Hi On Tuesday 20 December 2011, sf...@users.sourceforge.net wrote: > > Hello Stefan, > > "Stefan Lippers-Hollmann": > > You'll need to include <linux/export.h> in security/device_cgroup.c, to > > have EXPORT_SYMBOL (imho EXPORT_SYMBOL_GPL would make more sense in > > aufs3-standalone.patch) available to the module. > > If linux/export.h is the cause of the error, then it should be detected > at a comple-time instead of link-time, isn't it?
It is detected, just that it doesn't actually error out until the linking stage. Without "#include <linux/export.h>" in security/device_cgroup.c (I apply aufs3-standalone.patch after sed s/EXPORT_SYMBOL/\&_GPL/, but that doesn't make a difference here): CC security/lsm_audit.o CC security/device_cgroup.o /.../security/device_cgroup.c:503:1: warning: data definition has no type or storage class [enabled by default] /.../security/device_cgroup.c:503:1: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL_GPL' [-Wimplicit-int] /.../security/device_cgroup.c:503:1: warning: parameter names (without types) in function declaration [enabled by default] LD security/built-in.o With #include <linux/export.h> in security/device_cgroup.c: CC security/lsm_audit.o CC security/device_cgroup.o LD security/built-in.o [no warnings in fs/aufs/] Before 3.2-rcX, EXPORT_SYMBOL/ EXPORT_SYMBOL_GPL was defined by module.h (and by chance the other files for which aufs3-standalone.patch adds EXPORT_SYMBOL already include linux/export.h on their own), there are a couple of equivalent changes in 3.2~rc as well[1]; this becomes necessary because of[2]. Regards Stefan Lippers-Hollmann [1] http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=f4a65ad6eb9b56180724de52ddd6dd6712121be1 http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=a69e4c28b2bddc21b5752b1da8f43ab0a817305c http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=12b248eba4fd189216cad14b7dd1cfdacdf90cdf http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=e0ce42e19ce1978a5aee33b2954d7e1a730e88c4 http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=4af92e7a68af7b515d274f9d33b14b8a0804a0f6 http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=905905432868fa513f0f783fb9e5724536f4ee1f [...] [2] http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=f50169324df4ad942e544386d136216c8617636a ------------------------------------------------------------------------------ Write once. Port to many. Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join http://p.sf.net/sfu/intel-appdev