domctl: prefer is_..._domain() over is_..._vcpu()
authorJan Beulich <jbeulich@suse.com>
Fri, 12 Jun 2015 10:02:12 +0000 (12:02 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 12 Jun 2015 10:02:12 +0000 (12:02 +0200)
... when the domain pointer is already available.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
xen/common/domctl.c

index e571e762bc667d732275f763e0a4c7e64291bb96..ce517a76beba269314ef6ce873bdd44be7642f07 100644 (file)
@@ -495,7 +495,7 @@ long do_domctl(XEN_GUEST_HANDLE_PARAM(xen_domctl_t) u_domctl)
             break;
 
 #ifdef CONFIG_COMPAT
-        if ( !is_pv_32on64_vcpu(v) )
+        if ( !is_pv_32on64_domain(d) )
             ret = copy_from_guest(c.nat, op->u.vcpucontext.ctxt, 1);
         else
             ret = copy_from_guest(c.cmp,
@@ -901,7 +901,7 @@ long do_domctl(XEN_GUEST_HANDLE_PARAM(xen_domctl_t) u_domctl)
         vcpu_unpause(v);
 
 #ifdef CONFIG_COMPAT
-        if ( !is_pv_32on64_vcpu(v) )
+        if ( !is_pv_32on64_domain(d) )
             ret = copy_to_guest(op->u.vcpucontext.ctxt, c.nat, 1);
         else
             ret = copy_to_guest(guest_handle_cast(op->u.vcpucontext.ctxt,