From: Takashi Iwai Date: Mon, 6 Feb 2017 14:09:48 +0000 (+0100) Subject: ALSA: seq: Don't handle loop timeout at snd_seq_pool_done() X-Git-Tag: v3.2.87~68 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c723076373dac50287fba6ccd1067301b67dbfa4;p=pandora-kernel.git ALSA: seq: Don't handle loop timeout at snd_seq_pool_done() commit 37a7ea4a9b81f6a864c10a7cb0b96458df5310a3 upstream. snd_seq_pool_done() syncs with closing of all opened threads, but it aborts the wait loop with a timeout, and proceeds to the release resource even if not all threads have been closed. The timeout was 5 seconds, and if you run a crazy stuff, it can exceed easily, and may result in the access of the invalid memory address -- this is what syzkaller detected in a bug report. As a fix, let the code graduate from naiveness, simply remove the loop timeout. BugLink: http://lkml.kernel.org/r/CACT4Y+YdhDV2H5LLzDTJDVF-qiYHUHhtRaW4rbb4gUhTCQB81w@mail.gmail.com Reported-by: Dmitry Vyukov Signed-off-by: Takashi Iwai [bwh: Backported to 3.2: deleted log statement is slightly different] Signed-off-by: Ben Hutchings --- Reading git-diff-tree failed