That really fixed it .. thanks randy But Last time when I tried in 2.6.32 kernel I am not including kconfig.h. Is there any major change by latest 3.7 kernel where we need to add kconfig.h in code ? Just knowing Regards, Ajith -------------------------------------------- codingfreak.in On Thu, Feb 21, 2013 at 12:46 AM, Randy Dunlap <rdunlap@xxxxxxxxxxxxx> wrote: > On 02/19/13 20:21, Ajith Adapa wrote: >> Hi, >> >> I am not sure if this is the right place to ask the doubt or not but >> since I got this issue building LKM i am dropping a maile down here >> sorry for inconvenience caused. >> >> I am trying to build private LKM on latest 3.7 kernel using GCC 4.7.2. >> >> /usr/bin/gcc -M -g -O2 -DMODULE -D__KERNEL__ -DLINUX >> -fno-strict-aliasing -fno-common -ffreestanding -O2 -m32 >> -fomit-frame-pointer -g -pipe -msoft-float >> -mpreferred-stack-boundary=2 -fno-unit-at-a-time -march=i686 >> -mtune=pentium4 -mregparm=3 -I/lib/modules/3.7.6.1.i686/source/include >> -I/lib/modules/3.7.6.1.i686/source/arch/x86/include >> -I/lib/modules/3.7.6.1.i686/source/include >> -I/lib/modules/3.7.6.1.i686/source/include2 >> -I/lib/modules/3.7.6.1.i686/source/include/asm/mach-default >> -I/lib/modules/3.7.6.1.i686/source/include2/asm/mach-default >> -I/lib/modules/3.7.6.1.i686/source/include/uapi >> -I/lib/modules/3.7.6.1.i686/source/include/linux/kconfig.h >> -I/lib/modules/3.7.6.1.i686/source/include/generated/uapi >> -I/lib/modules/3.7.6.1.i686/source/arch/x86/include/generated/uapi >> -m32 tmp/l2.c >> >> I get the following error as shown below >> >> In file included from /home/linux-26/include/net/net_namespace.h:13:0, >> from /home/linux-26/include/linux/netdevice.h:43, >> from tmp/l2.c:26: >> /home/linux-26/include/net/netns/mib.h:15:15: error: missing binary >> operator before token "(" >> In file included from /home/linux-26/include/net/net_namespace.h:17:0, >> from /home/linux-26/include/linux/netdevice.h:43, >> from tmp/l2.c:26: >> /home/linux-26/include/net/netns/ipv6.h:75:15: error: missing binary >> operator before token "(" >> >> Any idea about the issue ?? Even I include uapi directory properly in >> the command. > > Does your module source file > #include <linux/kconfig.h> > ? > It probably needs to #include that file. > > > > -- > ~Randy -- To unsubscribe from this list: send the line "unsubscribe linux-modules" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html