Commit 486198fb authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] sparse: more fs/* NULL noise removal

(partially based on patch from Mika Kukkonen)
parent 8a4ba9cf
...@@ -772,7 +772,8 @@ ext2_xattr_set2(struct inode *inode, struct buffer_head *old_bh, ...@@ -772,7 +772,8 @@ ext2_xattr_set2(struct inode *inode, struct buffer_head *old_bh,
s_first_data_block) + s_first_data_block) +
EXT2_I(inode)->i_block_group * EXT2_I(inode)->i_block_group *
EXT2_BLOCKS_PER_GROUP(sb); EXT2_BLOCKS_PER_GROUP(sb);
int block = ext2_new_block(inode, goal, 0, 0, &error); int block = ext2_new_block(inode, goal,
NULL, NULL, &error);
if (error) if (error)
goto cleanup; goto cleanup;
ea_idebug(inode, "creating block %d", block); ea_idebug(inode, "creating block %d", block);
......
...@@ -114,10 +114,9 @@ void ...@@ -114,10 +114,9 @@ void
jffs_cleanup_fmcontrol(struct jffs_fmcontrol *fmc) jffs_cleanup_fmcontrol(struct jffs_fmcontrol *fmc)
{ {
if (fmc) { if (fmc) {
struct jffs_fm *cur;
struct jffs_fm *next = fmc->head; struct jffs_fm *next = fmc->head;
while (next) {
while ((cur = next)) { struct jffs_fm *cur = next;
next = next->next; next = next->next;
jffs_free_fm(cur); jffs_free_fm(cur);
} }
......
...@@ -191,7 +191,7 @@ nlm4_encode_testres(u32 *p, struct nlm_res *resp) ...@@ -191,7 +191,7 @@ nlm4_encode_testres(u32 *p, struct nlm_res *resp)
dprintk("xdr: before encode_testres (p %p resp %p)\n", p, resp); dprintk("xdr: before encode_testres (p %p resp %p)\n", p, resp);
if (!(p = nlm4_encode_cookie(p, &resp->cookie))) if (!(p = nlm4_encode_cookie(p, &resp->cookie)))
return 0; return NULL;
*p++ = resp->status; *p++ = resp->status;
if (resp->status == nlm_lck_denied) { if (resp->status == nlm_lck_denied) {
...@@ -202,7 +202,7 @@ nlm4_encode_testres(u32 *p, struct nlm_res *resp) ...@@ -202,7 +202,7 @@ nlm4_encode_testres(u32 *p, struct nlm_res *resp)
/* Encode owner handle. */ /* Encode owner handle. */
if (!(p = xdr_encode_netobj(p, &resp->lock.oh))) if (!(p = xdr_encode_netobj(p, &resp->lock.oh)))
return 0; return NULL;
start = loff_t_to_s64(fl->fl_start); start = loff_t_to_s64(fl->fl_start);
if (fl->fl_end == OFFSET_MAX) if (fl->fl_end == OFFSET_MAX)
......
...@@ -387,7 +387,7 @@ nfs4_do_setattr(struct nfs_server *server, struct nfs_fattr *fattr, ...@@ -387,7 +387,7 @@ nfs4_do_setattr(struct nfs_server *server, struct nfs_fattr *fattr,
fattr->valid = 0; fattr->valid = 0;
if (sattr->ia_valid & ATTR_SIZE) if (sattr->ia_valid & ATTR_SIZE)
nfs4_copy_stateid(&arg.stateid, state, 0); nfs4_copy_stateid(&arg.stateid, state, NULL);
else else
memcpy(&arg.stateid, &zero_stateid, sizeof(arg.stateid)); memcpy(&arg.stateid, &zero_stateid, sizeof(arg.stateid));
......
...@@ -695,28 +695,29 @@ static int reiserfs_parse_options (struct super_block * s, char * options, /* st ...@@ -695,28 +695,29 @@ static int reiserfs_parse_options (struct super_block * s, char * options, /* st
char * arg = NULL; char * arg = NULL;
char * pos; char * pos;
opt_desc_t opts[] = { opt_desc_t opts[] = {
{"tails", 't', tails, 0, 0}, /* Compatibility stuff, so that -o notail for old setups still work */ /* Compatibility stuff, so that -o notail for old setups still work */
{"notail", 0, 0, 0, (1<<REISERFS_LARGETAIL)|(1<<REISERFS_SMALLTAIL)}, {"tails", .arg_required = 't', .values = tails},
{"conv", 0, 0, 1<<REISERFS_CONVERT, 0}, {"notail", .clrmask = (1<<REISERFS_LARGETAIL)|(1<<REISERFS_SMALLTAIL)},
{"attrs", 0, 0, 1<<REISERFS_ATTRS, 0}, {"conv", .setmask = 1<<REISERFS_CONVERT},
{"noattrs", 0, 0, 0, 1<<REISERFS_ATTRS}, {"attrs", .setmask = 1<<REISERFS_ATTRS},
{"user_xattr", 0, 0, 1<<REISERFS_XATTRS_USER, 0}, {"noattrs", .clrmask = 1<<REISERFS_ATTRS},
{"nouser_xattr", 0, 0, 0, 1<<REISERFS_XATTRS_USER}, {"user_xattr", .setmask = 1<<REISERFS_XATTRS_USER},
{"nouser_xattr",.clrmask = 1<<REISERFS_XATTRS_USER},
#ifdef CONFIG_REISERFS_FS_POSIX_ACL #ifdef CONFIG_REISERFS_FS_POSIX_ACL
{"acl", 0, 0, 1<<REISERFS_POSIXACL, 0}, {"acl", .setmask = 1<<REISERFS_POSIXACL},
{"noacl", 0, 0, 0, 1<<REISERFS_POSIXACL}, {"noacl", .clrmask = 1<<REISERFS_POSIXACL},
#endif #endif
{"nolog", 0, 0, 0, 0}, /* This is unsupported */ {"nolog",}, /* This is unsupported */
{"replayonly", 0, 0, 1<<REPLAYONLY, 0}, {"replayonly", .setmask = 1<<REPLAYONLY},
{"block-allocator", 'a', balloc, 0, 0}, {"block-allocator", .arg_required = 'a', .values = balloc},
{"data", 'd', logging_mode, 0, 0}, {"data", .arg_required = 'd', .values = logging_mode},
{"resize", 'r', 0, 0, 0}, {"resize", .arg_required = 'r', .values = NULL},
{"jdev", 'j', 0, 0, 0}, {"jdev", .arg_required = 'j', .values = NULL},
{"nolargeio", 'w', 0, 0, 0}, {"nolargeio", .arg_required = 'w', .values = NULL},
{"commit", 'c', 0, 0, 0}, {"commit", .arg_required = 'c', .values = NULL},
{"usrquota", 0, 0, 0, 0}, {"usrquota",},
{"grpquota", 0, 0, 0, 0}, {"grpquota",},
{NULL, 0, 0, 0, 0} {NULL,}
}; };
*blocks = 0; *blocks = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment