target_signal.h 637 B

123456789101112131415161718192021222324252627282930313233343536
  1. #ifndef TARGET_SIGNAL_H
  2. #define TARGET_SIGNAL_H
  3. #include "cpu.h"
  4. /* this struct defines a stack used during syscall handling */
  5. typedef struct target_sigaltstack {
  6. abi_ulong ss_sp;
  7. abi_long ss_flags;
  8. abi_ulong ss_size;
  9. } target_stack_t;
  10. /*
  11. * sigaltstack controls
  12. */
  13. #define TARGET_SS_ONSTACK 1
  14. #define TARGET_SS_DISABLE 2
  15. #define TARGET_MINSIGSTKSZ 4096
  16. #define TARGET_SIGSTKSZ 16384
  17. #ifndef UREG_I6
  18. #define UREG_I6 6
  19. #endif
  20. #ifndef UREG_FP
  21. #define UREG_FP UREG_I6
  22. #endif
  23. static inline abi_ulong get_sp_from_cpustate(CPUSPARCState *state)
  24. {
  25. return state->regwptr[UREG_FP];
  26. }
  27. #endif /* TARGET_SIGNAL_H */