Changeset 32f3e34 in rtems


Ignore:
Timestamp:
09/24/98 13:55:18 (25 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
da38d8a
Parents:
287e9584
Message:

Patch from Erik Ivanenko <erik.ivanenko@…>:

Please find attached a start.s that includes a cli prior to the hlt
instruction. This ensures that external interrupts cannot restart
the system after returning to the startup code. ( According to the hlt
docs, they will! )

Also find a new timer.c. ( I forgot to update the countdowm value
in the timer when I changed the PSCLK frequency in start.s) . This
improves timer accuracy.

The raw_idt_notify messages are no longer infinite, I tested sp11 and
sp05, both which were bad, and I have seen the message print once in
one test. I think it's ok if it prints out once. In fact, I don't
think you can effectively stop it!

Location:
c/src/lib/libbsp/i386/i386ex
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/i386ex/start/start.s

    r287e9584 r32f3e34  
    6666       
    6767BEGIN_DATA
    68 /*      .section        .gdt */
    6968         PUBLIC (_Global_descriptor_table)
    7069                       
     
    345344* So, move the whole data section down.
    346345********************************************************/
    347                
    348 /* SYM(xfer_gdt):               
    349         movw $ _ram_gdt_offset  , di
    350         movw $ _ram_gdt_segment , cx
    351         mov  cx                 , es
    352 
    353         movw $ _gdt_size        , cx
    354         movw $ _rom_gdt_segment , ax
    355         movw $ _rom_gdt_offset  , si
    356         mov  ax                 , ds
    357        
    358         repne
    359         movsb
    360 */
    361346
    362347        movw $ _ram_data_offset , di
     
    377362 ****************************/
    378363       
    379 /*      movw $ _ram_gdt_segment, ax */
    380 
    381364#ifdef NEXT_GAS
    382365        data32
    383366        addr32
    384367#endif 
    385 /*        lgdt  _ram_gdt_offset     #  location of GDT */
    386 
    387368        lgdt SYM(GDTR) #  location of GDT
    388369
     
    406387 *********************/
    407388
    408 /*      ljmpl $ GDT_CODE_PTR , $  SYM(_copy_data) # sets the code selector*/
    409389        ljmpl $ GDT_CODE_PTR , $  SYM(_load_segment_registers) # sets the code selector
    410390       
    411391/*
    412  * Copy the data section down to RAM
    413  */
    414 /*SYM(_copy_data): */
     392 * Load the segment registers
     393 */
    415394SYM(_load_segment_registers):   
    416395        .code32
     
    421400        pLOAD_SEGMENT( GDT_DATA_PTR, es)
    422401       
    423 /*      movl            $ SYM(_data_start)      , edi # ram destination
    424         movl            $ SYM(_rom_data_start)  , esi # rom data source
    425         movl            $ SYM(_data_size)       , ecx # amount to move
    426         repne                                         # while ecx != 0
    427         movsb                                         #   move a byte   
    428 */
    429402/*
    430403 *  Set up the stack
     
    460433        call SYM(boot_card)
    461434        addl    $12,esp
    462        
    463         hlt
     435
     436        cli                              # stops interrupts from being processed after hlt!
     437        hlt                              # shutdown
    464438
    465439END
  • c/src/lib/libbsp/i386/i386ex/timer/timer.c

    r287e9584 r32f3e34  
    4848
    4949  outport_byte  ( TMRCON , 0xb0 ); /* select tmr2, stay in mode 0 */
    50   outport_byte  ( TMR1   , 0xd2 ); /* set to 250 usec interval */
     50  outport_byte  ( TMR1   , 0xfa ); /* set to 250 usec interval */
    5151  outport_byte  ( TMR1   , 0x00 );
    5252  outport_byte  ( TMRCON , 0x64 ); /* change to mode 2 ( starts timer ) */
     
    7979{
    8080 if (!i386_delete_idt_entry(&timer_raw_irq_data)) {
    81       printk("Timer raw handler deconnexion failed\n");
     81      printk("Timer_exit:Timer raw handler removal failed\n");
    8282      rtems_fatal_error_occurred(1);
    8383 }
     
    9595    atexit(Timer_exit); /* Try not to hose the system at exit. */
    9696    if (!i386_set_idt_entry (&timer_raw_irq_data)) {
    97       printk("raw handler connexion failed\n");
     97      printk("Timer_initialize: raw handler installation failed\n");
    9898      rtems_fatal_error_occurred(1);
    9999    }
Note: See TracChangeset for help on using the changeset viewer.