Commit 1c194626 authored by Michał Kępień's avatar Michał Kępień Committed by Darren Hart (VMware)

platform/x86: fujitsu-laptop: do not update ACPI device power status

Calling acpi_bus_update_power() for ACPI devices FUJ02B1 and FUJ02E3 is
pointless as they are not power manageable (neither _PS0 nor _PR0 is
defined for any of them), which causes their power state to be inherited
from their parent devices.  Given the ACPI paths of these two devices
(\_SB.PCI0.LPCB.FJEX, \_SB.FEXT), their parent devices are also not
power manageable.  These parent devices will thus have their power state
initialized to ACPI_STATE_D0, which in turn causes the power state for
both FUJ02B1 and FUJ02E3 to always be ACPI_STATE_D0 ("on").

Remove relevant acpi_bus_update_power() calls along with parts of debug
messages that they were supposed to have an effect on.
Signed-off-by: default avatarMichał Kępień <kernel@kempniu.pl>
Reviewed-by: default avatarJonathan Woithe <jwoithe@just42.net>
Signed-off-by: default avatarDarren Hart (VMware) <dvhart@infradead.org>
parent c1f51f1c
...@@ -402,7 +402,6 @@ static int fujitsu_backlight_register(struct acpi_device *device) ...@@ -402,7 +402,6 @@ static int fujitsu_backlight_register(struct acpi_device *device)
static int acpi_fujitsu_bl_add(struct acpi_device *device) static int acpi_fujitsu_bl_add(struct acpi_device *device)
{ {
struct fujitsu_bl *priv; struct fujitsu_bl *priv;
int state = 0;
int error; int error;
if (acpi_video_get_backlight_type() != acpi_backlight_vendor) if (acpi_video_get_backlight_type() != acpi_backlight_vendor)
...@@ -421,15 +420,8 @@ static int acpi_fujitsu_bl_add(struct acpi_device *device) ...@@ -421,15 +420,8 @@ static int acpi_fujitsu_bl_add(struct acpi_device *device)
if (error) if (error)
return error; return error;
error = acpi_bus_update_power(device->handle, &state); pr_info("ACPI: %s [%s]\n",
if (error) { acpi_device_name(device), acpi_device_bid(device));
pr_err("Error reading power state\n");
return error;
}
pr_info("ACPI: %s [%s] (%s)\n",
acpi_device_name(device), acpi_device_bid(device),
!device->power.state ? "on" : "off");
if (acpi_has_method(device->handle, METHOD_NAME__INI)) { if (acpi_has_method(device->handle, METHOD_NAME__INI)) {
vdbg_printk(FUJLAPTOP_DBG_INFO, "Invoking _INI\n"); vdbg_printk(FUJLAPTOP_DBG_INFO, "Invoking _INI\n");
...@@ -790,7 +782,6 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device) ...@@ -790,7 +782,6 @@ static int acpi_fujitsu_laptop_leds_register(struct acpi_device *device)
static int acpi_fujitsu_laptop_add(struct acpi_device *device) static int acpi_fujitsu_laptop_add(struct acpi_device *device)
{ {
struct fujitsu_laptop *priv; struct fujitsu_laptop *priv;
int state = 0;
int error; int error;
int i; int i;
...@@ -818,15 +809,8 @@ static int acpi_fujitsu_laptop_add(struct acpi_device *device) ...@@ -818,15 +809,8 @@ static int acpi_fujitsu_laptop_add(struct acpi_device *device)
if (error) if (error)
goto err_free_fifo; goto err_free_fifo;
error = acpi_bus_update_power(device->handle, &state); pr_info("ACPI: %s [%s]\n",
if (error) { acpi_device_name(device), acpi_device_bid(device));
pr_err("Error reading power state\n");
goto err_free_fifo;
}
pr_info("ACPI: %s [%s] (%s)\n",
acpi_device_name(device), acpi_device_bid(device),
!device->power.state ? "on" : "off");
if (acpi_has_method(device->handle, METHOD_NAME__INI)) { if (acpi_has_method(device->handle, METHOD_NAME__INI)) {
vdbg_printk(FUJLAPTOP_DBG_INFO, "Invoking _INI\n"); vdbg_printk(FUJLAPTOP_DBG_INFO, "Invoking _INI\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment