]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
ieee802154: remove unecessary condition check before debugfs_remove_recursive
authorzhong jiang <zhongjiang@huawei.com>
Sat, 8 Sep 2018 13:44:08 +0000 (21:44 +0800)
committerStefan Schmidt <stefan@datenfreihafen.org>
Fri, 21 Sep 2018 12:53:04 +0000 (14:53 +0200)
debugfs_remove_recursive has taken IS_ERR_OR_NULL into account. So just
remove the condition check before debugfs_remove_recursive.

Signed-off-by: zhong jiang <zhongjiang@huawei.com>
Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
drivers/net/ieee802154/adf7242.c

index 23a52b9293f35eaec1d71063305a029ba466d819..cd1d8faccca5fb36b488312d734d5e42cebb7b1a 100644 (file)
@@ -1308,8 +1308,7 @@ static int adf7242_remove(struct spi_device *spi)
 {
        struct adf7242_local *lp = spi_get_drvdata(spi);
 
-       if (!IS_ERR_OR_NULL(lp->debugfs_root))
-               debugfs_remove_recursive(lp->debugfs_root);
+       debugfs_remove_recursive(lp->debugfs_root);
 
        cancel_delayed_work_sync(&lp->work);
        destroy_workqueue(lp->wqueue);