Squash commits for public release
This commit is contained in:
22
kernel/include/platform/arm64/tasking/context.h
Normal file
22
kernel/include/platform/arm64/tasking/context.h
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef _KERNEL_PLATFORM_ARM64_TASKING_CONTEXT_H
|
||||
#define _KERNEL_PLATFORM_ARM64_TASKING_CONTEXT_H
|
||||
|
||||
#include <libkern/c_attrs.h>
|
||||
#include <libkern/types.h>
|
||||
|
||||
typedef struct {
|
||||
uint64_t x[22];
|
||||
uint64_t lr;
|
||||
} PACKED context_t;
|
||||
|
||||
static inline uintptr_t context_get_instruction_pointer(context_t* ctx)
|
||||
{
|
||||
return ctx->lr;
|
||||
}
|
||||
|
||||
static inline void context_set_instruction_pointer(context_t* ctx, uintptr_t ip)
|
||||
{
|
||||
ctx->lr = ip;
|
||||
}
|
||||
|
||||
#endif // _KERNEL_PLATFORM_ARM64_TASKING_CONTEXT_H
|
||||
Reference in New Issue
Block a user