]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
powerpc/64s: Fix Power9 DD2.1 logic in DT CPU features
authorMichael Ellerman <mpe@ellerman.id.au>
Wed, 22 Nov 2017 12:17:01 +0000 (23:17 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 22 Nov 2017 12:17:01 +0000 (23:17 +1100)
I got the logic wrong in the DT CPU features code when I added the
Power9 DD2.1 feature. We should be setting the bit if we detect a
DD2.1, not clearing it if we detect a DD2.0.

This code isn't actually exercised at the moment so nothing is
actually broken.

Fixes: 3ffa9d9e2a7c ("powerpc/64s: Fix Power9 DD2.0 workarounds by adding DD2.1 feature")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/dt_cpu_ftrs.c

index 602e0fde19b4a28ca505162dc07546bb2422b988..8bdc2f96c5d6a7a29b0fd299f2e121dc6a993911 100644 (file)
@@ -735,8 +735,8 @@ static __init void cpufeatures_cpu_quirks(void)
         */
        if ((version & 0xffffff00) == 0x004e0100)
                cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD1;
-       else if ((version & 0xffffefff) == 0x004e0200)
-               cur_cpu_spec->cpu_features &= ~CPU_FTR_POWER9_DD2_1;
+       else if ((version & 0xffffefff) == 0x004e0201)
+               cur_cpu_spec->cpu_features |= CPU_FTR_POWER9_DD2_1;
 }
 
 static void __init cpufeatures_setup_finished(void)