OpenCores
URL https://opencores.org/ocsvn/scarts/scarts/trunk

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-newlib/] [newlib-1.17.0/] [libgloss/] [sparc/] [libsys/] [template_r.S] - Blame information for rev 9

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 9 jlechner
/* reentrant system call template */
2
 
3
/* Lots of system calls are trivial functions, so we build their source files
4
   from a template.  New syscalls can be added simply by editing the
5
   Makefile!
6
 
7
   The system calls aren't necessarily reentrant.  If we were being used in
8
   an embedded system they could be.  Reentrant syscalls are also used,
9
   however, to provide ANSI C namespace clean access to the host o/s.
10
 
11
   Usage: Compile this file with "func" set to the name of the syscall.  */
12
 
13
#include "syscallasm.h"
14
 
15
#define concat(a,b)     a##b
16
#define concat3(a,b,c)  a##b##c
17
#define makesys(a)      concat (SYS_, a)
18
#define make_r_fn(a)    concat3 (_, a, _r)
19
 
20
/* The leading _'s get turned into #'s by the Makefile.  */
21
 
22
_ifdef REENT
23
        defsyscall_r (make_r_fn (func), makesys (func))
24
_else
25
        defsyscall (func, makesys (func))
26
_endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.