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] xen: remove more declarations from C files

To: <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] xen: remove more declarations from C files
From: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Date: Thu, 26 May 2011 17:25:22 +0100
Delivery-date: Thu, 26 May 2011 09:27:46 -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
User-agent: Mercurial-patchbomb/1.8.3
# HG changeset patch
# User Tim Deegan <Tim.Deegan@xxxxxxxxxx>
# Date 1306426663 -3600
# Node ID 69fe4b8a7c0961070a626cb473d19a0770db663a
# Parent  88fe9f780b3d0cf0fcd5aa9b87d4ec7ad404e985
xen: remove more declarations from C files.

This patch moves some more, mostly data, extern declarations into
header files.   I haven't been as strict as I was with functions;
in particular there are a number of declarations of assembler labels
that are only used in one place.  I've also left a few compat-mode
tricks, and all the magic in symbols.c

Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx>

diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/cpu/mcheck/mce.c
--- a/xen/arch/x86/cpu/mcheck/mce.c     Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/cpu/mcheck/mce.c     Thu May 26 17:17:43 2011 +0100
@@ -326,9 +326,6 @@ mctelem_cookie_t mcheck_mca_logout(enum 
                 mca_init_global(mc_flags, mig);
                 /* A hook here to get global extended msrs */
                 {
-                    struct mcinfo_extended *intel_get_extended_msrs(
-                        struct mcinfo_global *mig, struct mc_info *mi);
-
                     if (boot_cpu_data.x86_vendor ==
                         X86_VENDOR_INTEL)
                         intel_get_extended_msrs(mig, mci);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/cpu/mcheck/mce.h
--- a/xen/arch/x86/cpu/mcheck/mce.h     Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/cpu/mcheck/mce.h     Thu May 26 17:17:43 2011 +0100
@@ -57,6 +57,9 @@ extern int firstbank;
 int intel_mce_rdmsr(uint32_t msr, uint64_t *val);
 int intel_mce_wrmsr(uint32_t msr, uint64_t val);
 
+struct mcinfo_extended *intel_get_extended_msrs(
+    struct mcinfo_global *mig, struct mc_info *mi);
+
 int mce_available(struct cpuinfo_x86 *c);
 int mce_firstbank(struct cpuinfo_x86 *c);
 /* Helper functions used for collecting error telemetry */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/cpu/mcheck/x86_mca.h
--- a/xen/arch/x86/cpu/mcheck/x86_mca.h Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/cpu/mcheck/x86_mca.h Thu May 26 17:17:43 2011 +0100
@@ -156,6 +156,5 @@ struct mca_error_handler
 
 /* Global variables */
 extern bool_t mce_disabled;
-extern unsigned int nr_mce_banks;
 
 #endif /* X86_MCA_H */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/cpu/mtrr/main.c
--- a/xen/arch/x86/cpu/mtrr/main.c      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/cpu/mtrr/main.c      Thu May 26 17:17:43 2011 +0100
@@ -63,12 +63,6 @@ const struct mtrr_ops *__read_mostly mtr
 static void set_mtrr(unsigned int reg, unsigned long base,
                     unsigned long size, mtrr_type type);
 
-#ifndef CONFIG_X86_64
-extern int arr3_protected;
-#else
-#define arr3_protected 0
-#endif
-
 static const char *const mtrr_strings[MTRR_NUM_TYPES] =
 {
     "uncachable",               /* 0 */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/cpu/mtrr/mtrr.h
--- a/xen/arch/x86/cpu/mtrr/mtrr.h      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/cpu/mtrr/mtrr.h      Thu May 26 17:17:43 2011 +0100
@@ -86,3 +86,8 @@ void mtrr_wrmsr(unsigned int msr, uint64
 extern int amd_init_mtrr(void);
 extern int cyrix_init_mtrr(void);
 
+#ifndef CONFIG_X86_64
+extern int arr3_protected;
+#else
+#define arr3_protected 0
+#endif
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/extable.c
--- a/xen/arch/x86/extable.c    Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/extable.c    Thu May 26 17:17:43 2011 +0100
@@ -6,11 +6,6 @@
 #include <xen/spinlock.h>
 #include <asm/uaccess.h>
 
-extern struct exception_table_entry __start___ex_table[];
-extern struct exception_table_entry __stop___ex_table[];
-extern struct exception_table_entry __start___pre_ex_table[];
-extern struct exception_table_entry __stop___pre_ex_table[];
-
 #ifdef __i386__
 #define EX_FIELD(ptr, field) (ptr)->field
 #define swap_ex NULL
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/hvm/intercept.c
--- a/xen/arch/x86/hvm/intercept.c      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/hvm/intercept.c      Thu May 26 17:17:43 2011 +0100
@@ -32,13 +32,6 @@
 #include <xen/event.h>
 #include <xen/iommu.h>
 
-extern const struct hvm_mmio_handler hpet_mmio_handler;
-extern const struct hvm_mmio_handler vlapic_mmio_handler;
-extern const struct hvm_mmio_handler vioapic_mmio_handler;
-extern const struct hvm_mmio_handler msixtbl_mmio_handler;
-
-#define HVM_MMIO_HANDLER_NR 4
-
 static const struct hvm_mmio_handler *const
 hvm_mmio_handlers[HVM_MMIO_HANDLER_NR] =
 {
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/hvm/mtrr.c
--- a/xen/arch/x86/hvm/mtrr.c   Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/hvm/mtrr.c   Thu May 26 17:17:43 2011 +0100
@@ -28,8 +28,6 @@
 #include <asm/hvm/support.h>
 #include <asm/hvm/cacheattr.h>
 
-extern struct mtrr_state mtrr_state;
-
 static uint32_t size_or_mask;
 
 /* Get page attribute fields (PAn) from PAT MSR. */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/hvm/svm/svm.c
--- a/xen/arch/x86/hvm/svm/svm.c        Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/hvm/svm/svm.c        Thu May 26 17:17:43 2011 +0100
@@ -1656,8 +1656,6 @@ static void svm_vmexit_ud_intercept(stru
     }
 }
 
-extern unsigned int nr_mce_banks; /* from mce.h */
-
 static int svm_is_erratum_383(struct cpu_user_regs *regs)
 {
     uint64_t msr_content;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/hvm/svm/vmcb.c
--- a/xen/arch/x86/hvm/svm/vmcb.c       Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/hvm/svm/vmcb.c       Thu May 26 17:17:43 2011 +0100
@@ -32,8 +32,6 @@
 #include <asm/hvm/svm/svm.h>
 #include <asm/hvm/svm/svmdebug.h>
 
-extern int svm_dbg_on;
-
 struct vmcb_struct *alloc_vmcb(void) 
 {
     struct vmcb_struct *vmcb;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/hvm/vpmu.c
--- a/xen/arch/x86/hvm/vpmu.c   Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/hvm/vpmu.c   Thu May 26 17:17:43 2011 +0100
@@ -78,9 +78,6 @@ void vpmu_load(struct vcpu *v)
         vpmu->arch_vpmu_ops->arch_vpmu_load(v);
 }
 
-extern struct arch_vpmu_ops core2_vpmu_ops;
-extern struct arch_vpmu_ops amd_vpmu_ops;
-
 void vpmu_initialise(struct vcpu *v)
 {
     struct vpmu_struct *vpmu = vcpu_vpmu(v);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/io_apic.c
--- a/xen/arch/x86/io_apic.c    Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/io_apic.c    Thu May 26 17:17:43 2011 +0100
@@ -1440,7 +1440,6 @@ static void __init setup_ioapic_ids_from
  */
 static int __init timer_irq_works(void)
 {
-    extern unsigned long pit0_ticks;
     unsigned long t1, flags;
 
     t1 = pit0_ticks;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/oprofile/nmi_int.c
--- a/xen/arch/x86/oprofile/nmi_int.c   Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/oprofile/nmi_int.c   Thu May 26 17:17:43 2011 +0100
@@ -339,7 +339,6 @@ static int force_cpu_type(const char *st
 }
 custom_param("cpu_type", force_cpu_type);
 
-extern int ppro_has_global_ctrl;
 static int __init ppro_init(char ** cpu_type)
 {
        __u8 cpu_model = current_cpu_data.x86_model;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/oprofile/op_model_athlon.c
--- a/xen/arch/x86/oprofile/op_model_athlon.c   Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/oprofile/op_model_athlon.c   Thu May 26 17:17:43 2011 +0100
@@ -52,7 +52,6 @@
 static unsigned long reset_value[MAX_COUNTERS];
 
 extern char svm_stgi_label[];
-extern struct op_x86_model_spec const *__read_mostly model;
 
 #ifdef CONFIG_X86_64
 u32 ibs_caps = 0;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/oprofile/op_x86_model.h
--- a/xen/arch/x86/oprofile/op_x86_model.h      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/oprofile/op_x86_model.h      Thu May 26 17:17:43 2011 +0100
@@ -51,4 +51,8 @@ extern struct op_x86_model_spec const op
 extern struct op_x86_model_spec const op_amd_fam15h_spec;
 
 void arch_perfmon_setup_counters(void);
+
+extern int ppro_has_global_ctrl;
+extern struct op_x86_model_spec const *__read_mostly model;
+
 #endif /* OP_X86_MODEL_H */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/platform_hypercall.c
--- a/xen/arch/x86/platform_hypercall.c Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/platform_hypercall.c Thu May 26 17:17:43 2011 +0100
@@ -30,9 +30,6 @@
 #include "cpu/mtrr/mtrr.h"
 #include <xsm/xsm.h>
 
-extern uint16_t boot_edid_caps;
-extern uint8_t boot_edid_info[];
-
 #ifndef COMPAT
 typedef long ret_t;
 DEFINE_SPINLOCK(xenpf_lock);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/setup.c
--- a/xen/arch/x86/setup.c      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/setup.c      Thu May 26 17:17:43 2011 +0100
@@ -45,10 +45,6 @@
 #include <asm/setup.h>
 #include <xen/cpu.h>
 
-extern u16 boot_edid_caps;
-extern u8 boot_edid_info[128];
-extern struct boot_video_info boot_vid_info;
-
 /* opt_nosmp: If true, secondary processors are ignored. */
 static bool_t __initdata opt_nosmp;
 boolean_param("nosmp", opt_nosmp);
@@ -438,6 +434,7 @@ struct boot_video_info {
     u16 vesapm_off;         /* 0x26 */
     u16 vesa_attrib;        /* 0x28 */
 };
+extern struct boot_video_info boot_vid_info;
 
 static void __init parse_video_info(void)
 {
@@ -806,7 +803,6 @@ void __init __start_xen(unsigned long mb
             end = 0;
         if ( end > s )
         {
-            extern l2_pgentry_t l2_xenmap[];
             l4_pgentry_t *pl4e;
             l3_pgentry_t *pl3e;
             l2_pgentry_t *pl2e;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/tboot.c
--- a/xen/arch/x86/tboot.c      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/tboot.c      Thu May 26 17:17:43 2011 +0100
@@ -245,7 +245,6 @@ static void tboot_gen_domain_integrity(c
  */
 static int mfn_in_guarded_stack(unsigned long mfn)
 {
-    extern void *stack_base[NR_CPUS];
     void *p;
     int i;
 
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/traps.c
--- a/xen/arch/x86/traps.c      Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/traps.c      Thu May 26 17:17:43 2011 +0100
@@ -3248,8 +3248,6 @@ asmlinkage void do_debug(struct cpu_user
         if ( regs->eflags & X86_EFLAGS_TF )
         {
 #ifdef __x86_64__
-            void sysenter_entry(void);
-            void sysenter_eflags_saved(void);
             /* In SYSENTER entry path we can't zap TF until EFLAGS is saved. */
             if ( (regs->rip >= (unsigned long)sysenter_entry) &&
                  (regs->rip <= (unsigned long)sysenter_eflags_saved) )
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/x86_32/mm.c
--- a/xen/arch/x86/x86_32/mm.c  Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/x86_32/mm.c  Thu May 26 17:17:43 2011 +0100
@@ -34,8 +34,6 @@
 l2_pgentry_t __attribute__ ((__section__ (".bss.page_aligned")))
     idle_pg_table_l2[4 * L2_PAGETABLE_ENTRIES];
 
-extern l1_pgentry_t l1_identmap[L1_PAGETABLE_ENTRIES];
-
 unsigned int __read_mostly PAGE_HYPERVISOR         = __PAGE_HYPERVISOR;
 unsigned int __read_mostly PAGE_HYPERVISOR_NOCACHE = __PAGE_HYPERVISOR_NOCACHE;
 
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/arch/x86/x86_64/traps.c
--- a/xen/arch/x86/x86_64/traps.c       Thu May 26 17:16:47 2011 +0100
+++ b/xen/arch/x86/x86_64/traps.c       Thu May 26 17:17:43 2011 +0100
@@ -24,10 +24,6 @@
 #include <asm/hvm/support.h>
 #include <public/callback.h>
 
-asmlinkage void syscall_enter(void);
-asmlinkage void sysenter_entry(void);
-asmlinkage void compat_hypercall(void);
-asmlinkage void int80_direct_trap(void);
 
 static void print_xen_info(void)
 {
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/common/sched_arinc653.c
--- a/xen/common/sched_arinc653.c       Thu May 26 17:16:47 2011 +0100
+++ b/xen/common/sched_arinc653.c       Thu May 26 17:17:43 2011 +0100
@@ -654,7 +654,7 @@ a653sched_adjust_global(const struct sch
  * callback functions.
  * The symbol must be visible to the rest of Xen at link time.
  */
-struct scheduler sched_arinc653_def = {
+const struct scheduler sched_arinc653_def = {
     .name           = "ARINC 653 Scheduler",
     .opt_name       = "arinc653",
     .sched_id       = XEN_SCHEDULER_ARINC653,
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/common/schedule.c
--- a/xen/common/schedule.c     Thu May 26 17:16:47 2011 +0100
+++ b/xen/common/schedule.c     Thu May 26 17:17:43 2011 +0100
@@ -57,10 +57,6 @@ static void poll_timer_fn(void *data);
 DEFINE_PER_CPU(struct schedule_data, schedule_data);
 DEFINE_PER_CPU(struct scheduler *, scheduler);
 
-extern const struct scheduler sched_sedf_def;
-extern const struct scheduler sched_credit_def;
-extern const struct scheduler sched_credit2_def;
-extern const struct scheduler sched_arinc653_def;
 static const struct scheduler *schedulers[] = {
     &sched_sedf_def,
     &sched_credit_def,
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/drivers/acpi/pmstat.c
--- a/xen/drivers/acpi/pmstat.c Thu May 26 17:16:47 2011 +0100
+++ b/xen/drivers/acpi/pmstat.c Thu May 26 17:17:43 2011 +0100
@@ -45,8 +45,6 @@
 
 DEFINE_PER_CPU_READ_MOSTLY(struct pm_px *, cpufreq_statistic_data);
 
-extern struct list_head cpufreq_governor_list;
-
 /*
  * Get PM statistic info
  */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/drivers/passthrough/amd/iommu_acpi.c
--- a/xen/drivers/passthrough/amd/iommu_acpi.c  Thu May 26 17:16:47 2011 +0100
+++ b/xen/drivers/passthrough/amd/iommu_acpi.c  Thu May 26 17:17:43 2011 +0100
@@ -25,12 +25,6 @@
 #include <asm/hvm/svm/amd-iommu-proto.h>
 #include <asm/hvm/svm/amd-iommu-acpi.h>
 
-extern unsigned long amd_iommu_page_entries;
-extern unsigned short ivrs_bdf_entries;
-extern struct ivrs_mappings *ivrs_mappings;
-extern int ioapic_bdf[MAX_IO_APICS];
-extern void *shared_intremap_table;
-
 static unsigned short __initdata last_bdf;
 
 static void __init add_ivrs_mapping_entry(
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/drivers/passthrough/amd/iommu_intr.c
--- a/xen/drivers/passthrough/amd/iommu_intr.c  Thu May 26 17:16:47 2011 +0100
+++ b/xen/drivers/passthrough/amd/iommu_intr.c  Thu May 26 17:17:43 2011 +0100
@@ -28,8 +28,6 @@
 #define INTREMAP_ENTRIES (1 << INTREMAP_LENGTH)
 
 int ioapic_bdf[MAX_IO_APICS];
-extern struct ivrs_mappings *ivrs_mappings;
-extern unsigned short ivrs_bdf_entries;
 void *shared_intremap_table;
 static DEFINE_SPINLOCK(shared_intremap_lock);
 
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/drivers/passthrough/amd/pci_amd_iommu.c
--- a/xen/drivers/passthrough/amd/pci_amd_iommu.c       Thu May 26 17:16:47 
2011 +0100
+++ b/xen/drivers/passthrough/amd/pci_amd_iommu.c       Thu May 26 17:17:43 
2011 +0100
@@ -25,9 +25,6 @@
 #include <asm/amd-iommu.h>
 #include <asm/hvm/svm/amd-iommu-proto.h>
 
-extern unsigned short ivrs_bdf_entries;
-extern struct ivrs_mappings *ivrs_mappings;
-
 struct amd_iommu *find_iommu_for_device(int bdf)
 {
     BUG_ON ( bdf >= ivrs_bdf_entries );
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/acpi/cpufreq/cpufreq.h
--- a/xen/include/acpi/cpufreq/cpufreq.h        Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/acpi/cpufreq/cpufreq.h        Thu May 26 17:17:43 2011 +0100
@@ -103,6 +103,8 @@ extern struct cpufreq_governor cpufreq_g
 extern struct cpufreq_governor cpufreq_gov_performance;
 extern struct cpufreq_governor cpufreq_gov_powersave;
 
+extern struct list_head cpufreq_governor_list;
+
 extern int cpufreq_register_governor(struct cpufreq_governor *governor);
 extern struct cpufreq_governor *__find_governor(const char *governor);
 #define CPUFREQ_DEFAULT_GOVERNOR &cpufreq_gov_dbs
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/amd-iommu.h
--- a/xen/include/asm-x86/amd-iommu.h   Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/amd-iommu.h   Thu May 26 17:17:43 2011 +0100
@@ -99,4 +99,8 @@ struct ivrs_mappings {
     u8 dte_ext_int_pass;
     u8 dte_init_pass;
 };
+
+extern unsigned short ivrs_bdf_entries;
+extern struct ivrs_mappings *ivrs_mappings;
+
 #endif /* _ASM_X86_64_AMD_IOMMU_H */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/config.h
--- a/xen/include/asm-x86/config.h      Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/config.h      Thu May 26 17:17:43 2011 +0100
@@ -108,6 +108,8 @@ extern unsigned int trampoline_xen_phys_
 extern unsigned char trampoline_cpu_started;
 extern char wakeup_start[];
 extern unsigned int video_mode, video_flags;
+extern unsigned short boot_edid_caps;
+extern unsigned char boot_edid_info[128];
 #endif
 
 #if defined(__x86_64__)
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/hvm/io.h
--- a/xen/include/asm-x86/hvm/io.h      Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/hvm/io.h      Thu May 26 17:17:43 2011 +0100
@@ -65,6 +65,13 @@ struct hvm_mmio_handler {
     hvm_mmio_write_t write_handler;
 };
 
+extern const struct hvm_mmio_handler hpet_mmio_handler;
+extern const struct hvm_mmio_handler vlapic_mmio_handler;
+extern const struct hvm_mmio_handler vioapic_mmio_handler;
+extern const struct hvm_mmio_handler msixtbl_mmio_handler;
+
+#define HVM_MMIO_HANDLER_NR 4
+
 int hvm_io_intercept(ioreq_t *p, int type);
 void register_io_handler(
     struct domain *d, unsigned long addr, unsigned long size,
diff -r 88fe9f780b3d -r 69fe4b8a7c09 
xen/include/asm-x86/hvm/svm/amd-iommu-proto.h
--- a/xen/include/asm-x86/hvm/svm/amd-iommu-proto.h     Thu May 26 17:16:47 
2011 +0100
+++ b/xen/include/asm-x86/hvm/svm/amd-iommu-proto.h     Thu May 26 17:17:43 
2011 +0100
@@ -23,6 +23,7 @@
 
 #include <xen/sched.h>
 #include <asm/amd-iommu.h>
+#include <asm/apicdef.h>
 #include <xen/domain_page.h>
 
 #define for_each_amd_iommu(amd_iommu) \
@@ -95,6 +96,9 @@ void amd_iommu_read_msi_from_ire(
 unsigned int amd_iommu_read_ioapic_from_ire(
     unsigned int apic, unsigned int reg);
 
+extern int ioapic_bdf[MAX_IO_APICS];
+extern void *shared_intremap_table;
+
 /* power management support */
 void amd_iommu_resume(void);
 void amd_iommu_suspend(void);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/hvm/vpmu.h
--- a/xen/include/asm-x86/hvm/vpmu.h    Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/hvm/vpmu.h    Thu May 26 17:17:43 2011 +0100
@@ -56,6 +56,9 @@ struct arch_vpmu_ops {
     void (*arch_vpmu_load)(struct vcpu *v);
 };
 
+extern struct arch_vpmu_ops core2_vpmu_ops;
+extern struct arch_vpmu_ops amd_vpmu_ops;
+
 struct vpmu_struct {
     u32 flags;
     void *context;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/mce.h
--- a/xen/include/asm-x86/mce.h Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/mce.h Thu May 26 17:17:43 2011 +0100
@@ -30,4 +30,7 @@ extern int vmce_init_msr(struct domain *
 extern void vmce_destroy_msr(struct domain *d);
 extern int vmce_wrmsr(uint32_t msr, uint64_t val);
 extern int vmce_rdmsr(uint32_t msr, uint64_t *val);
+
+extern unsigned int nr_mce_banks;
+
 #endif
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/mtrr.h
--- a/xen/include/asm-x86/mtrr.h        Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/mtrr.h        Thu May 26 17:17:43 2011 +0100
@@ -52,6 +52,7 @@ struct mtrr_state {
        /* ranges in var MSRs are overlapped or not:0(no overlapped) */
        bool_t    overlapped;
 };
+extern struct mtrr_state mtrr_state;
 
 extern void mtrr_save_fixed_ranges(void *);
 extern void mtrr_save_state(void);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/page.h
--- a/xen/include/asm-x86/page.h        Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/page.h        Thu May 26 17:17:43 2011 +0100
@@ -303,6 +303,8 @@ extern l2_pgentry_t  *compat_idle_pg_tab
 extern unsigned int   m2p_compat_vstart;
 #endif
 extern l2_pgentry_t l2_identmap[4*L2_PAGETABLE_ENTRIES];
+extern l1_pgentry_t l1_identmap[L1_PAGETABLE_ENTRIES];
+extern l2_pgentry_t l2_xenmap[];
 void paging_init(void);
 void setup_idle_pagetable(void);
 #endif /* !defined(__ASSEMBLY__) */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/processor.h
--- a/xen/include/asm-x86/processor.h   Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/processor.h   Thu May 26 17:17:43 2011 +0100
@@ -580,6 +580,13 @@ DECLARE_TRAP_HANDLER(machine_check);
 DECLARE_TRAP_HANDLER(alignment_check);
 DECLARE_TRAP_HANDLER(spurious_interrupt_bug);
 #undef DECLARE_TRAP_HANDLER
+
+asmlinkage void syscall_enter(void);
+asmlinkage void sysenter_entry(void);
+asmlinkage void sysenter_eflags_saved(void);
+asmlinkage void compat_hypercall(void);
+asmlinkage void int80_direct_trap(void);
+
 extern asmlinkage int hypercall(void);
 
 int cpuid_hypervisor_leaves( uint32_t idx, uint32_t sub_idx,
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/asm-x86/uaccess.h
--- a/xen/include/asm-x86/uaccess.h     Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/asm-x86/uaccess.h     Thu May 26 17:17:43 2011 +0100
@@ -269,6 +269,10 @@ struct exception_table_entry
 {
        s32 addr, cont;
 };
+extern struct exception_table_entry __start___ex_table[];
+extern struct exception_table_entry __stop___ex_table[];
+extern struct exception_table_entry __start___pre_ex_table[];
+extern struct exception_table_entry __stop___pre_ex_table[];
 
 extern unsigned long search_exception_table(unsigned long);
 extern void sort_exception_tables(void);
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/xen/sched-if.h
--- a/xen/include/xen/sched-if.h        Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/xen/sched-if.h        Thu May 26 17:17:43 2011 +0100
@@ -183,6 +183,12 @@ struct scheduler {
     void         (*tick_resume)     (const struct scheduler *, unsigned int);
 };
 
+extern const struct scheduler sched_sedf_def;
+extern const struct scheduler sched_credit_def;
+extern const struct scheduler sched_credit2_def;
+extern const struct scheduler sched_arinc653_def;
+
+
 struct cpupool
 {
     int              cpupool_id;
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/xen/smp.h
--- a/xen/include/xen/smp.h     Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/xen/smp.h     Thu May 26 17:17:43 2011 +0100
@@ -63,4 +63,6 @@ static inline void on_each_cpu(
 
 int alloc_cpu_id(void);
 
+extern void *stack_base[NR_CPUS];
+
 #endif /* __XEN_SMP_H__ */
diff -r 88fe9f780b3d -r 69fe4b8a7c09 xen/include/xen/time.h
--- a/xen/include/xen/time.h    Thu May 26 17:16:47 2011 +0100
+++ b/xen/include/xen/time.h    Thu May 26 17:17:43 2011 +0100
@@ -15,6 +15,7 @@ extern int init_xen_time(void);
 extern void cstate_restore_tsc(void);
 
 extern unsigned long cpu_khz;
+extern unsigned long pit0_ticks;
 
 struct domain;
 struct vcpu;

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] xen: remove more declarations from C files, Tim Deegan <=