Date: Sat, 3 Nov 2018 21:07:09 +0100 From: Bernd Walter <ticso@cicely7.cicely.de> To: freebsd-arm@freebsd.org Cc: Bernd Walter <ticso@cicely7.cicely.de> Subject: How to add custom dts entries Message-ID: <20181103200709.GB79858@cicely7.cicely.de>
next in thread | raw e-mail | index | archive | help
For a raspberry (1B modell) I have the following patches: [92]cicely7> cat rpi.ds18b20.dts.patch Index: boot/fdt/dts/arm/rpi.dts =================================================================== --- boot/fdt/dts/arm/rpi.dts (revision 303469) +++ boot/fdt/dts/arm/rpi.dts (working copy) @@ -340,6 +348,11 @@ }; }; + onewire { + compatible = "w1-gpio"; + gpios = <&gpio 4 1>; + }; + power: regulator { compatible = "broadcom,bcm2835-power-mgr", "broadcom,bcm2708-power-mgr", [93]cicely7> cat rpi.apa102.dts.patch Index: boot/fdt/dts/arm/rpi.dts =================================================================== --- boot/fdt/dts/arm/rpi.dts (revision 303469) +++ boot/fdt/dts/arm/rpi.dts (working copy) @@ -292,6 +292,14 @@ broadcom,function = "ALT3"; }; }; + + spi0 { + apa102led0 { + compatible = "led,apa102"; + spi-chipselect = <0>; + }; + }; + usb { hub { compatible = "usb,hub", "usb,device"; And to install cd /usr/src/sys/modules/dtb/rpi make all install Obviously a few things have changed since then. We don't have overlay support yet, don't we? System is: # uname -a FreeBSD rpi-b 12.0-BETA3 FreeBSD 12.0-BETA3 r340039 RPI-B arm /usr/src is populated and my kernel driver itself build fine: # ls -la /boot/modules/ total 20 drwxr-xr-x 2 root wheel 512 Nov 3 20:54 . drwxr-xr-x 10 root wheel 1024 Nov 3 20:54 .. -r-xr-xr-x 1 root wheel 7080 Nov 3 20:54 apa102.ko -rw-r--r-- 1 root wheel 36 Nov 3 20:54 linker.hints -- B.Walter <bernd@bwct.de> http://www.bwct.de Modbus/TCP Ethernet I/O Baugruppen, ARM basierte FreeBSD Rechner uvm.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20181103200709.GB79858>