1
0
Fork 0
mirror of https://github.com/Atmosphere-NX/Atmosphere.git synced 2024-11-05 11:41:43 +00:00
Atmosphere/exosphere/src/smc_api.h

26 lines
568 B
C
Raw Normal View History

2018-02-17 23:48:34 +00:00
#ifndef EXOSPHERE_SMC_API_H
#define EXOSPHERE_SMC_API_H
#include <stdint.h>
#define SMC_HANDLER_USER 0
#define SMC_HANDLER_PRIV 1
typedef struct {
uint64_t X[8];
} smc_args_t;
bool try_set_user_smc_in_progress(void);
2018-03-04 20:57:25 +00:00
void set_user_smc_in_progress(void);
void clear_user_smc_in_progress(void);
2018-02-24 14:20:45 +00:00
void set_priv_smc_in_progress(void);
void clear_priv_smc_in_progress(void);
uintptr_t get_smc_core012_stack_address(void);
uintptr_t get_exception_entry_stack_address(unsigned int core_id);
2018-02-24 14:20:45 +00:00
2018-02-17 23:48:34 +00:00
void call_smc_handler(unsigned int handler_id, smc_args_t *args);
#endif