aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-sparc/unistd.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-sparc/unistd.h')
-rw-r--r--include/asm-sparc/unistd.h130
1 files changed, 0 insertions, 130 deletions
diff --git a/include/asm-sparc/unistd.h b/include/asm-sparc/unistd.h
index f7827fa4cd5e..d5b2f8053b3b 100644
--- a/include/asm-sparc/unistd.h
+++ b/include/asm-sparc/unistd.h
@@ -329,136 +329,6 @@
329 * find a free slot in the 0-302 range. 329 * find a free slot in the 0-302 range.
330 */ 330 */
331 331
332#define _syscall0(type,name) \
333type name(void) \
334{ \
335long __res; \
336register long __g1 __asm__ ("g1") = __NR_##name; \
337__asm__ __volatile__ ("t 0x10\n\t" \
338 "bcc 1f\n\t" \
339 "mov %%o0, %0\n\t" \
340 "sub %%g0, %%o0, %0\n\t" \
341 "1:\n\t" \
342 : "=r" (__res)\
343 : "r" (__g1) \
344 : "o0", "cc"); \
345if (__res < -255 || __res >= 0) \
346 return (type) __res; \
347errno = -__res; \
348return -1; \
349}
350
351#define _syscall1(type,name,type1,arg1) \
352type name(type1 arg1) \
353{ \
354long __res; \
355register long __g1 __asm__ ("g1") = __NR_##name; \
356register long __o0 __asm__ ("o0") = (long)(arg1); \
357__asm__ __volatile__ ("t 0x10\n\t" \
358 "bcc 1f\n\t" \
359 "mov %%o0, %0\n\t" \
360 "sub %%g0, %%o0, %0\n\t" \
361 "1:\n\t" \
362 : "=r" (__res), "=&r" (__o0) \
363 : "1" (__o0), "r" (__g1) \
364 : "cc"); \
365if (__res < -255 || __res >= 0) \
366 return (type) __res; \
367errno = -__res; \
368return -1; \
369}
370
371#define _syscall2(type,name,type1,arg1,type2,arg2) \
372type name(type1 arg1,type2 arg2) \
373{ \
374long __res; \
375register long __g1 __asm__ ("g1") = __NR_##name; \
376register long __o0 __asm__ ("o0") = (long)(arg1); \
377register long __o1 __asm__ ("o1") = (long)(arg2); \
378__asm__ __volatile__ ("t 0x10\n\t" \
379 "bcc 1f\n\t" \
380 "mov %%o0, %0\n\t" \
381 "sub %%g0, %%o0, %0\n\t" \
382 "1:\n\t" \
383 : "=r" (__res), "=&r" (__o0) \
384 : "1" (__o0), "r" (__o1), "r" (__g1) \
385 : "cc"); \
386if (__res < -255 || __res >= 0) \
387 return (type) __res; \
388errno = -__res; \
389return -1; \
390}
391
392#define _syscall3(type,name,type1,arg1,type2,arg2,type3,arg3) \
393type name(type1 arg1,type2 arg2,type3 arg3) \
394{ \
395long __res; \
396register long __g1 __asm__ ("g1") = __NR_##name; \
397register long __o0 __asm__ ("o0") = (long)(arg1); \
398register long __o1 __asm__ ("o1") = (long)(arg2); \
399register long __o2 __asm__ ("o2") = (long)(arg3); \
400__asm__ __volatile__ ("t 0x10\n\t" \
401 "bcc 1f\n\t" \
402 "mov %%o0, %0\n\t" \
403 "sub %%g0, %%o0, %0\n\t" \
404 "1:\n\t" \
405 : "=r" (__res), "=&r" (__o0) \
406 : "1" (__o0), "r" (__o1), "r" (__o2), "r" (__g1) \
407 : "cc"); \
408if (__res < -255 || __res>=0) \
409 return (type) __res; \
410errno = -__res; \
411return -1; \
412}
413
414#define _syscall4(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4) \
415type name (type1 arg1, type2 arg2, type3 arg3, type4 arg4) \
416{ \
417long __res; \
418register long __g1 __asm__ ("g1") = __NR_##name; \
419register long __o0 __asm__ ("o0") = (long)(arg1); \
420register long __o1 __asm__ ("o1") = (long)(arg2); \
421register long __o2 __asm__ ("o2") = (long)(arg3); \
422register long __o3 __asm__ ("o3") = (long)(arg4); \
423__asm__ __volatile__ ("t 0x10\n\t" \
424 "bcc 1f\n\t" \
425 "mov %%o0, %0\n\t" \
426 "sub %%g0, %%o0, %0\n\t" \
427 "1:\n\t" \
428 : "=r" (__res), "=&r" (__o0) \
429 : "1" (__o0), "r" (__o1), "r" (__o2), "r" (__o3), "r" (__g1) \
430 : "cc"); \
431if (__res < -255 || __res>=0) \
432 return (type) __res; \
433errno = -__res; \
434return -1; \
435}
436
437#define _syscall5(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4, \
438 type5,arg5) \
439type name (type1 arg1,type2 arg2,type3 arg3,type4 arg4,type5 arg5) \
440{ \
441long __res; \
442register long __g1 __asm__ ("g1") = __NR_##name; \
443register long __o0 __asm__ ("o0") = (long)(arg1); \
444register long __o1 __asm__ ("o1") = (long)(arg2); \
445register long __o2 __asm__ ("o2") = (long)(arg3); \
446register long __o3 __asm__ ("o3") = (long)(arg4); \
447register long __o4 __asm__ ("o4") = (long)(arg5); \
448__asm__ __volatile__ ("t 0x10\n\t" \
449 "bcc 1f\n\t" \
450 "mov %%o0, %0\n\t" \
451 "sub %%g0, %%o0, %0\n\t" \
452 "1:\n\t" \
453 : "=r" (__res), "=&r" (__o0) \
454 : "1" (__o0), "r" (__o1), "r" (__o2), "r" (__o3), "r" (__o4), "r" (__g1) \
455 : "cc"); \
456if (__res < -255 || __res>=0) \
457 return (type) __res; \
458errno = -__res; \
459return -1; \
460}
461
462#define __ARCH_WANT_IPC_PARSE_VERSION 332#define __ARCH_WANT_IPC_PARSE_VERSION
463#define __ARCH_WANT_OLD_READDIR 333#define __ARCH_WANT_OLD_READDIR
464#define __ARCH_WANT_STAT64 334#define __ARCH_WANT_STAT64