From: Gerd Knorr Subject: [patch] auto-enable translated shadow mode ... Date: Thu, 28 Jul 2005 17:19:07 +0200 Message-ID: <20050728151907.GB21125@bytesex> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org ... for dom0 if we know we'll need it. This is the xen counterpart to the previous xenlinux patch which adds this info to the kernel. Also adds some printk's. Gerd Index: xen/arch/x86/domain_build.c =================================================================== --- xen.orig/arch/x86/domain_build.c 2005-07-28 17:09:39.000000000 +0200 +++ xen/arch/x86/domain_build.c 2005-07-28 17:11:03.000000000 +0200 @@ -165,6 +165,8 @@ int construct_dom0(struct domain *d, xen_pae ? "yes" : "no", dom0_pae ? "yes" : "no"); return -EINVAL; } + if (strstr(dsi.xen_section_string, "SHADOW=translate")) + opt_dom0_translate = 1; /* Align load address to 4MB boundary. */ dsi.v_start &= ~((1UL<<22)-1); @@ -620,11 +622,13 @@ int construct_dom0(struct domain *d, if ( opt_dom0_shadow || opt_dom0_translate ) { + printk("dom0: shadow enable\n"); shadow_mode_enable(d, (opt_dom0_translate ? SHM_enable | SHM_refcounts | SHM_translate : SHM_enable)); if ( opt_dom0_translate ) { + printk("dom0: shadow translate\n"); #if defined(__i386__) && defined(CONFIG_X86_PAE) printk("FIXME: PAE code needed here: %s:%d (%s)\n", __FILE__, __LINE__, __FUNCTION__); @@ -657,6 +661,7 @@ int construct_dom0(struct domain *d, } update_pagetables(v); /* XXX SMP */ + printk("dom0: shadow setup done\n"); } return 0;