Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0b92b0cd authored by Charles Keepax's avatar Charles Keepax Committed by Takashi Iwai
Browse files

ALSA: compress: Use snd_compr_get_poll on error path



We have a function that returns the appropriate flags for the stream
direction, so we should use it.

Signed-off-by: default avatarCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
Acked-by: default avatarVinod Koul <vinod.koul@intel.com>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent e099aeea
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -421,10 +421,7 @@ static unsigned int snd_compr_poll(struct file *f, poll_table *wait)
			retval = snd_compr_get_poll(stream);
		break;
	default:
		if (stream->direction == SND_COMPRESS_PLAYBACK)
			retval = POLLOUT | POLLWRNORM | POLLERR;
		else
			retval = POLLIN | POLLRDNORM | POLLERR;
		retval = snd_compr_get_poll(stream) | POLLERR;
		break;
	}
out: