]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/misc/asus-laptop.c
ACPI: catch calls of acpi_driver_data on pointer of wrong type
[linux-2.6-omap-h63xx.git] / drivers / misc / asus-laptop.c
index 34666ff60d372cf2d95c53c96f097a4e076fe2f7..de82f2f5a813ed9622855125012f439fd076827a 100644 (file)
@@ -239,7 +239,7 @@ static struct workqueue_struct *led_workqueue;
        static int object##_led_wk;                                     \
        static DECLARE_WORK(object##_led_work, object##_led_update);    \
        static struct led_classdev object##_led = {                     \
-               .name           = "asus:" ledname,                      \
+               .name           = "asus::" ledname,                     \
                .brightness_set = object##_led_set,                     \
        }
 
@@ -327,7 +327,7 @@ static void write_status(acpi_handle handle, int out, int mask)
 
        switch (mask) {
        case MLED_ON:
-               out = !out & 0x1;
+               out = !(out & 0x1);
                break;
        case GLED_ON:
                out = (out & 0x1) + 1;
@@ -996,7 +996,7 @@ static int asus_hotk_add(struct acpi_device *device)
        hotk->handle = device->handle;
        strcpy(acpi_device_name(device), ASUS_HOTK_DEVICE_NAME);
        strcpy(acpi_device_class(device), ASUS_HOTK_CLASS);
-       acpi_driver_data(device) = hotk;
+       device->driver_data = hotk;
        hotk->device = device;
 
        result = asus_hotk_check();