|
[tipc-discussion] net/tipc/tipc_netlink.c:72: error: too few arguments to function ‘genlmsg_unicast’
From: Yordan P. <y.d...@gm...> - 2010-02-16 14:26:53
|
I receive the following error while trying to build the Tipc kernel module: net/tipc/tipc_netlink.c: In function ‘handle_cmd’: net/tipc/tipc_netlink.c:72: warning: passing argument 1 of ‘genlmsg_unicast’ from incompatible pointer type include/net/genetlink.h:242: note: expected ‘struct net *’ but argument is of type ‘struct sk_buff *’ net/tipc/tipc_netlink.c:72: warning: passing argument 2 of ‘genlmsg_unicast’ makes pointer from integer without a cast include/net/genetlink.h:242: note: expected ‘struct sk_buff *’ but argument is of type ‘__u32’ net/tipc/tipc_netlink.c:72: error: too few arguments to function ‘genlmsg_unicast’ make[1]: *** [net/tipc/tipc_netlink.o] Error 1 make: *** [_module_net/tipc] Error 2 checking through the source code I noticed that the genlmsg_unicast takes 3 parameters while tipc calls it with only 2. My system is: Debian testing. I am building against Debian patched kernel 2.6.32 I have downloaded tipc-1.7.6-bundle from the Tipc website. |
|
From: Stephens, A. <all...@wi...> - 2010-02-16 14:47:13
|
Hi Yordan: As noted on the TIPC project website, TIPC 1.7.6 only supports Linux kernels in the range 2.6.16-2.6.28. A TIPC 1.7.7 release that also supports later releases is being developed, but won't be available for a while. I suggest that you take a look at the TIPC 1.6 code that originally came with Linux 2.6.32 to see what parameters genlmsg_unicast() is using there. Hopefully, it will be relatively easy to port this change to your TIPC 1.7.6 code and get you up and running. Regards, Al > -----Original Message----- > From: Yordan Pavlov [mailto:y.d...@gm...] > Sent: Tuesday, February 16, 2010 9:27 AM > To: tip...@li... > Subject: [tipc-discussion] net/tipc/tipc_netlink.c:72: error: > too few arguments to function 'genlmsg_unicast' > > I receive the following error while trying to build the Tipc > kernel module: > > net/tipc/tipc_netlink.c: In function 'handle_cmd': > net/tipc/tipc_netlink.c:72: warning: passing argument 1 of > 'genlmsg_unicast' > from incompatible pointer type > include/net/genetlink.h:242: note: expected 'struct net *' > but argument is of type 'struct sk_buff *' > net/tipc/tipc_netlink.c:72: warning: passing argument 2 of > 'genlmsg_unicast' > makes pointer from integer without a cast > include/net/genetlink.h:242: note: expected 'struct sk_buff > *' but argument is of type '__u32' > net/tipc/tipc_netlink.c:72: error: too few arguments to > function 'genlmsg_unicast' > make[1]: *** [net/tipc/tipc_netlink.o] Error 1 > make: *** [_module_net/tipc] Error 2 > > checking through the source code I noticed that the > genlmsg_unicast takes 3 parameters while tipc calls it with only 2. > > My system is: > Debian testing. > I am building against Debian patched kernel 2.6.32 I have > downloaded tipc-1.7.6-bundle from the Tipc website. > -------------------------------------------------------------- > ---------------- > SOLARIS 10 is the OS for Data Centers - provides features > such as DTrace, Predictive Self Healing and Award Winning > ZFS. Get Solaris 10 NOW http://p.sf.net/sfu/solaris-dev2dev > _______________________________________________ > tipc-discussion mailing list > tip...@li... > https://lists.sourceforge.net/lists/listinfo/tipc-discussion > |
|
From: Stephens, A. <all...@wi...> - 2010-02-16 19:47:48
|
Hi Yordan: See responses inline below. -- Al ________________________________ From: Yordan Pavlov [mailto:y.d...@gm...] Sent: Tuesday, February 16, 2010 12:12 PM To: Stephens, Allan Subject: Re: [tipc-discussion] net/tipc/tipc_netlink.c:72: error: too few arguments to function 'genlmsg_unicast' Thanks for the fast response. I did notice the site saying that 1.7 supports kernels through 2.6.16 to 2.6.28 however 1.6 is said to support even older kernels so I thought that what I have in my debian kernel is actually version 1.7 of Tipc. [AL] TIPC 1.6 is integrated with the Linux kernel, and is available in all Linux kernels from 2.6.16 up to the most recent. TIPC 1.7 is a newer version of TIPC, and contains a number of additional capabilities and bug fixes that are not available in TIPC 1.6; however, it is an add-on that currently only supports the 2.6.16-2.6.28 range. As mentioned previously, we're going to update TIPC 1.7 in the next few months to make it usable on newer kernels. After that, we hope we can integrate it into the kernel so that we can stop supporting TIPC 1.6 entirely. As for trying to fix the error as you suggested, here is what I did. 1) I copied the 1.7 tipc files over what my debian kernel had in its source. 2) The error happened when trying to build net/tipc/tipc_netlink.c and since my original debian kernel does not have such file in its /net/tipc directory I removed it, also removing dependency to it in the Makefile in /net/tipc 3) After doing this I managed to build both the kernel module and the tipc config application. However I am a bit skeptical towards my fix. I guess there is a really good reason for why 2.7 can not work on 2.6.32 and if it were for such a quick fix you would have done it. [AL] The TIPC 1.6 and TIPC 1.7 products use slightly different file name conventions, with TIPC 1.7 adding the prefix "tipc_" to most of its file names. If you look in the file "net/tipc/netlink.c" in TIPC 1.6 (rather than "net/tipc/tipc_netlink.c") you should find the reference to genlmsg_unicast() I was referring to in my previous email. The concern that I've got with your current workaround is that by completely removing TIPC's support for netlink you will almost certainly find that the tipc-config dpesn't work for you because it will be unable to communicate via netlink with TIPC in the kernel. On Tue, Feb 16, 2010 at 4:47 PM, Stephens, Allan <all...@wi...> wrote: Hi Yordan: As noted on the TIPC project website, TIPC 1.7.6 only supports Linux kernels in the range 2.6.16-2.6.28. A TIPC 1.7.7 release that also supports later releases is being developed, but won't be available for a while. I suggest that you take a look at the TIPC 1.6 code that originally came with Linux 2.6.32 to see what parameters genlmsg_unicast() is using there. Hopefully, it will be relatively easy to port this change to your TIPC 1.7.6 code and get you up and running. Regards, Al |