From: Mike Frysinger Date: Tue, 18 Nov 2008 07:03:49 +0000 (+0800) Subject: [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit... X-Git-Tag: v2.6.28-rc8~36^2~2 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=0b0c940a91f8e6fd0e1be3e01d5e98997446233b;p=linux-2.6-omap-h63xx.git [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin If you enable some common audit code, the kernel fails to build. In file included from lib/audit.c:17: include/asm-generic/audit_write.h:3: error: '__NR_swapon' undeclared here (not in a function) make[1]: *** [lib/audit.o] Error 1 make: *** [lib] Error 2 So do not use __NR_swapon if it isnt defined for a port. Signed-off-by: Mike Frysinger Signed-off-by: Bryan Wu Signed-off-by: Al Viro --- diff --git a/include/asm-generic/audit_write.h b/include/asm-generic/audit_write.h index f10d367fb2a..c5f1c2c920e 100644 --- a/include/asm-generic/audit_write.h +++ b/include/asm-generic/audit_write.h @@ -1,6 +1,8 @@ #include __NR_acct, +#ifdef __NR_swapon __NR_swapon, +#endif __NR_quotactl, __NR_truncate, #ifdef __NR_truncate64