OPP: fix error checking in opp_migrate_dentry()
authorQi Zheng <zhengqi.arch@bytedance.com>
Wed, 8 Feb 2023 04:00:37 +0000 (12:00 +0800)
committerViresh Kumar <viresh.kumar@linaro.org>
Wed, 8 Feb 2023 05:10:59 +0000 (10:40 +0530)
commiteca4c0eea53432ec4b711b2a8ad282cbad231b4f
treedfebb4685e5f35a0168ab081f5cca2379b842ac0
parent68d8ad3bd9c397f2bf009368cb13e48cb91ea018
OPP: fix error checking in opp_migrate_dentry()

Since commit ff9fb72bc077 ("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: ff9fb72bc077 ("debugfs: return error values, not NULL")
Signed-off-by: Qi Zheng <zhengqi.arch@bytedance.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
drivers/opp/debugfs.c