WARNING - OLD ARCHIVES

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/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

RE: [Xen-users] Re: [Xen-devel] Xen - Guest memory allocation

To: Grzegorz Miłoś <gm281@xxxxxxxxx>, xen developers community <xen-devel@xxxxxxxxxxxxxxxxxxx>, xen users community <xen-users@xxxxxxxxxxxxxxxxxxx>
Subject: RE: [Xen-users] Re: [Xen-devel] Xen - Guest memory allocation
From: dinesh chandrasekaran <dinesh_chan8@xxxxxxxxxxx>
Date: Tue, 1 Jul 2008 02:52:25 +0530
Cc:
Delivery-date: Mon, 30 Jun 2008 14:22:48 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
Importance: Normal
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>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Okay.
              But I want to use 'I/O pages: memory in the memory mapped IO regions obtained by reading the BAR value from the pci device'
as the 'real' memory for all DomUs since I have 256MB behind that device.

From your reply,
I should use populate_physmap() only if that memory is exported as E820_RAM i.e if DomUs are to be restricted to specific range of the RAM.

And to use the addresses specified by the PCI BAR, I should use XEN_DOMCTL_iomem_permission.

'MEMORY' in the memory mapped IO regions obtained by reading the BAR value of the pci device.
But, wont this MEMORY be mapped to the actual RAM behind the CPU?

How could I completely avoid the RAM behind CPU and use the PCI memory for all DomUs?

Putting it simple, during boot-up process,

__  __            _____  _____                    _        _     _     
 \ \/ /___ _ __   |___ / |___ /    _   _ _ __  ___| |_ __ _| |__ | | ___
  \  // _ \ '_ \    |_ \   |_ \ __| | | | '_ \/ __| __/ _` | '_ \| |/ _ \
  /  \  __/ | | |  ___) | ___) |__| |_| | | | \__ \ || (_| | |_) | |  __/
 /_/\_\___|_| |_| |____(_)____/    \__,_|_| |_|___/\__\__,_|_.__/|_|\___|
                                                                        
(XEN)Xen version 3.3-unstable (reddy@(none)) (gcc version 4.1.1 (Gentoo4.1.1-r3)) Sat May 31 00:05:56 Local time zone must be set--see zicmanual page 2008
(XEN) Latest ChangeSet: Fri May 30 19:31:18 2008 +0100 17760:6e688d5a936b
(XEN) Command line:
(XEN) Video information:
(XEN)  VGA is text mode 80x25, font 8x16
(XEN)  VBE/DDC methods: V2; EDID transfer time: 2 seconds
(XEN) Disc information:
(XEN)  Found 1 MBR signatures
(XEN)  Found 1 EDD information structures
(XEN) Xen-e820 RAM map:
(XEN)  0000000000000000 - 0000000000094400 (usable)
(XEN)  0000000000094400 - 00000000000a0000 (reserved)
(XEN)  00000000000c2000 - 0000000000100000 (reserved)
(XEN)  0000000000100000 - 00000000cfe90000 (usable)
(XEN)  00000000cfe90000 - 00000000cfea3000 (ACPI data)
(XEN)  00000000cfea3000 - 00000000cff00000 (ACPI NVS)
(XEN)  00000000cff00000 - 00000000d0000000 (reserved)
(XEN)  00000000e0000000 - 00000000f0000000 (reserved)
(XEN)  00000000fec00000 - 00000000fec00400 (reserved)
(XEN)  00000000fee00000 - 00000000fee01000 (reserved)
(XEN)  00000000fff80000 - 0000000100000000 (reserved)
(XEN)  0000000100000000 - 0000000230000000 (usable)
(XEN)  00000000d0000000 - 00000000dfffffff (PCI_usable)             <this is the pci_device's BAR value>

Is this 256MB space from the RAM behind CPU?
or is this the address exclusiveley given to the RAM behind PCI?
Writing into this address will not require any re-mapping into CPU RAM?

Thanks,
Dinesh C



> Date: Mon, 30 Jun 2008 21:54:36 +0100
> From: gm281@xxxxxxxxx
> To: dinesh_chan8@xxxxxxxxxxx
> Subject: Re: [Xen-users] Re: [Xen-devel] Xen - Guest memory allocation
>
> Here is a brief terminology overview, to clear up any naming confusion:
> - I/O pages: memory in the memory mapped IO regions (a.k.a. IO memory)
> - 'real' memory: RAM
>
> > But let the Dom0 take care of I/O pages for all DomUs (hope this is the
> > default).
>
> By default Dom0 is allowed to access any IO memory, and DomUs aren't
> allowed to access any IO memory. In your email from 20th June you
> indicated that you want to allow DomUs to access certain IO memory
> range. In my previous email I suggested to look at using
> XEN_DOMCTL_iomem_permission to achieve that. You don't need to change
> populate_physmap to get that working I believe (I'm assuming PV domain
> here).
>
> > I'm just trying for the making Memory pages and NOT I/O pages for all DomUs
> > available from the my_pci address range
> > using populate_physmap().
>
> ?. Surely you either mean: RAM outside of my_pci range, or IO memory
> from my_pci range.
>
> >> You do need 'real' memory to be assigned to DomU.
> > Yeah. That is the reason why I used maddr_to_page() macro;
> >
> > I assume that xen uses populate_physmap() to allocate 'real' memory for all
> > DomUs.
> > Is my assumption wrong?
>
> Correct. populate_physmap() allocates RAM.
>
> Cheers
> Gr(z)egor(z)


Live.in : Get your yourname@xxxxxxx email id today. Powered by Windows Live Hotmail. Check it out!
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>