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


Groups > linux.kernel > #1625681 > unrolled thread

Re: [PATCH 1/4] fs: fix data invalidation in the cleancache during direct IO

Started byAndrew Morton <akpm@linux-foundation.org>
First post2017-04-19 00:50 +0200
Last post2017-04-19 00:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH 1/4] fs: fix data invalidation in the cleancache during  direct IO Andrew Morton <akpm@linux-foundation.org> - 2017-04-19 00:50 +0200

#1625681 — Re: [PATCH 1/4] fs: fix data invalidation in the cleancache during direct IO

FromAndrew Morton <akpm@linux-foundation.org>
Date2017-04-19 00:50 +0200
SubjectRe: [PATCH 1/4] fs: fix data invalidation in the cleancache during direct IO
Message-ID<txK6C-3m1-5@gated-at.bofh.it>
On Fri, 14 Apr 2017 17:07:50 +0300 Andrey Ryabinin <aryabinin@virtuozzo.com> wrote:

> Some direct write fs hooks call invalidate_inode_pages2[_range]()
> conditionally iff mapping->nrpages is not zero. If page cache is empty,
> buffered read following after direct IO write would get stale data from
> the cleancache.
> 
> Also it doesn't feel right to check only for ->nrpages because
> invalidate_inode_pages2[_range] invalidates exceptional entries as well.
> 
> Fix this by calling invalidate_inode_pages2[_range]() regardless of nrpages
> state.

I'm not understanding this.  I can buy the argument about
nrexceptional, but why does cleancache require the
invalidate_inode_pages2_range) call even when ->nrpages is zero?

I *assume* it's because invalidate_inode_pages2_range() calls
cleancache_invalidate_inode(), yes?  If so, can we please add this to
the changelog?  If not then please explain further.

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web