driver core: Move driver_sysfs_remove() after driver_sysfs_add()
authorLu Baolu <baolu.lu@linux.intel.com>
Fri, 31 Dec 2021 03:39:00 +0000 (11:39 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 6 Jan 2022 14:47:41 +0000 (15:47 +0100)
commit885e50253bfd6750327a265405461496d6af1639
tree39077d6c96bab42fb0c47b939d71c05b30660872
parent3407d826c18d9aed3c51545cc26ff9a2fda65463
driver core: Move driver_sysfs_remove() after driver_sysfs_add()

The driver_sysfs_remove() should be called after driver_sysfs_add() in
really_probe(). The out-of-order driver_sysfs_remove() tries to remove
some nonexistent nodes under the device and driver sysfs nodes. This is
allowed, hence this change doesn't fix any problem, just a cleanup.

Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Link: https://lore.kernel.org/r/20211231033901.2168664-2-baolu.lu@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/dd.c