diff options
author | Thomas Gleixner <tglx@tglx.tec.linutronix.de> | 2005-07-13 04:45:00 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@mtd.linutronix.de> | 2005-07-13 04:45:00 -0400 |
commit | 1b3035b7fcc72b6b36f2a3634dad832eb2453ce8 (patch) | |
tree | 728174d72943cc9b981a5843553551df62eddc41 /drivers/acpi/toshiba_acpi.c | |
parent | a98a5d04f400ad112e59cadd739dbabf89417e60 (diff) | |
parent | c32511e2718618f0b53479eb36e07439aa363a74 (diff) |
Merge with rsync://fileserver/linux
Diffstat (limited to 'drivers/acpi/toshiba_acpi.c')
-rw-r--r-- | drivers/acpi/toshiba_acpi.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/acpi/toshiba_acpi.c b/drivers/acpi/toshiba_acpi.c index c84997c9f964..73b1d8aeae9d 100644 --- a/drivers/acpi/toshiba_acpi.c +++ b/drivers/acpi/toshiba_acpi.c | |||
@@ -263,6 +263,9 @@ dispatch_write(struct file* file, const char __user * buffer, | |||
263 | * destination so that sscanf can be used on it safely. | 263 | * destination so that sscanf can be used on it safely. |
264 | */ | 264 | */ |
265 | tmp_buffer = kmalloc(count + 1, GFP_KERNEL); | 265 | tmp_buffer = kmalloc(count + 1, GFP_KERNEL); |
266 | if(!tmp_buffer) | ||
267 | return -ENOMEM; | ||
268 | |||
266 | if (copy_from_user(tmp_buffer, buffer, count)) { | 269 | if (copy_from_user(tmp_buffer, buffer, count)) { |
267 | result = -EFAULT; | 270 | result = -EFAULT; |
268 | } | 271 | } |
@@ -529,6 +532,11 @@ toshiba_acpi_init(void) | |||
529 | 532 | ||
530 | if (acpi_disabled) | 533 | if (acpi_disabled) |
531 | return -ENODEV; | 534 | return -ENODEV; |
535 | |||
536 | if (!acpi_specific_hotkey_enabled){ | ||
537 | printk(MY_INFO "Using generic hotkey driver\n"); | ||
538 | return -ENODEV; | ||
539 | } | ||
532 | /* simple device detection: look for HCI method */ | 540 | /* simple device detection: look for HCI method */ |
533 | if (is_valid_acpi_path(METHOD_HCI_1)) | 541 | if (is_valid_acpi_path(METHOD_HCI_1)) |
534 | method_hci = METHOD_HCI_1; | 542 | method_hci = METHOD_HCI_1; |