OpenCloudOS-Kernel/drivers/net/wwan/iosm
Aleksandr Mishin 040d938487 net: wwan: iosm: Fix tainted pointer delete is case of region creation fail
[ Upstream commit b0c9a26435413b81799047a7be53255640432547 ]

In case of region creation fail in ipc_devlink_create_region(), previously
created regions delete process starts from tainted pointer which actually
holds error code value.
Fix this bug by decreasing region index before delete.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: 4dcd183fbd ("net: wwan: iosm: devlink registration")
Signed-off-by: Aleksandr Mishin <amishin@t-argos.ru>
Acked-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://lore.kernel.org/r/20240604082500.20769-1-amishin@t-argos.ru
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-06-21 14:38:18 +02:00
..
Makefile
iosm_ipc_chnl_cfg.c
iosm_ipc_chnl_cfg.h
iosm_ipc_coredump.c
iosm_ipc_coredump.h
iosm_ipc_debugfs.c
iosm_ipc_debugfs.h
iosm_ipc_devlink.c net: wwan: iosm: Fix tainted pointer delete is case of region creation fail 2024-06-21 14:38:18 +02:00
iosm_ipc_devlink.h
iosm_ipc_flash.c
iosm_ipc_flash.h
iosm_ipc_imem.c Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_imem.h Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_imem_ops.c net: wwan: iosm: fix NULL pointer dereference when removing device 2023-05-17 12:58:42 +01:00
iosm_ipc_imem_ops.h net: wwan: iosm: fix NULL pointer dereference when removing device 2023-05-17 12:58:42 +01:00
iosm_ipc_irq.c
iosm_ipc_irq.h
iosm_ipc_mmio.c
iosm_ipc_mmio.h
iosm_ipc_mux.c
iosm_ipc_mux.h net: wwan: iosm: clean up unused struct members 2023-05-10 19:15:01 -07:00
iosm_ipc_mux_codec.c net: wwan: iosm: Convert single instance struct member to flexible array 2023-06-22 11:27:47 +02:00
iosm_ipc_mux_codec.h net: wwan: iosm: Convert single instance struct member to flexible array 2023-06-22 11:27:47 +02:00
iosm_ipc_pcie.c Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_pcie.h
iosm_ipc_pm.c
iosm_ipc_pm.h
iosm_ipc_port.c Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_port.h
iosm_ipc_protocol.c
iosm_ipc_protocol.h
iosm_ipc_protocol_ops.c
iosm_ipc_protocol_ops.h
iosm_ipc_task_queue.c
iosm_ipc_task_queue.h
iosm_ipc_trace.c Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_trace.h
iosm_ipc_uevent.c
iosm_ipc_uevent.h
iosm_ipc_wwan.c Revert "net: wwan: iosm: enable runtime pm support for 7560" 2023-10-18 11:08:52 +01:00
iosm_ipc_wwan.h