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-ia64-devel

Re: [Xen-ia64-devel] [PATCH] make xenLinux/ia64 privcmd mmap not to use

To: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
Subject: Re: [Xen-ia64-devel] [PATCH] make xenLinux/ia64 privcmd mmap not to use dom0 memory.
From: Alex Williamson <alex.williamson@xxxxxx>
Date: Thu, 18 May 2006 15:30:21 -0600
Cc: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 18 May 2006 14:30:34 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20060518133758.GE27665%yamahata@xxxxxxxxxxxxx>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Organization: LOSL
References: <20060516101647.GC20883%yamahata@xxxxxxxxxxxxx> <20060518133758.GE27665%yamahata@xxxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Thu, 2006-05-18 at 22:37 +0900, Isaku Yamahata wrote:
> Alex.
> xen_ia64_privcmd_init() tries to guess where pseudo physicall address
> region can be used for the priv cmd mmap by heuristics.
> Although I tested this patch on tiger2 and tiger4, I'm not sure
> about other platforms.
> Because your testing box has more complicated memory arrangement,
> Could you confirm it?

Hi Isaku,

   Yes, this seems to work on box:

xen privcmd uses pseudo physical addr range [0x10100000000, 0x3ffff000000]

> +
> +static int __init
> +xen_ia64_privcmd_init(void)
> +{
> +        void *efi_map_start, *efi_map_end, *p;
> +        u64 efi_desc_size;
> +        efi_memory_desc_t *md;
> +       unsigned long tmp_min;
> +       unsigned long tmp_max;
> +       unsigned long gap_size;

   Should we have a xen_init()/running_on_xen() and dom0 check here?  I
don't think we want to initialize this on either the transparent
virtualization or the domU case, right?

> +       
> +        for (p = efi_map_start; p < efi_map_end; p += efi_desc_size)
> {
> +               md = p;
> +               if (md->attribute & EFI_MEMORY_WB) {
> +                       tmp_min = md_end_addr(md);
> +               }
> +       }
> +       privcmd_resource_min = GRANULEROUNDUP(tmp_min);

   Can this range overlap non-WB ranges?  If so, it seems strange that
we would go to so much trouble trying to tuck this at the end of memory
or in a hole.  Thanks,

        Alex

-- 
Alex Williamson                             HP Linux & Open Source Lab


_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel