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-changelog

[Xen-changelog] Do not accept empty definition of __XEN_INTERFACE_VERSIO

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Do not accept empty definition of __XEN_INTERFACE_VERSION__
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 07 Apr 2006 10:10:06 +0000
Delivery-date: Fri, 07 Apr 2006 03:10:51 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 0037e3e4da08eccefc415e41749606e683916ae1
# Parent  0010df11836d182fbb00ebcc016e9e51705470e0
Do not accept empty definition of __XEN_INTERFACE_VERSION__
in xen-compat.h. It leads to building a broken kernel image
where the kernel sources end up using an unexpected interface
version. In the case of Linux, the kernel expects to use
the new sched_op() hypercall but ends up calling the
legacy hypercall -- this breaks poll, reboot, and save/restore.

A more acceptable patch would be to detect the empty
definition in xen-compat.h and give a reasonable #error message
to fail the build: the current error message is confusing.

Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>

diff -r 0010df11836d -r 0037e3e4da08 xen/include/public/xen-compat.h
--- a/xen/include/public/xen-compat.h   Thu Apr  6 23:32:54 2006
+++ b/xen/include/public/xen-compat.h   Fri Apr  7 08:57:36 2006
@@ -14,11 +14,8 @@
 #if defined(__XEN__)
 /* Xen is built with matching headers and implements the latest interface. */
 #define __XEN_INTERFACE_VERSION__ __XEN_LATEST_INTERFACE_VERSION__
-#elif (__XEN_INTERFACE_VERSION__ - 0) == 0
+#elif !defined(__XEN_INTERFACE_VERSION__)
 /* Guests which do not specify a version get the legacy interface. */
-#ifdef __XEN_INTERFACE_VERSION__
-#undef __XEN_INTERFACE_VERSION__
-#endif
 #define __XEN_INTERFACE_VERSION__ 0x00000000
 #endif
 

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Do not accept empty definition of __XEN_INTERFACE_VERSION__, Xen patchbot -unstable <=