Changeset c55364c4 in rtems


Ignore:
Timestamp:
Sep 10, 2007, 10:24:57 PM (12 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
751e9f60
Parents:
39ee40db
Message:

2007-09-10 Alain Schaefer <alani@…>

  • cpu_asm.S: Fix two problems:
    • CC bit has been clobbered and was not correctly restored
    • bfin hardware does not allow to read instructions from the L1
Location:
cpukit/score/cpu/bfin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/score/cpu/bfin/ChangeLog

    r39ee40db rc55364c4  
     12007-09-10      Alain Schaefer <alani@easc.ch>
     2
     3        * cpu_asm.S: Fix two problems:
     4            - CC bit has been clobbered and was not correctly restored
     5            - bfin hardware does not allow to read instructions from the L1
     6
     7
    182007-09-10      Alain Schaefer <alani@easc.ch>
    29
  • cpukit/score/cpu/bfin/cpu_asm.S

    r39ee40db rc55364c4  
    269269    P0.H = HI(SCRATCH);
    270270    P0.L = LO(SCRATCH);
    271 
     271 
     272        [--SP] = ASTAT; /*  save cc flag*/
    272273    /* if SP is already inside the SCRATCHPAD */
    273274    CC=SP<P0 (iu)
     
    303304   
    304305    P0 = RETI;
    305     R0 = W[P0];
     306    R0 = P0;
     307    R0.L = 0x0000;
     308    R1.H = 0xffa0;
     309    R1.L = 0x0000;
     310    CC = R0 == R1;
     311    if CC jump disablethreaddispatch;
     312       
     313    R0 = W[P0](Z);   
     314   
    306315    /* shift 16 bits to the right (select the high nibble ) */
    307316    /*R0 >>= 16;*/
     
    309318    R3 = 0;
    310319    /* Check if RETI is a LINK instruction */
    311     R1.h = HI(0xE800);
     320    R1.h = HI(0x0000);
    312321    R1.l = LO(0xE800);
    313322    CC=R0==R1;
     
    315324   
    316325    /* Check if RETI is a RTS instruction */
    317     R1.h = HI(0x0010);
     326    R1.h = HI(0x0000);
    318327    R1.l = LO(0x0010);
    319328    CC=R0==R1;
     
    402411    restoreP0:
    403412    P0 = USP;
     413    ASTAT = [SP++]; /* restore cc flag */
    404414       
    405415    /*now we should be on the old "user-stack" again */
Note: See TracChangeset for help on using the changeset viewer.