mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
Pull events into release branch
Conflicts: drivers/acpi/video.c Signed-off-by: Len Brown <[email protected]>
This commit is contained in:
commit
25c87f7f2a
18 changed files with 123 additions and 50 deletions
|
|
@ -732,7 +732,7 @@ static void asus_hotk_notify(acpi_handle handle, u32 event, void *data)
|
|||
lcd_blank(FB_BLANK_POWERDOWN);
|
||||
}
|
||||
|
||||
acpi_bus_generate_event(hotk->device, event,
|
||||
acpi_bus_generate_proc_event(hotk->device, event,
|
||||
hotk->event_count[event % 128]++);
|
||||
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -913,7 +913,7 @@ static void sony_acpi_notify(acpi_handle handle, u32 event, void *data)
|
|||
|
||||
dprintk("sony_acpi_notify, event: 0x%.2x\n", ev);
|
||||
sony_laptop_report_input_event(ev);
|
||||
acpi_bus_generate_event(sony_nc_acpi_device, 1, ev);
|
||||
acpi_bus_generate_proc_event(sony_nc_acpi_device, 1, ev);
|
||||
}
|
||||
|
||||
static acpi_status sony_walk_callback(acpi_handle handle, u32 level,
|
||||
|
|
@ -2301,7 +2301,7 @@ static irqreturn_t sony_pic_irq(int irq, void *dev_id)
|
|||
|
||||
found:
|
||||
sony_laptop_report_input_event(device_event);
|
||||
acpi_bus_generate_event(spic_dev.acpi_dev, 1, device_event);
|
||||
acpi_bus_generate_proc_event(spic_dev.acpi_dev, 1, device_event);
|
||||
sonypi_compat_report_event(device_event);
|
||||
|
||||
return IRQ_HANDLED;
|
||||
|
|
|
|||
|
|
@ -1190,10 +1190,10 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
|
|||
}
|
||||
|
||||
if (sendacpi)
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, hkey);
|
||||
acpi_bus_generate_proc_event(ibm->acpi->device, event, hkey);
|
||||
} else {
|
||||
printk(IBM_ERR "unknown hotkey notification event %d\n", event);
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 0);
|
||||
acpi_bus_generate_proc_event(ibm->acpi->device, event, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -2162,22 +2162,27 @@ static void dock_notify(struct ibm_struct *ibm, u32 event)
|
|||
int docked = dock_docked();
|
||||
int pci = ibm->acpi->hid && ibm->acpi->device &&
|
||||
acpi_match_device_ids(ibm->acpi->device, ibm_pci_device_ids);
|
||||
int data;
|
||||
|
||||
if (event == 1 && !pci) /* 570 */
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 1); /* button */
|
||||
data = 1; /* button */
|
||||
else if (event == 1 && pci) /* 570 */
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 3); /* dock */
|
||||
data = 3; /* dock */
|
||||
else if (event == 3 && docked)
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 1); /* button */
|
||||
data = 1; /* button */
|
||||
else if (event == 3 && !docked)
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 2); /* undock */
|
||||
data = 2; /* undock */
|
||||
else if (event == 0 && docked)
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 3); /* dock */
|
||||
data = 3; /* dock */
|
||||
else {
|
||||
printk(IBM_ERR "unknown dock event %d, status %d\n",
|
||||
event, _sta(dock_handle));
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 0); /* unknown */
|
||||
data = 0; /* unknown */
|
||||
}
|
||||
acpi_bus_generate_proc_event(ibm->acpi->device, event, data);
|
||||
acpi_bus_generate_netlink_event(ibm->acpi->device->pnp.device_class,
|
||||
ibm->acpi->device->dev.bus_id,
|
||||
event, data);
|
||||
}
|
||||
|
||||
static int dock_read(char *p)
|
||||
|
|
@ -2275,7 +2280,10 @@ static int __init bay_init(struct ibm_init_struct *iibm)
|
|||
|
||||
static void bay_notify(struct ibm_struct *ibm, u32 event)
|
||||
{
|
||||
acpi_bus_generate_event(ibm->acpi->device, event, 0);
|
||||
acpi_bus_generate_proc_event(ibm->acpi->device, event, 0);
|
||||
acpi_bus_generate_netlink_event(ibm->acpi->device->pnp.device_class,
|
||||
ibm->acpi->device->dev.bus_id,
|
||||
event, 0);
|
||||
}
|
||||
|
||||
#define bay_occupied(b) (_sta(b##_handle) & 1)
|
||||
|
|
|
|||
Loading…
Reference in a new issue