]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: SOF: fix race in FW boot timeout handling
authorKai Vehmanen <kai.vehmanen@linux.intel.com>
Thu, 9 May 2019 20:10:23 +0000 (15:10 -0500)
committerMark Brown <broonie@kernel.org>
Mon, 13 May 2019 11:37:12 +0000 (12:37 +0100)
commit4053e95845fec0bc4357010a8637bf6972266f9b
tree4e59a25e93eada96c8d0e74b3d976f730fa5670f
parent4600562ff06b6520111f8bc0f2fb8d05cb5ea4ec
ASoC: SOF: fix race in FW boot timeout handling

A race condition exists in handling firmware boot timeout.
If FW sends FW_READY just after boot timeout has expired in
driver, a kernel exception will result as FW_READY handler
will be run while the state is still being cleaned up in
snd_sof_run_firmware(). Avoid the race by setting
boot_complete also in the error case.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/loader.c