xfs: correct error sign on COLLAPSE_RANGE errors
authorDave Chinner <dchinner@redhat.com>
Wed, 14 May 2014 23:22:07 +0000 (09:22 +1000)
committerDave Chinner <david@fromorbit.com>
Wed, 14 May 2014 23:22:07 +0000 (09:22 +1000)
Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Jie Liu <jeff.liu@oracle.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
fs/xfs/xfs_file.c

index 37f98c6d81aa06b43ef3977f102a528d1183233e..830c1c937b8888e7adba5557997d8d30dfc91713 100644 (file)
@@ -837,7 +837,7 @@ xfs_file_fallocate(
                unsigned blksize_mask = (1 << inode->i_blkbits) - 1;
 
                if (offset & blksize_mask || len & blksize_mask) {
-                       error = -EINVAL;
+                       error = EINVAL;
                        goto out_unlock;
                }
 
@@ -846,7 +846,7 @@ xfs_file_fallocate(
                 * in which case it is effectively a truncate operation
                 */
                if (offset + len >= i_size_read(inode)) {
-                       error = -EINVAL;
+                       error = EINVAL;
                        goto out_unlock;
                }