xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@linaro.org>
To: Andrii Anisov <andrii.anisov@globallogic.com>
Cc: Oleksandr Tyshchenko <oleksandr.tyshchenko@globallogic.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	Tim Deegan <tim@xen.org>, Ian Campbell <Ian.Campbell@citrix.com>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Subject: Re: Restart domU failure (memory allocation issue)
Date: Fri, 14 Mar 2014 14:00:20 +0000	[thread overview]
Message-ID: <53230B74.6090105@linaro.org> (raw)
In-Reply-To: <CAGQvs6iZr3G83ZRVi0X1VLPER7w8p=QfFU5F9ZDXAtdx3XFNQg@mail.gmail.com>

On 03/14/2014 12:45 PM, Andrii Anisov wrote:
>     It seems that unmap will be done at the end of xc_dom_boot_image (see
>     xc_dom_unmap_all).
>     The latter function will go through the list of all mappings and close
>     it one by one.
>     You can add a print in xc_dom_unmap_one (tools/libxc/xc_dom_core.c) and
>     check if you have the same number of print with
>     xc_dom_pfn_to_ptr_retcount.
> 
> 
> As I see xc_dom_unmap_all ends with munmap(), what actually unmaps pages
> from process virtual memory space. But I have doubts if it is aware
> about cross domain mapping and cares about it.

This is done in kernel space. When you map the pages, privcmd will set
specific callbacks that will be use when munmap will be called (see
privcmd_close in drivers/xen/privcmd.c).

The privcmd_close function will call the hypercall to remove the foreign
page from the p2m.

-- 
Julien Grall

  reply	other threads:[~2014-03-14 14:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-13 18:33 Restart domU failure (memory allocation issue) Oleksandr Tyshchenko
2014-03-13 19:48 ` Julien Grall
2014-03-14 11:10   ` Andrii Anisov
2014-03-14 11:14     ` Andrii Anisov
2014-03-14 12:15       ` Julien Grall
2014-03-14 12:45         ` Andrii Anisov
2014-03-14 14:00           ` Julien Grall [this message]
2014-03-14 14:05             ` Andrii Anisov
2014-03-14 14:17               ` Julien Grall
2014-03-14 14:37                 ` Oleksandr Tyshchenko
2014-03-14 14:08             ` Oleksandr Tyshchenko

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=53230B74.6090105@linaro.org \
    --to=julien.grall@linaro.org \
    --cc=Ian.Campbell@citrix.com \
    --cc=andrii.anisov@globallogic.com \
    --cc=oleksandr.tyshchenko@globallogic.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=tim@xen.org \
    --cc=xen-devel@lists.xen.org \
    /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).