]>
git.ipfire.org Git - people/dweismueller/ipfire-2.x.git/blob - src/hwinfo/src/hd/veth.c
facef7756f7818b7c2c48f4d8f608fdcff353597
14 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
15 * iSeries veth devices
17 * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
22 void hd_scan_veth(hd_data_t
*hd_data
)
29 if(!hd_probe_feature(hd_data
, pr_veth
)) return;
31 hd_data
->module
= mod_veth
;
34 remove_hd_entries(hd_data
);
36 PROGRESS(1, 0, "read data");
38 if((dir
= opendir(PROC_ISERIES_VETH
))) {
39 while((de
= readdir(dir
))) {
40 if(sscanf(de
->d_name
, "veth%u", &u
) == 1) {
41 hd
= add_hd_entry(hd_data
, __LINE__
, 0);
42 hd
->base_class
.id
= bc_network
;
44 hd
->vendor
.id
= MAKE_ID(TAG_SPECIAL
, 0x6001); // IBM
45 hd
->device
.id
= MAKE_ID(TAG_SPECIAL
, 0x1000);
46 str_printf(&hd
->device
.name
, 0, "Virtual Ethernet card %d", hd
->slot
);
52 if((dir
= opendir(PROC_ISERIES
))) {
53 hd
= add_hd_entry(hd_data
, __LINE__
, 0);
54 hd
->base_class
.id
= bc_network
;
56 hd
->vendor
.id
= MAKE_ID(TAG_SPECIAL
, 0x6001); // IBM
57 hd
->device
.id
= MAKE_ID(TAG_SPECIAL
, 0x1000);
58 str_printf(&hd
->device
.name
, 0, "Virtual Ethernet card %d", hd
->slot
);