pcm: ioplug: Fix the regression of pulse plugin drain
The recent change to support the drain via polling caused a regression for pulse plugin; with speaker-test -c2 -twav with pulse, it leads to either no sounds or stall. The only sensible behavior change in the commit wrt pulse plugin is that now it starts the stream before calling drain callback. This supposed to be correct, but it seems hitting a pulse plugin bug. The start before drain callback is only a matter of consistency, and since this doesn't work for the single existing plugin using drain callback, we don't need to stick with this behavior. For addressing the regression, we check the presence of the drain callback and start the stream only when it doesn't exist, i.e. only in drain-via-poll mode. Fixes: ce2095c4 ("pcm: ioplug: Implement proper drain behavior") Reported-by:Diego Viola <diego.viola@gmail.com> Signed-off-by:
Takashi Iwai <tiwai@suse.de>
Loading
Please sign in to comment