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.

XIO3130 ENDIAN format

Other Parts Discussed in Thread: XIO3130

We have been seeing some strange behavior out of the PCIe devices so we started looking at the registers and the values that get written into those registers, trying to see if we can figure out what the switch is doing.  What was observed is that some of the registers seem to want data in little endian and others appear to want it in big endian. 

For instance, when writing one register with data like 14 60 then read it back, it comes back as 14 60.  When writing the next register with 90 30, it comes back 30 90.  Using the SEEPROM contents sent to us earlier, we cannot do some things with the chip and the belief is that the chip isn’t getting set up properly.  After accommodating some of the endianness oddities, we can now make the chip work properly, or at least more predictably.

Is there some document that we don’t have that describes the observed behavior?  Can you provide any insight into why the chip is responding as it is?

  • Hello Ed,

    I haven't heard of this behavior before.

    Can you tell me what registers are you seeing behaving like this so I can make some tests in the lab.

    Regards.

  • PCI itself is in little endian, while the TI specific configuration directives appear to be in big-endian.

     

    For example, the subsystem vendor/device loaded as 0x1234 from the EEPROM will be expressed as a PCI device ID 0x3412 in software.  If you want a device ID of 0x1234 you need to write 0x3412 into the EEPROM, as PCI is little endian.

     

    Based on the XIO3130 manual it appears that the XIO specific configration spaces, such as the General Control registers for downstream ports, are expected to be in Big Endian.  The value I was given to write to this space for ports 1/2 was 0x9062.

     

    In Big Endian this would translate to:

       Link Active Reporting, Slot Present, Power Controller present, PCI Hot Plug Surprise, and PCI Hot Plug Capable.

     

    If this address was in the same endian as the rest of the standard PCI config space, then 0x9062 would translate to:

       Reference Clock Disabled, Electromechanical interlock present, Power Fault Present, Power Indicator Implemented, Reference Clock Power Fault.

     

    Thus, my assumption is that data specific to the XIO3130 loaded from the EEPROM, even if it shows up in PCI config space, is Big Endian, and everything else which is covered by the PCI standard is Little Endian.

    Otherwise the recommendation regarding the values to write to the EEPROM would be very confusing.

  • Hello,

    I've been writing and reading to/from the XIO3130 and everything is in little-endian.

    Can you send me your eeprom file and what you are reading back?

    Regards.