aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/ubifs/journal.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/ubifs/journal.c b/fs/ubifs/journal.c
index 419c79ff377e..9f356432f35f 100644
--- a/fs/ubifs/journal.c
+++ b/fs/ubifs/journal.c
@@ -572,7 +572,7 @@ int ubifs_jnl_update(struct ubifs_info *c, const struct inode *dir,
572 /* Make sure to also account for extended attributes */ 572 /* Make sure to also account for extended attributes */
573 len += host_ui->data_len; 573 len += host_ui->data_len;
574 574
575 dent = kmalloc(len, GFP_NOFS); 575 dent = kzalloc(len, GFP_NOFS);
576 if (!dent) 576 if (!dent)
577 return -ENOMEM; 577 return -ENOMEM;
578 578
@@ -968,7 +968,7 @@ int ubifs_jnl_xrename(struct ubifs_info *c, const struct inode *fst_dir,
968 if (twoparents) 968 if (twoparents)
969 len += plen; 969 len += plen;
970 970
971 dent1 = kmalloc(len, GFP_NOFS); 971 dent1 = kzalloc(len, GFP_NOFS);
972 if (!dent1) 972 if (!dent1)
973 return -ENOMEM; 973 return -ENOMEM;
974 974
@@ -1116,7 +1116,7 @@ int ubifs_jnl_rename(struct ubifs_info *c, const struct inode *old_dir,
1116 len = aligned_dlen1 + aligned_dlen2 + ALIGN(ilen, 8) + ALIGN(plen, 8); 1116 len = aligned_dlen1 + aligned_dlen2 + ALIGN(ilen, 8) + ALIGN(plen, 8);
1117 if (move) 1117 if (move)
1118 len += plen; 1118 len += plen;
1119 dent = kmalloc(len, GFP_NOFS); 1119 dent = kzalloc(len, GFP_NOFS);
1120 if (!dent) 1120 if (!dent)
1121 return -ENOMEM; 1121 return -ENOMEM;
1122 1122
@@ -1498,7 +1498,7 @@ int ubifs_jnl_delete_xattr(struct ubifs_info *c, const struct inode *host,
1498 hlen = host_ui->data_len + UBIFS_INO_NODE_SZ; 1498 hlen = host_ui->data_len + UBIFS_INO_NODE_SZ;
1499 len = aligned_xlen + UBIFS_INO_NODE_SZ + ALIGN(hlen, 8); 1499 len = aligned_xlen + UBIFS_INO_NODE_SZ + ALIGN(hlen, 8);
1500 1500
1501 xent = kmalloc(len, GFP_NOFS); 1501 xent = kzalloc(len, GFP_NOFS);
1502 if (!xent) 1502 if (!xent)
1503 return -ENOMEM; 1503 return -ENOMEM;
1504 1504
@@ -1605,7 +1605,7 @@ int ubifs_jnl_change_xattr(struct ubifs_info *c, const struct inode *inode,
1605 aligned_len1 = ALIGN(len1, 8); 1605 aligned_len1 = ALIGN(len1, 8);
1606 aligned_len = aligned_len1 + ALIGN(len2, 8); 1606 aligned_len = aligned_len1 + ALIGN(len2, 8);
1607 1607
1608 ino = kmalloc(aligned_len, GFP_NOFS); 1608 ino = kzalloc(aligned_len, GFP_NOFS);
1609 if (!ino) 1609 if (!ino)
1610 return -ENOMEM; 1610 return -ENOMEM;
1611 1611