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

mtd: nftl: 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/20210610020130.14917-1-thunder.leizhen@huawei.com

authored by

Zhen Lei and committed by
Miquel Raynal
8ef02913 cba8b3bc

+1 -4
+1 -4
drivers/mtd/nftlmount.c
··· 188 188 /* memory alloc */ 189 189 nftl->EUNtable = kmalloc_array(nftl->nb_blocks, sizeof(u16), 190 190 GFP_KERNEL); 191 - if (!nftl->EUNtable) { 192 - printk(KERN_NOTICE "NFTL: allocation of EUNtable failed\n"); 191 + if (!nftl->EUNtable) 193 192 return -ENOMEM; 194 - } 195 193 196 194 nftl->ReplUnitTable = kmalloc_array(nftl->nb_blocks, 197 195 sizeof(u16), 198 196 GFP_KERNEL); 199 197 if (!nftl->ReplUnitTable) { 200 198 kfree(nftl->EUNtable); 201 - printk(KERN_NOTICE "NFTL: allocation of ReplUnitTable failed\n"); 202 199 return -ENOMEM; 203 200 } 204 201