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

[Xen-changelog] [mini-os master] mini-os: support newer xen interface



commit 219e088ad0588e32b5e10fcec726d8d546a5e221
Author:     Juergen Gross <jgross@xxxxxxxx>
AuthorDate: Tue Aug 30 13:51:21 2016 +0200
Commit:     Wei Liu <wei.liu2@xxxxxxxxxx>
CommitDate: Fri Sep 2 09:24:09 2016 +0100

    mini-os: support newer xen interface
    
    Mini-OS is currently setting __XEN_INTERFACE_VERSION__ to a rather
    ancient version.
    
    To be able to use a more recent variant garnt_entry_t must be changed
    to grant_entry_v1_t. In balloon.c we omit initializing elements of
    struct xen_memory_reservation with 0 to avoid problems with different
    named structure elements in different Xen interface versions.
    
    Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
    Reviewed-by: Wei Liu <wei.liu2@xxxxxxxxxx>
    Acked-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx>
---
 arch/arm/mm.c    | 2 +-
 arch/x86/mm.c    | 2 +-
 balloon.c        | 2 --
 gnttab.c         | 4 ++--
 include/gnttab.h | 2 +-
 5 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/arch/arm/mm.c b/arch/arm/mm.c
index 8c156c4..f806c9f 100644
--- a/arch/arm/mm.c
+++ b/arch/arm/mm.c
@@ -116,7 +116,7 @@ static paddr_t get_gnttab_base(void)
     return gnttab_base;
 }
 
-grant_entry_t *arch_init_gnttab(int nr_grant_frames)
+grant_entry_v1_t *arch_init_gnttab(int nr_grant_frames)
 {
     struct xen_add_to_physmap xatp;
     struct gnttab_setup_table setup;
diff --git a/arch/x86/mm.c b/arch/x86/mm.c
index 8dd90b8..05ad029 100644
--- a/arch/x86/mm.c
+++ b/arch/x86/mm.c
@@ -890,7 +890,7 @@ void arch_init_mm(unsigned long* start_pfn_p, unsigned 
long* max_pfn_p)
 #endif
 }
 
-grant_entry_t *arch_init_gnttab(int nr_grant_frames)
+grant_entry_v1_t *arch_init_gnttab(int nr_grant_frames)
 {
     struct gnttab_setup_table setup;
     unsigned long frames[nr_grant_frames];
diff --git a/balloon.c b/balloon.c
index b0d0230..5676d3b 100644
--- a/balloon.c
+++ b/balloon.c
@@ -73,8 +73,6 @@ int balloon_up(unsigned long n_pages)
     unsigned long page, pfn;
     int rc;
     struct xen_memory_reservation reservation = {
-        .address_bits = 0,
-        .extent_order = 0,
         .domid        = DOMID_SELF
     };
 
diff --git a/gnttab.c b/gnttab.c
index f395d12..3f0e35f 100644
--- a/gnttab.c
+++ b/gnttab.c
@@ -24,9 +24,9 @@
 
 /* NR_GRANT_FRAMES must be less than or equal to that configured in Xen */
 #define NR_GRANT_FRAMES 4
-#define NR_GRANT_ENTRIES (NR_GRANT_FRAMES * PAGE_SIZE / sizeof(grant_entry_t))
+#define NR_GRANT_ENTRIES (NR_GRANT_FRAMES * PAGE_SIZE / 
sizeof(grant_entry_v1_t))
 
-static grant_entry_t *gnttab_table;
+static grant_entry_v1_t *gnttab_table;
 static grant_ref_t gnttab_list[NR_GRANT_ENTRIES];
 #ifdef GNT_DEBUG
 static char inuse[NR_GRANT_ENTRIES];
diff --git a/include/gnttab.h b/include/gnttab.h
index c43ad42..a9d8e09 100644
--- a/include/gnttab.h
+++ b/include/gnttab.h
@@ -12,6 +12,6 @@ unsigned long gnttab_end_transfer(grant_ref_t gref);
 int gnttab_end_access(grant_ref_t ref);
 const char *gnttabop_error(int16_t status);
 void fini_gnttab(void);
-grant_entry_t *arch_init_gnttab(int nr_grant_frames);
+grant_entry_v1_t *arch_init_gnttab(int nr_grant_frames);
 
 #endif /* !__GNTTAB_H__ */
--
generated by git-patchbot for /home/xen/git/mini-os.git#master

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

 


Rackspace

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