Re: Pending splice(file -> FIFO) excludes all other FIFO operations forever (was: ... always blocks read(FIFO), regardless of O_NONBLOCK on read side?)

From: Matthew Wilcox
Date: Fri Jul 07 2023 - 20:00:42 EST


On Thu, Jul 06, 2023 at 02:56:45PM -0700, Linus Torvalds wrote:
> +static int busy_pipe_buf_confirm(struct pipe_inode_info *pipe,
> + struct pipe_buffer *buf)
> +{
> + struct page *page = buf->page;
> +
> + if (folio_wait_bit_interruptible(page_folio(page), PG_locked))
> + return -EINTR;

Do we really want interruptible here rather than killable? That is,
do we want SIGWINCH or SIGALRM to result in a short read? I assume
it's OK to return a short read because userspace has explicitly asked
for O_NONBLOCK and can therefore be expected to actually check the
return value from read().