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

[Xen-devel] [PATCH] Fix ia64 tools build

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] Fix ia64 tools build
From: "KUWAMURA Shin'ya" <kuwa@xxxxxxxxxxxxxx>
Date: Thu, 02 Sep 2010 13:43:50 +0900 (JST)
Delivery-date: Wed, 01 Sep 2010 21:46:06 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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
Hi,

22066:eccfdeb41b80 replaced tools/libxc/ia64/aclinux.h with 
xen/include/acpi/platform/aclinux.h.

In fact, the former differs from the latter: the former supports
non-kernel codes, but the latter does not support it because
17814:9af7a535225f removed it.

Thus tools cannot be built on ia64.

This patch adds #ifdef __XEN__ and copies non-kernel support codes in
the former.

Signed-off-by: KUWAMURA Shin'ya <kuwa@xxxxxxxxxxxxxx>
-- 
  KUWAMURA Shin'ya
# HG changeset patch
# User KUWAMURA Shin'ya <kuwa@xxxxxxxxxxxxxx>
# Date 1283396295 -32400
# Node ID 6367f64a1c3529ac2702bfa498cc2500db39ec65
# Parent  c7405a5e2d6df9dcc9c0344da47f45ea8c884b23
Fix ia64 tools build

22066:eccfdeb41b80 replaced tools/libxc/ia64/aclinux.h with
xen/include/acpi/platform/aclinux.h.

In fact, the former differs from the latter: the former supports
non-kernel codes, but the latter does not support it because
17814:9af7a535225f removed it.

Thus tools cannot be built on ia64.

This patch adds #ifdef __XEN__ and copies non-kernel support codes in
the former.

Signed-off-by: KUWAMURA Shin'ya <kuwa@xxxxxxxxxxxxxx>

diff -r c7405a5e2d6d -r 6367f64a1c35 xen/include/acpi/platform/aclinux.h
--- a/xen/include/acpi/platform/aclinux.h       Thu Sep 02 10:59:50 2010 +0900
+++ b/xen/include/acpi/platform/aclinux.h       Thu Sep 02 11:58:15 2010 +0900
@@ -47,6 +47,8 @@
 #define ACPI_USE_SYSTEM_CLIBRARY
 #define ACPI_USE_DO_WHILE_0
 
+#ifdef __XEN__
+
 #include <xen/config.h>
 #include <xen/cache.h>
 #include <xen/string.h>
@@ -70,6 +72,50 @@
 /* Full namespace pathname length limit - arbitrary */
 #define ACPI_PATHNAME_MAX              256
 
+#else /* !__XEN__ */
+
+#include <stdarg.h>
+#include <string.h>
+//#include <stdlib.h>
+#include <ctype.h>
+#include <unistd.h>
+
+#if defined(__ia64__) || defined(__x86_64__)
+#define ACPI_MACHINE_WIDTH          64
+#define COMPILER_DEPENDENT_INT64    long
+#define COMPILER_DEPENDENT_UINT64   unsigned long
+#else
+#define ACPI_MACHINE_WIDTH          32
+#define COMPILER_DEPENDENT_INT64    long long
+#define COMPILER_DEPENDENT_UINT64   unsigned long long
+#define ACPI_USE_NATIVE_DIVIDE
+#endif
+
+typedef int8_t         s8;
+typedef uint8_t                u8;
+typedef int16_t                s16;
+typedef uint16_t       u16;
+typedef int32_t                s32;
+typedef uint32_t       u32;
+typedef int64_t                s64;
+typedef uint64_t       u64;
+#define __iomem
+#ifdef __ia64__
+#ifdef __cplusplus
+#define CPP_ASMLINKAGE extern "C"
+#else
+#define CPP_ASMLINKAGE
+#endif
+#define asmlinkage CPP_ASMLINKAGE __attribute__((syscall_linkage))
+#endif
+#define CONFIG_ACPI_BOOT       1
+
+#define __cdecl
+#define ACPI_FLUSH_CPU_CACHE()
+#endif /* __XEN__ */
+
+/* Linux uses GCC */
+
 #include "acgcc.h"
 
 #define acpi_cpu_flags unsigned long
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] Fix ia64 tools build, KUWAMURA Shin'ya <=