All of lore.kernel.org
 help / color / mirror / Atom feed
From: "KUWAMURA Shin'ya" <kuwa@jp.fujitsu.com>
To: xen-devel@lists.xensource.com
Subject: [PATCH] Fix ia64 tools build
Date: Thu, 02 Sep 2010 13:43:50 +0900 (JST)	[thread overview]
Message-ID: <20100902.134350.71558960.kuwa@jp.fujitsu.com> (raw)

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

             reply	other threads:[~2010-09-02  4:43 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-02  4:43 KUWAMURA Shin'ya [this message]
2010-10-29  7:39 ` [PATCH] Fix ia64 tools build 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

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100902.134350.71558960.kuwa@jp.fujitsu.com \
    --to=kuwa@jp.fujitsu.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.