Patch "driver core: Release all resources during unbind before updating device links" has been added to the 5.15-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

    driver core: Release all resources during unbind before updating device links

to the 5.15-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:
     driver-core-release-all-resources-during-unbind-befo.patch
and it can be found in the queue-5.15 subdirectory.

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



commit 5ed42eeb1f404d6f001d14a3b0351142aae3119c
Author: Saravana Kannan <saravanak@xxxxxxxxxx>
Date:   Tue Oct 17 18:38:50 2023 -0700

    driver core: Release all resources during unbind before updating device links
    
    [ Upstream commit 2e84dc37920012b458e9458b19fc4ed33f81bc74 ]
    
    This commit fixes a bug in commit 9ed9895370ae ("driver core: Functional
    dependencies tracking support") where the device link status was
    incorrectly updated in the driver unbind path before all the device's
    resources were released.
    
    Fixes: 9ed9895370ae ("driver core: Functional dependencies tracking support")
    Cc: stable <stable@xxxxxxxxxx>
    Reported-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
    Closes: https://lore.kernel.org/all/20231014161721.f4iqyroddkcyoefo@xxxxxxxxxxxxxx/
    Signed-off-by: Saravana Kannan <saravanak@xxxxxxxxxx>
    Cc: Thierry Reding <thierry.reding@xxxxxxxxx>
    Cc: Yang Yingliang <yangyingliang@xxxxxxxxxx>
    Cc: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
    Cc: Mark Brown <broonie@xxxxxxxxxx>
    Cc: Matti Vaittinen <mazziesaccount@xxxxxxxxx>
    Cc: James Clark <james.clark@xxxxxxx>
    Acked-by: "Rafael J. Wysocki" <rafael@xxxxxxxxxx>
    Tested-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
    Acked-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
    Link: https://lore.kernel.org/r/20231018013851.3303928-1-saravanak@xxxxxxxxxx
    Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/base/dd.c b/drivers/base/dd.c
index 394ef41d732a9..5f521def6b7c0 100644
--- a/drivers/base/dd.c
+++ b/drivers/base/dd.c
@@ -1230,8 +1230,8 @@ static void __device_release_driver(struct device *dev, struct device *parent)
 		if (dev->bus && dev->bus->dma_cleanup)
 			dev->bus->dma_cleanup(dev);
 
-		device_links_driver_cleanup(dev);
 		device_unbind_cleanup(dev);
+		device_links_driver_cleanup(dev);
 
 		klist_remove(&dev->p->knode_driver);
 		device_pm_check_callbacks(dev);



[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