]> xenbits.xensource.com Git - xen.git/commitdiff
x86/p2m, arm/p2m: remove get_gfn_untyped().
authorTim Deegan <tim@xen.org>
Thu, 17 May 2012 09:24:54 +0000 (10:24 +0100)
committerTim Deegan <tim@xen.org>
Thu, 17 May 2012 09:24:54 +0000 (10:24 +0100)
Adjust its only user to use get_gfn.

Signed-off-by: Andres Lagar-Cavilla <andres@lagarcavilla.org>
Signed-off-by: Tim Deegan <tim@xen.org>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
xen/arch/x86/mm.c
xen/include/asm-arm/p2m.h
xen/include/asm-x86/p2m.h

index f65d40fac47e532bbf36aa8c5ffa782fcdb0096b..ac414d1b7c774da06aca61597f1cde90bda5f807 100644 (file)
@@ -4524,6 +4524,7 @@ static int xenmem_add_to_physmap_once(
     unsigned long gfn = 0; /* gcc ... */
     unsigned long prev_mfn, mfn = 0, gpfn, idx;
     int rc;
+    p2m_type_t p2mt;
 
     switch ( xatp->space )
     {
@@ -4596,7 +4597,7 @@ static int xenmem_add_to_physmap_once(
         put_page(page);
 
     /* Remove previously mapped page if it was present. */
-    prev_mfn = get_gfn_untyped(d, xatp->gpfn);
+    prev_mfn = mfn_x(get_gfn(d, xatp->gpfn, &p2mt));
     if ( mfn_valid(prev_mfn) )
     {
         if ( is_xen_heap_mfn(prev_mfn) )
index 6bcdf02b79614169f20f503bf4e5fc64fef0faf2..d88e7a9e9f7ebd312361f28ccd9b0e44ff5a83de 100644 (file)
@@ -75,12 +75,6 @@ static inline struct page_info *get_page_from_gfn(
     return page;
 }
 
-/* Compatibility function exporting the old untyped interface */
-static inline unsigned long get_gfn_untyped(struct domain *d, unsigned long gpfn)
-{
-    return gmfn_to_mfn(d, gpfn);
-}
-
 int get_page_type(struct page_info *page, unsigned long type);
 int is_iomem_page(unsigned long mfn);
 static inline int get_page_and_type(struct page_info *page,
index 48e3bad23e8c1147c1a6fbb4ca8e7598f71d54e1..94bd13616840ec3adbf6a0e3a5421d64390d98a7 100644 (file)
@@ -339,17 +339,6 @@ static inline mfn_t get_gfn_type(struct domain *d,
 #define get_gfn_unshare(d, g, t) get_gfn_type((d), (g), (t), \
                                               P2M_ALLOC | P2M_UNSHARE)
 
-/* Compatibility function exporting the old untyped interface */
-static inline unsigned long get_gfn_untyped(struct domain *d, unsigned long gpfn)
-{
-    mfn_t mfn;
-    p2m_type_t t;
-    mfn = get_gfn(d, gpfn, &t);
-    if ( p2m_is_valid(t) )
-        return mfn_x(mfn);
-    return INVALID_MFN;
-}
-
 /* Will release the p2m_lock for this gfn entry. */
 void __put_gfn(struct p2m_domain *p2m, unsigned long gfn);