lkml.org 
[lkml]   [2016]   [Oct]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: btrfs_direct_IO oops
On Sat, Oct 08, 2016 at 07:29:03PM +0100, Al Viro wrote:
> On Sat, Oct 08, 2016 at 02:08:06PM -0400, Dave Jones wrote:
> > That code: matches this dissembly:
> >
> > for (i = seg + 1; i < iter->nr_segs; i++) {
>
> *whoa*
>
> OK, that loop in check_direct_IO() should be done *ONLY* for
> iovec iter - even for a bvec one it's completely bogus, and
> for pipe ones it blows up immediately.
>
> Sorry, I'd missed that bogosity - replace
> if (iov_iter_rw(iter) == WRITE)
> return 0;
> with
> if (iov_iter_rw(iter) != READ || !iter_is_iovec(iter))
> return 0;
> in there; that should fix the damn thing.

Yep, seems to do the trick. Have been running the last six hours
without seeing it or anything similar since.

Dave

\
 
 \ /
  Last update: 2016-10-09 01:22    [W:0.052 / U:0.396 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site