aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2005-06-21 00:15:16 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-10-28 19:47:46 -0400
commit72adaa962741e8e910300b66bb123b1a9c31a8a8 (patch)
tree3847dca1d8dadc31df3c7e3275cac8592603be33 /drivers/usb/core
parent54a5c4cd2e4ec0b27c2c3731727f52591456086c (diff)
[PATCH] USB: convert usbmon to use usb notifiers
This also removes 2 usbmon callbacks. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/core')
-rw-r--r--drivers/usb/core/hcd.c2
-rw-r--r--drivers/usb/core/hcd.h16
2 files changed, 0 insertions, 18 deletions
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c
index 16790ad0e2e4..e8f2b8d8f14d 100644
--- a/drivers/usb/core/hcd.c
+++ b/drivers/usb/core/hcd.c
@@ -793,7 +793,6 @@ static int usb_register_bus(struct usb_bus *bus)
793 up (&usb_bus_list_lock); 793 up (&usb_bus_list_lock);
794 794
795 usb_notify_add_bus(bus); 795 usb_notify_add_bus(bus);
796 usbmon_notify_bus_add (bus);
797 796
798 dev_info (bus->controller, "new USB bus registered, assigned bus number %d\n", bus->busnum); 797 dev_info (bus->controller, "new USB bus registered, assigned bus number %d\n", bus->busnum);
799 return 0; 798 return 0;
@@ -821,7 +820,6 @@ static void usb_deregister_bus (struct usb_bus *bus)
821 up (&usb_bus_list_lock); 820 up (&usb_bus_list_lock);
822 821
823 usb_notify_remove_bus(bus); 822 usb_notify_remove_bus(bus);
824 usbmon_notify_bus_remove (bus);
825 823
826 clear_bit (bus->busnum, busmap.busmap); 824 clear_bit (bus->busnum, busmap.busmap);
827 825
diff --git a/drivers/usb/core/hcd.h b/drivers/usb/core/hcd.h
index cc33886260cd..a5d92943ff95 100644
--- a/drivers/usb/core/hcd.h
+++ b/drivers/usb/core/hcd.h
@@ -421,8 +421,6 @@ struct usb_mon_operations {
421 void (*urb_submit_error)(struct usb_bus *bus, struct urb *urb, int err); 421 void (*urb_submit_error)(struct usb_bus *bus, struct urb *urb, int err);
422 void (*urb_complete)(struct usb_bus *bus, struct urb *urb); 422 void (*urb_complete)(struct usb_bus *bus, struct urb *urb);
423 /* void (*urb_unlink)(struct usb_bus *bus, struct urb *urb); */ 423 /* void (*urb_unlink)(struct usb_bus *bus, struct urb *urb); */
424 void (*bus_add)(struct usb_bus *bus);
425 void (*bus_remove)(struct usb_bus *bus);
426}; 424};
427 425
428extern struct usb_mon_operations *mon_ops; 426extern struct usb_mon_operations *mon_ops;
@@ -445,18 +443,6 @@ static inline void usbmon_urb_complete(struct usb_bus *bus, struct urb *urb)
445 if (bus->monitored) 443 if (bus->monitored)
446 (*mon_ops->urb_complete)(bus, urb); 444 (*mon_ops->urb_complete)(bus, urb);
447} 445}
448
449static inline void usbmon_notify_bus_add(struct usb_bus *bus)
450{
451 if (mon_ops)
452 (*mon_ops->bus_add)(bus);
453}
454
455static inline void usbmon_notify_bus_remove(struct usb_bus *bus)
456{
457 if (mon_ops)
458 (*mon_ops->bus_remove)(bus);
459}
460 446
461int usb_mon_register(struct usb_mon_operations *ops); 447int usb_mon_register(struct usb_mon_operations *ops);
462void usb_mon_deregister(void); 448void usb_mon_deregister(void);
@@ -467,8 +453,6 @@ static inline void usbmon_urb_submit(struct usb_bus *bus, struct urb *urb) {}
467static inline void usbmon_urb_submit_error(struct usb_bus *bus, struct urb *urb, 453static inline void usbmon_urb_submit_error(struct usb_bus *bus, struct urb *urb,
468 int error) {} 454 int error) {}
469static inline void usbmon_urb_complete(struct usb_bus *bus, struct urb *urb) {} 455static inline void usbmon_urb_complete(struct usb_bus *bus, struct urb *urb) {}
470static inline void usbmon_notify_bus_add(struct usb_bus *bus) {}
471static inline void usbmon_notify_bus_remove(struct usb_bus *bus) {}
472 456
473#endif /* CONFIG_USB_MON */ 457#endif /* CONFIG_USB_MON */
474 458