Messages in this thread | | | From | "Roman Mitnitski" <> | Subject | Spying on the state of network interfaces from a kernel module - how? | Date | Mon, 6 Sep 1999 19:34:11 +0200 |
| |
Hello.
I would like to know is there's an elegant solution to the following problem:
I need to track the state of network interfaces (going up/down, addition of the new interfaces, IP change (i.e. ifconfig) from a kernel module.
I imagine that I can poll for changes (I know how to walk the device list) but this is not "nice" and will leave time intervals when my module is not aware of the changes in network devices (which is a bad thing).
If there's any way to set up a callback (or insert my function into a call chain?) on the event of changes in network devices, it would help me a lot.
The other problem is that I want to be able to load my module on average preconfigured linux system without re-compiling the kernel.
---------------------------------------------
Also, if anyone knows how to control IP forwarding (on/off) from the kernel module please let me know. I can see the code that's responsible for /proc/sys/net/ipv4/ip_forward but the functions are not exported to /proc/ksyms.
Any help is welcome, please e-mail me directly at roman@checkpoint.com
Thanks in advance
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |