diff options
author | Alexander Shishkin <alexander.shishkin@linux.intel.com> | 2013-03-30 12:53:53 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-30 08:08:39 -0700 |
commit | adf0f735e61aae5ff615bb0301d9fff29b589a5c (patch) | |
tree | b55bd577247cbcf5f3a297dfe263c29c2b4678d0 /drivers/usb/chipidea/core.c | |
parent | c8e333a3b17050800a5aa536feb628f18d2a01a2 (diff) | |
download | lwn-adf0f735e61aae5ff615bb0301d9fff29b589a5c.tar.gz lwn-adf0f735e61aae5ff615bb0301d9fff29b589a5c.zip |
usb: chipidea: move debug files creation/removal to the core
Create and remove debugfs entries in hdrc probe/remove instead of
start/stop of the device controller. Gadget specific will not export
anything while the controller is in host mode.
Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/chipidea/core.c')
-rw-r--r-- | drivers/usb/chipidea/core.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c index 5270156591e0..a7ce1b8c8fd7 100644 --- a/drivers/usb/chipidea/core.c +++ b/drivers/usb/chipidea/core.c @@ -455,8 +455,11 @@ static int ci_hdrc_probe(struct platform_device *pdev) if (ci->is_otg) hw_write(ci, OP_OTGSC, OTGSC_IDIE, OTGSC_IDIE); - return ret; + ret = dbg_create_files(ci); + if (!ret) + return 0; + free_irq(ci->irq, ci); stop: ci_role_stop(ci); rm_wq: @@ -470,6 +473,7 @@ static int ci_hdrc_remove(struct platform_device *pdev) { struct ci13xxx *ci = platform_get_drvdata(pdev); + dbg_remove_files(ci); flush_workqueue(ci->wq); destroy_workqueue(ci->wq); free_irq(ci->irq, ci); |