From: Andrew Morton <akpm@digeo.com>
To: Oleg Drokin <green@namesys.com>
Cc: jdike@karaya.com, roland@redhat.com,
linux-kernel@vger.kernel.org,
user-mode-linux-devel@lists.sourceforge.net
Subject: Re: build problems on architectures where FIXADDR_* stuff is not constant
Date: Tue, 13 May 2003 13:46:20 -0700 [thread overview]
Message-ID: <20030513134620.3dafeaf3.akpm@digeo.com> (raw)
In-Reply-To: <20030513122329.GA31609@namesys.com>
Oleg Drokin <green@namesys.com> wrote:
>
> Since there are architectures where FIXADDR_* stuff is not constant (e.g. UML),
> ...
> + fixmap_vma.vm_start = FIXADDR_START;
> + fixmap_vma.vm_end = FIXADDR_TOP;
> + fixmap_vma.vm_page_prot = PAGE_READONLY;
> pgd = pgd_offset_k(pg);
> if (!pgd)
> return i ? : -EFAULT;
That's modifying static storage which other, unrelated processes or CPUs
may be playing with.
The new code in get_user_pages() is rather rude - it's returning a
statically allocated VMA which isn't in the VMA tree - the caller (who
holds mmap_sem()) could reasonably expect that the VMA can be located via
find_vma(), or removed from the tree or whatever. But it cannot.
I think it needs to be redone. Either by stuffing a VMA into every
process's mm which describes the fixmap area, or by failing
get_user_pages() if the caller has passed in a non-NULL `vmas' and is
requesting access to the fixmap area.
Probably the latter. That'll require that access_process_vm() be changed
to not require a vma. It's only using the vma for cache flushing, but the
flishing in there is borked anyway.
next prev parent reply other threads:[~2003-05-13 20:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-05-13 12:23 build problems on architectures where FIXADDR_* stuff is not constant Oleg Drokin
2003-05-13 20:46 ` Andrew Morton [this message]
2003-05-13 23:56 ` Andrew Morton
2003-05-14 5:32 ` Oleg Drokin
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=20030513134620.3dafeaf3.akpm@digeo.com \
--to=akpm@digeo.com \
--cc=green@namesys.com \
--cc=jdike@karaya.com \
--cc=linux-kernel@vger.kernel.org \
--cc=roland@redhat.com \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/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;
as well as URLs for NNTP newsgroup(s).