This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


Re: [Xen-devel] Is there a way to map pv guest pseudo physical address i

To: Wei Liu <liuw@xxxxxxxxx>
Subject: Re: [Xen-devel] Is there a way to map pv guest pseudo physical address into dom0?
From: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Date: Mon, 27 Jun 2011 10:01:57 +0100
Cc: Anthony, Perard <anthony.perard@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <Stefano.Stabellini@xxxxxxxxxxxxx>
Delivery-date: Mon, 27 Jun 2011 02:06:57 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <BANLkTimW6NZRSR39WpSFrKfxCtDMCheMoA@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: Citrix Systems, Inc.
References: <BANLkTimW6NZRSR39WpSFrKfxCtDMCheMoA@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Mon, 2011-06-27 at 09:47 +0100, Wei Liu wrote:
> Hi, all
> I'm reading the code of QEMU's virtio infrastructure (hw/virtio.c) and
> Linux's virtio driver (virtio_blk.c, virtio_net.c).
> Virtio drivers utilize scatter gather infrastructure in the Linux
> kernel. It stores the physical addresses in scatter list. In Xen's hvm
> case, QEMU can access guest address space with
> cpu_physical_memory_map.
> However, in Xen's pv case, this "physical address" will be "pseudo
> physical address". In order to retrieve theirs content, backend must
> map them into its own address space. I'm wondering if there is such
> infrastructure to get this job done.

I think you want one of xc_map_* provided by libxc (see xenctrl.h). (But
avoid xc_map_foreign_batch which is deprecated).


Xen-devel mailing list