Thread (5 messages) 5 messages, 3 authors, 2021-03-01

Re: linux-next: manual merge of the akpm-current tree with the btrfs tree

From: Christoph Hellwig <hch@lst.de>
Date: 2021-02-26 05:17:27
Also in: lkml

On Fri, Feb 26, 2021 at 10:32:50AM +1100, Stephen Rothwell wrote:
quoted
quoted
 -	return filemap_read(iocb, to, ret);
 +	if (iocb->ki_flags & IOCB_NOWAIT)
 +		iocb->ki_flags |= IOCB_NOIO;
 +
- 	ret = generic_file_buffered_read(iocb, to, ret);
++	ret = filemap_read(iocb, to, ret);
 +
 +	if (iocb->ki_flags & IOCB_NOWAIT) {
 +		iocb->ki_flags &= ~IOCB_NOIO;
 +		if (ret == 0)
 +			ret = -EAGAIN;
 +	}
 +
 +	return ret;
  }
I think the above code looks completely bogus.  Instead whatever code
in btrfs hecks for IOCB_NOIO to avoid blocking readahead should also
check IOCB_NOWAIT.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help