OSDN Git Service

soundwire: stream: introduce sdw_slave_rt_find() helper
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Wed, 26 Jan 2022 01:17:13 +0000 (09:17 +0800)
committerVinod Koul <vkoul@kernel.org>
Fri, 11 Feb 2022 06:47:55 +0000 (12:17 +0530)
commit5e1df5431f5b68f178c016e7015fb244e9510370
tree2ff515af0e499c4705ad90c625845afbe5770803
parentac3bc88cc56e2712555adc86ee5b2f3a861ffb1e
soundwire: stream: introduce sdw_slave_rt_find() helper

Before we split the alloc and config steps, we need a helper to find
the Slave runtime for a stream. The helper is based on the search loop
in sdw_slave_rt_free(), which can now be simplified.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20220126011715.28204-18-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/soundwire/stream.c