aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_attr.c
diff options
context:
space:
mode:
authorEric Sandeen <sandeen@sandeen.net>2014-06-22 01:03:54 -0400
committerDave Chinner <david@fromorbit.com>2014-06-22 01:03:54 -0400
commitd99831ff393ff2e28d6110b41f24d9fecf986222 (patch)
tree4e21591c0ed0992ca085b08a2faf7b53fec51586 /fs/xfs/xfs_attr.c
parenta497c3ba1d97fc69c1e78e7b96435ba8c2cb42ee (diff)
xfs: return is not a function
return is not a function. "return(EIO);" is silly; "return (EIO);" moreso. return is not a function. Nuke the pointless parens. [dchinner: catch a couple of extra cases in xfs_attr_list.c, xfs_acl.c and xfs_linux.h.] Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com>
Diffstat (limited to 'fs/xfs/xfs_attr.c')
-rw-r--r--fs/xfs/xfs_attr.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/fs/xfs/xfs_attr.c b/fs/xfs/xfs_attr.c
index bfe36fc2cdc2..4cd541891a60 100644
--- a/fs/xfs/xfs_attr.c
+++ b/fs/xfs/xfs_attr.c
@@ -535,27 +535,27 @@ xfs_attr_shortform_addname(xfs_da_args_t *args)
535 535
536 retval = xfs_attr_shortform_lookup(args); 536 retval = xfs_attr_shortform_lookup(args);
537 if ((args->flags & ATTR_REPLACE) && (retval == ENOATTR)) { 537 if ((args->flags & ATTR_REPLACE) && (retval == ENOATTR)) {
538 return(retval); 538 return retval;
539 } else if (retval == EEXIST) { 539 } else if (retval == EEXIST) {
540 if (args->flags & ATTR_CREATE) 540 if (args->flags & ATTR_CREATE)
541 return(retval); 541 return retval;
542 retval = xfs_attr_shortform_remove(args); 542 retval = xfs_attr_shortform_remove(args);
543 ASSERT(retval == 0); 543 ASSERT(retval == 0);
544 } 544 }
545 545
546 if (args->namelen >= XFS_ATTR_SF_ENTSIZE_MAX || 546 if (args->namelen >= XFS_ATTR_SF_ENTSIZE_MAX ||
547 args->valuelen >= XFS_ATTR_SF_ENTSIZE_MAX) 547 args->valuelen >= XFS_ATTR_SF_ENTSIZE_MAX)
548 return(XFS_ERROR(ENOSPC)); 548 return XFS_ERROR(ENOSPC);
549 549
550 newsize = XFS_ATTR_SF_TOTSIZE(args->dp); 550 newsize = XFS_ATTR_SF_TOTSIZE(args->dp);
551 newsize += XFS_ATTR_SF_ENTSIZE_BYNAME(args->namelen, args->valuelen); 551 newsize += XFS_ATTR_SF_ENTSIZE_BYNAME(args->namelen, args->valuelen);
552 552
553 forkoff = xfs_attr_shortform_bytesfit(args->dp, newsize); 553 forkoff = xfs_attr_shortform_bytesfit(args->dp, newsize);
554 if (!forkoff) 554 if (!forkoff)
555 return(XFS_ERROR(ENOSPC)); 555 return XFS_ERROR(ENOSPC);
556 556
557 xfs_attr_shortform_add(args, forkoff); 557 xfs_attr_shortform_add(args, forkoff);
558 return(0); 558 return 0;
559} 559}
560 560
561 561
@@ -642,7 +642,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
642 ASSERT(committed); 642 ASSERT(committed);
643 args->trans = NULL; 643 args->trans = NULL;
644 xfs_bmap_cancel(args->flist); 644 xfs_bmap_cancel(args->flist);
645 return(error); 645 return error;
646 } 646 }
647 647
648 /* 648 /*
@@ -658,13 +658,13 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
658 */ 658 */
659 error = xfs_trans_roll(&args->trans, dp); 659 error = xfs_trans_roll(&args->trans, dp);
660 if (error) 660 if (error)
661 return (error); 661 return error;
662 662
663 /* 663 /*
664 * Fob the whole rest of the problem off on the Btree code. 664 * Fob the whole rest of the problem off on the Btree code.
665 */ 665 */
666 error = xfs_attr_node_addname(args); 666 error = xfs_attr_node_addname(args);
667 return(error); 667 return error;
668 } 668 }
669 669
670 /* 670 /*
@@ -673,7 +673,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
673 */ 673 */
674 error = xfs_trans_roll(&args->trans, dp); 674 error = xfs_trans_roll(&args->trans, dp);
675 if (error) 675 if (error)
676 return (error); 676 return error;
677 677
678 /* 678 /*
679 * If there was an out-of-line value, allocate the blocks we 679 * If there was an out-of-line value, allocate the blocks we
@@ -684,7 +684,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
684 if (args->rmtblkno > 0) { 684 if (args->rmtblkno > 0) {
685 error = xfs_attr_rmtval_set(args); 685 error = xfs_attr_rmtval_set(args);
686 if (error) 686 if (error)
687 return(error); 687 return error;
688 } 688 }
689 689
690 /* 690 /*
@@ -700,7 +700,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
700 */ 700 */
701 error = xfs_attr3_leaf_flipflags(args); 701 error = xfs_attr3_leaf_flipflags(args);
702 if (error) 702 if (error)
703 return(error); 703 return error;
704 704
705 /* 705 /*
706 * Dismantle the "old" attribute/value pair by removing 706 * Dismantle the "old" attribute/value pair by removing
@@ -714,7 +714,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
714 if (args->rmtblkno) { 714 if (args->rmtblkno) {
715 error = xfs_attr_rmtval_remove(args); 715 error = xfs_attr_rmtval_remove(args);
716 if (error) 716 if (error)
717 return(error); 717 return error;
718 } 718 }
719 719
720 /* 720 /*
@@ -744,7 +744,7 @@ xfs_attr_leaf_addname(xfs_da_args_t *args)
744 ASSERT(committed); 744 ASSERT(committed);
745 args->trans = NULL; 745 args->trans = NULL;
746 xfs_bmap_cancel(args->flist); 746 xfs_bmap_cancel(args->flist);
747 return(error); 747 return error;
748 } 748 }
749 749
750 /* 750 /*
@@ -1031,7 +1031,7 @@ restart:
1031 if (args->rmtblkno > 0) { 1031 if (args->rmtblkno > 0) {
1032 error = xfs_attr_rmtval_set(args); 1032 error = xfs_attr_rmtval_set(args);
1033 if (error) 1033 if (error)
1034 return(error); 1034 return error;
1035 } 1035 }
1036 1036
1037 /* 1037 /*
@@ -1061,7 +1061,7 @@ restart:
1061 if (args->rmtblkno) { 1061 if (args->rmtblkno) {
1062 error = xfs_attr_rmtval_remove(args); 1062 error = xfs_attr_rmtval_remove(args);
1063 if (error) 1063 if (error)
1064 return(error); 1064 return error;
1065 } 1065 }
1066 1066
1067 /* 1067 /*
@@ -1134,8 +1134,8 @@ out:
1134 if (state) 1134 if (state)
1135 xfs_da_state_free(state); 1135 xfs_da_state_free(state);
1136 if (error) 1136 if (error)
1137 return(error); 1137 return error;
1138 return(retval); 1138 return retval;
1139} 1139}
1140 1140
1141/* 1141/*
@@ -1297,7 +1297,7 @@ xfs_attr_node_removename(xfs_da_args_t *args)
1297 1297
1298out: 1298out:
1299 xfs_da_state_free(state); 1299 xfs_da_state_free(state);
1300 return(error); 1300 return error;
1301} 1301}
1302 1302
1303/* 1303/*
@@ -1345,7 +1345,7 @@ xfs_attr_fillstate(xfs_da_state_t *state)
1345 } 1345 }
1346 } 1346 }
1347 1347
1348 return(0); 1348 return 0;
1349} 1349}
1350 1350
1351/* 1351/*
@@ -1376,7 +1376,7 @@ xfs_attr_refillstate(xfs_da_state_t *state)
1376 blk->blkno, blk->disk_blkno, 1376 blk->blkno, blk->disk_blkno,
1377 &blk->bp, XFS_ATTR_FORK); 1377 &blk->bp, XFS_ATTR_FORK);
1378 if (error) 1378 if (error)
1379 return(error); 1379 return error;
1380 } else { 1380 } else {
1381 blk->bp = NULL; 1381 blk->bp = NULL;
1382 } 1382 }
@@ -1395,13 +1395,13 @@ xfs_attr_refillstate(xfs_da_state_t *state)
1395 blk->blkno, blk->disk_blkno, 1395 blk->blkno, blk->disk_blkno,
1396 &blk->bp, XFS_ATTR_FORK); 1396 &blk->bp, XFS_ATTR_FORK);
1397 if (error) 1397 if (error)
1398 return(error); 1398 return error;
1399 } else { 1399 } else {
1400 blk->bp = NULL; 1400 blk->bp = NULL;
1401 } 1401 }
1402 } 1402 }
1403 1403
1404 return(0); 1404 return 0;
1405} 1405}
1406 1406
1407/* 1407/*
@@ -1455,5 +1455,5 @@ xfs_attr_node_get(xfs_da_args_t *args)
1455 } 1455 }
1456 1456
1457 xfs_da_state_free(state); 1457 xfs_da_state_free(state);
1458 return(retval); 1458 return retval;
1459} 1459}