ACPI / boot: Don't define unused variables
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 18 Jul 2017 15:04:16 +0000 (18:04 +0300)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 24 Jul 2017 20:47:56 +0000 (22:47 +0200)
commit861a6ee8142efbe80b3891fdfb09f74d726c9809
tree59620021e8e0069a0a6df2b2d2ce4b123d14d6f3
parent520eccdfe187591a51ea9ab4c1a024ae4d0f68d9
ACPI / boot: Don't define unused variables

Some code in acpi_parse_x2apic() conditionally compiled, though parts of
it are being used in any case. This annoys gcc.

arch/x86/kernel/acpi/boot.c: In function ‘acpi_parse_x2apic’:
arch/x86/kernel/acpi/boot.c:203:5: warning: variable ‘enabled’ set but not used [-Wunused-but-set-variable]
  u8 enabled;
     ^~~~~~~
arch/x86/kernel/acpi/boot.c:202:6: warning: variable ‘apic_id’ set but not used [-Wunused-but-set-variable]
  int apic_id;
      ^~~~~~~

Re-arrange the code to avoid compiling unused variables.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
arch/x86/kernel/acpi/boot.c