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.

AM6422: SPI device driver is not functioning in the U-Boot loader

Part Number: AM6422


Tool/software:

Hi TI Support Team,

I am trying to display the product logo from the U-Boot loader on the custom board AM6422. I have configured the SPI device driver in U-Boot to communicate with the spi-LCD. However, I am encountering an issue when trying to initialize and access the SPI slave device (using spi_get_bus_and_cs), causing U-Boot to hang. Please let me know if I have missed any necessary configurations.

CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_CMD_SPI=y

Changes in k3-am642-evm.dts

        main_spi0_pins_default: main-spi0-pins-default {
                pinctrl-single,pins = <
                        AM64X_IOPAD(0x0210, PIN_INPUT, 0) /* (D13) SPI0_CLK */
                        AM64X_IOPAD(0x0208, PIN_OUTPUT, 0) /* (D12) SPI0_CS0 */
                        AM64X_IOPAD(0x0214, PIN_OUTPUT, 0) /* (A13) SPI0_D0 */
                >;
        };

&main_spi0 {
        status = "okay";
        pinctrl-names = "default";
        pinctrl-0 = <&main_spi0_pins_default>;
        ti,pindir-d0-out-d1-in = <1>;   
        ti,spi-num-cs = <1>;      
        spidev@0 {
            status = "okay";
            compatible = "rohm,dh2228fv";
            spi-max-frequency = <5000000>;
            reg = <0>;
            spi-cs-high;
       };
};

Uboot Debug Log:

Regards,

Kalyan