All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Wray <mike.wray@hp.com>
To: Keir Fraser <Keir.Fraser@cl.cam.ac.uk>
Cc: Ian Pratt <m+Ian.Pratt@cl.cam.ac.uk>,
	Rusty Russell <rusty@rustcorp.com.au>,
	Xen Mailing List <xen-devel@lists.xensource.com>,
	Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
Subject: Re: dom0 bootstrap for xenstore
Date: Thu, 16 Jun 2005 16:54:44 +0100	[thread overview]
Message-ID: <42B1A0C4.4090200@hp.com> (raw)
In-Reply-To: <c49743bea5e1b3f0cd7acfca8acc932c@cl.cam.ac.uk>

Keir Fraser wrote:
> 
> On 16 Jun 2005, at 09:11, Rusty Russell wrote:
> 
>> So here's my patch against latest bk, including test program but we have
>> an issue.  On unmap, I hit the BUG_ON() on mm/rmap.c:482.  Is this some
>> issue with using xc_map_foreign_range() on non-foreign pages?
> 
> 
> Ah, it's not working because xc_map_foreign_range does not raise refcnts 
> on the page being mapped. unmap_range then does the right thing for 
> foreign pages, and things like the local domain's shared_info page which 
> is really a Xen heap page, but will do the wrong thing for ordinary 
> pages out of the local domain's page allocator (like the xenstored 
> page). It will try to tear down rmap, drop refcnts, atc and get itself 
> into a mess.

Isn't it possible to fix xc_map_foreign_range() to do the right thing for
'ordinary' pages?

> On XenLinux, /dev/mem and /dev/kmem only work for mapping I/O memory.
> 
> Either we need a new interface for mmaping local xenstore page, or we 
> need to hack one of the existing /dev/mem or xc_map_foreign_range ioctl. 
> None of these options is very pleasant. :-(  I think simplest would be 
> to extend the gross /proc/xen/privcmd to have a mmap that we can use to 
> mmap xenstore page (maybe make a little more general purpose by turning 
> offset field of mmap into an enumeration, so we can map other useful 
> Xen-specific bits and bobs via it in the future).

OK, if xc_map_foreign_range() isn't fixable I guess we have to do something
like that.

Mike

  parent reply	other threads:[~2005-06-16 15:54 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <A95E2296287EAD4EB592B5DEEFCE0E9D282251@liverpoolst.ad.cl.cam.ac.uk>
     [not found] ` <1118891075.15491.14.camel@localhost.localdomain>
     [not found]   ` <ea6e31bae1f900c7b076535f372290a3@cl.cam.ac.uk>
2005-06-16  8:11     ` dom0 bootstrap for xenstore Rusty Russell
2005-06-16 13:55       ` Keir Fraser
2005-06-16 14:03         ` Keir Fraser
2005-06-16 15:54         ` Mike Wray [this message]
2005-06-16 19:40           ` Keir Fraser
2005-06-17  3:50         ` Rusty Russell
2005-06-17  7:31         ` Rusty Russell
2005-06-17 13:00           ` Mike Wray
2005-06-20  4:49             ` Rusty Russell
2005-06-20 15:39               ` Mike Wray

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=42B1A0C4.4090200@hp.com \
    --to=mike.wray@hp.com \
    --cc=Christian.Limpach@cl.cam.ac.uk \
    --cc=Keir.Fraser@cl.cam.ac.uk \
    --cc=m+Ian.Pratt@cl.cam.ac.uk \
    --cc=rusty@rustcorp.com.au \
    --cc=xen-devel@lists.xensource.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.