Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp4572807pxb; Wed, 20 Apr 2022 06:08:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWO9vm5FVmm4Axn9R8mO1FDs7rVClxZGgB/YxX6ummQ/8TGyK6dysQU2AXrMmpsdgb71yx X-Received: by 2002:a17:907:7d8b:b0:6ef:f0c9:9498 with SMTP id oz11-20020a1709077d8b00b006eff0c99498mr5534921ejc.706.1650460109950; Wed, 20 Apr 2022 06:08:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650460109; cv=none; d=google.com; s=arc-20160816; b=ta1sd0Kmu08MwFK1pkUXH+YdRzJElbFhTJ6kN4Lxb5rwcSLT6ffMvghx7f4MaAToEW WQcdf2wJzOg8TbMmQRO/Y7nrHo/eis7Nu0Tq440B7tUks/z2hiEifz1x9AfYqHTUUM/E m9qfKpkcQqNgce30oKMzYJhrXIOTskxZpVrEVYfvJpA9eRQwD97XWtLdrBYKDvgIf8Lp jB4C5z+Te6v3q/ooW8tTvw5RVtEFuK3Ebl6ToBGGMYJ5JyW+gSlqGD4IYnP48s2qrbi5 7Hu/Z115i4bKoXmrhy48jvKeTFFOm06UGBw8Sf1SU2L0eLl73wVqQEGCAeo29rMp0tZ9 AicQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uTjYvD2H2yAhu4F9ELwLlkHbskBphdGN/dCfYNdPzmY=; b=XydOatgIGNveMXGiOUjo/feREOK9LQDCqK6V8AbhCTlUizkVE5dUyv2nqd+A3Pkhq5 pi0B159V+WLU45wMCdZdd7ftxDccdcxmcUAdl1UYaCYmeUMy1rQb/VDm32nmaNjiYs3f oX+UAUmT5qqh9GSuETyUMMYVH1gh4OUBG+y6n6TGxa+tuvL5xULlr4V+sU3r4pFP1MDj uMd59lWuFK2Wuvg2x/xw0qA2Q0fv96epjIlxatWz5cIH4gYW4D8yxs8uRCw9wykaaYIr 5tARFPBLlFUx8i8IoJDZ1BYxu911g0+dZQsf/P/I9E6AqbotInRrkOii7nQsfZoPdw9Z hfeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=JsAk0oGM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u10-20020a50950a000000b0041d7dba939asi1359073eda.170.2022.04.20.06.08.04; Wed, 20 Apr 2022 06:08:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=JsAk0oGM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1357756AbiDSUz0 (ORCPT + 99 others); Tue, 19 Apr 2022 16:55:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43106 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1355188AbiDSUzX (ORCPT ); Tue, 19 Apr 2022 16:55:23 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B0AFD3F8B0 for ; Tue, 19 Apr 2022 13:52:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1650401558; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=uTjYvD2H2yAhu4F9ELwLlkHbskBphdGN/dCfYNdPzmY=; b=JsAk0oGMq5ro4mWZ0p/8TBqFG/ibOBAumaQaRkYddRZbxomusknQoU5NF1OHKQsao8uOCB cDN08/lsJGgysSKABI2AhYWXsrf6aI48tsTqrFgVBvbYM2tE7Vj7wtNBGmmU4S1/56+E/W I/d759PGvfLB13saU8onPnO+mNlwIUU= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-454-mH1b93fDN2Oc2Nk-0m7bzw-1; Tue, 19 Apr 2022 16:52:37 -0400 X-MC-Unique: mH1b93fDN2Oc2Nk-0m7bzw-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 246E91C00BA0; Tue, 19 Apr 2022 20:52:28 +0000 (UTC) Received: from cmirabil.remote.csb (unknown [10.22.8.24]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7697A2166B4F; Tue, 19 Apr 2022 20:52:27 +0000 (UTC) From: Charles Mirabile To: linux-kernel@vger.kernel.org Cc: Charles Mirabile , Serge Schneider , Stefan Wahren , Nicolas Saenz Julienne , Mattias Brugger , linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, fedora-rpi@googlegroups.com, Miguel Ojeda , Rob Herring , Krzysztof Kozlowski , Dmitry Torokhov , Lee Jones , devicetree@vger.kernel.org, linux-input@vger.kernel.org, Mwesigwa Guma , Joel Savitz Subject: [PATCH v9 4/6] dt-bindings: mfd: sensehat: Add Raspberry Pi Sense HAT schema Date: Tue, 19 Apr 2022 16:51:56 -0400 Message-Id: <20220419205158.28088-5-cmirabil@redhat.com> In-Reply-To: <20220419205158.28088-1-cmirabil@redhat.com> References: <20220419205158.28088-1-cmirabil@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch adds the device tree bindings for the Sense HAT and each of its children devices in yaml form. Co-developed-by: Mwesigwa Guma Signed-off-by: Mwesigwa Guma Co-developed-by: Joel Savitz Signed-off-by: Joel Savitz Signed-off-by: Charles Mirabile --- .../raspberrypi,sensehat-display.yaml | 27 +++++++++ .../input/raspberrypi,sensehat-joystick.yaml | 32 ++++++++++ .../bindings/mfd/raspberrypi,sensehat.yaml | 58 +++++++++++++++++++ 3 files changed, 117 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..5e41d6b7817d --- /dev/null +++ b/Documentation/devicetree/bindings/auxdisplay/raspberrypi,sensehat-display.yaml @@ -0,0 +1,27 @@ +# 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 + - Mwesigwa Guma + - Joel Savitz + +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..2c8bc10e6436 --- /dev/null +++ b/Documentation/devicetree/bindings/input/raspberrypi,sensehat-joystick.yaml @@ -0,0 +1,32 @@ +# 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 + - Mwesigwa Guma + - Joel Savitz + +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..6ac43dfc0270 --- /dev/null +++ b/Documentation/devicetree/bindings/mfd/raspberrypi,sensehat.yaml @@ -0,0 +1,58 @@ +# 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 + - Mwesigwa Guma + - Joel Savitz + +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 + 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