aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2007-08-25 01:44:01 -0400
committerLen Brown <len.brown@intel.com>2007-08-25 01:44:01 -0400
commit25c87f7f2a4fc3e50a7912b1c78405d454d1c4d9 (patch)
treec42d40004e9668d83ab03ab7332515ef08683c54 /drivers/misc
parenta4fd4946214fae86610b989c47e5ae762cc96ddb (diff)
parent3e069ee0c30d6f28b79e409ef2df1ffa427897ae (diff)
Pull events into release branch
Conflicts: drivers/acpi/video.c Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/asus-laptop.c2
-rw-r--r--drivers/misc/sony-laptop.c4
-rw-r--r--drivers/misc/thinkpad_acpi.c26
3 files changed, 20 insertions, 12 deletions
diff --git a/drivers/misc/asus-laptop.c b/drivers/misc/asus-laptop.c
index 40db9f70148f..7dce318df1bd 100644
--- a/drivers/misc/asus-laptop.c
+++ b/drivers/misc/asus-laptop.c
@@ -732,7 +732,7 @@ static void asus_hotk_notify(acpi_handle handle, u32 event, void *data)
732 lcd_blank(FB_BLANK_POWERDOWN); 732 lcd_blank(FB_BLANK_POWERDOWN);
733 } 733 }
734 734
735 acpi_bus_generate_event(hotk->device, event, 735 acpi_bus_generate_proc_event(hotk->device, event,
736 hotk->event_count[event % 128]++); 736 hotk->event_count[event % 128]++);
737 737
738 return; 738 return;
diff --git a/drivers/misc/sony-laptop.c b/drivers/misc/sony-laptop.c
index 7d8bebec2961..d38ddce592c0 100644
--- a/drivers/misc/sony-laptop.c
+++ b/drivers/misc/sony-laptop.c
@@ -913,7 +913,7 @@ static void sony_acpi_notify(acpi_handle handle, u32 event, void *data)
913 913
914 dprintk("sony_acpi_notify, event: 0x%.2x\n", ev); 914 dprintk("sony_acpi_notify, event: 0x%.2x\n", ev);
915 sony_laptop_report_input_event(ev); 915 sony_laptop_report_input_event(ev);
916 acpi_bus_generate_event(sony_nc_acpi_device, 1, ev); 916 acpi_bus_generate_proc_event(sony_nc_acpi_device, 1, ev);
917} 917}
918 918
919static acpi_status sony_walk_callback(acpi_handle handle, u32 level, 919static 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)
2301 2301
2302found: 2302found:
2303 sony_laptop_report_input_event(device_event); 2303 sony_laptop_report_input_event(device_event);
2304 acpi_bus_generate_event(spic_dev.acpi_dev, 1, device_event); 2304 acpi_bus_generate_proc_event(spic_dev.acpi_dev, 1, device_event);
2305 sonypi_compat_report_event(device_event); 2305 sonypi_compat_report_event(device_event);
2306 2306
2307 return IRQ_HANDLED; 2307 return IRQ_HANDLED;
diff --git a/drivers/misc/thinkpad_acpi.c b/drivers/misc/thinkpad_acpi.c
index f6cd34a3dbac..bb8956d0c104 100644
--- a/drivers/misc/thinkpad_acpi.c
+++ b/drivers/misc/thinkpad_acpi.c
@@ -1190,10 +1190,10 @@ static void hotkey_notify(struct ibm_struct *ibm, u32 event)
1190 } 1190 }
1191 1191
1192 if (sendacpi) 1192 if (sendacpi)
1193 acpi_bus_generate_event(ibm->acpi->device, event, hkey); 1193 acpi_bus_generate_proc_event(ibm->acpi->device, event, hkey);
1194 } else { 1194 } else {
1195 printk(IBM_ERR "unknown hotkey notification event %d\n", event); 1195 printk(IBM_ERR "unknown hotkey notification event %d\n", event);
1196 acpi_bus_generate_event(ibm->acpi->device, event, 0); 1196 acpi_bus_generate_proc_event(ibm->acpi->device, event, 0);
1197 } 1197 }
1198} 1198}
1199 1199
@@ -2162,22 +2162,27 @@ static void dock_notify(struct ibm_struct *ibm, u32 event)
2162 int docked = dock_docked(); 2162 int docked = dock_docked();
2163 int pci = ibm->acpi->hid && ibm->acpi->device && 2163 int pci = ibm->acpi->hid && ibm->acpi->device &&
2164 acpi_match_device_ids(ibm->acpi->device, ibm_pci_device_ids); 2164 acpi_match_device_ids(ibm->acpi->device, ibm_pci_device_ids);
2165 int data;
2165 2166
2166 if (event == 1 && !pci) /* 570 */ 2167 if (event == 1 && !pci) /* 570 */
2167 acpi_bus_generate_event(ibm->acpi->device, event, 1); /* button */ 2168 data = 1; /* button */
2168 else if (event == 1 && pci) /* 570 */ 2169 else if (event == 1 && pci) /* 570 */
2169 acpi_bus_generate_event(ibm->acpi->device, event, 3); /* dock */ 2170 data = 3; /* dock */
2170 else if (event == 3 && docked) 2171 else if (event == 3 && docked)
2171 acpi_bus_generate_event(ibm->acpi->device, event, 1); /* button */ 2172 data = 1; /* button */
2172 else if (event == 3 && !docked) 2173 else if (event == 3 && !docked)
2173 acpi_bus_generate_event(ibm->acpi->device, event, 2); /* undock */ 2174 data = 2; /* undock */
2174 else if (event == 0 && docked) 2175 else if (event == 0 && docked)
2175 acpi_bus_generate_event(ibm->acpi->device, event, 3); /* dock */ 2176 data = 3; /* dock */
2176 else { 2177 else {
2177 printk(IBM_ERR "unknown dock event %d, status %d\n", 2178 printk(IBM_ERR "unknown dock event %d, status %d\n",
2178 event, _sta(dock_handle)); 2179 event, _sta(dock_handle));
2179 acpi_bus_generate_event(ibm->acpi->device, event, 0); /* unknown */ 2180 data = 0; /* unknown */
2180 } 2181 }
2182 acpi_bus_generate_proc_event(ibm->acpi->device, event, data);
2183 acpi_bus_generate_netlink_event(ibm->acpi->device->pnp.device_class,
2184 ibm->acpi->device->dev.bus_id,
2185 event, data);
2181} 2186}
2182 2187
2183static int dock_read(char *p) 2188static int dock_read(char *p)
@@ -2275,7 +2280,10 @@ static int __init bay_init(struct ibm_init_struct *iibm)
2275 2280
2276static void bay_notify(struct ibm_struct *ibm, u32 event) 2281static void bay_notify(struct ibm_struct *ibm, u32 event)
2277{ 2282{
2278 acpi_bus_generate_event(ibm->acpi->device, event, 0); 2283 acpi_bus_generate_proc_event(ibm->acpi->device, event, 0);
2284 acpi_bus_generate_netlink_event(ibm->acpi->device->pnp.device_class,
2285 ibm->acpi->device->dev.bus_id,
2286 event, 0);
2279} 2287}
2280 2288
2281#define bay_occupied(b) (_sta(b##_handle) & 1) 2289#define bay_occupied(b) (_sta(b##_handle) & 1)