Changeset 8044533 in rtems for cpukit


Ignore:
Timestamp:
07/18/95 19:27:50 (28 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
10aed1e3
Parents:
f67ad3d
Message:

merged Linux UNIX simulator support (C)

Location:
cpukit/score/cpu
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/score/cpu/i386/cpu.c

    rf67ad3d r8044533  
    7474 
    7575#if __GO32__
    76 #include <cpu.h>
    7776#include <go32.h>
    7877#include <dpmi.h>
     
    9089    *old_handler =  0;    /* XXX not supported */
    9190
    92     handler_info.pm_offset = new_handler;
     91    handler_info.pm_offset = (u_long) new_handler;
    9392    handler_info.pm_selector = _go32_my_cs();
    9493
  • cpukit/score/cpu/unix/cpu.c

    rf67ad3d r8044533  
    392392  *(addr + SP_OFF) = (unsigned32)(_stack_high - CPU_FRAME_SIZE);
    393393  *(addr + FP_OFF) = (unsigned32)(_stack_high);
     394
     395#elif defined(i386)
     396 
     397    /*
     398     *  This information was gathered by disassembling setjmp().
     399     */
     400 
     401    stack_ptr = _stack_high - CPU_FRAME_SIZE;
     402    *(addr + EBX_OFF) = 0xFEEDFEED;
     403    *(addr + ESI_OFF) = 0xDEADDEAD;
     404    *(addr + EDI_OFF) = 0xDEAFDEAF;
     405    *(addr + EBP_OFF) = stack_ptr;
     406    *(addr + ESP_OFF) = stack_ptr;
     407    *(addr + RET_OFF) = jmp_addr;
     408 
     409 
     410    addr = (unsigned32 *) stack_ptr;
     411 
     412    addr[ 0 ] = jmp_addr;
     413    addr[ 1 ] = (unsigned32) stack_ptr;
     414    addr[ 2 ] = (unsigned32) stack_ptr;
     415
    394416#else
    395417#error "UNKNOWN CPU!!!"
Note: See TracChangeset for help on using the changeset viewer.