linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build failure after merge of the final tree (tile tree related)
@ 2010-06-07  4:01 Stephen Rothwell
  2010-06-07 12:48 ` [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h> Chris Metcalf
  2010-06-07 12:56 ` linux-next: build failure after merge of the final tree (tile tree related) Chris Metcalf
  0 siblings, 2 replies; 6+ messages in thread
From: Stephen Rothwell @ 2010-06-07  4:01 UTC (permalink / raw)
  To: Chris Metcalf; +Cc: linux-next, linux-kernel, David S. Miller, Arnd Bergmann

Hi Chris,

After merging the final tree, today's linux-next build (sparc32 defconfig)
failed like this:

arch/sparc/kernel/sys_sparc_32.c:229: error: conflicting types for 'sys_rt_sigaction'
include/linux/syscalls.h:367: note: previous declaration of 'sys_rt_sigaction' was here

Caused by commit 5360bd776f73d0a7da571d72a09a03f237e99900 ("Fix up the
"generic" unistd.h ABI to be more useful") from the tile tree.  Sparc's
sys_rt_sigaction has an extra argument.

I applied this patch for today.  Something better could probably be
done.  I note that there is already a declaration of sys_rt_sigaction in
include/asm-generic/syscalls.h ...

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Mon, 7 Jun 2010 13:49:46 +1000
Subject: [PATCH] Only declare sys_rt_sigaction if it is wanted.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 include/linux/syscalls.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h
index 61663cb..4193907 100644
--- a/include/linux/syscalls.h
+++ b/include/linux/syscalls.h
@@ -364,9 +364,11 @@ asmlinkage long sys_init_module(void __user *umod, unsigned long len,
 asmlinkage long sys_delete_module(const char __user *name_user,
 				unsigned int flags);
 
+#ifdef __ARCH_WANT_SYS_RT_SIGACTION
 asmlinkage long sys_rt_sigaction(int sig, const struct sigaction __user *act,
 				 struct sigaction __user *oact,
 				 size_t sigsetsize);
+#endif
 asmlinkage long sys_rt_sigprocmask(int how, sigset_t __user *set,
 				sigset_t __user *oset, size_t sigsetsize);
 asmlinkage long sys_rt_sigpending(sigset_t __user *set, size_t sigsetsize);
-- 
1.7.1

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h>.
  2010-06-07  4:01 linux-next: build failure after merge of the final tree (tile tree related) Stephen Rothwell
@ 2010-06-07 12:48 ` Chris Metcalf
  2010-06-07 13:18   ` Arnd Bergmann
  2010-06-07 12:56 ` linux-next: build failure after merge of the final tree (tile tree related) Chris Metcalf
  1 sibling, 1 reply; 6+ messages in thread
From: Chris Metcalf @ 2010-06-07 12:48 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, David S. Miller, Arnd Bergmann

It turns out there is some variance on the calling conventions for
these syscalls, and <asm-generic/syscalls.h> is already the mechanism
used to handle this.  Switch arch/tile over to using that mechanism and
tweak the calling conventions for a couple of tile syscalls to match
<asm-generic/syscalls.h>.

Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
---
 arch/tile/include/asm/syscalls.h |   22 +---------------------
 arch/tile/kernel/process.c       |    2 +-
 arch/tile/kernel/signal.c        |    4 ++--
 arch/tile/kernel/sys.c           |    2 +-
 include/linux/syscalls.h         |    4 ----
 5 files changed, 5 insertions(+), 29 deletions(-)

diff --git a/arch/tile/include/asm/syscalls.h b/arch/tile/include/asm/syscalls.h
index e1be54d..9f2b8e2 100644
--- a/arch/tile/include/asm/syscalls.h
+++ b/arch/tile/include/asm/syscalls.h
@@ -22,21 +22,7 @@
 #include <linux/linkage.h>
 #include <linux/signal.h>
 #include <linux/types.h>
-
-/* kernel/process.c */
-int sys_fork(struct pt_regs *);
-int sys_vfork(struct pt_regs *);
-int sys_clone(unsigned long clone_flags, unsigned long newsp,
-	      int __user *parent_tidptr, int __user *child_tidptr,
-	      struct pt_regs *);
-int sys_execve(char __user *path, char __user *__user *argv,
-	       char __user *__user *envp, struct pt_regs *);
-
-/* kernel/signal.c */
-int sys_sigaltstack(const stack_t __user *, stack_t __user *,
-		    struct pt_regs *);
-long sys_rt_sigreturn(struct pt_regs *);
-int sys_raise_fpe(int code, unsigned long addr, struct pt_regs*);
+#include <asm-generic/syscalls.h>
 
 /* kernel/sys.c */
 ssize_t sys32_readahead(int fd, u32 offset_lo, u32 offset_hi, u32 count);
@@ -45,12 +31,6 @@ long sys32_fadvise64(int fd, u32 offset_lo, u32 offset_hi,
 int sys32_fadvise64_64(int fd, u32 offset_lo, u32 offset_hi,
 		       u32 len_lo, u32 len_hi, int advice);
 long sys_flush_cache(void);
-long sys_mmap(unsigned long addr, unsigned long len,
-	      unsigned long prot, unsigned long flags,
-	      unsigned long fd, unsigned long offset);
-long sys_mmap2(unsigned long addr, unsigned long len,
-	       unsigned long prot, unsigned long flags,
-	       unsigned long fd, unsigned long offset);
 
 #ifndef __tilegx__
 /* mm/fault.c */
diff --git a/arch/tile/kernel/process.c b/arch/tile/kernel/process.c
index 824f230..c70ff14 100644
--- a/arch/tile/kernel/process.c
+++ b/arch/tile/kernel/process.c
@@ -502,7 +502,7 @@ int _sys_fork(struct pt_regs *regs)
 }
 
 int _sys_clone(unsigned long clone_flags, unsigned long newsp,
-	       int __user *parent_tidptr, int __user *child_tidptr,
+	       void __user *parent_tidptr, void __user *child_tidptr,
 	       struct pt_regs *regs)
 {
 	if (!newsp)
diff --git a/arch/tile/kernel/signal.c b/arch/tile/kernel/signal.c
index 7ea85eb..45835cf 100644
--- a/arch/tile/kernel/signal.c
+++ b/arch/tile/kernel/signal.c
@@ -43,8 +43,8 @@
 /* Caller before callee in this file; other callee is in assembler */
 void do_signal(struct pt_regs *regs);
 
-int _sys_sigaltstack(const stack_t __user *uss,
-		     stack_t __user *uoss, struct pt_regs *regs)
+long _sys_sigaltstack(const stack_t __user *uss,
+                      stack_t __user *uoss, struct pt_regs *regs)
 {
 	return do_sigaltstack(uss, uoss, regs->sp);
 }
diff --git a/arch/tile/kernel/sys.c b/arch/tile/kernel/sys.c
index a3d982b..0427978 100644
--- a/arch/tile/kernel/sys.c
+++ b/arch/tile/kernel/sys.c
@@ -95,7 +95,7 @@ SYSCALL_DEFINE6(mmap2, unsigned long, addr, unsigned long, len,
  */
 SYSCALL_DEFINE6(mmap, unsigned long, addr, unsigned long, len,
 		unsigned long, prot, unsigned long, flags,
-		unsigned long, fd, unsigned long, offset)
+		unsigned long, fd, off_t, offset)
 {
 	if (offset & ((1 << PAGE_SHIFT) - 1))
 		return -EINVAL;
diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h
index 1e3cd5f..7f614ce 100644
--- a/include/linux/syscalls.h
+++ b/include/linux/syscalls.h
@@ -364,13 +364,9 @@ asmlinkage long sys_init_module(void __user *umod, unsigned long len,
 asmlinkage long sys_delete_module(const char __user *name_user,
 				unsigned int flags);
 
-asmlinkage long sys_rt_sigaction(int sig, const struct sigaction __user *act,
-				 struct sigaction __user *oact,
-				 size_t sigsetsize);
 asmlinkage long sys_rt_sigprocmask(int how, sigset_t __user *set,
 				sigset_t __user *oset, size_t sigsetsize);
 asmlinkage long sys_rt_sigpending(sigset_t __user *set, size_t sigsetsize);
-asmlinkage long sys_rt_sigsuspend(sigset_t __user *unewset, size_t sigsetsize);
 asmlinkage long sys_rt_sigtimedwait(const sigset_t __user *uthese,
 				siginfo_t __user *uinfo,
 				const struct timespec __user *uts,
-- 
1.6.5.2

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: linux-next: build failure after merge of the final tree (tile tree related)
  2010-06-07  4:01 linux-next: build failure after merge of the final tree (tile tree related) Stephen Rothwell
  2010-06-07 12:48 ` [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h> Chris Metcalf
@ 2010-06-07 12:56 ` Chris Metcalf
  1 sibling, 0 replies; 6+ messages in thread
From: Chris Metcalf @ 2010-06-07 12:56 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, David S. Miller, Arnd Bergmann

On 6/7/2010 12:01 AM, Stephen Rothwell wrote:
> I applied this patch for today.  Something better could probably be
> done.  I note that there is already a declaration of sys_rt_sigaction in
> include/asm-generic/syscalls.h ...
>   

Yes, thanks for the pointer.  In fact by adjusting a couple of tile
syscalls slightly I can just use <asm-generic/syscalls.h> wholesale.  I
reverted the addition of sys_rt_sigaction() and sys_rt_sigsuspend() to
<linux/syscalls.h> and cleaned up the arch/tile/include/asm/syscalls.h
as well.  I mailed the patch as another reply-to to Stephen's original
message.

-- 
Chris Metcalf, Tilera Corp.
http://www.tilera.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h>.
  2010-06-07 12:48 ` [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h> Chris Metcalf
@ 2010-06-07 13:18   ` Arnd Bergmann
  0 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2010-06-07 13:18 UTC (permalink / raw)
  To: Chris Metcalf; +Cc: Stephen Rothwell, linux-next, linux-kernel, David S. Miller

On Monday 07 June 2010, Chris Metcalf wrote:
> It turns out there is some variance on the calling conventions for
> these syscalls, and <asm-generic/syscalls.h> is already the mechanism
> used to handle this.  Switch arch/tile over to using that mechanism and
> tweak the calling conventions for a couple of tile syscalls to match
> <asm-generic/syscalls.h>.
> 
> Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>

Looks good to me.

Acked-by: Arnd Bergmann <arnd@arndb.de>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* linux-next: build failure after merge of the final tree (tile tree related)
@ 2011-05-24  3:42 Stephen Rothwell
  2011-05-24 12:25 ` Chris Metcalf
  0 siblings, 1 reply; 6+ messages in thread
From: Stephen Rothwell @ 2011-05-24  3:42 UTC (permalink / raw)
  To: Chris Metcalf; +Cc: linux-next, linux-kernel

Hi Chris,

After merging the final tree, today's linux-next build (sparc64 defconfig)
failed like this:

In file included from arch/sparc/include/asm/siginfo.h:19,
                 from include/linux/signal.h:5,
                 from include/linux/sched.h:73,
                 from arch/sparc/kernel/asm-offsets.c:13:
include/linux/compat.h:401: error: expected ')' before 'ctx_id'
include/linux/compat.h:406: error: expected ')' before 'ctx_id'

Caused by commit be84cb43833e ("compat: fixes to allow working with tile arch").

I added this patch for today:

From: Stephen Rothwell <sfr@canb.auug.org.au>
Date: Tue, 24 May 2011 13:28:54 +1000
Subject: [PATCH] compat: include aio_abi.h for aio_context_t

fixes this build error on sparc64 (at least):

In file included from arch/sparc/include/asm/siginfo.h:19,
                 from include/linux/signal.h:5,
                 from include/linux/sched.h:73,
                 from arch/sparc/kernel/asm-offsets.c:13:
include/linux/compat.h:401: error: expected ')' before 'ctx_id'
include/linux/compat.h:406: error: expected ')' before 'ctx_id'

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 include/linux/compat.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/include/linux/compat.h b/include/linux/compat.h
index 644e1a4..ddcb7db 100644
--- a/include/linux/compat.h
+++ b/include/linux/compat.h
@@ -13,6 +13,7 @@
 #include <linux/socket.h>
 #include <linux/if.h>
 #include <linux/fs.h>
+#include <linux/aio_abi.h>	/* for aio_context_t */
 
 #include <asm/compat.h>
 #include <asm/siginfo.h>
-- 
1.7.5.1

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: linux-next: build failure after merge of the final tree (tile tree related)
  2011-05-24  3:42 Stephen Rothwell
@ 2011-05-24 12:25 ` Chris Metcalf
  0 siblings, 0 replies; 6+ messages in thread
From: Chris Metcalf @ 2011-05-24 12:25 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel

On 5/23/2011 11:42 PM, Stephen Rothwell wrote:
> Hi Chris,
>
> After merging the final tree, today's linux-next build (sparc64 defconfig)
> failed like this:
>
> [...]
>
> I added this patch for today:
>
> [...]
>
> diff --git a/include/linux/compat.h b/include/linux/compat.h
> index 644e1a4..ddcb7db 100644
> --- a/include/linux/compat.h
> +++ b/include/linux/compat.h
> @@ -13,6 +13,7 @@
>  #include <linux/socket.h>
>  #include <linux/if.h>
>  #include <linux/fs.h>
> +#include <linux/aio_abi.h>	/* for aio_context_t */
>  
>  #include <asm/compat.h>
>  #include <asm/siginfo.h>

Stephen, thanks for the discovery and the fix.  Apparently the uses in the
"tile" tree already happen to have this header included earlier, so I
didn't trip up against it.  I'll take the change into my tree.

-- 
Chris Metcalf, Tilera Corp.
http://www.tilera.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2011-05-24 12:25 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-07  4:01 linux-next: build failure after merge of the final tree (tile tree related) Stephen Rothwell
2010-06-07 12:48 ` [PATCH] Revert adding some arch-specific signal syscalls to <linux/syscalls.h> Chris Metcalf
2010-06-07 13:18   ` Arnd Bergmann
2010-06-07 12:56 ` linux-next: build failure after merge of the final tree (tile tree related) Chris Metcalf
  -- strict thread matches above, loose matches on Subject: below --
2011-05-24  3:42 Stephen Rothwell
2011-05-24 12:25 ` Chris Metcalf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).