[1/3] ALSA: HDA: Fix stream assignment for host in decoupled mode
diff mbox

Message ID 1438660720-30033-2-git-send-email-vinod.koul@intel.com
State New
Headers show

Commit Message

Vinod Koul Aug. 4, 2015, 3:58 a.m. UTC
From: Jeeja KP <jeeja.kp@intel.com>

This fixes issue in assigning host stream in case of
decoupled mode. The check to verify if the stream is already
in use was wrong so fix that

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 sound/hda/ext/hdac_ext_stream.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Takashi Iwai Aug. 4, 2015, 5:12 a.m. UTC | #1
On Tue, 04 Aug 2015 05:58:38 +0200,
Vinod Koul wrote:
> 
> From: Jeeja KP <jeeja.kp@intel.com>
> 
> This fixes issue in assigning host stream in case of
> decoupled mode. The check to verify if the stream is already
> in use was wrong so fix that
> 
> Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
> Signed-off-by: Vinod Koul <vinod.koul@intel.com>

Applied, thanks.


Takashi

> ---
>  sound/hda/ext/hdac_ext_stream.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/sound/hda/ext/hdac_ext_stream.c b/sound/hda/ext/hdac_ext_stream.c
> index f8ffbdbb450d..3de47dd1a76d 100644
> --- a/sound/hda/ext/hdac_ext_stream.c
> +++ b/sound/hda/ext/hdac_ext_stream.c
> @@ -299,7 +299,7 @@ hdac_ext_host_stream_assign(struct hdac_ext_bus *ebus,
>  		if (stream->direction != substream->stream)
>  			continue;
>  
> -		if (stream->opened) {
> +		if (!stream->opened) {
>  			if (!hstream->decoupled)
>  				snd_hdac_ext_stream_decouple(ebus, hstream, true);
>  			res = hstream;
> -- 
> 1.9.1
>

Patch
diff mbox

diff --git a/sound/hda/ext/hdac_ext_stream.c b/sound/hda/ext/hdac_ext_stream.c
index f8ffbdbb450d..3de47dd1a76d 100644
--- a/sound/hda/ext/hdac_ext_stream.c
+++ b/sound/hda/ext/hdac_ext_stream.c
@@ -299,7 +299,7 @@  hdac_ext_host_stream_assign(struct hdac_ext_bus *ebus,
 		if (stream->direction != substream->stream)
 			continue;
 
-		if (stream->opened) {
+		if (!stream->opened) {
 			if (!hstream->decoupled)
 				snd_hdac_ext_stream_decouple(ebus, hstream, true);
 			res = hstream;