diff options
author | Len Brown <len.brown@intel.com> | 2012-06-04 00:35:19 -0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2012-06-04 00:35:19 -0400 |
commit | 7e1bd6e38b1f30860ce25a014c6d6adfb0079f4a (patch) | |
tree | 65c5898ba93007d4399150c7a127a670bcfbc30d /drivers/acpi | |
parent | 301f33fbcf4ced53b3de114846ecece5d6aafeeb (diff) | |
parent | f8f5701bdaf9134b1f90e5044a82c66324d2073f (diff) |
Merge branch 'upstream' into bugfix-video
Update bugfix-video branch to 2.5-rc1
so I don't have to again resolve the
conflict in these patches vs. upstream.
Conflicts:
drivers/gpu/drm/gma500/psb_drv.c
text conflict: add comment vs delete neighboring line
keep just this:
/* igd_opregion_init(&dev_priv->opregion_dev); */
/* acpi_video_register(); */
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/bgrt.c | 1 | ||||
-rw-r--r-- | drivers/acpi/glue.c | 2 | ||||
-rw-r--r-- | drivers/acpi/pci_link.c | 12 | ||||
-rw-r--r-- | drivers/acpi/sleep.c | 14 | ||||
-rw-r--r-- | drivers/acpi/utils.c | 30 |
5 files changed, 45 insertions, 14 deletions
diff --git a/drivers/acpi/bgrt.c b/drivers/acpi/bgrt.c index 8cf6c46e99f..6680df36b96 100644 --- a/drivers/acpi/bgrt.c +++ b/drivers/acpi/bgrt.c @@ -11,6 +11,7 @@ #include <linux/init.h> #include <linux/device.h> #include <linux/sysfs.h> +#include <linux/io.h> #include <acpi/acpi.h> #include <acpi/acpi_bus.h> diff --git a/drivers/acpi/glue.c b/drivers/acpi/glue.c index 29a4a5c8ee0..1564e0927c2 100644 --- a/drivers/acpi/glue.c +++ b/drivers/acpi/glue.c @@ -69,6 +69,7 @@ static struct acpi_bus_type *acpi_get_bus_type(struct bus_type *type) up_read(&bus_type_sem); return ret; } +EXPORT_SYMBOL_GPL(register_acpi_bus_type); static int acpi_find_bridge_device(struct device *dev, acpi_handle * handle) { @@ -85,6 +86,7 @@ static int acpi_find_bridge_device(struct device *dev, acpi_handle * handle) up_read(&bus_type_sem); return ret; } +EXPORT_SYMBOL_GPL(unregister_acpi_bus_type); /* Get device's handler per its address under its parent */ struct acpi_find_child { diff --git a/drivers/acpi/pci_link.c b/drivers/acpi/pci_link.c index 4a29763b8eb..a12808259df 100644 --- a/drivers/acpi/pci_link.c +++ b/drivers/acpi/pci_link.c @@ -720,21 +720,21 @@ static int acpi_pci_link_add(struct acpi_device *device) acpi_device_bid(device)); for (i = 0; i < link->irq.possible_count; i++) { if (link->irq.active == link->irq.possible[i]) { - printk(" *%d", link->irq.possible[i]); + printk(KERN_CONT " *%d", link->irq.possible[i]); found = 1; } else - printk(" %d", link->irq.possible[i]); + printk(KERN_CONT " %d", link->irq.possible[i]); } - printk(")"); + printk(KERN_CONT ")"); if (!found) - printk(" *%d", link->irq.active); + printk(KERN_CONT " *%d", link->irq.active); if (!link->device->status.enabled) - printk(", disabled."); + printk(KERN_CONT ", disabled."); - printk("\n"); + printk(KERN_CONT "\n"); list_add_tail(&link->list, &acpi_link_list); diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c index eb6fd233764..74ee4ab577b 100644 --- a/drivers/acpi/sleep.c +++ b/drivers/acpi/sleep.c @@ -93,11 +93,9 @@ static int acpi_sleep_prepare(u32 acpi_state) #ifdef CONFIG_ACPI_SLEEP /* do we have a wakeup address for S2 and S3? */ if (acpi_state == ACPI_STATE_S3) { - if (!acpi_wakeup_address) { + if (!acpi_wakeup_address) return -EFAULT; - } - acpi_set_firmware_waking_vector( - (acpi_physical_address)acpi_wakeup_address); + acpi_set_firmware_waking_vector(acpi_wakeup_address); } ACPI_FLUSH_CPU_CACHE(); @@ -887,7 +885,7 @@ int __init acpi_sleep_init(void) status = acpi_get_sleep_type_data(i, &type_a, &type_b); if (ACPI_SUCCESS(status)) { sleep_states[i] = 1; - printk(" S%d", i); + printk(KERN_CONT " S%d", i); } } @@ -901,7 +899,7 @@ int __init acpi_sleep_init(void) hibernation_set_ops(old_suspend_ordering ? &acpi_hibernation_ops_old : &acpi_hibernation_ops); sleep_states[ACPI_STATE_S4] = 1; - printk(" S4"); + printk(KERN_CONT " S4"); if (!nosigcheck) { acpi_get_table(ACPI_SIG_FACS, 1, (struct acpi_table_header **)&facs); @@ -914,11 +912,11 @@ int __init acpi_sleep_init(void) status = acpi_get_sleep_type_data(ACPI_STATE_S5, &type_a, &type_b); if (ACPI_SUCCESS(status)) { sleep_states[ACPI_STATE_S5] = 1; - printk(" S5"); + printk(KERN_CONT " S5"); pm_power_off_prepare = acpi_power_off_prepare; pm_power_off = acpi_power_off; } - printk(")\n"); + printk(KERN_CONT ")\n"); /* * Register the tts_notifier to reboot notifier list so that the _TTS * object can also be evaluated when the system enters S5. diff --git a/drivers/acpi/utils.c b/drivers/acpi/utils.c index b002a471c5d..adbbc1c80a2 100644 --- a/drivers/acpi/utils.c +++ b/drivers/acpi/utils.c @@ -382,3 +382,33 @@ acpi_evaluate_reference(acpi_handle handle, } EXPORT_SYMBOL(acpi_evaluate_reference); + +acpi_status +acpi_get_physical_device_location(acpi_handle handle, struct acpi_pld *pld) +{ + acpi_status status; + struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; + union acpi_object *output; + + status = acpi_evaluate_object(handle, "_PLD", NULL, &buffer); + + if (ACPI_FAILURE(status)) + return status; + + output = buffer.pointer; + + if (!output || output->type != ACPI_TYPE_PACKAGE + || !output->package.count + || output->package.elements[0].type != ACPI_TYPE_BUFFER + || output->package.elements[0].buffer.length > sizeof(*pld)) { + status = AE_TYPE; + goto out; + } + + memcpy(pld, output->package.elements[0].buffer.pointer, + output->package.elements[0].buffer.length); +out: + kfree(buffer.pointer); + return status; +} +EXPORT_SYMBOL(acpi_get_physical_device_location); |