This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS570LC4357: EMIF address access problem

Part Number: TMS570LC4357
Other Parts Discussed in Thread: HALCOGEN

I am working with an external ASYNC NOR Flash (MT28EW 1Gb) using EMIF ASYNC1. I have a test script which tries to write a pattern to every address and read it back for comparison. I can successfully write to and read from all addresses within the allotted  22 bit address space. I want to access higher regions of memory using GIO to assert the remaining address lines. I see strange behavior when reading from the higher address space. I continue writing to all addresses but any address > 0x7FFFFF where A1 (EMIF_ADDR0) should be high reads back 0xFFFF (unwritten) and fails the comparison. All other addresses in this upper region read back correctly.

The Micron device driver for this part yields no failures when writing to these problem addresses though I don't exactly trust this. Here is our schematic for the flash device. I am unable to scope the bus.

My logic for reading and writing is as follows: 
#define MASK_ADDR(addr)     (addr & 0x7FFFFF)

#define check_a23(addr)     (addr & (1 << 23))  
#define check_a24(addr)     (addr & (1 << 24))  
#define check_a25(addr)     (addr & (1 << 25))  
uint16_t FlashRead_AddrSpace( uint32_t udAddrOff )
{
    if( check_a23(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A23);
    if( check_a24(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A24);
    if( check_a25(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A25);
    uint16_t ucVal = BASE_ADDR[MASK_ADDR(udAddrOff)];

    CLEAR_EMIF_ADDR(EMIF_A23);
    CLEAR_EMIF_ADDR(EMIF_A24);
    CLEAR_EMIF_ADDR(EMIF_A25);

    return ucVal;
} /* EndFunction FlashRead */
void FlashWrite_AddrSpace( uint32_t udAddrOff, uint16_t ucVal )
{
    if( check_a23(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A23);
    if( check_a24(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A24);
    if( check_a25(udAddrOff) )
        SET_EMIF_ADDR(EMIF_A25);

    /* Write ucVal to the word offset in flash */
    BASE_ADDR[MASK_ADDR(udAddrOff)] = ucVal;

    CLEAR_EMIF_ADDR(EMIF_A23);
    CLEAR_EMIF_ADDR(EMIF_A24);
    CLEAR_EMIF_ADDR(EMIF_A25);
}
Am I correct in my logic for using GIO for the extra address pins? Masking the address to clear bits [31-23] and setting them manually with GIO instead should behave the same as reading from the lower addresses right? I don't understand the behavior of A1 in this context.