diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2010-12-11 23:45:30 +0100 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2011-01-12 04:48:45 -0500 |
commit | 53eac700b0df1fef8c957b9eedfd7f48120425e3 (patch) | |
tree | 3793c9389b4d9e27936d296a35e54fc8200b6a5c /drivers/acpi/bus.c | |
parent | f6767dcf2a4f6e62960912d0affec1e15a246191 (diff) |
ACPI / PM: Drop acpi_power_nocheck
Since acpi_bus_set_power() should not use __acpi_bus_get_power() to
update the device's device->power.state field before changing its
power state (this may cause device->power.state to be inconsistent
with the device power resources' reference counters), remove this
call from it. In consequence, the acpi_power_nocheck variable is not
necessary any more, so it can be dropped along with the DMI table
used for setting that variable for HP Pavilion 05.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/bus.c')
-rw-r--r-- | drivers/acpi/bus.c | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/drivers/acpi/bus.c b/drivers/acpi/bus.c index 0baa5f97734..7ced61f3949 100644 --- a/drivers/acpi/bus.c +++ b/drivers/acpi/bus.c @@ -52,22 +52,6 @@ EXPORT_SYMBOL(acpi_root_dir); #define STRUCT_TO_INT(s) (*((int*)&s)) -static int set_power_nocheck(const struct dmi_system_id *id) -{ - printk(KERN_NOTICE PREFIX "%s detected - " - "disable power check in power transition\n", id->ident); - acpi_power_nocheck = 1; - return 0; -} -static struct dmi_system_id __cpuinitdata power_nocheck_dmi_table[] = { - { - set_power_nocheck, "HP Pavilion 05", { - DMI_MATCH(DMI_BIOS_VENDOR, "Phoenix Technologies LTD"), - DMI_MATCH(DMI_SYS_VENDOR, "HP Pavilion 05"), - DMI_MATCH(DMI_PRODUCT_VERSION, "2001211RE101GLEND") }, NULL}, - {}, -}; - #ifdef CONFIG_X86 static int set_copy_dsdt(const struct dmi_system_id *id) @@ -333,23 +317,6 @@ int acpi_bus_set_power(acpi_handle handle, int state) return -ENODEV; } - /* - * Get device's current power state - */ - if (!acpi_power_nocheck) { - /* - * Maybe the incorrect power state is returned on the bogus - * bios, which is different with the real power state. - * For example: the bios returns D0 state and the real power - * state is D3. OS expects to set the device to D0 state. In - * such case if OS uses the power state returned by the BIOS, - * the device can't be transisted to the correct power state. - * So if the acpi_power_nocheck is set, it is unnecessary to - * get the power state by calling acpi_bus_get_power. - */ - __acpi_bus_get_power(device, &device->power.state); - } - return __acpi_bus_set_power(device, state); } EXPORT_SYMBOL(acpi_bus_set_power); @@ -1072,12 +1039,6 @@ static int __init acpi_init(void) if (acpi_disabled) return result; - /* - * If the laptop falls into the DMI check table, the power state check - * will be disabled in the course of device power transition. - */ - dmi_check_system(power_nocheck_dmi_table); - acpi_scan_init(); acpi_ec_init(); acpi_debugfs_init(); |