qapi/char: Make backend types properly conditional
[qemu/kevin.git] / linux-user / loongarch64 / target_syscall.h
blob8b5de5212435606fc1069ffcc0c49b9509a0660e
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3 * Copyright (c) 2021 Loongson Technology Corporation Limited
4 */
6 #ifndef LOONGARCH_TARGET_SYSCALL_H
7 #define LOONGARCH_TARGET_SYSCALL_H
9 #include "qemu/units.h"
12 * this struct defines the way the registers are stored on the
13 * stack during a system call.
16 struct target_pt_regs {
17 /* Saved main processor registers. */
18 target_ulong regs[32];
20 /* Saved special registers. */
21 struct {
22 target_ulong era;
23 target_ulong badv;
24 target_ulong crmd;
25 target_ulong prmd;
26 target_ulong euen;
27 target_ulong ecfg;
28 target_ulong estat;
29 } csr;
30 target_ulong orig_a0;
31 target_ulong __last[0];
34 #define UNAME_MACHINE "loongarch64"
35 #define UNAME_MINIMUM_RELEASE "5.19.0"
37 #define TARGET_MCL_CURRENT 1
38 #define TARGET_MCL_FUTURE 2
39 #define TARGET_MCL_ONFAULT 4
41 #define TARGET_FORCE_SHMLBA
43 static inline abi_ulong target_shmlba(CPULoongArchState *env)
45 return 64 * KiB;
48 #endif