Changeset 7c3fb9b in mainline for kernel/arch/amd64/src
- Timestamp:
- 2018-05-17T08:29:01Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 6ff23ff
- Parents:
- fac0ac7
- git-author:
- Jiri Svoboda <jiri@…> (2018-05-16 17:28:17)
- git-committer:
- Jiri Svoboda <jiri@…> (2018-05-17 08:29:01)
- Location:
- kernel/arch/amd64/src
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/amd64/src/fpu_context.c
rfac0ac7 r7c3fb9b 57 57 { 58 58 /* TODO: Zero all SSE, MMX etc. registers */ 59 /* Default value of SCR register is 0x1f80, 60 * it masks all FPU exceptions*/ 59 /* 60 * Default value of SCR register is 0x1f80, 61 * it masks all FPU exceptions 62 */ 61 63 asm volatile ( 62 64 "fninit\n" -
kernel/arch/amd64/src/kseg.c
rfac0ac7 r7c3fb9b 42 42 * Allocate and initialize a per-CPU structure to be accessible via the 43 43 * GS_KERNEL segment register. 44 * */44 */ 45 45 void kseg_init(void) 46 46 { -
kernel/arch/amd64/src/pm.c
rfac0ac7 r7c3fb9b 268 268 tss_p = &tss; 269 269 } else { 270 /* We are going to use malloc, which may return 270 /* 271 * We are going to use malloc, which may return 271 272 * non boot-mapped pointer, initialize the CR3 register 272 * ahead of page_init */ 273 * ahead of page_init 274 */ 273 275 write_cr3((uintptr_t) AS_KERNEL->genarch.page_table); 274 276 -
kernel/arch/amd64/src/syscall.c
rfac0ac7 r7c3fb9b 52 52 /* Setup syscall entry address */ 53 53 54 /* This is _mess_ - the 64-bit CS is argument + 16, 54 /* 55 * This is _mess_ - the 64-bit CS is argument + 16, 55 56 * the SS is argument + 8. The order is: 56 57 * +0(KDATA_DES), +8(UDATA_DES), +16(UTEXT_DES) … … 60 61 ((uint64_t) (GDT_SELECTOR(KTEXT_DES) | PL_KERNEL) << 32)); 61 62 write_msr(AMD_MSR_LSTAR, (uint64_t)syscall_entry); 62 /* Mask RFLAGS on syscall 63 /* 64 * Mask RFLAGS on syscall 63 65 * - disable interrupts, until we exchange the stack register 64 66 * (mask the IF bit)
Note:
See TracChangeset
for help on using the changeset viewer.