From patchwork Sun Nov 15 19:29:43 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906719 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D2AE6138B for ; Sun, 15 Nov 2020 19:32:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id AE27122314 for ; Sun, 15 Nov 2020 19:32:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="FjnY8I/c" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727806AbgKOTcD (ORCPT ); Sun, 15 Nov 2020 14:32:03 -0500 Received: from mail.kernel.org ([198.145.29.99]:33936 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcC (ORCPT ); Sun, 15 Nov 2020 14:32:02 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B0B7622450; Sun, 15 Nov 2020 19:32:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468722; bh=Y9VRZv8QmXJaUps1gLHyOqX1ST1UIegXHzcwBj9wxfw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FjnY8I/cMkmpQkM0CTfJNB5SvFH4ttyt90efwXx/arz+J8Xe5MPpV8ltwClgU0kLI 462J/mBkiqm1hC3/vDoLsIXl/eO/PxO5uZPj0p8iVrEq0hLPn8xIWGkwo42UW+QN/h ZEo3Iv8HssGRu7trccEZUUxmolRMqU9oKBJ5cya8= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Rob Herring , Andy Gross , Bjorn Andersson , Jishnu Prakash Subject: [PATCH 1/9] dt-bindings:iio:qcom-spmi-vadc drop incorrect io-channel-ranges from example Date: Sun, 15 Nov 2020 19:29:43 +0000 Message-Id: <20201115192951.1073632-2-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron io-channel-ranges is a property for io-channel consumers. Here it is in an example of a provider of channels so doesn't do anything useful. Recent additions to dt-schema check this property is only provided alongside io-channels which is not true here and hence an error is reported. Signed-off-by: Jonathan Cameron Reported-by: Rob Herring Cc: Andy Gross Cc: Bjorn Andersson Cc: Jishnu Prakash Reviewed-by: Bjorn Andersson --- Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml | 3 --- 1 file changed, 3 deletions(-) diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml index 7f4f827c57a7..95cc705b961b 100644 --- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml +++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml @@ -48,8 +48,6 @@ properties: description: End of conversion interrupt. - io-channel-ranges: true - required: - compatible - reg @@ -249,7 +247,6 @@ examples: #address-cells = <1>; #size-cells = <0>; #io-channel-cells = <1>; - io-channel-ranges; /* Channel node */ adc-chan@39 { From patchwork Sun Nov 15 19:29:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906721 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 00649174A for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DA42D22314 for ; Sun, 15 Nov 2020 19:32:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="gE3DpyVo" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727813AbgKOTcE (ORCPT ); Sun, 15 Nov 2020 14:32:04 -0500 Received: from mail.kernel.org ([198.145.29.99]:33958 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcE (ORCPT ); Sun, 15 Nov 2020 14:32:04 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B729B2417E; Sun, 15 Nov 2020 19:32:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468724; bh=5fY4eeo9CrRYbF8Nlf9tRn8nQcFcZJBg4wDkbHq0/ig=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gE3DpyVoqa1TyoXadHx70cfvLVhq109IFbxAcAxYgocrsVt0isbTS8lyeTIOMOh09 n1mH79mdqMMdCLvvYtWGvL4OKRgn4dzyqf8LB7nqACZTgbAnjKzz0i/qMkbcfD/O43 Z/QuVCAGZL+lfMYiTaOWTZl46CsiQuzTzW5l7LoA= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Rob Herring , Krzysztof Kozlowski Subject: [PATCH 2/9] dt-bindings:iio:samsung,exynos-adc: drop missuse of io-channel-ranges Date: Sun, 15 Nov 2020 19:29:44 +0000 Message-Id: <20201115192951.1073632-3-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron io-channel-ranges is a property for consumers of io-channels, not providers. Hence it is not relevant in this binding or the examples given. Recent changes to dt-schema result int his being reported as an error as a dependency is enforced between this property and io-channels. Signed-off-by: Jonathan Cameron Reported-by: Rob Herring Cc: Krzysztof Kozlowski Reviewed-by: Krzysztof Kozlowski --- .../devicetree/bindings/iio/adc/samsung,exynos-adc.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Documentation/devicetree/bindings/iio/adc/samsung,exynos-adc.yaml b/Documentation/devicetree/bindings/iio/adc/samsung,exynos-adc.yaml index 5ebb0ab250bd..c65921e66dc1 100644 --- a/Documentation/devicetree/bindings/iio/adc/samsung,exynos-adc.yaml +++ b/Documentation/devicetree/bindings/iio/adc/samsung,exynos-adc.yaml @@ -49,8 +49,6 @@ properties: "#io-channel-cells": const: 1 - io-channel-ranges: true - vdd-supply: true samsung,syscon-phandle: @@ -130,7 +128,6 @@ examples: reg = <0x12d10000 0x100>; interrupts = <0 106 0>; #io-channel-cells = <1>; - io-channel-ranges; clocks = <&clock 303>; clock-names = "adc"; @@ -156,7 +153,6 @@ examples: reg = <0x126C0000 0x100>; interrupts = <0 137 0>; #io-channel-cells = <1>; - io-channel-ranges; clocks = <&cmu CLK_TSADC>, <&cmu CLK_SCLK_TSADC>; From patchwork Sun Nov 15 19:29:45 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906723 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 25D911746 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0AC7722314 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="lHt65GJE" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727817AbgKOTcG (ORCPT ); Sun, 15 Nov 2020 14:32:06 -0500 Received: from mail.kernel.org ([198.145.29.99]:33976 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcG (ORCPT ); Sun, 15 Nov 2020 14:32:06 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 7A5582417F; Sun, 15 Nov 2020 19:32:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468725; bh=bvLxYjGb0ESyOfmh5/AmeZXqHUg0YeOtUAUB/hHekQ4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lHt65GJEJZ76VpgxM2WSZkuV8He4tsPcC6NvQytNxJ3xUjDu6LrikywZhQ8fv4z9D 9+UyE8xOAKX0dd4c8l60bzQjgB8wYgpJp7fp18P9JFdGHNDamwxarzOfy4Qf+MCCxo HOQttwboxz3blH2VYC+UiUuiVQq6+8iRdNoeLT1w= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Florian Fainelli Subject: [PATCH 3/9] ARM: dts: Cygnus: Drop incorrect io-channel-ranges property. Date: Sun, 15 Nov 2020 19:29:45 +0000 Message-Id: <20201115192951.1073632-4-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property applies to consumers of io-channels. In this case we have a provider so the property is not used. Not dt_schema will now detect this as an error due to a dependency between this property and the io-channels property. Signed-off-by: Jonathan Cameron Cc: Florian Fainelli --- arch/arm/boot/dts/bcm-cygnus.dtsi | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/boot/dts/bcm-cygnus.dtsi b/arch/arm/boot/dts/bcm-cygnus.dtsi index dacaef2c14ca..0025c88f660c 100644 --- a/arch/arm/boot/dts/bcm-cygnus.dtsi +++ b/arch/arm/boot/dts/bcm-cygnus.dtsi @@ -591,7 +591,6 @@ touchscreen: touchscreen@180a6000 { adc: adc@180a6000 { compatible = "brcm,iproc-static-adc"; #io-channel-cells = <1>; - io-channel-ranges; adc-syscon = <&ts_adc_syscon>; clocks = <&asiu_clks BCM_CYGNUS_ASIU_ADC_CLK>; clock-names = "tsc_clk"; From patchwork Sun Nov 15 19:29:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906725 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4BFFF17EC for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2E29D2417E for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="tsmJnbvW" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727823AbgKOTcI (ORCPT ); Sun, 15 Nov 2020 14:32:08 -0500 Received: from mail.kernel.org ([198.145.29.99]:33990 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcH (ORCPT ); Sun, 15 Nov 2020 14:32:07 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0F706238E6; Sun, 15 Nov 2020 19:32:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468727; bh=OwGWd3NHSyxIgpZkw6VPdhPHWtFfwz9xDkexRakgkbA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tsmJnbvWp1czk4RW3dYSN2MSX88EEmDIFO8p7SPt+3vleXSOM0qosKa8DrFGhdHBW cVGx2j0JjPczy5ZXE7iLhejSYB/s5IuHrmIqNAr8SftGU+Snq6AjiB6GkmHF/N1olA o21+bs3J6Lmfxe23hvKs9qrm0vsuSue0d3C3H3Q0= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Krzysztof Kozlowski Subject: [PATCH 4/9] ARM: dts: exynos: Drop incorrect use of io-channel-ranges Date: Sun, 15 Nov 2020 19:29:46 +0000 Message-Id: <20201115192951.1073632-5-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property is only relevant to consumers of io-channels, not providers. All these dtsi files have it alongside #io-channel-cells which indicates they are providers of io-channels, not consumers. Note that dt_schema will now flag this up due to a dependency between this property and io-channels. Signed-off-by: Jonathan Cameron Cc: Krzysztof Kozlowski --- arch/arm/boot/dts/exynos3250.dtsi | 1 - arch/arm/boot/dts/exynos4412.dtsi | 1 - arch/arm/boot/dts/exynos5250.dtsi | 1 - arch/arm/boot/dts/exynos54xx.dtsi | 1 - 4 files changed, 4 deletions(-) diff --git a/arch/arm/boot/dts/exynos3250.dtsi b/arch/arm/boot/dts/exynos3250.dtsi index a1e93fb7f694..2dcc6b848937 100644 --- a/arch/arm/boot/dts/exynos3250.dtsi +++ b/arch/arm/boot/dts/exynos3250.dtsi @@ -439,7 +439,6 @@ adc: adc@126c0000 { clock-names = "adc", "sclk"; clocks = <&cmu CLK_TSADC>, <&cmu CLK_SCLK_TSADC>; #io-channel-cells = <1>; - io-channel-ranges; samsung,syscon-phandle = <&pmu_system_controller>; status = "disabled"; }; diff --git a/arch/arm/boot/dts/exynos4412.dtsi b/arch/arm/boot/dts/exynos4412.dtsi index e76881dc0014..a9df16015fef 100644 --- a/arch/arm/boot/dts/exynos4412.dtsi +++ b/arch/arm/boot/dts/exynos4412.dtsi @@ -274,7 +274,6 @@ adc: adc@126c0000 { clocks = <&clock CLK_TSADC>; clock-names = "adc"; #io-channel-cells = <1>; - io-channel-ranges; samsung,syscon-phandle = <&pmu_system_controller>; status = "disabled"; }; diff --git a/arch/arm/boot/dts/exynos5250.dtsi b/arch/arm/boot/dts/exynos5250.dtsi index bd2d8835dd36..c43e99b6c1cc 100644 --- a/arch/arm/boot/dts/exynos5250.dtsi +++ b/arch/arm/boot/dts/exynos5250.dtsi @@ -844,7 +844,6 @@ adc: adc@12d10000 { clocks = <&clock CLK_ADC>; clock-names = "adc"; #io-channel-cells = <1>; - io-channel-ranges; samsung,syscon-phandle = <&pmu_system_controller>; status = "disabled"; }; diff --git a/arch/arm/boot/dts/exynos54xx.dtsi b/arch/arm/boot/dts/exynos54xx.dtsi index 8aa5117e58ce..18a7559054dc 100644 --- a/arch/arm/boot/dts/exynos54xx.dtsi +++ b/arch/arm/boot/dts/exynos54xx.dtsi @@ -101,7 +101,6 @@ adc: adc@12d10000 { reg = <0x12d10000 0x100>; interrupts = ; #io-channel-cells = <1>; - io-channel-ranges; status = "disabled"; }; From patchwork Sun Nov 15 19:29:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906727 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6E1CD17D5 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5373E22384 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="bvfGXOZu" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727834AbgKOTcK (ORCPT ); Sun, 15 Nov 2020 14:32:10 -0500 Received: from mail.kernel.org ([198.145.29.99]:34000 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcJ (ORCPT ); Sun, 15 Nov 2020 14:32:09 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9BFA922453; Sun, 15 Nov 2020 19:32:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468728; bh=EygQxIRuhbt1ue+G0jOWi99anW905/Chac5nTAS9+tY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=bvfGXOZu+HrkThdEC2OpyNpOLHHJkDU0MTOBkX33kyvNQ8nV7P6tCqi63/Ynf7IDx aI6dZrUZaRyC71Jdbi0faEftTQhCeZG67Zd5z4O8ZQC92RE6bdg7PNUahwAi93FzPv YWL0wal9yfvdcd4vA9F4UBZcOFDtMw83oBr+zUns= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Krzysztof Kozlowski Subject: [PATCH 5/9] ARM: dts: s5pv210: Drop incorrect use of io-channel-ranges property. Date: Sun, 15 Nov 2020 19:29:47 +0000 Message-Id: <20201115192951.1073632-6-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property is relevant to consumers of io-channels. Here it is used by a provider. dt_schema will now report and error as this property must be in the same node as io-channels and it is not here. Signed-off-by: Jonathan Cameron Cc: Krzysztof Kozlowski --- arch/arm/boot/dts/s5pv210.dtsi | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi index 2871351ab907..353ba7b09a0c 100644 --- a/arch/arm/boot/dts/s5pv210.dtsi +++ b/arch/arm/boot/dts/s5pv210.dtsi @@ -149,7 +149,6 @@ adc: adc@e1700000 { clocks = <&clocks CLK_TSADC>; clock-names = "adc"; #io-channel-cells = <1>; - io-channel-ranges; status = "disabled"; }; From patchwork Sun Nov 15 19:29:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906729 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8E82614B3 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 759AD22384 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="PmyfKjVc" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727838AbgKOTcL (ORCPT ); Sun, 15 Nov 2020 14:32:11 -0500 Received: from mail.kernel.org ([198.145.29.99]:34014 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcK (ORCPT ); Sun, 15 Nov 2020 14:32:10 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2E77B22450; Sun, 15 Nov 2020 19:32:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468730; bh=x71USCiHj/GQY0jK4FvaaciNOHo6Au4EPLPmumf7GyQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PmyfKjVc/PsBbRPrgZo/RXBK1rZ3UiMRaEwzD1Ph7azHx3eyCaGf3j/S4uZkIMbyx QwMfXCJHa/S9udvCMSSb6JFLfpXAbONWEUHsfVlFogYaCgHKSYRI9BcVy4o9EovfYC Tv3+2lYWzTBuq96CsmutcXDo7qhG/N2JnEfxbcZY= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Andy Gross , Bjorn Andersson Subject: [PATCH 6/9] ARM: dts: qcom-pma8084: Drop incorrect use of io-channel-ranges Date: Sun, 15 Nov 2020 19:29:48 +0000 Message-Id: <20201115192951.1073632-7-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property is used by io-channel consumers, not providers so should not present here. Note dt_schema will now detect this error as there is a dependency between this property and io-channels. Signed-off-by: Jonathan Cameron Cc: Andy Gross Cc: Bjorn Andersson --- arch/arm/boot/dts/qcom-pma8084.dtsi | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/boot/dts/qcom-pma8084.dtsi b/arch/arm/boot/dts/qcom-pma8084.dtsi index ea1ca166165c..e921c5e93a5d 100644 --- a/arch/arm/boot/dts/qcom-pma8084.dtsi +++ b/arch/arm/boot/dts/qcom-pma8084.dtsi @@ -68,7 +68,6 @@ pma8084_vadc: vadc@3100 { #address-cells = <1>; #size-cells = <0>; #io-channel-cells = <1>; - io-channel-ranges; die_temp { reg = ; From patchwork Sun Nov 15 19:29:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906731 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B37E1138B for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 98A0F22314 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="U5SwWYWu" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727846AbgKOTcM (ORCPT ); Sun, 15 Nov 2020 14:32:12 -0500 Received: from mail.kernel.org ([198.145.29.99]:34030 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcM (ORCPT ); Sun, 15 Nov 2020 14:32:12 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DFBE922384; Sun, 15 Nov 2020 19:32:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468732; bh=9K6SJF2DPcYP95bCSQS5MwGaGuNC39mHRymwVDL/LaE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=U5SwWYWu/7mh0rCtohgZYikZl7vMPJbrFNQ5NVDwP1Yxbw4jkuaodub8Okx+lP7+N 5FSaawtrBkIHtNJvcp+QoCQVmCVcEC6kCxJnmzan0wCGCnJCclBAZs8NEIHXnf6YeM UoFMSkFmSM4OT+UKzMxXvbwsoTI/p+SDInhm1KPg= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Krzysztof Kozlowski Subject: [PATCH 7/9] ARM: dts: s5pv210-aries: Drop unneeded io-channel-ranges property. Date: Sun, 15 Nov 2020 19:29:49 +0000 Message-Id: <20201115192951.1073632-8-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property is only useful if a node has children as it allows them to then use io-channel properties in the parent. Here there are no children. This is harmless, but we are planning to shortly drop this property as it is rarely used correctly and there is little reason it would ever be needed as we can just provide the io-channels property to any child nodes that need it. Signed-off-by: Jonathan Cameron Cc: Krzysztof Kozlowski --- arch/arm/boot/dts/s5pv210-aries.dtsi | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/boot/dts/s5pv210-aries.dtsi b/arch/arm/boot/dts/s5pv210-aries.dtsi index bd4450dbdcb6..1ad9582db1ee 100644 --- a/arch/arm/boot/dts/s5pv210-aries.dtsi +++ b/arch/arm/boot/dts/s5pv210-aries.dtsi @@ -589,7 +589,6 @@ gp2a_shunt: current-sense-shunt { io-channels = <&adc 9>; shunt-resistor-micro-ohms = <47000000>; /* 47 ohms */ #io-channel-cells = <0>; - io-channel-ranges; }; }; From patchwork Sun Nov 15 19:29:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906733 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D2C7115E6 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BA2BF22314 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Walhpthl" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727851AbgKOTcO (ORCPT ); Sun, 15 Nov 2020 14:32:14 -0500 Received: from mail.kernel.org ([198.145.29.99]:34050 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcN (ORCPT ); Sun, 15 Nov 2020 14:32:13 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 7350124170; Sun, 15 Nov 2020 19:32:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468733; bh=qg7S1FYh+40H4HhjM4ldZ9PsZ0Izqr4zzHGY0I4mLyk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Walhpthl8BjFhAjx5iuwb9HpKPxp4OEaSIT0aYJBPypDKznqw3lptkJpkUtnuAHFD uhvDM0MSZFdjhtfWmdpVS8pwU3H0guEmz8h+mWKDazWw7QmhczK3evW1OrY9DUIHAy QWvHYMAbr4KMqoB+jzf/9LtITterFHpYwWHL/iFk= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Krzysztof Kozlowski Subject: [PATCH 8/9] arm64: dts: exynos: Drop incorrect use of io-channel-ranges property. Date: Sun, 15 Nov 2020 19:29:50 +0000 Message-Id: <20201115192951.1073632-9-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property is for consumers of io-channels. Here it is used in providers of those channels. Note dt_schema will currently flag this as an error due to a dependency between this property and io-channels. Signed-off-by: Jonathan Cameron Cc: Krzysztof Kozlowski --- arch/arm64/boot/dts/exynos/exynos5433.dtsi | 1 - arch/arm64/boot/dts/exynos/exynos7.dtsi | 1 - 2 files changed, 2 deletions(-) diff --git a/arch/arm64/boot/dts/exynos/exynos5433.dtsi b/arch/arm64/boot/dts/exynos/exynos5433.dtsi index 8eb4576da8f3..ac33372f611b 100644 --- a/arch/arm64/boot/dts/exynos/exynos5433.dtsi +++ b/arch/arm64/boot/dts/exynos/exynos5433.dtsi @@ -1445,7 +1445,6 @@ adc: adc@14d10000 { clock-names = "adc"; clocks = <&cmu_peric CLK_PCLK_ADCIF>; #io-channel-cells = <1>; - io-channel-ranges; status = "disabled"; }; diff --git a/arch/arm64/boot/dts/exynos/exynos7.dtsi b/arch/arm64/boot/dts/exynos/exynos7.dtsi index b9ed6a33e290..1f59e437e606 100644 --- a/arch/arm64/boot/dts/exynos/exynos7.dtsi +++ b/arch/arm64/boot/dts/exynos/exynos7.dtsi @@ -567,7 +567,6 @@ adc: adc@13620000 { clocks = <&clock_peric0 PCLK_ADCIF>; clock-names = "adc"; #io-channel-cells = <1>; - io-channel-ranges; status = "disabled"; }; From patchwork Sun Nov 15 19:29:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11906735 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id F2B78174A for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D917022314 for ; Sun, 15 Nov 2020 19:32:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="IMQZo7ii" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727852AbgKOTcQ (ORCPT ); Sun, 15 Nov 2020 14:32:16 -0500 Received: from mail.kernel.org ([198.145.29.99]:34076 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726923AbgKOTcQ (ORCPT ); Sun, 15 Nov 2020 14:32:16 -0500 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 093B0238E6; Sun, 15 Nov 2020 19:32:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605468735; bh=ErJov3gozQbcXRWPQ/ExCFfzkMh9py6GNRxpW3I4Dyw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IMQZo7iiN9bX+UpHwQTM+8TlQe73QrxY7IAvT0Lo1E9nFVBKV4oMRXQL5+0D1ty3g gyE/niTL0fVhcY8PXeaVsjYaZ864QtSJzwG2oqqKF7OROum5JSmZrgeGie8yMKy3+/ Ko3rrnEiXb7Xih6VUPFSBZG1ihMonan1agWgKkuU= From: Jonathan Cameron To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: robh+dt@kernel.org, Jonathan Cameron , Guenter Roeck , Lars-Peter Clausen Subject: [RFC PATCH 9/9] iio: inkern: Drop io-channel-ranges dt property support Date: Sun, 15 Nov 2020 19:29:51 +0000 Message-Id: <20201115192951.1073632-10-jic23@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201115192951.1073632-1-jic23@kernel.org> References: <20201115192951.1073632-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron This property has been almost exclusively missused in mainline and we don't actually have any instances of it being necessary. As such Rob Herring suggested we just drop it and I can't immediately see any reason to disagree. If anyone has an out of tree dts file that makes use of this then let me know. I'm not against keeping the code, but documenting it as a deprecated property not to be used in new dts files. Note build tested only. If someone could give it a sanity check on a platform that uses this interface that would be great. If not I'll mock something up before applying this. Signed-off-by: Jonathan Cameron Cc: Guenter Roeck Cc: Lars-Peter Clausen --- drivers/iio/inkern.c | 49 +++++++++++++++----------------------------- 1 file changed, 17 insertions(+), 32 deletions(-) diff --git a/drivers/iio/inkern.c b/drivers/iio/inkern.c index ede99e0d5371..85a6f6103ee9 100644 --- a/drivers/iio/inkern.c +++ b/drivers/iio/inkern.c @@ -184,40 +184,25 @@ static struct iio_channel *of_iio_channel_get_by_name(struct device_node *np, const char *name) { struct iio_channel *chan = NULL; - - /* Walk up the tree of devices looking for a matching iio channel */ - while (np) { - int index = 0; - - /* - * For named iio channels, first look up the name in the - * "io-channel-names" property. If it cannot be found, the - * index will be an error code, and of_iio_channel_get() - * will fail. - */ - if (name) - index = of_property_match_string(np, "io-channel-names", + int index = 0; + + /* + * For named iio channels, first look up the name in the + * "io-channel-names" property. If it cannot be found, the + * index will be an error code, and of_iio_channel_get() + * will fail. + */ + if (name) + index = of_property_match_string(np, "io-channel-names", name); - chan = of_iio_channel_get(np, index); - if (!IS_ERR(chan) || PTR_ERR(chan) == -EPROBE_DEFER) - break; - else if (name && index >= 0) { - pr_err("ERROR: could not get IIO channel %pOF:%s(%i)\n", - np, name ? name : "", index); - return NULL; - } + chan = of_iio_channel_get(np, index); + if (!IS_ERR(chan) || PTR_ERR(chan) == -EPROBE_DEFER) + return chan; + else if (name && index >= 0) + pr_err("ERROR: could not get IIO channel %pOF:%s(%i)\n", + np, name ? name : "", index); - /* - * No matching IIO channel found on this node. - * If the parent node has a "io-channel-ranges" property, - * then we can try one of its channels. - */ - np = np->parent; - if (np && !of_get_property(np, "io-channel-ranges", NULL)) - return NULL; - } - - return chan; + return NULL; } static struct iio_channel *of_iio_channel_get_all(struct device *dev)