Commit 01e42849 authored by Nicholas Piggin's avatar Nicholas Piggin Committed by Jialin Zhang
Browse files

powerpc/64s: Fix GENERIC_CPU build flags for PPC970 / G5

stable inclusion
from stable-v5.10.150
commit 2bde4e1e4f017ac6acebab28e6440af9a8c9cc77
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I6D0XA

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=2bde4e1e4f017ac6acebab28e6440af9a8c9cc77



--------------------------------

[ Upstream commit 58ec7f06 ]

Big-endian GENERIC_CPU supports 970, but builds with -mcpu=power5.
POWER5 is ISA v2.02 whereas 970 is v2.01 plus Altivec. 2.02 added
the popcntb instruction which a compiler might use.

Use -mcpu=power4.

Fixes: 471d7ff8 ("powerpc/64s: Remove POWER4 support")
Signed-off-by: default avatarNicholas Piggin <npiggin@gmail.com>
Reviewed-by: default avatarSegher Boessenkool <segher@kernel.crashing.org>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220921014103.587954-1-npiggin@gmail.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarJialin Zhang <zhangjialin11@huawei.com>
parent f8640720
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment