]> git.baikalelectronics.ru Git - kernel.git/commit
direct-io: fix AIO regression
authorChristoph Hellwig <hch@lst.de>
Wed, 30 Jul 2014 11:18:48 +0000 (07:18 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Fri, 1 Aug 2014 06:35:51 +0000 (02:35 -0400)
commit540d3e0581f08d9225d4e7f70c170e3702646591
tree282f8b70abda0aa10827d4237cee4c408260748c
parent275887191d26ecf8aa27dd87f9be136ec0c8fa33
direct-io: fix AIO regression

The direct-io.c rewrite to use the iov_iter infrastructure stopped updating
the size field in struct dio_submit, and thus rendered the check for
allowing asynchronous completions to always return false.  Fix this by
comparing it to the count of bytes in the iov_iter instead.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reported-by: Tim Chen <tim.c.chen@linux.intel.com>
Tested-by: Tim Chen <tim.c.chen@linux.intel.com>
fs/direct-io.c