Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1403491

why does page_cache_pipe_buf_confirm() need to check page->mapping?

From Miklos Szeredi <miklos@szeredi.hu>
Newsgroups linux.kernel
Subject why does page_cache_pipe_buf_confirm() need to check page->mapping?
Date 2016-05-19 10:10 +0200
Message-ID <rArbV-5AA-19@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Jens,

I haven't done a great deal of research into this, but checking
page->mapping in page_cache_pipe_buf_confirm() might be bogus.

If the page is truncated *after* being spliced into the pipe, why on
earth does the buffer become invalid?

This looks to be a problem for filesystems that invalidate pages
(because the the data is possibly stale) and the pipe read returns
-ENODATA even though the data is there, it's just possibly different
from what was spliced into the pipe.  But I don't think that's a
reason for throwing away that buffer and definitely not a reason to
return an error.

Thanks,
Miklos

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

why does page_cache_pipe_buf_confirm() need to check page->mapping? Miklos Szeredi <miklos@szeredi.hu> - 2016-05-19 10:10 +0200

csiph-web