blob: db76c4b3ee1119b8b0d99d49b8941e2a2bebafa0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
/dts-v1/;
/plugin/;
/ {
compatible = "raspberrypi";
fragment@0 {
target = <&spi>;
__overlay__ {
cs-gpios = <&gpio 8 1>, <&gpio 7 1>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&spi0_pins &spi0_cs_pins>;
#address-cells = <1>;
#size-cells = <0>;
spidev@0 {
reg = <0>; // CE0
spi-max-frequency = <500000>;
compatible = "spidev";
};
spidev@1 {
reg = <1>; // CE1
spi-max-frequency = <500000>;
compatible = "spidev";
};
};
};
fragment@1 {
target = <&alt0>;
__overlay__ {
// Drop GPIO 7, SPI 8-11
brcm,pins = <4 5>;
};
};
fragment@2 {
target = <&gpio>;
__overlay__ {
spi0_pins: spi0_pins {
brcm,pins = <9 10 11>;
brcm,function = <4>; // alt0
};
spi0_cs_pins: spi0_cs_pins {
brcm,pins = <8 7>;
brcm,function = <1>; // out
};
};
};
};
|