Hi,
We want to directly manipulate PWM and SPI of SPE above linux kernel.
In tegra186-quill-p3310-1000-c03-00-base.dtb, we find there are two places have “c260000”:
1.
spi@c260000 {
compatible = "nvidia,tegra186-spi";
reg = <0x0 0xc260000 0x0 0x10000>;
interrupts = <0x0 0x25 0x4>;
#address-cells = <0x1>;
#size-cells = <0x0>;
iommus = <0x11 0x20>;
dmas = <0x25 0x10 0x25 0x10>;
dma-names = "rx", "tx";
nvidia,clk-parents = "pll_p", "osc";
spi-max-frequency = <0xb71b00>;
clocks = <0x10 0xde 0x10 0x10d 0x10 0x264>;
clock-names = "spi", "pll_p", "osc";
resets = <0x10 0x29>;
reset-names = "spi";
status = "okay";
linux,phandle = <0x18d>;
phandle = <0x18d>;
spi-touch-sharp19x12@0 {
avdd-supply = <0x3e>;
dvdd-supply = <0x3f>;
status = "okay";
compatible = "sharp,lr388k7_ts";
reg = <0x0>;
spi-max-frequency = <0xb71b00>;
irq-gpio = <0x28 0x2f 0x1>;
interrupt-parent = <0x28>;
interrupts = <0x2f 0x1>;
reset-gpio = <0x28 0x3 0x0>;
clock-sel-gpio = <0x40 0x1 0x0>;
x-max = <0x2580>;
y-max = <0x3c00>;
z-max = <0xffff>;
flip-x = <0x1>;
flip-y = <0x1>;
touch-num-max = <0xa>;
platform-id = <0x1>;
};
aon_spi@c260000 {
status = "disabled";
compatible = "nvidia,tegra186-aon-spi";
bus-number = <0x1>;
#address-cells = <0x1>;
#size-cells = <0x0>;
spi-max-frequency = <0xb71b00>;
mboxes = <0x41 0x2>;
linux,phandle = <0x191>;
phandle = <0x191>;
};
Refer to this guide:https://elinux.org/Jetson/TX2_SPI.
We try to add the following to spi1(place1) in the dtb and reflash. We find spidev1.0.
But if we add the following to aon_spi(place2) in the dtb and reflash. We can not find spi device.
spi@0 {
compatible = "spidev";
reg = <0x0>;
spi-max-frequency = <0x1312D00>;
nvidia,enable-hw-based-cs;
nvidia,cs-setup-clk-count = <0x1e>;
nvidia,cs-hold-clk-count = <0x1e>;
nvidia,rx-clk-tap-delay = <0x1f>;
nvidia,tx-clk-tap-delay = <0x0>;
};
So, my questions is: What is the difference between spi1 and aon_spi? They have the same address “c260000”.
Thanks.