X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=drivers%2Facpi%2Fbutton.c;h=2e79a3395ecffca8641cc02e64b616ef88be5ba6;hb=121964ec38d3e17b5ea6183b3c0571df2f4b0eb6;hp=cb4110b50cd0f19f15b0f6c6d124861bd62a82ef;hpb=6606e17a7f1c3bc1b1e83d0c517f11d094e55bf1;p=linux-2.6-omap-h63xx.git diff --git a/drivers/acpi/button.c b/drivers/acpi/button.c index cb4110b50cd..2e79a3395ec 100644 --- a/drivers/acpi/button.c +++ b/drivers/acpi/button.c @@ -66,6 +66,16 @@ MODULE_AUTHOR("Paul Diefenbaugh"); MODULE_DESCRIPTION("ACPI Button Driver"); MODULE_LICENSE("GPL"); +static const struct acpi_device_id button_device_ids[] = { + {ACPI_BUTTON_HID_LID, 0}, + {ACPI_BUTTON_HID_SLEEP, 0}, + {ACPI_BUTTON_HID_SLEEPF, 0}, + {ACPI_BUTTON_HID_POWER, 0}, + {ACPI_BUTTON_HID_POWERF, 0}, + {"", 0}, +}; +MODULE_DEVICE_TABLE(acpi, button_device_ids); + static int acpi_button_add(struct acpi_device *device); static int acpi_button_remove(struct acpi_device *device, int type); static int acpi_button_info_open_fs(struct inode *inode, struct file *file); @@ -74,7 +84,7 @@ static int acpi_button_state_open_fs(struct inode *inode, struct file *file); static struct acpi_driver acpi_button_driver = { .name = "button", .class = ACPI_BUTTON_CLASS, - .ids = "button_power,button_sleep,PNP0C0D,PNP0C0C,PNP0C0E", + .ids = button_device_ids, .ops = { .add = acpi_button_add, .remove = acpi_button_remove, @@ -274,7 +284,7 @@ static void acpi_button_notify(acpi_handle handle, u32 event, void *data) } input_sync(input); - acpi_bus_generate_event(button->device, event, + acpi_bus_generate_proc_event(button->device, event, ++button->pushed); break; default: