Hi @KevinFFF,
We use Infineon TPM SLB9670 on Orin through SPI
The result can work normal,but we use LA to test we found some weird phenomenon like below photo:
The CS should be slow then MISO,but it didn’t.
Does the pinmux setting error?Or occupied by other devices in the Device Tree?
SPI Pinmux setting:
sudo ./opt/nvidia/jetson.io/jetson-io.py to create a dtb file and use this dtb file.
pinmux@2430000 {
pinctrl-0 = <0x516>;
pinctrl-names = "default";
compatible = "nvidia,tegra234-pinmux";
reg = <0x00 0x2430000 0x00 0x19100 0x00 0xc300000 0x00 0x4000>;
#gpio-range-cells = <0x03>;
status = "okay";
phandle = <0x2ce>;
exp-header-pinmux {
phandle = <0x516>;
hdr40-pin26 {
nvidia,enable-input = <0x01>;
nvidia,tristate = <0x00>;
nvidia,function = "spi1";
nvidia,pins = "spi1_cs1_pz7";
};
hdr40-pin24 {
nvidia,enable-input = <0x01>;
nvidia,tristate = <0x00>;
nvidia,function = "spi1";
nvidia,pins = "spi1_cs0_pz6";
};
hdr40-pin23 {
nvidia,enable-input = <0x01>;
nvidia,tristate = <0x00>;
nvidia,function = "spi1";
nvidia,pins = "spi1_sck_pz3";
};
hdr40-pin21 {
nvidia,enable-input = <0x01>;
nvidia,tristate = <0x00>;
nvidia,function = "spi1";
nvidia,pins = "spi1_miso_pz4";
};
hdr40-pin19 {
nvidia,enable-input = <0x01>;
nvidia,tristate = <0x00>;
nvidia,function = "spi1";
nvidia,pins = "spi1_mosi_pz5";
};
};
Add TPM device in spi@3210000:
spi@3210000 {
compatible = "nvidia,tegra186-spi";
reg = <0x00 0x3210000 0x00 0x10000>;
interrupts = <0x00 0x24 0x04>;
#address-cells = <0x01>;
#size-cells = <0x00>;
iommus = <0x02 0x04>;
dma-coherent;
dmas = <0x03 0x0f 0x03 0x0f>;
dma-names = "rx\0tx";
spi-max-frequency = <0x3dfd240>;
nvidia,clk-parents = "pll_p\0clk_m";
clocks = <0x04 0x87 0x04 0x66 0x04 0x0e>;
clock-names = "spi\0pll_p\0clk_m";
resets = <0x04 0x5b>;
reset-names = "spi";
status = "okay";
phandle = <0x31e>;
prod-settings {
#prod-cells = <0x04>;
prod {
prod = <0x00 0x194 0x80000000 0x00>;
board {
prod = <0x00 0x04 0x3f 0x30>;
};
};
};
slb9670@0 {
compatible = "infineon,slb9670";
reg = <0x00>;
spi-max-frequency = <32000000>;
controller-data {
nvidia,enable-hw-based-cs;
nvidia,rx-clk-tap-delay = <0x11>;
};
};
and I found the this post situation was similar to me(SPI infineon TPM 2.0 cs-gpios not correct work on Jetpack 5.0.2 and 5.1)