• Michael Ellerman's avatar
    powerpc/pseries: Fix IBM_ARCH_VEC_NRCORES_OFFSET since POWER8NVL was added · 7c630ac4
    Michael Ellerman authored
    [ Upstream commit 2c2a63e3 ]
    
    The recent commit 7cc85103 ("powerpc/pseries: Add POWER8NVL support
    to ibm,client-architecture-support call") added a new PVR mask & value
    to the start of the ibm_architecture_vec[] array.
    
    However it missed the fact that further down in the array, we hard code
    the offset of one of the fields, and then at boot use that value to
    patch the value in the array. This means every update to the array must
    also update the #define, ugh.
    
    This means that on pseries machines we will misreport to firmware the
    number of cores we support, by a factor of threads_per_core.
    
    Fix it for now by updating the #define.
    
    Fixes: 7cc85103 ("powerpc/pseries: Add POWER8NVL support to ibm,client-architecture-support call")
    Cc: stable@vger.kernel.org # v4.0+
    Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
    Signed-off-by: default avatarSasha Levin <sasha.levin@oracle.com>
    7c630ac4
prom_init.c 76.2 KB