* [PATCH] soundwire: take in count the bandwidth of a prepared stream
@ 2025-03-10 7:36 Bard Liao
2025-03-10 20:24 ` Vinod Koul
0 siblings, 1 reply; 2+ messages in thread
From: Bard Liao @ 2025-03-10 7:36 UTC (permalink / raw)
To: linux-sound, vkoul
Cc: vinod.koul, linux-kernel, pierre-louis.bossart, bard.liao
When a stream's state is marked as prepared, it is ready for
playback/capture. Therefore, we need to include the stream's bandwidth
when we calculate the required bandwidth of a bus.
Fixes: 25befdf32aa40 ("soundwire: generic_bandwidth_allocation: count the bandwidth of active streams only")
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://github.com/thesofproject/linux/issues/5334
Reviewed-by: Richard Fitzgerald <rf@opensource.cirrus.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
---
drivers/soundwire/generic_bandwidth_allocation.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/soundwire/generic_bandwidth_allocation.c b/drivers/soundwire/generic_bandwidth_allocation.c
index b646c2ffe84a..1cfaccf43eac 100644
--- a/drivers/soundwire/generic_bandwidth_allocation.c
+++ b/drivers/soundwire/generic_bandwidth_allocation.c
@@ -237,10 +237,11 @@ static int sdw_compute_group_params(struct sdw_bus *bus,
continue;
} else {
/*
- * Include runtimes with running (ENABLED state) and paused (DISABLED state)
- * streams
+ * Include runtimes with running (ENABLED/PREPARED state) and
+ * paused (DISABLED state) streams
*/
if (m_rt->stream->state != SDW_STREAM_ENABLED &&
+ m_rt->stream->state != SDW_STREAM_PREPARED &&
m_rt->stream->state != SDW_STREAM_DISABLED)
continue;
}
--
2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: [PATCH] soundwire: take in count the bandwidth of a prepared stream
2025-03-10 7:36 [PATCH] soundwire: take in count the bandwidth of a prepared stream Bard Liao
@ 2025-03-10 20:24 ` Vinod Koul
0 siblings, 0 replies; 2+ messages in thread
From: Vinod Koul @ 2025-03-10 20:24 UTC (permalink / raw)
To: linux-sound, Bard Liao
Cc: vinod.koul, linux-kernel, pierre-louis.bossart, bard.liao
On Mon, 10 Mar 2025 15:36:53 +0800, Bard Liao wrote:
> When a stream's state is marked as prepared, it is ready for
> playback/capture. Therefore, we need to include the stream's bandwidth
> when we calculate the required bandwidth of a bus.
>
>
Applied, thanks!
[1/1] soundwire: take in count the bandwidth of a prepared stream
commit: 08ae0d61c3d79bb5d52ae30ad4fc12442e966a23
Best regards,
--
~Vinod
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-03-10 20:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-10 7:36 [PATCH] soundwire: take in count the bandwidth of a prepared stream Bard Liao
2025-03-10 20:24 ` Vinod Koul
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®