Path: blob/master/arch/cris/arch-v10/kernel/entry.S
15125 views
/*1* linux/arch/cris/entry.S2*3* Copyright (C) 2000, 2001, 2002 Axis Communications AB4*5* Authors: Bjorn Wesen ([email protected])6*/78/*9* entry.S contains the system-call and fault low-level handling routines.10*11* NOTE: This code handles signal-recognition, which happens every time12* after a timer-interrupt and after each system call.13*14* Stack layout in 'ret_from_system_call':15* ptrace needs to have all regs on the stack.16* if the order here is changed, it needs to be17* updated in fork.c:copy_process, signal.c:do_signal,18* ptrace.c and ptrace.h19*20*/2122#include <linux/linkage.h>23#include <linux/sys.h>24#include <asm/unistd.h>25#include <arch/sv_addr_ag.h>26#include <asm/errno.h>27#include <asm/thread_info.h>28#include <asm/asm-offsets.h>29#include <asm/page.h>30#include <asm/pgtable.h>3132;; functions exported from this file3334.globl system_call35.globl ret_from_intr36.globl ret_from_fork37.globl resume38.globl multiple_interrupt39.globl hwbreakpoint40.globl IRQ1_interrupt41.globl spurious_interrupt42.globl hw_bp_trigs43.globl mmu_bus_fault44.globl do_sigtrap45.globl gdb_handle_breakpoint46.globl sys_call_table4748;; below are various parts of system_call which are not in the fast-path4950#ifdef CONFIG_PREEMPT51; Check if preemptive kernel scheduling should be done52_resume_kernel:53di54; Load current task struct55movs.w -8192, $r0 ; THREAD_SIZE = 819256and.d $sp, $r057move.d [$r0+TI_preempt_count], $r10 ; Preemption disabled?58bne _Rexit59nop60_need_resched:61move.d [$r0+TI_flags], $r1062btstq TIF_NEED_RESCHED, $r10 ; Check if need_resched is set63bpl _Rexit64nop65; Ok, lets's do some preemptive kernel scheduling66jsr preempt_schedule_irq67; Load new task struct68movs.w -8192, $r0 ; THREAD_SIZE = 819269and.d $sp, $r070; One more time (with new task)71ba _need_resched72nop73#else74#define _resume_kernel _Rexit75#endif7677; Called at exit from fork. schedule_tail must be called to drop78; spinlock if CONFIG_PREEMPT79ret_from_fork:80jsr schedule_tail81ba ret_from_sys_call82nop8384ret_from_intr:85;; check for resched if preemptive kernel or if we're going back to user-mode86;; this test matches the user_regs(regs) macro87;; we cannot simply test $dccr, because that does not necessarily88;; reflect what mode we'll return into.8990move.d [$sp + PT_dccr], $r0; regs->dccr91btstq 8, $r0 ; U-flag92bpl _resume_kernel93; Note that di below is in delay slot9495_resume_userspace:96di ; so need_resched and sigpending don't change9798movs.w -8192, $r0 ; THREAD_SIZE == 819299and.d $sp, $r0100101move.d [$r0+TI_flags], $r10 ; current->work102and.d _TIF_WORK_MASK, $r10 ; is there any work to be done on return103bne _work_pending104nop105ba _Rexit106nop107108;; The system_call is called by a BREAK instruction, which works like109;; an interrupt call but it stores the return PC in BRP instead of IRP.110;; Since we dont really want to have two epilogues (one for system calls111;; and one for interrupts) we push the contents of BRP instead of IRP in the112;; system call prologue, to make it look like an ordinary interrupt on the113;; stackframe.114;;115;; Since we can't have system calls inside interrupts, it should not matter116;; that we don't stack IRP.117;;118;; In r9 we have the wanted syscall number. Arguments come in r10,r11,r12,r13,mof,srp119;;120;; This function looks on the _surface_ like spaghetti programming, but it's121;; really designed so that the fast-path does not force cache-loading of non-used122;; instructions. Only the non-common cases cause the outlined code to run..123124system_call:125;; stack-frame similar to the irq heads, which is reversed in ret_from_sys_call126move $brp,[$sp=$sp-16]; instruction pointer and room for a fake SBFS frame127push $srp128push $dccr129push $mof130subq 14*4, $sp ; make room for r0-r13131movem $r13, [$sp] ; push r0-r13132push $r10 ; push orig_r10133clear.d [$sp=$sp-4] ; frametype == 0, normal stackframe134135movs.w -ENOSYS, $r0136move.d $r0, [$sp+PT_r10] ; put the default return value in r10 in the frame137138;; check if this process is syscall-traced139140movs.w -8192, $r0 ; THREAD_SIZE == 8192141and.d $sp, $r0142143move.d [$r0+TI_flags], $r0144btstq TIF_SYSCALL_TRACE, $r0145bmi _syscall_trace_entry146nop147148_syscall_traced:149150;; check for sanity in the requested syscall number151152cmpu.w NR_syscalls, $r9153bcc ret_from_sys_call154lslq 2, $r9 ; multiply by 4, in the delay slot155156;; as a bonus 7th parameter, we give the location on the stack157;; of the register structure itself. some syscalls need this.158159push $sp160161;; the parameter carrying registers r10, r11, r12 and 13 are intact.162;; the fifth and sixth parameters (if any) was in mof and srp163;; respectively, and we need to put them on the stack.164165push $srp166push $mof167168jsr [$r9+sys_call_table] ; actually do the system call169addq 3*4, $sp ; pop the mof, srp and regs parameters170move.d $r10, [$sp+PT_r10] ; save the return value171172moveq 1, $r9 ; "parameter" to ret_from_sys_call to show it was a sys call173174;; fall through into ret_from_sys_call to return175176ret_from_sys_call:177;; r9 is a parameter - if >=1 we came from a syscall, if 0, from an irq178179;; get the current task-struct pointer (see top for defs)180181movs.w -8192, $r0 ; THREAD_SIZE == 8192182and.d $sp, $r0183184di ; make sure need_resched and sigpending don't change185move.d [$r0+TI_flags],$r1186and.d _TIF_ALLWORK_MASK, $r1187bne _syscall_exit_work188nop189190_Rexit:191;; this epilogue MUST match the prologues in multiple_interrupt, irq.h and ptregs.h192pop $r10 ; frametype193bne _RBFexit ; was not CRIS_FRAME_NORMAL, handle otherwise194addq 4, $sp ; skip orig_r10, in delayslot195movem [$sp+], $r13 ; registers r0-r13196pop $mof ; multiply overflow register197pop $dccr ; condition codes198pop $srp ; subroutine return pointer199;; now we have a 4-word SBFS frame which we do not want to restore200;; using RBF since it was not stacked with SBFS. instead we would like to201;; just get the PC value to restart it with, and skip the rest of202;; the frame.203;; Also notice that it's important to use instructions here that204;; keep the interrupts disabled (since we've already popped DCCR)205move [$sp=$sp+16], $p8; pop the SBFS frame from the sp206jmpu [$sp-16] ; return through the irp field in the sbfs frame207208_RBFexit:209movem [$sp+], $r13 ; registers r0-r13, in delay slot210pop $mof ; multiply overflow register211pop $dccr ; condition codes212pop $srp ; subroutine return pointer213rbf [$sp+] ; return by popping the CPU status214215;; We get here after doing a syscall if extra work might need to be done216;; perform syscall exit tracing if needed217218_syscall_exit_work:219;; $r0 contains current at this point and irq's are disabled220221move.d [$r0+TI_flags], $r1222btstq TIF_SYSCALL_TRACE, $r1223bpl _work_pending224nop225226ei227228move.d $r9, $r1 ; preserve r9229jsr do_syscall_trace230move.d $r1, $r9231232ba _resume_userspace233nop234235_work_pending:236move.d [$r0+TI_flags], $r1237btstq TIF_NEED_RESCHED, $r1238bpl _work_notifysig ; was neither trace nor sched, must be signal/notify239nop240241_work_resched:242move.d $r9, $r1 ; preserve r9243jsr schedule244move.d $r1, $r9245di246247move.d [$r0+TI_flags], $r1248and.d _TIF_WORK_MASK, $r1; ignore the syscall trace counter249beq _Rexit250nop251btstq TIF_NEED_RESCHED, $r1252bmi _work_resched ; current->work.need_resched253nop254255_work_notifysig:256;; deal with pending signals and notify-resume requests257258move.d $r9, $r10 ; do_notify_resume syscall/irq param259move.d $sp, $r11 ; the regs param260move.d $r1, $r12 ; the thread_info_flags parameter261jsr do_notify_resume262263ba _Rexit264nop265266;; We get here as a sidetrack when we've entered a syscall with the267;; trace-bit set. We need to call do_syscall_trace and then continue268;; with the call.269270_syscall_trace_entry:271;; PT_r10 in the frame contains -ENOSYS as required, at this point272273jsr do_syscall_trace274275;; now re-enter the syscall code to do the syscall itself276;; we need to restore $r9 here to contain the wanted syscall, and277;; the other parameter-bearing registers278279move.d [$sp+PT_r9], $r9280move.d [$sp+PT_orig_r10], $r10 ; PT_r10 is already filled with -ENOSYS.281move.d [$sp+PT_r11], $r11282move.d [$sp+PT_r12], $r12283move.d [$sp+PT_r13], $r13284move [$sp+PT_mof], $mof285move [$sp+PT_srp], $srp286287ba _syscall_traced288nop289290;; resume performs the actual task-switching, by switching stack pointers291;; input arguments: r10 = prev, r11 = next, r12 = thread offset in task struct292;; returns old current in r10293;;294;; TODO: see the i386 version. The switch_to which calls resume in our version295;; could really be an inline asm of this.296297resume:298push $srp ; we keep the old/new PC on the stack299add.d $r12, $r10 ; r10 = current tasks tss300move $dccr, [$r10+THREAD_dccr]; save irq enable state301di302303move $usp, [$r10+ THREAD_usp] ; save user-mode stackpointer304305;; See copy_thread for the reason why register R9 is saved.306subq 10*4, $sp307movem $r9, [$sp] ; save non-scratch registers and R9.308309move.d $sp, [$r10+THREAD_ksp] ; save the kernel stack pointer for the old task310move.d $sp, $r10 ; return last running task in r10311and.d -8192, $r10 ; get thread_info from stackpointer312move.d [$r10+TI_task], $r10 ; get task313add.d $r12, $r11 ; find the new tasks tss314move.d [$r11+THREAD_ksp], $sp ; switch into the new stackframe by restoring kernel sp315316movem [$sp+], $r9 ; restore non-scratch registers and R9.317318move [$r11+THREAD_usp], $usp ; restore user-mode stackpointer319320move [$r11+THREAD_dccr], $dccr ; restore irq enable status321jump [$sp+] ; restore PC322323;; This is the MMU bus fault handler.324;; It needs to stack the CPU status and overall is different325;; from the other interrupt handlers.326327mmu_bus_fault:328;; For refills we try to do a quick page table lookup. If it is329;; a real fault we let the mm subsystem handle it.330331;; the first longword in the sbfs frame was the interrupted PC332;; which fits nicely with the "IRP" slot in pt_regs normally used to333;; contain the return address. used by Oops to print kernel errors.334sbfs [$sp=$sp-16] ; push the internal CPU status335push $dccr336di337subq 2*4, $sp338movem $r1, [$sp]339move.d [R_MMU_CAUSE], $r1340;; ETRAX 100LX TR89 bugfix: if the second half of an unaligned341;; write causes a MMU-fault, it will not be restarted correctly.342;; This could happen if a write crosses a page-boundary and the343;; second page is not yet COW'ed or even loaded. The workaround344;; is to clear the unaligned bit in the CPU status record, so345;; that the CPU will rerun both the first and second halves of346;; the instruction. This will not have any sideeffects unless347;; the first half goes to any device or memory that can't be348;; written twice, and which is mapped through the MMU.349;;350;; We only need to do this for writes.351btstq 8, $r1 ; Write access?352bpl 1f353nop354move.d [$sp+16], $r0 ; Clear unaligned bit in csrinstr355and.d ~(1<<5), $r0356move.d $r0, [$sp+16]3571: btstq 12, $r1 ; Refill?358bpl 2f359lsrq 24, $r1 ; Get PGD index (bit 24-31)360move.d [current_pgd], $r0 ; PGD for the current process361move.d [$r0+$r1.d], $r0 ; Get PMD362beq 2f363nop364and.w PAGE_MASK, $r0 ; Remove PMD flags365move.d [R_MMU_CAUSE], $r1366lsrq PAGE_SHIFT, $r1367and.d 0x7ff, $r1 ; Get PTE index into PGD (bit 13-23)368move.d [$r0+$r1.d], $r1 ; Get PTE369beq 2f370nop371;; Store in TLB372move.d $r1, [R_TLB_LO]373;; Return374movem [$sp+], $r1375pop $dccr376rbf [$sp+] ; return by popping the CPU status3773782: ; PMD or PTE missing, let the mm subsystem fix it up.379movem [$sp+], $r1380pop $dccr381382; Ok, not that easy, pass it on to the mm subsystem383; The MMU status record is now on the stack384push $srp ; make a stackframe similar to pt_regs385push $dccr386push $mof387di388subq 14*4, $sp389movem $r13, [$sp]390push $r10 ; dummy orig_r10391moveq 1, $r10392push $r10 ; frametype == 1, BUSFAULT frame type393394move.d $sp, $r10 ; pt_regs argument to handle_mmu_bus_fault395396jsr handle_mmu_bus_fault ; in arch/cris/arch-v10/mm/fault.c397398;; now we need to return through the normal path, we cannot just399;; do the RBFexit since we might have killed off the running400;; process due to a SEGV, scheduled due to a page blocking or401;; whatever.402403moveq 0, $r9 ; busfault is equivalent to an irq404405ba ret_from_intr406nop407408;; special handlers for breakpoint and NMI409hwbreakpoint:410push $dccr411di412push $r10413push $r11414move.d [hw_bp_trig_ptr],$r10415move $brp,$r11416move.d $r11,[$r10+]417move.d $r10,[hw_bp_trig_ptr]4181: pop $r11419pop $r10420pop $dccr421retb422nop423424IRQ1_interrupt:425;; this prologue MUST match the one in irq.h and the struct in ptregs.h!!!426move $brp,[$sp=$sp-16]; instruction pointer and room for a fake SBFS frame427push $srp428push $dccr429push $mof430di431subq 14*4, $sp432movem $r13, [$sp]433push $r10 ; push orig_r10434clear.d [$sp=$sp-4] ; frametype == 0, normal frame435436;; If there is a glitch on the NMI pin shorter than ~100ns437;; (i.e. non-active by the time we get here) then the nmi_pin bit438;; in R_IRQ_MASK0_RD will already be cleared. The watchdog_nmi bit439;; is cleared by us however (when feeding the watchdog), which is why440;; we use that bit to determine what brought us here.441442move.d [R_IRQ_MASK0_RD], $r1 ; External NMI or watchdog?443and.d (1<<30), $r1444bne wdog445move.d $sp, $r10446jsr handle_nmi447setf m ; Enable NMI again448ba _Rexit ; Return the standard way449nop450wdog:451#if defined(CONFIG_ETRAX_WATCHDOG) && !defined(CONFIG_SVINTO_SIM)452;; Check if we're waiting for reset to happen, as signalled by453;; hard_reset_now setting cause_of_death to a magic value. If so, just454;; get stuck until reset happens.455.comm cause_of_death, 4 ;; Don't declare this anywhere.456move.d [cause_of_death], $r10457cmp.d 0xbedead, $r10458_killed_by_death:459beq _killed_by_death460nop461462;; We'll see this in ksymoops dumps.463Watchdog_bite:464465#ifdef CONFIG_ETRAX_WATCHDOG_NICE_DOGGY466;; We just restart the watchdog here to be sure we dont get467;; hit while printing the watchdogmsg below468;; This restart is compatible with the rest of the C-code, so469;; the C-code can keep restarting the watchdog after this point.470;; The non-NICE_DOGGY code below though, disables the possibility471;; to restart since it changes the watchdog key, to avoid any472;; buggy loops etc. keeping the watchdog alive after this.473jsr reset_watchdog474#else475476;; We need to extend the 3.3ms after the NMI at watchdog bite, so we have477;; time for an oops-dump over a 115k2 serial wire. Another 100ms should do.478479;; Change the watchdog key to an arbitrary 3-bit value and restart the480;; watchdog.481#define WD_INIT 2482moveq IO_FIELD (R_WATCHDOG, key, WD_INIT), $r10483move.d R_WATCHDOG, $r11484485move.d $r10, [$r11]486moveq IO_FIELD (R_WATCHDOG, key, \487IO_EXTRACT (R_WATCHDOG, key, \488IO_MASK (R_WATCHDOG, key)) \489^ WD_INIT) \490| IO_STATE (R_WATCHDOG, enable, start), $r10491move.d $r10, [$r11]492493#endif494495;; Note that we don't do "setf m" here (or after two necessary NOPs),496;; since *not* doing that saves us from re-entrancy checks. We don't want497;; to get here again due to possible subsequent NMIs; we want the watchdog498;; to reset us.499500move.d _watchdogmsg,$r10501jsr printk502503move.d $sp, $r10504jsr watchdog_bite_hook505506;; This nop is here so we see the "Watchdog_bite" label in ksymoops dumps507;; rather than "spurious_interrupt".508nop509;; At this point we drop down into spurious_interrupt, which will do a510;; hard reset.511512.section .rodata,"a"513_watchdogmsg:514.ascii "Oops: bitten by watchdog\n\0"515.previous516517#endif /* CONFIG_ETRAX_WATCHDOG and not CONFIG_SVINTO_SIM */518519spurious_interrupt:520di521jump hard_reset_now522523;; this handles the case when multiple interrupts arrive at the same time524;; we jump to the first set interrupt bit in a priority fashion525;; the hardware will call the unserved interrupts after the handler finishes526527multiple_interrupt:528;; this prologue MUST match the one in irq.h and the struct in ptregs.h!!!529move $irp,[$sp=$sp-16]; instruction pointer and room for a fake SBFS frame530push $srp531push $dccr532push $mof533di534subq 14*4, $sp535movem $r13, [$sp]536push $r10 ; push orig_r10537clear.d [$sp=$sp-4] ; frametype == 0, normal frame538539move.d $sp, $r10540jsr do_multiple_IRQ541542jump ret_from_intr543544do_sigtrap:545;;546;; SIGTRAP the process that executed the break instruction.547;; Make a frame that Rexit in entry.S expects.548;;549move $brp, [$sp=$sp-16] ; Push BRP while faking a cpu status record.550push $srp ; Push subroutine return pointer.551push $dccr ; Push condition codes.552push $mof ; Push multiply overflow reg.553di ; Need to disable irq's at this point.554subq 14*4, $sp ; Make room for r0-r13.555movem $r13, [$sp] ; Push the r0-r13 registers.556push $r10 ; Push orig_r10.557clear.d [$sp=$sp-4] ; Frametype - this is a normal stackframe.558559movs.w -8192,$r9 ; THREAD_SIZE == 8192560and.d $sp, $r9561move.d [$r9+TI_task], $r10562move.d [$r10+TASK_pid], $r10 ; current->pid as arg1.563moveq 5, $r11 ; SIGTRAP as arg2.564jsr sys_kill565jump ret_from_intr ; Use the return routine for interrupts.566567gdb_handle_breakpoint:568push $dccr569push $r0570#ifdef CONFIG_ETRAX_KGDB571move $dccr, $r0 ; U-flag not affected by previous insns.572btstq 8, $r0 ; Test the U-flag.573bmi _ugdb_handle_breakpoint ; Go to user mode debugging.574nop ; Empty delay slot (cannot pop r0 here).575pop $r0 ; Restore r0.576ba kgdb_handle_breakpoint ; Go to kernel debugging.577pop $dccr ; Restore dccr in delay slot.578#endif579580_ugdb_handle_breakpoint:581move $brp, $r0 ; Use r0 temporarily for calculation.582subq 2, $r0 ; Set to address of previous instruction.583move $r0, $brp584pop $r0 ; Restore r0.585ba do_sigtrap ; SIGTRAP the offending process.586pop $dccr ; Restore dccr in delay slot.587588.global kernel_execve589kernel_execve:590move.d __NR_execve, $r9591break 13592ret593nop594595.data596597hw_bp_trigs:598.space 64*4599hw_bp_trig_ptr:600.dword hw_bp_trigs601602.section .rodata,"a"603sys_call_table:604.long sys_restart_syscall /* 0 - old "setup()" system call, used for restarting */605.long sys_exit606.long sys_fork607.long sys_read608.long sys_write609.long sys_open /* 5 */610.long sys_close611.long sys_waitpid612.long sys_creat613.long sys_link614.long sys_unlink /* 10 */615.long sys_execve616.long sys_chdir617.long sys_time618.long sys_mknod619.long sys_chmod /* 15 */620.long sys_lchown16621.long sys_ni_syscall /* old break syscall holder */622.long sys_stat623.long sys_lseek624.long sys_getpid /* 20 */625.long sys_mount626.long sys_oldumount627.long sys_setuid16628.long sys_getuid16629.long sys_stime /* 25 */630.long sys_ptrace631.long sys_alarm632.long sys_fstat633.long sys_pause634.long sys_utime /* 30 */635.long sys_ni_syscall /* old stty syscall holder */636.long sys_ni_syscall /* old gtty syscall holder */637.long sys_access638.long sys_nice639.long sys_ni_syscall /* 35 old ftime syscall holder */640.long sys_sync641.long sys_kill642.long sys_rename643.long sys_mkdir644.long sys_rmdir /* 40 */645.long sys_dup646.long sys_pipe647.long sys_times648.long sys_ni_syscall /* old prof syscall holder */649.long sys_brk /* 45 */650.long sys_setgid16651.long sys_getgid16652.long sys_signal653.long sys_geteuid16654.long sys_getegid16 /* 50 */655.long sys_acct656.long sys_umount /* recycled never used phys( */657.long sys_ni_syscall /* old lock syscall holder */658.long sys_ioctl659.long sys_fcntl /* 55 */660.long sys_ni_syscall /* old mpx syscall holder */661.long sys_setpgid662.long sys_ni_syscall /* old ulimit syscall holder */663.long sys_ni_syscall /* old sys_olduname holder */664.long sys_umask /* 60 */665.long sys_chroot666.long sys_ustat667.long sys_dup2668.long sys_getppid669.long sys_getpgrp /* 65 */670.long sys_setsid671.long sys_sigaction672.long sys_sgetmask673.long sys_ssetmask674.long sys_setreuid16 /* 70 */675.long sys_setregid16676.long sys_sigsuspend677.long sys_sigpending678.long sys_sethostname679.long sys_setrlimit /* 75 */680.long sys_old_getrlimit681.long sys_getrusage682.long sys_gettimeofday683.long sys_settimeofday684.long sys_getgroups16 /* 80 */685.long sys_setgroups16686.long sys_select /* was old_select in Linux/E100 */687.long sys_symlink688.long sys_lstat689.long sys_readlink /* 85 */690.long sys_uselib691.long sys_swapon692.long sys_reboot693.long sys_old_readdir694.long sys_old_mmap /* 90 */695.long sys_munmap696.long sys_truncate697.long sys_ftruncate698.long sys_fchmod699.long sys_fchown16 /* 95 */700.long sys_getpriority701.long sys_setpriority702.long sys_ni_syscall /* old profil syscall holder */703.long sys_statfs704.long sys_fstatfs /* 100 */705.long sys_ni_syscall /* sys_ioperm in i386 */706.long sys_socketcall707.long sys_syslog708.long sys_setitimer709.long sys_getitimer /* 105 */710.long sys_newstat711.long sys_newlstat712.long sys_newfstat713.long sys_ni_syscall /* old sys_uname holder */714.long sys_ni_syscall /* sys_iopl in i386 */715.long sys_vhangup716.long sys_ni_syscall /* old "idle" system call */717.long sys_ni_syscall /* vm86old in i386 */718.long sys_wait4719.long sys_swapoff /* 115 */720.long sys_sysinfo721.long sys_ipc722.long sys_fsync723.long sys_sigreturn724.long sys_clone /* 120 */725.long sys_setdomainname726.long sys_newuname727.long sys_ni_syscall /* sys_modify_ldt */728.long sys_adjtimex729.long sys_mprotect /* 125 */730.long sys_sigprocmask731.long sys_ni_syscall /* old "create_module" */732.long sys_init_module733.long sys_delete_module734.long sys_ni_syscall /* 130: old "get_kernel_syms" */735.long sys_quotactl736.long sys_getpgid737.long sys_fchdir738.long sys_bdflush739.long sys_sysfs /* 135 */740.long sys_personality741.long sys_ni_syscall /* for afs_syscall */742.long sys_setfsuid16743.long sys_setfsgid16744.long sys_llseek /* 140 */745.long sys_getdents746.long sys_select747.long sys_flock748.long sys_msync749.long sys_readv /* 145 */750.long sys_writev751.long sys_getsid752.long sys_fdatasync753.long sys_sysctl754.long sys_mlock /* 150 */755.long sys_munlock756.long sys_mlockall757.long sys_munlockall758.long sys_sched_setparam759.long sys_sched_getparam /* 155 */760.long sys_sched_setscheduler761.long sys_sched_getscheduler762.long sys_sched_yield763.long sys_sched_get_priority_max764.long sys_sched_get_priority_min /* 160 */765.long sys_sched_rr_get_interval766.long sys_nanosleep767.long sys_mremap768.long sys_setresuid16769.long sys_getresuid16 /* 165 */770.long sys_ni_syscall /* sys_vm86 */771.long sys_ni_syscall /* Old sys_query_module */772.long sys_poll773.long sys_nfsservctl774.long sys_setresgid16 /* 170 */775.long sys_getresgid16776.long sys_prctl777.long sys_rt_sigreturn778.long sys_rt_sigaction779.long sys_rt_sigprocmask /* 175 */780.long sys_rt_sigpending781.long sys_rt_sigtimedwait782.long sys_rt_sigqueueinfo783.long sys_rt_sigsuspend784.long sys_pread64 /* 180 */785.long sys_pwrite64786.long sys_chown16787.long sys_getcwd788.long sys_capget789.long sys_capset /* 185 */790.long sys_sigaltstack791.long sys_sendfile792.long sys_ni_syscall /* streams1 */793.long sys_ni_syscall /* streams2 */794.long sys_vfork /* 190 */795.long sys_getrlimit796.long sys_mmap2797.long sys_truncate64798.long sys_ftruncate64799.long sys_stat64 /* 195 */800.long sys_lstat64801.long sys_fstat64802.long sys_lchown803.long sys_getuid804.long sys_getgid /* 200 */805.long sys_geteuid806.long sys_getegid807.long sys_setreuid808.long sys_setregid809.long sys_getgroups /* 205 */810.long sys_setgroups811.long sys_fchown812.long sys_setresuid813.long sys_getresuid814.long sys_setresgid /* 210 */815.long sys_getresgid816.long sys_chown817.long sys_setuid818.long sys_setgid819.long sys_setfsuid /* 215 */820.long sys_setfsgid821.long sys_pivot_root822.long sys_mincore823.long sys_madvise824.long sys_getdents64 /* 220 */825.long sys_fcntl64826.long sys_ni_syscall /* reserved for TUX */827.long sys_ni_syscall828.long sys_gettid829.long sys_readahead /* 225 */830.long sys_setxattr831.long sys_lsetxattr832.long sys_fsetxattr833.long sys_getxattr834.long sys_lgetxattr /* 230 */835.long sys_fgetxattr836.long sys_listxattr837.long sys_llistxattr838.long sys_flistxattr839.long sys_removexattr /* 235 */840.long sys_lremovexattr841.long sys_fremovexattr842.long sys_tkill843.long sys_sendfile64844.long sys_futex /* 240 */845.long sys_sched_setaffinity846.long sys_sched_getaffinity847.long sys_ni_syscall /* sys_set_thread_area */848.long sys_ni_syscall /* sys_get_thread_area */849.long sys_io_setup /* 245 */850.long sys_io_destroy851.long sys_io_getevents852.long sys_io_submit853.long sys_io_cancel854.long sys_fadvise64 /* 250 */855.long sys_ni_syscall856.long sys_exit_group857.long sys_lookup_dcookie858.long sys_epoll_create859.long sys_epoll_ctl /* 255 */860.long sys_epoll_wait861.long sys_remap_file_pages862.long sys_set_tid_address863.long sys_timer_create864.long sys_timer_settime /* 260 */865.long sys_timer_gettime866.long sys_timer_getoverrun867.long sys_timer_delete868.long sys_clock_settime869.long sys_clock_gettime /* 265 */870.long sys_clock_getres871.long sys_clock_nanosleep872.long sys_statfs64873.long sys_fstatfs64874.long sys_tgkill /* 270 */875.long sys_utimes876.long sys_fadvise64_64877.long sys_ni_syscall /* sys_vserver */878.long sys_ni_syscall /* sys_mbind */879.long sys_ni_syscall /* 275 sys_get_mempolicy */880.long sys_ni_syscall /* sys_set_mempolicy */881.long sys_mq_open882.long sys_mq_unlink883.long sys_mq_timedsend884.long sys_mq_timedreceive /* 280 */885.long sys_mq_notify886.long sys_mq_getsetattr887.long sys_ni_syscall /* reserved for kexec */888.long sys_waitid889.long sys_ni_syscall /* 285 */ /* available */890.long sys_add_key891.long sys_request_key892.long sys_keyctl893.long sys_ioprio_set894.long sys_ioprio_get /* 290 */895.long sys_inotify_init896.long sys_inotify_add_watch897.long sys_inotify_rm_watch898.long sys_migrate_pages899.long sys_openat /* 295 */900.long sys_mkdirat901.long sys_mknodat902.long sys_fchownat903.long sys_futimesat904.long sys_fstatat64 /* 300 */905.long sys_unlinkat906.long sys_renameat907.long sys_linkat908.long sys_symlinkat909.long sys_readlinkat /* 305 */910.long sys_fchmodat911.long sys_faccessat912.long sys_pselect6913.long sys_ppoll914.long sys_unshare /* 310 */915.long sys_set_robust_list916.long sys_get_robust_list917.long sys_splice918.long sys_sync_file_range919.long sys_tee /* 315 */920.long sys_vmsplice921.long sys_move_pages922.long sys_getcpu923.long sys_epoll_pwait924.long sys_utimensat /* 320 */925.long sys_signalfd926.long sys_timerfd_create927.long sys_eventfd928.long sys_fallocate929.long sys_timerfd_settime /* 325 */930.long sys_timerfd_gettime931.long sys_signalfd4932.long sys_eventfd2933.long sys_epoll_create1934.long sys_dup3 /* 330 */935.long sys_pipe2936.long sys_inotify_init1937.long sys_preadv938.long sys_pwritev939.long sys_setns /* 335 */940941/*942* NOTE!! This doesn't have to be exact - we just have943* to make sure we have _enough_ of the "sys_ni_syscall"944* entries. Don't panic if you notice that this hasn't945* been shrunk every time we add a new system call.946*/947948.rept NR_syscalls-(.-sys_call_table)/4949.long sys_ni_syscall950.endr951952953954