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] PV-on-HVM driver for IPF

To: Doi.Tsunehisa@xxxxxxxxxxxxxx
Subject: Re: [Xen-ia64-devel] PV-on-HVM driver for IPF
From: Alex Williamson <alex.williamson@xxxxxx>
Date: Sun, 27 Aug 2006 19:52:36 -0600
Cc: Tristan Gingold <Tristan.Gingold@xxxxxxxx>, xen-ia64-devel <xen-ia64-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Sun, 27 Aug 2006 18:53:10 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200608272335.k7RNZ3Q11200@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
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: OSLO R&D
References: <44EDA623.7020906@xxxxxxxxxxxxxx> <200608241546.25980.Tristan.Gingold@xxxxxxxx> <200608242347.k7ONlNQ19109@xxxxxxxxxxxxxxxxxxxxxxxxxxx> <200608250910.21923.Tristan.Gingold@xxxxxxxx> <200608250731.k7P7VOQ01983@xxxxxxxxxxxxxxxxxxxxxxxxxxx> <44EEB51C.4030303@xxxxxxxxxxxxxx> <44EEB87A.4070008@xxxxxxxxxxxxxx> <1156547609.5554.19.camel@lappy> <44EFE003.3000005@xxxxxxxxxxxxxx> <1156689263.8384.14.camel@lappy> <200608272335.k7RNZ3Q11200@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Mon, 2006-08-28 at 08:35 +0900, Doi.Tsunehisa@xxxxxxxxxxxxxx wrote:
> 
>   In PV-on-HVM driver code, is_running_on_xen and HYPERVISOR_ioremap
> have to be used as valid feature. Thus we modified like this.

   Doesn't the below do what you need w/o breaking the CONFIG_XEN=n
build?  It's important to keep both builds working.  Thanks,

        Alex

Signed-off-by: Alex Williamson <alex.williamson@xxxxxx>
---

diff -r 3e0685ecfe64 linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h
--- a/linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h        Fri Aug 25 
16:21:39 2006 -0600
+++ b/linux-2.6-xen-sparse/include/asm-ia64/hypervisor.h        Sun Aug 27 
19:50:59 2006 -0600
@@ -59,8 +59,6 @@ extern shared_info_t *HYPERVISOR_shared_
 extern shared_info_t *HYPERVISOR_shared_info;
 extern start_info_t *xen_start_info;
 
-#define is_initial_xendomain() (xen_start_info->flags & SIF_INITDOMAIN)
-
 void force_evtchn_callback(void);
 
 /* Turn jiffies into Xen system time. XXX Implement me. */
@@ -182,10 +180,26 @@ MULTI_update_va_mapping(
        mcl->result = 0;
 }
 
+static inline void
+MULTI_grant_table_op(multicall_entry_t *mcl, unsigned int cmd,
+       void *uop, unsigned int count)
+{
+       mcl->op = __HYPERVISOR_grant_table_op;
+       mcl->args[0] = cmd;
+       mcl->args[1] = (unsigned long)uop;
+       mcl->args[2] = count;
+}
+
 // for debug
 asmlinkage int xprintk(const char *fmt, ...);
 #define xprintd(fmt, ...)      xprintk("%s:%d " fmt, __func__, __LINE__, \
                                        ##__VA_ARGS__)
 #endif /* CONFIG_XEN */
 
+#ifdef CONFIG_XEN_PRIVILEGED_GUEST
+#define is_initial_xendomain() (xen_start_info->flags & SIF_INITDOMAIN)
+#else
+#define is_initial_xendomain() 0
+#endif
+
 #endif /* __HYPERVISOR_H__ */



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