dmaengine: bestcomm: fix system boot lockups
authorAnatolij Gustschin <agust@denx.de>
Thu, 14 Oct 2021 09:40:12 +0000 (11:40 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 18 Nov 2021 18:17:16 +0000 (19:17 +0100)
commit6a85f01a89efbedcc217997129eff404b9870078
treeb0755c5d12eb5487e394848c0041b94d030b2ac4
parentc4cd9e5acc34735e344b0cc03a8f27cc0b4fa0b3
dmaengine: bestcomm: fix system boot lockups

commit adec566b05288f2787a1f88dbaf77ed8b0c644fa upstream.

memset() and memcpy() on an MMIO region like here results in a
lockup at startup on mpc5200 platform (since this first happens
during probing of the ATA and Ethernet drivers). Use memset_io()
and memcpy_toio() instead.

Fixes: 2f9ea1bde0d1 ("bestcomm: core bestcomm support for Freescale MPC5200")
Cc: stable@vger.kernel.org # v5.14+
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Link: https://lore.kernel.org/r/20211014094012.21286-1-agust@denx.de
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/dma/bestcomm/ata.c
drivers/dma/bestcomm/bestcomm.c
drivers/dma/bestcomm/fec.c
drivers/dma/bestcomm/gen_bd.c