aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/power.c
diff options
context:
space:
mode:
authorLin Ming <ming.m.lin@intel.com>2008-12-16 04:02:22 -0500
committerLen Brown <len.brown@intel.com>2008-12-31 01:11:51 -0500
commit60a4ce7f4148155d3f28eea4a213f7ee47cd57b7 (patch)
tree5eac1cfc5924b8e5676347f9df660d926643f598 /drivers/acpi/power.c
parent30823736162ff91512965e3c730557e34fa71d6d (diff)
ACPI: power.c: call acpi_get_name to get node name
acpi_ut_get_node_name is an internal acpica function. use acpi_get_name to get node ascii name Signed-off-by: Lin Ming <ming.m.lin@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/power.c')
-rw-r--r--drivers/acpi/power.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/acpi/power.c b/drivers/acpi/power.c
index bb7d50dd2818..c926e7d4a0d6 100644
--- a/drivers/acpi/power.c
+++ b/drivers/acpi/power.c
@@ -139,6 +139,8 @@ static int acpi_power_get_state(acpi_handle handle, int *state)
139{ 139{
140 acpi_status status = AE_OK; 140 acpi_status status = AE_OK;
141 unsigned long long sta = 0; 141 unsigned long long sta = 0;
142 char node_name[5];
143 struct acpi_buffer buffer = { sizeof(node_name), node_name };
142 144
143 145
144 if (!handle || !state) 146 if (!handle || !state)
@@ -151,8 +153,10 @@ static int acpi_power_get_state(acpi_handle handle, int *state)
151 *state = (sta & 0x01)?ACPI_POWER_RESOURCE_STATE_ON: 153 *state = (sta & 0x01)?ACPI_POWER_RESOURCE_STATE_ON:
152 ACPI_POWER_RESOURCE_STATE_OFF; 154 ACPI_POWER_RESOURCE_STATE_OFF;
153 155
156 acpi_get_name(handle, ACPI_SINGLE_NAME, &buffer);
157
154 ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Resource [%s] is %s\n", 158 ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Resource [%s] is %s\n",
155 acpi_ut_get_node_name(handle), 159 node_name,
156 *state ? "on" : "off")); 160 *state ? "on" : "off"));
157 161
158 return 0; 162 return 0;