i.MX8QXP - driver spi-nxp-fspi.c - flexpsi bus B not working

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

i.MX8QXP - driver spi-nxp-fspi.c - flexpsi bus B not working

3,412 Views
MarcoSandrelli
Contributor III

Hello,

I encoutered an issue related to the FLEXSPI BUS of the i.MX8QXP SoC (driver drivers / spi / spi-nxp-fspi.c of kernel 5.4.70). According to the documentation  the driver can be configured as follows:

Required SPI slave node properties:
  - reg :        There are two buses (A and B) with two chip selects each.
                 This encodes to which bus and CS the flash is connected:
                 - <0>: Bus A, CS 0
                 - <1>: Bus A, CS 1
                 - <2>: Bus B, CS 0
                 - <3>: Bus B, CS 1

The Pinmux in dts is the follow:

pinctrl_flexspi0: flexspi0grp {
fsl,pins = <

IMX8QXP_QSPI0A_SCLK_LSIO_QSPI0A_SCLK 0x06000021
IMX8QXP_QSPI0A_SS0_B_LSIO_QSPI0A_SS0_B 0x06000021
IMX8QXP_QSPI0A_DATA0_LSIO_QSPI0A_DATA0 0x06000021
IMX8QXP_QSPI0A_DATA1_LSIO_QSPI0A_DATA1 0x06000021
IMX8QXP_QSPI0A_DATA2_LSIO_QSPI0A_DATA2 0x06000021
IMX8QXP_QSPI0A_DATA3_LSIO_QSPI0A_DATA3 0x06000021

IMX8QXP_QSPI0B_SCLK_LSIO_QSPI0B_SCLK 0x06000021
IMX8QXP_QSPI0B_SS0_B_LSIO_QSPI0B_SS0_B 0x06000021
IMX8QXP_QSPI0B_SS1_B_LSIO_QSPI0B_SS1_B 0x06000021

IMX8QXP_QSPI0B_DATA0_LSIO_QSPI0B_DATA0 0x06000021
IMX8QXP_QSPI0B_DATA1_LSIO_QSPI0B_DATA1 0x06000021
IMX8QXP_QSPI0B_DATA2_LSIO_QSPI0B_DATA2 0x06000021
IMX8QXP_QSPI0B_DATA3_LSIO_QSPI0B_DATA3 0x06000021

>;
};

The interface is configured in the following way:

&flexspi0 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_flexspi0>;
status = "okay";

flash_b_0: flash_b-mx2@2 {
compatible = "macronix,mx25u6435f", "jedec,spi-nor";
reg = <2>;
#address-cells = <1>;
#size-cells = <1>;
spi-max-frequency = <25000000>;
status = "okay";
spi-tx-bus-width = <4>;
spi-rx-bus-width = <4>;

};
};

As described, this eeprom should be recognized by BUS FLEXSPI B in Chip Select 0. But what happens is that we see Chip Select and Clock working correctly but no data comes out of the SoC in any of the 4 lines: DATA0, DATA1, DATA2, DATA3. I don't know if it's a known problem or I'm doing something wrong. Thanks for the support.

Best Regards

0 Kudos
Reply
9 Replies

3,310 Views
MarcoSandrelli
Contributor III

Hi Jimmy,

I want to use the eeprom at kernel level, not for boot.

I met this issue at kernel level.

 

Thank you for your answer.

0 Kudos
Reply

3,314 Views
jimmychan
NXP TechSupport
NXP TechSupport

Are you want to boot from the flash that connected on QSPI0B?

0 Kudos
Reply

3,308 Views
jimmychan
NXP TechSupport
NXP TechSupport

Is the macronix driver load/running correct when kernel boot up? could you send me the bootup log?

0 Kudos
Reply

3,306 Views
MarcoSandrelli
Contributor III

Hi Jimmy,

main issue is that there are not DATA signals coming out from i.MX8QX QSPIB, same eeprom is installed in QSPIA and it is correctly recognized from the driver.

0 Kudos
Reply

3,287 Views
jimmychan
NXP TechSupport
NXP TechSupport

please try :

lash_b_0: flash_b-mx2@0 {
compatible = "macronix,mx25u6435f", "jedec,spi-nor";
reg = <2>;

0 Kudos
Reply

3,276 Views
MarcoSandrelli
Contributor III

Hi Jimmy,

I try it but i doesn't work, the DATA PINs doesn't exchange data.

I try IMX8QXP_QSPI0B_DATA0_LSIO_QSPI0B_DATA0 muxed as GPIO and it works as expected, so physical connection is ok.

 

0 Kudos
Reply

3,273 Views
jimmychan
NXP TechSupport
NXP TechSupport

Could you show me the part of the schematic about the connection between eeprom and flexspi?

0 Kudos
Reply

3,253 Views
MarcoSandrelli
Contributor III

Hi,

in attachment the schematic.

Best Regards

0 Kudos
Reply

3,245 Views
jimmychan
NXP TechSupport
NXP TechSupport

is both QSPI0A and QSPI0B connect the eeprom?

please also try "flash_b_0: flash_b-mx2@1" in your dts file.

Tags (1)
0 Kudos
Reply