diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2017-08-15 10:14:19 -0400 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2017-08-16 10:43:23 -0400 |
commit | b5f5245491b4bea1fd75dfd535e0ea7ec2071b3c (patch) | |
tree | 8c95f2642dce2b18f115554d5a3b358bb54dc86f /fs/udf | |
parent | 033c9da00893e90dcff0a714bcb5d66890ad818a (diff) |
fs-udf: Delete an error message for a failed memory allocation in two functions
Omit an extra message for a memory allocation failure in these functions.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/udf')
-rw-r--r-- | fs/udf/inode.c | 7 | ||||
-rw-r--r-- | fs/udf/super.c | 2 |
2 files changed, 1 insertions, 8 deletions
diff --git a/fs/udf/inode.c b/fs/udf/inode.c index 2bdb68215771..8dacf4f57414 100644 --- a/fs/udf/inode.c +++ b/fs/udf/inode.c | |||
@@ -1572,13 +1572,8 @@ static int udf_alloc_i_data(struct inode *inode, size_t size) | |||
1572 | { | 1572 | { |
1573 | struct udf_inode_info *iinfo = UDF_I(inode); | 1573 | struct udf_inode_info *iinfo = UDF_I(inode); |
1574 | iinfo->i_ext.i_data = kmalloc(size, GFP_KERNEL); | 1574 | iinfo->i_ext.i_data = kmalloc(size, GFP_KERNEL); |
1575 | 1575 | if (!iinfo->i_ext.i_data) | |
1576 | if (!iinfo->i_ext.i_data) { | ||
1577 | udf_err(inode->i_sb, "(ino %ld) no free memory\n", | ||
1578 | inode->i_ino); | ||
1579 | return -ENOMEM; | 1576 | return -ENOMEM; |
1580 | } | ||
1581 | |||
1582 | return 0; | 1577 | return 0; |
1583 | } | 1578 | } |
1584 | 1579 | ||
diff --git a/fs/udf/super.c b/fs/udf/super.c index d772c9c676d0..93c59630512b 100644 --- a/fs/udf/super.c +++ b/fs/udf/super.c | |||
@@ -268,8 +268,6 @@ static int udf_sb_alloc_partition_maps(struct super_block *sb, u32 count) | |||
268 | 268 | ||
269 | sbi->s_partmaps = kcalloc(count, sizeof(*sbi->s_partmaps), GFP_KERNEL); | 269 | sbi->s_partmaps = kcalloc(count, sizeof(*sbi->s_partmaps), GFP_KERNEL); |
270 | if (!sbi->s_partmaps) { | 270 | if (!sbi->s_partmaps) { |
271 | udf_err(sb, "Unable to allocate space for %d partition maps\n", | ||
272 | count); | ||
273 | sbi->s_partitions = 0; | 271 | sbi->s_partitions = 0; |
274 | return -ENOMEM; | 272 | return -ENOMEM; |
275 | } | 273 | } |