Skip to contentSkip to conversation

mtd: rawnand: atmel: remove unnecessary oom message

PATCH Applied Zhen Lei 2 participants 2 messages Jun 10, 2021 – Jun 11, 2021

Subsystems (5)
lore
Share & tools
lore

Zhen Lei

author
#0 lore raw

PATCH 1/1 mtd: rawnand: atmel: remove unnecessary oom message

Fixes scripts/checkpatch.pl warning:
WARNING: Possible unnecessary 'out of memory' message

Remove it can help us save a bit of memory.

---
 drivers/mtd/nand/raw/atmel/nand-controller.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/mtd/nand/raw/atmel/nand-controller.c +1 -3
index 6e15f424b0718b3..f3276ee9e4fe73a 100644
@@ -1634,10 +1634,8 @@ static struct atmel_nand *atmel_nand_create(struct atmel_nand_controller *nc,
 	}
 
 	nand = devm_kzalloc(nc->dev, struct_size(nand, cs, numcs), GFP_KERNEL);
-	if (!nand) {
-		dev_err(nc->dev, "Failed to allocate NAND object\n");
+	if (!nand)
 		return ERR_PTR(-ENOMEM);
-	}
 
 	nand->numcs = numcs;
 
Signature · 1 line
2.26.0.106.g9fadedd
maintainer Applied
#1 lore raw
Quoted 6 lines · Zhen Lei

Fixes scripts/checkpatch.pl warning:
WARNING: Possible unnecessary 'out of memory' message

Remove it can help us save a bit of memory.

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

Miquel

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