提交 c9359f41 编写于 作者: H Heikki Krogerus 提交者: Greg Kroah-Hartman

usb: typec: fusb302: Fix debugfs issue

Removing the "fusb302" debugfs directory when unloading
the driver. That allows the driver to be loaded more then
one time. The directory will not get actually removed until
it is empty, so only after the last instance has been
removed.

This fixes an issue where the driver can't be re-loaded if
it has been unloaded as the "fusb302" debugfs directory
already exists.

Fixes: 76f0c53d ("usb: typec: fusb302: Move out of staging")
Signed-off-by: NHeikki Krogerus <heikki.krogerus@linux.intel.com>
Reviewed-by: NGuenter Roeck <linux@roeck-us.net>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 7c8d4456
...@@ -234,6 +234,7 @@ static int fusb302_debugfs_init(struct fusb302_chip *chip) ...@@ -234,6 +234,7 @@ static int fusb302_debugfs_init(struct fusb302_chip *chip)
static void fusb302_debugfs_exit(struct fusb302_chip *chip) static void fusb302_debugfs_exit(struct fusb302_chip *chip)
{ {
debugfs_remove(chip->dentry); debugfs_remove(chip->dentry);
debugfs_remove(rootdir);
} }
#else #else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册