mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-07-11 07:19:20 +00:00
Added SMP support
This commit is contained in:
@ -5,7 +5,8 @@
|
||||
|
||||
namespace Interrupts
|
||||
{
|
||||
void Initialize();
|
||||
extern void *apic;
|
||||
void Initialize(int Core);
|
||||
void Enable();
|
||||
}
|
||||
|
||||
|
@ -3,6 +3,9 @@
|
||||
|
||||
#include <types.h>
|
||||
|
||||
/** @brief Maximum supported number of CPU cores by the kernel */
|
||||
#define MAX_CPU 256
|
||||
|
||||
#define CPU_DATA_CHECKSUM 0xC0FFEE
|
||||
|
||||
struct CPUData
|
||||
@ -32,4 +35,9 @@ struct CPUData
|
||||
CPUData *GetCurrentCPU();
|
||||
CPUData *GetCPU(uint64_t ID);
|
||||
|
||||
namespace SMP
|
||||
{
|
||||
void Initialize(void *madt);
|
||||
}
|
||||
|
||||
#endif // !__FENNIX_KERNEL_SMP_H__
|
||||
|
@ -47,6 +47,12 @@ typedef __builtin_va_list va_list;
|
||||
|
||||
#define offsetof(type, member) __builtin_offsetof(type, member)
|
||||
|
||||
#define MIN(a, b) (((a) < (b)) ? (a) : (b))
|
||||
#define MAX(a, b) (((a) > (b)) ? (a) : (b))
|
||||
|
||||
#define VPOKE(type, address) (*((volatile type *)(address)))
|
||||
#define POKE(type, address) (*((type *)(address)))
|
||||
|
||||
typedef __INT8_TYPE__ int8_t;
|
||||
typedef __INT16_TYPE__ int16_t;
|
||||
typedef __INT32_TYPE__ int32_t;
|
||||
|
Reference in New Issue
Block a user