If you want to scan the interface list from kernel space you can do something like:
{
	struct device *dev;
	for (dev = dev_base; dev != NULL; dev = dev->next) 
        {
		/* your code here */
		/* example */
		
		if (dev->family == AF_INET)
		{
			/* this is an inet device */
		}
		if (dev->type == ARPHRD_ETHER)
		{
			/* this is ethernet */
		}
	}
}
./Pedro.
 |