s390/facilities: cleanup PFMF and HPAGE machine facility detection
MACHINE_HAS_PFMF and MACHINE_HAS_HPAGE actually have the same semantics: the cpu has the EDAT1 facility installed in zArch mode. So remove one of the feature flags in machine_flags and rename the other one to EDAT1. The two old macros simply get mapped to MACHINE_HAS_EDAT1. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
9e2d8656f5
commit
3c7ef08bba
|
@ -75,8 +75,7 @@ extern unsigned int s390_user_mode;
|
|||
#define MACHINE_FLAG_DIAG9C (1UL << 7)
|
||||
#define MACHINE_FLAG_MVCOS (1UL << 8)
|
||||
#define MACHINE_FLAG_KVM (1UL << 9)
|
||||
#define MACHINE_FLAG_HPAGE (1UL << 10)
|
||||
#define MACHINE_FLAG_PFMF (1UL << 11)
|
||||
#define MACHINE_FLAG_EDAT1 (1UL << 10)
|
||||
#define MACHINE_FLAG_LPAR (1UL << 12)
|
||||
#define MACHINE_FLAG_SPP (1UL << 13)
|
||||
#define MACHINE_FLAG_TOPOLOGY (1UL << 14)
|
||||
|
@ -88,6 +87,8 @@ extern unsigned int s390_user_mode;
|
|||
#define MACHINE_IS_LPAR (S390_lowcore.machine_flags & MACHINE_FLAG_LPAR)
|
||||
|
||||
#define MACHINE_HAS_DIAG9C (S390_lowcore.machine_flags & MACHINE_FLAG_DIAG9C)
|
||||
#define MACHINE_HAS_PFMF MACHINE_HAS_EDAT1
|
||||
#define MACHINE_HAS_HPAGE MACHINE_HAS_EDAT1
|
||||
|
||||
#ifndef CONFIG_64BIT
|
||||
#define MACHINE_HAS_IEEE (S390_lowcore.machine_flags & MACHINE_FLAG_IEEE)
|
||||
|
@ -96,8 +97,7 @@ extern unsigned int s390_user_mode;
|
|||
#define MACHINE_HAS_DIAG44 (1)
|
||||
#define MACHINE_HAS_MVPG (S390_lowcore.machine_flags & MACHINE_FLAG_MVPG)
|
||||
#define MACHINE_HAS_MVCOS (0)
|
||||
#define MACHINE_HAS_HPAGE (0)
|
||||
#define MACHINE_HAS_PFMF (0)
|
||||
#define MACHINE_HAS_EDAT1 (0)
|
||||
#define MACHINE_HAS_SPP (0)
|
||||
#define MACHINE_HAS_TOPOLOGY (0)
|
||||
#define MACHINE_HAS_TE (0)
|
||||
|
@ -109,8 +109,7 @@ extern unsigned int s390_user_mode;
|
|||
#define MACHINE_HAS_DIAG44 (S390_lowcore.machine_flags & MACHINE_FLAG_DIAG44)
|
||||
#define MACHINE_HAS_MVPG (1)
|
||||
#define MACHINE_HAS_MVCOS (S390_lowcore.machine_flags & MACHINE_FLAG_MVCOS)
|
||||
#define MACHINE_HAS_HPAGE (S390_lowcore.machine_flags & MACHINE_FLAG_HPAGE)
|
||||
#define MACHINE_HAS_PFMF (S390_lowcore.machine_flags & MACHINE_FLAG_PFMF)
|
||||
#define MACHINE_HAS_EDAT1 (S390_lowcore.machine_flags & MACHINE_FLAG_EDAT1)
|
||||
#define MACHINE_HAS_SPP (S390_lowcore.machine_flags & MACHINE_FLAG_SPP)
|
||||
#define MACHINE_HAS_TOPOLOGY (S390_lowcore.machine_flags & MACHINE_FLAG_TOPOLOGY)
|
||||
#define MACHINE_HAS_TE (S390_lowcore.machine_flags & MACHINE_FLAG_TE)
|
||||
|
|
|
@ -283,14 +283,6 @@ static noinline __init void setup_facility_list(void)
|
|||
ARRAY_SIZE(S390_lowcore.stfle_fac_list));
|
||||
}
|
||||
|
||||
static noinline __init void setup_hpage(void)
|
||||
{
|
||||
if (!test_facility(2) || !test_facility(8))
|
||||
return;
|
||||
S390_lowcore.machine_flags |= MACHINE_FLAG_HPAGE;
|
||||
__ctl_set_bit(0, 23);
|
||||
}
|
||||
|
||||
static __init void detect_mvpg(void)
|
||||
{
|
||||
#ifndef CONFIG_64BIT
|
||||
|
@ -378,10 +370,12 @@ static __init void detect_diag44(void)
|
|||
static __init void detect_machine_facilities(void)
|
||||
{
|
||||
#ifdef CONFIG_64BIT
|
||||
if (test_facility(8)) {
|
||||
S390_lowcore.machine_flags |= MACHINE_FLAG_EDAT1;
|
||||
__ctl_set_bit(0, 23);
|
||||
}
|
||||
if (test_facility(3))
|
||||
S390_lowcore.machine_flags |= MACHINE_FLAG_IDTE;
|
||||
if (test_facility(8))
|
||||
S390_lowcore.machine_flags |= MACHINE_FLAG_PFMF;
|
||||
if (test_facility(27))
|
||||
S390_lowcore.machine_flags |= MACHINE_FLAG_MVCOS;
|
||||
if (test_facility(40))
|
||||
|
@ -484,7 +478,6 @@ void __init startup_init(void)
|
|||
detect_diag9c();
|
||||
detect_diag44();
|
||||
detect_machine_facilities();
|
||||
setup_hpage();
|
||||
setup_topology();
|
||||
sclp_facilities_detect();
|
||||
detect_memory_layout(memory_chunk);
|
||||
|
|
Loading…
Reference in New Issue