Skip to content

Fix dma_map_sg error check

Jack Wang linux-amlogic linux-arm-kernel linux-arm-msm linux-crypto linux-mips linux-mmc linux-mtd linux-nvme linux-rdma linux-scsi linux-sunxi linux-usb lkml netdev 1 version Applied

Status from this message: Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git nand/next, thanks.

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest19 patches 23 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/19mailbox: bcm-ferxrm-mailbox: Fix error check for dma_map_sgdrivers/mailbox/bcm-flexrm-mailbox.c+4 -42 replies
2/19infiniband/mthca: Fix dma_map_sg error checkdrivers/infiniband/hw/mthca/mthca_memfree.c+4 -33 replies
3/19HSI: omap_ssi_port: Fix dma_map_sg error checkdrivers/hsi/controllers/omap_ssi_port.c+4 -40 replies
4/19mtd: rawnand: stm32_fmc2: Fix dma_map_sg error checkdrivers/mtd/nand/raw/stm32_fmc2_nand.c+5 -32 replies
5/19mtd: rawnand: marvell: Fix error handle regarding dma_map_sgdrivers/mtd/nand/raw/marvell_nand.c+7 -11 reply
6/19usb/hcd: Fix dma_map_sg error checkdrivers/usb/core/hcd.c+1 -10 replies
7/19crypto: gemin: Fix error check for dma_map_sgdrivers/crypto/gemini/sl3516-ce-cipher.c+3 -34 replies
8/19crypto: sahara: Fix error check for dma_map_sgdrivers/crypto/sahara.c+2 -20 replies
9/19crypto: qce: Fix dma_map_sg error checkdrivers/crypto/qce/aead.c drivers/crypto/qce/sha.c drivers/crypto/qce/skcipher.c+11 -90 replies
10/19crypto: amlogic: Fix dma_map_sg error checkdrivers/crypto/amlogic/amlogic-gxl-cipher.c+3 -31 reply
11/19crypto: allwinner: Fix dma_map_sg error checkdrivers/crypto/allwinner/sun8i-ce/sun8i-ce-cipher.c drivers/crypto/allwinner/sun8i-ce/sun8i-ce-hash.c drivers/crypto/allwinner/sun8i-ss/sun8i-ss-cipher.c +1 more+7 -70 replies
12/19crypto: ccree: Fix dma_map_sg error checkdrivers/crypto/ccree/cc_buffer_mgr.c+1 -11 reply
13/19intel_th: Fix dma_map_sg error checkdrivers/hwtracing/intel_th/msu.c+1 -10 replies
14/19nvme-rdma: Fix error check for ib_dma_map_sgdrivers/nvme/host/rdma.c+2 -24 replies
15/19nvme-fc: Fix the error check for dma_map_sgdrivers/nvme/host/fc.c drivers/nvme/target/fc.c+6 -10 replies
16/19scsi/qlogicpti: Fix dma_map_sg checkdrivers/scsi/qlogicpti.c+2 -10 replies
17/19mmc: meson-mx-sdhc: Fix error check for dma_map_sgdrivers/mmc/host/meson-mx-sdhc-mmc.c+1 -12 replies
18/19mmc: jz4740_mmc: Fix error check for dma_map_sgdrivers/mmc/host/jz4740_mmc.c+1 -10 replies
19/19net/mlx4: Fix error check for dma_map_sgdrivers/net/ethernet/mellanox/mlx4/icm.c+2 -23 replies

Reviews trailers per patch

5 of 19 patches have a Reviewed-by or Acked-by.

PatchKees CookLeon RomanovskyChristophe KerelloLinus WalleijCorentin Labbe
1/19
2/19R-b
3/19
4/19R-b
5/19
6/19
7/19R-b A-b T-b
8/19
9/19
10/19T-b A-b
11/19
12/19
13/19
14/19
15/19
16/19
17/19
18/19
19/19R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 5 reviewers.

Read the v1 thread

Cover letter [PATCH v1 00/19] Fix dma_map_sg error check

Hi, all,

While working on a bugfix on RTRS[1], I noticed there are quite a few other drivers have the same problem, due to the fact dma_map_sg return 0 on error, not like most of the cases, return negative value for error.

I "grep -A 5 dma_map_sg' in kernel tree, and audit/fix the one I feel is buggy, hence this serry. All the patch are independent, so can go either through the maintainer tree once it is reviewed.

Thanks!

[1] https://lore.kernel.org/linux-rdma/[email protected]/T/#t

Jack Wang (19):
mailbox: bcm-ferxrm-mailbox: Fix error check for dma_map_sg infiniband/mthca: Fix dma_map_sg error check
HSI: omap_ssi_port: Fix dma_map_sg error check
mtd: rawnand: stm32_fmc2: Fix dma_map_sg error check
mtd: rawnand: marvell: Fix error handle regarding dma_map_sg usb/hcd: Fix dma_map_sg error check
crypto: gemin: Fix error check for dma_map_sg
crypto: sahara: Fix error check for dma_map_sg
crypto: qce: Fix dma_map_sg error check
crypto: amlogic: Fix dma_map_sg error check
crypto: allwinner: Fix dma_map_sg error check
crypto: ccree: Fix dma_map_sg error check
intel_th: Fix dma_map_sg error check
nvme-rdma: Fix error check for ib_dma_map_sg
nvme-fc: Fix the error check for dma_map_sg scsi/qlogicpti: Fix dma_map_sg check
mmc: meson-mx-sdhc: Fix error check for dma_map_sg
mmc: jz4740_mmc: Fix error check for dma_map_sg net/mlx4: Fix error check for dma_map_sg

 drivers/crypto/allwinner/sun8i-ce/sun8i-ce-cipher.c | 6 +++---
 drivers/crypto/allwinner/sun8i-ce/sun8i-ce-hash.c   | 2 +-
 drivers/crypto/allwinner/sun8i-ss/sun8i-ss-cipher.c | 4 ++--
 drivers/crypto/allwinner/sun8i-ss/sun8i-ss-hash.c   | 2 +-
 drivers/crypto/amlogic/amlogic-gxl-cipher.c         | 6 +++---
 drivers/crypto/ccree/cc_buffer_mgr.c                | 2 +-
 drivers/crypto/gemini/sl3516-ce-cipher.c            | 6 +++---
 drivers/crypto/qce/aead.c                           | 4 ++--
 drivers/crypto/qce/sha.c                            | 8 +++++---
 drivers/crypto/qce/skcipher.c                       | 8 ++++----
 drivers/crypto/sahara.c                             | 4 ++--
 drivers/hsi/controllers/omap_ssi_port.c             | 8 ++++----
 drivers/hwtracing/intel_th/msu.c                    | 2 +-
 drivers/infiniband/hw/mthca/mthca_memfree.c         | 7 ++++---
 drivers/mailbox/bcm-flexrm-mailbox.c                | 8 ++++----
 drivers/mmc/host/jz4740_mmc.c                       | 2 +-
 drivers/mmc/host/meson-mx-sdhc-mmc.c                | 2 +-
 drivers/mtd/nand/raw/marvell_nand.c                 | 8 +++++++-
 drivers/mtd/nand/raw/stm32_fmc2_nand.c              | 8 +++++---
 drivers/net/ethernet/mellanox/mlx4/icm.c            | 4 ++--
 drivers/nvme/host/fc.c                              | 2 +-
 drivers/nvme/host/rdma.c                            | 4 ++--
 drivers/nvme/target/fc.c                            | 5 +++++
 drivers/scsi/qlogicpti.c                            | 3 ++-
 drivers/usb/core/hcd.c                              | 2 +-
 25 files changed, 67 insertions(+), 50 deletions(-)
Signature · 1 line
2.34.1