summaryrefslogtreecommitdiffstats
path: root/drivers/uwb/pal.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/uwb/pal.c')
-rw-r--r--drivers/uwb/pal.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/uwb/pal.c b/drivers/uwb/pal.c
index 605765124f5..99a19c19909 100644
--- a/drivers/uwb/pal.c
+++ b/drivers/uwb/pal.c
@@ -16,6 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <linux/kernel.h>
+#include <linux/debugfs.h>
#include <linux/uwb.h>
#include "uwb-internal.h"
@@ -54,6 +55,8 @@ int uwb_pal_register(struct uwb_pal *pal)
}
}
+ pal->debugfs_dir = uwb_dbg_create_pal_dir(pal);
+
mutex_lock(&rc->uwb_dev.mutex);
list_add(&pal->node, &rc->pals);
mutex_unlock(&rc->uwb_dev.mutex);
@@ -76,6 +79,8 @@ void uwb_pal_unregister(struct uwb_pal *pal)
list_del(&pal->node);
mutex_unlock(&rc->uwb_dev.mutex);
+ debugfs_remove(pal->debugfs_dir);
+
if (pal->device) {
sysfs_remove_link(&rc->uwb_dev.dev.kobj, pal->name);
sysfs_remove_link(&pal->device->kobj, "uwb_rc");