Tool/software:
Hello Support Team,
With AM62x SKEVM board, McSPI interface is being done in order to use EXP_SPI0 in the board, but there is no device name in /dev/ like /dev/spidev0.0 after loading dtbo as an overlay.
What has been done...
1. 'k3-am625-sk-mcspi-loopback.dtso' is used.
2. menuconfig has been changed 'McSPI' enabled.
Here is the dt source
#include <dt-bindings/gpio/gpio.h> #include "k3-pinctrl.h" &main_pmx0 { main_spi0_pins_default: main-spi0-pins-default { pinctrl-single,pins = < AM62X_IOPAD(0x01bc, PIN_INPUT, 0) /* (A14) SPI0_CLK */ AM62X_IOPAD(0x01c0, PIN_INPUT, 0) /* (B13) SPI0_D0 */ AM62X_IOPAD(0x01c4, PIN_INPUT, 0) /* (B14) SPI0_D1 */ AM62X_IOPAD(0x01b4, PIN_INPUT, 0) /* (A13) SPI0_CS0 */ >; }; }; &main_i2c1 { gpio@22 { en_rpi_3v3 { gpio-hog; gpios = <5 GPIO_ACTIVE_HIGH>; output-high; line-name = "EXP_PS_3V3_EN"; }; }; }; &main_spi0 { status = "okay"; #address-cells = <1>; #size-cells = <0>; pinctrl-0 = <&main_spi0_pins_default>; pinctrl-names = "default"; spidev@0 { /* * Using spidev compatible is warned loudly, * thus use another equivalent compatible id * from spidev. */ compatible = "rohm,dh2228fv"; spi-max-frequency = <24000000>; reg = <0>; }; };
Here is the result on the shell of the board.
root@am62xx-evm:~# ls /dev/spi* ls: cannot access '/dev/spi*': No such file or directory root@am62xx-evm:~# dmesg | grep spi [ 0.000000] Kernel command line: console=ttyS2,115200n8 earlycon=ns16550a,mmio32,0x02800000 mtdparts=spi-nand0:512k(ospi_nand.tiboot3),2m(ospi_nand.tispl),4m(ospi_nand.u-boot),256k(ospi_nand.env),256k(ospi_nand.env.backup),98048k@32m(ospi_nand.rootfs),256k@130816k(ospi_nand.phypattern) root=PARTUUID=076c4a2a-02 rw rootfstype=ext4 rootwait [ 1.358534] spi-nor spi0.0: s28hs512t (65536 Kbytes) [ 1.363665] 7 fixed-partitions partitions found on MTD device fc40000.spi.0 [ 1.370630] Creating 7 MTD partitions on "fc40000.spi.0": [ 1.376030] 0x000000000000-0x000000080000 : "ospi.tiboot3" [ 1.383046] 0x000000080000-0x000000280000 : "ospi.tispl" [ 1.389733] 0x000000280000-0x000000680000 : "ospi.u-boot" [ 1.396379] 0x000000680000-0x0000006c0000 : "ospi.env" [ 1.402783] 0x0000006c0000-0x000000700000 : "ospi.env.backup" [ 1.409816] 0x000000800000-0x000003fc0000 : "ospi.rootfs" [ 1.416570] 0x000003fc0000-0x000004000000 : "ospi.phypattern"
Thanks in advance,
Kal Kim