I build yocto image from GitHub - SolidRun/meta-solidrun-arm-hailo: A yocto meta layer for SolidRun Hailo-15 SOM for Hailo15 Hummingboard IIOT. Based on my requirements, I have to add an external SPI communication(disabled by default) and configure 4 gpio pins for that (I choose, Hailo15 Pins 7,10,20,27). So I have modified the DTS as below. (All the modified portions from the default device tree are represented in bold.)
/ {
carrier_spi_mux: carrier_spi_mux {
compatible = “gpio-mux”;
#mux-control-cells = <0>;
mux-gpios = <&tca6416_21 0 GPIO_ACTIVE_HIGH>;
idle-state = <0>;
};
/* NOTE: Frequency can’t go below 6250000 for hailo unit */
&hailo_spi_muxed {
/delete-node/ b2b_spi@1;
carrier_spi_muxed: carrier_spi_muxed@1 {
compatible = “spi-mux”;
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;
spi-max-frequency = <6250000>;
mux-controls = <&carrier_spi_mux>;
carrier_tpm: tpm@0 {
compatible = “infineon,slb9670”, “tcg,tpm_tis-spi”;
reg = <0>;
spi-max-frequency = <6250000>;
};
carrier_conn: carrier_conn_spi@1 {
status = “okay”;
compatible = “xxxx,xxxx-xxx”;
reg = <1>;
spi-max-frequency = <6250000>;
spi-irq-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
reset-gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>; //reset
power-gpios = <&gpio1 20 GPIO_ACTIVE_HIGH>, <&gpio1 21 GPIO_ACTIVE_HIGH>; //wake,busy
};
};
};
Also I set pin 7 and pin 10 as gpio since these were not configured in pinctrl.
pinctrl_gpio7: gpio7 {
function = “gpio”;
groups = “gpio7_grp”;
};
pinctrl_gpio10: gpio10 {
function = “gpio”;
groups = “gpio10_grp”;
};
Since ‘mux-gpios’ control pin (&tca6416_21 0)has made HIGH in device tree, the external SPI should have to be active.
Does my configuration is correct? I have configured such that I could take output from the J22 connector on Hummingboard IIOT. Also how to validate the dts configuration?