mtd: rawnand: stm32_fmc2: Fix dma_map_sg error check
authorJack Wang <jinpu.wang@ionos.com>
Fri, 19 Aug 2022 06:07:46 +0000 (08:07 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Wed, 21 Sep 2022 08:38:46 +0000 (10:38 +0200)
commit43b81c2a3e6e07915151045aa13a6e8a9bd64419
tree90b9d66ef1a2e01e402ed10d7cb2a979b4cbbede
parentddfa68d415c749390e6a89f760b5edfa2774ad7b
mtd: rawnand: stm32_fmc2: Fix dma_map_sg error check

dma_map_sg return 0 on error, in case of error return -EIO.

Cc: Miquel Raynal <miquel.raynal@bootlin.com>
Cc: Richard Weinberger <richard@nod.at>
Cc: Vignesh Raghavendra <vigneshr@ti.com>
Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>
Cc: Alexandre Torgue <alexandre.torgue@foss.st.com>
Cc: Philipp Zabel <p.zabel@pengutronix.de>
Cc: Christophe Kerello <christophe.kerello@foss.st.com>
Cc: Cai Huoqing <cai.huoqing@linux.dev>
Cc: linux-mtd@lists.infradead.org
Cc: linux-stm32@st-md-mailman.stormreply.com
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jack Wang <jinpu.wang@ionos.com>
Reviewed-by: Christophe Kerello <christophe.kerello@foss.st.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220819060801.10443-5-jinpu.wang@ionos.com
drivers/mtd/nand/raw/stm32_fmc2_nand.c