aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorVikram Pandita <vikram.pandita@ti.com>2009-02-21 18:31:44 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2009-02-27 17:40:51 -0500
commite747951240b9f820b94fd5582663c66d798c8fd1 (patch)
treeb3f53e4de8fa8f0cfc9621075393dcf72bf4d71e /drivers/usb
parent5c23c9078f8e3476982409b1075b54c8cd65e82c (diff)
USB: musb: fix srp sysfs entry deletion
The SRP sysfs attribute is dependent on gadget mode; any gadget may support SRP. But "rmmod musb_hdrc" didn't remove that attribute; fix. Signed-off-by: Vikram Pandita <vikram.pandita@ti.com> Acked-by: Felipe Balbi <me@felipebalbi.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/musb/musb_core.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index 60cbaec1aa41..af77e4659006 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -1816,7 +1816,7 @@ static void musb_free(struct musb *musb)
1816#ifdef CONFIG_SYSFS 1816#ifdef CONFIG_SYSFS
1817 device_remove_file(musb->controller, &dev_attr_mode); 1817 device_remove_file(musb->controller, &dev_attr_mode);
1818 device_remove_file(musb->controller, &dev_attr_vbus); 1818 device_remove_file(musb->controller, &dev_attr_vbus);
1819#ifdef CONFIG_USB_MUSB_OTG 1819#ifdef CONFIG_USB_GADGET_MUSB_HDRC
1820 device_remove_file(musb->controller, &dev_attr_srp); 1820 device_remove_file(musb->controller, &dev_attr_srp);
1821#endif 1821#endif
1822#endif 1822#endif
@@ -2064,7 +2064,7 @@ fail2:
2064#ifdef CONFIG_SYSFS 2064#ifdef CONFIG_SYSFS
2065 device_remove_file(musb->controller, &dev_attr_mode); 2065 device_remove_file(musb->controller, &dev_attr_mode);
2066 device_remove_file(musb->controller, &dev_attr_vbus); 2066 device_remove_file(musb->controller, &dev_attr_vbus);
2067#ifdef CONFIG_USB_MUSB_OTG 2067#ifdef CONFIG_USB_GADGET_MUSB_HDRC
2068 device_remove_file(musb->controller, &dev_attr_srp); 2068 device_remove_file(musb->controller, &dev_attr_srp);
2069#endif 2069#endif
2070#endif 2070#endif