mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-24 04:34:08 +08:00
OPP: fix error checking in opp_migrate_dentry()
Since commitff9fb72bc0
("debugfs: return error values, not NULL") changed return value of debugfs_rename() in error cases from %NULL to %ERR_PTR(-ERROR), we should also check error values instead of NULL. Fixes:ff9fb72bc0
("debugfs: return error values, not NULL") Signed-off-by: Qi Zheng <zhengqi.arch@bytedance.com> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
This commit is contained in:
parent
68d8ad3bd9
commit
eca4c0eea5
@ -235,7 +235,7 @@ static void opp_migrate_dentry(struct opp_device *opp_dev,
|
||||
|
||||
dentry = debugfs_rename(rootdir, opp_dev->dentry, rootdir,
|
||||
opp_table->dentry_name);
|
||||
if (!dentry) {
|
||||
if (IS_ERR(dentry)) {
|
||||
dev_err(dev, "%s: Failed to rename link from: %s to %s\n",
|
||||
__func__, dev_name(opp_dev->dev), dev_name(dev));
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user