From: Peter Zijlstra <a.p.zijlstra@chello.nl>
To: Miklos Szeredi <miklos@szeredi.hu>
Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
linux-mm@kvack.org
Subject: Re: [patch 2/2] only allow nonlinear vmas for ram backed filesystems
Date: Thu, 05 Apr 2007 11:50:00 +0200 [thread overview]
Message-ID: <1175766600.6483.100.camel@twins> (raw)
In-Reply-To: <E1HZORc-0000UZ-00@dorka.pomaz.szeredi.hu>
On Thu, 2007-04-05 at 11:39 +0200, Miklos Szeredi wrote:
> > > + /*
> > > + * page_mkclean doesn't work on nonlinear vmas, so if dirty
> > > + * pages need to be accounted, emulate with linear vmas.
> > > + */
> > > + if (mapping_cap_account_dirty(mapping)) {
> >
> > Perhaps this should read:
> >
> > if (vma_wants_writenotify(vma)) {
> >
>
> I looked at that, but IIRC vma_wants_writenotify() doesn't work after
> mmap(), because of the updated protection bits.
Right, bother, that again. I fudged it in mprotect by setting the pgprot
bits to what was expected although I had a parametrised version earlier.
But that was disliked.
> > That way we would even allow read only non-linear mappings of 'real'
> > filesystem files.
>
> Well, we could do that, but is it really worth the hassle? The real
> question is whether anyone would want to use non-linear
> shared-read-only mappings or not.
Hmm, yeah, I thought that was the case with that code snippet Andrew
pulled of the interweb, but on second inspection they do map it writable
too. I was led astray by the fact that they map the same file twice.
Oh well, lets just keep the patch as is then.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
prev parent reply other threads:[~2007-04-05 9:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-05 9:29 [patch 1/2] split mmap Miklos Szeredi
2007-04-05 9:30 ` [patch 2/2] only allow nonlinear vmas for ram backed filesystems Miklos Szeredi, Miklos Szeredi
2007-04-05 9:36 ` Peter Zijlstra
2007-04-05 9:39 ` Miklos Szeredi
2007-04-05 9:50 ` Peter Zijlstra [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1175766600.6483.100.camel@twins \
--to=a.p.zijlstra@chello.nl \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=miklos@szeredi.hu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox