summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpi_memhotplug.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-07-03 21:32:50 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-07-03 21:32:50 -0700
commite82ca04387dd6c98722f5f48235089839fd04268 (patch)
tree8fb4b0435e57c7dab70dfd4cc71b4cd35686126d /drivers/acpi/acpi_memhotplug.c
parent075395d228641646159dae3dd170fa3fc6ff477a (diff)
parent309b0f125a22ee34c8f6962677255f7bf6af5e3d (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: (44 commits) ACPI: remove function tracing macros from drivers/acpi/*.c ACPI: add support for Smart Battery ACPI: handle battery notify event on broken BIOS ACPI: handle AC notify event on broken BIOS ACPI: asus_acpi: add S1N WLED control ACPI: asus_acpi: correct M6N/M6R display nodes ACPI: asus_acpi: add S1N WLED control ACPI: asus_acpi: rework model detection ACPI: asus_acpi: support L5D ACPI: asus_acpi: handle internal Bluetooth / support W5A ACPI: asus_acpi: support A4G ACPI: asus_acpi: support W3400N ACPI: asus_acpi: LED display support ACPI: asus_acpi: support A3G ACPI: asus_acpi: misc cleanups ACPI: video: Remove unneeded acpi_handle from driver. ACPI: thermal: Remove unneeded acpi_handle from driver. ACPI: power: Remove unneeded acpi_handle from driver. ACPI: pci_root: Remove unneeded acpi_handle from driver. ACPI: pci_link: Remove unneeded acpi_handle from driver. ...
Diffstat (limited to 'drivers/acpi/acpi_memhotplug.c')
-rw-r--r--drivers/acpi/acpi_memhotplug.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/acpi/acpi_memhotplug.c b/drivers/acpi/acpi_memhotplug.c
index cd57372a672..81e970adeab 100644
--- a/drivers/acpi/acpi_memhotplug.c
+++ b/drivers/acpi/acpi_memhotplug.c
@@ -80,7 +80,7 @@ struct acpi_memory_info {
};
struct acpi_memory_device {
- acpi_handle handle;
+ struct acpi_device * device;
unsigned int state; /* State of the memory device */
struct list_head res_list;
};
@@ -129,7 +129,7 @@ acpi_memory_get_device_resources(struct acpi_memory_device *mem_device)
struct acpi_memory_info *info, *n;
- status = acpi_walk_resources(mem_device->handle, METHOD_NAME__CRS,
+ status = acpi_walk_resources(mem_device->device->handle, METHOD_NAME__CRS,
acpi_memory_get_resource, mem_device);
if (ACPI_FAILURE(status)) {
list_for_each_entry_safe(info, n, &mem_device->res_list, list)
@@ -192,7 +192,7 @@ static int acpi_memory_check_device(struct acpi_memory_device *mem_device)
/* Get device present/absent information from the _STA */
- if (ACPI_FAILURE(acpi_evaluate_integer(mem_device->handle, "_STA",
+ if (ACPI_FAILURE(acpi_evaluate_integer(mem_device->device->handle, "_STA",
NULL, &current_status)))
return -ENODEV;
/*
@@ -222,7 +222,7 @@ static int acpi_memory_enable_device(struct acpi_memory_device *mem_device)
return result;
}
- node = acpi_get_node(mem_device->handle);
+ node = acpi_get_node(mem_device->device->handle);
/*
* Tell the VM there is more memory here...
* Note: Assume that this function returns zero on success
@@ -269,7 +269,7 @@ static int acpi_memory_powerdown_device(struct acpi_memory_device *mem_device)
arg_list.pointer = &arg;
arg.type = ACPI_TYPE_INTEGER;
arg.integer.value = 1;
- status = acpi_evaluate_object(mem_device->handle,
+ status = acpi_evaluate_object(mem_device->device->handle,
"_EJ0", &arg_list, NULL);
/* Return on _EJ0 failure */
if (ACPI_FAILURE(status)) {
@@ -278,7 +278,7 @@ static int acpi_memory_powerdown_device(struct acpi_memory_device *mem_device)
}
/* Evalute _STA to check if the device is disabled */
- status = acpi_evaluate_integer(mem_device->handle, "_STA",
+ status = acpi_evaluate_integer(mem_device->device->handle, "_STA",
NULL, &current_status);
if (ACPI_FAILURE(status))
return -ENODEV;
@@ -398,7 +398,7 @@ static int acpi_memory_device_add(struct acpi_device *device)
memset(mem_device, 0, sizeof(struct acpi_memory_device));
INIT_LIST_HEAD(&mem_device->res_list);
- mem_device->handle = device->handle;
+ mem_device->device = device;
sprintf(acpi_device_name(device), "%s", ACPI_MEMORY_DEVICE_NAME);
sprintf(acpi_device_class(device), "%s", ACPI_MEMORY_DEVICE_CLASS);
acpi_driver_data(device) = mem_device;
@@ -466,7 +466,7 @@ static acpi_status is_memory_device(acpi_handle handle)
info = buffer.pointer;
if (!(info->valid & ACPI_VALID_HID)) {
- acpi_os_free(buffer.pointer);
+ kfree(buffer.pointer);
return AE_ERROR;
}
@@ -475,7 +475,7 @@ static acpi_status is_memory_device(acpi_handle handle)
(strcmp(hardware_id, ACPI_MEMORY_DEVICE_HID)))
status = AE_ERROR;
- acpi_os_free(buffer.pointer);
+ kfree(buffer.pointer);
return status;
}