Re: [PATCH] btrfs: Return EINVAL when length to trim is less than FSB

2012-10-24 Thread Lukáš Czerner
On Tue, 16 Oct 2012, Lukas Czerner wrote: Date: Tue, 16 Oct 2012 11:34:36 +0200 From: Lukas Czerner lczer...@redhat.com To: linux-btrfs@vger.kernel.org Cc: jba...@fusionio.com, Lukas Czerner lczer...@redhat.com Subject: [PATCH] btrfs: Return EINVAL when length to trim is less than FSB

Re: [PATCH] btrfs: Return EINVAL when length to trim is less than FSB

2012-10-24 Thread Li Zefan
when length to trim is less than FSB Currently if len argument in btrfs_ioctl_fitrim() is smaller than one FSB we will continue and finally return 0 bytes discarded. However if the length to discard is smaller then file system block we should really return EINVAL. ping This patch has

[PATCH] btrfs: Return EINVAL when length to trim is less than FSB

2012-10-16 Thread Lukas Czerner
Currently if len argument in btrfs_ioctl_fitrim() is smaller than one FSB we will continue and finally return 0 bytes discarded. However if the length to discard is smaller then file system block we should really return EINVAL. Signed-off-by: Lukas Czerner lczer...@redhat.com ---