linux/drivers/soundwire
Rander Wang 870533403f soundwire: stream: fix memory leak in stream config error path
[ Upstream commit 48f17f96a81763c7c8bf5500460a359b9939359f ]

When stream config is failed, master runtime will release all
slave runtime in the slave_rt_list, but slave runtime is not
added to the list at this time. This patch frees slave runtime
in the config error path to fix the memory leak.

Fixes: 89e590535f ("soundwire: Add support for SoundWire stream management")
Signed-off-by: Rander Wang <rander.wang@intel.com>
Reviewed-by: Keyon Jie <yang.jie@intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20210331004610.12242-1-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-05-14 09:44:19 +02:00
..
bus_type.c
bus.c soundwire: bus: Fix device found flag correctly 2021-05-14 09:44:19 +02:00
bus.h
cadence_master.c soundwire: cadence: fix ACK/NAK handling 2021-03-04 10:26:36 +01:00
cadence_master.h soundwire: intel/cadence: fix startup sequence 2020-10-01 13:17:13 +02:00
debugfs.c
intel_init.c
intel.c soundwire: intel/cadence: fix startup sequence 2020-10-01 13:17:13 +02:00
intel.h
Kconfig
Makefile
mipi_disco.c
slave.c
stream.c soundwire: stream: fix memory leak in stream config error path 2021-05-14 09:44:19 +02:00