OS kernel.
More...
OS kernel.
The kernel of PatchworkOS.
◆ CONFIG_INTERRUPT_STACK_PAGES
| #define CONFIG_INTERRUPT_STACK_PAGES 1 |
Interrupt stack configuration.
The CONFIG_INTERRUPT_STACK_PAGES constant defines the amount of pages that are allocated for the per-CPU interrupt, exception and doubleFault stacks.
The interrupt stack can be much much smaller than regular kernel stacks as all interrupt handlers should be as short as possible and allocate as little memory as possible to reduce the amount of time while preemptions are disabled.
Definition at line 14 of file config.h.
◆ CONFIG_MAX_KERNEL_STACK_PAGES
| #define CONFIG_MAX_KERNEL_STACK_PAGES 100 |
Kernel stack configuration.
The CONFIG_MAX_KERNEL_STACK_PAGES constant defines the maximum amount of pages that are allowed to be allocated for a threads kernel stack, the kernel stack is used while the thread is in kernel space and NOT handling an exception/interrupt.
Definition at line 26 of file config.h.
◆ CONFIG_MAX_USER_STACK_PAGES
| #define CONFIG_MAX_USER_STACK_PAGES 100 |
User stack configuration.
The CONFIG_MAX_USER_STACK_PAGES constant defines the maximum amount of pages that are allowed to be allocated for a threads user stack, the user stack is used while the thread is in user space.
Definition at line 37 of file config.h.
◆ CONFIG_MAX_FD
Maximum file descriptor configuration.
The CONFIG_MAX_FD constant defines the maximum amount of file descriptors that a process is allowed to have open.
Definition at line 47 of file config.h.
◆ CONFIG_LOG_SERIAL
| #define CONFIG_LOG_SERIAL true |
Serial logging configuration.
The CONFIG_LOG_SERIAL constant defines if to output logged strings via serial.
Definition at line 57 of file config.h.
◆ CONFIG_MAX_NOTES
| #define CONFIG_MAX_NOTES 8 |
Maximum note queue configuration.
The CONFIG_MAX_NOTES constant defines the maximum length of a threads note queue. If a thread is unable to receive the notes in time before the queue fills up, then notes will be discarded, unless they are flagged as NOTE_CRITICAL.
Definition at line 68 of file config.h.
◆ CONFIG_MAX_ARGC
| #define CONFIG_MAX_ARGC 512 |
Maximum argument vector configuration.
The CONFIG_MAX_ARGC constant defines the maximum amount of arguments that can be passed to a process via its argument vector. Used to avoid vulnerabilities where extremely large argument vectors are passed to processes.
Definition at line 79 of file config.h.
◆ CONFIG_MIN_TIMER_TIMEOUT
Minimum timer timeout configuration.
The CONFIG_MIN_TIMER_TIMEOUT constant defines the minimum timeout that can be set for timers.
Definition at line 89 of file config.h.
◆ CONFIG_TIME_SLICE
Time slice configuration.
The CONFIG_TIME_SLICE constant defines the default time slice given to threads when they are scheduled.
Definition at line 99 of file config.h.
◆ CONFIG_CACHE_HOT_THRESHOLD
Cache hot threshold configuration.
The CONFIG_CACHE_HOT_THRESHOLD constant defines the threshold below which a time duration is considered "cache
hot", meaning that the data is likely still in the CPU cache.
Definition at line 110 of file config.h.
◆ CONFIG_MUTEX_MAX_SLOW_SPIN
| #define CONFIG_MUTEX_MAX_SLOW_SPIN 1000 |
Maximum mutex slow spin configuration.
The CONFIG_MUTEX_MAX_SLOW_SPIN constant defines the maximum number of iterations a thread will spin before blocking on a mutex.
Definition at line 121 of file config.h.
◆ CONFIG_SCREEN_MAX_LINES
| #define CONFIG_SCREEN_MAX_LINES 256 |
Maximum screen lines configuration.
The CONFIG_SCREEN_MAX_LINES constant defines the maximum number of lines that the logging system will display.
Definition at line 131 of file config.h.
◆ CONFIG_PMM_BITMAP_MAX_ADDR
| #define CONFIG_PMM_BITMAP_MAX_ADDR 0x4000000ULL |
Maximum bitmap allocator address.
The CONFIG_PMM_BITMAP_MAX_ADDR constant defines the maximum address below which pages will be handled by the bitmap allocator, pages above this value will be handled by the free stack allocator.
Definition at line 142 of file config.h.
◆ CONFIG_PROCESS_REAPER_INTERVAL
Process reaper interval configuration.
The CONFIG_PROCESS_REAPER_INTERVAL constant defines the minimum interval at which the process reaper runs to clean up zombie processes. It might run less frequently.
Definition at line 153 of file config.h.