iMX8QM PCIe Driver Issue

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

iMX8QM PCIe Driver Issue

3,176 Views
prashanthkumar
Contributor II

Hi,


In iMX8QM custom board with L4.14.78 Kernel BSP release, PCIe device is not mounting properly.

Its getting below error prints, after hard resetting only its able to mount PCIe SATA module.


Note : We are using same iMX8QM board for both BSP releases. So, no Hardware changes.

   ata1.00: exception Emask 0x0 SAct 0x40000 SErr 0x0 action 0x6 frozen
    ata1.00: failed command: READ FPDMA QUEUED
    ata1.00: cmd 60/08:90:f8:6d:bf/00:00:01:00:00/40 tag 18 ncq dma 4096 in
             res 40/00:00:00:00:00/00:00:00:00:00/00 Emask 0x4 (timeout)
    ata1.00: status: { DRDY }
    ata1: hard resetting link
    ata1: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
    ata1.00: configured for UDMA/100
    ata1.00: device reported invalid CHS sector 0
    ata1: EH complete
    EXT4-fs (sda1): recovery complete
    EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)

But in L4.9.51 & 4.9.88 Kernel BSP releases, its not having above issue. The DTS(Device Tree) configuration for PCIe SATA module is same in both Kernel versions which is given below.

pinctrl_pciea: pcieagrp{
                            fsl,pins = <
                                    SC_P_SIM0_POWER_EN_LSIO_GPIO0_IO04                  0x00000021
                                    SC_P_PCIE_CTRL0_WAKE_B_LSIO_GPIO4_IO28           0x06000021
                                    SC_P_PCIE_CTRL0_PERST_B_LSIO_GPIO4_IO29         0x06000021
                            >;
                    };


    &pciea{
            ext_osc = <0>;
            pinctrl-names = "default";
            pinctrl-0 = <&pinctrl_pciea>;
            reset-gpio = <&gpio4 29 GPIO_ACTIVE_LOW>;
            status = "okay";
    };

But the 4.14.78 Kernel Driver file (drivers/pci/dwc/pci-imx6.c) having many changes compared to 4.14.78 Kernel Driver. Whether that driver changes will effect to PCIe device?


Please let me know any changes required in updated Kernel BSP for PCIe SATA mounting issue.


Thanks in Advance.

Regards,

Prashanth Kumar K

0 Kudos
5 Replies

2,056 Views
prashanthkumar
Contributor II

Hi Igor,

We are working on iMX8QM B0 processor only. Both A0 & B0 CPUs with 4.14.78 Kernel BSP having PCIe SATA mounting issue.

B oth A0 & B0 CPUs with 4.9.88/4.9.51 BSP releases, PCIe SATA is working properly without any issues.

Unfortunately we don't have any iMX8QM MEK reference board here for testing.

Best Regards,

Prashanth Kumar K

0 Kudos

2,056 Views
igorpadykov
NXP Employee
NXP Employee

Hi Prashanth 

issue may be related to Table 12. Known issues and workarounds for i.MX 8 Family SoC

attached Release Notes.

Best regards
igor

2,056 Views
prashanthkumar
Contributor II

Hi Igor,

I tried 3 different PCIe SATA module, having same issue with 4.14.78 Kernel, but its working properly in L4.9.51 & 4.9.88 kernel BSP.

Also checked PCIe USB3.0 Host module. With that also having mounting in 4.14.78 kernel.

root@imx8qmmek:~# lspci

00:00.0 PCI bridge: Freescale Semiconductor Inc Device 0000 (rev 01)

01:00.0 USB controller: ASMedia Technology Inc. ASM1142 USB 3.1 Host Controller

The mounting issue is,

 [   51.273680] xhci_hcd 0000:01:00.0: xHCI host not responding to stop endpoint command.
 [   51.281551] xhci_hcd 0000:01:00.0: xHCI host controller not responding, assume dead
 [   51.289236] xhci_hcd 0000:01:00.0: HC died; cleaning up
 [   51.294545] usb 4-2: USB disconnect, device number 2
 [   51.294715] sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x03 driverbyte=0x00
 [   51.294730] sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x28 28 00 00 00 16 29 00 00 7d 00
 [   51.294740] print_req_error: I/O error, dev sdb, sector 5673
 [   51.329772] sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x01 driverbyte=0x00
 [   51.337983] sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x28 28 00 00 00 16 2a 00 00 7c 00
 [   51.345603] print_req_error: I/O error, dev sdb, sector 5674
 [   51.351571] sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x01 driverbyte=0x00
 [   51.351731] FAT-fs (sdb1): FAT read failed (blocknr 3618)
 [   51.365231] sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x28 28 00 00 00 16 a6 00 00 75 00
 [   51.372847] print_req_error: I/O error, dev sdb, sector 5798
 [   51.381162] FAT-fs (sdb1): FAT read failed (blocknr 1808)
 df: /run/media/sdb1: Input/output error

After this issue, its able to mount USB3.0 device.

Is there any workaround/solution for this issue?

Best Regards,

Prashanth Kumar K

0 Kudos

2,056 Views
igorpadykov
NXP Employee
NXP Employee

Hi Prashanth

one can check that iMX8QM board has latest B0 chip reviision

and test with iMX8QM MEK reference board and Linux Binary Demo Files - i.MX 8QMax MEK

Unfortunately this processor is not officially supported yet, suggest to use

NXP Professional Services | NXP 

Best regards
igor

0 Kudos

2,056 Views
igorpadykov
NXP Employee
NXP Employee

Hi Prashanth

one can try with other sata modules, reason may be that

L4.14.78 issue happen only on that sata model (there is no suitable driver for that 

pcie sata card). In general L4.14.78  PCIe driver can be also tested with other pcie devices.

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos