We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d67dada commit 2bf1c45Copy full SHA for 2bf1c45
drivers/regulator/core.c
@@ -5256,7 +5256,7 @@ static void rdev_init_debugfs(struct regulator_dev *rdev)
5256
}
5257
5258
rdev->debugfs = debugfs_create_dir(rname, debugfs_root);
5259
- if (!rdev->debugfs) {
+ if (IS_ERR(rdev->debugfs)) {
5260
rdev_warn(rdev, "Failed to create debugfs directory\n");
5261
return;
5262
@@ -6178,7 +6178,7 @@ static int __init regulator_init(void)
6178
ret = class_register(®ulator_class);
6179
6180
debugfs_root = debugfs_create_dir("regulator", NULL);
6181
- if (!debugfs_root)
+ if (IS_ERR(debugfs_root))
6182
pr_warn("regulator: Failed to create debugfs directory\n");
6183
6184
#ifdef CONFIG_DEBUG_FS
0 commit comments