| To: | xfs@xxxxxxxxxxx |
|---|---|
| Subject: | [PATCH 09/14] xfs: remote attribute lookups require the value length |
| From: | Dave Chinner <david@xxxxxxxxxxxxx> |
| Date: | Mon, 20 May 2013 09:51:16 +1000 |
| Delivered-to: | xfs@xxxxxxxxxxx |
| In-reply-to: | <1369007481-15185-1-git-send-email-david@xxxxxxxxxxxxx> |
| References: | <1369007481-15185-1-git-send-email-david@xxxxxxxxxxxxx> |
From: Dave Chinner <dchinner@xxxxxxxxxx>
When reading a remote attribute, to correctly calculate the length
of the data buffer for CRC enable filesystems, we need to know the
length of the attribute data. We get this information when we look
up the attribute, but we don't store it in the args structure along
with the other remote attr information we get from the lookup. Add
this information to the args structure so we can use it
appropriately.
Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
---
fs/xfs/xfs_attr_leaf.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/xfs/xfs_attr_leaf.c b/fs/xfs/xfs_attr_leaf.c
index 8eeb88f..0bce1b3 100644
--- a/fs/xfs/xfs_attr_leaf.c
+++ b/fs/xfs/xfs_attr_leaf.c
@@ -2332,9 +2332,10 @@ xfs_attr3_leaf_lookup_int(
if (!xfs_attr_namesp_match(args->flags, entry->flags))
continue;
args->index = probe;
+ args->valuelen = be32_to_cpu(name_rmt->valuelen);
args->rmtblkno = be32_to_cpu(name_rmt->valueblk);
args->rmtblkcnt = XFS_B_TO_FSB(args->dp->i_mount,
-
be32_to_cpu(name_rmt->valuelen));
+ args->valuelen);
return XFS_ERROR(EEXIST);
}
}
--
1.7.10.4
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH 11/14] xfs: remote attribute tail zeroing does too much, Dave Chinner |
|---|---|
| Next by Date: | [PATCH 01/14] xfs: fix sub-page blocksize data integrity writes, Dave Chinner |
| Previous by Thread: | Re: [PATCH 11/14] xfs: remote attribute tail zeroing does too much, Ben Myers |
| Next by Thread: | Re: [PATCH 09/14] xfs: remote attribute lookups require the value length, Ben Myers |
| Indexes: | [Date] [Thread] [Top] [All Lists] |