aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/acpiphp_ibm.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-09-23 12:32:11 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-23 12:32:11 -0400
commitc11f6c82581e8be4e1829c677db54e7f55cebece (patch)
tree1a116241b0831ded998aabe800bdc24104cbd826 /drivers/pci/hotplug/acpiphp_ibm.c
parent40aba218969914d1b225e742617adb921cf94eae (diff)
parent193a6dec1c0246a80b6d0101e4f351ccf877bcac (diff)
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (119 commits) ACPI: don't pass handle for fixed hardware notifications ACPI: remove null pointer checks in deferred execution path ACPI: simplify deferred execution path acerhdf: additional BIOS versions acerhdf: convert to dev_pm_ops acerhdf: fix fan control for AOA150 model thermal: add missing Kconfig dependency acpi: switch /proc/acpi/{debug_layer,debug_level} to seq_file hp-wmi: fix rfkill memory leak on unload ACPI: remove unnecessary #ifdef CONFIG_DMI ACPI: linux/acpi.h should not include linux/dmi.h hwmon driver for ACPI 4.0 power meters topstar-laptop: add new driver for hotkeys support on Topstar N01 thinkpad_acpi: fix rfkill memory leak on unload thinkpad-acpi: report brightness events when required thinkpad-acpi: don't poll by default any of the reserved hotkeys thinkpad-acpi: Fix procfs hotkey reset command thinkpad-acpi: deprecate hotkey_bios_mask thinkpad-acpi: hotkey poll fixes thinkpad-acpi: be more strict when detecting a ThinkPad ...
Diffstat (limited to 'drivers/pci/hotplug/acpiphp_ibm.c')
-rw-r--r--drivers/pci/hotplug/acpiphp_ibm.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/drivers/pci/hotplug/acpiphp_ibm.c b/drivers/pci/hotplug/acpiphp_ibm.c
index 5befa7e379b7..a9d926b7d805 100644
--- a/drivers/pci/hotplug/acpiphp_ibm.c
+++ b/drivers/pci/hotplug/acpiphp_ibm.c
@@ -398,23 +398,21 @@ static acpi_status __init ibm_find_acpi_device(acpi_handle handle,
398 acpi_handle *phandle = (acpi_handle *)context; 398 acpi_handle *phandle = (acpi_handle *)context;
399 acpi_status status; 399 acpi_status status;
400 struct acpi_device_info *info; 400 struct acpi_device_info *info;
401 struct acpi_buffer info_buffer = { ACPI_ALLOCATE_BUFFER, NULL };
402 int retval = 0; 401 int retval = 0;
403 402
404 status = acpi_get_object_info(handle, &info_buffer); 403 status = acpi_get_object_info(handle, &info);
405 if (ACPI_FAILURE(status)) { 404 if (ACPI_FAILURE(status)) {
406 err("%s: Failed to get device information status=0x%x\n", 405 err("%s: Failed to get device information status=0x%x\n",
407 __func__, status); 406 __func__, status);
408 return retval; 407 return retval;
409 } 408 }
410 info = info_buffer.pointer; 409 info->hardware_id.string[sizeof(info->hardware_id.length) - 1] = '\0';
411 info->hardware_id.value[sizeof(info->hardware_id.value) - 1] = '\0';
412 410
413 if (info->current_status && (info->valid & ACPI_VALID_HID) && 411 if (info->current_status && (info->valid & ACPI_VALID_HID) &&
414 (!strcmp(info->hardware_id.value, IBM_HARDWARE_ID1) || 412 (!strcmp(info->hardware_id.string, IBM_HARDWARE_ID1) ||
415 !strcmp(info->hardware_id.value, IBM_HARDWARE_ID2))) { 413 !strcmp(info->hardware_id.string, IBM_HARDWARE_ID2))) {
416 dbg("found hardware: %s, handle: %p\n", 414 dbg("found hardware: %s, handle: %p\n",
417 info->hardware_id.value, handle); 415 info->hardware_id.string, handle);
418 *phandle = handle; 416 *phandle = handle;
419 /* returning non-zero causes the search to stop 417 /* returning non-zero causes the search to stop
420 * and returns this value to the caller of 418 * and returns this value to the caller of