VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   33 Branches   57 Tags
author: Kees Cook <keescook@chromium.org> 2018-06-12 13:55:00 -0700 committer: Kees Cook <keescook@chromium.org> 2018-06-12 16:19:22 -0700 commit: 6da2ec56059c3c7a7e5f729e6349e74ace1e5c57 parent: 1c542f38ab8d30d9c852a16d49ac5a15267bbf1f
Commit Summary:
treewide: kmalloc() -> kmalloc_array()
Diffstat:
1 file changed, 1 insertion, 1 deletion
diff --git a/fs/jffs2/wbuf.c b/fs/jffs2/wbuf.c
index 2cfe487708e0..c6821a509481 100644
--- a/fs/jffs2/wbuf.c
+++ b/fs/jffs2/wbuf.c
@@ -1208,7 +1208,7 @@ int jffs2_nand_flash_setup(struct jffs2_sb_info *c)
 	if (!c->wbuf)
 		return -ENOMEM;
 
-	c->oobbuf = kmalloc(NR_OOB_SCAN_PAGES * c->oobavail, GFP_KERNEL);
+	c->oobbuf = kmalloc_array(NR_OOB_SCAN_PAGES, c->oobavail, GFP_KERNEL);
 	if (!c->oobbuf) {
 		kfree(c->wbuf);
 		return -ENOMEM;