So I changed CONFIG_SPI_SPIDEV=y. I think the problem is still the device-tree. It gives me an issue when I try to compile with
gpio@6000d000 {
compatible = "nvidia,tegra210-gpio", "nvidia,tegra124-gpio", "nvidia,tegra30-gpio";
reg = <0x0 0x6000d000 0x0 0x1000>;
interrupts = <0x0 0x20 0x4 0x0 0x21 0x4 0x0 0x22 0x4 0x0 0x23 0x4 0x0 0x37 0x4 0x0 0x57 0x4 0x0 0x59 0x4 0x0 0x7d 0x4>;
#gpio-cells = <0x2>;
gpio-controller;
#interrupt-cells = <0x2>;
interrupt-controller;
gpio-ranges = <0x5a 0x0 0x0 0xf6>;
status = "okay";
linux,phandle = <0x78>;
phandle = <0x78>;
wlan-default-input {
gpio-hog;
input;
gpios = <0x3a 0x0 0x41 0x0>;
label = "wlan-default-input-h2", "wlan-default-input-i1";
};
wlan-default-output-high {
gpio-hog;
output-high;
gpios = <0x38 0x0 0x40 0x0 0x42 0x0>;
label = "wlan-default-output-high-h0", "wlan-default-output-high-i0";
};
camera-control-output-low {
gpio-hog;
output-low;
gpios = <0x94 0x0 0x97 0x0 0x95 0x0 0x98 0x0>;
label = "cam0-rst", "cam0-pwdn", "cam1-rst", "cam1-pwdn";
};
e2614-rt5658-audio {
gpio-hog;
function;
gpios = <0x8 0x0 0x9 0x0 0xa 0x0 0xb 0x0 0xd8 0x0 0xdb 0x0 0x24 0x0 0x25 0x0>;
label = "I2S0_LRCLK", "I2S0_SDIN", "I2S0_SDOUT", "I2S0_CLK", "AUDIO_MCLK", "AUD_RST", "DMIC3_CLK", "DMIC3_DAT";
status = "disabled";
linux,phandle = <0x13d>;
phandle = <0x13d>;
};
gpio_default: default{
gpio-hog;
function;
gpios = <TEGRA_GPIO(C, 0) 0 TEGRA_GPIO(C, 1) 0 TEGRA_GPIO(C, 2) 0 TEGRA_GPIO(C, 3) 0 TEGRA_GPIO(C, 4) 0>;
};
};
when I compile using
sudo dtc -I dts -O dtb -o ~/Downloads/Linux_for_tegra/kernel/dtb/tegra210-jetson-tx1-p2597-2180-a01-devkit.dtb ~/Desktop/extracted.dts
I get
Error: /home/lhr/Desktop/extracted.dts:3073.17-18 syntax error
FATAL ERROR: Unable to parse input tree
I believe the error occurs in
gpios = <TEGRA_GPIO(C, 0) 0 TEGRA_GPIO(C, 1) 0 TEGRA_GPIO(C, 2) 0 TEGRA_GPIO(C, 3) 0 TEGRA_GPIO(C, 4) 0>;
because I can compile without this line.
Is there any mistake in this line or is there another tool other than device-tree-compiler I should use?