summaryrefslogtreecommitdiff
path: root/drivers/net/netdevsim/health.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/netdevsim/health.c')
-rw-r--r--drivers/net/netdevsim/health.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/netdevsim/health.c b/drivers/net/netdevsim/health.c
index 9aa637d162eb7..30595b1299bd0 100644
--- a/drivers/net/netdevsim/health.c
+++ b/drivers/net/netdevsim/health.c
@@ -285,8 +285,8 @@ int nsim_dev_health_init(struct nsim_dev *nsim_dev, struct devlink *devlink)
}
health->ddir = debugfs_create_dir("health", nsim_dev->ddir);
- if (IS_ERR_OR_NULL(health->ddir)) {
- err = PTR_ERR_OR_ZERO(health->ddir) ?: -EINVAL;
+ if (IS_ERR(health->ddir)) {
+ err = PTR_ERR(health->ddir);
goto err_dummy_reporter_destroy;
}