diff mbox series

ray_cs: use remove_proc_subtree to simplify procfs code

Message ID 20190306114812.30480-1-yuehaibing@huawei.com (mailing list archive)
State Accepted
Commit 3b6edcb3fffeb9af00a7e0d21636ba2d95ef9987
Delegated to: Kalle Valo
Headers show
Series ray_cs: use remove_proc_subtree to simplify procfs code | expand

Commit Message

Yue Haibing March 6, 2019, 11:48 a.m. UTC
From: YueHaibing <yuehaibing@huawei.com>

Use remove_proc_subtree to remove the whole subtree

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/net/wireless/ray_cs.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

Comments

Kalle Valo April 25, 2019, 4:39 p.m. UTC | #1
Yue Haibing <yuehaibing@huawei.com> wrote:

> From: YueHaibing <yuehaibing@huawei.com>
> 
> Use remove_proc_subtree to remove the whole subtree
> 
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Patch applied to wireless-drivers-next.git, thanks.

3b6edcb3fffe ray_cs: use remove_proc_subtree to simplify procfs code
diff mbox series

Patch

diff --git a/drivers/net/wireless/ray_cs.c b/drivers/net/wireless/ray_cs.c
index d561659..ee4d810 100644
--- a/drivers/net/wireless/ray_cs.c
+++ b/drivers/net/wireless/ray_cs.c
@@ -2820,11 +2820,7 @@  static void __exit exit_ray_cs(void)
 	pr_debug("ray_cs: cleanup_module\n");
 
 #ifdef CONFIG_PROC_FS
-	remove_proc_entry("driver/ray_cs/ray_cs", NULL);
-	remove_proc_entry("driver/ray_cs/essid", NULL);
-	remove_proc_entry("driver/ray_cs/net_type", NULL);
-	remove_proc_entry("driver/ray_cs/translate", NULL);
-	remove_proc_entry("driver/ray_cs", NULL);
+	remove_proc_subtree("driver/ray_cs", NULL);
 #endif
 
 	pcmcia_unregister_driver(&ray_driver);