1 From b2a2630ad69cc2f76fc027f1e730d6d82f84ea82 Mon Sep 17 00:00:00 2001
2 From: Phil Elwell <phil@raspberrypi.org>
3 Date: Mon, 5 Dec 2016 17:10:44 +0000
4 Subject: [PATCH] BCM270X_DT: Add i2c-sensor overlay
6 The i2c-sensor overlay is a container for various pressure and
7 temperature sensors, currently bmp085 and bmp280. The standalone
8 bmp085_i2c-sensor overlay is now deprecated.
10 Signed-off-by: Phil Elwell <phil@raspberrypi.org>
12 arch/arm/boot/dts/overlays/Makefile | 1 +
13 arch/arm/boot/dts/overlays/README | 12 ++++++--
14 arch/arm/boot/dts/overlays/i2c-sensor-overlay.dts | 34 +++++++++++++++++++++++
15 3 files changed, 45 insertions(+), 2 deletions(-)
16 create mode 100644 arch/arm/boot/dts/overlays/i2c-sensor-overlay.dts
18 --- a/arch/arm/boot/dts/overlays/Makefile
19 +++ b/arch/arm/boot/dts/overlays/Makefile
20 @@ -42,6 +42,7 @@ dtbo-$(RPI_DT_OVERLAYS) += i2c-gpio.dtbo
21 dtbo-$(RPI_DT_OVERLAYS) += i2c-mux.dtbo
22 dtbo-$(RPI_DT_OVERLAYS) += i2c-pwm-pca9685a.dtbo
23 dtbo-$(RPI_DT_OVERLAYS) += i2c-rtc.dtbo
24 +dtbo-$(RPI_DT_OVERLAYS) += i2c-sensor.dtbo
25 dtbo-$(RPI_DT_OVERLAYS) += i2c0-bcm2708.dtbo
26 dtbo-$(RPI_DT_OVERLAYS) += i2c1-bcm2708.dtbo
27 dtbo-$(RPI_DT_OVERLAYS) += i2s-gpio28-31.dtbo
28 --- a/arch/arm/boot/dts/overlays/README
29 +++ b/arch/arm/boot/dts/overlays/README
30 @@ -283,8 +283,7 @@ Params: swap_lr Reverse
33 Name: bmp085_i2c-sensor
34 -Info: Configures the BMP085/BMP180 digital barometric pressure and temperature
35 - sensors from Bosch Sensortec
36 +Info: This overlay is now deprecated - see i2c-sensor
37 Load: dtoverlay=bmp085_i2c-sensor
40 @@ -536,6 +535,15 @@ Params: abx80x Select o
45 +Info: Adds support for a number of I2C barometric pressure and temperature
47 +Load: dtoverlay=i2c-sensor,<param>=<val>
48 +Params: bmp085 Select the Bosch sensortronic BMP085
50 + bmp280 Select the Bosch sensortronic BMP280
54 Info: Enable the i2c_bcm2708 driver for the i2c0 bus. Not all pin combinations
55 are usable on all platforms.
57 +++ b/arch/arm/boot/dts/overlays/i2c-sensor-overlay.dts
59 +// Definitions for a few digital barometric pressure and temperature sensors
64 + compatible = "brcm,bcm2708";
67 + target = <&i2c_arm>;
69 + #address-cells = <1>;
74 + compatible = "bosch,bmp085";
76 + default-oversampling = <3>;
81 + compatible = "bosch,bmp280";
89 + bmp085 = <&bmp085>,"status";
90 + bmp280 = <&bmp280>,"status";