Skip to content

Commit 76910e9

Browse files
committed
topology2: Add new token 'playback_pause_supported' and set it true for nocodec only
We need to face with reality that the pause/resume is a feature that is not well tested (end users are using audio via audio servers and they don't use pause/resume) causing constant issues with no real life benefit: With IPC4 multiple pause/resume will make the delay reporting to be exponentially shoot out, making the reported delay to be unusable. Looks like suspend/resume with paused stream has been broken for a long time and just got noticed (since it was not tested). Add a new token to allow selected PCMs to advertise pause support and keep it false by default. The kernel side will allow ignoring the flag to keep the pause advertised for continued testing while protecting accidental use of it by users. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: thesofproject/linux#5035
1 parent 0bda13d commit 76910e9

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

tools/topology/topology2/include/common/pcm.conf

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,16 @@ Class.PCM."pcm" {
4444
token_ref "stream.bool"
4545
}
4646

47+
DefineAttribute."playback_pause_supported" {
48+
# Token reference and type
49+
token_ref "stream.bool"
50+
}
51+
52+
DefineAttribute."capture_pause_supported" {
53+
# Token reference and type
54+
token_ref "stream.bool"
55+
}
56+
4757
attributes {
4858
!constructor [
4959
"name"
@@ -60,4 +70,6 @@ Class.PCM."pcm" {
6070

6171
# Default values for PCM attributes
6272
compress "false"
73+
playback_pause_supported "false"
74+
capture_pause_supported "false"
6375
}

tools/topology/topology2/include/common/tokens.conf

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,10 @@ Object.Base.VendorToken {
129129

130130
"13" {
131131
name "stream"
132-
playback_compatible_d0i3 "1200"
133-
capture_compatible_d0i3 "1201"
132+
playback_compatible_d0i3 1200
133+
capture_compatible_d0i3 1201
134+
playback_pause_supported 1202
135+
capture_pause_supported 1203
134136
}
135137

136138
"14" {

0 commit comments

Comments
 (0)