From: Andrea Arcangeli <andrea@suse.de>
To: Ian Pratt <Ian.Pratt@cl.cam.ac.uk>
Cc: linux-kernel@vger.kernel.org, Steven.Hand@cl.cam.ac.uk,
Christian.Limpach@cl.cam.ac.uk, Keir.Fraser@cl.cam.ac.uk,
"David S. Miller" <davem@redhat.com>,
William Lee Irwin III <wli@holomorphy.com>
Subject: Re: [4/7] Xen VMM patch set : /dev/mem io_remap_page_range for CONFIG_XEN
Date: Tue, 30 Nov 2004 04:08:12 +0100 [thread overview]
Message-ID: <20041130030812.GN4365@dualathlon.random> (raw)
In-Reply-To: <E1CVI5c-0004bf-00@mta1.cl.cam.ac.uk>
On Fri, Nov 19, 2004 at 11:22:51PM +0000, Ian Pratt wrote:
>
> This patch modifies /dev/mem to call io_remap_page_range rather than
> remap_pfn_range under CONFIG_XEN. This is required because in arch
Why don't we change /dev/mem to use io_remap_page_range unconditionally
for ranges above high_memory? Clearly io_remap_page_range can map device
space, and I guess that's what io_remap_page_range is there for. sparc
and sparc64 are the only two ones implementing io_remap_page_range, so
maybe Dave or Wli can tell us if there's any penalty in using
io_remap_page_range in mmap(/dev/mmap) for phys ranges above
high_memory. I don't know the sparc architectural details of mk_pte_io
invoked by io_remap_page_range of the sparc arch.
There's also an issue with io_remap_page_range where sparc has 6 args
while everyone else has 5 args. It's perfectly fine that sparc will be
the only one parsing the last value, but we should pass that last value
to all archs, so that people can avoid writing code like the below
(drivers/char/drm):
#ifdef __sparc__
if (io_remap_page_range(DRM_RPR_ARG(vma) vma->vm_start,
VM_OFFSET(vma) + offset,
vma->vm_end - vma->vm_start,
vma->vm_page_prot, 0))
#else
if (remap_pfn_range(DRM_RPR_ARG(vma) vma->vm_start,
(VM_OFFSET(vma) + offset) >> PAGE_SHIFT,
vma->vm_end - vma->vm_start,
vma->vm_page_prot))
#endif
Thanks.
next prev parent reply other threads:[~2004-11-30 3:08 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-11-19 23:16 Xen VMM patch set - take 2 Ian Pratt
2004-11-19 23:20 ` [1/7] Xen VMM patch set : add ptep_establish_new to make va available Ian Pratt
2004-11-19 23:20 ` [2/7] Xen VMM patch set : return code for arch_free_page Ian Pratt
2004-11-30 2:28 ` Andrea Arcangeli
2004-11-19 23:21 ` [3/7] Xen VMM patch set : runtime disable of VT console Ian Pratt
2004-11-19 23:22 ` [4/7] Xen VMM patch set : /dev/mem io_remap_page_range for CONFIG_XEN Ian Pratt
2004-11-20 2:03 ` William Lee Irwin III
2004-11-20 16:31 ` Christoph Hellwig
2004-11-20 18:03 ` Ian Pratt
2004-11-27 12:39 ` Ian Pratt
2004-11-27 16:51 ` Randy.Dunlap
2004-11-30 3:08 ` Andrea Arcangeli [this message]
2004-11-30 3:14 ` David S. Miller
2004-11-30 3:38 ` William Lee Irwin III
2004-11-30 8:56 ` Ian Pratt
2004-11-30 9:04 ` Arjan van de Ven
2004-11-30 12:09 ` Ian Pratt
2004-11-30 12:14 ` Arjan van de Ven
2004-11-30 12:18 ` Arjan van de Ven
2004-11-30 13:16 ` Ian Pratt
2004-11-30 18:03 ` Andrea Arcangeli
2004-12-04 23:49 ` Ian Pratt
2004-12-05 0:40 ` Andrea Arcangeli
2004-12-05 2:47 ` William Lee Irwin III
2004-11-19 23:23 ` [5/7] Xen VMM patch set : split free_irq into teardown_irq Ian Pratt
2004-11-20 16:32 ` Christoph Hellwig
2004-11-20 19:20 ` Ian Pratt
2004-11-27 12:45 ` Ian Pratt
2004-11-19 23:25 ` [6/7] Xen VMM patch set : add alloc_skb_from_cache Ian Pratt
2004-11-20 2:11 ` James Morris
2004-11-20 6:03 ` Chris Wedgwood
2004-11-20 6:47 ` David S. Miller
2004-11-20 10:28 ` Keir Fraser
2004-11-20 10:33 ` Chris Wedgwood
2004-11-19 23:28 ` [7/7] Xen VMM patch set : handle fragemented skbs correctly in icmp_filter Ian Pratt
2004-11-25 15:46 ` Xen VMM patch set - take 2 Ian Pratt
2004-11-28 17:07 ` Rik van Riel
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=20041130030812.GN4365@dualathlon.random \
--to=andrea@suse.de \
--cc=Christian.Limpach@cl.cam.ac.uk \
--cc=Ian.Pratt@cl.cam.ac.uk \
--cc=Keir.Fraser@cl.cam.ac.uk \
--cc=Steven.Hand@cl.cam.ac.uk \
--cc=davem@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=wli@holomorphy.com \
/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