From: Pierre-Louis Bossart Date: Tue, 24 Nov 2020 01:33:15 +0000 (+0800) Subject: soundwire: bus: reset slave_notify status at each loop X-Git-Tag: v5.11-rc1~164^2~46^2~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7ffaba042e0e997832032b2d7b062dc27a7ebb2d;p=thirdparty%2Flinux.git soundwire: bus: reset slave_notify status at each loop The code loops multiple times to deal with pending interrupts, but we never reset the slave_notify status. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Guennadi Liakhovetski Signed-off-by: Bard Liao Link: https://lore.kernel.org/r/20201124013318.8963-3-yung-chuan.liao@linux.intel.com Signed-off-by: Vinod Koul --- diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c index 45131b9f5080b..d6e6465218190 100644 --- a/drivers/soundwire/bus.c +++ b/drivers/soundwire/bus.c @@ -1425,7 +1425,7 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave) u8 clear = 0, bit, port_status[15] = {0}; int port_num, stat, ret, count = 0; unsigned long port; - bool slave_notify = false; + bool slave_notify; u8 sdca_cascade = 0; u8 buf, buf2[2], _buf, _buf2[2]; bool parity_check; @@ -1467,6 +1467,8 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave) } do { + slave_notify = false; + /* * Check parity, bus clash and Slave (impl defined) * interrupt