提交 c523aef0 编写于 作者: L Len Brown

Merge branches 'release', 'button-sysfs', 'misc', 'mismatch', 'randconfig' and...

Merge branches 'release', 'button-sysfs', 'misc', 'mismatch', 'randconfig' and 'toshiba' into release
......@@ -283,24 +283,23 @@ config ACPI_TOSHIBA
If you have a legacy free Toshiba laptop (such as the Libretto L1
series), say Y.
config ACPI_CUSTOM_DSDT
bool "Include Custom DSDT"
config ACPI_CUSTOM_DSDT_FILE
string "Custom DSDT Table file to include"
default ""
depends on !STANDALONE
default n
help
This option supports a custom DSDT by linking it into the kernel.
See Documentation/acpi/dsdt-override.txt
If unsure, say N.
config ACPI_CUSTOM_DSDT_FILE
string "Custom DSDT Table file to include"
depends on ACPI_CUSTOM_DSDT
default ""
help
Enter the full path name to the file which includes the AmlCode
declaration.
If unsure, don't enter a file name.
config ACPI_CUSTOM_DSDT
bool
default ACPI_CUSTOM_DSDT_FILE != ""
config ACPI_CUSTOM_DSDT_INITRD
bool "Read Custom DSDT from initramfs"
depends on BLK_DEV_INITRD
......
......@@ -776,7 +776,7 @@ static int __init acpi_init(void)
acpi_kobj = kobject_create_and_add("acpi", firmware_kobj);
if (!acpi_kobj) {
printk(KERN_WARNING "%s: kset create error\n", __FUNCTION__);
printk(KERN_WARNING "%s: kset create error\n", __func__);
acpi_kobj = NULL;
}
......
......@@ -449,6 +449,7 @@ static int acpi_button_add(struct acpi_device *device)
input->phys = button->phys;
input->id.bustype = BUS_HOST;
input->id.product = button->type;
input->dev.parent = &device->dev;
switch (button->type) {
case ACPI_BUTTON_TYPE_POWER:
......
......@@ -1237,7 +1237,7 @@ int acpi_check_resource_conflict(struct resource *res)
if (clash) {
if (acpi_enforce_resources != ENFORCE_RESOURCES_NO) {
printk(KERN_INFO "%sACPI: %s resource %s [0x%llx-0x%llx]"
printk("%sACPI: %s resource %s [0x%llx-0x%llx]"
" conflicts with ACPI region %s"
" [0x%llx-0x%llx]\n",
acpi_enforce_resources == ENFORCE_RESOURCES_LAX
......
......@@ -184,7 +184,7 @@ static void acpi_pci_bridge_scan(struct acpi_device *device)
}
}
static int acpi_pci_root_add(struct acpi_device *device)
static int __devinit acpi_pci_root_add(struct acpi_device *device)
{
int result = 0;
struct acpi_pci_root *root = NULL;
......
......@@ -888,8 +888,8 @@ int acpi_processor_device_add(acpi_handle handle, struct acpi_device **device)
return 0;
}
static void
acpi_processor_hotplug_notify(acpi_handle handle, u32 event, void *data)
static void __ref acpi_processor_hotplug_notify(acpi_handle handle,
u32 event, void *data)
{
struct acpi_processor *pr;
struct acpi_device *device = NULL;
......@@ -899,9 +899,10 @@ acpi_processor_hotplug_notify(acpi_handle handle, u32 event, void *data)
switch (event) {
case ACPI_NOTIFY_BUS_CHECK:
case ACPI_NOTIFY_DEVICE_CHECK:
printk("Processor driver received %s event\n",
ACPI_DEBUG_PRINT((ACPI_DB_INFO,
"Processor driver received %s event\n",
(event == ACPI_NOTIFY_BUS_CHECK) ?
"ACPI_NOTIFY_BUS_CHECK" : "ACPI_NOTIFY_DEVICE_CHECK");
"ACPI_NOTIFY_BUS_CHECK" : "ACPI_NOTIFY_DEVICE_CHECK"));
if (!is_processor_present(handle))
break;
......
......@@ -966,7 +966,7 @@ static void acpi_device_set_id(struct acpi_device *device,
case ACPI_BUS_TYPE_DEVICE:
status = acpi_get_object_info(handle, &buffer);
if (ACPI_FAILURE(status)) {
printk(KERN_ERR PREFIX "%s: Error reading device info\n", __FUNCTION__);
printk(KERN_ERR PREFIX "%s: Error reading device info\n", __func__);
return;
}
......
......@@ -504,7 +504,7 @@ static void acpi_power_off_prepare(void)
static void acpi_power_off(void)
{
/* acpi_sleep_prepare(ACPI_STATE_S5) should have already been called */
printk("%s called\n", __FUNCTION__);
printk("%s called\n", __func__);
local_irq_disable();
acpi_enable_wakeup_device(ACPI_STATE_S5);
acpi_enter_sleep_state(ACPI_STATE_S5);
......
......@@ -319,7 +319,7 @@ void acpi_irq_stats_init(void)
goto fail;
for (i = 0; i < num_counters; ++i) {
char buffer[10];
char buffer[12];
char *name;
if (i < num_gpes)
......
......@@ -99,6 +99,13 @@ MODULE_LICENSE("GPL");
#define HCI_VIDEO_OUT_CRT 0x2
#define HCI_VIDEO_OUT_TV 0x4
static const struct acpi_device_id toshiba_device_ids[] = {
{"TOS6200", 0},
{"TOS1900", 0},
{"", 0},
};
MODULE_DEVICE_TABLE(acpi, toshiba_device_ids);
/* utility
*/
......
......@@ -109,7 +109,7 @@ void acpi_ut_track_stack_ptr(void)
* RETURN: Updated pointer to the function name
*
* DESCRIPTION: Remove the "Acpi" prefix from the function name, if present.
* This allows compiler macros such as __FUNCTION__ to be used
* This allows compiler macros such as __func__ to be used
* with no change to the debug output.
*
******************************************************************************/
......
......@@ -407,6 +407,12 @@ acpi_evaluate_reference(acpi_handle handle,
break;
}
if (!element->reference.handle) {
printk(KERN_WARNING PREFIX "Invalid reference in"
" package %s\n", pathname);
status = AE_NULL_ENTRY;
break;
}
/* Get the acpi_handle. */
list->handles[i] = element->reference.handle;
......
......@@ -1201,7 +1201,7 @@ static int acpi_video_bus_ROM_seq_show(struct seq_file *seq, void *offset)
if (!video)
goto end;
printk(KERN_INFO PREFIX "Please implement %s\n", __FUNCTION__);
printk(KERN_INFO PREFIX "Please implement %s\n", __func__);
seq_printf(seq, "<TODO>\n");
end:
......
......@@ -765,7 +765,7 @@ static struct led_classdev mail_led = {
.brightness_set = mail_led_set,
};
static int __init acer_led_init(struct device *dev)
static int __devinit acer_led_init(struct device *dev)
{
return led_classdev_register(dev, &mail_led);
}
......@@ -798,7 +798,7 @@ static struct backlight_ops acer_bl_ops = {
.update_status = update_bl_status,
};
static int __init acer_backlight_init(struct device *dev)
static int __devinit acer_backlight_init(struct device *dev)
{
struct backlight_device *bd;
......@@ -817,7 +817,7 @@ static int __init acer_backlight_init(struct device *dev)
return 0;
}
static void __exit acer_backlight_exit(void)
static void acer_backlight_exit(void)
{
backlight_device_unregister(acer_backlight_device);
}
......
......@@ -272,21 +272,29 @@ static int acpi_pci_set_power_state(struct pci_dev *dev, pci_power_t state)
{
acpi_handle handle = DEVICE_ACPI_HANDLE(&dev->dev);
acpi_handle tmp;
static int state_conv[] = {
[0] = 0,
[1] = 1,
[2] = 2,
[3] = 3,
[4] = 3
static const u8 state_conv[] = {
[PCI_D0] = ACPI_STATE_D0,
[PCI_D1] = ACPI_STATE_D1,
[PCI_D2] = ACPI_STATE_D2,
[PCI_D3hot] = ACPI_STATE_D3,
[PCI_D3cold] = ACPI_STATE_D3
};
int acpi_state = state_conv[(int __force) state];
if (!handle)
return -ENODEV;
/* If the ACPI device has _EJ0, ignore the device */
if (ACPI_SUCCESS(acpi_get_handle(handle, "_EJ0", &tmp)))
return 0;
return acpi_bus_set_power(handle, acpi_state);
switch (state) {
case PCI_D0:
case PCI_D1:
case PCI_D2:
case PCI_D3hot:
case PCI_D3cold:
return acpi_bus_set_power(handle, state_conv[state]);
}
return -EINVAL;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册