Changeset dff90fa7 in mainline for kernel/arch/ia32/src


Ignore:
Timestamp:
2013-06-05T19:41:12Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
74dcc07
Parents:
f288d85 (diff), 6db5d4b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

mainline changes

Location:
kernel/arch/ia32/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ia32/src/boot/vesa_real.inc

    rf288d85 rdff90fa7  
    3131vesa_init:
    3232        lidtl vesa_idtr
    33         jmp $GDT_SELECTOR(VESA_INIT_DES), $vesa_init_real - vesa_init
     33       
     34        mov $GDT_SELECTOR(VESA_INIT_DATA_DES), %bx
     35       
     36        mov %bx, %es
     37        mov %bx, %fs
     38        mov %bx, %gs
     39        mov %bx, %ds
     40        mov %bx, %ss
     41       
     42        jmp $GDT_SELECTOR(VESA_INIT_CODE_DES), $vesa_init_real - vesa_init
    3443
    3544vesa_idtr:
     
    3948.code16
    4049vesa_init_real:
    41        
    4250        mov %cr0, %eax
    4351        and $~1, %eax
     
    4553       
    4654        jmp $VESA_INIT_SEGMENT, $vesa_init_real2 - vesa_init
    47        
     55
    4856vesa_init_real2:
    4957        mov $VESA_INIT_SEGMENT, %bx
  • kernel/arch/ia32/src/cpu/cpu.c

    rf288d85 rdff90fa7  
    115115                        "mov %[help], %%cr4\n"
    116116                        : [help] "+r" (help)
    117                         : [mask] "i" (CR4_OSFXSR_MASK | (1 << 10))
     117                        : [mask] "i" (CR4_OSFXSR_MASK | CR4_OSXMMEXCPT_MASK)
    118118                );
    119119        }
    120 
     120       
    121121#ifndef PROCESSOR_i486
    122122        if (CPU->arch.fi.bits.sep) {
  • kernel/arch/ia32/src/fpu_context.c

    rf288d85 rdff90fa7  
    2727 */
    2828
    29 /** @addtogroup ia32   
     29/** @addtogroup ia32
    3030 * @{
    3131 */
     
    3737#include <arch.h>
    3838#include <cpu.h>
    39 
    4039
    4140/** x87 FPU scr values (P3+ MMX2) */
     
    6059        X87_DENORMAL_EXC_FLAG = (1 << 1),
    6160        X87_INVALID_OP_EXC_FLAG = (1 << 0),
    62 
     61       
    6362        X87_ALL_MASK = X87_PRECISION_MASK | X87_UNDERFLOW_MASK | X87_OVERFLOW_MASK | X87_ZERO_DIV_MASK | X87_DENORMAL_OP_MASK | X87_INVALID_OP_MASK,
    6463};
    6564
    66 
    6765typedef void (*fpu_context_function)(fpu_context_t *fctx);
    6866
    69 static fpu_context_function fpu_save, fpu_restore;
     67static fpu_context_function fpu_save;
     68static fpu_context_function fpu_restore;
    7069
    7170static void fpu_context_f_save(fpu_context_t *fctx)
     
    104103void fpu_fxsr(void)
    105104{
    106         fpu_save=fpu_context_fx_save;
    107         fpu_restore=fpu_context_fx_restore;
     105        fpu_save = fpu_context_fx_save;
     106        fpu_restore = fpu_context_fx_restore;
    108107}
    109108
  • kernel/arch/ia32/src/mm/page.c

    rf288d85 rdff90fa7  
    8484void page_fault(unsigned int n __attribute__((unused)), istate_t *istate)
    8585{
    86         uintptr_t page;
     86        uintptr_t badvaddr;
    8787        pf_access_t access;
    8888       
    89         page = read_cr2();
     89        badvaddr = read_cr2();
    9090               
    9191        if (istate->error_word & PFERR_CODE_RSVD)
     
    9797                access = PF_ACCESS_READ;
    9898       
    99         if (as_page_fault(page, access, istate) == AS_PF_FAULT) {
    100                 fault_if_from_uspace(istate, "Page fault: %#x.", page);
    101                 panic_memtrap(istate, access, page, NULL);
    102         }
     99        (void) as_page_fault(badvaddr, access, istate);
    103100}
    104101
  • kernel/arch/ia32/src/pm.c

    rf288d85 rdff90fa7  
    7575        /* VESA Init descriptor */
    7676#ifdef CONFIG_FB
    77         { 0xffff, 0, VESA_INIT_SEGMENT >> 12, AR_PRESENT | AR_CODE | DPL_KERNEL, 0xf, 0, 0, 0, 0, 0 }
     77        { 0xffff, 0, VESA_INIT_SEGMENT >> 12, AR_PRESENT | AR_CODE | AR_READABLE | DPL_KERNEL, 0xf, 0, 0, 0, 0, 0 },
     78        { 0xffff, 0, VESA_INIT_SEGMENT >> 12, AR_PRESENT | AR_DATA | AR_WRITABLE | DPL_KERNEL, 0xf, 0, 0, 0, 0, 0 }
    7879#endif
    7980};
Note: See TracChangeset for help on using the changeset viewer.