From patchwork Mon Oct 9 20:53:38 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 115304 Delivered-To: patch@linaro.org Received: by 10.140.22.163 with SMTP id 32csp2984513qgn; Mon, 9 Oct 2017 13:53:48 -0700 (PDT) X-Google-Smtp-Source: AOwi7QARAXgOxvwm5FFYd4JIa2f4tU8zVTjhZYxjhls7AHgcWUOKbg/w59E/CJ5HPiCavoB3ZTyp X-Received: by 10.98.103.93 with SMTP id b90mr11127231pfc.2.1507582428503; Mon, 09 Oct 2017 13:53:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1507582428; cv=none; d=google.com; s=arc-20160816; b=AsFvPeYXt+9eZF57YkQkd1wHDVgHwVwFIsxTr0+5w+1uzanj/Fohj5vn50aCXhGhQC p1DF+cHG2MCMSNNegUMkXEugEQnCcxtglfEPybHdn4en0w8YXfjZQKc/fDlr02JRhEaQ y/eF1QN5Z167JBCZQSgj1lmJqHXZZPZdnoMOhhgbkVZo7L9cVj2KVlCbkEwMl64cItvv Hv65uI4/JsynITa51z/mKoivhj0WKzbmJevyYx8e1rQJ91/0bnBLv4WC0xuTE8JpUmzO hwx5ZF3rOxZbCQ7HadZOGumJiWpDXNAtcKkHxEvm2syZr6OUfuRUYs2E4TGbO8NYNAC3 knNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=LIFKJYbjHwtFx45l46eemNbYZgInbjZJNCNtM59orVk=; b=Hw7HzogbcKAP6wwfn2djDvAlirWpR0JORnQe8xRIFTh+lCM/fec/qiCZpqBUoI/n0M wyXXf0NB6C+lj1xDOXFT8n5t8Av/GefH+dknUd415qGCfmUh44LlLGGfC1p2HUFli58r xUjyE3QFz1vyZeFrTP6IFABcsRXLATwNn4d0V5b+mJDwW+RjFh1UWYr50gwJdMaiL/Cl ZJkAVUvwnEdxW29J5wAKTRbrehnHmdf3gSwvS+GVAnDKnqFztKjfNp26JdxvUYXD2D55 4QTLKYbG4DPOM9PHEOVx6eACjcDItXvZNP0Fllzegc5pJ/26FZhRHrFZJjuFWVL0nGg9 xyyA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d37si7687937plb.674.2017.10.09.13.53.48; Mon, 09 Oct 2017 13:53:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755486AbdJIUxq (ORCPT + 5 others); Mon, 9 Oct 2017 16:53:46 -0400 Received: from mail.free-electrons.com ([62.4.15.54]:44583 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755414AbdJIUxo (ORCPT ); Mon, 9 Oct 2017 16:53:44 -0400 Received: by mail.free-electrons.com (Postfix, from userid 110) id 492722092E; Mon, 9 Oct 2017 22:53:41 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.free-electrons.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost (LFbn-TOU-1-209-191.w86-201.abo.wanadoo.fr [86.201.56.191]) by mail.free-electrons.com (Postfix) with ESMTPSA id 2318F208C1; Mon, 9 Oct 2017 22:53:41 +0200 (CEST) From: Maxime Ripard To: Chen-Yu Tsai , Maxime Ripard , linus.walleij@linaro.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org Subject: [PATCH v2 2/3] pinctrl: sunxi: Disable strict mode for old pinctrl drivers Date: Mon, 9 Oct 2017 22:53:38 +0200 Message-Id: X-Mailer: git-send-email 2.13.6 In-Reply-To: References: In-Reply-To: References: Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Old pinctrl drivers will need to disable strict mode for various reasons, among which: - Some DT will still have a pinctrl group for each GPIO used, which will be rejected by pin_request. While we could remove those nodes, we still have to deal with old DTs. - Some GPIOs on these boards need to have their pin configuration changed (for bias or current), and there's no clear migration path Let's disable the strict mode on those SoCs so that there's no breakage. Signed-off-by: Maxime Ripard --- drivers/pinctrl/sunxi/pinctrl-sun4i-a10.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun5i.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun6i-a31-r.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun6i-a31.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun8i-a23.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun8i-a33.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun8i-h3-r.c | 3 ++- drivers/pinctrl/sunxi/pinctrl-sun8i-h3.c | 3 ++- drivers/pinctrl/sunxi/pinctrl-sun9i-a80-r.c | 1 + drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c | 1 + 11 files changed, 13 insertions(+), 2 deletions(-) -- git-series 0.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/pinctrl/sunxi/pinctrl-sun4i-a10.c b/drivers/pinctrl/sunxi/pinctrl-sun4i-a10.c index f763d8d62d6e..295e48fc94bc 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun4i-a10.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun4i-a10.c @@ -1289,6 +1289,7 @@ static const struct sunxi_pinctrl_desc sun4i_a10_pinctrl_data = { .npins = ARRAY_SIZE(sun4i_a10_pins), .irq_banks = 1, .irq_read_needs_mux = true, + .disable_strict_mode = true, }; static int sun4i_a10_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun5i.c b/drivers/pinctrl/sunxi/pinctrl-sun5i.c index 47afd558b114..27ec99e81c4c 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun5i.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun5i.c @@ -713,6 +713,7 @@ static const struct sunxi_pinctrl_desc sun5i_pinctrl_data = { .pins = sun5i_pins, .npins = ARRAY_SIZE(sun5i_pins), .irq_banks = 1, + .disable_strict_mode = true, }; static int sun5i_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun6i-a31-r.c b/drivers/pinctrl/sunxi/pinctrl-sun6i-a31-r.c index 49a1deb97bb7..a00246d3dd49 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun6i-a31-r.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun6i-a31-r.c @@ -106,6 +106,7 @@ static const struct sunxi_pinctrl_desc sun6i_a31_r_pinctrl_data = { .npins = ARRAY_SIZE(sun6i_a31_r_pins), .pin_base = PL_BASE, .irq_banks = 2, + .disable_strict_mode = true, }; static int sun6i_a31_r_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun6i-a31.c b/drivers/pinctrl/sunxi/pinctrl-sun6i-a31.c index 951a25c18815..82ffaf466892 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun6i-a31.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun6i-a31.c @@ -965,6 +965,7 @@ static const struct sunxi_pinctrl_desc sun6i_a31_pinctrl_data = { .pins = sun6i_a31_pins, .npins = ARRAY_SIZE(sun6i_a31_pins), .irq_banks = 4, + .disable_strict_mode = true, }; static int sun6i_a31_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c b/drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c index 67ee6f9b3b68..8a08c4afc6a8 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c @@ -93,6 +93,7 @@ static const struct sunxi_pinctrl_desc sun8i_a23_r_pinctrl_data = { .npins = ARRAY_SIZE(sun8i_a23_r_pins), .pin_base = PL_BASE, .irq_banks = 1, + .disable_strict_mode = true, }; static int sun8i_a23_r_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun8i-a23.c b/drivers/pinctrl/sunxi/pinctrl-sun8i-a23.c index 721b6935baf3..402fd7d21e7b 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun8i-a23.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun8i-a23.c @@ -563,6 +563,7 @@ static const struct sunxi_pinctrl_desc sun8i_a23_pinctrl_data = { .pins = sun8i_a23_pins, .npins = ARRAY_SIZE(sun8i_a23_pins), .irq_banks = 3, + .disable_strict_mode = true, }; static int sun8i_a23_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun8i-a33.c b/drivers/pinctrl/sunxi/pinctrl-sun8i-a33.c index ef1e0bef4099..da387211a75e 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun8i-a33.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun8i-a33.c @@ -486,6 +486,7 @@ static const struct sunxi_pinctrl_desc sun8i_a33_pinctrl_data = { .npins = ARRAY_SIZE(sun8i_a33_pins), .irq_banks = 2, .irq_bank_base = 1, + .disable_strict_mode = true, }; static int sun8i_a33_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun8i-h3-r.c b/drivers/pinctrl/sunxi/pinctrl-sun8i-h3-r.c index ebfd9a26628c..b795a199e240 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun8i-h3-r.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun8i-h3-r.c @@ -82,7 +82,8 @@ static const struct sunxi_pinctrl_desc sun8i_h3_r_pinctrl_data = { .npins = ARRAY_SIZE(sun8i_h3_r_pins), .irq_banks = 1, .pin_base = PL_BASE, - .irq_read_needs_mux = true + .irq_read_needs_mux = true, + .disable_strict_mode = true, }; static int sun8i_h3_r_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun8i-h3.c b/drivers/pinctrl/sunxi/pinctrl-sun8i-h3.c index 518a92df4418..d1719a738c20 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun8i-h3.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun8i-h3.c @@ -491,7 +491,8 @@ static const struct sunxi_pinctrl_desc sun8i_h3_pinctrl_data = { .pins = sun8i_h3_pins, .npins = ARRAY_SIZE(sun8i_h3_pins), .irq_banks = 2, - .irq_read_needs_mux = true + .irq_read_needs_mux = true, + .disable_strict_mode = true, }; static int sun8i_h3_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun9i-a80-r.c b/drivers/pinctrl/sunxi/pinctrl-sun9i-a80-r.c index 92a873f73697..c63086c98335 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun9i-a80-r.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun9i-a80-r.c @@ -152,6 +152,7 @@ static const struct sunxi_pinctrl_desc sun9i_a80_r_pinctrl_data = { .npins = ARRAY_SIZE(sun9i_a80_r_pins), .pin_base = PL_BASE, .irq_banks = 2, + .disable_strict_mode = true, }; static int sun9i_a80_r_pinctrl_probe(struct platform_device *pdev) diff --git a/drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c b/drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c index bc14e954d7a2..472ef0d91b99 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c +++ b/drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c @@ -721,6 +721,7 @@ static const struct sunxi_pinctrl_desc sun9i_a80_pinctrl_data = { .pins = sun9i_a80_pins, .npins = ARRAY_SIZE(sun9i_a80_pins), .irq_banks = 5, + .disable_strict_mode = true, }; static int sun9i_a80_pinctrl_probe(struct platform_device *pdev)