* [PATCH] Include asm/siginfo.h in linux/coredump.h
@ 2012-10-10 22:04 Richard Weinberger
2012-10-10 22:16 ` Andrew Morton
0 siblings, 1 reply; 4+ messages in thread
From: Richard Weinberger @ 2012-10-10 22:04 UTC (permalink / raw)
To: linux-kernel
Cc: Richard Weinberger, Denys Vlasenko, Oleg Nesterov, Amerigo Wang,
Jonathan M. Foote, Roland McGrath, Pedro Alves, Fengguang Wu,
Stephen Rothwell, Andrew Morton
commit 5ab1c30 (coredump: pass siginfo_t* to do_coredump() and below, not merely signr)
added siginfo_t to linux/coredump.h but forgot to include asm/siginfo.h.
This breaks the build for UML/i386.
(And any other arch where asm/siginfo.h is not magically preincluded...)
In file included from arch/x86/um/elfcore.c:2:0:
include/linux/coredump.h:15:25: error: unknown type name 'siginfo_t'
make[1]: *** [arch/x86/um/elfcore.o] Error 1
Cc: Denys Vlasenko <vda.linux@googlemail.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Amerigo Wang <amwang@redhat.com>
Cc: "Jonathan M. Foote" <jmfoote@cert.org>
Cc: Roland McGrath <roland@hack.frob.com>
Cc: Pedro Alves <palves@redhat.com>
Cc: Fengguang Wu <fengguang.wu@intel.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Richard Weinberger <richard@nod.at>
---
include/linux/coredump.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/linux/coredump.h b/include/linux/coredump.h
index 1775eb8..1d73993 100644
--- a/include/linux/coredump.h
+++ b/include/linux/coredump.h
@@ -4,6 +4,7 @@
#include <linux/types.h>
#include <linux/mm.h>
#include <linux/fs.h>
+#include <asm/siginfo.h>
/*
* These are the only things you should do on a core-file: use only these
--
1.7.12.1
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Include asm/siginfo.h in linux/coredump.h
2012-10-10 22:04 [PATCH] Include asm/siginfo.h in linux/coredump.h Richard Weinberger
@ 2012-10-10 22:16 ` Andrew Morton
2012-10-10 22:20 ` Richard Weinberger
0 siblings, 1 reply; 4+ messages in thread
From: Andrew Morton @ 2012-10-10 22:16 UTC (permalink / raw)
To: Richard Weinberger
Cc: linux-kernel, Denys Vlasenko, Oleg Nesterov, Amerigo Wang,
Jonathan M. Foote, Roland McGrath, Pedro Alves, Fengguang Wu,
Stephen Rothwell
On Thu, 11 Oct 2012 00:04:07 +0200
Richard Weinberger <richard@nod.at> wrote:
> commit 5ab1c30 (coredump: pass siginfo_t* to do_coredump() and below, not merely signr)
> added siginfo_t to linux/coredump.h but forgot to include asm/siginfo.h.
> This breaks the build for UML/i386.
> (And any other arch where asm/siginfo.h is not magically preincluded...)
>
> In file included from arch/x86/um/elfcore.c:2:0:
> include/linux/coredump.h:15:25: error: unknown type name 'siginfo_t'
> make[1]: *** [arch/x86/um/elfcore.o] Error 1
>
> Cc: Denys Vlasenko <vda.linux@googlemail.com>
> Cc: Oleg Nesterov <oleg@redhat.com>
> Cc: Amerigo Wang <amwang@redhat.com>
> Cc: "Jonathan M. Foote" <jmfoote@cert.org>
> Cc: Roland McGrath <roland@hack.frob.com>
> Cc: Pedro Alves <palves@redhat.com>
> Cc: Fengguang Wu <fengguang.wu@intel.com>
> Cc: Stephen Rothwell <sfr@canb.auug.org.au>
> Cc: Andrew Morton <akpm@linux-foundation.org>
> Signed-off-by: Richard Weinberger <richard@nod.at>
> ---
> include/linux/coredump.h | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/include/linux/coredump.h b/include/linux/coredump.h
> index 1775eb8..1d73993 100644
> --- a/include/linux/coredump.h
> +++ b/include/linux/coredump.h
> @@ -4,6 +4,7 @@
> #include <linux/types.h>
> #include <linux/mm.h>
> #include <linux/fs.h>
> +#include <asm/siginfo.h>
>
> /*
> * These are the only things you should do on a core-file: use only these
hm, yes. It would be nice to jsut forward-declare the struct but we
can't do that because it's a pesky typedef.
I wonder if it would be cleaner to just include linux/signal.h? Diving
down into the arch layer is a bit unusual. Doesn't matter, I guess.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Include asm/siginfo.h in linux/coredump.h
2012-10-10 22:16 ` Andrew Morton
@ 2012-10-10 22:20 ` Richard Weinberger
2012-10-10 22:34 ` Roland McGrath
0 siblings, 1 reply; 4+ messages in thread
From: Richard Weinberger @ 2012-10-10 22:20 UTC (permalink / raw)
To: Andrew Morton
Cc: linux-kernel, Denys Vlasenko, Oleg Nesterov, Amerigo Wang,
Jonathan M. Foote, Roland McGrath, Pedro Alves, Fengguang Wu,
Stephen Rothwell
Am Wed, 10 Oct 2012 15:16:59 -0700
schrieb Andrew Morton <akpm@linux-foundation.org>:
> On Thu, 11 Oct 2012 00:04:07 +0200
> Richard Weinberger <richard@nod.at> wrote:
>
> > commit 5ab1c30 (coredump: pass siginfo_t* to do_coredump() and
> > below, not merely signr) added siginfo_t to linux/coredump.h but
> > forgot to include asm/siginfo.h. This breaks the build for UML/i386.
> > (And any other arch where asm/siginfo.h is not magically
> > preincluded...)
> >
> > In file included from arch/x86/um/elfcore.c:2:0:
> > include/linux/coredump.h:15:25: error: unknown type name 'siginfo_t'
> > make[1]: *** [arch/x86/um/elfcore.o] Error 1
> >
> > Cc: Denys Vlasenko <vda.linux@googlemail.com>
> > Cc: Oleg Nesterov <oleg@redhat.com>
> > Cc: Amerigo Wang <amwang@redhat.com>
> > Cc: "Jonathan M. Foote" <jmfoote@cert.org>
> > Cc: Roland McGrath <roland@hack.frob.com>
> > Cc: Pedro Alves <palves@redhat.com>
> > Cc: Fengguang Wu <fengguang.wu@intel.com>
> > Cc: Stephen Rothwell <sfr@canb.auug.org.au>
> > Cc: Andrew Morton <akpm@linux-foundation.org>
> > Signed-off-by: Richard Weinberger <richard@nod.at>
> > ---
> > include/linux/coredump.h | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/include/linux/coredump.h b/include/linux/coredump.h
> > index 1775eb8..1d73993 100644
> > --- a/include/linux/coredump.h
> > +++ b/include/linux/coredump.h
> > @@ -4,6 +4,7 @@
> > #include <linux/types.h>
> > #include <linux/mm.h>
> > #include <linux/fs.h>
> > +#include <asm/siginfo.h>
> >
> > /*
> > * These are the only things you should do on a core-file: use
> > only these
>
> hm, yes. It would be nice to jsut forward-declare the struct but we
> can't do that because it's a pesky typedef.
I know. :-\
> I wonder if it would be cleaner to just include linux/signal.h?
> Diving down into the arch layer is a bit unusual. Doesn't matter, I
> guess.
I chose asm/siginfo.h because other users of siginfo_t also just
include this file and linux/signal.h includes much more than we
actually need...
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-10-10 22:34 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-10 22:04 [PATCH] Include asm/siginfo.h in linux/coredump.h Richard Weinberger
2012-10-10 22:16 ` Andrew Morton
2012-10-10 22:20 ` Richard Weinberger
2012-10-10 22:34 ` Roland McGrath
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®