Subject: [PATCH 14/33] score: create head files syscalls.h uaccess.h ucontext.h unistd.h user.h
From da0c2143d701caf1baf23c8619c78a51ee901b13 Mon Sep 17 00:00:00 2001
From: Chen Liqin <[email protected]>
Date: Wed, 26 Aug 2009 10:05:03 +0800
Subject: [PATCH 14/33] score: create head files syscalls.h uaccess.h ucontext.h unistd.h user.h
Signed-off-by Chen Liqin <[email protected]>
--- arch/score/include/asm/syscalls.h | 11 +++++++++++ arch/score/include/asm/uaccess.h | 27 +++++++++++++++++++++++++++ arch/score/include/asm/ucontext.h | 1 + arch/score/include/asm/unistd.h | 8 ++++++++ arch/score/include/asm/user.h | 21 +++++++++++++++++++++ 5 files changed, 68 insertions(+), 0 deletions(-) create mode 100644 arch/score/include/asm/syscalls.h create mode 100644 arch/score/include/asm/uaccess.h create mode 100644 arch/score/include/asm/ucontext.h create mode 100644 arch/score/include/asm/unistd.h create mode 100644 arch/score/include/asm/user.h
arch/score/include/asm/syscalls.h new file +11 -0
@@ -0,0 +1,11 @@ +#ifndef _ASM_SCORE_SYSCALLS_H +#define _ASM_SCORE_SYSCALLS_H + +asmlinkage long score_clone (struct pt_regs *regs); +asmlinkage long score_execve (struct pt_regs *regs); +asmlinkage long score_sigaltstack (struct pt_regs *regs); +asmlinkage long score_rt_sigreturn (struct pt_regs *regs); + +#include <asm-generic/syscalls.h> + +#endif /* _ASM_SCORE_SYSCALLS_H */
arch/score/include/asm/uaccess.h new file +27 -0
@@ -0,0 +1,27 @@ +#ifndef _ASM_SCORE_UACCESS_H +#define _ASM_SCORE_UACCESS_H +/* +* Copyright (C) 2006 Atmark Techno, Inc. +* +* This file is subject to the terms and conditions of the GNU General Public +* License. See the file "COPYING" in the main directory of this archive +* for more details. +*/ +struct pt_regs ; +extern int fixup_exception (struct pt_regs *regs); + +#ifndef __ASSEMBLY__ + +#define __range_ok (addr, size) \ + ((((unsigned long __force)(addr) >= 0x80000000) \ + || ((unsigned long)(size) > 0x80000000) \ + || (((unsigned long __force)(addr) + (unsigned long)(size)) > 0x80000000))) + +#define __access_ok (addr, size) \ + (__range_ok((addr), (size)) == 0) + +#include <asm-generic/uaccess.h> + +#endif /* __ASSEMBLY__ */ + +#endif /* _ASM_SCORE_UACCESS_H */
arch/score/include/asm/ucontext.h new file +1 -0
@@ -0,0 +1 @@ +#include <asm-generic/ucontext.h>
arch/score/include/asm/unistd.h new file +8 -0
@@ -0,0 +1,8 @@ +#if !defined(_ASM_SCORE_UNISTD_H) || defined(__SYSCALL) +#define _ASM_SCORE_UNISTD_H + +#define __ARCH_HAVE_MMU + +#include <asm-generic/unistd.h> + +#endif /* _ASM_SCORE_UNISTD_H */
arch/score/include/asm/user.h new file +21 -0
@@ -0,0 +1,21 @@ +#ifndef _ASM_SCORE_USER_H +#define _ASM_SCORE_USER_H + +struct user_regs_struct { +unsigned long regs[32 ]; + +unsigned long cel; +unsigned long ceh; + +unsigned long sr0;/* cnt */ +unsigned long sr1;/* lcr */ +unsigned long sr2;/* scr */ + +unsigned long cp0_epc; +unsigned long cp0_ema; +unsigned long cp0_psr; +unsigned long cp0_ecr; +unsigned long cp0_condition; +}; + +#endif /* _ASM_SCORE_USER_H */
Signature · 1 line
1.6.2