1*a1465c8bSIlya Leoshkevich/* 2*a1465c8bSIlya Leoshkevich * Test early exception recognition using EXRL + SSM. 3*a1465c8bSIlya Leoshkevich * 4*a1465c8bSIlya Leoshkevich * SPDX-License-Identifier: GPL-2.0-or-later 5*a1465c8bSIlya Leoshkevich */ 6*a1465c8bSIlya Leoshkevich .org 0x8d 7*a1465c8bSIlya Leoshkevichilc: 8*a1465c8bSIlya Leoshkevich .org 0x8e 9*a1465c8bSIlya Leoshkevichprogram_interruption_code: 10*a1465c8bSIlya Leoshkevich .org 0x150 11*a1465c8bSIlya Leoshkevichprogram_old_psw: 12*a1465c8bSIlya Leoshkevich .org 0x1D0 /* program new PSW */ 13*a1465c8bSIlya Leoshkevich .quad 0,pgm 14*a1465c8bSIlya Leoshkevich .org 0x200 /* lowcore padding */ 15*a1465c8bSIlya Leoshkevich 16*a1465c8bSIlya Leoshkevich .globl _start 17*a1465c8bSIlya Leoshkevich_start: 18*a1465c8bSIlya Leoshkevich exrl %r0,ssm 19*a1465c8bSIlya Leoshkevichexpected_pswa: 20*a1465c8bSIlya Leoshkevich j failure 21*a1465c8bSIlya Leoshkevichssm: 22*a1465c8bSIlya Leoshkevich ssm ssm_op 23*a1465c8bSIlya Leoshkevich 24*a1465c8bSIlya Leoshkevichpgm: 25*a1465c8bSIlya Leoshkevich chhsi program_interruption_code,0x6 /* specification exception? */ 26*a1465c8bSIlya Leoshkevich jne failure 27*a1465c8bSIlya Leoshkevich cli ilc,6 /* ilc for EXRL? */ 28*a1465c8bSIlya Leoshkevich jne failure 29*a1465c8bSIlya Leoshkevich clc program_old_psw(16),expected_old_psw /* correct old PSW? */ 30*a1465c8bSIlya Leoshkevich jne failure 31*a1465c8bSIlya Leoshkevich lpswe success_psw 32*a1465c8bSIlya Leoshkevichfailure: 33*a1465c8bSIlya Leoshkevich lpswe failure_psw 34*a1465c8bSIlya Leoshkevich 35*a1465c8bSIlya Leoshkevichssm_op: 36*a1465c8bSIlya Leoshkevich .byte 0x08 /* bit 4 set */ 37*a1465c8bSIlya Leoshkevich .align 8 38*a1465c8bSIlya Leoshkevichexpected_old_psw: 39*a1465c8bSIlya Leoshkevich .quad 0x0800000180000000,expected_pswa /* bit 2 set */ 40*a1465c8bSIlya Leoshkevichsuccess_psw: 41*a1465c8bSIlya Leoshkevich .quad 0x2000000000000,0xfff /* see is_special_wait_psw() */ 42*a1465c8bSIlya Leoshkevichfailure_psw: 43*a1465c8bSIlya Leoshkevich .quad 0x2000000000000,0 /* disabled wait */ 44