diff options
author | Tao Ma <tao.ma@oracle.com> | 2010-04-29 15:13:56 +1000 |
---|---|---|
committer | Alex Elder <aelder@sgi.com> | 2010-05-19 09:58:16 -0500 |
commit | 2d1ff3c75a4642062d314634290be6d8da4ffb03 (patch) | |
tree | 1112feee61ad0c7653c6877d04397b4949c46471 /fs/xfs/xfs_iomap.c | |
parent | 48389ef17583f2214bbd2c119b3015677419c16b (diff) |
xfs: Make fiemap work in query mode.
According to Documentation/filesystems/fiemap.txt, If fm_extent_count
is zero, then the fm_extents[] array is ignored (no extents will be
returned), and the fm_mapped_extents count will hold the number of
extents needed.
But as the commit 97db39a1f6f69e906e98118392400de5217aa33a has changed
bmv_count to the caller's input buffer, this number query function can't
work any more. As this commit is written to change bmv_count from
MAXEXTNUM because of ENOMEM.
This patch just try to set bm.bmv_count to something sane.
Thanks to Dave Chinner <david@fromorbit.com> for the suggestion.
Cc: Eric Sandeen <sandeen@redhat.com>
Cc: Alex Elder <aelder@sgi.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Tao Ma <tao.ma@oracle.com>
Diffstat (limited to 'fs/xfs/xfs_iomap.c')
0 files changed, 0 insertions, 0 deletions