Re: How to get all network devices

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Yi-Wen,
The variable dev_base holds the pointer to the linked list of net_devices. You can traverse this linked list & read all the interfaces.
remember to hold a read lock while accessing dev_base.
read_lock(&dev_base_lock);


The variable dev_base is defined in space.c
hope that helps.



On Wed, 23 Jul 2003 blue wrote :
Hi, all
Is there any method to get all network interfaces? I want to write a
kernel module.
I searched kernel API, but there's no such method for me to call.


Thanks for your help

Best regards

Yi-Wen
-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html

___________________________________________________
Download the hottest & happening ringtones here!
OR SMS: Top tone to 7333
Click here now: http://sms.rediff.com/cgi-bin/ringtone/ringhome.pl



- : send the line "unsubscribe linux-net" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux