* [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
@ 2017-10-31 6:55 Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t Bhupinder Thakur
` (3 more replies)
0 siblings, 4 replies; 12+ messages in thread
From: Bhupinder Thakur @ 2017-10-31 6:55 UTC (permalink / raw)
To: xen-devel
Cc: Stefano Stabellini, Wei Liu, Andrew Cooper, Ian Jackson,
Julien Grall, Jan Beulich
In libxl__device_vuart_add vuart_gfn is getting stored as a hex value:
> flexarray_append(ro_front, GCSPRINTF("%"PRI_xen_pfn, state->vuart_gfn));
However, xenstore reads this value as a decimal value and tries to map the
wrong address and fails.
This patch introduces a new format specifier "PRIu_xen_pfn" which formats the value as a
decimal value.
Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
Acked-by: Wei Liu <wei.liu2@citrix.com>
---
CC: Ian Jackson <ian.jackson@eu.citrix.com>
CC: Wei Liu <wei.liu2@citrix.com>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Julien Grall <julien.grall@arm.com>
CC: Jan Beulich <jbeulich@suse.com>
CC: Andrew Cooper <andrew.cooper3@citrix.com>
tools/libxl/libxl_console.c | 2 +-
xen/include/public/arch-arm.h | 1 +
xen/include/public/arch-x86/xen.h | 1 +
3 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/tools/libxl/libxl_console.c b/tools/libxl/libxl_console.c
index c05dc28..6bfc0e5 100644
--- a/tools/libxl/libxl_console.c
+++ b/tools/libxl/libxl_console.c
@@ -376,7 +376,7 @@ int libxl__device_vuart_add(libxl__gc *gc, uint32_t domid,
flexarray_append(ro_front, "port");
flexarray_append(ro_front, GCSPRINTF("%"PRIu32, state->vuart_port));
flexarray_append(ro_front, "ring-ref");
- flexarray_append(ro_front, GCSPRINTF("%"PRI_xen_pfn, state->vuart_gfn));
+ flexarray_append(ro_front, GCSPRINTF("%"PRIu_xen_pfn, state->vuart_gfn));
flexarray_append(ro_front, "limit");
flexarray_append(ro_front, GCSPRINTF("%d", LIBXL_XENCONSOLE_LIMIT));
flexarray_append(ro_front, "type");
diff --git a/xen/include/public/arch-arm.h b/xen/include/public/arch-arm.h
index 5708cd2..05fd11c 100644
--- a/xen/include/public/arch-arm.h
+++ b/xen/include/public/arch-arm.h
@@ -274,6 +274,7 @@ DEFINE_XEN_GUEST_HANDLE(vcpu_guest_core_regs_t);
typedef uint64_t xen_pfn_t;
#define PRI_xen_pfn PRIx64
+#define PRIu_xen_pfn PRIu64
/* Maximum number of virtual CPUs in legacy multi-processor guests. */
/* Only one. All other VCPUS must use VCPUOP_register_vcpu_info */
diff --git a/xen/include/public/arch-x86/xen.h b/xen/include/public/arch-x86/xen.h
index ff91831..3b0b1d6 100644
--- a/xen/include/public/arch-x86/xen.h
+++ b/xen/include/public/arch-x86/xen.h
@@ -75,6 +75,7 @@ __DeFiNe__ __DECL_REG_LO16(name) e ## name
#ifndef __ASSEMBLY__
typedef unsigned long xen_pfn_t;
#define PRI_xen_pfn "lx"
+#define PRIu_xen_pfn "lu"
#endif
#define XEN_HAVE_PV_GUEST_ENTRY 1
--
2.7.4
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t
2017-10-31 6:55 [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Bhupinder Thakur
@ 2017-10-31 6:55 ` Bhupinder Thakur
2017-10-31 10:05 ` Wei Liu
2017-10-31 6:55 ` [PATCH 3/4 v3] xenconsole: Change the type of ring_ref to xen_pfn_t in console_create_ring Bhupinder Thakur
` (2 subsequent siblings)
3 siblings, 1 reply; 12+ messages in thread
From: Bhupinder Thakur @ 2017-10-31 6:55 UTC (permalink / raw)
To: xen-devel; +Cc: Wei Liu, Julien Grall, Stefano Stabellini, Ian Jackson
Currently the type of console mfn is unsigned long in libxl. This may be
an issue for 32-bit toolstack running on 64-bit Xen, where the pfn are
64 bit. To ensure that console_mfn can hold any valid 64-bit pfn, the
type of console_mfn is changed to xen_pfn_t.
Also the name console_mfn is misleading as it is actually a gfn. This
patch also modifies the name to console_gfn.
Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
---
CC: Ian Jackson <ian.jackson@eu.citrix.com>
CC: Wei Liu <wei.liu2@citrix.com>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Julien Grall <julien.grall@arm.com>
This patch is as per the review of commit fa1f157
libxl: Fix the bug introduced in commit "libxl: use correct type
tools/libxc/include/xenctrl_compat.h | 2 +-
tools/libxc/xc_foreign_memory.c | 4 ++--
tools/libxl/libxl_console.c | 2 +-
tools/libxl/libxl_create.c | 10 +++++-----
tools/libxl/libxl_dom.c | 12 ++++++------
tools/libxl/libxl_internal.h | 2 +-
tools/libxl/libxl_save_helper.c | 6 +++---
7 files changed, 19 insertions(+), 19 deletions(-)
diff --git a/tools/libxc/include/xenctrl_compat.h b/tools/libxc/include/xenctrl_compat.h
index a655e47..5ee72bf 100644
--- a/tools/libxc/include/xenctrl_compat.h
+++ b/tools/libxc/include/xenctrl_compat.h
@@ -26,7 +26,7 @@
*/
void *xc_map_foreign_range(xc_interface *xch, uint32_t dom,
int size, int prot,
- unsigned long mfn );
+ xen_pfn_t pfn);
void *xc_map_foreign_pages(xc_interface *xch, uint32_t dom, int prot,
const xen_pfn_t *arr, int num );
diff --git a/tools/libxc/xc_foreign_memory.c b/tools/libxc/xc_foreign_memory.c
index 4053d26..c1f114a 100644
--- a/tools/libxc/xc_foreign_memory.c
+++ b/tools/libxc/xc_foreign_memory.c
@@ -33,7 +33,7 @@ void *xc_map_foreign_pages(xc_interface *xch, uint32_t dom, int prot,
void *xc_map_foreign_range(xc_interface *xch,
uint32_t dom, int size, int prot,
- unsigned long mfn)
+ xen_pfn_t pfn)
{
xen_pfn_t *arr;
int num;
@@ -46,7 +46,7 @@ void *xc_map_foreign_range(xc_interface *xch,
return NULL;
for ( i = 0; i < num; i++ )
- arr[i] = mfn + i;
+ arr[i] = pfn + i;
ret = xc_map_foreign_pages(xch, dom, prot, arr, num);
free(arr);
diff --git a/tools/libxl/libxl_console.c b/tools/libxl/libxl_console.c
index 6bfc0e5..f2ca689 100644
--- a/tools/libxl/libxl_console.c
+++ b/tools/libxl/libxl_console.c
@@ -329,7 +329,7 @@ int libxl__device_console_add(libxl__gc *gc, uint32_t domid,
flexarray_append(ro_front, "port");
flexarray_append(ro_front, GCSPRINTF("%"PRIu32, state->console_port));
flexarray_append(ro_front, "ring-ref");
- flexarray_append(ro_front, GCSPRINTF("%lu", state->console_mfn));
+ flexarray_append(ro_front, GCSPRINTF("%"PRIu_xen_pfn, state->console_mfn));
} else {
flexarray_append(front, "state");
flexarray_append(front, GCSPRINTF("%d", XenbusStateInitialising));
diff --git a/tools/libxl/libxl_create.c b/tools/libxl/libxl_create.c
index f15fb21..26870ca 100644
--- a/tools/libxl/libxl_create.c
+++ b/tools/libxl/libxl_create.c
@@ -1134,7 +1134,7 @@ static void domcreate_bootloader_done(libxl__egc *egc,
}
void libxl__srm_callout_callback_restore_results(xen_pfn_t store_mfn,
- xen_pfn_t console_mfn, void *user)
+ xen_pfn_t console_gfn, void *user)
{
libxl__save_helper_state *shs = user;
libxl__domain_create_state *dcs = shs->caller_state;
@@ -1142,7 +1142,7 @@ void libxl__srm_callout_callback_restore_results(xen_pfn_t store_mfn,
libxl__domain_build_state *const state = &dcs->build_state;
state->store_mfn = store_mfn;
- state->console_mfn = console_mfn;
+ state->console_gfn = console_gfn;
shs->need_results = 0;
}
@@ -1740,7 +1740,7 @@ static int do_domain_soft_reset(libxl_ctx *ctx,
libxl__domain_create_state *dcs;
libxl__domain_build_state *state;
libxl__domain_save_state *dss;
- const char *console_tty, *xs_store_mfn, *xs_console_mfn;
+ const char *console_tty, *xs_store_mfn, *xs_console_gfn;
char *dom_path;
uint32_t domid_out;
int rc;
@@ -1781,12 +1781,12 @@ static int do_domain_soft_reset(libxl_ctx *ctx,
rc = libxl__xs_read_checked(gc, XBT_NULL,
GCSPRINTF("%s/console/ring-ref", dom_path),
- &xs_console_mfn);
+ &xs_console_gfn);
if (rc) {
LOGD(ERROR, domid_soft_reset, "failed to read console/ring-ref.");
goto out;
}
- state->console_mfn = xs_console_mfn ? atol(xs_console_mfn): 0;
+ state->console_gfn = xs_console_gfn ? atol(xs_console_gfn): 0;
rc = libxl__xs_read_mandatory(gc, XBT_NULL,
GCSPRINTF("%s/console/tty", dom_path),
diff --git a/tools/libxl/libxl_dom.c b/tools/libxl/libxl_dom.c
index ef834e6..647dbf7 100644
--- a/tools/libxl/libxl_dom.c
+++ b/tools/libxl/libxl_dom.c
@@ -852,11 +852,11 @@ int libxl__build_pv(libxl__gc *gc, uint32_t domid,
goto out;
if (xc_dom_translated(dom)) {
- state->console_mfn = dom->console_pfn;
+ state->console_gfn = dom->console_pfn;
state->store_mfn = dom->xenstore_pfn;
state->vuart_gfn = dom->vuart_gfn;
} else {
- state->console_mfn = xc_dom_p2m(dom, dom->console_pfn);
+ state->console_gfn = xc_dom_p2m(dom, dom->console_pfn);
state->store_mfn = xc_dom_p2m(dom, dom->xenstore_pfn);
}
@@ -869,7 +869,7 @@ out:
static int hvm_build_set_params(xc_interface *handle, uint32_t domid,
libxl_domain_build_info *info,
int store_evtchn, unsigned long *store_mfn,
- int console_evtchn, unsigned long *console_mfn,
+ int console_evtchn, xen_pfn_t *console_gfn,
domid_t store_domid, domid_t console_domid)
{
struct hvm_info_table *va_hvm;
@@ -901,9 +901,9 @@ static int hvm_build_set_params(xc_interface *handle, uint32_t domid,
xc_hvm_param_set(handle, domid, HVM_PARAM_CONSOLE_EVTCHN, console_evtchn);
*store_mfn = str_mfn;
- *console_mfn = cons_mfn;
+ *console_gfn = cons_mfn;
- xc_dom_gnttab_hvm_seed(handle, domid, *console_mfn, *store_mfn, console_domid, store_domid);
+ xc_dom_gnttab_hvm_seed(handle, domid, *console_gfn, *store_mfn, console_domid, store_domid);
return 0;
}
@@ -1270,7 +1270,7 @@ int libxl__build_hvm(libxl__gc *gc, uint32_t domid,
rc = hvm_build_set_params(ctx->xch, domid, info, state->store_port,
&state->store_mfn, state->console_port,
- &state->console_mfn, state->store_domid,
+ &state->console_gfn, state->store_domid,
state->console_domid);
if (rc != 0) {
LOG(ERROR, "hvm build set params failed");
diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h
index bfa95d8..49f7966 100644
--- a/tools/libxl/libxl_internal.h
+++ b/tools/libxl/libxl_internal.h
@@ -1129,7 +1129,7 @@ typedef struct {
uint32_t console_port;
uint32_t console_domid;
- unsigned long console_mfn;
+ xen_pfn_t console_gfn;
char *console_tty;
char *saved_state;
diff --git a/tools/libxl/libxl_save_helper.c b/tools/libxl/libxl_save_helper.c
index 38089a0..bf50ec8 100644
--- a/tools/libxl/libxl_save_helper.c
+++ b/tools/libxl/libxl_save_helper.c
@@ -284,17 +284,17 @@ int main(int argc, char **argv)
helper_setcallbacks_restore(&helper_restore_callbacks, cbflags);
unsigned long store_mfn = 0;
- unsigned long console_mfn = 0;
+ unsigned long console_gfn = 0;
startup("restore");
setup_signals(SIG_DFL);
r = xc_domain_restore(xch, io_fd, dom, store_evtchn, &store_mfn,
- store_domid, console_evtchn, &console_mfn,
+ store_domid, console_evtchn, &console_gfn,
console_domid, hvm, pae,
stream_type,
&helper_restore_callbacks, send_back_fd);
- helper_stub_restore_results(store_mfn,console_mfn,0);
+ helper_stub_restore_results(store_mfn,console_gfn,0);
complete(r);
} else {
--
2.7.4
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PATCH 3/4 v3] xenconsole: Change the type of ring_ref to xen_pfn_t in console_create_ring
2017-10-31 6:55 [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t Bhupinder Thakur
@ 2017-10-31 6:55 ` Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1 Bhupinder Thakur
2017-10-31 10:07 ` [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Wei Liu
3 siblings, 0 replies; 12+ messages in thread
From: Bhupinder Thakur @ 2017-10-31 6:55 UTC (permalink / raw)
To: xen-devel; +Cc: Wei Liu, Julien Grall, Stefano Stabellini, Ian Jackson
Currently, ring_ref is read as an integer in console_create_ring which could lead to
truncation of the value as it is reading a 64-bit value.
The fix is to modify the type of ring_ref to xen_pfn_t and use the correct format
specifier to read the value correctly for all architectures.
Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
Acked-by: Wei Liu <wei.liu2@citrix.com>
---
CC: Ian Jackson <ian.jackson@eu.citrix.com>
CC: Wei Liu <wei.liu2@citrix.com>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Julien Grall <julien.grall@arm.com>
This patch is as per the review of commit fa1f157
libxl: Fix the bug introduced in commit "libxl: use correct type
tools/console/daemon/io.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c
index e22009a..1839973 100644
--- a/tools/console/daemon/io.c
+++ b/tools/console/daemon/io.c
@@ -19,6 +19,7 @@
#define _GNU_SOURCE
+#include <inttypes.h>
#include "utils.h"
#include "io.h"
#include <xenevtchn.h>
@@ -81,6 +82,12 @@ static unsigned int nr_fds;
#define ROUNDUP(_x,_w) (((unsigned long)(_x)+(1UL<<(_w))-1) & ~((1UL<<(_w))-1))
+#if defined(CONFIG_ARM)
+# define SCNi_xen_pfn SCNi64
+#else
+# define SCNi_xen_pfn "li"
+#endif
+
struct buffer {
char *data;
size_t consumed;
@@ -98,7 +105,7 @@ struct console {
struct buffer buffer;
char *xspath;
char *log_suffix;
- int ring_ref;
+ xen_pfn_t ring_ref;
xenevtchn_handle *xce_handle;
int xce_pollfd_idx;
int event_count;
@@ -661,12 +668,13 @@ static void console_unmap_interface(struct console *con)
static int console_create_ring(struct console *con)
{
- int err, remote_port, ring_ref, rc;
+ int err, remote_port, rc;
+ xen_pfn_t ring_ref;
char *type, path[PATH_MAX];
struct domain *dom = con->d;
err = xs_gather(xs, con->xspath,
- "ring-ref", "%u", &ring_ref,
+ "ring-ref", "%"SCNi_xen_pfn, &ring_ref,
"port", "%i", &remote_port,
NULL);
@@ -705,7 +713,7 @@ static int console_create_ring(struct console *con)
con->interface = xc_map_foreign_range(
xc, dom->domid, XC_PAGE_SIZE,
PROT_READ|PROT_WRITE,
- (unsigned long)ring_ref);
+ ring_ref);
if (con->interface == NULL) {
err = EINVAL;
goto out;
--
2.7.4
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1
2017-10-31 6:55 [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 3/4 v3] xenconsole: Change the type of ring_ref to xen_pfn_t in console_create_ring Bhupinder Thakur
@ 2017-10-31 6:55 ` Bhupinder Thakur
2017-10-31 10:06 ` Wei Liu
2017-10-31 10:07 ` [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Wei Liu
3 siblings, 1 reply; 12+ messages in thread
From: Bhupinder Thakur @ 2017-10-31 6:55 UTC (permalink / raw)
To: xen-devel; +Cc: Wei Liu, Julien Grall, Stefano Stabellini, Ian Jackson
xenconsole will use a new macro XEN_INVALID_PFN instead of -1 for initializing ring-ref.
Since the type of ring_ref is changed to xen_pfn_t (which is an unsigned value) assigning -1
appeared to be confusing. For clarity, XEN_INVALID_PFN is introduced.
Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
---
CC: Ian Jackson <ian.jackson@eu.citrix.com>
CC: Wei Liu <wei.liu2@citrix.com>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Julien Grall <julien.grall@arm.com>
This patch is as per the review of commit fa1f157
libxl: Fix the bug introduced in commit "libxl: use correct type
tools/console/daemon/io.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c
index 1839973..aa291db 100644
--- a/tools/console/daemon/io.c
+++ b/tools/console/daemon/io.c
@@ -62,6 +62,8 @@
/* Duration of each time period in ms */
#define RATE_LIMIT_PERIOD 200
+#define XEN_INVALID_PFN (~(xen_pfn_t)0)
+
extern int log_reload;
extern int log_guest;
extern int log_hv;
@@ -658,12 +660,12 @@ static void console_unmap_interface(struct console *con)
{
if (con->interface == NULL)
return;
- if (xgt_handle && con->ring_ref == -1)
+ if (xgt_handle && con->ring_ref == XEN_INVALID_PFN)
xengnttab_unmap(xgt_handle, con->interface, 1);
else
munmap(con->interface, XC_PAGE_SIZE);
con->interface = NULL;
- con->ring_ref = -1;
+ con->ring_ref = XEN_INVALID_PFN;
}
static int console_create_ring(struct console *con)
@@ -698,7 +700,7 @@ static int console_create_ring(struct console *con)
free(type);
/* If using ring_ref and it has changed, remap */
- if (ring_ref != con->ring_ref && con->ring_ref != -1)
+ if (ring_ref != con->ring_ref && con->ring_ref != XEN_INVALID_PFN)
console_unmap_interface(con);
if (!con->interface && xgt_handle && con->use_gnttab) {
@@ -706,7 +708,7 @@ static int console_create_ring(struct console *con)
con->interface = xengnttab_map_grant_ref(xgt_handle,
dom->domid, GNTTAB_RESERVED_CONSOLE,
PROT_READ|PROT_WRITE);
- con->ring_ref = -1;
+ con->ring_ref = XEN_INVALID_PFN;
}
if (!con->interface) {
/* Fall back to xc_map_foreign_range */
@@ -812,7 +814,7 @@ static int console_init(struct console *con, struct domain *dom, void **data)
con->master_pollfd_idx = -1;
con->slave_fd = -1;
con->log_fd = -1;
- con->ring_ref = -1;
+ con->ring_ref = XEN_INVALID_PFN;
con->local_port = -1;
con->remote_port = -1;
con->xce_pollfd_idx = -1;
--
2.7.4
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t
2017-10-31 6:55 ` [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t Bhupinder Thakur
@ 2017-10-31 10:05 ` Wei Liu
0 siblings, 0 replies; 12+ messages in thread
From: Wei Liu @ 2017-10-31 10:05 UTC (permalink / raw)
To: Bhupinder Thakur
Cc: xen-devel, Julien Grall, Stefano Stabellini, Ian Jackson, Wei Liu
On Tue, Oct 31, 2017 at 12:25:06PM +0530, Bhupinder Thakur wrote:
> Currently the type of console mfn is unsigned long in libxl. This may be
> an issue for 32-bit toolstack running on 64-bit Xen, where the pfn are
> 64 bit. To ensure that console_mfn can hold any valid 64-bit pfn, the
> type of console_mfn is changed to xen_pfn_t.
>
> Also the name console_mfn is misleading as it is actually a gfn. This
> patch also modifies the name to console_gfn.
>
> Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
Acked-by: Wei Liu <wei.liu2@citrix.com>
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1
2017-10-31 6:55 ` [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1 Bhupinder Thakur
@ 2017-10-31 10:06 ` Wei Liu
0 siblings, 0 replies; 12+ messages in thread
From: Wei Liu @ 2017-10-31 10:06 UTC (permalink / raw)
To: Bhupinder Thakur
Cc: xen-devel, Julien Grall, Stefano Stabellini, Ian Jackson, Wei Liu
On Tue, Oct 31, 2017 at 12:25:08PM +0530, Bhupinder Thakur wrote:
> xenconsole will use a new macro XEN_INVALID_PFN instead of -1 for initializing ring-ref.
> Since the type of ring_ref is changed to xen_pfn_t (which is an unsigned value) assigning -1
> appeared to be confusing. For clarity, XEN_INVALID_PFN is introduced.
>
> Signed-off-by: Bhupinder Thakur <bhupinder.thakur@linaro.org>
Acked-by: Wei Liu <wei.liu2@citrix.com>
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-10-31 6:55 [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Bhupinder Thakur
` (2 preceding siblings ...)
2017-10-31 6:55 ` [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1 Bhupinder Thakur
@ 2017-10-31 10:07 ` Wei Liu
2017-11-13 15:56 ` Julien Grall
3 siblings, 1 reply; 12+ messages in thread
From: Wei Liu @ 2017-10-31 10:07 UTC (permalink / raw)
To: Bhupinder Thakur, Julien Grall
Cc: Stefano Stabellini, Wei Liu, Andrew Cooper, Ian Jackson,
Julien Grall, Jan Beulich, xen-devel
Change the tag to for-4.10.
Julien, this is needed to fix vuart emulation.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-10-31 10:07 ` [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Wei Liu
@ 2017-11-13 15:56 ` Julien Grall
2017-11-14 10:05 ` Wei Liu
0 siblings, 1 reply; 12+ messages in thread
From: Julien Grall @ 2017-11-13 15:56 UTC (permalink / raw)
To: Wei Liu, Bhupinder Thakur
Cc: Stefano Stabellini, Andrew Cooper, Ian Jackson, Julien Grall,
Jan Beulich, xen-devel
Hi Wei,
Sorry I missed that e-mail.
On 10/31/2017 10:07 AM, Wei Liu wrote:
> Change the tag to for-4.10.
>
> Julien, this is needed to fix vuart emulation.
To confirm, only patch #1 is candidate for Xen 4.10, right? The rest
will be queued for Xen 4.11?
For patch #1:
Release-acked-by: Julien Grall <julien.grall@linaro.org>
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-11-13 15:56 ` Julien Grall
@ 2017-11-14 10:05 ` Wei Liu
2017-11-14 11:42 ` Bhupinder Thakur
0 siblings, 1 reply; 12+ messages in thread
From: Wei Liu @ 2017-11-14 10:05 UTC (permalink / raw)
To: Julien Grall
Cc: Stefano Stabellini, Wei Liu, Andrew Cooper, Ian Jackson,
Julien Grall, Jan Beulich, Bhupinder Thakur, xen-devel
On Mon, Nov 13, 2017 at 03:56:23PM +0000, Julien Grall wrote:
> Hi Wei,
>
> Sorry I missed that e-mail.
>
> On 10/31/2017 10:07 AM, Wei Liu wrote:
> > Change the tag to for-4.10.
> >
> > Julien, this is needed to fix vuart emulation.
>
> To confirm, only patch #1 is candidate for Xen 4.10, right? The rest will be
> queued for Xen 4.11?
>
I think so.
Bhupinder, can you confirm that?
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-11-14 10:05 ` Wei Liu
@ 2017-11-14 11:42 ` Bhupinder Thakur
2017-11-14 13:56 ` Wei Liu
0 siblings, 1 reply; 12+ messages in thread
From: Bhupinder Thakur @ 2017-11-14 11:42 UTC (permalink / raw)
To: Wei Liu
Cc: Stefano Stabellini, Andrew Cooper, Julien Grall, Ian Jackson,
Julien Grall, Jan Beulich, Xen-devel
[-- Attachment #1.1: Type: text/plain, Size: 581 bytes --]
Hi,
On 14 Nov 2017 3:35 pm, "Wei Liu" <wei.liu2@citrix.com> wrote:
> On Mon, Nov 13, 2017 at 03:56:23PM +0000, Julien Grall wrote:
> > Hi Wei,
> >
> > Sorry I missed that e-mail.
> >
> > On 10/31/2017 10:07 AM, Wei Liu wrote:
> > > Change the tag to for-4.10.
> > >
> > > Julien, this is needed to fix vuart emulation.
> >
> > To confirm, only patch #1 is candidate for Xen 4.10, right? The rest
> will be
> > queued for Xen 4.11?
> >
>
> I think so.
>
> Bhupinder, can you confirm that?
>
Yes. Only first patch is required for fixing the compilation issue.
Regards,
Bhupinder
[-- Attachment #1.2: Type: text/html, Size: 1094 bytes --]
[-- Attachment #2: Type: text/plain, Size: 127 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-11-14 11:42 ` Bhupinder Thakur
@ 2017-11-14 13:56 ` Wei Liu
2018-01-24 12:34 ` Wei Liu
0 siblings, 1 reply; 12+ messages in thread
From: Wei Liu @ 2017-11-14 13:56 UTC (permalink / raw)
To: Bhupinder Thakur
Cc: Stefano Stabellini, Wei Liu, Andrew Cooper, Julien Grall,
Ian Jackson, Julien Grall, Jan Beulich, Xen-devel
On Tue, Nov 14, 2017 at 05:12:26PM +0530, Bhupinder Thakur wrote:
> Hi,
>
> On 14 Nov 2017 3:35 pm, "Wei Liu" <wei.liu2@citrix.com> wrote:
>
> > On Mon, Nov 13, 2017 at 03:56:23PM +0000, Julien Grall wrote:
> > > Hi Wei,
> > >
> > > Sorry I missed that e-mail.
> > >
> > > On 10/31/2017 10:07 AM, Wei Liu wrote:
> > > > Change the tag to for-4.10.
> > > >
> > > > Julien, this is needed to fix vuart emulation.
> > >
> > > To confirm, only patch #1 is candidate for Xen 4.10, right? The rest
> > will be
> > > queued for Xen 4.11?
> > >
> >
> > I think so.
> >
> > Bhupinder, can you confirm that?
> >
>
> Yes. Only first patch is required for fixing the compilation issue.
>
Thanks. I will commit the first patch and put the rest in my for-next
queue.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn"
2017-11-14 13:56 ` Wei Liu
@ 2018-01-24 12:34 ` Wei Liu
0 siblings, 0 replies; 12+ messages in thread
From: Wei Liu @ 2018-01-24 12:34 UTC (permalink / raw)
To: Bhupinder Thakur
Cc: Stefano Stabellini, Wei Liu, Andrew Cooper, Julien Grall,
Ian Jackson, Julien Grall, Jan Beulich, Xen-devel
On Tue, Nov 14, 2017 at 01:56:11PM +0000, Wei Liu wrote:
> On Tue, Nov 14, 2017 at 05:12:26PM +0530, Bhupinder Thakur wrote:
> > Hi,
> >
> > On 14 Nov 2017 3:35 pm, "Wei Liu" <wei.liu2@citrix.com> wrote:
> >
> > > On Mon, Nov 13, 2017 at 03:56:23PM +0000, Julien Grall wrote:
> > > > Hi Wei,
> > > >
> > > > Sorry I missed that e-mail.
> > > >
> > > > On 10/31/2017 10:07 AM, Wei Liu wrote:
> > > > > Change the tag to for-4.10.
> > > > >
> > > > > Julien, this is needed to fix vuart emulation.
> > > >
> > > > To confirm, only patch #1 is candidate for Xen 4.10, right? The rest
> > > will be
> > > > queued for Xen 4.11?
> > > >
> > >
> > > I think so.
> > >
> > > Bhupinder, can you confirm that?
> > >
> >
> > Yes. Only first patch is required for fixing the compilation issue.
> >
>
> Thanks. I will commit the first patch and put the rest in my for-next
> queue.
OK, patch 2 to 4 applied cleanly but the build is broken by them.
libxl_console.c: In function ‘libxl__device_console_add’:
libxl_console.c:332:68: error: ‘libxl__domain_build_state {aka struct <anonymous>}’ has no member named ‘console_mfn’; did you mean ‘console_gfn’?
flexarray_append(ro_front, GCSPRINTF("%"PRIu_xen_pfn, state->console_mfn));
^
libxl_internal.h:3921:58: note: in definition of macro ‘GCSPRINTF’
#define GCSPRINTF(fmt, ...) (libxl__sprintf((gc), (fmt), __VA_ARGS__))
^~~~~~~~~~~
For now I've dropped this series.
Wei.
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2018-01-24 12:35 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-31 6:55 [PATCH 1/4 v3] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 2/4 v3] libxl: Change the type of console_mfn to xen_pfn_t Bhupinder Thakur
2017-10-31 10:05 ` Wei Liu
2017-10-31 6:55 ` [PATCH 3/4 v3] xenconsole: Change the type of ring_ref to xen_pfn_t in console_create_ring Bhupinder Thakur
2017-10-31 6:55 ` [PATCH 4/4 v3] xenconsole: Define and use a macro XEN_INVALID_PFN instead of -1 Bhupinder Thakur
2017-10-31 10:06 ` Wei Liu
2017-10-31 10:07 ` [PATCH 1/4 v3 for-4.10] libxl: Fix the bug introduced in commit "libxl: use correct type modifier for vuart_gfn" Wei Liu
2017-11-13 15:56 ` Julien Grall
2017-11-14 10:05 ` Wei Liu
2017-11-14 11:42 ` Bhupinder Thakur
2017-11-14 13:56 ` Wei Liu
2018-01-24 12:34 ` Wei Liu
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).