]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/acpi/power.c
ARM: OMAP3: mmc-twl4030 add cover switch
[linux-2.6-omap-h63xx.git] / drivers / acpi / power.c
index bb7d50dd28186d3c1d7e5d3d1bdb735aeab1944c..c926e7d4a0d619fd5b16a3b8d4806b05bba5aeeb 100644 (file)
@@ -139,6 +139,8 @@ static int acpi_power_get_state(acpi_handle handle, int *state)
 {
        acpi_status status = AE_OK;
        unsigned long long sta = 0;
+       char node_name[5];
+       struct acpi_buffer buffer = { sizeof(node_name), node_name };
 
 
        if (!handle || !state)
@@ -151,8 +153,10 @@ static int acpi_power_get_state(acpi_handle handle, int *state)
        *state = (sta & 0x01)?ACPI_POWER_RESOURCE_STATE_ON:
                              ACPI_POWER_RESOURCE_STATE_OFF;
 
+       acpi_get_name(handle, ACPI_SINGLE_NAME, &buffer);
+
        ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Resource [%s] is %s\n",
-                         acpi_ut_get_node_name(handle),
+                         node_name,
                                *state ? "on" : "off"));
 
        return 0;