Question: ifconfig, ip and ethernet driver module

From: Joachim Franek (Joachim.Franek@t-online.de)
Date: Tue Feb 12 2002 - 02:33:56 EST


Hi,

I have a question about the location, the ip number is stored.
Kernel 2.4.x.

Assume there is a ethernet driver module eth.o. With
insmod eth.o there is eth1 available and with
ifconfig eth1 192.168.10.12 up
the interface is operational.

ifconfig calls the code of the function:
int eth_open(struct net_device *dev)

And at this time I want to know the parameter
of ifconfig.

my_network= ??? (Result: 192*256*256 + 168*156 + 10)
my_ip= ??? (Result: 12)
(assuming a netmask of 24 bits)

Thanks.

Joachim Franek
www.de-franek.de
rs485.de-franek.de
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Feb 15 2002 - 21:00:47 EST