syscall.S 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. /* Copyright (C) 1991, 1992, 1997, 2002 Free Software Foundation, Inc.
  2. The GNU C Library is free software; you can redistribute it and/or
  3. modify it under the terms of the GNU Lesser General Public
  4. License as published by the Free Software Foundation; either
  5. version 2.1 of the License, or (at your option) any later version.
  6. The GNU C Library is distributed in the hope that it will be useful,
  7. but WITHOUT ANY WARRANTY; without even the implied warranty of
  8. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  9. Lesser General Public License for more details.
  10. You should have received a copy of the GNU Lesser General Public
  11. License along with the GNU C Library; if not, see
  12. <http://www.gnu.org/licenses/>. */
  13. #include <features.h>
  14. #include <sys/syscall.h>
  15. .text
  16. .global syscall
  17. .type syscall,%function
  18. .align 4
  19. syscall:
  20. mov %o0, %g1
  21. mov %o1, %o0
  22. mov %o2, %o1
  23. mov %o3, %o2
  24. mov %o4, %o3
  25. mov %o5, %o4
  26. ta 0x10
  27. bcs __syscall_error
  28. nop
  29. retl
  30. nop
  31. .size syscall,.-syscall