lkml.org 
[lkml]   [2017]   [Nov]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 16/16] x86/entry/64: Move the IST stacks into cpu_entry_area
On Mon, Nov 20, 2017 at 11:38 PM, Ingo Molnar <mingo@kernel.org> wrote:
>
> * Andy Lutomirski <luto@kernel.org> wrote:
>
>> /* May not be marked __init: used by software suspend */
>> void syscall_init(void)
>> {
>> @@ -1627,7 +1637,7 @@ void cpu_init(void)
>> * set up and load the per-CPU TSS
>> */
>> if (!oist->ist[0]) {
>> - char *estacks = per_cpu(exception_stacks, cpu);
>> + char *estacks = get_cpu_entry_area(cpu)->exception_stacks;
>>
>> for (v = 0; v < N_EXCEPTION_STACKS; v++) {
>> estacks += exception_stack_sizes[v];
>
> This generates a new build warning:
>
> /home/mingo/tip/arch/x86/kernel/cpu/common.c: In function ‘syscall_init’:
> /home/mingo/tip/arch/x86/kernel/cpu/common.c:1443:6: warning: unused variable ‘cpu’ [-Wunused-variable]
> int cpu = smp_processor_id();
>
> because 'cpu' is now unused in the !CONFIG_IA32_EMULATION part.
>
> The naive fix is something like the patch below, untested.

I don't think I get this warning (at least not on my latest tree), but
there's an obvious cleanup to the earlier SYSCALL trampoline patch
that makes cpu be definitely used.

\
 
 \ /
  Last update: 2017-11-21 16:34    [W:0.077 / U:16.608 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site