Btrfs: Limit inline extents to root->sectorsize
authorChandan Rajendra <chandan@linux.vnet.ibm.com>
Thu, 21 Jan 2016 10:26:01 +0000 (15:56 +0530)
committerDavid Sterba <dsterba@suse.com>
Mon, 1 Feb 2016 18:24:29 +0000 (19:24 +0100)
commit0c29ba993e4b08771deb20f8717a4b57cc7e678b
tree78f0190cfc726cfc63c154f2b64945147bcfd71c
parent5f4dc8fc835bbb902f5c2aa3de3978f3f518aa73
Btrfs: Limit inline extents to root->sectorsize

cow_file_range_inline() limits the size of an inline extent to
PAGE_CACHE_SIZE. This breaks in subpagesize-blocksize scenarios. Fix this by
comparing against root->sectorsize.

Reviewed-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: Chandan Rajendra <chandan@linux.vnet.ibm.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/inode.c