Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1188208
| From | Catalin Marinas <catalin.marinas@arm.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] sched, arm64: Fix the fallout of increasing the offset of 'thread_struct' within 'task_struct' |
| Date | 2015-07-20 16:10 +0200 |
| Message-ID | <pOjVw-3qK-15@gated-at.bofh.it> (permalink) |
| References | <pNJIl-1XU-3@gated-at.bofh.it> <pNJS2-28W-3@gated-at.bofh.it> <pOdGq-2OY-17@gated-at.bofh.it> <pOjLQ-30h-19@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Mon, Jul 20, 2015 at 06:52:28AM -0700, Guenter Roeck wrote:
> On 07/20/2015 12:20 AM, Ingo Molnar wrote:
> >* Guenter <linux@roeck-us.net> wrote:
> >>On Sat, Jul 18, 2015 at 04:27:17PM -0700, Guenter wrote:
> >>>Commit 0c8c0f03e3a2 ("x86/fpu, sched: Dynamically allocate 'struct fpu'")
> >>>causes s390 builds in mainline to fail as follows.
> >>>
> >>>arch/s390/kernel/traps.c: Assembler messages:
> >>>arch/s390/kernel/traps.c:262: Error: operand out of range
> >>> (0x00000000000023e8 is not between 0x0000000000000000 and 0x0000000000000fff)
> >>>arch/s390/kernel/traps.c:300: Error: operand out of range
> >>> (0x00000000000023e8 is not between 0x0000000000000000 and 0x0000000000000fff)
> >>>
> >>
> >>Also:
> >>
> >>arm64:allmodconfig:
> >>
> >>arch/arm64/kernel/entry.S: Assembler messages:
> >>arch/arm64/kernel/entry.S:588: Error: immediate out of range
> >>arch/arm64/kernel/entry.S:597: Error: immediate out of range
> >>make[1]: *** [arch/arm64/kernel/entry.o] Error 1
> >>
> >>I didn't bisect that one, but it looks like the cause is the same.
> >
> >Hm, it looks like the new, increased offset of 'thread_struct' within
> >'task_struct' goes over a limit that these instructions are able to support on
> >arm64:
> >
> > arch/arm64/kernel/asm-offsets.c: DEFINE(THREAD_CPU_CONTEXT, offsetof(struct task_struct, thread.cpu_context));
> > arch/arm64/kernel/entry.S: add x8, x0, #THREAD_CPU_CONTEXT
> > arch/arm64/kernel/entry.S: add x8, x1, #THREAD_CPU_CONTEXT
> >
> >If there's no instruction that can support such offset sizes then I suspect the
> >straightforward fix would be to pass in thread_struct instead - like the patch
> >below. That's a tiny bit cleaner for type encapsulation anyway.
>
> Olof submitted a different patch to solve the problem:
> http://www.spinics.net/lists/kernel/msg2036825.html
>
> His patch is passing cpu_context instead of thread_context.
It's likely that we'll use this patch instead:
http://lkml.kernel.org/g/20150720105345.GC9908@arm.com
--
Catalin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: [PATCH] sched, arm64: Fix the fallout of increasing the offset of 'thread_struct' within 'task_struct' Guenter Roeck <linux@roeck-us.net> - 2015-07-20 16:00 +0200 Re: [PATCH] sched, arm64: Fix the fallout of increasing the offset of 'thread_struct' within 'task_struct' Catalin Marinas <catalin.marinas@arm.com> - 2015-07-20 16:10 +0200
csiph-web