[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH 6/9] x86/mtrr: drop unused mtrr_ops struct



There are no users of the mtrr_ops struct or any of the callers on it so
drop those.

Signed-off-by: Doug Goldstein <cardoe@xxxxxxxxxx>
---
 xen/arch/x86/cpu/mtrr/generic.c | 12 ------------
 xen/arch/x86/cpu/mtrr/mtrr.h    | 23 -----------------------
 2 files changed, 35 deletions(-)

diff --git a/xen/arch/x86/cpu/mtrr/generic.c b/xen/arch/x86/cpu/mtrr/generic.c
index 45d4def..1d67035 100644
--- a/xen/arch/x86/cpu/mtrr/generic.c
+++ b/xen/arch/x86/cpu/mtrr/generic.c
@@ -560,15 +560,3 @@ int positive_have_wrcomb(void)
 {
        return 1;
 }
-
-/* generic structure...
- */
-const struct mtrr_ops generic_mtrr_ops = {
-       .use_intel_if      = 1,
-       .set_all           = mtrr_generic_set_all,
-       .get               = mtrr_generic_get,
-       .get_free_region   = mtrr_generic_get_free_region,
-       .set               = mtrr_generic_set,
-       .validate_add_page = mtrr_generic_validate_add_page,
-       .have_wrcomb       = mtrr_generic_have_wrcomb,
-};
diff --git a/xen/arch/x86/cpu/mtrr/mtrr.h b/xen/arch/x86/cpu/mtrr/mtrr.h
index 25f4867..9391fc5 100644
--- a/xen/arch/x86/cpu/mtrr/mtrr.h
+++ b/xen/arch/x86/cpu/mtrr/mtrr.h
@@ -11,24 +11,6 @@
 #define MTRR_CHANGE_MASK_VARIABLE  0x02
 #define MTRR_CHANGE_MASK_DEFTYPE   0x04
 
-
-struct mtrr_ops {
-       u32     vendor;
-       u32     use_intel_if;
-//     void    (*init)(void);
-       void    (*set)(unsigned int reg, unsigned long base,
-                      unsigned long size, mtrr_type type);
-       void    (*set_all)(void);
-
-       void    (*get)(unsigned int reg, unsigned long *base,
-                      unsigned long *size, mtrr_type * type);
-       int     (*get_free_region)(unsigned long base, unsigned long size,
-                                  int replace_reg);
-       int     (*validate_add_page)(unsigned long base, unsigned long size,
-                                    unsigned int type);
-       int     (*have_wrcomb)(void);
-};
-
 void mtrr_generic_get(unsigned int reg, unsigned long *base,
         unsigned long *size, mtrr_type *type);
 int mtrr_generic_get_free_region(unsigned long base, unsigned long size,
@@ -40,8 +22,6 @@ void mtrr_generic_set(unsigned int reg, unsigned long base,
         unsigned long size, mtrr_type type);
 int mtrr_generic_have_wrcomb(void);
 
-extern const struct mtrr_ops generic_mtrr_ops;
-
 extern int positive_have_wrcomb(void);
 
 /* library functions for processor-specific routines */
@@ -58,10 +38,7 @@ void set_mtrr_prepare_save(struct set_mtrr_context *ctxt);
 
 void get_mtrr_state(void);
 
-extern void set_mtrr_ops(const struct mtrr_ops *);
-
 extern u64 size_or_mask, size_and_mask;
-extern const struct mtrr_ops *mtrr_if;
 
 extern unsigned int num_var_ranges;
 
-- 
2.7.3


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.