[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v4 04/39] arm/p2m: Add HVMOP_altp2m_get_domain_state
This commit adopts the x86 HVMOP_altp2m_get_domain_state implementation. Signed-off-by: Sergej Proskurin <proskurin@xxxxxxxxxxxxx> --- Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx> Cc: Julien Grall <julien.grall@xxxxxxx> --- v3: Removed the "altp2m_enabled" check in HVMOP_altp2m_get_domain_state case as it has been moved in front of the switch statement in "do_altp2m_op". Removed the macro "altp2m_enabled". Instead, check directly for the HVM_PARAM_ALTP2M param in d->arch.hvm_domain. --- xen/arch/arm/hvm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xen/arch/arm/hvm.c b/xen/arch/arm/hvm.c index 6f5f9b41ac..43b8352cb7 100644 --- a/xen/arch/arm/hvm.c +++ b/xen/arch/arm/hvm.c @@ -85,7 +85,8 @@ static int do_altp2m_op(XEN_GUEST_HANDLE_PARAM(void) arg) switch ( a.cmd ) { case HVMOP_altp2m_get_domain_state: - rc = -EOPNOTSUPP; + a.u.domain_state.state = altp2m_active(d); + rc = __copy_to_guest(arg, &a, 1) ? -EFAULT : 0; break; case HVMOP_altp2m_set_domain_state: -- 2.13.3 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |