Welcome! Log In Create A New Profile

Advanced

compile networking stack kernel module

Posted by Greg 
compile networking stack kernel module
December 16, 2008 11:06PM
I'm new to OS development and hence linux development work.

> I've spent about a week trying to research linux kernel development for my
> project. My issue is with compiling the modified kernel source. Compiling
> the whole kernel is easily 2+ hours. I think my best option that I've come across is compiling an individual kernel module
> and reinstalling it.

> However the issue I'm having is figuring out which module corresponds to
> linux/net/ipv4/arp.c. I've read a lot and
> searched for many clues but haven't found anything too useful. (modinfo
> <modname>, lsmod, etc). I believe not all of the kernel is in modules, so
> possibly arp.c isn't linked into a module either?

Any answers for how I can quickly compile a small subset of the linux kernel? Particularly the networking stack (net/ipv4/arp.c)??

Thanks.
Re: compile networking stack kernel module
February 09, 2009 02:34AM
Looking at the Makefile in net/ipv4 subdirectory:

obj-y := route.o inetpeer.o protocol.o \
ip_input.o ip_fragment.o ip_forward.o ip_options.o \
ip_output.o ip_sockglue.o inet_hashtables.o \
inet_timewait_sock.o inet_connection_sock.o \
tcp.o tcp_input.o tcp_output.o tcp_timer.o tcp_ipv4.o \
tcp_minisocks.o tcp_cong.o \
datagram.o raw.o udp.o udplite.o \
arp.o icmp.o devinet.o af_inet.o igmp.o \
fib_frontend.o fib_semantics.o \
inet_fragment.o


It can be concluded that it does not offer any module option, which is "obj-m". Therefore, arp.o is compiled into the linux kernel's vmlinux image. It cannot be separated as a module, as far as I can see.
Author:

Your Email:


Subject:


Message: