18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * System calls under the Sparc. 48c2ecf20Sopenharmony_ci * 58c2ecf20Sopenharmony_ci * Don't be scared by the ugly clobbers, it is the only way I can 68c2ecf20Sopenharmony_ci * think of right now to force the arguments into fixed registers 78c2ecf20Sopenharmony_ci * before the trap into the system call with gcc 'asm' statements. 88c2ecf20Sopenharmony_ci * 98c2ecf20Sopenharmony_ci * Copyright (C) 1995, 2007 David S. Miller (davem@davemloft.net) 108c2ecf20Sopenharmony_ci * 118c2ecf20Sopenharmony_ci * SunOS compatibility based upon preliminary work which is: 128c2ecf20Sopenharmony_ci * 138c2ecf20Sopenharmony_ci * Copyright (C) 1995 Adrian M. Rodriguez (adrian@remus.rutgers.edu) 148c2ecf20Sopenharmony_ci */ 158c2ecf20Sopenharmony_ci#ifndef _SPARC_UNISTD_H 168c2ecf20Sopenharmony_ci#define _SPARC_UNISTD_H 178c2ecf20Sopenharmony_ci 188c2ecf20Sopenharmony_ci#include <uapi/asm/unistd.h> 198c2ecf20Sopenharmony_ci 208c2ecf20Sopenharmony_ci#define NR_syscalls __NR_syscalls 218c2ecf20Sopenharmony_ci 228c2ecf20Sopenharmony_ci#ifdef __32bit_syscall_numbers__ 238c2ecf20Sopenharmony_ci#else 248c2ecf20Sopenharmony_ci#define __NR_time 231 /* Linux sparc32 */ 258c2ecf20Sopenharmony_ci#endif 268c2ecf20Sopenharmony_ci#define __ARCH_WANT_NEW_STAT 278c2ecf20Sopenharmony_ci#define __ARCH_WANT_OLD_READDIR 288c2ecf20Sopenharmony_ci#define __ARCH_WANT_STAT64 298c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_ALARM 308c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_GETHOSTNAME 318c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_PAUSE 328c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_SIGNAL 338c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_TIME32 348c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_UTIME32 358c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_WAITPID 368c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_SOCKETCALL 378c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_FADVISE64 388c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_GETPGRP 398c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_NICE 408c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_OLDUMOUNT 418c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_SIGPENDING 428c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_SIGPROCMASK 438c2ecf20Sopenharmony_ci#ifdef __32bit_syscall_numbers__ 448c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_IPC 458c2ecf20Sopenharmony_ci#else 468c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_TIME 478c2ecf20Sopenharmony_ci#define __ARCH_WANT_SYS_UTIME 488c2ecf20Sopenharmony_ci#define __ARCH_WANT_COMPAT_SYS_SENDFILE 498c2ecf20Sopenharmony_ci#endif 508c2ecf20Sopenharmony_ci 518c2ecf20Sopenharmony_ci#ifdef __32bit_syscall_numbers__ 528c2ecf20Sopenharmony_ci/* Sparc 32-bit only has the "setresuid32", "getresuid32" variants, 538c2ecf20Sopenharmony_ci * it never had the plain ones and there is no value to adding those 548c2ecf20Sopenharmony_ci * old versions into the syscall table. 558c2ecf20Sopenharmony_ci */ 568c2ecf20Sopenharmony_ci#define __IGNORE_setresuid 578c2ecf20Sopenharmony_ci#define __IGNORE_getresuid 588c2ecf20Sopenharmony_ci#define __IGNORE_setresgid 598c2ecf20Sopenharmony_ci#define __IGNORE_getresgid 608c2ecf20Sopenharmony_ci#endif 618c2ecf20Sopenharmony_ci 628c2ecf20Sopenharmony_ci#endif /* _SPARC_UNISTD_H */ 63