1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 * Copyright (c) 2021 Loongson Technology Corporation Limited
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. */
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
)