Skip to content

Commit

Permalink
Adding spi directly into the device tree
Browse files Browse the repository at this point in the history
  • Loading branch information
computermouth committed Aug 24, 2017
1 parent 8854fbf commit 28e7e96
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions arch/arm/boot/dts/ntc-gr8-crumb.dts
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,20 @@
allwinner,drive = <SUN4I_PINCTRL_10_MA>;
allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
};

spi2_pins_a: spi2@0 {
allwinner,pins = "PE1", "PE2", "PE3";
allwinner,function = "spi2";
allwinner,drive = <0>;
allwinner,pull = <0>;
};

spi2_cs0_pins_a: spi2-cs0@0 {
allwinner,pins = "PE0";
allwinner,function = "spi2";
allwinner,drive = <0>;
allwinner,pull = <0>;
};
};

&pwm {
Expand Down Expand Up @@ -258,6 +272,20 @@
regulator-name = "vcc-wifi-2";
};

&spi2 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&spi2_pins_a>, <&spi2_cs0_pins_a>;

spi2_0 {
#address-cells = <1>;
#size-cells = <0>;
compatible = "spidev";
reg = <0>;
spi-max-frequency = <50000000>;
};
};

&uart1 {
pinctrl-names = "default";
pinctrl-0 = <&uart1_pins_a>, <&uart1_cts_rts_pins_a>;
Expand Down

0 comments on commit 28e7e96

Please sign in to comment.