2 * S/390 misc helper routines
4 * Copyright (c) 2009 Ulrich Hecht
5 * Copyright (c) 2009 Alexander Graf
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Lesser General Public License for more details.
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, see <http://www.gnu.org/licenses/>.
21 #include "qemu/osdep.h"
22 #include "qemu/cutils.h"
24 #include "s390x-internal.h"
25 #include "qemu/host-utils.h"
26 #include "exec/helper-proto.h"
27 #include "qemu/timer.h"
28 #include "exec/exec-all.h"
29 #include "exec/cpu_ldst.h"
30 #include "qapi/error.h"
31 #include "tcg_s390x.h"
34 #if !defined(CONFIG_USER_ONLY)
35 #include "sysemu/cpus.h"
36 #include "sysemu/sysemu.h"
37 #include "hw/s390x/ebcdic.h"
38 #include "hw/s390x/s390-virtio-hcall.h"
39 #include "hw/s390x/sclp.h"
40 #include "hw/s390x/s390_flic.h"
41 #include "hw/s390x/ioinst.h"
42 #include "hw/s390x/s390-pci-inst.h"
43 #include "hw/boards.h"
44 #include "hw/s390x/tod.h"
47 /* #define DEBUG_HELPER */
49 #define HELPER_LOG(x...) qemu_log(x)
51 #define HELPER_LOG(x...)
54 /* Raise an exception statically from a TB. */
55 void HELPER(exception
)(CPUS390XState
*env
, uint32_t excp
)
57 CPUState
*cs
= env_cpu(env
);
59 HELPER_LOG("%s: exception %d\n", __func__
, excp
);
60 cs
->exception_index
= excp
;
64 /* Store CPU Timer (also used for EXTRACT CPU TIME) */
65 uint64_t HELPER(stpt
)(CPUS390XState
*env
)
67 #if defined(CONFIG_USER_ONLY)
69 * Fake a descending CPU timer. We could get negative values here,
70 * but we don't care as it is up to the OS when to process that
71 * interrupt and reset to > 0.
73 return UINT64_MAX
- (uint64_t)cpu_get_host_ticks();
75 return time2tod(env
->cputm
- qemu_clock_get_ns(QEMU_CLOCK_VIRTUAL
));
80 uint64_t HELPER(stck
)(CPUS390XState
*env
)
82 #ifdef CONFIG_USER_ONLY
86 clock_gettime(CLOCK_REALTIME
, &ts
);
87 ns
= ts
.tv_sec
* NANOSECONDS_PER_SECOND
+ ts
.tv_nsec
;
89 return TOD_UNIX_EPOCH
+ time2tod(ns
);
91 S390TODState
*td
= s390_get_todstate();
92 S390TODClass
*tdc
= S390_TOD_GET_CLASS(td
);
95 tdc
->get(td
, &tod
, &error_abort
);
100 #ifndef CONFIG_USER_ONLY
101 /* SCLP service call */
102 uint32_t HELPER(servc
)(CPUS390XState
*env
, uint64_t r1
, uint64_t r2
)
105 int r
= sclp_service_call(env_archcpu(env
), r1
, r2
);
108 tcg_s390_program_interrupt(env
, -r
, GETPC());
113 void HELPER(diag
)(CPUS390XState
*env
, uint32_t r1
, uint32_t r3
, uint32_t num
)
121 r
= s390_virtio_hypercall(env
);
131 handle_diag_308(env
, r1
, r3
, GETPC());
136 /* time bomb (watchdog) */
137 r
= handle_diag_288(env
, r1
, r3
);
145 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, GETPC());
150 void HELPER(spx
)(CPUS390XState
*env
, uint64_t a1
)
152 const uint32_t prefix
= a1
& 0x7fffe000;
153 const uint32_t old_prefix
= env
->psa
;
154 CPUState
*cs
= env_cpu(env
);
156 if (prefix
== old_prefix
) {
160 * Since prefix got aligned to 8k and memory increments are a multiple of
161 * 8k checking the first page is sufficient
163 if (!mmu_absolute_addr_valid(prefix
, true)) {
164 tcg_s390_program_interrupt(env
, PGM_ADDRESSING
, GETPC());
168 HELPER_LOG("prefix: %#x\n", prefix
);
169 tlb_flush_page(cs
, 0);
170 tlb_flush_page(cs
, TARGET_PAGE_SIZE
);
172 tlb_flush_page(cs
, prefix
);
173 tlb_flush_page(cs
, prefix
+ TARGET_PAGE_SIZE
);
175 if (old_prefix
!= 0) {
176 tlb_flush_page(cs
, old_prefix
);
177 tlb_flush_page(cs
, old_prefix
+ TARGET_PAGE_SIZE
);
181 static void update_ckc_timer(CPUS390XState
*env
)
183 S390TODState
*td
= s390_get_todstate();
186 /* stop the timer and remove pending CKC IRQs */
187 timer_del(env
->tod_timer
);
188 g_assert(bql_locked());
189 env
->pending_int
&= ~INTERRUPT_EXT_CLOCK_COMPARATOR
;
191 /* the tod has to exceed the ckc, this can never happen if ckc is all 1's */
192 if (env
->ckc
== -1ULL) {
196 /* difference between origins */
197 time
= env
->ckc
- td
->base
.low
;
200 time
= tod2time(time
);
202 timer_mod(env
->tod_timer
, time
);
205 /* Set Clock Comparator */
206 void HELPER(sckc
)(CPUS390XState
*env
, uint64_t ckc
)
211 update_ckc_timer(env
);
215 void tcg_s390_tod_updated(CPUState
*cs
, run_on_cpu_data opaque
)
217 update_ckc_timer(cpu_env(cs
));
221 uint32_t HELPER(sck
)(CPUS390XState
*env
, uint64_t tod_low
)
223 S390TODState
*td
= s390_get_todstate();
224 S390TODClass
*tdc
= S390_TOD_GET_CLASS(td
);
231 tdc
->set(td
, &tod
, &error_abort
);
236 /* Set Tod Programmable Field */
237 void HELPER(sckpf
)(CPUS390XState
*env
, uint64_t r0
)
241 if (val
& 0xffff0000) {
242 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, GETPC());
247 /* Store Clock Comparator */
248 uint64_t HELPER(stckc
)(CPUS390XState
*env
)
254 void HELPER(spt
)(CPUS390XState
*env
, uint64_t time
)
261 time
= tod2time(time
);
263 env
->cputm
= qemu_clock_get_ns(QEMU_CLOCK_VIRTUAL
) + time
;
265 timer_mod(env
->cpu_timer
, env
->cputm
);
268 /* Store System Information */
269 uint32_t HELPER(stsi
)(CPUS390XState
*env
, uint64_t a0
, uint64_t r0
, uint64_t r1
)
271 const uintptr_t ra
= GETPC();
272 const uint32_t sel1
= r0
& STSI_R0_SEL1_MASK
;
273 const uint32_t sel2
= r1
& STSI_R1_SEL2_MASK
;
274 const MachineState
*ms
= MACHINE(qdev_get_machine());
275 uint16_t total_cpus
= 0, conf_cpus
= 0, reserved_cpus
= 0;
276 S390CPU
*cpu
= env_archcpu(env
);
280 if ((r0
& STSI_R0_FC_MASK
) > STSI_R0_FC_LEVEL_3
) {
281 /* invalid function code: no other checks are performed */
285 if ((r0
& STSI_R0_RESERVED_MASK
) || (r1
& STSI_R1_RESERVED_MASK
)) {
286 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, ra
);
289 if ((r0
& STSI_R0_FC_MASK
) == STSI_R0_FC_CURRENT
) {
290 /* query the current level: no further checks are performed */
291 env
->regs
[0] = STSI_R0_FC_LEVEL_3
;
295 if (a0
& ~TARGET_PAGE_MASK
) {
296 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, ra
);
299 /* count the cpus and split them into configured and reserved ones */
300 for (i
= 0; i
< ms
->possible_cpus
->len
; i
++) {
302 if (ms
->possible_cpus
->cpus
[i
].cpu
) {
310 * In theory, we could report Level 1 / Level 2 as current. However,
311 * the Linux kernel will detect this as running under LPAR and assume
312 * that we have a sclp linemode console (which is always present on
313 * LPAR, but not the default for QEMU), therefore not displaying boot
314 * messages and making booting a Linux kernel under TCG harder.
316 * For now we fake the same SMP configuration on all levels.
318 * TODO: We could later make the level configurable via the machine
319 * and change defaults (linemode console) based on machine type
322 switch (r0
& STSI_R0_FC_MASK
) {
323 case STSI_R0_FC_LEVEL_1
:
324 if ((sel1
== 1) && (sel2
== 1)) {
325 /* Basic Machine Configuration */
328 ebcdic_put(sysib
.sysib_111
.manuf
, "QEMU ", 16);
329 /* same as machine type number in STORE CPU ID, but in EBCDIC */
330 snprintf(type
, ARRAY_SIZE(type
), "%X", cpu
->model
->def
->type
);
331 ebcdic_put(sysib
.sysib_111
.type
, type
, 4);
332 /* model number (not stored in STORE CPU ID for z/Architecture) */
333 ebcdic_put(sysib
.sysib_111
.model
, "QEMU ", 16);
334 ebcdic_put(sysib
.sysib_111
.sequence
, "QEMU ", 16);
335 ebcdic_put(sysib
.sysib_111
.plant
, "QEMU", 4);
336 } else if ((sel1
== 2) && (sel2
== 1)) {
337 /* Basic Machine CPU */
338 ebcdic_put(sysib
.sysib_121
.sequence
, "QEMUQEMUQEMUQEMU", 16);
339 ebcdic_put(sysib
.sysib_121
.plant
, "QEMU", 4);
340 sysib
.sysib_121
.cpu_addr
= cpu_to_be16(env
->core_id
);
341 } else if ((sel1
== 2) && (sel2
== 2)) {
342 /* Basic Machine CPUs */
343 sysib
.sysib_122
.capability
= cpu_to_be32(0x443afc29);
344 sysib
.sysib_122
.total_cpus
= cpu_to_be16(total_cpus
);
345 sysib
.sysib_122
.conf_cpus
= cpu_to_be16(conf_cpus
);
346 sysib
.sysib_122
.reserved_cpus
= cpu_to_be16(reserved_cpus
);
351 case STSI_R0_FC_LEVEL_2
:
352 if ((sel1
== 2) && (sel2
== 1)) {
354 ebcdic_put(sysib
.sysib_221
.sequence
, "QEMUQEMUQEMUQEMU", 16);
355 ebcdic_put(sysib
.sysib_221
.plant
, "QEMU", 4);
356 sysib
.sysib_221
.cpu_addr
= cpu_to_be16(env
->core_id
);
357 } else if ((sel1
== 2) && (sel2
== 2)) {
359 sysib
.sysib_222
.lcpuc
= 0x80; /* dedicated */
360 sysib
.sysib_222
.total_cpus
= cpu_to_be16(total_cpus
);
361 sysib
.sysib_222
.conf_cpus
= cpu_to_be16(conf_cpus
);
362 sysib
.sysib_222
.reserved_cpus
= cpu_to_be16(reserved_cpus
);
363 ebcdic_put(sysib
.sysib_222
.name
, "QEMU ", 8);
364 sysib
.sysib_222
.caf
= cpu_to_be32(1000);
365 sysib
.sysib_222
.dedicated_cpus
= cpu_to_be16(conf_cpus
);
370 case STSI_R0_FC_LEVEL_3
:
371 if ((sel1
== 2) && (sel2
== 2)) {
373 sysib
.sysib_322
.count
= 1;
374 sysib
.sysib_322
.vm
[0].total_cpus
= cpu_to_be16(total_cpus
);
375 sysib
.sysib_322
.vm
[0].conf_cpus
= cpu_to_be16(conf_cpus
);
376 sysib
.sysib_322
.vm
[0].reserved_cpus
= cpu_to_be16(reserved_cpus
);
377 sysib
.sysib_322
.vm
[0].caf
= cpu_to_be32(1000);
378 /* Linux kernel uses this to distinguish us from z/VM */
379 ebcdic_put(sysib
.sysib_322
.vm
[0].cpi
, "KVM/Linux ", 16);
380 sysib
.sysib_322
.vm
[0].ext_name_encoding
= 2; /* UTF-8 */
382 /* If our VM has a name, use the real name */
384 memset(sysib
.sysib_322
.vm
[0].name
, 0x40,
385 sizeof(sysib
.sysib_322
.vm
[0].name
));
386 ebcdic_put(sysib
.sysib_322
.vm
[0].name
, qemu_name
,
387 MIN(sizeof(sysib
.sysib_322
.vm
[0].name
),
389 strpadcpy((char *)sysib
.sysib_322
.ext_names
[0],
390 sizeof(sysib
.sysib_322
.ext_names
[0]),
394 ebcdic_put(sysib
.sysib_322
.vm
[0].name
, "TCGguest", 8);
395 strcpy((char *)sysib
.sysib_322
.ext_names
[0], "TCGguest");
399 memcpy(sysib
.sysib_322
.vm
[0].uuid
, &qemu_uuid
,
400 sizeof(sysib
.sysib_322
.vm
[0].uuid
));
408 if (s390_cpu_virt_mem_write(cpu
, a0
, 0, &sysib
, sizeof(sysib
))) {
409 s390_cpu_virt_mem_handle_exc(cpu
, ra
);
416 uint32_t HELPER(sigp
)(CPUS390XState
*env
, uint64_t order_code
, uint32_t r1
,
421 /* TODO: needed to inject interrupts - push further down */
423 cc
= handle_sigp(env
, order_code
& SIGP_ORDER_MASK
, r1
, r3
);
430 #ifndef CONFIG_USER_ONLY
431 void HELPER(xsch
)(CPUS390XState
*env
, uint64_t r1
)
433 S390CPU
*cpu
= env_archcpu(env
);
435 ioinst_handle_xsch(cpu
, r1
, GETPC());
439 void HELPER(csch
)(CPUS390XState
*env
, uint64_t r1
)
441 S390CPU
*cpu
= env_archcpu(env
);
443 ioinst_handle_csch(cpu
, r1
, GETPC());
447 void HELPER(hsch
)(CPUS390XState
*env
, uint64_t r1
)
449 S390CPU
*cpu
= env_archcpu(env
);
451 ioinst_handle_hsch(cpu
, r1
, GETPC());
455 void HELPER(msch
)(CPUS390XState
*env
, uint64_t r1
, uint64_t inst
)
457 S390CPU
*cpu
= env_archcpu(env
);
459 ioinst_handle_msch(cpu
, r1
, inst
>> 16, GETPC());
463 void HELPER(rchp
)(CPUS390XState
*env
, uint64_t r1
)
465 S390CPU
*cpu
= env_archcpu(env
);
467 ioinst_handle_rchp(cpu
, r1
, GETPC());
471 void HELPER(rsch
)(CPUS390XState
*env
, uint64_t r1
)
473 S390CPU
*cpu
= env_archcpu(env
);
475 ioinst_handle_rsch(cpu
, r1
, GETPC());
479 void HELPER(sal
)(CPUS390XState
*env
, uint64_t r1
)
481 S390CPU
*cpu
= env_archcpu(env
);
484 ioinst_handle_sal(cpu
, r1
, GETPC());
488 void HELPER(schm
)(CPUS390XState
*env
, uint64_t r1
, uint64_t r2
, uint64_t inst
)
490 S390CPU
*cpu
= env_archcpu(env
);
493 ioinst_handle_schm(cpu
, r1
, r2
, inst
>> 16, GETPC());
497 void HELPER(ssch
)(CPUS390XState
*env
, uint64_t r1
, uint64_t inst
)
499 S390CPU
*cpu
= env_archcpu(env
);
501 ioinst_handle_ssch(cpu
, r1
, inst
>> 16, GETPC());
505 void HELPER(stcrw
)(CPUS390XState
*env
, uint64_t inst
)
507 S390CPU
*cpu
= env_archcpu(env
);
510 ioinst_handle_stcrw(cpu
, inst
>> 16, GETPC());
514 void HELPER(stsch
)(CPUS390XState
*env
, uint64_t r1
, uint64_t inst
)
516 S390CPU
*cpu
= env_archcpu(env
);
518 ioinst_handle_stsch(cpu
, r1
, inst
>> 16, GETPC());
522 uint32_t HELPER(tpi
)(CPUS390XState
*env
, uint64_t addr
)
524 const uintptr_t ra
= GETPC();
525 S390CPU
*cpu
= env_archcpu(env
);
526 QEMUS390FLICState
*flic
= s390_get_qemu_flic(s390_get_flic());
527 QEMUS390FlicIO
*io
= NULL
;
531 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, ra
);
535 io
= qemu_s390_flic_dequeue_io(flic
, env
->cregs
[6]);
547 .id
= cpu_to_be16(io
->id
),
548 .nr
= cpu_to_be16(io
->nr
),
549 .parm
= cpu_to_be32(io
->parm
),
552 if (s390_cpu_virt_mem_write(cpu
, addr
, 0, &intc
, sizeof(intc
))) {
553 /* writing failed, reinject and properly clean up */
554 s390_io_interrupt(io
->id
, io
->nr
, io
->parm
, io
->word
);
557 s390_cpu_virt_mem_handle_exc(cpu
, ra
);
561 /* no protection applies */
562 lowcore
= cpu_map_lowcore(env
);
563 lowcore
->subchannel_id
= cpu_to_be16(io
->id
);
564 lowcore
->subchannel_nr
= cpu_to_be16(io
->nr
);
565 lowcore
->io_int_parm
= cpu_to_be32(io
->parm
);
566 lowcore
->io_int_word
= cpu_to_be32(io
->word
);
567 cpu_unmap_lowcore(lowcore
);
575 void HELPER(tsch
)(CPUS390XState
*env
, uint64_t r1
, uint64_t inst
)
577 S390CPU
*cpu
= env_archcpu(env
);
579 ioinst_handle_tsch(cpu
, r1
, inst
>> 16, GETPC());
583 void HELPER(chsc
)(CPUS390XState
*env
, uint64_t inst
)
585 S390CPU
*cpu
= env_archcpu(env
);
587 ioinst_handle_chsc(cpu
, inst
>> 16, GETPC());
592 #ifndef CONFIG_USER_ONLY
593 void HELPER(per_check_exception
)(CPUS390XState
*env
)
595 if (env
->per_perc_atmid
) {
596 tcg_s390_program_interrupt(env
, PGM_PER
, GETPC());
600 /* Check if an address is within the PER starting address and the PER
601 ending address. The address range might loop. */
602 static inline bool get_per_in_range(CPUS390XState
*env
, uint64_t addr
)
604 if (env
->cregs
[10] <= env
->cregs
[11]) {
605 return env
->cregs
[10] <= addr
&& addr
<= env
->cregs
[11];
607 return env
->cregs
[10] <= addr
|| addr
<= env
->cregs
[11];
611 void HELPER(per_branch
)(CPUS390XState
*env
, uint64_t from
, uint64_t to
)
613 if ((env
->cregs
[9] & PER_CR9_EVENT_BRANCH
)) {
614 if (!(env
->cregs
[9] & PER_CR9_CONTROL_BRANCH_ADDRESS
)
615 || get_per_in_range(env
, to
)) {
616 env
->per_address
= from
;
617 env
->per_perc_atmid
= PER_CODE_EVENT_BRANCH
| get_per_atmid(env
);
622 void HELPER(per_ifetch
)(CPUS390XState
*env
, uint64_t addr
)
624 if ((env
->cregs
[9] & PER_CR9_EVENT_IFETCH
) && get_per_in_range(env
, addr
)) {
625 env
->per_address
= addr
;
626 env
->per_perc_atmid
= PER_CODE_EVENT_IFETCH
| get_per_atmid(env
);
628 /* If the instruction has to be nullified, trigger the
629 exception immediately. */
630 if (env
->cregs
[9] & PER_CR9_EVENT_NULLIFICATION
) {
631 CPUState
*cs
= env_cpu(env
);
633 env
->per_perc_atmid
|= PER_CODE_EVENT_NULLIFICATION
;
634 env
->int_pgm_code
= PGM_PER
;
635 env
->int_pgm_ilen
= get_ilen(cpu_ldub_code(env
, addr
));
637 cs
->exception_index
= EXCP_PGM
;
643 void HELPER(per_store_real
)(CPUS390XState
*env
)
645 if ((env
->cregs
[9] & PER_CR9_EVENT_STORE
) &&
646 (env
->cregs
[9] & PER_CR9_EVENT_STORE_REAL
)) {
647 /* PSW is saved just before calling the helper. */
648 env
->per_address
= env
->psw
.addr
;
649 env
->per_perc_atmid
= PER_CODE_EVENT_STORE_REAL
| get_per_atmid(env
);
654 static uint8_t stfl_bytes
[2048];
655 static unsigned int used_stfl_bytes
;
657 static void prepare_stfl(void)
659 static bool initialized
;
662 /* racy, but we don't care, the same values are always written */
667 s390_get_feat_block(S390_FEAT_TYPE_STFL
, stfl_bytes
);
668 for (i
= 0; i
< sizeof(stfl_bytes
); i
++) {
670 used_stfl_bytes
= i
+ 1;
676 #ifndef CONFIG_USER_ONLY
677 void HELPER(stfl
)(CPUS390XState
*env
)
681 lowcore
= cpu_map_lowcore(env
);
683 memcpy(&lowcore
->stfl_fac_list
, stfl_bytes
, sizeof(lowcore
->stfl_fac_list
));
684 cpu_unmap_lowcore(lowcore
);
688 uint32_t HELPER(stfle
)(CPUS390XState
*env
, uint64_t addr
)
690 const uintptr_t ra
= GETPC();
691 const int count_bytes
= ((env
->regs
[0] & 0xff) + 1) * 8;
696 tcg_s390_program_interrupt(env
, PGM_SPECIFICATION
, ra
);
700 max_bytes
= ROUND_UP(used_stfl_bytes
, 8);
703 * The PoP says that doublewords beyond the highest-numbered facility
704 * bit may or may not be stored. However, existing hardware appears to
705 * not store the words, and existing software depend on that.
707 for (i
= 0; i
< MIN(count_bytes
, max_bytes
); ++i
) {
708 cpu_stb_data_ra(env
, addr
+ i
, stfl_bytes
[i
], ra
);
711 env
->regs
[0] = deposit64(env
->regs
[0], 0, 8, (max_bytes
/ 8) - 1);
712 return count_bytes
>= max_bytes
? 0 : 3;
715 #ifndef CONFIG_USER_ONLY
717 * Note: we ignore any return code of the functions called for the pci
718 * instructions, as the only time they return !0 is when the stub is
719 * called, and in that case we didn't even offer the zpci facility.
720 * The only exception is SIC, where program checks need to be handled
723 void HELPER(clp
)(CPUS390XState
*env
, uint32_t r2
)
725 S390CPU
*cpu
= env_archcpu(env
);
728 clp_service_call(cpu
, r2
, GETPC());
732 void HELPER(pcilg
)(CPUS390XState
*env
, uint32_t r1
, uint32_t r2
)
734 S390CPU
*cpu
= env_archcpu(env
);
737 pcilg_service_call(cpu
, r1
, r2
, GETPC());
741 void HELPER(pcistg
)(CPUS390XState
*env
, uint32_t r1
, uint32_t r2
)
743 S390CPU
*cpu
= env_archcpu(env
);
746 pcistg_service_call(cpu
, r1
, r2
, GETPC());
750 void HELPER(stpcifc
)(CPUS390XState
*env
, uint32_t r1
, uint64_t fiba
,
753 S390CPU
*cpu
= env_archcpu(env
);
756 stpcifc_service_call(cpu
, r1
, fiba
, ar
, GETPC());
760 void HELPER(sic
)(CPUS390XState
*env
, uint64_t r1
, uint64_t r3
)
762 S390CPU
*cpu
= env_archcpu(env
);
766 r
= css_do_sic(cpu
, (r3
>> 27) & 0x7, r1
& 0xffff);
768 /* css_do_sic() may actually return a PGM_xxx value to inject */
770 tcg_s390_program_interrupt(env
, -r
, GETPC());
774 void HELPER(rpcit
)(CPUS390XState
*env
, uint32_t r1
, uint32_t r2
)
776 S390CPU
*cpu
= env_archcpu(env
);
779 rpcit_service_call(cpu
, r1
, r2
, GETPC());
783 void HELPER(pcistb
)(CPUS390XState
*env
, uint32_t r1
, uint32_t r3
,
784 uint64_t gaddr
, uint32_t ar
)
786 S390CPU
*cpu
= env_archcpu(env
);
789 pcistb_service_call(cpu
, r1
, r3
, gaddr
, ar
, GETPC());
793 void HELPER(mpcifc
)(CPUS390XState
*env
, uint32_t r1
, uint64_t fiba
,
796 S390CPU
*cpu
= env_archcpu(env
);
799 mpcifc_service_call(cpu
, r1
, fiba
, ar
, GETPC());