From: Charles Mirabile <cmirabil@redhat.com>
To: linux-kernel@vger.kernel.org
Cc: Charles Mirabile <cmirabil@redhat.com>,
Peter Robinson <pbrobinson@gmail.com>,
Serge Schneider <serge@raspberrypi.org>,
Stefan Wahren <stefan.wahren@i2se.com>,
Nicolas Saenz Julienne <nicolassaenzj@gmail.com>,
Mattias Brugger <mbrugger@suse.com>,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org, rh-kdlp@googlegroups.com,
Miguel Ojeda <ojeda@kernel.org>, Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Florian Fainelli <f.fainelli@gmail.com>,
Broadcom internal kernel review list
<bcm-kernel-feedback-list@broadcom.com>,
Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Lee Jones <lee.jones@linaro.org>,
devicetree@vger.kernel.org, linux-input@vger.kernel.org,
Joel Savitz <jsavitz@redhat.com>,
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Subject: [PATCH 3/5] dt-bindings: mfd: sensehat: Add Raspberry Pi Sense HAT schema
Date: Tue, 23 Aug 2022 13:41:56 -0400 [thread overview]
Message-ID: <20220823174158.45579-4-cmirabil@redhat.com> (raw)
In-Reply-To: <20220823174158.45579-1-cmirabil@redhat.com>
This patch adds the device tree bindings for the Sense HAT
and each of its children devices in yaml form.
Co-developed-by: Joel Savitz <jsavitz@redhat.com>
Signed-off-by: Joel Savitz <jsavitz@redhat.com>
Signed-off-by: Charles Mirabile <cmirabil@redhat.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
.../raspberrypi,sensehat-display.yaml | 26 +++++++++
.../input/raspberrypi,sensehat-joystick.yaml | 31 ++++++++++
.../bindings/mfd/raspberrypi,sensehat.yaml | 57 +++++++++++++++++++
3 files changed, 114 insertions(+)
create mode 100644 Documentation/devicetree/bindings/auxdisplay/raspberrypi,sensehat-display.yaml
create mode 100644 Documentation/devicetree/bindings/input/raspberrypi,sensehat-joystick.yaml
create mode 100644 Documentation/devicetree/bindings/mfd/raspberrypi,sensehat.yaml
diff --git a/Documentation/devicetree/bindings/auxdisplay/raspberrypi,sensehat-display.yaml b/Documentation/devicetree/bindings/auxdisplay/raspberrypi,sensehat-display.yaml
new file mode 100644
index 000000000000..0cf59b0a519c
--- /dev/null
+++ b/Documentation/devicetree/bindings/auxdisplay/raspberrypi,sensehat-display.yaml
@@ -0,0 +1,26 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/auxdisplay/raspberrypi,sensehat-display.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Raspberry Pi Sensehat Display
+
+maintainers:
+ - Charles Mirabile <cmirabil@redhat.com>
+ - Joel Savitz <jsavitz@redhat.com>
+
+description:
+ This device is part of the sensehat multi function device.
+ For more information see ../mfd/raspberrypi,sensehat.yaml.
+
+ This device features a programmable 8x8 RGB LED matrix.
+
+properties:
+ compatible:
+ const: raspberrypi,sensehat-display
+
+required:
+ - compatible
+
+additionalProperties: false
diff --git a/Documentation/devicetree/bindings/input/raspberrypi,sensehat-joystick.yaml b/Documentation/devicetree/bindings/input/raspberrypi,sensehat-joystick.yaml
new file mode 100644
index 000000000000..98b03878a570
--- /dev/null
+++ b/Documentation/devicetree/bindings/input/raspberrypi,sensehat-joystick.yaml
@@ -0,0 +1,31 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/input/raspberrypi,sensehat-joystick.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Raspberry Pi Sensehat Joystick
+
+maintainers:
+ - Charles Mirabile <cmirabil@redhat.com>
+ - Joel Savitz <jsavitz@redhat.com>
+
+description:
+ This device is part of the sensehat multi function device.
+ For more information see ../mfd/raspberrypi,sensehat.yaml.
+
+ This device features a five button joystick (up, down,left,
+ right, click)
+
+properties:
+ compatible:
+ const: raspberrypi,sensehat-joystick
+
+ interrupts:
+ maxItems: 1
+
+required:
+ - compatible
+ - interrupts
+
+additionalProperties: false
diff --git a/Documentation/devicetree/bindings/mfd/raspberrypi,sensehat.yaml b/Documentation/devicetree/bindings/mfd/raspberrypi,sensehat.yaml
new file mode 100644
index 000000000000..bc53834fbaa7
--- /dev/null
+++ b/Documentation/devicetree/bindings/mfd/raspberrypi,sensehat.yaml
@@ -0,0 +1,57 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mfd/raspberrypi,sensehat.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Raspberry Pi Sensehat
+
+maintainers:
+ - Charles Mirabile <cmirabil@redhat.com>
+ - Joel Savitz <jsavitz@redhat.com>
+
+description:
+ The Raspberry Pi Sensehat is an addon board originally developed
+ for the Raspberry Pi that has a joystick and an 8x8 RGB LED display
+ as well as several environmental sensors. It connects via i2c and
+ a gpio for irq.
+
+properties:
+ compatible:
+ const: raspberrypi,sensehat
+
+ reg:
+ maxItems: 1
+
+ joystick:
+ $ref: /schemas/input/raspberrypi,sensehat-joystick.yaml#
+
+ display:
+ $ref: /schemas/auxdisplay/raspberrypi,sensehat-display.yaml#
+
+required:
+ - compatible
+ - reg
+ - joystick
+ - display
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ hat@46 {
+ compatible = "raspberrypi,sensehat";
+ reg = <0x46>;
+ display {
+ compatible = "raspberrypi,sensehat-display";
+ };
+ joystick {
+ compatible = "raspberrypi,sensehat-joystick";
+ interrupts = <23 IRQ_TYPE_EDGE_RISING>;
+ };
+ };
+ };
--
2.31.1
next parent reply other threads:[~2022-08-23 19:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220823174158.45579-1-cmirabil@redhat.com>
2022-08-23 17:41 ` Charles Mirabile [this message]
2022-08-24 12:13 ` [PATCH 3/5] dt-bindings: mfd: sensehat: Add Raspberry Pi Sense HAT schema Matthias Brugger
2022-09-06 2:47 ` Bagas Sanjaya
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220823174158.45579-4-cmirabil@redhat.com \
--to=cmirabil@redhat.com \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=f.fainelli@gmail.com \
--cc=jsavitz@redhat.com \
--cc=krzk+dt@kernel.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=lee.jones@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=mbrugger@suse.com \
--cc=nicolassaenzj@gmail.com \
--cc=ojeda@kernel.org \
--cc=pbrobinson@gmail.com \
--cc=rh-kdlp@googlegroups.com \
--cc=robh+dt@kernel.org \
--cc=serge@raspberrypi.org \
--cc=stefan.wahren@i2se.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).