From: Juergen Gross <jgross@suse.com>
To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org
Cc: Juergen Gross <jgross@suse.com>,
samuel.thibault@ens-lyon.org, wei.liu2@citrix.com
Subject: [PATCH 1/3] mini-os: support newer xen interface
Date: Tue, 30 Aug 2016 13:51:21 +0200 [thread overview]
Message-ID: <1472557883-21300-2-git-send-email-jgross@suse.com> (raw)
In-Reply-To: <1472557883-21300-1-git-send-email-jgross@suse.com>
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@suse.com>
---
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__ */
--
2.6.6
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2016-08-30 11:51 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-30 11:51 [PATCH 0/3] repair stubdoms Juergen Gross
2016-08-30 11:51 ` Juergen Gross [this message]
2016-08-30 13:53 ` [PATCH 1/3] mini-os: support newer xen interface Wei Liu
2016-08-30 21:30 ` Samuel Thibault
2016-08-30 11:51 ` [PATCH 2/3] mini-os: provide irq on/off/save/restore functions for Mini-OS apps Juergen Gross
2016-08-30 13:54 ` [Minios-devel] " Wei Liu
2016-08-30 14:08 ` Juergen Gross
2016-08-30 21:34 ` Samuel Thibault
2016-08-30 11:51 ` [PATCH 3/3] mini-os: support "make config" for out-of-tree users Juergen Gross
2016-08-30 13:57 ` [Minios-devel] " Wei Liu
2016-09-02 1:22 ` Samuel Thibault
2016-08-30 21:38 ` Samuel Thibault
2016-09-01 6:21 ` Juergen Gross
2016-09-02 1:21 ` Samuel Thibault
2016-09-02 5:42 ` Juergen Gross
2016-09-02 7:02 ` Samuel Thibault
2016-09-02 8:26 ` [Minios-devel] [PATCH 0/3] repair stubdoms Wei Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1472557883-21300-2-git-send-email-jgross@suse.com \
--to=jgross@suse.com \
--cc=minios-devel@lists.xenproject.org \
--cc=samuel.thibault@ens-lyon.org \
--cc=wei.liu2@citrix.com \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).