mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 14:51:00 +07:00
usb: musb: remove dead code from procfs
When removing the procfs file, I forgot to remove some code that created and removed that file. Here's a patch to fix it. Ideally this patch will be melded into the patch removing the procfs file, don't know if it's possible still. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
458e6a511f
commit
28c2c51c07
@ -2055,15 +2055,6 @@ musb_init_controller(struct device *dev, int nIrq, void __iomem *ctrl)
|
||||
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
fail:
|
||||
if (musb->clock)
|
||||
clk_put(musb->clock);
|
||||
device_init_wakeup(dev, 0);
|
||||
musb_free(musb);
|
||||
return status;
|
||||
|
||||
#ifdef CONFIG_SYSFS
|
||||
status = device_create_file(dev, &dev_attr_mode);
|
||||
status = device_create_file(dev, &dev_attr_vbus);
|
||||
@ -2072,12 +2063,31 @@ musb_init_controller(struct device *dev, int nIrq, void __iomem *ctrl)
|
||||
#endif /* CONFIG_USB_GADGET_MUSB_HDRC */
|
||||
status = 0;
|
||||
#endif
|
||||
if (status)
|
||||
goto fail2;
|
||||
|
||||
return 0;
|
||||
|
||||
fail2:
|
||||
#ifdef CONFIG_SYSFS
|
||||
device_remove_file(musb->controller, &dev_attr_mode);
|
||||
device_remove_file(musb->controller, &dev_attr_vbus);
|
||||
#ifdef CONFIG_USB_MUSB_OTG
|
||||
device_remove_file(musb->controller, &dev_attr_srp);
|
||||
#endif
|
||||
#endif
|
||||
musb_platform_exit(musb);
|
||||
fail:
|
||||
dev_err(musb->controller,
|
||||
"musb_init_controller failed with status %d\n", status);
|
||||
|
||||
if (musb->clock)
|
||||
clk_put(musb->clock);
|
||||
device_init_wakeup(dev, 0);
|
||||
musb_free(musb);
|
||||
|
||||
return status;
|
||||
|
||||
fail2:
|
||||
musb_platform_exit(musb);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------------*/
|
||||
|
Loading…
Reference in New Issue
Block a user