All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Fix ia64 tools build
@ 2010-09-02  4:43 KUWAMURA Shin'ya
  2010-10-29  7:39 ` KUWAMURA Shin'ya
  0 siblings, 1 reply; 9+ messages in thread
From: KUWAMURA Shin'ya @ 2010-09-02  4:43 UTC (permalink / raw)
  To: xen-devel

[-- Attachment #1: Type: Text/Plain, Size: 459 bytes --]

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@jp.fujitsu.com>
-- 
  KUWAMURA Shin'ya

[-- Attachment #2: fix-ia64-tools-aclinux.patch --]
[-- Type: Text/X-Patch, Size: 2237 bytes --]

# HG changeset patch
# User KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
# 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@jp.fujitsu.com>

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

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

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

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-11-02  0:43 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-09-02  4:43 [PATCH] Fix ia64 tools build KUWAMURA Shin'ya
2010-10-29  7:39 ` KUWAMURA Shin'ya
2010-10-29  7:55   ` Keir Fraser
2010-10-29 13:12     ` Ian Campbell
2010-11-01  8:39     ` KUWAMURA Shin'ya
2010-11-01  9:21       ` Keir Fraser
2010-11-01  9:28         ` Ian Campbell
2010-11-01  9:48           ` Keir Fraser
2010-11-02  0:43             ` KUWAMURA Shin'ya

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.