Hi igor,
I've tried what you recommended, using the lpspi dts example you gave. I modified fsl-imx8qxp-mek-ov5640-rpmsg.dts to create spidev0 from lpspi0. When I boot up my imx8, the spidev0.0 still doesn't appear. Looking down through the inherited devicetree files, I found another definition of lpspi0 at fsl-imxdx.dtsi on line 2735. Will this conflict with the lpspi0 that I defined?
(I modified fsl-imx8qxp-mek-ov5640-rpmsg.dts because I also need camera functionality on the board.)
fsl-imx8qxp-mek-ov5640-rpmsg.dts
#include "fsl-imx8qxp-mek-rpmsg.dts"
#include "fsl-imx8qxp-mek-ov5640.dtsi"
&i2c_rpbus_5 {
ov5640: ov5640@3c {
compatible = "ovti,ov5640_v3";
reg = <0x3c>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_parallel_csi>;
clocks = <&clk IMX8QXP_PARALLEL_CSI_MISC0_CLK>;
clock-names = "csi_mclk";
pwn-gpios = <&gpio3 2 GPIO_ACTIVE_LOW>;
rst-gpios = <&gpio3 3 GPIO_ACTIVE_HIGH>;
csi_id = <0>;
mclk = <24000000>;
mclk_source = <0>;
status = "okay";
port {
ov5640_ep: endpoint {
remote-endpoint = <¶llel_csi_ep>;
};
};
};
};
&iomuxc {
imxqxp-mek {
pinctrl_lpspi0: lpspi0grp {
fsl,pins = <
SC_P_SPI0_SCK_ADMA_SPI0_SCK 0x0600004c
SC_P_SPI0_SDO_ADMA_SPI0_SDO 0x0600004c
SC_P_SPI0_SDI_ADMA_SPI0_SDI 0x0600004c
SC_P_SPI0_CS0_ADMA_SPI0_CS0 0x0600004c
>;
};
};
};
&lpspi0 {
#address-cells = <1>;
#size-cells = <0>;
fsl,spi-num-chipselects = <1>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lpspi0>;
status = "okay";
spidev0: spi@0 {
reg = <0>;
compatible = "rohm, dh2228fv";
spi-max-fequency = <10000000>;
};
};
fsl-imx8dx.dtsi
lpspi0: lpspi@5a000000 {
compatible = "fsl,imx7ulp-spi";
reg = <0x0 0x5a000000 0x0 0x10000>;
interrupts = <GIC_SPI 216 IRQ_TYPE_LEVEL_HIGH>;
interrupt-parent = <&gic>;
clocks = <&clk IMX8QXP_SPI0_CLK>,
<&clk IMX8QXP_SPI0_IPG_CLK>;
clock-names = "per", "ipg";
assigned-clocks = <&clk IMX8QXP_SPI0_CLK>;
assigned-clock-rates = <20000000>;
power-domains = <&pd_dma_lpspi0>;
dma-names = "tx","rx";
dmas = <&edma2 1 0 0>, <&edma2 0 0 1>;
status = "disabled";
};
Thanks,
Nolan Z