Skip to content

Commit 6376402

Browse files
hcahcaAlexander Gordeev
authored andcommitted
s390/ptrace: remove PSW_DEFAULT_KEY from uapi
Move PSW_DEFAULT_KEY from uapi/asm/ptrace.h to asm/ptrace.h. This is possible, since it depends on PAGE_DEFAULT_ACC which is not part of uapi. Or in other words: this define cannot be used without error. Therefore remove it from uapi. Acked-by: Alexander Gordeev <agordeev@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
1 parent d15e431 commit 6376402

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

arch/s390/include/asm/page.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
#define PAGE_SHIFT _PAGE_SHIFT
2020
#define PAGE_SIZE _PAGE_SIZE
2121
#define PAGE_MASK _PAGE_MASK
22-
#define PAGE_DEFAULT_ACC 0
22+
#define PAGE_DEFAULT_ACC _AC(0, UL)
2323
/* storage-protection override */
2424
#define PAGE_SPO_ACC 9
2525
#define PAGE_DEFAULT_KEY (PAGE_DEFAULT_ACC << 4)

arch/s390/include/asm/ptrace.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
#define _PIF_GUEST_FAULT BIT(PIF_GUEST_FAULT)
2424
#define _PIF_FTRACE_FULL_REGS BIT(PIF_FTRACE_FULL_REGS)
2525

26+
#define PSW_DEFAULT_KEY ((PAGE_DEFAULT_ACC) << 52)
27+
2628
#ifndef __ASSEMBLY__
2729

2830
#define PSW_KERNEL_BITS (PSW_DEFAULT_KEY | PSW_MASK_BASE | PSW_ASC_HOME | \

arch/s390/include/uapi/asm/ptrace.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -237,8 +237,6 @@ typedef struct {
237237
#define PSW_ADDR_AMODE 0x80000000UL
238238
#define PSW_ADDR_INSN 0x7FFFFFFFUL
239239

240-
#define PSW_DEFAULT_KEY (((unsigned long) PAGE_DEFAULT_ACC) << 20)
241-
242240
#define PSW_ASC_PRIMARY 0x00000000UL
243241
#define PSW_ASC_ACCREG 0x00004000UL
244242
#define PSW_ASC_SECONDARY 0x00008000UL
@@ -267,8 +265,6 @@ typedef struct {
267265
#define PSW_ADDR_AMODE 0x0000000000000000UL
268266
#define PSW_ADDR_INSN 0xFFFFFFFFFFFFFFFFUL
269267

270-
#define PSW_DEFAULT_KEY (((unsigned long) PAGE_DEFAULT_ACC) << 52)
271-
272268
#define PSW_ASC_PRIMARY 0x0000000000000000UL
273269
#define PSW_ASC_ACCREG 0x0000400000000000UL
274270
#define PSW_ASC_SECONDARY 0x0000800000000000UL

0 commit comments

Comments
 (0)