Patch "OPP: fix error checking in opp_migrate_dentry()" has been added to the 5.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    OPP: fix error checking in opp_migrate_dentry()

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     opp-fix-error-checking-in-opp_migrate_dentry.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 2180e4f8fda20905b634bcbc68ce474e2acd8f60
Author: Qi Zheng <zhengqi.arch@xxxxxxxxxxxxx>
Date:   Wed Feb 8 12:00:37 2023 +0800

    OPP: fix error checking in opp_migrate_dentry()
    
    [ Upstream commit eca4c0eea53432ec4b711b2a8ad282cbad231b4f ]
    
    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@xxxxxxxxxxxxx>
    Signed-off-by: Viresh Kumar <viresh.kumar@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/opp/debugfs.c b/drivers/opp/debugfs.c
index 609665e339b6b..c7647410316e6 100644
--- a/drivers/opp/debugfs.c
+++ b/drivers/opp/debugfs.c
@@ -162,7 +162,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;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux