* [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype
@ 2017-06-07 7:20 Sergey Dyasli
2017-06-07 10:22 ` Juergen Gross
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Sergey Dyasli @ 2017-06-07 7:20 UTC (permalink / raw)
To: xen-devel, linux-kernel
Cc: Paul Durrant, Stefano Stabellini, Boris Ostrovsky, Juergen Gross,
Julien Grall, Marc Zyngier, Jan Beulich, Andrew Cooper,
Sergey Dyasli
Change the third parameter to be the required struct xen_dm_op_buf *
instead of a generic void * (which blindly accepts any pointer).
Signed-off-by: Sergey Dyasli <sergey.dyasli@citrix.com>
---
v1 --> v2:
- Replaced "#include <xen/interface/hvm/dm_op.h>" with
forward declaration of struct xen_dm_op_buf
arch/x86/include/asm/xen/hypercall.h | 4 +++-
include/xen/arm/hypercall.h | 5 ++++-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/arch/x86/include/asm/xen/hypercall.h b/arch/x86/include/asm/xen/hypercall.h
index f6d20f6cca12..7a4db5fefd15 100644
--- a/arch/x86/include/asm/xen/hypercall.h
+++ b/arch/x86/include/asm/xen/hypercall.h
@@ -50,6 +50,8 @@
#include <xen/interface/platform.h>
#include <xen/interface/xen-mca.h>
+struct xen_dm_op_buf;
+
/*
* The hypercall asms have to meet several constraints:
* - Work on 32- and 64-bit.
@@ -474,7 +476,7 @@ HYPERVISOR_xenpmu_op(unsigned int op, void *arg)
static inline int
HYPERVISOR_dm_op(
- domid_t dom, unsigned int nr_bufs, void *bufs)
+ domid_t dom, unsigned int nr_bufs, struct xen_dm_op_buf *bufs)
{
return _hypercall3(int, dm_op, dom, nr_bufs, bufs);
}
diff --git a/include/xen/arm/hypercall.h b/include/xen/arm/hypercall.h
index 73db4b2eeb89..b40485e54d80 100644
--- a/include/xen/arm/hypercall.h
+++ b/include/xen/arm/hypercall.h
@@ -39,6 +39,8 @@
#include <xen/interface/sched.h>
#include <xen/interface/platform.h>
+struct xen_dm_op_buf;
+
long privcmd_call(unsigned call, unsigned long a1,
unsigned long a2, unsigned long a3,
unsigned long a4, unsigned long a5);
@@ -53,7 +55,8 @@ int HYPERVISOR_physdev_op(int cmd, void *arg);
int HYPERVISOR_vcpu_op(int cmd, int vcpuid, void *extra_args);
int HYPERVISOR_tmem_op(void *arg);
int HYPERVISOR_vm_assist(unsigned int cmd, unsigned int type);
-int HYPERVISOR_dm_op(domid_t domid, unsigned int nr_bufs, void *bufs);
+int HYPERVISOR_dm_op(domid_t domid, unsigned int nr_bufs,
+ struct xen_dm_op_buf *bufs);
int HYPERVISOR_platform_op_raw(void *arg);
static inline int HYPERVISOR_platform_op(struct xen_platform_op *op)
{
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype
2017-06-07 7:20 [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype Sergey Dyasli
@ 2017-06-07 10:22 ` Juergen Gross
2017-06-07 18:09 ` Stefano Stabellini
2017-06-08 17:42 ` Juergen Gross
2 siblings, 0 replies; 4+ messages in thread
From: Juergen Gross @ 2017-06-07 10:22 UTC (permalink / raw)
To: Sergey Dyasli, xen-devel, linux-kernel
Cc: Paul Durrant, Stefano Stabellini, Boris Ostrovsky, Julien Grall,
Marc Zyngier, Jan Beulich, Andrew Cooper
On 07/06/17 09:20, Sergey Dyasli wrote:
> Change the third parameter to be the required struct xen_dm_op_buf *
> instead of a generic void * (which blindly accepts any pointer).
>
> Signed-off-by: Sergey Dyasli <sergey.dyasli@citrix.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Thanks,
Juergen
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype
2017-06-07 7:20 [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype Sergey Dyasli
2017-06-07 10:22 ` Juergen Gross
@ 2017-06-07 18:09 ` Stefano Stabellini
2017-06-08 17:42 ` Juergen Gross
2 siblings, 0 replies; 4+ messages in thread
From: Stefano Stabellini @ 2017-06-07 18:09 UTC (permalink / raw)
To: Sergey Dyasli
Cc: xen-devel, linux-kernel, Paul Durrant, Stefano Stabellini,
Boris Ostrovsky, Juergen Gross, Julien Grall, Marc Zyngier,
Jan Beulich, Andrew Cooper
On Wed, 7 Jun 2017, Sergey Dyasli wrote:
> Change the third parameter to be the required struct xen_dm_op_buf *
> instead of a generic void * (which blindly accepts any pointer).
>
> Signed-off-by: Sergey Dyasli <sergey.dyasli@citrix.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
> ---
> v1 --> v2:
> - Replaced "#include <xen/interface/hvm/dm_op.h>" with
> forward declaration of struct xen_dm_op_buf
>
> arch/x86/include/asm/xen/hypercall.h | 4 +++-
> include/xen/arm/hypercall.h | 5 ++++-
> 2 files changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/arch/x86/include/asm/xen/hypercall.h b/arch/x86/include/asm/xen/hypercall.h
> index f6d20f6cca12..7a4db5fefd15 100644
> --- a/arch/x86/include/asm/xen/hypercall.h
> +++ b/arch/x86/include/asm/xen/hypercall.h
> @@ -50,6 +50,8 @@
> #include <xen/interface/platform.h>
> #include <xen/interface/xen-mca.h>
>
> +struct xen_dm_op_buf;
> +
> /*
> * The hypercall asms have to meet several constraints:
> * - Work on 32- and 64-bit.
> @@ -474,7 +476,7 @@ HYPERVISOR_xenpmu_op(unsigned int op, void *arg)
>
> static inline int
> HYPERVISOR_dm_op(
> - domid_t dom, unsigned int nr_bufs, void *bufs)
> + domid_t dom, unsigned int nr_bufs, struct xen_dm_op_buf *bufs)
> {
> return _hypercall3(int, dm_op, dom, nr_bufs, bufs);
> }
> diff --git a/include/xen/arm/hypercall.h b/include/xen/arm/hypercall.h
> index 73db4b2eeb89..b40485e54d80 100644
> --- a/include/xen/arm/hypercall.h
> +++ b/include/xen/arm/hypercall.h
> @@ -39,6 +39,8 @@
> #include <xen/interface/sched.h>
> #include <xen/interface/platform.h>
>
> +struct xen_dm_op_buf;
> +
> long privcmd_call(unsigned call, unsigned long a1,
> unsigned long a2, unsigned long a3,
> unsigned long a4, unsigned long a5);
> @@ -53,7 +55,8 @@ int HYPERVISOR_physdev_op(int cmd, void *arg);
> int HYPERVISOR_vcpu_op(int cmd, int vcpuid, void *extra_args);
> int HYPERVISOR_tmem_op(void *arg);
> int HYPERVISOR_vm_assist(unsigned int cmd, unsigned int type);
> -int HYPERVISOR_dm_op(domid_t domid, unsigned int nr_bufs, void *bufs);
> +int HYPERVISOR_dm_op(domid_t domid, unsigned int nr_bufs,
> + struct xen_dm_op_buf *bufs);
> int HYPERVISOR_platform_op_raw(void *arg);
> static inline int HYPERVISOR_platform_op(struct xen_platform_op *op)
> {
> --
> 2.11.0
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype
2017-06-07 7:20 [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype Sergey Dyasli
2017-06-07 10:22 ` Juergen Gross
2017-06-07 18:09 ` Stefano Stabellini
@ 2017-06-08 17:42 ` Juergen Gross
2 siblings, 0 replies; 4+ messages in thread
From: Juergen Gross @ 2017-06-08 17:42 UTC (permalink / raw)
To: Sergey Dyasli, xen-devel, linux-kernel
Cc: Paul Durrant, Stefano Stabellini, Boris Ostrovsky, Julien Grall,
Marc Zyngier, Jan Beulich, Andrew Cooper
On 07/06/17 09:20, Sergey Dyasli wrote:
> Change the third parameter to be the required struct xen_dm_op_buf *
> instead of a generic void * (which blindly accepts any pointer).
>
> Signed-off-by: Sergey Dyasli <sergey.dyasli@citrix.com>
Committed to xen/tip.git for-linus-4.13
Thanks,
Juergen
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-06-08 17:42 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-07 7:20 [PATCH v2] xen: fix HYPERVISOR_dm_op() prototype Sergey Dyasli
2017-06-07 10:22 ` Juergen Gross
2017-06-07 18:09 ` Stefano Stabellini
2017-06-08 17:42 ` Juergen Gross
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).