]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
x86, microcode: Save an indentation level in reload_for_cpu
authorBorislav Petkov <borislav.petkov@amd.com>
Mon, 23 Jul 2012 17:05:53 +0000 (19:05 +0200)
committerH. Peter Anvin <hpa@linux.intel.com>
Wed, 22 Aug 2012 23:14:08 +0000 (16:14 -0700)
Invert the uci->valid check so that the later block can be aligned on
the first indentation level of the function. No functional change.

Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Link: http://lkml.kernel.org/r/1344361461-10076-3-git-send-email-bp@amd64.org
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
arch/x86/kernel/microcode_core.c

index 4873e62db6a18468b23736c5f4adfd2de8b3b85b..63a95686502272f639e68d88532030f9562b16f8 100644 (file)
@@ -276,19 +276,18 @@ static struct platform_device     *microcode_pdev;
 static int reload_for_cpu(int cpu)
 {
        struct ucode_cpu_info *uci = ucode_cpu_info + cpu;
+       enum ucode_state ustate;
        int err = 0;
 
-       if (uci->valid) {
-               enum ucode_state ustate;
-
-               ustate = microcode_ops->request_microcode_fw(cpu, &microcode_pdev->dev);
-               if (ustate == UCODE_OK)
-                       apply_microcode_on_target(cpu);
-               else
-                       if (ustate == UCODE_ERROR)
-                               err = -EINVAL;
-       }
+       if (!uci->valid)
+               return err;
 
+       ustate = microcode_ops->request_microcode_fw(cpu, &microcode_pdev->dev);
+       if (ustate == UCODE_OK)
+               apply_microcode_on_target(cpu);
+       else
+               if (ustate == UCODE_ERROR)
+                       err = -EINVAL;
        return err;
 }