alsa-pcm: Fix target calculation

Use threshold instead of last_threshold so that early wakeup is detected
in handle_capture() when duration changes.
This commit is contained in:
Jonas Holmberg 2021-01-28 16:44:33 +01:00 committed by Wim Taymans
parent c0ed88f2f9
commit 0ccad38df1

View file

@ -802,7 +802,7 @@ static int get_status(struct state *state, snd_pcm_uframes_t *delay, snd_pcm_ufr
}
*target = state->last_threshold + state->headroom;
*target = state->threshold + state->headroom;
#define MARGIN 48
if (state->resample && state->rate_match) {