[Sound-open-firmware] [PATCH] component: make sure we can enter the start from paused state
Liam Girdwood
liam.r.girdwood at linux.intel.com
Thu Oct 5 23:09:23 CEST 2017
Fix state checking to make sure start can be entered after pause.
Signed-off-by: Liam Girdwood <liam.r.girdwood at linux.intel.com>
---
src/audio/component.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/audio/component.c b/src/audio/component.c
index ec170c6..80311e3 100644
--- a/src/audio/component.c
+++ b/src/audio/component.c
@@ -122,7 +122,8 @@ int comp_set_state(struct comp_dev *dev, int cmd)
switch (cmd) {
case COMP_CMD_START:
- if (dev->state == COMP_STATE_PREPARE) {
+ if (dev->state == COMP_STATE_PREPARE ||
+ dev->state == COMP_STATE_PAUSED) {
dev->state = COMP_STATE_ACTIVE;
} else {
trace_comp_error("CES");
--
2.11.0
More information about the Sound-open-firmware
mailing list