* [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin
@ 2008-11-18 7:03 Bryan Wu
2008-11-19 6:33 ` Andrew Morton
0 siblings, 1 reply; 4+ messages in thread
From: Bryan Wu @ 2008-11-18 7:03 UTC (permalink / raw)
To: viro, akpm; +Cc: linux-kernel, Mike Frysinger, Bryan Wu
From: Mike Frysinger <vapier.adi@gmail.com>
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 <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
---
include/asm-generic/audit_write.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/include/asm-generic/audit_write.h b/include/asm-generic/audit_write.h
index f10d367..c5f1c2c 100644
--- a/include/asm-generic/audit_write.h
+++ b/include/asm-generic/audit_write.h
@@ -1,6 +1,8 @@
#include <asm-generic/audit_dir_write.h>
__NR_acct,
+#ifdef __NR_swapon
__NR_swapon,
+#endif
__NR_quotactl,
__NR_truncate,
#ifdef __NR_truncate64
--
1.5.6.3
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin
2008-11-18 7:03 [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin Bryan Wu
@ 2008-11-19 6:33 ` Andrew Morton
2008-11-19 7:08 ` Al Viro
2008-11-19 13:49 ` Mike Frysinger
0 siblings, 2 replies; 4+ messages in thread
From: Andrew Morton @ 2008-11-19 6:33 UTC (permalink / raw)
To: Bryan Wu; +Cc: viro, linux-kernel, Mike Frysinger
On Tue, 18 Nov 2008 15:03:49 +0800 Bryan Wu <cooloney@kernel.org> wrote:
> From: Mike Frysinger <vapier.adi@gmail.com>
>
> 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 <vapier.adi@gmail.com>
> Signed-off-by: Bryan Wu <cooloney@kernel.org>
> ---
> include/asm-generic/audit_write.h | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/include/asm-generic/audit_write.h b/include/asm-generic/audit_write.h
> index f10d367..c5f1c2c 100644
> --- a/include/asm-generic/audit_write.h
> +++ b/include/asm-generic/audit_write.h
> @@ -1,6 +1,8 @@
> #include <asm-generic/audit_dir_write.h>
> __NR_acct,
> +#ifdef __NR_swapon
> __NR_swapon,
> +#endif
> __NR_quotactl,
> __NR_truncate,
> #ifdef __NR_truncate64
hrm.
Should blackfin define __NR_swapon instead? afacit
include/asm/unistd.h is an exported-to-userspace header, so the
architecture should export __NR_swapon to prevent userspace build
failures?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin
2008-11-19 6:33 ` Andrew Morton
@ 2008-11-19 7:08 ` Al Viro
2008-11-19 13:49 ` Mike Frysinger
1 sibling, 0 replies; 4+ messages in thread
From: Al Viro @ 2008-11-19 7:08 UTC (permalink / raw)
To: Andrew Morton; +Cc: Bryan Wu, linux-kernel, Mike Frysinger
On Tue, Nov 18, 2008 at 10:33:08PM -0800, Andrew Morton wrote:
> > @@ -1,6 +1,8 @@
> > #include <asm-generic/audit_dir_write.h>
> > __NR_acct,
> > +#ifdef __NR_swapon
> > __NR_swapon,
> > +#endif
> > __NR_quotactl,
> > __NR_truncate,
> > #ifdef __NR_truncate64
>
> hrm.
>
> Should blackfin define __NR_swapon instead? afacit
> include/asm/unistd.h is an exported-to-userspace header, so the
> architecture should export __NR_swapon to prevent userspace build
> failures?
Not in the absense of syscall in question. Patch applied, will push the
tree tomorrow.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin
2008-11-19 6:33 ` Andrew Morton
2008-11-19 7:08 ` Al Viro
@ 2008-11-19 13:49 ` Mike Frysinger
1 sibling, 0 replies; 4+ messages in thread
From: Mike Frysinger @ 2008-11-19 13:49 UTC (permalink / raw)
To: Andrew Morton; +Cc: Bryan Wu, viro, linux-kernel
On Wed, Nov 19, 2008 at 01:33, Andrew Morton wrote:
> On Tue, 18 Nov 2008 15:03:49 +0800 Bryan Wu wrote:
>> From: Mike Frysinger <vapier.adi@gmail.com>
>> 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 <vapier.adi@gmail.com>
>> Signed-off-by: Bryan Wu <cooloney@kernel.org>
>> ---
>> include/asm-generic/audit_write.h | 2 ++
>> 1 files changed, 2 insertions(+), 0 deletions(-)
>>
>> diff --git a/include/asm-generic/audit_write.h b/include/asm-generic/audit_write.h
>> index f10d367..c5f1c2c 100644
>> --- a/include/asm-generic/audit_write.h
>> +++ b/include/asm-generic/audit_write.h
>> @@ -1,6 +1,8 @@
>> #include <asm-generic/audit_dir_write.h>
>> __NR_acct,
>> +#ifdef __NR_swapon
>> __NR_swapon,
>> +#endif
>> __NR_quotactl,
>> __NR_truncate,
>> #ifdef __NR_truncate64
>
> hrm.
>
> Should blackfin define __NR_swapon instead? afacit
> include/asm/unistd.h is an exported-to-userspace header, so the
> architecture should export __NR_swapon to prevent userspace build
> failures?
i dont think ports should be forced to define syscalls they dont
support. no-mmu cant do swap, so Blackfin doesnt define it ...
-mike
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-11-19 13:49 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-18 7:03 [PATCH] asm/generic: fix bug - kernel fails to build when enable some common audit code on Blackfin Bryan Wu
2008-11-19 6:33 ` Andrew Morton
2008-11-19 7:08 ` Al Viro
2008-11-19 13:49 ` Mike Frysinger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox