From patchwork Sun Dec 4 10:43:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 29400 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1734321wrr; Sun, 4 Dec 2022 02:47:11 -0800 (PST) X-Google-Smtp-Source: AA0mqf5+K7/zKd4y4P9bRSLQ9voXxzzsKzgkPmbSu6dJGVqtwuMhB1Uk6a5//SIINSMSPg0QjUcB X-Received: by 2002:a17:903:28f:b0:189:8a36:1b70 with SMTP id j15-20020a170903028f00b001898a361b70mr34772974plr.12.1670150831380; Sun, 04 Dec 2022 02:47:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670150831; cv=none; d=google.com; s=arc-20160816; b=mxdkmSTFZrAYTqfpIo8mBF//mIfYtVMBLTpDTCVYg8pEhasxZpR1i31ZApuDs9FsY1 lbGDqcXgzuh8JczyO1BnMts5zStfuTMjRhB6EO/eQWQoRJNUdk1MfpEU6REls//dv6lo CTZJ97tqDc5RYhcRzWXIACvW5nslh/xiPiusqLlhK1Iiu7XcUKCAEwi/npAo8v41xFdu riU+vhpY2kiBOJhSTTd091vxRN3CfX89QrdCJpGMu1rtOQ1i7SuPHKHNguzXUlEUX2T9 vCPYqMX7yNR8oo3LW0n0iB7oSUJ/waQyu3TRVQgaNiFZS+Ib18LuCaJpk21HWWhGmyjl uF+A== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=mkpnkgS661CL81tREqROjXb5VEYTJXJHdLfxFTagbbs=; b=b3J/1fHq3n6zZtKeGzWl7Bby7/jckt0ER2FVBwW1KOs80P7mfziSmuP5ZcqRBti+07 rYN1sKcvPIf4j8mxXSMdIFuqZhkGIzp/zDMT/gWhFWHOfN+b+HYxHUFkXkiB5y5CqD4R 8Wa2Up28bEHbmSpcsDDINkoOAIMfqcK80r1e8WFTPo6FvbRJ5E+xIvI4nZdA3HhK2Pxn 7rtIXu2m4hGiM1WERpf3UrbOMLPeXtJQ424eHHZ2A83GbIRc70xr4YqkRU47Nm/9T6a/ KNrfPLZwZuceD+/uU/dVEI4SmF1dPoc7fvCYzlyC8Kk28fh1Rgj+nODsKTs8Ae0L4LtQ FZEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eyNqK8eh; 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=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m20-20020a170902e41400b0018863dbf3b1si10732550ple.284.2022.12.04.02.46.58; Sun, 04 Dec 2022 02:47:11 -0800 (PST) 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=@linaro.org header.s=google header.b=eyNqK8eh; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230156AbiLDKne (ORCPT + 99 others); Sun, 4 Dec 2022 05:43:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36090 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229995AbiLDKnc (ORCPT ); Sun, 4 Dec 2022 05:43:32 -0500 Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 01627E086 for ; Sun, 4 Dec 2022 02:43:31 -0800 (PST) Received: by mail-lf1-x12b.google.com with SMTP id f21so13435942lfm.9 for ; Sun, 04 Dec 2022 02:43:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=mkpnkgS661CL81tREqROjXb5VEYTJXJHdLfxFTagbbs=; b=eyNqK8ehsyoOUvVJLufQ4cBhyIoGEL8itAxijDj/69skdhojwUO9aEX6194hgAbilG JtUv8ryuYSlmJf79TOm7u+qaJxs4aRRX/zxOfIy3yYhYEokxgv0dLcRA5q75bFrs0NKi cMocSXaPOcjITs7K0srq4EJDfFi9snUEy7IPTe0V2cyuO4LagEwmpiiCOpKBffdCJeDU ObmRoXmP6xF5bA8iGaDaQK83wR9udl5gDBtquqoYSznoz6xMSJmTTWunRtp+/xx/K8ow MceG8sv0IlTallBvAADkCN/Je74E4AZgHL+QFRtcZ33T0UnYUxdR2BnUvjpdv2v+P9eD Jq3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=mkpnkgS661CL81tREqROjXb5VEYTJXJHdLfxFTagbbs=; b=Db2isWN/RYMYslm7bqlyjnOFTnWbthHbyV1w0UOO6TgEzPmLWWBqXeVYUEhL78QSea xTDgOw2BYTAd7HrcfE6K3pc5HUVIoXueZXnHNLT+/VPBggQZ6L+aiAj+lqRHenwf5iDo kicboKH+lyNcNDo3CA5bZBGmW781+d+3l+F+DfwBwRjll5keb5sjU/eXs+VapfLkU5ww ArIYnMg+DYP1/T39e7nFDLaRNwD4NGVW1r64/OO4DsZpLCBn9pZdEFg+mAIezbW/ODOm Cu7VlDZb/APV19CfdLDVVTxvBxUyic5xvjylJ9KzuYOYd0plB8MSBZUv6BhGJP1lAtxY /XTA== X-Gm-Message-State: ANoB5pkLa8cSmDTEEAa2XN7A1Qo9U6yEZup9uvU/WvfJltIbwONtHBvA t7t7uf2Tu4DMoqUXRnSm58+nBg== X-Received: by 2002:ac2:5979:0:b0:4b5:7607:3191 with SMTP id h25-20020ac25979000000b004b576073191mr11601lfp.93.1670150609232; Sun, 04 Dec 2022 02:43:29 -0800 (PST) Received: from krzk-bin.NAT.warszawa.vectranet.pl (088156142067.dynamic-2-waw-k-3-2-0.vectranet.pl. [88.156.142.67]) by smtp.gmail.com with ESMTPSA id w13-20020a05651c118d00b0026c42f67eb8sm893318ljo.7.2022.12.04.02.43.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Dec 2022 02:43:28 -0800 (PST) From: Krzysztof Kozlowski To: Pavel Machek , Rob Herring , Krzysztof Kozlowski , Sean Young , linux-leds@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Cc: Krzysztof Kozlowski Subject: [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema Date: Sun, 4 Dec 2022 11:43:21 +0100 Message-Id: <20221204104323.117974-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1751280078138737013?= X-GMAIL-MSGID: =?utf-8?q?1751280078138737013?= Convert the GPIO IR LED bindings to DT schema. Signed-off-by: Krzysztof Kozlowski --- .../bindings/leds/irled/gpio-ir-tx.txt | 14 -------- .../bindings/leds/irled/gpio-ir-tx.yaml | 36 +++++++++++++++++++ MAINTAINERS | 1 + 3 files changed, 37 insertions(+), 14 deletions(-) delete mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt create mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml diff --git a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt deleted file mode 100644 index cbe8dfd29715..000000000000 --- a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt +++ /dev/null @@ -1,14 +0,0 @@ -Device tree bindings for IR LED connected through gpio pin which is used as -remote controller transmitter. - -Required properties: - - compatible: should be "gpio-ir-tx". - - gpios : Should specify the IR LED GPIO, see "gpios property" in - Documentation/devicetree/bindings/gpio/gpio.txt. Active low LEDs - should be indicated using flags in the GPIO specifier. - -Example: - irled@0 { - compatible = "gpio-ir-tx"; - gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>; - }; diff --git a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml new file mode 100644 index 000000000000..5839d00c7089 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml @@ -0,0 +1,36 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/irled/gpio-ir-tx.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: IR LED connected through GPIO pin + +maintainers: + - Sean Young + +description: + IR LED connected through GPIO pin which is used as remote controller + transmitter. + +properties: + compatible: + const: gpio-ir-tx + + gpios: + maxItems: 1 + +required: + - compatible + - gpios + +additionalProperties: false + +examples: + - | + #include + + irled { + compatible = "gpio-ir-tx"; + gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>; + }; diff --git a/MAINTAINERS b/MAINTAINERS index be71999cea73..25b7fbf09e7b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -8839,6 +8839,7 @@ GPIO IR Transmitter M: Sean Young L: linux-media@vger.kernel.org S: Maintained +F: Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml F: drivers/media/rc/gpio-ir-tx.c GPIO MOCKUP DRIVER From patchwork Sun Dec 4 10:43:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 29401 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1735577wrr; Sun, 4 Dec 2022 02:52:25 -0800 (PST) X-Google-Smtp-Source: AA0mqf451Jh99KRZb+RCVZj6ZBeIkUPhST7mc/Uy7IFYidtmiMJC1zeq0jal5Kn94n6DkUokmQbP X-Received: by 2002:aa7:cb09:0:b0:463:ff10:4ff with SMTP id s9-20020aa7cb09000000b00463ff1004ffmr59802470edt.290.1670151145286; Sun, 04 Dec 2022 02:52:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670151145; cv=none; d=google.com; s=arc-20160816; b=UOhj+mD2XN8lQ1EPAIVjOZm6kE2ul619RgnjPhH6j/6bkP8I2F+gANjAAOn02R5mgN s6vNGOWxTsqage8G/EpWl5TelWzdlHkXCfEcmcVh6aTDTwP+m/L56vjSyQhb9ZfxWdsq AEz/b4a4IUCKa2Suq39MU5U4s0xR4wsD3GuiuB4xEdaLxJKu4EfsLYTGHU4w16FMiqi3 Isnhv9KHzIFVIDFnnmSCDQJ1nIE2xaE4sL8opBCsyDZbGy/aik5HoGpH2yQcYzsTEkVe gT5bX5i0Ha9otSAHUiTDVr/jqT6XpSSslVDEV9uVeRFa5QB3Dhev/zSrfqSu556+bKYh OeUw== 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=vUtAt+SuxLZPa/RB4QNwZAEnF/ypq5aNumvuCyCA9xc=; b=K3IrhGeQPuIsOp67cMpMlAB5cGOS6IpwYz8kUYOEXZ0LFMK9vqgilSsTzV3MxbtYyt nUKodhGlimqsKfKebU4vSZnIKleLDwBeYrl+I1RTHC90kmnYlDW5QaRBXpYWnsiaJwgo 4wpGtL26+on2oN/xKHiMs6ALyxFFGmzkLiLwxdQGfcmNkgEtvo+u//7rrt9P8K+4RdX0 dhskMUdLSEUka6vFFVz/cs31d9XmC1rpRumNtCS170JyDhQucbSgJOJiRvYyAKmOeodA tRUyZnmh+Q/9eMhvLfuRn1HsJPdnkhlI4eHZxcsxfmUJMz0X+G8whPCf4zZ615HMxUUN qaWQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="b13/F8a+"; 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=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t1-20020a170906268100b007470b52f94esi7837032ejc.199.2022.12.04.02.52.00; Sun, 04 Dec 2022 02:52:25 -0800 (PST) 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=@linaro.org header.s=google header.b="b13/F8a+"; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230169AbiLDKng (ORCPT + 99 others); Sun, 4 Dec 2022 05:43:36 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36126 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230137AbiLDKnd (ORCPT ); Sun, 4 Dec 2022 05:43:33 -0500 Received: from mail-lj1-x229.google.com (mail-lj1-x229.google.com [IPv6:2a00:1450:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DAA88E0FE for ; Sun, 4 Dec 2022 02:43:31 -0800 (PST) Received: by mail-lj1-x229.google.com with SMTP id x6so10361694lji.10 for ; Sun, 04 Dec 2022 02:43:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=vUtAt+SuxLZPa/RB4QNwZAEnF/ypq5aNumvuCyCA9xc=; b=b13/F8a+rUqvNZ/XYyBYbeH+jtIJ+hV+icTub0e55c0B1U8hk+1IIlKae3gTssRMZm 0Vpyp4gKhqCxneqz0Iz9Vjop23XhBF9VKCDhfNeAoMRTgXlzFcAFTrOWmSDaETLAwsDw EpjoigAnFinTxpZrrU2YHxR5iA6OrnnkQzqYkVrEmidIy9AASxwyu4ZR9QL8U4x95FfW wB6dECAuda6SZgu5CiKnwVJSBmpN+p66EHu0a6Tkx2fNZiugxyyZnQreZRsoT1Mr3eDJ dwIUmoROfqCAHTKo8d2oMhuZYD2O9uwQHlF5BGvTdTl5X8OVYaWIAZI8PnI8k9Q2bEyF 596w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vUtAt+SuxLZPa/RB4QNwZAEnF/ypq5aNumvuCyCA9xc=; b=BUtjtHIDn4eEVGcXwKfOxiCBAo1ykSKytMUKHxPPnyhefu+OSjIr7ho4fPtAaW/y68 mP7+xSqRt2oUUfCRmi6su1YbfoFGrwDjKSBhk7/HNFnmhqRnjuzSfkiTXw7eTc4K+Arh 2fm0UtpBnZt0GaUlaCm1rxrz2mf6Aih7RXbVUXEdgjt7LYklubtX8xRC4qyNRqsLVeSn 4RgG2jMYU4b4OUGvIjoOEeUJikHGstnTvc/sD9+m9KZnn1TmpOXFUdvFx+01qrVk2Q+7 7bIwK/giXTwoSf7X95s2q7imv5gZvJ0lVEf3S/kIjq7j5danuk/3S658+zeCtI6dbkbT qP7Q== X-Gm-Message-State: ANoB5pk9GMCR0CiSshQ3v+e3az5maXARmalMVdCAL5jY1PEuoAegnpVd HHgupKz+jtbaUskmAx/VvpdY7w== X-Received: by 2002:a2e:b0fb:0:b0:279:9db3:7e58 with SMTP id h27-20020a2eb0fb000000b002799db37e58mr9729626ljl.341.1670150610240; Sun, 04 Dec 2022 02:43:30 -0800 (PST) Received: from krzk-bin.NAT.warszawa.vectranet.pl (088156142067.dynamic-2-waw-k-3-2-0.vectranet.pl. [88.156.142.67]) by smtp.gmail.com with ESMTPSA id w13-20020a05651c118d00b0026c42f67eb8sm893318ljo.7.2022.12.04.02.43.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Dec 2022 02:43:29 -0800 (PST) From: Krzysztof Kozlowski To: Pavel Machek , Rob Herring , Krzysztof Kozlowski , Sean Young , linux-leds@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Cc: Krzysztof Kozlowski Subject: [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: convert to DT schema Date: Sun, 4 Dec 2022 11:43:22 +0100 Message-Id: <20221204104323.117974-2-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221204104323.117974-1-krzysztof.kozlowski@linaro.org> References: <20221204104323.117974-1-krzysztof.kozlowski@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1751280407266041442?= X-GMAIL-MSGID: =?utf-8?q?1751280407266041442?= Convert the PWM IR LED bindings to DT schema. Signed-off-by: Krzysztof Kozlowski --- .../bindings/leds/irled/pwm-ir-tx.txt | 13 ------- .../bindings/leds/irled/pwm-ir-tx.yaml | 34 +++++++++++++++++++ MAINTAINERS | 1 + 3 files changed, 35 insertions(+), 13 deletions(-) delete mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt create mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml diff --git a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt deleted file mode 100644 index 66e5672c2e3d..000000000000 --- a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt +++ /dev/null @@ -1,13 +0,0 @@ -Device tree bindings for IR LED connected through pwm pin which is used as -remote controller transmitter. - -Required properties: - - compatible: should be "pwm-ir-tx". - - pwms : PWM property to point to the PWM device (phandle)/port (id) - and to specify the period time to be used: <&phandle id period_ns>; - -Example: - irled { - compatible = "pwm-ir-tx"; - pwms = <&pwm0 0 10000000>; - }; diff --git a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml new file mode 100644 index 000000000000..f2a6fa140f38 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml @@ -0,0 +1,34 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/irled/pwm-ir-tx.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: IR LED connected through PWM pin + +maintainers: + - Sean Young + +description: + IR LED connected through PWM pin which is used as remote controller + transmitter. + +properties: + compatible: + const: pwm-ir-tx + + pwms: + maxItems: 1 + +required: + - compatible + - pwms + +additionalProperties: false + +examples: + - | + irled { + compatible = "pwm-ir-tx"; + pwms = <&pwm0 0 10000000>; + }; diff --git a/MAINTAINERS b/MAINTAINERS index 25b7fbf09e7b..e3f3c3e53f77 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -16960,6 +16960,7 @@ PWM IR Transmitter M: Sean Young L: linux-media@vger.kernel.org S: Maintained +F: Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml F: drivers/media/rc/pwm-ir-tx.c PWM SUBSYSTEM From patchwork Sun Dec 4 10:43:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 29402 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1735988wrr; Sun, 4 Dec 2022 02:54:01 -0800 (PST) X-Google-Smtp-Source: AA0mqf7evdQzV/2XzdskeJFBI/jjloELWe+AbBNrVcJboViB3mNR328wXIAmyEv5KyxQ1fQ30y0d X-Received: by 2002:a05:6a00:450b:b0:574:c544:3b5e with SMTP id cw11-20020a056a00450b00b00574c5443b5emr43300889pfb.66.1670151241398; Sun, 04 Dec 2022 02:54:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670151241; cv=none; d=google.com; s=arc-20160816; b=kkZUoAFzHUjSs7TZh+bg8HaOvfYKo5n7g4GPURe+VK7eXhPRuZ8G8kq4SnjiDi3wRc STPmbTYiqyQHS97fYBYXtsv/vgdd+PYdgQqu1xM1sOeMexnEDB34LPElEtv7DBdu7kSm KD52t6TPCSMf7TEPQd9CAdXAZuxdnqt6LTyFBh1BHpX2Xaj16VonprhmyfM2MNyOgJ2p M99Q4RUtdm2BTr8289nnmpgYCGRXpNuisEcV2qhhnUXNtI++QH0SM2G/x42jxJ1M2eLy t0oS6zZusfwBCs8XlcdzJxpQLzPQB5vm/Cb6BLPpnlQ3I2dcqzFr1FtbQptauhzAvcJd nKPA== 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=wKxfJBtE9R/RmkSFqJuCs7AeQseJPQiGfkmXFgO8eRE=; b=iJCF0V3HOJlE+TLIyFaangU/mGWkHyvUpbkkJ8cypuLMfiUYpk8YNipfkNlBbkrrho +ZiCN4ojBWqOJg0z3DZWedBB5TjUdOOgjZXhMnzz+k0SphY9vPhNx3/qCZZw0nTgtL8U OgXMcKB4yQ4lrqqJZYO5ULtHlg8BrVOfSeJRDlPi2pkYDkvwlG7CdujdMvS0wkDKjtUW Ekn/AFQd+kjMVqfPdhjDTxWEz17/3nAPqDp7992V9JKGayjzbXcnBDfIjbRfjME46IX6 1vrW4hxT+9nbjDlIPJTV/QlQwF1UFCML2kKtiQqXaalYyJwgeJdRCpjY2EWkm/FSYLU+ 6NAg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NygHRy+2; 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=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x1-20020a1709029a4100b00184c33ddeb8si10788844plv.23.2022.12.04.02.53.47; Sun, 04 Dec 2022 02:54:01 -0800 (PST) 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=@linaro.org header.s=google header.b=NygHRy+2; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230146AbiLDKnj (ORCPT + 99 others); Sun, 4 Dec 2022 05:43:39 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36128 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230160AbiLDKne (ORCPT ); Sun, 4 Dec 2022 05:43:34 -0500 Received: from mail-lj1-x235.google.com (mail-lj1-x235.google.com [IPv6:2a00:1450:4864:20::235]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 10A19F037 for ; Sun, 4 Dec 2022 02:43:32 -0800 (PST) Received: by mail-lj1-x235.google.com with SMTP id b9so10380558ljr.5 for ; Sun, 04 Dec 2022 02:43:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=wKxfJBtE9R/RmkSFqJuCs7AeQseJPQiGfkmXFgO8eRE=; b=NygHRy+2Rq2KEujc0x//tVDRPbwYxxkTgX0T8P3Q/v5z3iW/dLE0/BDRYVBawgtseE eL4FgeKIuUuY2tGMaqMlw9fZdNPZZt5ePgAH/Eto9xbh3DkxYud33xSJB0mbnxefpfGU sGu/ZcKSq53vZmHeg6kuu/+i8rdk4dLzICM3EF49ab4hc6THSqcTNkFoACIedqh2yyA8 PvQul1RCxyko/hakFADrfzbTHb2my/63HUGLIpbG9/gKzhCn5WlkxUs9yQnDmxWE4cq6 0qJqpG35dZ8ctNqOCwJ81nwzpUanTauxvBV9obWzs3HI++tIB48tCyzp5VkEWowh4pKF zfxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wKxfJBtE9R/RmkSFqJuCs7AeQseJPQiGfkmXFgO8eRE=; b=clRW+bQcjbHcNsKNHtqJ+cP4xnzaFyNiFvhvWfNOncWoRPvR9huxVBablr0QDmnybD 1e2+FL/Wj2nwVUX171lASeDemcXuRozI950BAP7QiuRN5plm0E5KQe7kRQKX+78eyaCT mLRA3UG77yX7EBghbVK1o2n9yKQj7AWqRbfgegSErkN65c/68w4PmZbBG2sS33nBLVme ABCfxHuyagcHmhyNrCI5RonMwUIn2PpuBKhpWXVwlklUSqkVS1Qd+UnLs+UCnZn5ySiT x1Iqjeiy/+O8Suqy4nII6ZFoi83grWZQMZ6tfMaD/LA7Y99LN3CVeS1Ch0d0i+NayAWt 5E2w== X-Gm-Message-State: ANoB5pmWqhJY+7QlktHqZ91jpO3EptXzCQrmR05t3PdQ4BPGV4MJU8du 6+wdCpD5+0QbVZVRYqw4NpXjneVEzUikSuKcODU= X-Received: by 2002:a05:651c:1187:b0:279:d72d:215e with SMTP id w7-20020a05651c118700b00279d72d215emr3750216ljo.184.1670150611194; Sun, 04 Dec 2022 02:43:31 -0800 (PST) Received: from krzk-bin.NAT.warszawa.vectranet.pl (088156142067.dynamic-2-waw-k-3-2-0.vectranet.pl. [88.156.142.67]) by smtp.gmail.com with ESMTPSA id w13-20020a05651c118d00b0026c42f67eb8sm893318ljo.7.2022.12.04.02.43.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Dec 2022 02:43:30 -0800 (PST) From: Krzysztof Kozlowski To: Pavel Machek , Rob Herring , Krzysztof Kozlowski , Sean Young , linux-leds@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Cc: Krzysztof Kozlowski Subject: [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: convert to DT schema Date: Sun, 4 Dec 2022 11:43:23 +0100 Message-Id: <20221204104323.117974-3-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221204104323.117974-1-krzysztof.kozlowski@linaro.org> References: <20221204104323.117974-1-krzysztof.kozlowski@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1751280508207165484?= X-GMAIL-MSGID: =?utf-8?q?1751280508207165484?= Convert the SPI IR LED bindings to DT schema. Signed-off-by: Krzysztof Kozlowski --- .../bindings/leds/irled/ir-spi-led.yaml | 61 +++++++++++++++++++ .../bindings/leds/irled/spi-ir-led.txt | 29 --------- 2 files changed, 61 insertions(+), 29 deletions(-) create mode 100644 Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml delete mode 100644 Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt diff --git a/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml new file mode 100644 index 000000000000..72cadebf6e3e --- /dev/null +++ b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml @@ -0,0 +1,61 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/irled/ir-spi-led.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: IR LED connected through SPI bus + +maintainers: + - Sean Young + +description: + IR LED switch is connected to the MOSI line of the SPI device and the data + is delivered through that. + +allOf: + - $ref: /schemas/spi/spi-peripheral-props.yaml# + +properties: + compatible: + const: ir-spi-led + + reg: + maxItems: 1 + + duty-cycle: + $ref: /schemas/types.yaml#/definitions/uint8 + enum: [50, 60, 70, 75, 80, 90] + description: + Percentage of one period in which the signal is active. + + led-active-low: + type: boolean + description: + Output is negated with a NOT gate. + + power-supply: true + +required: + - compatible + - reg + +unevaluatedProperties: false + +examples: + - | + spi { + #address-cells = <1>; + #size-cells = <0>; + + irled@0 { + compatible = "ir-spi-led"; + reg = <0x0>; + + duty-cycle = /bits/ 8 <60>; + led-active-low; + power-supply = <&irda_regulator>; + spi-max-frequency = <5000000>; + }; + }; + diff --git a/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt b/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt deleted file mode 100644 index 83ff1b4d70a6..000000000000 --- a/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt +++ /dev/null @@ -1,29 +0,0 @@ -Device tree bindings for IR LED connected through SPI bus which is used as -remote controller. - -The IR LED switch is connected to the MOSI line of the SPI device and the data -are delivered thourgh that. - -Required properties: - - compatible: should be "ir-spi-led". - -Optional properties: - - duty-cycle: 8 bit value that represents the percentage of one period - in which the signal is active. It can be 50, 60, 70, 75, 80 or 90. - - led-active-low: boolean value that specifies whether the output is - negated with a NOT gate. - - power-supply: specifies the power source. It can either be a regulator - or a gpio which enables a regulator, i.e. a regulator-fixed as - described in - Documentation/devicetree/bindings/regulator/fixed-regulator.yaml - -Example: - - irled@0 { - compatible = "ir-spi-led"; - reg = <0x0>; - spi-max-frequency = <5000000>; - power-supply = <&vdd_led>; - led-active-low; - duty-cycle = /bits/ 8 <60>; - };