diff options
author | Zhang Rui <rui.zhang@intel.com> | 2013-09-03 08:31:49 +0800 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-09-24 01:37:53 +0200 |
commit | b408a054931cdd1274f72fbeb297e3e3c7ce85f8 (patch) | |
tree | 4c06815cae0722b42dc3ffe0dfa31960d59f2c65 | |
parent | 4a10c2ac2f368583138b774ca41fac4207911983 (diff) |
olpc_xo15_sci: convert acpi_evaluate_object() to acpi_execute_simple_method()
acpi_execute_simple_method() is a new ACPI API introduced to invoke
an ACPI control method that has single integer parameter and no return value.
Convert acpi_evaluate_object() to acpi_execute_simple_method()
in arch/x86/platform/olpc/olpc-xo15-sci.c
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
CC: Daniel Drake <dsd@laptop.org>
CC: H. Peter Anvin <hpa@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
-rw-r--r-- | arch/x86/platform/olpc/olpc-xo15-sci.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/arch/x86/platform/olpc/olpc-xo15-sci.c b/arch/x86/platform/olpc/olpc-xo15-sci.c index fef7d0ba7e3..649a12befba 100644 --- a/arch/x86/platform/olpc/olpc-xo15-sci.c +++ b/arch/x86/platform/olpc/olpc-xo15-sci.c @@ -40,16 +40,9 @@ static bool lid_wake_on_close; */ static int set_lid_wake_behavior(bool wake_on_close) { - struct acpi_object_list arg_list; - union acpi_object arg; acpi_status status; - arg_list.count = 1; - arg_list.pointer = &arg; - arg.type = ACPI_TYPE_INTEGER; - arg.integer.value = wake_on_close; - - status = acpi_evaluate_object(NULL, "\\_SB.PCI0.LID.LIDW", &arg_list, NULL); + status = acpi_execute_simple_method(NULL, "\\_SB.PCI0.LID.LIDW", wake_on_close); if (ACPI_FAILURE(status)) { pr_warning(PFX "failed to set lid behavior\n"); return 1; |