|
Kodi Docs 20.0
Kodi is an open source media player and entertainment hub.
|
#include "ldt_keeper.h"#include <string.h>#include <stdint.h>#include <stdlib.h>#include <errno.h>#include <fcntl.h>#include <sys/mman.h>#include <sys/types.h>#include <stdio.h>#include <unistd.h>#include "mmap_anon.h"Classes | |
| struct | user_desc |
Macros | |
| #define | LDT_ENTRIES 8192 |
| #define | LDT_ENTRY_SIZE 8 |
| #define | MODIFY_LDT_CONTENTS_DATA 0 |
| #define | MODIFY_LDT_CONTENTS_STACK 1 |
| #define | MODIFY_LDT_CONTENTS_CODE 2 |
| #define | LDT_SEL(idx) ((idx) << 3 | 1 << 2 | 3) |
| #define | TEB_SEL_IDX 17 |
Functions | |
| void | Setup_FS_Segment (void) |
| ldt_fs_t * | Setup_LDT_Keeper (void) |
| void | Restore_LDT_Keeper (ldt_fs_t *ldt_fs) |
Variables | |
| void * | fs_seg =0 |
| #define LDT_ENTRIES 8192 |
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! This file MUST be in main library because LDT must be modified before program creates first thread
| #define LDT_ENTRY_SIZE 8 |
| #define LDT_SEL | ( | idx | ) | ((idx) << 3 | 1 << 2 | 3) |
| #define MODIFY_LDT_CONTENTS_CODE 2 |
| #define MODIFY_LDT_CONTENTS_DATA 0 |
| #define MODIFY_LDT_CONTENTS_STACK 1 |
| #define TEB_SEL_IDX 17 |
here is a small logical problem with Restore for multithreaded programs - in C++ we use static class for this...
| void* fs_seg =0 |