]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
serial: sh-sci: protect invalidating RXDMA on shutdown
authorWolfram Sang <wsa+renesas@sang-engineering.com>
Mon, 6 May 2024 11:40:17 +0000 (13:40 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Jun 2024 11:39:40 +0000 (13:39 +0200)
commitb28bdc96074bc11f742762f6e84de5280d647e73
treec9aafb9ac2346961bef7234112a19f66541b1dad
parent8acae047215024d1ac499b3c8337ef1b952f160b
serial: sh-sci: protect invalidating RXDMA on shutdown

[ Upstream commit aae20f6e34cd0cbd67a1d0e5877561c40109a81b ]

The to-be-fixed commit removed locking when invalidating the DMA RX
descriptors on shutdown. It overlooked that there is still a rx_timer
running which may still access the protected data. So, re-add the
locking.

Reported-by: Dirk Behme <dirk.behme@de.bosch.com>
Closes: https://lore.kernel.org/r/ee6c9e16-9f29-450e-81da-4a8dceaa8fc7@de.bosch.com
Fixes: 2c4ee23530ff ("serial: sh-sci: Postpone DMA release when falling back to PIO")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://lore.kernel.org/r/20240506114016.30498-7-wsa+renesas@sang-engineering.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/tty/serial/sh-sci.c