speakup crashes with kernel 5.4.69
Samuel Thibault
samuel.thibault at ens-lyon.org
Mon Nov 2 04:10:16 EST 2020
John Covici, le lun. 02 nov. 2020 03:47:47 -0500, a ecrit:
> Looks like the patch is working!
Ok, good. Could you try the (much simpler) attached patch instead?
Samuel
-------------- next part --------------
--- a/drivers/accessibility/speakup/spk_ttyio.c
+++ b/drivers/accessibility/speakup/spk_ttyio.c
@@ -298,11 +298,13 @@ static unsigned char ttyio_in(int timeou
struct spk_ldisc_data *ldisc_data = speakup_tty->disc_data;
char rv;
- if (wait_for_completion_timeout(&ldisc_data->completion,
+ if (!timeout) {
+ if (!try_wait_for_completion(&ldisc_data->completion))
+ return 0xff;
+ } else if (wait_for_completion_timeout(&ldisc_data->completion,
usecs_to_jiffies(timeout)) == 0) {
- if (timeout)
- pr_warn("spk_ttyio: timeout (%d) while waiting for input\n",
- timeout);
+ pr_warn("spk_ttyio: timeout (%d) while waiting for input\n",
+ timeout);
return 0xff;
}
More information about the Speakup
mailing list