• Heiko Carstens's avatar
    s390/nmi: consistently enable machine checks in trap_init() · 84e599e3
    Heiko Carstens authored
    The kernel starts with machine checks disabled (machine check mask bit in
    the PSW is zero), and machine checks are enabled when trap_init() is
    called. The rationale is that this allows to assume that the system is
    initialized up to a certain point before the machine check handler may be
    invoked.
    
    However the implementation is incomplete: all new PSW masks in lowcore have
    the machine check mask bit. This means that e.g. for any early program
    check machine checks are enabled within the program check handler. This
    contradicts the whole point of enabling machine checks at a single place.
    
    Change this and initialize all new PSWs in lowcore so they have the machine
    check mask bit not set. Set the bit in all masks in trap_init(). This way
    machine check enabling is consistent.
    Reviewed-by: default avatarAlexander Gordeev <agordeev@linux.ibm.com>
    Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
    Signed-off-by: default avatarAlexander Gordeev <agordeev@linux.ibm.com>
    84e599e3
traps.c 10.8 KB