aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--xen/common/lib.c2
-rw-r--r--xen/common/page_alloc.c2
-rw-r--r--xen/common/time.c2
-rw-r--r--xen/drivers/passthrough/vtd/intremap.c6
-rw-r--r--xen/drivers/passthrough/vtd/iommu.c2
-rw-r--r--xen/drivers/passthrough/vtd/utils.c2
-rw-r--r--xen/include/xen/elfcore.h2
-rw-r--r--xen/include/xen/hvm/irq.h2
8 files changed, 10 insertions, 10 deletions
diff --git a/xen/common/lib.c b/xen/common/lib.c
index e9d0637b68..03c8b8b8f4 100644
--- a/xen/common/lib.c
+++ b/xen/common/lib.c
@@ -423,7 +423,7 @@ s64 __ldivmod_helper(s64 a, s64 b, s64 *r)
/* Compute with 96 bit intermediate result: (a*b)/c */
uint64_t muldiv64(uint64_t a, uint32_t b, uint32_t c)
{
-#ifdef __x86_64__
+#ifdef CONFIG_X86
asm ( "mul %%rdx; div %%rcx" : "=a" (a) : "0" (a), "d" (b), "c" (c) );
return a;
#else
diff --git a/xen/common/page_alloc.c b/xen/common/page_alloc.c
index 1d7359db29..ae309faf3e 100644
--- a/xen/common/page_alloc.c
+++ b/xen/common/page_alloc.c
@@ -1141,7 +1141,7 @@ void __init scrub_heap_pages(void)
* XEN-HEAP SUB-ALLOCATOR
*/
-#if !defined(__x86_64__)
+#if !defined(CONFIG_X86)
void init_xenheap_pages(paddr_t ps, paddr_t pe)
{
diff --git a/xen/common/time.c b/xen/common/time.c
index d326f334cf..c16ff10cdd 100644
--- a/xen/common/time.c
+++ b/xen/common/time.c
@@ -43,7 +43,7 @@ struct tm gmtime(unsigned long t)
const unsigned short int *ip;
y = 1970;
-#ifdef __x86_64__
+#if BITS_PER_LONG >= 64
/* Allow the concept of time before 1970. 64-bit only; for 32-bit
* time after 2038 seems more important than time before 1970. */
while ( t & (1UL<<39) )
diff --git a/xen/drivers/passthrough/vtd/intremap.c b/xen/drivers/passthrough/vtd/intremap.c
index 5fe4246568..1a13a8264d 100644
--- a/xen/drivers/passthrough/vtd/intremap.c
+++ b/xen/drivers/passthrough/vtd/intremap.c
@@ -31,7 +31,7 @@
#include "vtd.h"
#include "extern.h"
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(CONFIG_X86)
#include <asm/apic.h>
#include <asm/io_apic.h>
#define nr_ioapic_entries(i) nr_ioapic_entries[i]
@@ -302,7 +302,7 @@ static int ioapic_rte_to_remap_entry(struct iommu *iommu,
if ( rte_upper )
{
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(CONFIG_X86)
if ( x2apic_enabled )
new_ire.lo.dst = value;
else
@@ -422,7 +422,7 @@ void io_apic_write_remap_rte(
__ioapic_write_entry(apic, ioapic_pin, 1, old_rte);
}
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(CONFIG_X86)
static void set_msi_source_id(struct pci_dev *pdev, struct iremap_entry *ire)
{
diff --git a/xen/drivers/passthrough/vtd/iommu.c b/xen/drivers/passthrough/vtd/iommu.c
index b566d2465e..257d1a023b 100644
--- a/xen/drivers/passthrough/vtd/iommu.c
+++ b/xen/drivers/passthrough/vtd/iommu.c
@@ -34,7 +34,7 @@
#include <xen/softirq.h>
#include <asm/msi.h>
#include <asm/irq.h>
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(CONFIG_X86)
#include <asm/hvm/vmx/vmx.h>
#include <asm/p2m.h>
#include <mach_apic.h>
diff --git a/xen/drivers/passthrough/vtd/utils.c b/xen/drivers/passthrough/vtd/utils.c
index 07337b9e48..a3868eb3e3 100644
--- a/xen/drivers/passthrough/vtd/utils.c
+++ b/xen/drivers/passthrough/vtd/utils.c
@@ -188,7 +188,7 @@ void print_vtd_entries(struct iommu *iommu, int bus, int devfn, u64 gmfn)
static void dump_iommu_info(unsigned char key)
{
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(CONFIG_X86)
struct acpi_drhd_unit *drhd;
struct iommu *iommu;
int i;
diff --git a/xen/include/xen/elfcore.h b/xen/include/xen/elfcore.h
index bd2b4c285a..cc68d5cad8 100644
--- a/xen/include/xen/elfcore.h
+++ b/xen/include/xen/elfcore.h
@@ -65,7 +65,7 @@ typedef struct {
unsigned long xen_compile_date;
unsigned long xen_compile_time;
unsigned long tainted;
-#if defined(__x86_64__)
+#if defined(CONFIG_X86)
unsigned long xen_phys_start;
unsigned long dom0_pfn_to_mfn_frame_list_list;
#endif
diff --git a/xen/include/xen/hvm/irq.h b/xen/include/xen/hvm/irq.h
index 060e91633a..973368cdfe 100644
--- a/xen/include/xen/hvm/irq.h
+++ b/xen/include/xen/hvm/irq.h
@@ -76,7 +76,7 @@ struct hvm_girq_dpci_mapping {
#define NR_ISAIRQS 16
#define NR_LINK 4
-#if defined(__x86_64__)
+#if defined(CONFIG_X86)
# define NR_HVM_IRQS VIOAPIC_NUM_PINS
#endif