linux-stable/drivers/base
Andy Shevchenko fd6f7ad2fd driver core: return an error when dev_set_name() hasn't happened
The commit d21fdd07ce ("driver core: Return proper error code when
dev_set_name() fails") rewrote the logic of handling the dev_set_name()
error codes, but missed the point that initially set error value to
-EINVAL might be rewritten and hence the error path can't be triggered
at some circumstances. To fix this, make sure that error variable is
set to -EINVAL when other conditionals are false.

Reported-by: syzbot+bdfb03b1ec8b342c12cb@syzkaller.appspotmail.com
Fixes: d21fdd07ce ("driver core: Return proper error code when dev_set_name() fails")
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20230828145824.3895288-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-09-12 15:54:44 +02:00
..
firmware_loader firmware_loader: Fix a NULL vs IS_ERR() check 2023-05-31 20:31:00 +01:00
power PM: sleep: wakeirq: drop unused enable helpers 2023-07-24 09:51:51 +02:00
regmap regmap: Fix the type used for a bitmap pointer 2023-07-23 23:40:30 +01:00
test drivers: base: test: Add missing MODULE_* macros to root device tests 2023-08-16 19:01:29 +02:00
arch_numa.c
arch_topology.c
attribute_container.c
auxiliary.c
base.h
bus.c
cacheinfo.c drivers: base: cacheinfo: Update cpu_map_populated during CPU Hotplug 2023-05-31 20:36:47 +01:00
class.c driver core: class: properly reference count class_dev_iter() 2023-05-19 11:03:36 +01:00
component.c
container.c
core.c driver core: return an error when dev_set_name() hasn't happened 2023-09-12 15:54:44 +02:00
cpu.c Driver core changes for 6.6-rc1 2023-09-01 09:43:18 -07:00
dd.c driver core: Call dma_cleanup() on the test_remove path 2023-08-05 08:31:41 +02:00
devcoredump.c
devres.c drivers/base: use ARCH_DMA_MINALIGN instead of ARCH_KMALLOC_MINALIGN 2023-06-19 16:19:20 -07:00
devtmpfs.c
driver.c
firmware.c
hypervisor.c
init.c
isa.c isa: Remove unnecessary checks 2023-05-31 19:03:39 +01:00
Kconfig
Makefile
map.c
memory.c - An extensive rework of kexec and crash Kconfig from Eric DeVolder 2023-08-29 14:53:51 -07:00
module.c
node.c Driver core changes for 6.6-rc1 2023-09-01 09:43:18 -07:00
physical_location.c
physical_location.h
pinctrl.c
platform-msi.c
platform.c of: Move of_platform_register_reconfig_notifier() into DT core 2023-08-04 11:36:33 -06:00
property.c drivers: fwnode: fix fwnode_irq_get[_byname]() 2023-06-15 13:37:35 +02:00
soc.c
swnode.c
syscore.c
topology.c
trace.c
trace.h
transport_class.c