diff options
author | Alan Stern <stern@rowland.harvard.edu> | 2008-08-20 17:22:05 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-08-21 13:26:38 -0400 |
commit | b5fb454f69642f9d933b327b185a2ba06dd0945c (patch) | |
tree | aa68acda039477c8d6411ed3e0fe78d3f9098071 /drivers/usb | |
parent | 5096aedcd2eb70fbea83f09281f97f9ec973d9de (diff) |
USB: automatically enable RHSC interrupts
This patch (as1069c) changes the way OHCI root-hub status-change
interrupts are enabled. Currently a special HCD method,
hub_irq_enable(), is called when the hub driver is finished using a
root hub. This approach turns out to be subject to races, resulting
in unnecessary polling.
The patch does away with the method entirely. Instead, the driver
automatically enables the RHSC interrupt when no more status changes
are present. This scheme is safe with controllers using
level-triggered semantics for their interrupt flags.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/core/hcd.c | 9 | ||||
-rw-r--r-- | drivers/usb/core/hcd.h | 4 | ||||
-rw-r--r-- | drivers/usb/core/hub.c | 9 | ||||
-rw-r--r-- | drivers/usb/host/ohci-at91.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-au1xxx.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-ep93xx.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-hub.c | 53 | ||||
-rw-r--r-- | drivers/usb/host/ohci-lh7a404.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-omap.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-pci.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-pnx4008.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-pnx8550.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-ppc-of.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-ppc-soc.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-ps3.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-pxa27x.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-s3c2410.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-sa1111.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-sh.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-sm501.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/ohci-ssb.c | 1 | ||||
-rw-r--r-- | drivers/usb/host/u132-hcd.c | 11 |
22 files changed, 31 insertions, 72 deletions
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c index f7bfd72ef11..8abd4e59bf4 100644 --- a/drivers/usb/core/hcd.c +++ b/drivers/usb/core/hcd.c | |||
@@ -924,15 +924,6 @@ static int register_root_hub(struct usb_hcd *hcd) | |||
924 | return retval; | 924 | return retval; |
925 | } | 925 | } |
926 | 926 | ||
927 | void usb_enable_root_hub_irq (struct usb_bus *bus) | ||
928 | { | ||
929 | struct usb_hcd *hcd; | ||
930 | |||
931 | hcd = container_of (bus, struct usb_hcd, self); | ||
932 | if (hcd->driver->hub_irq_enable && hcd->state != HC_STATE_HALT) | ||
933 | hcd->driver->hub_irq_enable (hcd); | ||
934 | } | ||
935 | |||
936 | 927 | ||
937 | /*-------------------------------------------------------------------------*/ | 928 | /*-------------------------------------------------------------------------*/ |
938 | 929 | ||
diff --git a/drivers/usb/core/hcd.h b/drivers/usb/core/hcd.h index 5b0b59b0d89..e710ce04e22 100644 --- a/drivers/usb/core/hcd.h +++ b/drivers/usb/core/hcd.h | |||
@@ -212,8 +212,6 @@ struct hc_driver { | |||
212 | int (*bus_suspend)(struct usb_hcd *); | 212 | int (*bus_suspend)(struct usb_hcd *); |
213 | int (*bus_resume)(struct usb_hcd *); | 213 | int (*bus_resume)(struct usb_hcd *); |
214 | int (*start_port_reset)(struct usb_hcd *, unsigned port_num); | 214 | int (*start_port_reset)(struct usb_hcd *, unsigned port_num); |
215 | void (*hub_irq_enable)(struct usb_hcd *); | ||
216 | /* Needed only if port-change IRQs are level-triggered */ | ||
217 | 215 | ||
218 | /* force handover of high-speed port to full-speed companion */ | 216 | /* force handover of high-speed port to full-speed companion */ |
219 | void (*relinquish_port)(struct usb_hcd *, int); | 217 | void (*relinquish_port)(struct usb_hcd *, int); |
@@ -379,8 +377,6 @@ extern struct list_head usb_bus_list; | |||
379 | extern struct mutex usb_bus_list_lock; | 377 | extern struct mutex usb_bus_list_lock; |
380 | extern wait_queue_head_t usb_kill_urb_queue; | 378 | extern wait_queue_head_t usb_kill_urb_queue; |
381 | 379 | ||
382 | extern void usb_enable_root_hub_irq(struct usb_bus *bus); | ||
383 | |||
384 | extern int usb_find_interface_driver(struct usb_device *dev, | 380 | extern int usb_find_interface_driver(struct usb_device *dev, |
385 | struct usb_interface *interface); | 381 | struct usb_interface *interface); |
386 | 382 | ||
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index 107e1d25dde..6a5cb018383 100644 --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c | |||
@@ -2102,8 +2102,6 @@ int usb_port_resume(struct usb_device *udev) | |||
2102 | } | 2102 | } |
2103 | 2103 | ||
2104 | clear_bit(port1, hub->busy_bits); | 2104 | clear_bit(port1, hub->busy_bits); |
2105 | if (!hub->hdev->parent && !hub->busy_bits[0]) | ||
2106 | usb_enable_root_hub_irq(hub->hdev->bus); | ||
2107 | 2105 | ||
2108 | status = check_port_resume_type(udev, | 2106 | status = check_port_resume_type(udev, |
2109 | hub, port1, status, portchange, portstatus); | 2107 | hub, port1, status, portchange, portstatus); |
@@ -3081,11 +3079,6 @@ static void hub_events(void) | |||
3081 | } | 3079 | } |
3082 | } | 3080 | } |
3083 | 3081 | ||
3084 | /* If this is a root hub, tell the HCD it's okay to | ||
3085 | * re-enable port-change interrupts now. */ | ||
3086 | if (!hdev->parent && !hub->busy_bits[0]) | ||
3087 | usb_enable_root_hub_irq(hdev->bus); | ||
3088 | |||
3089 | loop_autopm: | 3082 | loop_autopm: |
3090 | /* Allow autosuspend if we're not going to run again */ | 3083 | /* Allow autosuspend if we're not going to run again */ |
3091 | if (list_empty(&hub->event_list)) | 3084 | if (list_empty(&hub->event_list)) |
@@ -3311,8 +3304,6 @@ static int usb_reset_and_verify_device(struct usb_device *udev) | |||
3311 | break; | 3304 | break; |
3312 | } | 3305 | } |
3313 | clear_bit(port1, parent_hub->busy_bits); | 3306 | clear_bit(port1, parent_hub->busy_bits); |
3314 | if (!parent_hdev->parent && !parent_hub->busy_bits[0]) | ||
3315 | usb_enable_root_hub_irq(parent_hdev->bus); | ||
3316 | 3307 | ||
3317 | if (ret < 0) | 3308 | if (ret < 0) |
3318 | goto re_enumerate; | 3309 | goto re_enumerate; |
diff --git a/drivers/usb/host/ohci-at91.c b/drivers/usb/host/ohci-at91.c index 6db7a2889e6..4ed228a8994 100644 --- a/drivers/usb/host/ohci-at91.c +++ b/drivers/usb/host/ohci-at91.c | |||
@@ -260,7 +260,6 @@ static const struct hc_driver ohci_at91_hc_driver = { | |||
260 | */ | 260 | */ |
261 | .hub_status_data = ohci_hub_status_data, | 261 | .hub_status_data = ohci_hub_status_data, |
262 | .hub_control = ohci_hub_control, | 262 | .hub_control = ohci_hub_control, |
263 | .hub_irq_enable = ohci_rhsc_enable, | ||
264 | #ifdef CONFIG_PM | 263 | #ifdef CONFIG_PM |
265 | .bus_suspend = ohci_bus_suspend, | 264 | .bus_suspend = ohci_bus_suspend, |
266 | .bus_resume = ohci_bus_resume, | 265 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-au1xxx.c b/drivers/usb/host/ohci-au1xxx.c index c0948008fe3..2ac4e022a13 100644 --- a/drivers/usb/host/ohci-au1xxx.c +++ b/drivers/usb/host/ohci-au1xxx.c | |||
@@ -163,7 +163,6 @@ static const struct hc_driver ohci_au1xxx_hc_driver = { | |||
163 | */ | 163 | */ |
164 | .hub_status_data = ohci_hub_status_data, | 164 | .hub_status_data = ohci_hub_status_data, |
165 | .hub_control = ohci_hub_control, | 165 | .hub_control = ohci_hub_control, |
166 | .hub_irq_enable = ohci_rhsc_enable, | ||
167 | #ifdef CONFIG_PM | 166 | #ifdef CONFIG_PM |
168 | .bus_suspend = ohci_bus_suspend, | 167 | .bus_suspend = ohci_bus_suspend, |
169 | .bus_resume = ohci_bus_resume, | 168 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-ep93xx.c b/drivers/usb/host/ohci-ep93xx.c index cb0b506f825..fb3055f084b 100644 --- a/drivers/usb/host/ohci-ep93xx.c +++ b/drivers/usb/host/ohci-ep93xx.c | |||
@@ -134,7 +134,6 @@ static struct hc_driver ohci_ep93xx_hc_driver = { | |||
134 | .get_frame_number = ohci_get_frame, | 134 | .get_frame_number = ohci_get_frame, |
135 | .hub_status_data = ohci_hub_status_data, | 135 | .hub_status_data = ohci_hub_status_data, |
136 | .hub_control = ohci_hub_control, | 136 | .hub_control = ohci_hub_control, |
137 | .hub_irq_enable = ohci_rhsc_enable, | ||
138 | #ifdef CONFIG_PM | 137 | #ifdef CONFIG_PM |
139 | .bus_suspend = ohci_bus_suspend, | 138 | .bus_suspend = ohci_bus_suspend, |
140 | .bus_resume = ohci_bus_resume, | 139 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-hub.c b/drivers/usb/host/ohci-hub.c index 439beb784f3..7ea9a7b3115 100644 --- a/drivers/usb/host/ohci-hub.c +++ b/drivers/usb/host/ohci-hub.c | |||
@@ -36,18 +36,6 @@ | |||
36 | 36 | ||
37 | /*-------------------------------------------------------------------------*/ | 37 | /*-------------------------------------------------------------------------*/ |
38 | 38 | ||
39 | /* hcd->hub_irq_enable() */ | ||
40 | static void ohci_rhsc_enable (struct usb_hcd *hcd) | ||
41 | { | ||
42 | struct ohci_hcd *ohci = hcd_to_ohci (hcd); | ||
43 | |||
44 | spin_lock_irq(&ohci->lock); | ||
45 | if (!ohci->autostop) | ||
46 | del_timer(&hcd->rh_timer); /* Prevent next poll */ | ||
47 | ohci_writel(ohci, OHCI_INTR_RHSC, &ohci->regs->intrenable); | ||
48 | spin_unlock_irq(&ohci->lock); | ||
49 | } | ||
50 | |||
51 | #define OHCI_SCHED_ENABLES \ | 39 | #define OHCI_SCHED_ENABLES \ |
52 | (OHCI_CTRL_CLE|OHCI_CTRL_BLE|OHCI_CTRL_PLE|OHCI_CTRL_IE) | 40 | (OHCI_CTRL_CLE|OHCI_CTRL_BLE|OHCI_CTRL_PLE|OHCI_CTRL_IE) |
53 | 41 | ||
@@ -374,18 +362,28 @@ static int ohci_root_hub_state_changes(struct ohci_hcd *ohci, int changed, | |||
374 | int any_connected) | 362 | int any_connected) |
375 | { | 363 | { |
376 | int poll_rh = 1; | 364 | int poll_rh = 1; |
365 | int rhsc; | ||
377 | 366 | ||
367 | rhsc = ohci_readl(ohci, &ohci->regs->intrenable) & OHCI_INTR_RHSC; | ||
378 | switch (ohci->hc_control & OHCI_CTRL_HCFS) { | 368 | switch (ohci->hc_control & OHCI_CTRL_HCFS) { |
379 | 369 | ||
380 | case OHCI_USB_OPER: | 370 | case OHCI_USB_OPER: |
381 | /* keep on polling until we know a device is connected | 371 | /* If no status changes are pending, enable status-change |
382 | * and RHSC is enabled */ | 372 | * interrupts. |
373 | */ | ||
374 | if (!rhsc && !changed) { | ||
375 | rhsc = OHCI_INTR_RHSC; | ||
376 | ohci_writel(ohci, rhsc, &ohci->regs->intrenable); | ||
377 | } | ||
378 | |||
379 | /* Keep on polling until we know a device is connected | ||
380 | * and RHSC is enabled, or until we autostop. | ||
381 | */ | ||
383 | if (!ohci->autostop) { | 382 | if (!ohci->autostop) { |
384 | if (any_connected || | 383 | if (any_connected || |
385 | !device_may_wakeup(&ohci_to_hcd(ohci) | 384 | !device_may_wakeup(&ohci_to_hcd(ohci) |
386 | ->self.root_hub->dev)) { | 385 | ->self.root_hub->dev)) { |
387 | if (ohci_readl(ohci, &ohci->regs->intrenable) & | 386 | if (rhsc) |
388 | OHCI_INTR_RHSC) | ||
389 | poll_rh = 0; | 387 | poll_rh = 0; |
390 | } else { | 388 | } else { |
391 | ohci->autostop = 1; | 389 | ohci->autostop = 1; |
@@ -398,12 +396,13 @@ static int ohci_root_hub_state_changes(struct ohci_hcd *ohci, int changed, | |||
398 | ohci->autostop = 0; | 396 | ohci->autostop = 0; |
399 | ohci->next_statechange = jiffies + | 397 | ohci->next_statechange = jiffies + |
400 | STATECHANGE_DELAY; | 398 | STATECHANGE_DELAY; |
401 | } else if (time_after_eq(jiffies, | 399 | } else if (rhsc && time_after_eq(jiffies, |
402 | ohci->next_statechange) | 400 | ohci->next_statechange) |
403 | && !ohci->ed_rm_list | 401 | && !ohci->ed_rm_list |
404 | && !(ohci->hc_control & | 402 | && !(ohci->hc_control & |
405 | OHCI_SCHED_ENABLES)) { | 403 | OHCI_SCHED_ENABLES)) { |
406 | ohci_rh_suspend(ohci, 1); | 404 | ohci_rh_suspend(ohci, 1); |
405 | poll_rh = 0; | ||
407 | } | 406 | } |
408 | } | 407 | } |
409 | break; | 408 | break; |
@@ -417,6 +416,12 @@ static int ohci_root_hub_state_changes(struct ohci_hcd *ohci, int changed, | |||
417 | else | 416 | else |
418 | usb_hcd_resume_root_hub(ohci_to_hcd(ohci)); | 417 | usb_hcd_resume_root_hub(ohci_to_hcd(ohci)); |
419 | } else { | 418 | } else { |
419 | if (!rhsc && (ohci->autostop || | ||
420 | ohci_to_hcd(ohci)->self.root_hub-> | ||
421 | do_remote_wakeup)) | ||
422 | ohci_writel(ohci, OHCI_INTR_RHSC, | ||
423 | &ohci->regs->intrenable); | ||
424 | |||
420 | /* everything is idle, no need for polling */ | 425 | /* everything is idle, no need for polling */ |
421 | poll_rh = 0; | 426 | poll_rh = 0; |
422 | } | 427 | } |
@@ -438,12 +443,16 @@ static inline int ohci_rh_resume(struct ohci_hcd *ohci) | |||
438 | static int ohci_root_hub_state_changes(struct ohci_hcd *ohci, int changed, | 443 | static int ohci_root_hub_state_changes(struct ohci_hcd *ohci, int changed, |
439 | int any_connected) | 444 | int any_connected) |
440 | { | 445 | { |
441 | int poll_rh = 1; | 446 | /* If RHSC is enabled, don't poll */ |
442 | |||
443 | /* keep on polling until RHSC is enabled */ | ||
444 | if (ohci_readl(ohci, &ohci->regs->intrenable) & OHCI_INTR_RHSC) | 447 | if (ohci_readl(ohci, &ohci->regs->intrenable) & OHCI_INTR_RHSC) |
445 | poll_rh = 0; | 448 | return 0; |
446 | return poll_rh; | 449 | |
450 | /* If no status changes are pending, enable status-change interrupts */ | ||
451 | if (!changed) { | ||
452 | ohci_writel(ohci, OHCI_INTR_RHSC, &ohci->regs->intrenable); | ||
453 | return 0; | ||
454 | } | ||
455 | return 1; | ||
447 | } | 456 | } |
448 | 457 | ||
449 | #endif /* CONFIG_PM */ | 458 | #endif /* CONFIG_PM */ |
diff --git a/drivers/usb/host/ohci-lh7a404.c b/drivers/usb/host/ohci-lh7a404.c index 9e31d440d11..de42283149c 100644 --- a/drivers/usb/host/ohci-lh7a404.c +++ b/drivers/usb/host/ohci-lh7a404.c | |||
@@ -193,7 +193,6 @@ static const struct hc_driver ohci_lh7a404_hc_driver = { | |||
193 | */ | 193 | */ |
194 | .hub_status_data = ohci_hub_status_data, | 194 | .hub_status_data = ohci_hub_status_data, |
195 | .hub_control = ohci_hub_control, | 195 | .hub_control = ohci_hub_control, |
196 | .hub_irq_enable = ohci_rhsc_enable, | ||
197 | #ifdef CONFIG_PM | 196 | #ifdef CONFIG_PM |
198 | .bus_suspend = ohci_bus_suspend, | 197 | .bus_suspend = ohci_bus_suspend, |
199 | .bus_resume = ohci_bus_resume, | 198 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-omap.c b/drivers/usb/host/ohci-omap.c index 3d532b70967..1eb64d08b60 100644 --- a/drivers/usb/host/ohci-omap.c +++ b/drivers/usb/host/ohci-omap.c | |||
@@ -470,7 +470,6 @@ static const struct hc_driver ohci_omap_hc_driver = { | |||
470 | */ | 470 | */ |
471 | .hub_status_data = ohci_hub_status_data, | 471 | .hub_status_data = ohci_hub_status_data, |
472 | .hub_control = ohci_hub_control, | 472 | .hub_control = ohci_hub_control, |
473 | .hub_irq_enable = ohci_rhsc_enable, | ||
474 | #ifdef CONFIG_PM | 473 | #ifdef CONFIG_PM |
475 | .bus_suspend = ohci_bus_suspend, | 474 | .bus_suspend = ohci_bus_suspend, |
476 | .bus_resume = ohci_bus_resume, | 475 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-pci.c b/drivers/usb/host/ohci-pci.c index 083e8df0a81..a9c2ae36c7a 100644 --- a/drivers/usb/host/ohci-pci.c +++ b/drivers/usb/host/ohci-pci.c | |||
@@ -459,7 +459,6 @@ static const struct hc_driver ohci_pci_hc_driver = { | |||
459 | */ | 459 | */ |
460 | .hub_status_data = ohci_hub_status_data, | 460 | .hub_status_data = ohci_hub_status_data, |
461 | .hub_control = ohci_hub_control, | 461 | .hub_control = ohci_hub_control, |
462 | .hub_irq_enable = ohci_rhsc_enable, | ||
463 | #ifdef CONFIG_PM | 462 | #ifdef CONFIG_PM |
464 | .bus_suspend = ohci_bus_suspend, | 463 | .bus_suspend = ohci_bus_suspend, |
465 | .bus_resume = ohci_bus_resume, | 464 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-pnx4008.c b/drivers/usb/host/ohci-pnx4008.c index b02cd076197..658a2a978c3 100644 --- a/drivers/usb/host/ohci-pnx4008.c +++ b/drivers/usb/host/ohci-pnx4008.c | |||
@@ -277,7 +277,6 @@ static const struct hc_driver ohci_pnx4008_hc_driver = { | |||
277 | */ | 277 | */ |
278 | .hub_status_data = ohci_hub_status_data, | 278 | .hub_status_data = ohci_hub_status_data, |
279 | .hub_control = ohci_hub_control, | 279 | .hub_control = ohci_hub_control, |
280 | .hub_irq_enable = ohci_rhsc_enable, | ||
281 | #ifdef CONFIG_PM | 280 | #ifdef CONFIG_PM |
282 | .bus_suspend = ohci_bus_suspend, | 281 | .bus_suspend = ohci_bus_suspend, |
283 | .bus_resume = ohci_bus_resume, | 282 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-pnx8550.c b/drivers/usb/host/ohci-pnx8550.c index 605d59cba28..28467e288a9 100644 --- a/drivers/usb/host/ohci-pnx8550.c +++ b/drivers/usb/host/ohci-pnx8550.c | |||
@@ -201,7 +201,6 @@ static const struct hc_driver ohci_pnx8550_hc_driver = { | |||
201 | */ | 201 | */ |
202 | .hub_status_data = ohci_hub_status_data, | 202 | .hub_status_data = ohci_hub_status_data, |
203 | .hub_control = ohci_hub_control, | 203 | .hub_control = ohci_hub_control, |
204 | .hub_irq_enable = ohci_rhsc_enable, | ||
205 | #ifdef CONFIG_PM | 204 | #ifdef CONFIG_PM |
206 | .bus_suspend = ohci_bus_suspend, | 205 | .bus_suspend = ohci_bus_suspend, |
207 | .bus_resume = ohci_bus_resume, | 206 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-ppc-of.c b/drivers/usb/host/ohci-ppc-of.c index 91e6e101a4c..7ac53264ead 100644 --- a/drivers/usb/host/ohci-ppc-of.c +++ b/drivers/usb/host/ohci-ppc-of.c | |||
@@ -72,7 +72,6 @@ static const struct hc_driver ohci_ppc_of_hc_driver = { | |||
72 | */ | 72 | */ |
73 | .hub_status_data = ohci_hub_status_data, | 73 | .hub_status_data = ohci_hub_status_data, |
74 | .hub_control = ohci_hub_control, | 74 | .hub_control = ohci_hub_control, |
75 | .hub_irq_enable = ohci_rhsc_enable, | ||
76 | #ifdef CONFIG_PM | 75 | #ifdef CONFIG_PM |
77 | .bus_suspend = ohci_bus_suspend, | 76 | .bus_suspend = ohci_bus_suspend, |
78 | .bus_resume = ohci_bus_resume, | 77 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-ppc-soc.c b/drivers/usb/host/ohci-ppc-soc.c index 523c3012557..cd3398b675b 100644 --- a/drivers/usb/host/ohci-ppc-soc.c +++ b/drivers/usb/host/ohci-ppc-soc.c | |||
@@ -172,7 +172,6 @@ static const struct hc_driver ohci_ppc_soc_hc_driver = { | |||
172 | */ | 172 | */ |
173 | .hub_status_data = ohci_hub_status_data, | 173 | .hub_status_data = ohci_hub_status_data, |
174 | .hub_control = ohci_hub_control, | 174 | .hub_control = ohci_hub_control, |
175 | .hub_irq_enable = ohci_rhsc_enable, | ||
176 | #ifdef CONFIG_PM | 175 | #ifdef CONFIG_PM |
177 | .bus_suspend = ohci_bus_suspend, | 176 | .bus_suspend = ohci_bus_suspend, |
178 | .bus_resume = ohci_bus_resume, | 177 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-ps3.c b/drivers/usb/host/ohci-ps3.c index 55c95647f00..2089d8a46c4 100644 --- a/drivers/usb/host/ohci-ps3.c +++ b/drivers/usb/host/ohci-ps3.c | |||
@@ -68,7 +68,6 @@ static const struct hc_driver ps3_ohci_hc_driver = { | |||
68 | .get_frame_number = ohci_get_frame, | 68 | .get_frame_number = ohci_get_frame, |
69 | .hub_status_data = ohci_hub_status_data, | 69 | .hub_status_data = ohci_hub_status_data, |
70 | .hub_control = ohci_hub_control, | 70 | .hub_control = ohci_hub_control, |
71 | .hub_irq_enable = ohci_rhsc_enable, | ||
72 | .start_port_reset = ohci_start_port_reset, | 71 | .start_port_reset = ohci_start_port_reset, |
73 | #if defined(CONFIG_PM) | 72 | #if defined(CONFIG_PM) |
74 | .bus_suspend = ohci_bus_suspend, | 73 | .bus_suspend = ohci_bus_suspend, |
diff --git a/drivers/usb/host/ohci-pxa27x.c b/drivers/usb/host/ohci-pxa27x.c index 8c9c4849db6..7f0f35c7818 100644 --- a/drivers/usb/host/ohci-pxa27x.c +++ b/drivers/usb/host/ohci-pxa27x.c | |||
@@ -298,7 +298,6 @@ static const struct hc_driver ohci_pxa27x_hc_driver = { | |||
298 | */ | 298 | */ |
299 | .hub_status_data = ohci_hub_status_data, | 299 | .hub_status_data = ohci_hub_status_data, |
300 | .hub_control = ohci_hub_control, | 300 | .hub_control = ohci_hub_control, |
301 | .hub_irq_enable = ohci_rhsc_enable, | ||
302 | #ifdef CONFIG_PM | 301 | #ifdef CONFIG_PM |
303 | .bus_suspend = ohci_bus_suspend, | 302 | .bus_suspend = ohci_bus_suspend, |
304 | .bus_resume = ohci_bus_resume, | 303 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-s3c2410.c b/drivers/usb/host/ohci-s3c2410.c index 9e3dc4069e8..f46af7a718d 100644 --- a/drivers/usb/host/ohci-s3c2410.c +++ b/drivers/usb/host/ohci-s3c2410.c | |||
@@ -466,7 +466,6 @@ static const struct hc_driver ohci_s3c2410_hc_driver = { | |||
466 | */ | 466 | */ |
467 | .hub_status_data = ohci_s3c2410_hub_status_data, | 467 | .hub_status_data = ohci_s3c2410_hub_status_data, |
468 | .hub_control = ohci_s3c2410_hub_control, | 468 | .hub_control = ohci_s3c2410_hub_control, |
469 | .hub_irq_enable = ohci_rhsc_enable, | ||
470 | #ifdef CONFIG_PM | 469 | #ifdef CONFIG_PM |
471 | .bus_suspend = ohci_bus_suspend, | 470 | .bus_suspend = ohci_bus_suspend, |
472 | .bus_resume = ohci_bus_resume, | 471 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-sa1111.c b/drivers/usb/host/ohci-sa1111.c index 4626b002e67..e4bbe8e188e 100644 --- a/drivers/usb/host/ohci-sa1111.c +++ b/drivers/usb/host/ohci-sa1111.c | |||
@@ -231,7 +231,6 @@ static const struct hc_driver ohci_sa1111_hc_driver = { | |||
231 | */ | 231 | */ |
232 | .hub_status_data = ohci_hub_status_data, | 232 | .hub_status_data = ohci_hub_status_data, |
233 | .hub_control = ohci_hub_control, | 233 | .hub_control = ohci_hub_control, |
234 | .hub_irq_enable = ohci_rhsc_enable, | ||
235 | #ifdef CONFIG_PM | 234 | #ifdef CONFIG_PM |
236 | .bus_suspend = ohci_bus_suspend, | 235 | .bus_suspend = ohci_bus_suspend, |
237 | .bus_resume = ohci_bus_resume, | 236 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-sh.c b/drivers/usb/host/ohci-sh.c index e7ee607278f..60f03cc7ec4 100644 --- a/drivers/usb/host/ohci-sh.c +++ b/drivers/usb/host/ohci-sh.c | |||
@@ -68,7 +68,6 @@ static const struct hc_driver ohci_sh_hc_driver = { | |||
68 | */ | 68 | */ |
69 | .hub_status_data = ohci_hub_status_data, | 69 | .hub_status_data = ohci_hub_status_data, |
70 | .hub_control = ohci_hub_control, | 70 | .hub_control = ohci_hub_control, |
71 | .hub_irq_enable = ohci_rhsc_enable, | ||
72 | #ifdef CONFIG_PM | 71 | #ifdef CONFIG_PM |
73 | .bus_suspend = ohci_bus_suspend, | 72 | .bus_suspend = ohci_bus_suspend, |
74 | .bus_resume = ohci_bus_resume, | 73 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-sm501.c b/drivers/usb/host/ohci-sm501.c index 21b164e4abe..cff23637cfc 100644 --- a/drivers/usb/host/ohci-sm501.c +++ b/drivers/usb/host/ohci-sm501.c | |||
@@ -75,7 +75,6 @@ static const struct hc_driver ohci_sm501_hc_driver = { | |||
75 | */ | 75 | */ |
76 | .hub_status_data = ohci_hub_status_data, | 76 | .hub_status_data = ohci_hub_status_data, |
77 | .hub_control = ohci_hub_control, | 77 | .hub_control = ohci_hub_control, |
78 | .hub_irq_enable = ohci_rhsc_enable, | ||
79 | #ifdef CONFIG_PM | 78 | #ifdef CONFIG_PM |
80 | .bus_suspend = ohci_bus_suspend, | 79 | .bus_suspend = ohci_bus_suspend, |
81 | .bus_resume = ohci_bus_resume, | 80 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/ohci-ssb.c b/drivers/usb/host/ohci-ssb.c index 3660c83d80a..23fd6a886bd 100644 --- a/drivers/usb/host/ohci-ssb.c +++ b/drivers/usb/host/ohci-ssb.c | |||
@@ -81,7 +81,6 @@ static const struct hc_driver ssb_ohci_hc_driver = { | |||
81 | 81 | ||
82 | .hub_status_data = ohci_hub_status_data, | 82 | .hub_status_data = ohci_hub_status_data, |
83 | .hub_control = ohci_hub_control, | 83 | .hub_control = ohci_hub_control, |
84 | .hub_irq_enable = ohci_rhsc_enable, | ||
85 | #ifdef CONFIG_PM | 84 | #ifdef CONFIG_PM |
86 | .bus_suspend = ohci_bus_suspend, | 85 | .bus_suspend = ohci_bus_suspend, |
87 | .bus_resume = ohci_bus_resume, | 86 | .bus_resume = ohci_bus_resume, |
diff --git a/drivers/usb/host/u132-hcd.c b/drivers/usb/host/u132-hcd.c index 20ad3c48fcb..228f2b070f2 100644 --- a/drivers/usb/host/u132-hcd.c +++ b/drivers/usb/host/u132-hcd.c | |||
@@ -2934,16 +2934,6 @@ static int u132_start_port_reset(struct usb_hcd *hcd, unsigned port_num) | |||
2934 | return 0; | 2934 | return 0; |
2935 | } | 2935 | } |
2936 | 2936 | ||
2937 | static void u132_hub_irq_enable(struct usb_hcd *hcd) | ||
2938 | { | ||
2939 | struct u132 *u132 = hcd_to_u132(hcd); | ||
2940 | if (u132->going > 1) { | ||
2941 | dev_err(&u132->platform_dev->dev, "device has been removed %d\n" | ||
2942 | , u132->going); | ||
2943 | } else if (u132->going > 0) | ||
2944 | dev_err(&u132->platform_dev->dev, "device is being removed\n"); | ||
2945 | } | ||
2946 | |||
2947 | 2937 | ||
2948 | #ifdef CONFIG_PM | 2938 | #ifdef CONFIG_PM |
2949 | static int u132_bus_suspend(struct usb_hcd *hcd) | 2939 | static int u132_bus_suspend(struct usb_hcd *hcd) |
@@ -2995,7 +2985,6 @@ static struct hc_driver u132_hc_driver = { | |||
2995 | .bus_suspend = u132_bus_suspend, | 2985 | .bus_suspend = u132_bus_suspend, |
2996 | .bus_resume = u132_bus_resume, | 2986 | .bus_resume = u132_bus_resume, |
2997 | .start_port_reset = u132_start_port_reset, | 2987 | .start_port_reset = u132_start_port_reset, |
2998 | .hub_irq_enable = u132_hub_irq_enable, | ||
2999 | }; | 2988 | }; |
3000 | 2989 | ||
3001 | /* | 2990 | /* |