[Toybox] [TOY] lspci
Andre Renaud
andre at bluewatersys.com
Fri Aug 2 15:07:38 PDT 2013
Hi Issac,
> to elements (one for each device) of an array of struct bar and the ref fields
> of the elements of this array should point back to the corresponding list
> element. Then, sort the array of struct bars according to ref->vendor and
> ref->device. Next, update ref->strs to point to the right element in the
> sorted array. Now we can start reading the (sorted) pci database line by
> line and fill out the other elements of the struct bar array. For the
> printing we iterate through the list of struct foo.
If this code gets written, it could be used equally well in the lsusb
code, as the usb database is almost identical to the pci one:
http://pci-ids.ucw.cz/pci.ids
http://www.linux-usb.org/usb.ids
Regards,
Andre
1375481258.0
More information about the Toybox
mailing list