mirror of https://github.com/thesofproject/sof.git
topology2: Add pcm capabilities class
Add pcm capabilities class definition, pcm capabilities object can be instantiated as: Object.PCM.pcm_caps."DIRECTION" { name "Headset" direction "playback" formats "S32_LE,S24_LE,S16_LE" rate_min 48000 rate_max 48000 channels_min 2 channels_max 2 periods_min 2 } Signed-off-by: Ranjani Sridharan <ranjani.sidharan@linux.intel.com> Signed-off-by: Chao Song <chao.song@linux.intel.com>
This commit is contained in:
parent
ae80d3b8af
commit
256bc69f31
|
@ -0,0 +1,92 @@
|
||||||
|
#
|
||||||
|
# PCM Capabilities Class definition. All attributes defined herein are
|
||||||
|
# namespaced by alsatplg to "Object.PCM.pcm_caps.DIRECTION.attribute_name".
|
||||||
|
#
|
||||||
|
# Usage: PCM object can be instantiated as:
|
||||||
|
#
|
||||||
|
# Object.PCM.pcm_caps."DIRECTION" {
|
||||||
|
# name "Headset"
|
||||||
|
# direction "playback"
|
||||||
|
# formats "S32_LE,S24_LE,S16_LE"
|
||||||
|
# rate_min 48000
|
||||||
|
# rate_max 48000
|
||||||
|
# channels_min 2
|
||||||
|
# channels_max 2
|
||||||
|
# periods_min 2
|
||||||
|
# }
|
||||||
|
#
|
||||||
|
# where DIRECTION is the unique stream direction for the pcm_caps object within
|
||||||
|
# the same alsaconf node (normally, pcm object).
|
||||||
|
|
||||||
|
Class.PCM."pcm_caps" {
|
||||||
|
#
|
||||||
|
# Argument used to construct PCM Capabilities
|
||||||
|
#
|
||||||
|
DefineAttribute."name" {
|
||||||
|
type "string"
|
||||||
|
}
|
||||||
|
|
||||||
|
DefineAttribute."direction" {
|
||||||
|
type "string"
|
||||||
|
!valid_values [
|
||||||
|
playback
|
||||||
|
capture
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
DefineAttribute."formats" {
|
||||||
|
type "string"
|
||||||
|
}
|
||||||
|
|
||||||
|
DefineAttribute."rates" {
|
||||||
|
type "string"
|
||||||
|
}
|
||||||
|
|
||||||
|
DefineAttribute."sigbits" {}
|
||||||
|
|
||||||
|
DefineAttribute."rate_min" {}
|
||||||
|
|
||||||
|
DefineAttribute."rate_max" {}
|
||||||
|
|
||||||
|
DefineAttribute."channels_min" {}
|
||||||
|
|
||||||
|
DefineAttribute."channels_max" {}
|
||||||
|
|
||||||
|
DefineAttribute."periods_min" {}
|
||||||
|
|
||||||
|
DefineAttribute."periods_max" {}
|
||||||
|
|
||||||
|
DefineAttribute."period_size_min" {}
|
||||||
|
|
||||||
|
DefineAttribute."period_size_max" {}
|
||||||
|
|
||||||
|
DefineAttribute."buffer_size_min" {}
|
||||||
|
|
||||||
|
DefineAttribute."buffer_size_max" {}
|
||||||
|
|
||||||
|
attributes {
|
||||||
|
!constructor [
|
||||||
|
"name"
|
||||||
|
"direction"
|
||||||
|
]
|
||||||
|
|
||||||
|
#
|
||||||
|
# pcm_caps objects instantiated within the same alsaconf node must have unique
|
||||||
|
# direction attribute
|
||||||
|
#
|
||||||
|
unique "direction"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Default attribute values for PCM capabilities
|
||||||
|
formats "S32_LE,S24_LE,S16_LE"
|
||||||
|
rate_min 48000
|
||||||
|
rate_max 48000
|
||||||
|
periods_min 2
|
||||||
|
periods_max 16
|
||||||
|
channels_min 2
|
||||||
|
channels_max 2
|
||||||
|
period_size_min 192
|
||||||
|
period_size_max 16384
|
||||||
|
buffer_size_min 65536
|
||||||
|
buffer_size_max 65536
|
||||||
|
}
|
Loading…
Reference in New Issue