BTRFS: support NFSv2 export
authorNeilBrown <neilb@suse.de>
Fri, 8 May 2015 00:16:23 +0000 (10:16 +1000)
committerChris Mason <clm@fb.com>
Tue, 6 Oct 2015 13:55:23 +0000 (06:55 -0700)
commit7d35199e15b82a4d1a20049153b03e6258ce79f7
tree285948462f1025eba99217bbb979399f414b41d5
parente5fffbac4a49270e4976d71a0e054c0cf3ef4f8e
BTRFS: support NFSv2 export

The "fh_len" passed to ->fh_to_* is not guaranteed to be that same as
that returned by encode_fh - it may be larger.

With NFSv2, the filehandle is fixed length, so it may appear longer
than expected and be zero-padded.

So we must test that fh_len is at least some value, not exactly equal
to it.

Signed-off-by: NeilBrown <neilb@suse.de>
Acked-by: David Sterba <dsterba@suse.cz>
fs/btrfs/export.c