提交 a5ca7345 编写于 作者: R Rafael J. Wysocki 提交者: Len Brown

ACPI / PM: Fix build warning in sleep.c for CONFIG_ACPI_SLEEP unset

If CONFIG_ACPI_SLEEP is unset, the compiler complains that
pwr_btn_event_pending is defined but not used.  To silence the
warning, move the definition of pwr_btn_event_pending under an
appropriate #ifdef.
Reported-by: NPaul E. McKenney <paul.mckenney@linaro.org>
Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
Tested-by: NPaul E. McKenney <paul.mckenney@linaro.org>
Signed-off-by: NLen Brown <len.brown@intel.com>
上级 28a33cbc
...@@ -57,7 +57,6 @@ MODULE_PARM_DESC(gts, "Enable evaluation of _GTS on suspend."); ...@@ -57,7 +57,6 @@ MODULE_PARM_DESC(gts, "Enable evaluation of _GTS on suspend.");
MODULE_PARM_DESC(bfs, "Enable evaluation of _BFS on resume".); MODULE_PARM_DESC(bfs, "Enable evaluation of _BFS on resume".);
static u8 sleep_states[ACPI_S_STATE_COUNT]; static u8 sleep_states[ACPI_S_STATE_COUNT];
static bool pwr_btn_event_pending;
static void acpi_sleep_tts_switch(u32 acpi_state) static void acpi_sleep_tts_switch(u32 acpi_state)
{ {
...@@ -110,6 +109,7 @@ static int acpi_sleep_prepare(u32 acpi_state) ...@@ -110,6 +109,7 @@ static int acpi_sleep_prepare(u32 acpi_state)
#ifdef CONFIG_ACPI_SLEEP #ifdef CONFIG_ACPI_SLEEP
static u32 acpi_target_sleep_state = ACPI_STATE_S0; static u32 acpi_target_sleep_state = ACPI_STATE_S0;
static bool pwr_btn_event_pending;
/* /*
* The ACPI specification wants us to save NVS memory regions during hibernation * The ACPI specification wants us to save NVS memory regions during hibernation
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册