2419880_en-US

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

2419880_en-US

2419880_en-US

[i.MX8QXP] I2C reads above 256 bytes time out; 256-byte and paged reads pass

Hi NXP Team,

We are facing an I2C long-read issue on the i.MX8QXP C0 MEK platform while accessing an Apple MFi authentication IC.

The MFi device communicates correctly for reads up to 256 bytes. However, any single read greater than 256 bytes consistently times out. The complete certificate can be read successfully when divided into 128-byte pages.

We need support to confirm whether this is a known limitation or issue in the i.MX LPI2C PIO driver and to recommend an appropriate driver fix or DMA configuration ?

Platform details

  • Platform: NXP i.MX8QXP C0 MEK
  • Kernel: Linux 6.6.52-lynx-lts-next
  • Yocto baseline: Scarthgap-based build
  • I2C controller: 5a810000.i2c
  • Linux adapter: /dev/i2c-1
  • Driver: drivers/i2c/busses/i2c-imx-lpi2c.c
  • Controller mode: PIO
  • MFi slave address: 0x10
  • I2C frequency: 400 kHz
  • Certificate-length register: 0x30
  • Certificate-data registers: 0x31 onward
  • Certificate length on this device: 608 bytes
  • Reproducibility: 100%

Kernel initialization confirms PIO mode:

imx-lpi2c 5a810000.i2c: use pio mode
i2c i2c-1: LPI2C adapter registered

The live Device Tree confirms 400 kHz:

The MFi application performs the following sequence:

  1. Select register 0x30.
  2. Read two-byte certificate length.
  3. Certificate length returned: 0x0260, or 608 bytes.
  4. Select register 0x31.
  5. Request a single 608-byte read.

Application result:

Reading Certificate Size
Setting register 0x30
Reading register 0x30, 2 bytes
Allocating Certificate Size: 608 bytes

Reading Certificate Data
Setting register 0x31
Reading register 0x31, 608 bytes
Reading register 0x31, 608 bytes failed: EIO

Reading register 0x31, 608 bytes
Reading register 0x31, 608 bytes failed: ETIMEDOUT

Reading register 0x31, 608 bytes
Reading register 0x31, 608 bytes failed: ETIMEDOUT

Dynamic-debug output:

i2c i2c-1:  exit with: error: -5
i2c i2c-1:  exit with: error: -110
i2c i2c-1:  exit with: error: -110

 



Tags (1)
No ratings
Version history
Last update:
Saturday
Updated by: