ALSA backend: try to recover from poll errors
When recover() successfully re-initializes the device, processing can continue just like after an x-run. This can happen during initial session load of "expensive" sessions (in particular on slow systems, e.g. Raspberry Pi) usually with synths. Worker thread pulls in many external files in the background which blocks the bus for a long time. resulting in a poll-timeout.
This commit is contained in:
parent
4001ed7515
commit
eea697b260
@ -229,14 +229,18 @@ snd_pcm_sframes_t Alsa_pcmi::pcm_wait (void)
|
||||
if (_play_handle && (play_av = snd_pcm_avail_update (_play_handle)) < 0)
|
||||
{
|
||||
_state = -1;
|
||||
recover ();
|
||||
if (!recover ()) {
|
||||
_state = 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
capt_av = 999999999;
|
||||
if (_capt_handle && (capt_av = snd_pcm_avail_update (_capt_handle)) < 0)
|
||||
{
|
||||
_state = -1;
|
||||
recover ();
|
||||
if (!recover ()) {
|
||||
_state = 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user