mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH -next] unicore32: Fix build error
@ 2016-10-18  7:24 Guenter Roeck
  2016-10-18 13:51 ` Guenter Roeck
  2016-10-26  2:30 ` Xuetao Guan
  0 siblings, 2 replies; 3+ messages in thread
From: Guenter Roeck @ 2016-10-18  7:24 UTC (permalink / raw)
  To: Guan Xuetao; +Cc: Qin Rui, linux-kernel, Guenter Roeck

Since the oldabi syscall interface was first introduced, the infrastructure
changed and the patch no longer compiles. See commit f56141e3e2d9a ("all
arches, signal: move restart_block to struct task_struct") for details.

Fixes: 1ace5d1e3d4b4 ("unicore32-oldabi: add oldabi syscall interface")
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
Should be merged with the commit introducing the problem if possible.

 arch/unicore32/kernel/signal.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/unicore32/kernel/signal.c b/arch/unicore32/kernel/signal.c
index 78a66491b108..be75ef8c1e0c 100644
--- a/arch/unicore32/kernel/signal.c
+++ b/arch/unicore32/kernel/signal.c
@@ -115,7 +115,7 @@ asmlinkage int __sys_sigreturn(struct pt_regs *regs)
 	struct sigframe __user *frame;
 
 	/* Always make any pending restarted system calls return -EINTR */
-	current_thread_info()->restart_block.fn = do_no_restart_syscall;
+	current->restart_block.fn = do_no_restart_syscall;
 
 	/*
 	 * Since we stacked the signal on a 64-bit boundary,
-- 
2.5.0

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

* Re: [PATCH -next] unicore32: Fix build error
  2016-10-18  7:24 [PATCH -next] unicore32: Fix build error Guenter Roeck
@ 2016-10-18 13:51 ` Guenter Roeck
  2016-10-26  2:30 ` Xuetao Guan
  1 sibling, 0 replies; 3+ messages in thread
From: Guenter Roeck @ 2016-10-18 13:51 UTC (permalink / raw)
  To: Guan Xuetao; +Cc: Qin Rui, linux-kernel

On 10/18/2016 12:24 AM, Guenter Roeck wrote:
> Since the oldabi syscall interface was first introduced, the infrastructure
> changed and the patch no longer compiles. See commit f56141e3e2d9a ("all
> arches, signal: move restart_block to struct task_struct") for details.
>
> Fixes: 1ace5d1e3d4b4 ("unicore32-oldabi: add oldabi syscall interface")
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> ---
> Should be merged with the commit introducing the problem if possible.
>

Additional comment: Even with this patch applied, the image does not boot with
qemu in -next. Here is a partial log:

...
Memory: 441012K/524288K available (1923K kernel code, 76K rwdata, 312K rodata, 2212K init, 175K bss, 83276K reserved, 0K cma-reserved)^M
Virtual kernel memory layout:^M
     vector  : 0xffff0000 - 0xffff1000   (   4 kB)^M
     vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)^M
     lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)^M
     modules : 0xbf000000 - 0xc0000000   (  16 MB)^M
       .init : 0xc0408000 - 0xc0631000   (2212 kB)^M
       .text : 0xc0631000 - 0xc0811e20   (1924 kB)^M
       .data : 0xc0811e20 - 0xc0873160   ( 389 kB)^M
------------[ cut here ]------------^M
WARNING: CPU: 0 PID: 0 at mm/percpu.c:996 pcpu_alloc+0x528/0x5d4^M

The code then loops forever repeating this warning and the associated traceback.

Guenter

>  arch/unicore32/kernel/signal.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/unicore32/kernel/signal.c b/arch/unicore32/kernel/signal.c
> index 78a66491b108..be75ef8c1e0c 100644
> --- a/arch/unicore32/kernel/signal.c
> +++ b/arch/unicore32/kernel/signal.c
> @@ -115,7 +115,7 @@ asmlinkage int __sys_sigreturn(struct pt_regs *regs)
>  	struct sigframe __user *frame;
>
>  	/* Always make any pending restarted system calls return -EINTR */
> -	current_thread_info()->restart_block.fn = do_no_restart_syscall;
> +	current->restart_block.fn = do_no_restart_syscall;
>
>  	/*
>  	 * Since we stacked the signal on a 64-bit boundary,
>

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

* Re: [PATCH -next] unicore32: Fix build error
  2016-10-18  7:24 [PATCH -next] unicore32: Fix build error Guenter Roeck
  2016-10-18 13:51 ` Guenter Roeck
@ 2016-10-26  2:30 ` Xuetao Guan
  1 sibling, 0 replies; 3+ messages in thread
From: Xuetao Guan @ 2016-10-26  2:30 UTC (permalink / raw)
  To: Guenter Roeck; +Cc: Guan Xuetao, Qin Rui, linux-kernel, Guenter Roeck

> Since the oldabi syscall interface was first introduced, the
> infrastructure
> changed and the patch no longer compiles. See commit f56141e3e2d9a ("all
> arches, signal: move restart_block to struct task_struct") for details.
>
> Fixes: 1ace5d1e3d4b4 ("unicore32-oldabi: add oldabi syscall interface")
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>

Sorry, I missed your patch when sent patch-v2 for oldabi.
And so, I directly modified the codes in patch-v2.
I'll add your comment and Sob for patch-v2.
Thanks, Guenter.

Xuetao

> ---
> Should be merged with the commit introducing the problem if possible.
>
>  arch/unicore32/kernel/signal.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/unicore32/kernel/signal.c
> b/arch/unicore32/kernel/signal.c
> index 78a66491b108..be75ef8c1e0c 100644
> --- a/arch/unicore32/kernel/signal.c
> +++ b/arch/unicore32/kernel/signal.c
> @@ -115,7 +115,7 @@ asmlinkage int __sys_sigreturn(struct pt_regs *regs)
>  	struct sigframe __user *frame;
>
>  	/* Always make any pending restarted system calls return -EINTR */
> -	current_thread_info()->restart_block.fn = do_no_restart_syscall;
> +	current->restart_block.fn = do_no_restart_syscall;
>
>  	/*
>  	 * Since we stacked the signal on a 64-bit boundary,
> --
> 2.5.0
>

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

end of thread, other threads:[~2016-10-26  2:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-10-18  7:24 [PATCH -next] unicore32: Fix build error Guenter Roeck
2016-10-18 13:51 ` Guenter Roeck
2016-10-26  2:30 ` Xuetao Guan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome