Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mtd: amd76xrom: 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.

Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20210610022631.15344-1-thunder.leizhen@huawei.com

authored by

Zhen Lei and committed by
Miquel Raynal
3d2fac0e 042bf272

+2 -4
+2 -4
drivers/mtd/maps/amd76xrom.c
··· 189 189 190 190 if (!map) { 191 191 map = kmalloc(sizeof(*map), GFP_KERNEL); 192 - } 193 - if (!map) { 194 - printk(KERN_ERR MOD_NAME ": kmalloc failed"); 195 - goto out; 192 + if (!map) 193 + goto out; 196 194 } 197 195 memset(map, 0, sizeof(*map)); 198 196 INIT_LIST_HEAD(&map->list);