Файловый менеджер - Редактировать - /var/www/html/s390.zip
Ðазад
PK ! ��� appldata/Makefilenu �[��� # SPDX-License-Identifier: GPL-2.0 # # Makefile for the Linux - z/VM Monitor Stream. # obj-$(CONFIG_APPLDATA_BASE) += appldata_base.o obj-$(CONFIG_APPLDATA_MEM) += appldata_mem.o obj-$(CONFIG_APPLDATA_OS) += appldata_os.o obj-$(CONFIG_APPLDATA_NET_SUM) += appldata_net_sum.o PK ! ���I I crypto/Makefilenu �[��� # SPDX-License-Identifier: GPL-2.0 # # Cryptographic API # obj-$(CONFIG_CRYPTO_SHA1_S390) += sha1_s390.o sha_common.o obj-$(CONFIG_CRYPTO_SHA256_S390) += sha256_s390.o sha_common.o obj-$(CONFIG_CRYPTO_SHA512_S390) += sha512_s390.o sha_common.o obj-$(CONFIG_CRYPTO_SHA3_256_S390) += sha3_256_s390.o sha_common.o obj-$(CONFIG_CRYPTO_SHA3_512_S390) += sha3_512_s390.o sha_common.o obj-$(CONFIG_CRYPTO_DES_S390) += des_s390.o obj-$(CONFIG_CRYPTO_AES_S390) += aes_s390.o obj-$(CONFIG_CRYPTO_PAES_S390) += paes_s390.o obj-$(CONFIG_CRYPTO_CHACHA_S390) += chacha_s390.o obj-$(CONFIG_S390_PRNG) += prng.o obj-$(CONFIG_CRYPTO_GHASH_S390) += ghash_s390.o obj-$(CONFIG_CRYPTO_CRC32_S390) += crc32-vx_s390.o obj-$(CONFIG_ARCH_RANDOM) += arch_random.o crc32-vx_s390-y := crc32-vx.o crc32le-vx.o crc32be-vx.o chacha_s390-y := chacha-glue.o chacha-s390.o PK ! �<�� � net/Makefilenu �[��� # SPDX-License-Identifier: GPL-2.0 # # Arch-specific network modules # obj-$(CONFIG_BPF_JIT) += bpf_jit_comp.o obj-$(CONFIG_HAVE_PNETID) += pnet.o PK ! ���G� � include/uapi/asm/runtime_instr.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _S390_UAPI_RUNTIME_INSTR_H #define _S390_UAPI_RUNTIME_INSTR_H #include <linux/types.h> #define S390_RUNTIME_INSTR_START 0x1 #define S390_RUNTIME_INSTR_STOP 0x2 struct runtime_instr_cb { __u64 rca; __u64 roa; __u64 rla; __u32 v : 1; __u32 s : 1; __u32 k : 1; __u32 h : 1; __u32 a : 1; __u32 reserved1 : 3; __u32 ps : 1; __u32 qs : 1; __u32 pc : 1; __u32 qc : 1; __u32 reserved2 : 1; __u32 g : 1; __u32 u : 1; __u32 l : 1; __u32 key : 4; __u32 reserved3 : 8; __u32 t : 1; __u32 rgs : 3; __u32 m : 4; __u32 n : 1; __u32 mae : 1; __u32 reserved4 : 2; __u32 c : 1; __u32 r : 1; __u32 b : 1; __u32 j : 1; __u32 e : 1; __u32 x : 1; __u32 reserved5 : 2; __u32 bpxn : 1; __u32 bpxt : 1; __u32 bpti : 1; __u32 bpni : 1; __u32 reserved6 : 2; __u32 d : 1; __u32 f : 1; __u32 ic : 4; __u32 dc : 4; __u64 reserved7; __u64 sf; __u64 rsic; __u64 reserved8; } __attribute__((__packed__, __aligned__(8))); static inline void load_runtime_instr_cb(struct runtime_instr_cb *cb) { asm volatile(".insn rsy,0xeb0000000060,0,0,%0" /* LRIC */ : : "Q" (*cb)); } static inline void store_runtime_instr_cb(struct runtime_instr_cb *cb) { asm volatile(".insn rsy,0xeb0000000061,0,0,%0" /* STRIC */ : "=Q" (*cb) : : "cc"); } #endif /* _S390_UAPI_RUNTIME_INSTR_H */ PK ! ��F F include/uapi/asm/unistd.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * * Derived from "include/asm-i386/unistd.h" */ #ifndef _UAPI_ASM_S390_UNISTD_H_ #define _UAPI_ASM_S390_UNISTD_H_ #ifdef __s390x__ #include <asm/unistd_64.h> #else #include <asm/unistd_32.h> #endif #endif /* _UAPI_ASM_S390_UNISTD_H_ */ PK ! k��$ �$ include/uapi/asm/sie.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _UAPI_ASM_S390_SIE_H #define _UAPI_ASM_S390_SIE_H #define diagnose_codes \ { 0x10, "DIAG (0x10) release pages" }, \ { 0x44, "DIAG (0x44) time slice end" }, \ { 0x9c, "DIAG (0x9c) time slice end directed" }, \ { 0x204, "DIAG (0x204) logical-cpu utilization" }, \ { 0x258, "DIAG (0x258) page-reference services" }, \ { 0x288, "DIAG (0x288) watchdog functions" }, \ { 0x308, "DIAG (0x308) ipl functions" }, \ { 0x500, "DIAG (0x500) KVM virtio functions" }, \ { 0x501, "DIAG (0x501) KVM breakpoint" } #define sigp_order_codes \ { 0x01, "SIGP sense" }, \ { 0x02, "SIGP external call" }, \ { 0x03, "SIGP emergency signal" }, \ { 0x04, "SIGP start" }, \ { 0x05, "SIGP stop" }, \ { 0x06, "SIGP restart" }, \ { 0x09, "SIGP stop and store status" }, \ { 0x0b, "SIGP initial cpu reset" }, \ { 0x0c, "SIGP cpu reset" }, \ { 0x0d, "SIGP set prefix" }, \ { 0x0e, "SIGP store status at address" }, \ { 0x12, "SIGP set architecture" }, \ { 0x13, "SIGP conditional emergency signal" }, \ { 0x15, "SIGP sense running" }, \ { 0x16, "SIGP set multithreading"}, \ { 0x17, "SIGP store additional status at address"} #define icpt_prog_codes \ { 0x0001, "Prog Operation" }, \ { 0x0002, "Prog Privileged Operation" }, \ { 0x0003, "Prog Execute" }, \ { 0x0004, "Prog Protection" }, \ { 0x0005, "Prog Addressing" }, \ { 0x0006, "Prog Specification" }, \ { 0x0007, "Prog Data" }, \ { 0x0008, "Prog Fixedpoint overflow" }, \ { 0x0009, "Prog Fixedpoint divide" }, \ { 0x000A, "Prog Decimal overflow" }, \ { 0x000B, "Prog Decimal divide" }, \ { 0x000C, "Prog HFP exponent overflow" }, \ { 0x000D, "Prog HFP exponent underflow" }, \ { 0x000E, "Prog HFP significance" }, \ { 0x000F, "Prog HFP divide" }, \ { 0x0010, "Prog Segment translation" }, \ { 0x0011, "Prog Page translation" }, \ { 0x0012, "Prog Translation specification" }, \ { 0x0013, "Prog Special operation" }, \ { 0x0015, "Prog Operand" }, \ { 0x0016, "Prog Trace table" }, \ { 0x0017, "Prog ASNtranslation specification" }, \ { 0x001C, "Prog Spaceswitch event" }, \ { 0x001D, "Prog HFP square root" }, \ { 0x001F, "Prog PCtranslation specification" }, \ { 0x0020, "Prog AFX translation" }, \ { 0x0021, "Prog ASX translation" }, \ { 0x0022, "Prog LX translation" }, \ { 0x0023, "Prog EX translation" }, \ { 0x0024, "Prog Primary authority" }, \ { 0x0025, "Prog Secondary authority" }, \ { 0x0026, "Prog LFXtranslation exception" }, \ { 0x0027, "Prog LSXtranslation exception" }, \ { 0x0028, "Prog ALET specification" }, \ { 0x0029, "Prog ALEN translation" }, \ { 0x002A, "Prog ALE sequence" }, \ { 0x002B, "Prog ASTE validity" }, \ { 0x002C, "Prog ASTE sequence" }, \ { 0x002D, "Prog Extended authority" }, \ { 0x002E, "Prog LSTE sequence" }, \ { 0x002F, "Prog ASTE instance" }, \ { 0x0030, "Prog Stack full" }, \ { 0x0031, "Prog Stack empty" }, \ { 0x0032, "Prog Stack specification" }, \ { 0x0033, "Prog Stack type" }, \ { 0x0034, "Prog Stack operation" }, \ { 0x0039, "Prog Region first translation" }, \ { 0x003A, "Prog Region second translation" }, \ { 0x003B, "Prog Region third translation" }, \ { 0x0040, "Prog Monitor event" }, \ { 0x0080, "Prog PER event" }, \ { 0x0119, "Prog Crypto operation" } #define exit_code_ipa0(ipa0, opcode, mnemonic) \ { (ipa0 << 8 | opcode), #ipa0 " " mnemonic } #define exit_code(opcode, mnemonic) \ { opcode, mnemonic } #define icpt_insn_codes \ exit_code_ipa0(0x01, 0x01, "PR"), \ exit_code_ipa0(0x01, 0x04, "PTFF"), \ exit_code_ipa0(0x01, 0x07, "SCKPF"), \ exit_code_ipa0(0xAA, 0x00, "RINEXT"), \ exit_code_ipa0(0xAA, 0x01, "RION"), \ exit_code_ipa0(0xAA, 0x02, "TRIC"), \ exit_code_ipa0(0xAA, 0x03, "RIOFF"), \ exit_code_ipa0(0xAA, 0x04, "RIEMIT"), \ exit_code_ipa0(0xB2, 0x02, "STIDP"), \ exit_code_ipa0(0xB2, 0x04, "SCK"), \ exit_code_ipa0(0xB2, 0x05, "STCK"), \ exit_code_ipa0(0xB2, 0x06, "SCKC"), \ exit_code_ipa0(0xB2, 0x07, "STCKC"), \ exit_code_ipa0(0xB2, 0x08, "SPT"), \ exit_code_ipa0(0xB2, 0x09, "STPT"), \ exit_code_ipa0(0xB2, 0x0d, "PTLB"), \ exit_code_ipa0(0xB2, 0x10, "SPX"), \ exit_code_ipa0(0xB2, 0x11, "STPX"), \ exit_code_ipa0(0xB2, 0x12, "STAP"), \ exit_code_ipa0(0xB2, 0x14, "SIE"), \ exit_code_ipa0(0xB2, 0x16, "SETR"), \ exit_code_ipa0(0xB2, 0x17, "STETR"), \ exit_code_ipa0(0xB2, 0x18, "PC"), \ exit_code_ipa0(0xB2, 0x20, "SERVC"), \ exit_code_ipa0(0xB2, 0x21, "IPTE"), \ exit_code_ipa0(0xB2, 0x28, "PT"), \ exit_code_ipa0(0xB2, 0x29, "ISKE"), \ exit_code_ipa0(0xB2, 0x2a, "RRBE"), \ exit_code_ipa0(0xB2, 0x2b, "SSKE"), \ exit_code_ipa0(0xB2, 0x2c, "TB"), \ exit_code_ipa0(0xB2, 0x2e, "PGIN"), \ exit_code_ipa0(0xB2, 0x2f, "PGOUT"), \ exit_code_ipa0(0xB2, 0x30, "CSCH"), \ exit_code_ipa0(0xB2, 0x31, "HSCH"), \ exit_code_ipa0(0xB2, 0x32, "MSCH"), \ exit_code_ipa0(0xB2, 0x33, "SSCH"), \ exit_code_ipa0(0xB2, 0x34, "STSCH"), \ exit_code_ipa0(0xB2, 0x35, "TSCH"), \ exit_code_ipa0(0xB2, 0x36, "TPI"), \ exit_code_ipa0(0xB2, 0x37, "SAL"), \ exit_code_ipa0(0xB2, 0x38, "RSCH"), \ exit_code_ipa0(0xB2, 0x39, "STCRW"), \ exit_code_ipa0(0xB2, 0x3a, "STCPS"), \ exit_code_ipa0(0xB2, 0x3b, "RCHP"), \ exit_code_ipa0(0xB2, 0x3c, "SCHM"), \ exit_code_ipa0(0xB2, 0x40, "BAKR"), \ exit_code_ipa0(0xB2, 0x48, "PALB"), \ exit_code_ipa0(0xB2, 0x4c, "TAR"), \ exit_code_ipa0(0xB2, 0x50, "CSP"), \ exit_code_ipa0(0xB2, 0x54, "MVPG"), \ exit_code_ipa0(0xB2, 0x56, "STHYI"), \ exit_code_ipa0(0xB2, 0x58, "BSG"), \ exit_code_ipa0(0xB2, 0x5a, "BSA"), \ exit_code_ipa0(0xB2, 0x5f, "CHSC"), \ exit_code_ipa0(0xB2, 0x74, "SIGA"), \ exit_code_ipa0(0xB2, 0x76, "XSCH"), \ exit_code_ipa0(0xB2, 0x78, "STCKE"), \ exit_code_ipa0(0xB2, 0x7c, "STCKF"), \ exit_code_ipa0(0xB2, 0x7d, "STSI"), \ exit_code_ipa0(0xB2, 0xb0, "STFLE"), \ exit_code_ipa0(0xB2, 0xb1, "STFL"), \ exit_code_ipa0(0xB2, 0xb2, "LPSWE"), \ exit_code_ipa0(0xB2, 0xf8, "TEND"), \ exit_code_ipa0(0xB2, 0xfc, "TABORT"), \ exit_code_ipa0(0xB9, 0x1e, "KMAC"), \ exit_code_ipa0(0xB9, 0x28, "PCKMO"), \ exit_code_ipa0(0xB9, 0x2a, "KMF"), \ exit_code_ipa0(0xB9, 0x2b, "KMO"), \ exit_code_ipa0(0xB9, 0x2d, "KMCTR"), \ exit_code_ipa0(0xB9, 0x2e, "KM"), \ exit_code_ipa0(0xB9, 0x2f, "KMC"), \ exit_code_ipa0(0xB9, 0x3e, "KIMD"), \ exit_code_ipa0(0xB9, 0x3f, "KLMD"), \ exit_code_ipa0(0xB9, 0x8a, "CSPG"), \ exit_code_ipa0(0xB9, 0x8d, "EPSW"), \ exit_code_ipa0(0xB9, 0x8e, "IDTE"), \ exit_code_ipa0(0xB9, 0x8f, "CRDTE"), \ exit_code_ipa0(0xB9, 0x9c, "EQBS"), \ exit_code_ipa0(0xB9, 0xa2, "PTF"), \ exit_code_ipa0(0xB9, 0xab, "ESSA"), \ exit_code_ipa0(0xB9, 0xae, "RRBM"), \ exit_code_ipa0(0xB9, 0xaf, "PFMF"), \ exit_code_ipa0(0xE3, 0x03, "LRAG"), \ exit_code_ipa0(0xE3, 0x13, "LRAY"), \ exit_code_ipa0(0xE3, 0x25, "NTSTG"), \ exit_code_ipa0(0xE5, 0x00, "LASP"), \ exit_code_ipa0(0xE5, 0x01, "TPROT"), \ exit_code_ipa0(0xE5, 0x60, "TBEGIN"), \ exit_code_ipa0(0xE5, 0x61, "TBEGINC"), \ exit_code_ipa0(0xEB, 0x25, "STCTG"), \ exit_code_ipa0(0xEB, 0x2f, "LCTLG"), \ exit_code_ipa0(0xEB, 0x60, "LRIC"), \ exit_code_ipa0(0xEB, 0x61, "STRIC"), \ exit_code_ipa0(0xEB, 0x62, "MRIC"), \ exit_code_ipa0(0xEB, 0x8a, "SQBS"), \ exit_code_ipa0(0xC8, 0x01, "ECTG"), \ exit_code(0x0a, "SVC"), \ exit_code(0x80, "SSM"), \ exit_code(0x82, "LPSW"), \ exit_code(0x83, "DIAG"), \ exit_code(0xae, "SIGP"), \ exit_code(0xac, "STNSM"), \ exit_code(0xad, "STOSM"), \ exit_code(0xb1, "LRA"), \ exit_code(0xb6, "STCTL"), \ exit_code(0xb7, "LCTL"), \ exit_code(0xee, "PLO") #define sie_intercept_code \ { 0x00, "Host interruption" }, \ { 0x04, "Instruction" }, \ { 0x08, "Program interruption" }, \ { 0x0c, "Instruction and program interruption" }, \ { 0x10, "External request" }, \ { 0x14, "External interruption" }, \ { 0x18, "I/O request" }, \ { 0x1c, "Wait state" }, \ { 0x20, "Validity" }, \ { 0x28, "Stop request" }, \ { 0x2c, "Operation exception" }, \ { 0x38, "Partial-execution" }, \ { 0x3c, "I/O interruption" }, \ { 0x40, "I/O instruction" }, \ { 0x48, "Timing subset" } /* * This is the simple interceptable instructions decoder. * * It will be used as userspace interface and it can be used in places * that does not allow to use general decoder functions, * such as trace events declarations. * * Some userspace tools may want to parse this code * and would be confused by switch(), if() and other statements, * but they can understand conditional operator. */ #define INSN_DECODE_IPA0(ipa0, insn, rshift, mask) \ (insn >> 56) == (ipa0) ? \ ((ipa0 << 8) | ((insn >> rshift) & mask)) : #define INSN_DECODE(insn) (insn >> 56) /* * The macro icpt_insn_decoder() takes an intercepted instruction * and returns a key, which can be used to find a mnemonic name * of the instruction in the icpt_insn_codes table. */ #define icpt_insn_decoder(insn) ( \ INSN_DECODE_IPA0(0x01, insn, 48, 0xff) \ INSN_DECODE_IPA0(0xaa, insn, 48, 0x0f) \ INSN_DECODE_IPA0(0xb2, insn, 48, 0xff) \ INSN_DECODE_IPA0(0xb9, insn, 48, 0xff) \ INSN_DECODE_IPA0(0xe3, insn, 48, 0xff) \ INSN_DECODE_IPA0(0xe5, insn, 48, 0xff) \ INSN_DECODE_IPA0(0xeb, insn, 16, 0xff) \ INSN_DECODE_IPA0(0xc8, insn, 48, 0x0f) \ INSN_DECODE(insn)) #endif /* _UAPI_ASM_S390_SIE_H */ PK ! �2D include/uapi/asm/setup.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * Copyright IBM Corp. 1999, 2010 */ #ifndef _UAPI_ASM_S390_SETUP_H #define _UAPI_ASM_S390_SETUP_H #define COMMAND_LINE_SIZE 4096 #endif /* _UAPI_ASM_S390_SETUP_H */ PK ! ��6Z Z include/uapi/asm/Kbuildnu �[��� # SPDX-License-Identifier: GPL-2.0 generated-y += unistd_32.h generated-y += unistd_64.h PK ! H%v~� � include/uapi/asm/kvm_para.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * User API definitions for paravirtual devices on s390 * * Copyright IBM Corp. 2008 * * Author(s): Christian Borntraeger <borntraeger@de.ibm.com> */ PK ! bZj include/uapi/asm/ipcbuf.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef __S390_IPCBUF_H__ #define __S390_IPCBUF_H__ #include <linux/posix_types.h> /* * The user_ipc_perm structure for S/390 architecture. * Note extra padding because this structure is passed back and forth * between kernel and user space. * * Pad space is left for: * - 32-bit mode_t and seq * - 2 miscellaneous 32-bit values */ struct ipc64_perm { __kernel_key_t key; __kernel_uid32_t uid; __kernel_gid32_t gid; __kernel_uid32_t cuid; __kernel_gid32_t cgid; __kernel_mode_t mode; unsigned short __pad1; unsigned short seq; #ifndef __s390x__ unsigned short __pad2; #endif /* ! __s390x__ */ unsigned long __unused1; unsigned long __unused2; }; #endif /* __S390_IPCBUF_H__ */ PK ! lb��� � include/uapi/asm/chpid.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * Copyright IBM Corp. 2007, 2012 * Author(s): Peter Oberparleiter <peter.oberparleiter@de.ibm.com> */ #ifndef _UAPI_ASM_S390_CHPID_H #define _UAPI_ASM_S390_CHPID_H #include <linux/string.h> #include <linux/types.h> #define __MAX_CHPID 255 struct chp_id { __u8 reserved1; __u8 cssid; __u8 reserved2; __u8 id; } __attribute__((packed)); #endif /* _UAPI_ASM_S390_CHPID_H */ PK ! h+�w w include/uapi/asm/perf_regs.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _ASM_S390_PERF_REGS_H #define _ASM_S390_PERF_REGS_H enum perf_event_s390_regs { PERF_REG_S390_R0, PERF_REG_S390_R1, PERF_REG_S390_R2, PERF_REG_S390_R3, PERF_REG_S390_R4, PERF_REG_S390_R5, PERF_REG_S390_R6, PERF_REG_S390_R7, PERF_REG_S390_R8, PERF_REG_S390_R9, PERF_REG_S390_R10, PERF_REG_S390_R11, PERF_REG_S390_R12, PERF_REG_S390_R13, PERF_REG_S390_R14, PERF_REG_S390_R15, PERF_REG_S390_FP0, PERF_REG_S390_FP1, PERF_REG_S390_FP2, PERF_REG_S390_FP3, PERF_REG_S390_FP4, PERF_REG_S390_FP5, PERF_REG_S390_FP6, PERF_REG_S390_FP7, PERF_REG_S390_FP8, PERF_REG_S390_FP9, PERF_REG_S390_FP10, PERF_REG_S390_FP11, PERF_REG_S390_FP12, PERF_REG_S390_FP13, PERF_REG_S390_FP14, PERF_REG_S390_FP15, PERF_REG_S390_MASK, PERF_REG_S390_PC, PERF_REG_S390_MAX }; #endif /* _ASM_S390_PERF_REGS_H */ PK ! �Q8�� � include/uapi/asm/uvdevice.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * Copyright IBM Corp. 2022 * Author(s): Steffen Eiden <seiden@linux.ibm.com> */ #ifndef __S390_ASM_UVDEVICE_H #define __S390_ASM_UVDEVICE_H #include <linux/types.h> struct uvio_ioctl_cb { __u32 flags; __u16 uv_rc; /* UV header rc value */ __u16 uv_rrc; /* UV header rrc value */ __u64 argument_addr; /* Userspace address of uvio argument */ __u32 argument_len; __u8 reserved14[0x40 - 0x14]; /* must be zero */ }; #define UVIO_ATT_USER_DATA_LEN 0x100 #define UVIO_ATT_UID_LEN 0x10 struct uvio_attest { __u64 arcb_addr; /* 0x0000 */ __u64 meas_addr; /* 0x0008 */ __u64 add_data_addr; /* 0x0010 */ __u8 user_data[UVIO_ATT_USER_DATA_LEN]; /* 0x0018 */ __u8 config_uid[UVIO_ATT_UID_LEN]; /* 0x0118 */ __u32 arcb_len; /* 0x0128 */ __u32 meas_len; /* 0x012c */ __u32 add_data_len; /* 0x0130 */ __u16 user_data_len; /* 0x0134 */ __u16 reserved136; /* 0x0136 */ }; /* * The following max values define an upper length for the IOCTL in/out buffers. * However, they do not represent the maximum the Ultravisor allows which is * often way smaller. By allowing larger buffer sizes we hopefully do not need * to update the code with every machine update. It is therefore possible for * userspace to request more memory than actually used by kernel/UV. */ #define UVIO_ATT_ARCB_MAX_LEN 0x100000 #define UVIO_ATT_MEASUREMENT_MAX_LEN 0x8000 #define UVIO_ATT_ADDITIONAL_MAX_LEN 0x8000 #define UVIO_DEVICE_NAME "uv" #define UVIO_TYPE_UVC 'u' #define UVIO_IOCTL_ATT _IOWR(UVIO_TYPE_UVC, 0x01, struct uvio_ioctl_cb) #endif /* __S390_ASM_UVDEVICE_H */ PK ! 6�A| | include/uapi/asm/schid.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _UAPIASM_SCHID_H #define _UAPIASM_SCHID_H #include <linux/types.h> #ifndef __ASSEMBLY__ struct subchannel_id { __u32 cssid : 8; __u32 : 4; __u32 m : 1; __u32 ssid : 2; __u32 one : 1; __u32 sch_no : 16; } __attribute__ ((packed, aligned(4))); #endif /* __ASSEMBLY__ */ #endif /* _UAPIASM_SCHID_H */ PK ! ���� � include/uapi/asm/termios.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * * Derived from "include/asm-i386/termios.h" */ #ifndef _UAPI_S390_TERMIOS_H #define _UAPI_S390_TERMIOS_H #include <asm/termbits.h> #include <asm/ioctls.h> struct winsize { unsigned short ws_row; unsigned short ws_col; unsigned short ws_xpixel; unsigned short ws_ypixel; }; #define NCC 8 struct termio { unsigned short c_iflag; /* input mode flags */ unsigned short c_oflag; /* output mode flags */ unsigned short c_cflag; /* control mode flags */ unsigned short c_lflag; /* local mode flags */ unsigned char c_line; /* line discipline */ unsigned char c_cc[NCC]; /* control characters */ }; /* modem lines */ #define TIOCM_LE 0x001 #define TIOCM_DTR 0x002 #define TIOCM_RTS 0x004 #define TIOCM_ST 0x008 #define TIOCM_SR 0x010 #define TIOCM_CTS 0x020 #define TIOCM_CAR 0x040 #define TIOCM_RNG 0x080 #define TIOCM_DSR 0x100 #define TIOCM_CD TIOCM_CAR #define TIOCM_RI TIOCM_RNG #define TIOCM_OUT1 0x2000 #define TIOCM_OUT2 0x4000 #define TIOCM_LOOP 0x8000 /* ioctl (fd, TIOCSERGETLSR, &result) where result may be as below */ #endif /* _UAPI_S390_TERMIOS_H */ PK ! �<�: : include/uapi/asm/posix_types.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * */ #ifndef __ARCH_S390_POSIX_TYPES_H #define __ARCH_S390_POSIX_TYPES_H /* * This file is generally used by user-level software, so you need to * be a little careful about namespace pollution etc. Also, we cannot * assume GCC is being used. */ typedef unsigned long __kernel_size_t; typedef long __kernel_ssize_t; #define __kernel_size_t __kernel_size_t typedef unsigned short __kernel_old_dev_t; #define __kernel_old_dev_t __kernel_old_dev_t #ifdef __KERNEL__ typedef unsigned short __kernel_old_uid_t; typedef unsigned short __kernel_old_gid_t; #define __kernel_old_uid_t __kernel_old_uid_t #endif #ifndef __s390x__ typedef unsigned long __kernel_ino_t; typedef unsigned short __kernel_mode_t; typedef unsigned short __kernel_ipc_pid_t; typedef unsigned short __kernel_uid_t; typedef unsigned short __kernel_gid_t; typedef int __kernel_ptrdiff_t; #else /* __s390x__ */ typedef unsigned int __kernel_ino_t; typedef unsigned int __kernel_mode_t; typedef int __kernel_ipc_pid_t; typedef unsigned int __kernel_uid_t; typedef unsigned int __kernel_gid_t; typedef long __kernel_ptrdiff_t; typedef unsigned long __kernel_sigset_t; /* at least 32 bits */ #endif /* __s390x__ */ #define __kernel_ino_t __kernel_ino_t #define __kernel_mode_t __kernel_mode_t #define __kernel_ipc_pid_t __kernel_ipc_pid_t #define __kernel_uid_t __kernel_uid_t #define __kernel_gid_t __kernel_gid_t #include <asm-generic/posix_types.h> #endif PK ! "�/ include/uapi/asm/types.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * * Derived from "include/asm-i386/types.h" */ #ifndef _UAPI_S390_TYPES_H #define _UAPI_S390_TYPES_H #include <asm-generic/int-ll64.h> #ifndef __ASSEMBLY__ /* A address type so that arithmetic can be done on it & it can be upgraded to 64 bit when necessary */ typedef unsigned long addr_t; typedef __signed__ long saddr_t; typedef struct { __u32 u[4]; } __vector128; #endif /* __ASSEMBLY__ */ #endif /* _UAPI_S390_TYPES_H */ PK ! �#i5M M include/uapi/asm/kvm.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef __LINUX_KVM_S390_H #define __LINUX_KVM_S390_H /* * KVM s390 specific structures and definitions * * Copyright IBM Corp. 2008, 2018 * * Author(s): Carsten Otte <cotte@de.ibm.com> * Christian Borntraeger <borntraeger@de.ibm.com> */ #include <linux/types.h> #define __KVM_S390 #define __KVM_HAVE_GUEST_DEBUG /* Device control API: s390-specific devices */ #define KVM_DEV_FLIC_GET_ALL_IRQS 1 #define KVM_DEV_FLIC_ENQUEUE 2 #define KVM_DEV_FLIC_CLEAR_IRQS 3 #define KVM_DEV_FLIC_APF_ENABLE 4 #define KVM_DEV_FLIC_APF_DISABLE_WAIT 5 #define KVM_DEV_FLIC_ADAPTER_REGISTER 6 #define KVM_DEV_FLIC_ADAPTER_MODIFY 7 #define KVM_DEV_FLIC_CLEAR_IO_IRQ 8 #define KVM_DEV_FLIC_AISM 9 #define KVM_DEV_FLIC_AIRQ_INJECT 10 #define KVM_DEV_FLIC_AISM_ALL 11 /* * We can have up to 4*64k pending subchannels + 8 adapter interrupts, * as well as up to ASYNC_PF_PER_VCPU*KVM_MAX_VCPUS pfault done interrupts. * There are also sclp and machine checks. This gives us * sizeof(kvm_s390_irq)*(4*65536+8+64*64+1+1) = 72 * 266250 = 19170000 * Lets round up to 8192 pages. */ #define KVM_S390_MAX_FLOAT_IRQS 266250 #define KVM_S390_FLIC_MAX_BUFFER 0x2000000 struct kvm_s390_io_adapter { __u32 id; __u8 isc; __u8 maskable; __u8 swap; __u8 flags; }; #define KVM_S390_ADAPTER_SUPPRESSIBLE 0x01 struct kvm_s390_ais_req { __u8 isc; __u16 mode; }; struct kvm_s390_ais_all { __u8 simm; __u8 nimm; }; #define KVM_S390_IO_ADAPTER_MASK 1 #define KVM_S390_IO_ADAPTER_MAP 2 #define KVM_S390_IO_ADAPTER_UNMAP 3 struct kvm_s390_io_adapter_req { __u32 id; __u8 type; __u8 mask; __u16 pad0; __u64 addr; }; /* kvm attr_group on vm fd */ #define KVM_S390_VM_MEM_CTRL 0 #define KVM_S390_VM_TOD 1 #define KVM_S390_VM_CRYPTO 2 #define KVM_S390_VM_CPU_MODEL 3 #define KVM_S390_VM_MIGRATION 4 /* kvm attributes for mem_ctrl */ #define KVM_S390_VM_MEM_ENABLE_CMMA 0 #define KVM_S390_VM_MEM_CLR_CMMA 1 #define KVM_S390_VM_MEM_LIMIT_SIZE 2 #define KVM_S390_NO_MEM_LIMIT U64_MAX /* kvm attributes for KVM_S390_VM_TOD */ #define KVM_S390_VM_TOD_LOW 0 #define KVM_S390_VM_TOD_HIGH 1 #define KVM_S390_VM_TOD_EXT 2 struct kvm_s390_vm_tod_clock { __u8 epoch_idx; __u64 tod; }; /* kvm attributes for KVM_S390_VM_CPU_MODEL */ /* processor related attributes are r/w */ #define KVM_S390_VM_CPU_PROCESSOR 0 struct kvm_s390_vm_cpu_processor { __u64 cpuid; __u16 ibc; __u8 pad[6]; __u64 fac_list[256]; }; /* machine related attributes are r/o */ #define KVM_S390_VM_CPU_MACHINE 1 struct kvm_s390_vm_cpu_machine { __u64 cpuid; __u32 ibc; __u8 pad[4]; __u64 fac_mask[256]; __u64 fac_list[256]; }; #define KVM_S390_VM_CPU_PROCESSOR_FEAT 2 #define KVM_S390_VM_CPU_MACHINE_FEAT 3 #define KVM_S390_VM_CPU_FEAT_NR_BITS 1024 #define KVM_S390_VM_CPU_FEAT_ESOP 0 #define KVM_S390_VM_CPU_FEAT_SIEF2 1 #define KVM_S390_VM_CPU_FEAT_64BSCAO 2 #define KVM_S390_VM_CPU_FEAT_SIIF 3 #define KVM_S390_VM_CPU_FEAT_GPERE 4 #define KVM_S390_VM_CPU_FEAT_GSLS 5 #define KVM_S390_VM_CPU_FEAT_IB 6 #define KVM_S390_VM_CPU_FEAT_CEI 7 #define KVM_S390_VM_CPU_FEAT_IBS 8 #define KVM_S390_VM_CPU_FEAT_SKEY 9 #define KVM_S390_VM_CPU_FEAT_CMMA 10 #define KVM_S390_VM_CPU_FEAT_PFMFI 11 #define KVM_S390_VM_CPU_FEAT_SIGPIF 12 #define KVM_S390_VM_CPU_FEAT_KSS 13 struct kvm_s390_vm_cpu_feat { __u64 feat[16]; }; #define KVM_S390_VM_CPU_PROCESSOR_SUBFUNC 4 #define KVM_S390_VM_CPU_MACHINE_SUBFUNC 5 /* for "test bit" instructions MSB 0 bit ordering, for "query" raw blocks */ struct kvm_s390_vm_cpu_subfunc { __u8 plo[32]; /* always */ __u8 ptff[16]; /* with TOD-clock steering */ __u8 kmac[16]; /* with MSA */ __u8 kmc[16]; /* with MSA */ __u8 km[16]; /* with MSA */ __u8 kimd[16]; /* with MSA */ __u8 klmd[16]; /* with MSA */ __u8 pckmo[16]; /* with MSA3 */ __u8 kmctr[16]; /* with MSA4 */ __u8 kmf[16]; /* with MSA4 */ __u8 kmo[16]; /* with MSA4 */ __u8 pcc[16]; /* with MSA4 */ __u8 ppno[16]; /* with MSA5 */ __u8 kma[16]; /* with MSA8 */ __u8 kdsa[16]; /* with MSA9 */ __u8 sortl[32]; /* with STFLE.150 */ __u8 dfltcc[32]; /* with STFLE.151 */ __u8 reserved[1728]; }; /* kvm attributes for crypto */ #define KVM_S390_VM_CRYPTO_ENABLE_AES_KW 0 #define KVM_S390_VM_CRYPTO_ENABLE_DEA_KW 1 #define KVM_S390_VM_CRYPTO_DISABLE_AES_KW 2 #define KVM_S390_VM_CRYPTO_DISABLE_DEA_KW 3 #define KVM_S390_VM_CRYPTO_ENABLE_APIE 4 #define KVM_S390_VM_CRYPTO_DISABLE_APIE 5 /* kvm attributes for migration mode */ #define KVM_S390_VM_MIGRATION_STOP 0 #define KVM_S390_VM_MIGRATION_START 1 #define KVM_S390_VM_MIGRATION_STATUS 2 /* for KVM_GET_REGS and KVM_SET_REGS */ struct kvm_regs { /* general purpose regs for s390 */ __u64 gprs[16]; }; /* for KVM_GET_SREGS and KVM_SET_SREGS */ struct kvm_sregs { __u32 acrs[16]; __u64 crs[16]; }; /* for KVM_GET_FPU and KVM_SET_FPU */ struct kvm_fpu { __u32 fpc; __u64 fprs[16]; }; #define KVM_GUESTDBG_USE_HW_BP 0x00010000 #define KVM_HW_BP 1 #define KVM_HW_WP_WRITE 2 #define KVM_SINGLESTEP 4 struct kvm_debug_exit_arch { __u64 addr; __u8 type; __u8 pad[7]; /* Should be set to 0 */ }; struct kvm_hw_breakpoint { __u64 addr; __u64 phys_addr; __u64 len; __u8 type; __u8 pad[7]; /* Should be set to 0 */ }; /* for KVM_SET_GUEST_DEBUG */ struct kvm_guest_debug_arch { __u32 nr_hw_bp; __u32 pad; /* Should be set to 0 */ struct kvm_hw_breakpoint __user *hw_bp; }; /* for KVM_SYNC_PFAULT and KVM_REG_S390_PFTOKEN */ #define KVM_S390_PFAULT_TOKEN_INVALID 0xffffffffffffffffULL #define KVM_SYNC_PREFIX (1UL << 0) #define KVM_SYNC_GPRS (1UL << 1) #define KVM_SYNC_ACRS (1UL << 2) #define KVM_SYNC_CRS (1UL << 3) #define KVM_SYNC_ARCH0 (1UL << 4) #define KVM_SYNC_PFAULT (1UL << 5) #define KVM_SYNC_VRS (1UL << 6) #define KVM_SYNC_RICCB (1UL << 7) #define KVM_SYNC_FPRS (1UL << 8) #define KVM_SYNC_GSCB (1UL << 9) #define KVM_SYNC_BPBC (1UL << 10) #define KVM_SYNC_ETOKEN (1UL << 11) #define KVM_SYNC_DIAG318 (1UL << 12) #define KVM_SYNC_S390_VALID_FIELDS \ (KVM_SYNC_PREFIX | KVM_SYNC_GPRS | KVM_SYNC_ACRS | KVM_SYNC_CRS | \ KVM_SYNC_ARCH0 | KVM_SYNC_PFAULT | KVM_SYNC_VRS | KVM_SYNC_RICCB | \ KVM_SYNC_FPRS | KVM_SYNC_GSCB | KVM_SYNC_BPBC | KVM_SYNC_ETOKEN | \ KVM_SYNC_DIAG318) /* length and alignment of the sdnx as a power of two */ #define SDNXC 8 #define SDNXL (1UL << SDNXC) /* definition of registers in kvm_run */ struct kvm_sync_regs { __u64 prefix; /* prefix register */ __u64 gprs[16]; /* general purpose registers */ __u32 acrs[16]; /* access registers */ __u64 crs[16]; /* control registers */ __u64 todpr; /* tod programmable register [ARCH0] */ __u64 cputm; /* cpu timer [ARCH0] */ __u64 ckc; /* clock comparator [ARCH0] */ __u64 pp; /* program parameter [ARCH0] */ __u64 gbea; /* guest breaking-event address [ARCH0] */ __u64 pft; /* pfault token [PFAULT] */ __u64 pfs; /* pfault select [PFAULT] */ __u64 pfc; /* pfault compare [PFAULT] */ union { __u64 vrs[32][2]; /* vector registers (KVM_SYNC_VRS) */ __u64 fprs[16]; /* fp registers (KVM_SYNC_FPRS) */ }; __u8 reserved[512]; /* for future vector expansion */ __u32 fpc; /* valid on KVM_SYNC_VRS or KVM_SYNC_FPRS */ __u8 bpbc : 1; /* bp mode */ __u8 reserved2 : 7; __u8 padding1[51]; /* riccb needs to be 64byte aligned */ __u8 riccb[64]; /* runtime instrumentation controls block */ __u64 diag318; /* diagnose 0x318 info */ __u8 padding2[184]; /* sdnx needs to be 256byte aligned */ union { __u8 sdnx[SDNXL]; /* state description annex */ struct { __u64 reserved1[2]; __u64 gscb[4]; __u64 etoken; __u64 etoken_extension; }; }; }; #define KVM_REG_S390_TODPR (KVM_REG_S390 | KVM_REG_SIZE_U32 | 0x1) #define KVM_REG_S390_EPOCHDIFF (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x2) #define KVM_REG_S390_CPU_TIMER (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x3) #define KVM_REG_S390_CLOCK_COMP (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x4) #define KVM_REG_S390_PFTOKEN (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x5) #define KVM_REG_S390_PFCOMPARE (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x6) #define KVM_REG_S390_PFSELECT (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x7) #define KVM_REG_S390_PP (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x8) #define KVM_REG_S390_GBEA (KVM_REG_S390 | KVM_REG_SIZE_U64 | 0x9) #endif PK ! ���� � include/uapi/asm/signal.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * * Derived from "include/asm-i386/signal.h" */ #ifndef _UAPI_ASMS390_SIGNAL_H #define _UAPI_ASMS390_SIGNAL_H #include <linux/types.h> #include <linux/time.h> /* Avoid too many header ordering problems. */ struct siginfo; struct pt_regs; #ifndef __KERNEL__ /* Here we must cater to libcs that poke about in kernel headers. */ #define NSIG 32 typedef unsigned long sigset_t; #endif /* __KERNEL__ */ #define SIGHUP 1 #define SIGINT 2 #define SIGQUIT 3 #define SIGILL 4 #define SIGTRAP 5 #define SIGABRT 6 #define SIGIOT 6 #define SIGBUS 7 #define SIGFPE 8 #define SIGKILL 9 #define SIGUSR1 10 #define SIGSEGV 11 #define SIGUSR2 12 #define SIGPIPE 13 #define SIGALRM 14 #define SIGTERM 15 #define SIGSTKFLT 16 #define SIGCHLD 17 #define SIGCONT 18 #define SIGSTOP 19 #define SIGTSTP 20 #define SIGTTIN 21 #define SIGTTOU 22 #define SIGURG 23 #define SIGXCPU 24 #define SIGXFSZ 25 #define SIGVTALRM 26 #define SIGPROF 27 #define SIGWINCH 28 #define SIGIO 29 #define SIGPOLL SIGIO /* #define SIGLOST 29 */ #define SIGPWR 30 #define SIGSYS 31 #define SIGUNUSED 31 /* These should not be considered constants from userland. */ #define SIGRTMIN 32 #define SIGRTMAX _NSIG #define SA_RESTORER 0x04000000 #define MINSIGSTKSZ 2048 #define SIGSTKSZ 8192 #include <asm-generic/signal-defs.h> #ifndef __KERNEL__ /* * There are two system calls in regard to sigaction, sys_rt_sigaction * and sys_sigaction. Internally the kernel uses the struct old_sigaction * for the older sys_sigaction system call, and the kernel version of the * struct sigaction for the newer sys_rt_sigaction. * * The uapi definition for struct sigaction has made a strange distinction * between 31-bit and 64-bit in the past. For 64-bit the uapi structure * looks like the kernel struct sigaction, but for 31-bit it used to * look like the kernel struct old_sigaction. That practically made the * structure unusable for either system call. To get around this problem * the glibc always had its own definitions for the sigaction structures. * * The current struct sigaction uapi definition below is suitable for the * sys_rt_sigaction system call only. */ struct sigaction { union { __sighandler_t _sa_handler; void (*_sa_sigaction)(int, struct siginfo *, void *); } _u; unsigned long sa_flags; void (*sa_restorer)(void); sigset_t sa_mask; }; #define sa_handler _u._sa_handler #define sa_sigaction _u._sa_sigaction #endif /* __KERNEL__ */ typedef struct sigaltstack { void __user *ss_sp; int ss_flags; size_t ss_size; } stack_t; #endif /* _UAPI_ASMS390_SIGNAL_H */ PK ! �;� � include/uapi/asm/sclp_ctl.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * IOCTL interface for SCLP * * Copyright IBM Corp. 2012 * * Author: Michael Holzheu <holzheu@linux.vnet.ibm.com> */ #ifndef _ASM_SCLP_CTL_H #define _ASM_SCLP_CTL_H #include <linux/types.h> struct sclp_ctl_sccb { __u32 cmdw; __u64 sccb; } __attribute__((packed)); #define SCLP_CTL_IOCTL_MAGIC 0x10 #define SCLP_CTL_SCCB \ _IOWR(SCLP_CTL_IOCTL_MAGIC, 0x10, struct sclp_ctl_sccb) #endif PK ! ����- �- include/uapi/asm/ptrace.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * Copyright IBM Corp. 1999, 2000 * Author(s): Denis Joseph Barrow (djbarrow@de.ibm.com,barrow_dj@yahoo.com) */ #ifndef _UAPI_S390_PTRACE_H #define _UAPI_S390_PTRACE_H /* * Offsets in the user_regs_struct. They are used for the ptrace * system call and in entry.S */ #ifndef __s390x__ #define PT_PSWMASK 0x00 #define PT_PSWADDR 0x04 #define PT_GPR0 0x08 #define PT_GPR1 0x0C #define PT_GPR2 0x10 #define PT_GPR3 0x14 #define PT_GPR4 0x18 #define PT_GPR5 0x1C #define PT_GPR6 0x20 #define PT_GPR7 0x24 #define PT_GPR8 0x28 #define PT_GPR9 0x2C #define PT_GPR10 0x30 #define PT_GPR11 0x34 #define PT_GPR12 0x38 #define PT_GPR13 0x3C #define PT_GPR14 0x40 #define PT_GPR15 0x44 #define PT_ACR0 0x48 #define PT_ACR1 0x4C #define PT_ACR2 0x50 #define PT_ACR3 0x54 #define PT_ACR4 0x58 #define PT_ACR5 0x5C #define PT_ACR6 0x60 #define PT_ACR7 0x64 #define PT_ACR8 0x68 #define PT_ACR9 0x6C #define PT_ACR10 0x70 #define PT_ACR11 0x74 #define PT_ACR12 0x78 #define PT_ACR13 0x7C #define PT_ACR14 0x80 #define PT_ACR15 0x84 #define PT_ORIGGPR2 0x88 #define PT_FPC 0x90 /* * A nasty fact of life that the ptrace api * only supports passing of longs. */ #define PT_FPR0_HI 0x98 #define PT_FPR0_LO 0x9C #define PT_FPR1_HI 0xA0 #define PT_FPR1_LO 0xA4 #define PT_FPR2_HI 0xA8 #define PT_FPR2_LO 0xAC #define PT_FPR3_HI 0xB0 #define PT_FPR3_LO 0xB4 #define PT_FPR4_HI 0xB8 #define PT_FPR4_LO 0xBC #define PT_FPR5_HI 0xC0 #define PT_FPR5_LO 0xC4 #define PT_FPR6_HI 0xC8 #define PT_FPR6_LO 0xCC #define PT_FPR7_HI 0xD0 #define PT_FPR7_LO 0xD4 #define PT_FPR8_HI 0xD8 #define PT_FPR8_LO 0XDC #define PT_FPR9_HI 0xE0 #define PT_FPR9_LO 0xE4 #define PT_FPR10_HI 0xE8 #define PT_FPR10_LO 0xEC #define PT_FPR11_HI 0xF0 #define PT_FPR11_LO 0xF4 #define PT_FPR12_HI 0xF8 #define PT_FPR12_LO 0xFC #define PT_FPR13_HI 0x100 #define PT_FPR13_LO 0x104 #define PT_FPR14_HI 0x108 #define PT_FPR14_LO 0x10C #define PT_FPR15_HI 0x110 #define PT_FPR15_LO 0x114 #define PT_CR_9 0x118 #define PT_CR_10 0x11C #define PT_CR_11 0x120 #define PT_IEEE_IP 0x13C #define PT_LASTOFF PT_IEEE_IP #define PT_ENDREGS 0x140-1 #define GPR_SIZE 4 #define CR_SIZE 4 #define STACK_FRAME_OVERHEAD 96 /* size of minimum stack frame */ #else /* __s390x__ */ #define PT_PSWMASK 0x00 #define PT_PSWADDR 0x08 #define PT_GPR0 0x10 #define PT_GPR1 0x18 #define PT_GPR2 0x20 #define PT_GPR3 0x28 #define PT_GPR4 0x30 #define PT_GPR5 0x38 #define PT_GPR6 0x40 #define PT_GPR7 0x48 #define PT_GPR8 0x50 #define PT_GPR9 0x58 #define PT_GPR10 0x60 #define PT_GPR11 0x68 #define PT_GPR12 0x70 #define PT_GPR13 0x78 #define PT_GPR14 0x80 #define PT_GPR15 0x88 #define PT_ACR0 0x90 #define PT_ACR1 0x94 #define PT_ACR2 0x98 #define PT_ACR3 0x9C #define PT_ACR4 0xA0 #define PT_ACR5 0xA4 #define PT_ACR6 0xA8 #define PT_ACR7 0xAC #define PT_ACR8 0xB0 #define PT_ACR9 0xB4 #define PT_ACR10 0xB8 #define PT_ACR11 0xBC #define PT_ACR12 0xC0 #define PT_ACR13 0xC4 #define PT_ACR14 0xC8 #define PT_ACR15 0xCC #define PT_ORIGGPR2 0xD0 #define PT_FPC 0xD8 #define PT_FPR0 0xE0 #define PT_FPR1 0xE8 #define PT_FPR2 0xF0 #define PT_FPR3 0xF8 #define PT_FPR4 0x100 #define PT_FPR5 0x108 #define PT_FPR6 0x110 #define PT_FPR7 0x118 #define PT_FPR8 0x120 #define PT_FPR9 0x128 #define PT_FPR10 0x130 #define PT_FPR11 0x138 #define PT_FPR12 0x140 #define PT_FPR13 0x148 #define PT_FPR14 0x150 #define PT_FPR15 0x158 #define PT_CR_9 0x160 #define PT_CR_10 0x168 #define PT_CR_11 0x170 #define PT_IEEE_IP 0x1A8 #define PT_LASTOFF PT_IEEE_IP #define PT_ENDREGS 0x1B0-1 #define GPR_SIZE 8 #define CR_SIZE 8 #define STACK_FRAME_OVERHEAD 160 /* size of minimum stack frame */ #endif /* __s390x__ */ #define NUM_GPRS 16 #define NUM_FPRS 16 #define NUM_CRS 16 #define NUM_ACRS 16 #define NUM_CR_WORDS 3 #define FPR_SIZE 8 #define FPC_SIZE 4 #define FPC_PAD_SIZE 4 /* gcc insists on aligning the fpregs */ #define ACR_SIZE 4 #define PTRACE_OLDSETOPTIONS 21 #define PTRACE_SYSEMU 31 #define PTRACE_SYSEMU_SINGLESTEP 32 #ifndef __ASSEMBLY__ #include <linux/stddef.h> #include <linux/types.h> typedef union { float f; double d; __u64 ui; struct { __u32 hi; __u32 lo; } fp; } freg_t; typedef struct { __u32 fpc; __u32 pad; freg_t fprs[NUM_FPRS]; } s390_fp_regs; #define FPC_EXCEPTION_MASK 0xF8000000 #define FPC_FLAGS_MASK 0x00F80000 #define FPC_DXC_MASK 0x0000FF00 #define FPC_RM_MASK 0x00000003 /* this typedef defines how a Program Status Word looks like */ typedef struct { unsigned long mask; unsigned long addr; } __attribute__ ((aligned(8))) psw_t; #ifndef __s390x__ #define PSW_MASK_PER 0x40000000UL #define PSW_MASK_DAT 0x04000000UL #define PSW_MASK_IO 0x02000000UL #define PSW_MASK_EXT 0x01000000UL #define PSW_MASK_KEY 0x00F00000UL #define PSW_MASK_BASE 0x00080000UL /* always one */ #define PSW_MASK_MCHECK 0x00040000UL #define PSW_MASK_WAIT 0x00020000UL #define PSW_MASK_PSTATE 0x00010000UL #define PSW_MASK_ASC 0x0000C000UL #define PSW_MASK_CC 0x00003000UL #define PSW_MASK_PM 0x00000F00UL #define PSW_MASK_RI 0x00000000UL #define PSW_MASK_EA 0x00000000UL #define PSW_MASK_BA 0x00000000UL #define PSW_MASK_USER 0x0000FF00UL #define PSW_ADDR_AMODE 0x80000000UL #define PSW_ADDR_INSN 0x7FFFFFFFUL #define PSW_DEFAULT_KEY (((unsigned long) PAGE_DEFAULT_ACC) << 20) #define PSW_ASC_PRIMARY 0x00000000UL #define PSW_ASC_ACCREG 0x00004000UL #define PSW_ASC_SECONDARY 0x00008000UL #define PSW_ASC_HOME 0x0000C000UL #else /* __s390x__ */ #define PSW_MASK_PER 0x4000000000000000UL #define PSW_MASK_DAT 0x0400000000000000UL #define PSW_MASK_IO 0x0200000000000000UL #define PSW_MASK_EXT 0x0100000000000000UL #define PSW_MASK_BASE 0x0000000000000000UL #define PSW_MASK_KEY 0x00F0000000000000UL #define PSW_MASK_MCHECK 0x0004000000000000UL #define PSW_MASK_WAIT 0x0002000000000000UL #define PSW_MASK_PSTATE 0x0001000000000000UL #define PSW_MASK_ASC 0x0000C00000000000UL #define PSW_MASK_CC 0x0000300000000000UL #define PSW_MASK_PM 0x00000F0000000000UL #define PSW_MASK_RI 0x0000008000000000UL #define PSW_MASK_EA 0x0000000100000000UL #define PSW_MASK_BA 0x0000000080000000UL #define PSW_MASK_USER 0x0000FF0180000000UL #define PSW_ADDR_AMODE 0x0000000000000000UL #define PSW_ADDR_INSN 0xFFFFFFFFFFFFFFFFUL #define PSW_DEFAULT_KEY (((unsigned long) PAGE_DEFAULT_ACC) << 52) #define PSW_ASC_PRIMARY 0x0000000000000000UL #define PSW_ASC_ACCREG 0x0000400000000000UL #define PSW_ASC_SECONDARY 0x0000800000000000UL #define PSW_ASC_HOME 0x0000C00000000000UL #endif /* __s390x__ */ /* * The s390_regs structure is used to define the elf_gregset_t. */ typedef struct { psw_t psw; unsigned long gprs[NUM_GPRS]; unsigned int acrs[NUM_ACRS]; unsigned long orig_gpr2; } s390_regs; /* * The user_pt_regs structure exports the beginning of * the in-kernel pt_regs structure to user space. */ typedef struct { unsigned long args[1]; psw_t psw; unsigned long gprs[NUM_GPRS]; } user_pt_regs; /* * Now for the user space program event recording (trace) definitions. * The following structures are used only for the ptrace interface, don't * touch or even look at it if you don't want to modify the user-space * ptrace interface. In particular stay away from it for in-kernel PER. */ typedef struct { unsigned long cr[NUM_CR_WORDS]; } per_cr_words; #define PER_EM_MASK 0xE8000000UL typedef struct { #ifdef __s390x__ unsigned : 32; #endif /* __s390x__ */ unsigned em_branching : 1; unsigned em_instruction_fetch : 1; /* * Switching on storage alteration automatically fixes * the storage alteration event bit in the users std. */ unsigned em_storage_alteration : 1; unsigned em_gpr_alt_unused : 1; unsigned em_store_real_address : 1; unsigned : 3; unsigned branch_addr_ctl : 1; unsigned : 1; unsigned storage_alt_space_ctl : 1; unsigned : 21; unsigned long starting_addr; unsigned long ending_addr; } per_cr_bits; typedef struct { unsigned short perc_atmid; unsigned long address; unsigned char access_id; } per_lowcore_words; typedef struct { unsigned perc_branching : 1; unsigned perc_instruction_fetch : 1; unsigned perc_storage_alteration : 1; unsigned perc_gpr_alt_unused : 1; unsigned perc_store_real_address : 1; unsigned : 3; unsigned atmid_psw_bit_31 : 1; unsigned atmid_validity_bit : 1; unsigned atmid_psw_bit_32 : 1; unsigned atmid_psw_bit_5 : 1; unsigned atmid_psw_bit_16 : 1; unsigned atmid_psw_bit_17 : 1; unsigned si : 2; unsigned long address; unsigned : 4; unsigned access_id : 4; } per_lowcore_bits; typedef struct { union { per_cr_words words; per_cr_bits bits; } control_regs; /* * The single_step and instruction_fetch bits are obsolete, * the kernel always sets them to zero. To enable single * stepping use ptrace(PTRACE_SINGLESTEP) instead. */ unsigned single_step : 1; unsigned instruction_fetch : 1; unsigned : 30; /* * These addresses are copied into cr10 & cr11 if single * stepping is switched off */ unsigned long starting_addr; unsigned long ending_addr; union { per_lowcore_words words; per_lowcore_bits bits; } lowcore; } per_struct; typedef struct { unsigned int len; unsigned long kernel_addr; unsigned long process_addr; } ptrace_area; /* * S/390 specific non posix ptrace requests. I chose unusual values so * they are unlikely to clash with future ptrace definitions. */ #define PTRACE_PEEKUSR_AREA 0x5000 #define PTRACE_POKEUSR_AREA 0x5001 #define PTRACE_PEEKTEXT_AREA 0x5002 #define PTRACE_PEEKDATA_AREA 0x5003 #define PTRACE_POKETEXT_AREA 0x5004 #define PTRACE_POKEDATA_AREA 0x5005 #define PTRACE_GET_LAST_BREAK 0x5006 #define PTRACE_PEEK_SYSTEM_CALL 0x5007 #define PTRACE_POKE_SYSTEM_CALL 0x5008 #define PTRACE_ENABLE_TE 0x5009 #define PTRACE_DISABLE_TE 0x5010 #define PTRACE_TE_ABORT_RAND 0x5011 /* * The numbers chosen here are somewhat arbitrary but absolutely MUST * not overlap with any of the number assigned in <linux/ptrace.h>. */ #define PTRACE_SINGLEBLOCK 12 /* resume execution until next branch */ /* * PT_PROT definition is loosely based on hppa bsd definition in * gdb/hppab-nat.c */ #define PTRACE_PROT 21 typedef enum { ptprot_set_access_watchpoint, ptprot_set_write_watchpoint, ptprot_disable_watchpoint } ptprot_flags; typedef struct { unsigned long lowaddr; unsigned long hiaddr; ptprot_flags prot; } ptprot_area; /* Sequence of bytes for breakpoint illegal instruction. */ #define S390_BREAKPOINT {0x0,0x1} #define S390_BREAKPOINT_U16 ((__u16)0x0001) #define S390_SYSCALL_OPCODE ((__u16)0x0a00) #define S390_SYSCALL_SIZE 2 /* * The user_regs_struct defines the way the user registers are * store on the stack for signal handling. */ struct user_regs_struct { psw_t psw; unsigned long gprs[NUM_GPRS]; unsigned int acrs[NUM_ACRS]; unsigned long orig_gpr2; s390_fp_regs fp_regs; /* * These per registers are in here so that gdb can modify them * itself as there is no "official" ptrace interface for hardware * watchpoints. This is the way intel does it. */ per_struct per_info; unsigned long ieee_instruction_pointer; /* obsolete, always 0 */ }; #endif /* __ASSEMBLY__ */ #endif /* _UAPI_S390_PTRACE_H */ PK ! W��� � include/uapi/asm/ucontext.hnu �[��� /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ /* * S390 version * * Derived from "include/asm-i386/ucontext.h" */ #ifndef _ASM_S390_UCONTEXT_H #define _ASM_S390_UCONTEXT_H #define UC_GPRS_HIGH 1 /* uc_mcontext_ext has valid high gprs */ #define UC_VXRS 2 /* uc_mcontext_ext has valid vector regs */ /* * The struct ucontext_extended describes how the registers are stored * on a rt signal frame. Please note that the structure is not fixed, * if new CPU registers are added to the user state the size of the * struct ucontext_extended will increase. */ struct ucontext_extended { unsigned long uc_flags; struct ucontext *uc_link; stack_t uc_stack; _sigregs uc_mcontext; sigset_t uc_sigmask; /* Allow for uc_sigmask growth. Glibc uses a 1024-bit sigset_t. */ unsigned char __unused[128 - sizeof(sigset_t)]; _sigregs_ext uc_mcontext_ext; }; struct ucontext { unsigned long uc_flags; struct ucontext *uc_link; stack_t uc_stack; _sigregs uc_mcontext; sigset_t uc_sigmask; /* Allow for uc_sigmask growth. Glibc uses a 1024-bit sigset_t. */ unsigned char __unused[128 - sizeof(sigset_t)]; }; #endif /* !_ASM_S390_UCONTEXT_H */ PK ! ;�{� � "