diff options
author | Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> | 2023-01-19 08:32:09 +0100 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2023-01-31 15:27:17 +0100 |
commit | 45cb70f99993f74bb46cef72158f59677dbea318 (patch) | |
tree | 5255e96eb4354a2de71b52c1b922b6a7e017c933 /drivers/soundwire/stream.c | |
parent | soundwire: stream: use consistent pattern for freeing buffers (diff) | |
download | linux-45cb70f99993f74bb46cef72158f59677dbea318.tar.xz linux-45cb70f99993f74bb46cef72158f59677dbea318.zip |
soundwire: bus: remove sdw_defer argument in sdw_transfer_defer()
There's no point in passing an argument that is a pointer to a bus
member. We can directly get the member and do an indirection when
needed.
This is a first step before simplifying the hardware-specific
callbacks further.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20230119073211.85979-3-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/stream.c')
-rw-r--r-- | drivers/soundwire/stream.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/soundwire/stream.c b/drivers/soundwire/stream.c index 9c13dbd2b26e..2e39587ed1de 100644 --- a/drivers/soundwire/stream.c +++ b/drivers/soundwire/stream.c @@ -684,8 +684,6 @@ static int sdw_bank_switch(struct sdw_bus *bus, int m_rt_count) if (!wr_msg) return -ENOMEM; - bus->defer_msg.msg = wr_msg; - wbuf = kzalloc(sizeof(*wbuf), GFP_KERNEL); if (!wbuf) { ret = -ENOMEM; @@ -713,7 +711,7 @@ static int sdw_bank_switch(struct sdw_bus *bus, int m_rt_count) multi_link = bus->multi_link && (m_rt_count >= bus->hw_sync_min_links); if (multi_link) - ret = sdw_transfer_defer(bus, wr_msg, &bus->defer_msg); + ret = sdw_transfer_defer(bus, wr_msg); else ret = sdw_transfer(bus, wr_msg); |