linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] mtd: rawnand: brcmnand: Fix NULL pointer assignment
@ 2019-10-21 16:45 Florian Fainelli
  2019-10-30  8:24 ` Miquel Raynal
  0 siblings, 1 reply; 2+ messages in thread
From: Florian Fainelli @ 2019-10-21 16:45 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: Florian Fainelli, Vignesh Raghavendra, Kamal Dasu,
	Richard Weinberger, open list, Marek Vasut,
	open list:BROADCOM STB NAND FLASH DRIVER, Miquel Raynal,
	open list:BROADCOM STB NAND FLASH DRIVER, Brian Norris,
	David Woodhouse

Sparse complained about the following:

drivers/mtd/nand/raw/brcmnand/brcmnand.c:921:40: warning: Using plain integer as NULL pointer

fix this issue by assigning the pointer to NULL.

Fixes: c1ac2dc34b51 ("mtd: rawnand: brcmnand: When oops in progress use pio and interrupt polling")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
 drivers/mtd/nand/raw/brcmnand/brcmnand.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/raw/brcmnand/brcmnand.c b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
index 15ef30b368a5..6a7f0211f5a5 100644
--- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
@@ -918,7 +918,7 @@ static inline void disable_ctrl_irqs(struct brcmnand_controller *ctrl)
 		return;
 
 	if (has_flash_dma(ctrl)) {
-		ctrl->flash_dma_base = 0;
+		ctrl->flash_dma_base = NULL;
 		disable_irq(ctrl->dma_irq);
 	}
 
-- 
2.17.1


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] mtd: rawnand: brcmnand: Fix NULL pointer assignment
  2019-10-21 16:45 [PATCH v2] mtd: rawnand: brcmnand: Fix NULL pointer assignment Florian Fainelli
@ 2019-10-30  8:24 ` Miquel Raynal
  0 siblings, 0 replies; 2+ messages in thread
From: Miquel Raynal @ 2019-10-30  8:24 UTC (permalink / raw)
  To: Florian Fainelli, linux-arm-kernel
  Cc: Vignesh Raghavendra, Kamal Dasu, Richard Weinberger, open list,
	Marek Vasut, open list:BROADCOM STB NAND FLASH DRIVER,
	Miquel Raynal, open list:BROADCOM STB NAND FLASH DRIVER,
	Brian Norris, David Woodhouse

On Mon, 2019-10-21 at 16:45:54 UTC, Florian Fainelli wrote:
> Sparse complained about the following:
> 
> drivers/mtd/nand/raw/brcmnand/brcmnand.c:921:40: warning: Using plain integer as NULL pointer
> 
> fix this issue by assigning the pointer to NULL.
> 
> Fixes: c1ac2dc34b51 ("mtd: rawnand: brcmnand: When oops in progress use pio and interrupt polling")
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>

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

Miquel

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-10-30  8:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-21 16:45 [PATCH v2] mtd: rawnand: brcmnand: Fix NULL pointer assignment Florian Fainelli
2019-10-30  8:24 ` Miquel Raynal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).