libxc: do not return a value from xc_cpuid_policy
authorRoger Pau Monne <roger.pau@citrix.com>
Thu, 28 Jun 2018 10:12:07 +0000 (12:12 +0200)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Thu, 28 Jun 2018 10:32:42 +0000 (11:32 +0100)
None of the called functions return any errors, so there's no point in
returning an int from xc_cpuid_policy.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
tools/libxc/xc_cpuid_x86.c

index 364f802c0fe7e8a3a5b088040d95665f4e7aba4d..3d1421aa50770cebbfd35678a0e925b13e739eb7 100644 (file)
@@ -592,9 +592,9 @@ static void xc_cpuid_pv_policy(xc_interface *xch,
     }
 }
 
-static int xc_cpuid_policy(xc_interface *xch,
-                           const struct cpuid_domain_info *info,
-                           const unsigned int *input, unsigned int *regs)
+static void xc_cpuid_policy(xc_interface *xch,
+                            const struct cpuid_domain_info *info,
+                            const unsigned int *input, unsigned int *regs)
 {
     /*
      * For hypervisor leaves (0x4000XXXX) only 0x4000xx00.EAX[7:0] bits (max
@@ -604,15 +604,13 @@ static int xc_cpuid_policy(xc_interface *xch,
     if ( (input[0] & 0xffff0000) == 0x40000000 )
     {
         regs[0] = regs[1] = regs[2] = regs[3] = 0;
-        return 0;
+        return;
     }
 
     if ( info->hvm )
         xc_cpuid_hvm_policy(xch, info, input, regs);
     else
         xc_cpuid_pv_policy(xch, info, input, regs);
-
-    return 0;
 }
 
 static int xc_cpuid_do_domctl(