@@ -117,6 +117,7 @@ static __always_inline char *u64_to_hex(char *dest, u64 val)
117
117
118
118
static notrace void s390_handle_damage (void )
119
119
{
120
+ struct lowcore * lc = get_lowcore ();
120
121
union ctlreg0 cr0 , cr0_new ;
121
122
char message [100 ];
122
123
psw_t psw_save ;
@@ -125,7 +126,7 @@ static notrace void s390_handle_damage(void)
125
126
smp_emergency_stop ();
126
127
diag_amode31_ops .diag308_reset ();
127
128
ptr = nmi_puts (message , "System stopped due to unrecoverable machine check, code: 0x" );
128
- u64_to_hex (ptr , get_lowcore () -> mcck_interruption_code );
129
+ u64_to_hex (ptr , lc -> mcck_interruption_code );
129
130
130
131
/*
131
132
* Disable low address protection and make machine check new PSW a
@@ -135,17 +136,17 @@ static notrace void s390_handle_damage(void)
135
136
cr0_new = cr0 ;
136
137
cr0_new .lap = 0 ;
137
138
local_ctl_load (0 , & cr0_new .reg );
138
- psw_save = get_lowcore () -> mcck_new_psw ;
139
- psw_bits (get_lowcore () -> mcck_new_psw ).io = 0 ;
140
- psw_bits (get_lowcore () -> mcck_new_psw ).ext = 0 ;
141
- psw_bits (get_lowcore () -> mcck_new_psw ).wait = 1 ;
139
+ psw_save = lc -> mcck_new_psw ;
140
+ psw_bits (lc -> mcck_new_psw ).io = 0 ;
141
+ psw_bits (lc -> mcck_new_psw ).ext = 0 ;
142
+ psw_bits (lc -> mcck_new_psw ).wait = 1 ;
142
143
sclp_emergency_printk (message );
143
144
144
145
/*
145
146
* Restore machine check new PSW and control register 0 to original
146
147
* values. This makes possible system dump analysis easier.
147
148
*/
148
- get_lowcore () -> mcck_new_psw = psw_save ;
149
+ lc -> mcck_new_psw = psw_save ;
149
150
local_ctl_load (0 , & cr0 .reg );
150
151
disabled_wait ();
151
152
while (1 );
@@ -301,6 +302,7 @@ void notrace s390_do_machine_check(struct pt_regs *regs)
301
302
static int ipd_count ;
302
303
static DEFINE_SPINLOCK (ipd_lock );
303
304
static unsigned long long last_ipd ;
305
+ struct lowcore * lc = get_lowcore ();
304
306
struct mcck_struct * mcck ;
305
307
unsigned long long tmp ;
306
308
irqentry_state_t irq_state ;
@@ -313,7 +315,7 @@ void notrace s390_do_machine_check(struct pt_regs *regs)
313
315
if (user_mode (regs ))
314
316
update_timer_mcck ();
315
317
inc_irq_stat (NMI_NMI );
316
- mci .val = get_lowcore () -> mcck_interruption_code ;
318
+ mci .val = lc -> mcck_interruption_code ;
317
319
mcck = this_cpu_ptr (& cpu_mcck );
318
320
319
321
/*
@@ -381,9 +383,9 @@ void notrace s390_do_machine_check(struct pt_regs *regs)
381
383
}
382
384
if (mci .ed && mci .ec ) {
383
385
/* External damage */
384
- if (get_lowcore () -> external_damage_code & (1U << ED_STP_SYNC ))
386
+ if (lc -> external_damage_code & (1U << ED_STP_SYNC ))
385
387
mcck -> stp_queue |= stp_sync_check ();
386
- if (get_lowcore () -> external_damage_code & (1U << ED_STP_ISLAND ))
388
+ if (lc -> external_damage_code & (1U << ED_STP_ISLAND ))
387
389
mcck -> stp_queue |= stp_island_check ();
388
390
mcck_pending = 1 ;
389
391
}
0 commit comments