Add spigen(4) fdt data overlays for RPI-B, RPI-2.
By adding spigen-rpi{2,-b}.dtso to fdt_overlays= in loader.conf, the fdt data will set up the correct pinmux and device nodes to create a spigen(4) device for each available chipselect pin. Submitted by: Bob Frazier Differential Revision: https://reviews.freebsd.org/D15067
This commit is contained in:
parent
c5b7751fa2
commit
ce0b0df7ab
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=335564
29
sys/dts/arm/overlays/spigen-rpi-b.dtso
Normal file
29
sys/dts/arm/overlays/spigen-rpi-b.dtso
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
/* $FreeBSD$ */
|
||||||
|
|
||||||
|
/dts-v1/;
|
||||||
|
/plugin/;
|
||||||
|
|
||||||
|
/ {
|
||||||
|
compatible = "brcm,bcm2835";
|
||||||
|
};
|
||||||
|
|
||||||
|
&{/soc/spi@7e204000} {
|
||||||
|
status = "okay";
|
||||||
|
|
||||||
|
spigen0: spigen0 {
|
||||||
|
compatible = "freebsd,spigen";
|
||||||
|
reg = <0>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
spigen1: spigen1 {
|
||||||
|
compatible = "freebsd,spigen";
|
||||||
|
reg = <1>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&{/soc/gpio@7e200000/spi0_cs_pins} {
|
||||||
|
brcm,pins = <8 7>;
|
||||||
|
brcm,function = <4>; /* ALT0 */
|
||||||
|
};
|
||||||
|
|
37
sys/dts/arm/overlays/spigen-rpi2.dtso
Normal file
37
sys/dts/arm/overlays/spigen-rpi2.dtso
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
/* $FreeBSD$ */
|
||||||
|
|
||||||
|
/dts-v1/;
|
||||||
|
/plugin/;
|
||||||
|
|
||||||
|
/ {
|
||||||
|
compatible = "brcm,bcm2836";
|
||||||
|
};
|
||||||
|
|
||||||
|
&{/soc/spi@7e204000} {
|
||||||
|
status = "okay";
|
||||||
|
spigen0: spigen0 {
|
||||||
|
compatible = "freebsd,spigen";
|
||||||
|
reg = <0>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
spigen1: spigen1 {
|
||||||
|
compatible = "freebsd,spigen";
|
||||||
|
reg = <1>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
spigen2: spigen2 {
|
||||||
|
compatible = "freebsd,spigen";
|
||||||
|
reg = <2>;
|
||||||
|
status = "okay";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&{/soc/gpio@7e200000/spi0_cs_pins} {
|
||||||
|
brcm,pins = <8 7 16>;
|
||||||
|
brcm,function = <4>; /* ALT0 */
|
||||||
|
};
|
||||||
|
|
||||||
|
&{/soc/gpio@7e200000/spi0_gpio7} {
|
||||||
|
brcm,pins = <7 8 16 9 10 11>;
|
||||||
|
};
|
||||||
|
|
@ -2,6 +2,10 @@
|
|||||||
# DTS files for the Raspberry Pi-B
|
# DTS files for the Raspberry Pi-B
|
||||||
DTS=rpi.dts rpi2.dts
|
DTS=rpi.dts rpi2.dts
|
||||||
|
|
||||||
|
DTSO= \
|
||||||
|
spigen-rpi-b.dtso \
|
||||||
|
spigen-rpi2.dtso \
|
||||||
|
|
||||||
LINKS= \
|
LINKS= \
|
||||||
${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b.dtb \
|
${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b.dtb \
|
||||||
${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b-rev2.dtb \
|
${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b-rev2.dtb \
|
||||||
|
Loading…
Reference in New Issue
Block a user