From patchwork Mon May 2 09:48:58 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Stein X-Patchwork-Id: 12834078 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D504DC433EF for ; Mon, 2 May 2022 09:50:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=STZVudJP5ZjS5ctlsZLnxII3borvNjzQXcX0bx8cUYE=; b=06WnQ005vJlRJH lgZvQ2JJ1ByaRJ19ar2awy0dbkDxVR5bcCRaDQdRjrlTlhwhHorU9hH8eud9v88tPpopajYel4EnJ 1JGETnONe+eJyJQPvPV8S+Ox2H0GSIcT7gy1hvGyb8uO84iwpDzI0VeZzGTy1RdFdv0ndx44pUWtK 3k+q5KucqFPkxrQ2Ajh+vP556lbPPi9F16Oe3N1s5eHu/4VSG9NCByrGr8F72BjTRWJ2RH8z9Xzk+ YtjpMbuqC7zhIyppbnuEEy0WhRyaLbJgqV9LRk2D76QXEvWrAPVi/z3Rxy/wH4QcE2zql6q6sKJsE ElgZfD96RjiyzZ7N26RQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSgI-000gBQ-SU; Mon, 02 May 2022 09:49:27 +0000 Received: from mx1.tq-group.com ([93.104.207.81]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSg7-000g3x-7D for linux-arm-kernel@lists.infradead.org; Mon, 02 May 2022 09:49:16 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484955; x=1683020955; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=7NOVRH5gYXnHf6z2bzLqGROkXli3gZcZvcXNGi/7KrM=; b=WbFc9AfzaoS0x9JjPC3iA4iGe7i8QvTKoZetV02tszFmetjKUz0kC/Do ZZJBanPkwNgArPZrPbsAe2GQVAu+MA5OtkczPUzA9JfPwyMqsiHNUU8s2 Dehnd65eyuqbYBGZL+6AgkVQ4rhx2fYYqSq/t8ZFPdTJtSBujWSLpCqWR LM46sol6pCsJf0VTVQLuN1ltb50BbD2ZBP0EP6FQHcC0rZ9/KeNTKPwCd XfH0rx9FazK2QPnSrKxFJrngqeMk73lOcGNZgGbm117qGElcR6x6OHfc3 DYJRwpolvqxbvkBK1ehmJgQiviRO/p7zgIjb5c5uVW1gAYYRjZd9AA3Ap g==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608911" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Mon, 02 May 2022 11:49:07 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Mon, 02 May 2022 11:49:07 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484947; x=1683020947; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=7NOVRH5gYXnHf6z2bzLqGROkXli3gZcZvcXNGi/7KrM=; b=pm7SJXbP13YfWVUmaFS376Bu24X+XL753slUNXFtd/afgDzCYuQC3tgr HNAjuquZQlLJ8eduliJDJKwUBnRF3yiHV06wII8xfU+OoSsAS6JsOw1rf 1K5TCm2FltrBlcVHZGeYdMUx/tyXUUcqlzWlYa1uwAiQapDVA+0WJpBBa zTFiT4vNAuE6YwwJemVdPbo2qWKyqP6FuaoHy4dAlNboqpkGSPyR/eS6+ O/irDAlqcT0q728nukEQFHYtmeY7BIlODBsPLBr9gKf64Ocr5/komIvd2 A2gZ4bX6AXovMhLej7l8iKre82SeYmpCxwqT5YzVhW2q+NrizrPmqSEzq A==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608910" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 May 2022 11:49:06 +0200 Received: from steina-w.tq-net.de (unknown [10.123.49.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by vtuxmail01.tq-net.de (Postfix) with ESMTPSA id 9421F280075; Mon, 2 May 2022 11:49:06 +0200 (CEST) From: Alexander Stein To: Rob Herring , Krzysztof Kozlowski , Shawn Guo , Sascha Hauer , Fabio Estevam Cc: Markus Niebel , Pengutronix Kernel Team , NXP Linux Team , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Alexander Stein Subject: [PATCH 1/4] arm64: dt: imx8mq: support pwm polarity inversion Date: Mon, 2 May 2022 11:48:58 +0200 Message-Id: <20220502094901.251310-2-alexander.stein@ew.tq-group.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> References: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220502_024915_618911_CF2A1A41 X-CRM114-Status: GOOD ( 15.26 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Markus Niebel The i.MX8MQ has the same PWM IP as i.MX6 / i.MX7. This IP and the driver supporting pwm polarity inversion. Switch CPU device tree fragment to use 3 pwm-cells and correct board device trees. Signed-off-by: Markus Niebel Signed-off-by: Alexander Stein --- arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts | 2 +- arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts | 2 +- arch/arm64/boot/dts/freescale/imx8mq.dtsi | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts b/arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts index 622f3787a186..b86f188a440d 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts @@ -18,7 +18,7 @@ / { backlight_dsi: backlight-dsi { compatible = "pwm-backlight"; /* 200 Hz for the PAM2841 */ - pwms = <&pwm1 0 5000000>; + pwms = <&pwm1 0 5000000 0>; brightness-levels = <0 100>; num-interpolated-steps = <100>; /* Default brightness level (index into the array defined by */ diff --git a/arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts b/arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts index 94a13cb500e6..8956a46788fa 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts +++ b/arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts @@ -18,7 +18,7 @@ backlight: backlight { compatible = "pwm-backlight"; pinctrl-names = "default"; pinctrl-0 = <&pinctrl_backlight>; - pwms = <&pwm2 0 10000>; + pwms = <&pwm2 0 10000 0>; power-supply = <®_main_usb>; enable-gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>; brightness-levels = <0 32 64 128 160 200 255>; diff --git a/arch/arm64/boot/dts/freescale/imx8mq.dtsi b/arch/arm64/boot/dts/freescale/imx8mq.dtsi index 1eca2b431467..49eadb081b19 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mq.dtsi @@ -798,7 +798,7 @@ pwm1: pwm@30660000 { clocks = <&clk IMX8MQ_CLK_PWM1_ROOT>, <&clk IMX8MQ_CLK_PWM1_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -809,7 +809,7 @@ pwm2: pwm@30670000 { clocks = <&clk IMX8MQ_CLK_PWM2_ROOT>, <&clk IMX8MQ_CLK_PWM2_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -820,7 +820,7 @@ pwm3: pwm@30680000 { clocks = <&clk IMX8MQ_CLK_PWM3_ROOT>, <&clk IMX8MQ_CLK_PWM3_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -831,7 +831,7 @@ pwm4: pwm@30690000 { clocks = <&clk IMX8MQ_CLK_PWM4_ROOT>, <&clk IMX8MQ_CLK_PWM4_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; From patchwork Mon May 2 09:48:59 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Stein X-Patchwork-Id: 12834079 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DCDA5C433F5 for ; Mon, 2 May 2022 09:50:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=uti5kZbIEoqGY8jLn+NmdfczXm0bdtyg4GYg3ZeYbRo=; b=JSzuEmySoF5afd EmVYMsyNjyHEW/zTPR9wysdBA7vYGafIMGNMMdwZgkdgjOUzOX9bRHJ9pa99wQFBRjk8QDa/9+kSP cBPgYOaAgSk3pZNyw1LUeXC7fYTUBagwyXfWGPHcjTVK7J9Lsda8dzH5axB9tEnD7InUkdGDP2Z2y uQ494GGKTfMxmhjxWIqHY9m7uQ8/n/fc0ccbGPfTDLMcZ6FM743XL1gYbC80TctKnPDVYWLgCrCeo qfAC0THRzCMB5SQYK/aOsmLMTHKaVCOTU1RwQvY0lQgjtLjoWZgxU5PEYn/rWk5avDOhgGdhE+eYt XSD6G+6LHshvbgH0aGvQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSgR-000gDv-M3; Mon, 02 May 2022 09:49:35 +0000 Received: from mx1.tq-group.com ([93.104.207.81]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSg8-000g6v-C9 for linux-arm-kernel@lists.infradead.org; Mon, 02 May 2022 09:49:18 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484956; x=1683020956; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=kNdxQM4Z358rG+nMcsZbxOxW/RpxRdESr63QyCt4bkA=; b=Iwe2DX11LfqALsNKet6ZTIhTDTzdUqDBt+qoP/kUkSOeLqJH3VD8vcQf Ntr0q/+n/ZbW5h97FvnpjVWXaIXNWIIiyU4NYpsbAExRUmjlfFGta8MXP srb/799h8YKhL/KmyPmC7wzIhi/rrjhm3rXeydVAI6DA8MZla92oOXM/T FGYH4b/QewSThGh1N5IVPf5BOKWYogGiSrvYmLZ2ujtBSDjNDE0qQMszu KvefOY8vB1nLtF9cRczBJ0Mu1Ebh29d1i9zlcaWtWifzp8poHuLqcO0hM 91atMkeMnsFAfLTKB6FK5GVw0U5QQojgc7hwi4YZXCZ62znrM5R1dTQBY g==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608913" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Mon, 02 May 2022 11:49:07 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Mon, 02 May 2022 11:49:07 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484947; x=1683020947; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=kNdxQM4Z358rG+nMcsZbxOxW/RpxRdESr63QyCt4bkA=; b=nLhuRlOUrZ8833DCPm/AElqwpYdyUpORJgUrS6vPHlVdDLmxkAfmTml5 3gTFqNpWPJDYWu+UO7VfX20n730gxawETu9/p4b5UPRjzTTdhoeCpiTDl +gzyCBYqpm9/dOG6lNhbyoVZVQ1HisCPKO6Cyu/w4PIhpiODcy5zpVJeO WP1Ox3uKiAQqSTQO0CjPFHVChjpR44BvRBHpCAc5hZ5ZpOi+0dw1ocTNx MzoDUywPJju/LZreo5hHw4YNXKIYSO2yxErDGtI3bhtZ/oHcyKwe9N9OR j0yYwRgJJYbvpT7WOPUG9D+YDW/a3xLAo/FvNHx+IknI/pDrgYoK3tUl1 w==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608912" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from steina-w.tq-net.de (unknown [10.123.49.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by vtuxmail01.tq-net.de (Postfix) with ESMTPSA id C8C26280078; Mon, 2 May 2022 11:49:06 +0200 (CEST) From: Alexander Stein To: Rob Herring , Krzysztof Kozlowski , Shawn Guo , Sascha Hauer , Fabio Estevam Cc: Markus Niebel , Pengutronix Kernel Team , NXP Linux Team , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Alexander Stein Subject: [PATCH 2/4] arm64: dt: imx8mm: support pwm polarity inversion Date: Mon, 2 May 2022 11:48:59 +0200 Message-Id: <20220502094901.251310-3-alexander.stein@ew.tq-group.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> References: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220502_024916_803113_05A2BCA7 X-CRM114-Status: GOOD ( 14.41 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Markus Niebel The i.MX8M Mini has the same PWM IP as i.MX6 / i.MX7. This IP and the driver supporting pwm polarity inversion. Switch CPU device tree fragment to use 3 pwm-cells and correct board device trees. Signed-off-by: Markus Niebel Signed-off-by: Alexander Stein --- .../boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts | 2 +- arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi | 2 +- arch/arm64/boot/dts/freescale/imx8mm.dtsi | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts b/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts index 154116d01c94..fbc9cc23700a 100644 --- a/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts +++ b/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts @@ -35,7 +35,7 @@ backlight: backlight { brightness-levels = <0 1 10 20 30 40 50 60 70 75 80 90 100>; default-brightness-level = <7>; enable-gpios = <&gpio3 0 GPIO_ACTIVE_HIGH>; - pwms = <&pwm1 0 5000000>; + pwms = <&pwm1 0 5000000 0>; /* Disabled by default, unless display board plugged in. */ status = "disabled"; }; diff --git a/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi index 6a209395452a..c42b966f7a64 100644 --- a/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi @@ -61,7 +61,7 @@ reg_usdhc2_vmmc: regulator-usdhc2 { backlight: backlight { compatible = "pwm-backlight"; - pwms = <&pwm1 0 5000000>; + pwms = <&pwm1 0 5000000 0>; brightness-levels = <0 255>; num-interpolated-steps = <255>; default-brightness-level = <250>; diff --git a/arch/arm64/boot/dts/freescale/imx8mm.dtsi b/arch/arm64/boot/dts/freescale/imx8mm.dtsi index 1ee05677c2dd..1bf070473829 100644 --- a/arch/arm64/boot/dts/freescale/imx8mm.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mm.dtsi @@ -758,7 +758,7 @@ pwm1: pwm@30660000 { clocks = <&clk IMX8MM_CLK_PWM1_ROOT>, <&clk IMX8MM_CLK_PWM1_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -769,7 +769,7 @@ pwm2: pwm@30670000 { clocks = <&clk IMX8MM_CLK_PWM2_ROOT>, <&clk IMX8MM_CLK_PWM2_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -780,7 +780,7 @@ pwm3: pwm@30680000 { clocks = <&clk IMX8MM_CLK_PWM3_ROOT>, <&clk IMX8MM_CLK_PWM3_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -791,7 +791,7 @@ pwm4: pwm@30690000 { clocks = <&clk IMX8MM_CLK_PWM4_ROOT>, <&clk IMX8MM_CLK_PWM4_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; From patchwork Mon May 2 09:49:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Stein X-Patchwork-Id: 12834080 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BDA0FC433F5 for ; Mon, 2 May 2022 09:50:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zTLnrzE7AneWpV9MmyGzxvDOM4OPMGTaidfmWIecs1s=; b=FfHYyvPU4Shhec iW7ZrF7SL3X9c2yGQZhmctVMEfzrlV6OvWOkmKgqKLYTKrfHRzo+cZpxqd3QGtrFP/N8NoSGOTQul eAEZWsqN2hor0k2slWC5dITbEeO1RTF+F75FjE1XTtzjlo+7jk6rJt8/A+YpImdySauxSzr/Ji7aa kKvWFWIWQvumx97HtoKSM/TOFCHV8WxYAOSinOpdvP63dIE6wVs2Rvwn9rDgymRVHZ5YWoJAI1PR9 omXkXUHXhlPklv2Mh/jHg94HvNjz8KipirLXb3A7reZCmwJjPTn4eXiBrLISsCtBmNC2f2KjLhWA/ IPhJCYgVOn2qHxPj05Yw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSgc-000gHn-Dg; Mon, 02 May 2022 09:49:46 +0000 Received: from mx1.tq-group.com ([93.104.207.81]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSg9-000g3x-Fk for linux-arm-kernel@lists.infradead.org; Mon, 02 May 2022 09:49:19 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484957; x=1683020957; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=hg61ERVzrL5sBOFYdRQ0uFMW1DGo0Jl96d3Qgjw0SdU=; b=fAjujaLVjk06GthVK4jGip5/RZaUXVAguvfSrTBFemygjx4nc3cj1/B1 vGH3hKPn2koZd5T4SXPf9x29C3cSO+8QjWbzAM1RwM3j1lzPygwrKiGSL PrBiXSYCXqj27WD2Tf6hR1qEq8RqXd3pGuFcjZFCvoj+F4dJkczW7hjpR aE5dCPfTcoGNs043/qMFls2NBEZVMQ0UkwEjHCbuiYwrY0muzR0BrcMka POa1jAJZAE+spubvRgu4jZNI3J/G9CXpbqdCgpKXP2eOOJ/dMO8EdeXdi 6xhwx6ukaNJKwAYzZMp8Mp1DXUwDZk0NM+6OZWq3C8LTaDzlTwTZqz1US g==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608915" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Mon, 02 May 2022 11:49:07 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Mon, 02 May 2022 11:49:07 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484947; x=1683020947; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=hg61ERVzrL5sBOFYdRQ0uFMW1DGo0Jl96d3Qgjw0SdU=; b=JyxszQcHf9ywHpShM3+wKm3bKGT/kQ/kP4fqET4hAeDbOhr1OdgRdwsB YLAVgdwTFNNn5sGquE0DzQMiQLr/RhMeJ987/eaYt49qC0xoGO5OF0UcF 0oQ3buYLEczNoA8jnURMD9G7sr7625Yr4K388DMYeCI6LRIpYD7MO59I2 T/VHE1f1kp9DvWxsIXPzyIzTvL+IBZcfUzUdv/zciZKU5JgrpwNw4L7VT fCsBZ55wp2Ec7zmrAOLW7KKxSYJBajcVmK0arcWlVktT/u9j2HcbJ/pi1 itF/FLwUCBLXBJPF2rQKaWkEyn1+AZ/g+H2lLcFAtflQW0nCxOT6LVhlh Q==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608914" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from steina-w.tq-net.de (unknown [10.123.49.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by vtuxmail01.tq-net.de (Postfix) with ESMTPSA id 2B911280070; Mon, 2 May 2022 11:49:07 +0200 (CEST) From: Alexander Stein To: Rob Herring , Krzysztof Kozlowski , Shawn Guo , Sascha Hauer , Fabio Estevam Cc: Markus Niebel , Pengutronix Kernel Team , NXP Linux Team , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Alexander Stein Subject: [PATCH 3/4] arm64: dt: imx8mn: support pwm polarity inversion Date: Mon, 2 May 2022 11:49:00 +0200 Message-Id: <20220502094901.251310-4-alexander.stein@ew.tq-group.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> References: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220502_024917_909695_C24B3817 X-CRM114-Status: GOOD ( 12.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Markus Niebel The i.MX8M Nano has the same PWM IP as i.MX6 / i.MX7. This IP and the driver supporting pwm polarity inversion. Switch CPU device tree fragment to use 3 pwm-cells. Signed-off-by: Markus Niebel Signed-off-by: Alexander Stein --- arch/arm64/boot/dts/freescale/imx8mn.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mn.dtsi b/arch/arm64/boot/dts/freescale/imx8mn.dtsi index 8def5d679e7e..e41e1d56f980 100644 --- a/arch/arm64/boot/dts/freescale/imx8mn.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mn.dtsi @@ -705,7 +705,7 @@ pwm1: pwm@30660000 { clocks = <&clk IMX8MN_CLK_PWM1_ROOT>, <&clk IMX8MN_CLK_PWM1_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -716,7 +716,7 @@ pwm2: pwm@30670000 { clocks = <&clk IMX8MN_CLK_PWM2_ROOT>, <&clk IMX8MN_CLK_PWM2_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -727,7 +727,7 @@ pwm3: pwm@30680000 { clocks = <&clk IMX8MN_CLK_PWM3_ROOT>, <&clk IMX8MN_CLK_PWM3_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -738,7 +738,7 @@ pwm4: pwm@30690000 { clocks = <&clk IMX8MN_CLK_PWM4_ROOT>, <&clk IMX8MN_CLK_PWM4_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; From patchwork Mon May 2 09:49:01 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Stein X-Patchwork-Id: 12834081 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 97CE1C433F5 for ; Mon, 2 May 2022 09:51:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=9Y/ffbakCGmPYrR2k17VAg3p2Gfpbe36R435d9YQ+Rk=; b=YJU/lRNV+3ovAF PCuhTgarJn6Yaya0rvdygtT94vrtFhjwp5TzsRp+k1ktaMVAyyYORJAU8mJawm8UIvDgUrhPhQMO6 dgxTZUelt6jT39LxG/f5NwxlgeOGS/Y7ro9Huc69cLazTzRCtglOxAlTPsQTTR5D1gyOPo1mfcNyS /gsEVpIYPeuuMsRk4FFH1shwLd2MWOmhEbEur94eZ8viXecQdJ31H4yDqHgGWfYtfHYAvAjT46VC6 jv8w0iYrrCQQaGxn0RED3eedoO666Q29mYkj7luUgTgRyFNJbSNl0Q4LC7RJQ7FWAyck/8RmpZeXu 8R2Y3GlQlVNNSMcjBy8Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSgn-000gMm-Hb; Mon, 02 May 2022 09:49:57 +0000 Received: from mx1.tq-group.com ([93.104.207.81]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlSgA-000g7x-KW for linux-arm-kernel@lists.infradead.org; Mon, 02 May 2022 09:49:20 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484958; x=1683020958; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ci02NB4QGci9pTeqTiLS0Ke/DzJkZ60fO1FMVNrrSdU=; b=PTaA09BRlOXVxbIgjtE3n2WInM6/pxJJy75GfwruGU7wLFkMEkCDQt+Q JlzTvsnbJ7iWh8RRdOTaubJdQr9BvIUulRQbbn8ybN7vEQWxaFw2g+Xen M7BiadNCc5WXpoGMo7BbnJAFB/iTeygoza6Qjr0xFa1E3cjJZS+Kk6TjH uP9u/pcBFranXFiVXKMsqvN1PrbTxe8V/Ab8VASZAjezVOBKuAPxMCD6h 6XTZK2PrXW1yqpFBe/Q0xotLl2rP2d4ow48ZIzIpmLgENjdqaybtwcBPC Qu6Fh6dPLsBe6UBtI4gpCJbfd3vmrtNb7Nw0JVqGGUOf51cAfDAT/uFfe Q==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608917" Received: from unknown (HELO tq-pgp-pr1.tq-net.de) ([192.168.6.15]) by mx1-pgp.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from mx1.tq-group.com ([192.168.6.7]) by tq-pgp-pr1.tq-net.de (PGP Universal service); Mon, 02 May 2022 11:49:07 +0200 X-PGP-Universal: processed; by tq-pgp-pr1.tq-net.de on Mon, 02 May 2022 11:49:07 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tq-group.com; i=@tq-group.com; q=dns/txt; s=key1; t=1651484947; x=1683020947; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ci02NB4QGci9pTeqTiLS0Ke/DzJkZ60fO1FMVNrrSdU=; b=Ns6FB/gL5wXWiMMAB+Dc0nw82reyemAUdjK4lfKN16g642ETONF1EvXB /hO2CKx/tg+zPPSffA7pD1q1XKa5Z5LCWn+Euz9Fo2FbVDD+LRYsez3K+ 87GvnC5lpyGbUReGpOOT45C+cCc0NoRkoz6iD92hiHuOPmDPvGqRhVD5w HBsF6Lx7wSNkhUShMZsq5GP9NHl1X95pcgb9CKR22if408SriNpeUmOwC gLC1bhQq/9KOyDYVnVNtVZF83iW5HKPWT4jMZINvEEXSTjfXVTUv4J3D8 4/7CCsO9p+iqVZKEGsoKbzQym4bAmB+DMjMRXwlzoxF4xtQDhGhoIAFfF w==; X-IronPort-AV: E=Sophos;i="5.91,190,1647298800"; d="scan'208";a="23608916" Received: from vtuxmail01.tq-net.de ([10.115.0.20]) by mx1.tq-group.com with ESMTP; 02 May 2022 11:49:07 +0200 Received: from steina-w.tq-net.de (unknown [10.123.49.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by vtuxmail01.tq-net.de (Postfix) with ESMTPSA id 64B7F28007C; Mon, 2 May 2022 11:49:07 +0200 (CEST) From: Alexander Stein To: Rob Herring , Krzysztof Kozlowski , Shawn Guo , Sascha Hauer , Fabio Estevam Cc: Markus Niebel , Pengutronix Kernel Team , NXP Linux Team , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Alexander Stein Subject: [PATCH 4/4] arm64: dt: imx8mp: support pwm polarity inversion Date: Mon, 2 May 2022 11:49:01 +0200 Message-Id: <20220502094901.251310-5-alexander.stein@ew.tq-group.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> References: <20220502094901.251310-1-alexander.stein@ew.tq-group.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220502_024919_047594_D7A0D0EB X-CRM114-Status: GOOD ( 12.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Markus Niebel The i.MX8M Plus has the same PWM IP as i.MX6 / i.MX7. This IP and the driver supporting pwm polarity inversion. Switch CPU device tree fragment to use 3 pwm-cells. Tested on MBa8MPxL mainboard. Signed-off-by: Markus Niebel Signed-off-by: Alexander Stein --- arch/arm64/boot/dts/freescale/imx8mp.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi index 7ad824e6b820..89ef26399bfa 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi @@ -567,7 +567,7 @@ pwm1: pwm@30660000 { clocks = <&clk IMX8MP_CLK_PWM1_ROOT>, <&clk IMX8MP_CLK_PWM1_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -578,7 +578,7 @@ pwm2: pwm@30670000 { clocks = <&clk IMX8MP_CLK_PWM2_ROOT>, <&clk IMX8MP_CLK_PWM2_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -589,7 +589,7 @@ pwm3: pwm@30680000 { clocks = <&clk IMX8MP_CLK_PWM3_ROOT>, <&clk IMX8MP_CLK_PWM3_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; }; @@ -600,7 +600,7 @@ pwm4: pwm@30690000 { clocks = <&clk IMX8MP_CLK_PWM4_ROOT>, <&clk IMX8MP_CLK_PWM4_ROOT>; clock-names = "ipg", "per"; - #pwm-cells = <2>; + #pwm-cells = <3>; status = "disabled"; };