sigcontext.h 910 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note */
  2. /*
  3. * Copyright (C) 2012 Regents of the University of California
  4. */
  5. #ifndef _UAPI_ASM_RISCV_SIGCONTEXT_H
  6. #define _UAPI_ASM_RISCV_SIGCONTEXT_H
  7. #include <asm/ptrace.h>
  8. /* The Magic number for signal context frame header. */
  9. #define RISCV_V_MAGIC 0x53465457
  10. #define END_MAGIC 0x0
  11. /* The size of END signal context header. */
  12. #define END_HDR_SIZE 0x0
  13. #ifndef __ASSEMBLY__
  14. struct __sc_riscv_v_state {
  15. struct __riscv_v_ext_state v_state;
  16. } __attribute__((aligned(16)));
  17. /*
  18. * Signal context structure
  19. *
  20. * This contains the context saved before a signal handler is invoked;
  21. * it is restored by sys_rt_sigreturn.
  22. */
  23. struct sigcontext {
  24. struct user_regs_struct sc_regs;
  25. union {
  26. union __riscv_fp_state sc_fpregs;
  27. struct __riscv_extra_ext_header sc_extdesc;
  28. };
  29. };
  30. #endif /*!__ASSEMBLY__*/
  31. #endif /* _UAPI_ASM_RISCV_SIGCONTEXT_H */