Quote:
Originally Posted by catkin
You could look at the ethtool source for ideas.
EDIT: or you could use something like (my C is rusty) system( "ethtool" "<interface name>" ) and parse the output.
|
Command "ethtool -i <interface name>" really helpful. Thank you! Will look into ethtool's source codes later.
Quote:
Originally Posted by markush
You may scan the output of the last line of any devicesection shows the actually used module.
Or explore the sources of lspci respectively.
Markus
|
lspci only list the PCI based devices, USB devices will not be listed. That means if my program want to know the name of the driver used by my USB Network Interface Card, using lspci is impossible. However, I still appreciate for your reply.
Anyway, I still hope for more ideas. Anyone with any other ideas, or if anyone can suggest a library or give me sample codes, please feel free to reply here. Any replies, whether helpful or not, will be appreciated.