From 7ffdb475ede7a5bff250823249e7247e604d746d Mon Sep 17 00:00:00 2001 From: Prabhu Annabathula <prabhu.annabathula@motorola.com> Date: Fri, 26 Sep 2014 12:34:47 -0500 Subject: [PATCH] ASoC : msm: fix none toplogy setting for AOV port none toplogy should be set before sending copp create message to LPASS, moved the code to correct location. Change-Id: If062260133375f56f75150f45510e8a72d50dc95 Signed-off-by: Prabhu Annabathula <prabhu.annabathula@motorola.com> --- sound/soc/msm/qdsp6v2/q6adm.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/sound/soc/msm/qdsp6v2/q6adm.c b/sound/soc/msm/qdsp6v2/q6adm.c index 8ea407ca9088..08caf510f8b4 100644 --- a/sound/soc/msm/qdsp6v2/q6adm.c +++ b/sound/soc/msm/qdsp6v2/q6adm.c @@ -1429,6 +1429,13 @@ int adm_open(int port_id, int path, int rate, int channel_mode, int topology, } else this_adm.topology[index] = open.topology_id; + if (this_adm.port_none_topo == port_id && + this_adm.port_none_topo != AFE_PORT_INVALID) { + open.topology_id = NULL_COPP_TOPOLOGY; + this_adm.topology[index] = NULL_COPP_TOPOLOGY; + pr_debug("set topology none for port 0X%x\n", port_id); + } + open.dev_num_channel = channel_mode & 0xFF; open.bit_width = bits_per_sample; WARN_ON(perf_mode == ULTRA_LOW_LATENCY_PCM_MODE && @@ -1532,11 +1539,7 @@ int adm_open(int port_id, int path, int rate, int channel_mode, int topology, goto fail_cmd; } } - if (this_adm.port_none_topo == port_id && - this_adm.port_none_topo != AFE_PORT_INVALID) { - open.topology_id = NULL_COPP_TOPOLOGY; - pr_debug("set topology none for port 0X%x\n", port_id); - } + if (perf_mode == ULTRA_LOW_LATENCY_PCM_MODE || perf_mode == LOW_LATENCY_PCM_MODE) { atomic_inc(&this_adm.copp_low_latency_cnt[index]); -- GitLab