lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <58924d4f-2d29-4edb-95e9-ee7ccdb688d0@microchip.com>
Date: Wed, 2 Jul 2025 10:48:14 +0000
From: <Balamanikandan.Gunasundar@...rochip.com>
To: <fourier.thomas@...il.com>
CC: <stable@...r.kernel.org>, <miquel.raynal@...tlin.com>, <richard@....at>,
	<vigneshr@...com>, <u.kleine-koenig@...libre.com>, <vipin.kumar@...com>,
	<artem.bityutskiy@...ux.intel.com>, <vireshk@...nel.org>,
	<David.Woodhouse@...el.com>, <linux-mtd@...ts.infradead.org>,
	<linux-kernel@...r.kernel.org>, <Balamanikandan.Gunasundar@...rochip.com>
Subject: Re: [PATCH v2] mtd: rawnand: atmel: Add missing check after DMA map

Wrong subject prefix ?

On 02/07/25 12:28 pm, Thomas Fourier wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> 
> The DMA map functions can fail and should be tested for errors.
> 
> Fixes: 4774fb0a48aa ("mtd: nand/fsmc: Add DMA support")
> Signed-off-by: Thomas Fourier <fourier.thomas@...il.com>
> ---
> v1 -> v2:
> - Add stable@...r.kernel.org
> - Fix subject prefix
> 
>   drivers/mtd/nand/raw/fsmc_nand.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/mtd/nand/raw/fsmc_nand.c b/drivers/mtd/nand/raw/fsmc_nand.c
> index d579d5dd60d6..df61db8ce466 100644
> --- a/drivers/mtd/nand/raw/fsmc_nand.c
> +++ b/drivers/mtd/nand/raw/fsmc_nand.c
> @@ -503,6 +503,8 @@ static int dma_xfer(struct fsmc_nand_data *host, void *buffer, int len,
> 
>          dma_dev = chan->device;
>          dma_addr = dma_map_single(dma_dev->dev, buffer, len, direction);
> +       if (dma_mapping_error(dma_dev->dev, dma_addr))
> +               return -EINVAL;
> 
>          if (direction == DMA_TO_DEVICE) {
>                  dma_src = dma_addr;
> --
> 2.43.0
> 
> 
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ