Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/amd64/src/syscall.c

    r1d3d2cf re13daa5d  
    5858         */
    5959        write_msr(AMD_MSR_STAR,
    60             ((uint64_t) (GDT_SELECTOR(KDATA_DES) | PL_USER) << 48) |
    61             ((uint64_t) (GDT_SELECTOR(KTEXT_DES) | PL_KERNEL) << 32));
     60            ((uint64_t)(gdtselector(KDATA_DES) | PL_USER) << 48) |
     61            ((uint64_t)(gdtselector(KTEXT_DES) | PL_KERNEL) << 32));
    6262        write_msr(AMD_MSR_LSTAR, (uint64_t)syscall_entry);
    6363        /* Mask RFLAGS on syscall
     
    6666         * - clear DF so that the string instructions operate in
    6767         *   the right direction
    68          * - clear NT to prevent a #GP should the flag proliferate to an IRET
    6968         */
    70         write_msr(AMD_MSR_SFMASK, RFLAGS_IF | RFLAGS_DF | RFLAGS_NT);
     69        write_msr(AMD_MSR_SFMASK, RFLAGS_IF | RFLAGS_DF);
    7170}
    7271
Note: See TracChangeset for help on using the changeset viewer.