BCM2708: Add Raspberry Pi TV HAT Device Tree Support
authorYasunari Takiguchi <Yasunari.Takiguchi@sony.com>
Thu, 22 Dec 2016 06:34:12 +0000 (15:34 +0900)
committerRaspbian kernel package updater <root@raspbian.org>
Sat, 31 Mar 2018 14:53:25 +0000 (15:53 +0100)
This is an EXAMPLE CODE of Raspberry Pi TV HAT device tree overlay.
Although this is not a part of our release code, it has been used to verify
CXD2880 device driver with TV HAT.

Add the following line to /boot/config.txt to enable TV HAT:

dtoverlay=rpi-tv

Reboot Raspberry Pi and check the existance of /proc/device-tree/soc/spi@7e204000/cxd2880@0.
If exists, the installation is successful.  you should be able to find the following three files.
/dev/dvb/adapter0/frontend0
/dev/dvb/adapter0/demux0
/dev/dvb/adapter0/dvr0

Signed-off-by: Yasunari Takiguchi <Yasunari.Takiguchi@sony.com>
Signed-off-by: Masayuki Yamamoto <Masayuki.Yamamoto@sony.com>
Signed-off-by: Hideki Nozawa <Hideki.Nozawa@sony.com>
Signed-off-by: Kota Yonezawa <Kota.Yonezawa@sony.com>
Signed-off-by: Toshihiko Matsumoto <Toshihiko.Matsumoto@sony.com>
Signed-off-by: Satoshi Watanabe <Satoshi.C.Watanabe@sony.com>
arch/arm/boot/dts/overlays/Makefile
arch/arm/boot/dts/overlays/README
arch/arm/boot/dts/overlays/rpi-tv-overlay.dts [new file with mode: 0644]

index b64dd7ac0630b2b525809a9f5221420f34a58ac9..e2f66a55dc5afe13d690c2c17827054ac94b7168 100644 (file)
@@ -81,6 +81,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
        rpi-ft5406.dtbo \
        rpi-proto.dtbo \
        rpi-sense.dtbo \
+       rpi-tv.dtbo \
        rra-digidac1-wm8741-audio.dtbo \
        sc16is750-i2c.dtbo \
        sc16is752-spi1.dtbo \
index 1377e5b8e8363c3e0ede318ce54bd784cb70d4c9..e2a803e5180cf78d67b6723cfd2f6d3b2b54e53b 100644 (file)
@@ -1142,6 +1142,12 @@ Load:   dtoverlay=rpi-sense
 Params: <None>
 
 
+Name:   rpi-tv
+Info:   Raspberry Pi TV HAT
+Load:   dtoverlay=rpi-tv
+Params: <None>
+
+
 Name:   rra-digidac1-wm8741-audio
 Info:   Configures the Red Rocks Audio DigiDAC1 soundcard
 Load:   dtoverlay=rra-digidac1-wm8741-audio
diff --git a/arch/arm/boot/dts/overlays/rpi-tv-overlay.dts b/arch/arm/boot/dts/overlays/rpi-tv-overlay.dts
new file mode 100644 (file)
index 0000000..a68f6f7
--- /dev/null
@@ -0,0 +1,31 @@
+// rpi-tv HAT
+
+/dts-v1/;
+/plugin/;
+
+/ {
+       compatible = "brcm,bcm2708", "brcm,bcm2709";
+
+       fragment@0 {
+               target = <&spi0>;
+               __overlay__ {
+                       /* needed to avoid dtc warning */
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+
+                       status = "okay";
+
+                       spidev@0 {
+                               status = "disabled";
+                       };
+
+                       cxd2880@0 {
+                               compatible = "sony,cxd2880";
+                               reg = <0>; /* CE0 */
+                               spi-max-frequency = <50000000>;
+                               status = "okay";
+                       };
+               };
+       };
+
+};