aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/include/asm')
-rw-r--r--arch/powerpc/include/asm/book3s/64/pgtable.h1
-rw-r--r--arch/powerpc/include/asm/syscall.h10
2 files changed, 10 insertions, 1 deletions
diff --git a/arch/powerpc/include/asm/book3s/64/pgtable.h b/arch/powerpc/include/asm/book3s/64/pgtable.h
index 62e6ea0a7650..8308f32e9782 100644
--- a/arch/powerpc/include/asm/book3s/64/pgtable.h
+++ b/arch/powerpc/include/asm/book3s/64/pgtable.h
@@ -90,7 +90,6 @@
90#define _PAGE_SOFT_DIRTY _RPAGE_SW3 /* software: software dirty tracking */ 90#define _PAGE_SOFT_DIRTY _RPAGE_SW3 /* software: software dirty tracking */
91#define _PAGE_SPECIAL _RPAGE_SW2 /* software: special page */ 91#define _PAGE_SPECIAL _RPAGE_SW2 /* software: special page */
92#define _PAGE_DEVMAP _RPAGE_SW1 /* software: ZONE_DEVICE page */ 92#define _PAGE_DEVMAP _RPAGE_SW1 /* software: ZONE_DEVICE page */
93#define __HAVE_ARCH_PTE_DEVMAP
94 93
95/* 94/*
96 * Drivers request for cache inhibited pte mapping using _PAGE_NO_CACHE 95 * Drivers request for cache inhibited pte mapping using _PAGE_NO_CACHE
diff --git a/arch/powerpc/include/asm/syscall.h b/arch/powerpc/include/asm/syscall.h
index 81abcf6a737b..38d62acfdce7 100644
--- a/arch/powerpc/include/asm/syscall.h
+++ b/arch/powerpc/include/asm/syscall.h
@@ -35,6 +35,16 @@ static inline void syscall_rollback(struct task_struct *task,
35 regs->gpr[3] = regs->orig_gpr3; 35 regs->gpr[3] = regs->orig_gpr3;
36} 36}
37 37
38static inline long syscall_get_error(struct task_struct *task,
39 struct pt_regs *regs)
40{
41 /*
42 * If the system call failed,
43 * regs->gpr[3] contains a positive ERRORCODE.
44 */
45 return (regs->ccr & 0x10000000UL) ? -regs->gpr[3] : 0;
46}
47
38static inline long syscall_get_return_value(struct task_struct *task, 48static inline long syscall_get_return_value(struct task_struct *task,
39 struct pt_regs *regs) 49 struct pt_regs *regs)
40{ 50{