LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-16-2006, 10:09 PM   #1
hedpe
Member
 
Registered: Jan 2005
Location: Boston, MA
Distribution: Debian
Posts: 380

Rep: Reputation: 30
need help compiling this module meant for 2.6.9 kernel


Hey guys,

I am trying to compile some code that compiles fine on the kernel it was intended for, 2.6.9 ... well I am running 2.6.15-r1 now and it seems some kernel IP implementation has changed.

Here is the error/warning:
Code:
*** Warning: "tcp_protocol" [/home/hedpe/temp/host_driver.ko] undefined!
Which comes from the line:
Code:
extern struct net_protocol tcp_protocol;  /* The TCP protocol already defined */
Well, i suppose its no longer already defined

On another note, he was using the structures tcp_opt and inet_opt which I believe were replaced by tcp_sock and inet_sock

I can't seem however to find out what replaced tcp_protocol so I can update this code.

Thanks!
George
 
Old 02-17-2006, 01:44 AM   #2
hedpe
Member
 
Registered: Jan 2005
Location: Boston, MA
Distribution: Debian
Posts: 380

Original Poster
Rep: Reputation: 30
you know what thought, i found this still in my 2.6.15-r1 kernel:

/usr/src/linux/net/ipv4/af_inet.c
Code:
static struct net_protocol tcp_protocol = {
  .handler =  tcp_v4_rcv,
  .err_handler =  tcp_v4_err,
  .no_policy =  1,
};
so why is it giving me that error?

That is ipv4 code... and since i'm talking on this very forum, I am assuming ipv4 is working :P

when I try to load the module, dmesg also spits out at me:
Code:
host_driver: Unknown symbol tcp_protocol
here are some of my kernel settings:
Code:
monster xcp_host # grep "NET" /usr/src/linux/.config
CONFIG_NET=y
# CONFIG_NET_KEY is not set
CONFIG_INET=y
# CONFIG_NET_IPIP is not set
# CONFIG_NET_IPGRE is not set
# CONFIG_INET_AH is not set
# CONFIG_INET_ESP is not set
# CONFIG_INET_IPCOMP is not set
# CONFIG_INET_TUNNEL is not set
CONFIG_INET_DIAG=y
CONFIG_INET_TCP_DIAG=y
CONFIG_NETFILTER=y
# CONFIG_NETFILTER_DEBUG is not set
# CONFIG_NETFILTER_NETLINK is not set
# CONFIG_IP_NF_NETBIOS_NS is not set
CONFIG_IP_NF_TARGET_NETMAP=y
# CONFIG_DECNET is not set
# CONFIG_NET_DIVERT is not set
# CONFIG_ECONET is not set
# CONFIG_NET_SCHED is not set
# CONFIG_NET_PKTGEN is not set
CONFIG_NETDEVICES=y
# CONFIG_NET_SB1000 is not set
# CONFIG_ARCNET is not set
CONFIG_NET_ETHERNET=y
# CONFIG_NET_VENDOR_3COM is not set
# CONFIG_NET_VENDOR_SMC is not set
# CONFIG_NET_VENDOR_RACAL is not set
# CONFIG_NET_TULIP is not set
# CONFIG_NET_ISA is not set
CONFIG_NET_PCI=y
# CONFIG_PCNET32 is not set
# CONFIG_NET_POCKET is not set
CONFIG_NET_RADIO=y
CONFIG_NET_WIRELESS=y
# CONFIG_NET_FC is not set
# CONFIG_NETCONSOLE is not set
# CONFIG_NETPOLL is not set
# CONFIG_NET_POLL_CONTROLLER is not set
# CONFIG_USB_USBNET is not set

Last edited by hedpe; 02-17-2006 at 02:10 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
compiling only one module without recompiling the kernel l_9_l Linux - General 8 07-06-2009 10:00 PM
Trouble Compiling Kernel Module... Elric of Grans Linux - General 2 05-31-2006 12:57 AM
compiling single kernel module only evil_empire Linux - Software 2 01-31-2006 12:44 AM
Compiling a module/Kernel mismatch fbarre Linux - Newbie 2 09-04-2003 08:26 PM
Kernel compiling and module compiling tarballed Linux - General 1 12-22-2002 05:31 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration