From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BE0E4CDB482 for ; Tue, 17 Oct 2023 12:04:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233761AbjJQME4 (ORCPT ); Tue, 17 Oct 2023 08:04:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229459AbjJQMEx (ORCPT ); Tue, 17 Oct 2023 08:04:53 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 24A3AF1 for ; Tue, 17 Oct 2023 05:04:51 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-4060b623e64so35178815e9.0 for ; Tue, 17 Oct 2023 05:04:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544289; x=1698149089; darn=vger.kernel.org; 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=fHHeG5JRIrppV58ReGuMBvMgk8ne+kNJoA1YKryvqFg=; b=2SrRY3U/LUUddE6vr7B1pfMUV1gJInKkq75oPYO7mkkBhoVICz4Yw333RcGckM84R1 o+eoXH08eOe6+dbaOS7GzJohbLHRd6LPSJPkXTggDNFdSbxsemB4FBoWBTNVYom1qz3A Q4AKtbxaYdvv+6t1iTuYAWisZwVZunfDtQBycSqhnZS4OdEKVaxeDdgcn3Bqi3SryRQX TTCfQ7nBfxw59+0s7k234chu2H3zE+246U6bXoHzvtRBRCweKilzgyuWwgTscdHCA2nh P2ByccVoF3/FvtrU0VsJawcJmFN7JMqU4NemEDiX4DlBtSXYGw+UZZHJtUTv+0iiqTO5 yAUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544289; x=1698149089; 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=fHHeG5JRIrppV58ReGuMBvMgk8ne+kNJoA1YKryvqFg=; b=SQBxjLPlgbiC8qvpj4TbN79QWy/Gt/uvZCp4gmKF6aztgwT31qr/n6mBOK4jCaq9JR YrUPvS6WNL2SpaN1J9lU3q8XX0H3nuktKWciEDT7MxMsX+wvFsD46v2WpQbf3Aj8NAMS Rh2VHeQXl+IwB8WJB88RfXqu+dGrMWJiw0mLy/3/0cYcKVcHnKyk1THddvw8cBDAUaKc AQ5yyyUFJBddqtIKjtFsLSxGduP+lZfTPjQGEAlT200M737+FlqLWmu8N61Q50bCpKck vhM+wct0gP+1ODHRehwYzfpsYlWwRLDHxCj1wWKtMepumRI/Yn0t1DLVadLKzCr0Uxpq xt8w== X-Gm-Message-State: AOJu0Yw1ttJSfs/SAqBNgUSF7FRcCuBulpoVPdN1l1J8yuMsnKNYhG8a tnSkfU54Cn4/ciI2/FviELyXqQ== X-Google-Smtp-Source: AGHT+IFA0moEr3UGf6vPmXCGuFJNzqDcsJwhXXG0UIzqX4L+ZqoFf+ma6PxjyQJlkTSMHvNM95rcCw== X-Received: by 2002:a05:600c:a39c:b0:407:4126:f71c with SMTP id hn28-20020a05600ca39c00b004074126f71cmr1619544wmb.6.1697544289376; Tue, 17 Oct 2023 05:04:49 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:48 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 01/73] pinctrl: remove unneeded extern specifiers from consumer.h Date: Tue, 17 Oct 2023 14:03:19 +0200 Message-Id: <20231017120431.68847-2-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski The 'extern' specifiers are not needed for function declarations. Remove all of them from the pinctrl/consumer.h header. Signed-off-by: Bartosz Golaszewski Reviewed-by: Linus Walleij Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- include/linux/pinctrl/consumer.h | 34 ++++++++++++++++---------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 4729d54e8995..22eef0a513ce 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -25,27 +25,27 @@ struct pinctrl_state; #ifdef CONFIG_PINCTRL =20 /* External interface to pin control */ -extern bool pinctrl_gpio_can_use_line(unsigned gpio); -extern int pinctrl_gpio_request(unsigned gpio); -extern void pinctrl_gpio_free(unsigned gpio); -extern int pinctrl_gpio_direction_input(unsigned gpio); -extern int pinctrl_gpio_direction_output(unsigned gpio); -extern int pinctrl_gpio_set_config(unsigned gpio, unsigned long config); +bool pinctrl_gpio_can_use_line(unsigned gpio); +int pinctrl_gpio_request(unsigned gpio); +void pinctrl_gpio_free(unsigned gpio); +int pinctrl_gpio_direction_input(unsigned gpio); +int pinctrl_gpio_direction_output(unsigned gpio); +int pinctrl_gpio_set_config(unsigned gpio, unsigned long config); =20 -extern struct pinctrl * __must_check pinctrl_get(struct device *dev); -extern void pinctrl_put(struct pinctrl *p); -extern struct pinctrl_state * __must_check pinctrl_lookup_state(struct pin= ctrl *p, - const char *name); -extern int pinctrl_select_state(struct pinctrl *p, struct pinctrl_state *s= ); +struct pinctrl * __must_check pinctrl_get(struct device *dev); +void pinctrl_put(struct pinctrl *p); +struct pinctrl_state * __must_check pinctrl_lookup_state(struct pinctrl *p, + const char *name); +int pinctrl_select_state(struct pinctrl *p, struct pinctrl_state *s); =20 -extern struct pinctrl * __must_check devm_pinctrl_get(struct device *dev); -extern void devm_pinctrl_put(struct pinctrl *p); -extern int pinctrl_select_default_state(struct device *dev); +struct pinctrl * __must_check devm_pinctrl_get(struct device *dev); +void devm_pinctrl_put(struct pinctrl *p); +int pinctrl_select_default_state(struct device *dev); =20 #ifdef CONFIG_PM -extern int pinctrl_pm_select_default_state(struct device *dev); -extern int pinctrl_pm_select_sleep_state(struct device *dev); -extern int pinctrl_pm_select_idle_state(struct device *dev); +int pinctrl_pm_select_default_state(struct device *dev); +int pinctrl_pm_select_sleep_state(struct device *dev); +int pinctrl_pm_select_idle_state(struct device *dev); #else static inline int pinctrl_pm_select_default_state(struct device *dev) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id ED4A0CDB484 for ; Tue, 17 Oct 2023 12:05:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234830AbjJQME7 (ORCPT ); Tue, 17 Oct 2023 08:04:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232093AbjJQMEy (ORCPT ); Tue, 17 Oct 2023 08:04:54 -0400 Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7D615EA for ; Tue, 17 Oct 2023 05:04:52 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-405497850dbso54303265e9.0 for ; Tue, 17 Oct 2023 05:04:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544291; x=1698149091; darn=vger.kernel.org; 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=hDPPG8QeEjXolFjUXbjhpSbzoHQO2mUvJPEw2R2sG4g=; b=EMPeZQHXva58CabESQC4WX509CTrFCqwZD4pFfpnDQj6xrDSB9l8JYqXEaf577H9CL WK03UhFLZBS/7YaIAe78nXwMYH45y0GHTENfpmuJldtjZyeD4pmQocllK4alOGnBq27W x0qqv1K2ThNNRR7HQk/ur2OZfcPQTIWO0EjdoDYyWswW7V3utWI2z2ouE/gwp/J+eiHy QZDmUVPbbXoz6geRsM6yPQvUpczwlnK7LkonOe9jhfX87h7dj1nux6UTTjvXjrEoP4tD u1C9LcX20zaDmDdoAUgrXZtLx+mKSGnLz/F2Lg1mmRvS6Eey0qU4vEMErQLywHehafzd gjVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544291; x=1698149091; 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=hDPPG8QeEjXolFjUXbjhpSbzoHQO2mUvJPEw2R2sG4g=; b=V9sVblpWweZlk0xpzKAnp9IgnIxqV8kPWVlZVIgjRBaM9Z7q1Q4SUu333WKiwKONJd AuEIJVUngcric70bmvMPcMrnITf00Nro8oVdo86vOTH1zt7XlVKaFtZIGP019+p76yFc fWmlwrY27dym0Ou8PwpyTmUn6ciqHj5LyQWEO+1gFF8bGarvwn4wb3glRdg43IPDz/im LhIRkuMV9T3S0M94J35+442/STmkBPmZu7aOcMmv+P7ccRbvSimwhwGKfOuQtd1561m3 MoSOjruAmnt4jPzIkQ2CRuSlaDJLVT0bNRRKYSXBW42j9eu6IH/2ZU6EgWFQUsNgn4xr +oCg== X-Gm-Message-State: AOJu0Yyft1Y7JWdz8qF/FWT2nk3x0u5W6uvPwObliV/avoVJ0EE3ay5d FEQa5c19BEUP/SPhNNomOz1eog== X-Google-Smtp-Source: AGHT+IFVX4szWxW17yEip5UZ2AuD3RpKciAgXfA8C/yANBf8pa18lBqBy8fz2bpXonFqAnv8ANWJEQ== X-Received: by 2002:a05:600c:510d:b0:407:8f23:ce2 with SMTP id o13-20020a05600c510d00b004078f230ce2mr1531828wms.31.1697544290532; Tue, 17 Oct 2023 05:04:50 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:49 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 02/73] pinctrl: provide new GPIO-to-pinctrl glue helpers Date: Tue, 17 Oct 2023 14:03:20 +0200 Message-Id: <20231017120431.68847-3-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Currently the pinctrl GPIO helpers all take a number from the global GPIO numberspace - of which we're trying to get rid of as argument. These helpers are almost universally called from GPIOLIB driver callbacks which take a pointer to the backing gpio_chip and the controller-relative offset as arguments. Let's provide improved variants of these functions that match the GPIOLIB signatures as the first step in removing the older flavor. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 108 ++++++++++++++++++++++--------- include/linux/pinctrl/consumer.h | 46 +++++++++++++ 2 files changed, 125 insertions(+), 29 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 9900f8e9e321..6cd22829544c 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -23,6 +23,8 @@ #include #include =20 +#include + #include #include #include @@ -781,14 +783,13 @@ bool pinctrl_gpio_can_use_line(unsigned gpio) } EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line); =20 -/** - * pinctrl_gpio_request() - request a single pin to be used as GPIO - * @gpio: the GPIO pin number from the GPIO subsystem number space - * - * This function should *ONLY* be used from gpiolib-based GPIO drivers, - * as part of their gpio_request() semantics, platforms and individual dri= vers - * shall *NOT* request GPIO pins to be muxed in. - */ +bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et) +{ + return pinctrl_gpio_can_use_line(gc->base + offset); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line_new); + +/* This function is deprecated and will be removed. Don't use. */ int pinctrl_gpio_request(unsigned gpio) { struct pinctrl_dev *pctldev; @@ -817,13 +818,21 @@ int pinctrl_gpio_request(unsigned gpio) EXPORT_SYMBOL_GPL(pinctrl_gpio_request); =20 /** - * pinctrl_gpio_free() - free control on a single pin, currently used as G= PIO - * @gpio: the GPIO pin number from the GPIO subsystem number space + * pinctrl_gpio_request_new() - request a single pin to be used as GPIO + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * * This function should *ONLY* be used from gpiolib-based GPIO drivers, - * as part of their gpio_free() semantics, platforms and individual drivers - * shall *NOT* request GPIO pins to be muxed out. + * as part of their gpio_request() semantics, platforms and individual dri= vers + * shall *NOT* request GPIO pins to be muxed in. */ +int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) +{ + return pinctrl_gpio_request(gc->base + offset); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_request_new); + +/* This function is deprecated and will be removed. Don't use. */ void pinctrl_gpio_free(unsigned gpio) { struct pinctrl_dev *pctldev; @@ -846,6 +855,21 @@ void pinctrl_gpio_free(unsigned gpio) } EXPORT_SYMBOL_GPL(pinctrl_gpio_free); =20 +/** + * pinctrl_gpio_free_new() - free control on a single pin, currently used = as GPIO + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller + * + * This function should *ONLY* be used from gpiolib-based GPIO drivers, + * as part of their gpio_request() semantics, platforms and individual dri= vers + * shall *NOT* request GPIO pins to be muxed in. + */ +void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) +{ + return pinctrl_gpio_free(gc->base + offset); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_free_new); + static int pinctrl_gpio_direction(unsigned gpio, bool input) { struct pinctrl_dev *pctldev; @@ -869,14 +893,7 @@ static int pinctrl_gpio_direction(unsigned gpio, bool = input) return ret; } =20 -/** - * pinctrl_gpio_direction_input() - request a GPIO pin to go into input mo= de - * @gpio: the GPIO pin number from the GPIO subsystem number space - * - * This function should *ONLY* be used from gpiolib-based GPIO drivers, - * as part of their gpio_direction_input() semantics, platforms and indivi= dual - * drivers shall *NOT* touch pin control GPIO calls. - */ +/* This function is deprecated and will be removed. Don't use. */ int pinctrl_gpio_direction_input(unsigned gpio) { return pinctrl_gpio_direction(gpio, true); @@ -884,13 +901,21 @@ int pinctrl_gpio_direction_input(unsigned gpio) EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); =20 /** - * pinctrl_gpio_direction_output() - request a GPIO pin to go into output = mode - * @gpio: the GPIO pin number from the GPIO subsystem number space + * pinctrl_gpio_direction_input_new() - request a GPIO pin to go into inpu= t mode + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * * This function should *ONLY* be used from gpiolib-based GPIO drivers, - * as part of their gpio_direction_output() semantics, platforms and indiv= idual + * as part of their gpio_direction_input() semantics, platforms and indivi= dual * drivers shall *NOT* touch pin control GPIO calls. */ +int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int of= fset) +{ + return pinctrl_gpio_direction_input(gc->base + offset); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input_new); + +/* This function is deprecated and will be removed. Don't use. */ int pinctrl_gpio_direction_output(unsigned gpio) { return pinctrl_gpio_direction(gpio, false); @@ -898,14 +923,22 @@ int pinctrl_gpio_direction_output(unsigned gpio) EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); =20 /** - * pinctrl_gpio_set_config() - Apply config to given GPIO pin - * @gpio: the GPIO pin number from the GPIO subsystem number space - * @config: the configuration to apply to the GPIO + * pinctrl_gpio_direction_output_new() - request a GPIO pin to go into out= put + * mode + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * - * This function should *ONLY* be used from gpiolib-based GPIO drivers, if - * they need to call the underlying pin controller to change GPIO config - * (for example set debounce time). + * This function should *ONLY* be used from gpiolib-based GPIO drivers, + * as part of their gpio_direction_output() semantics, platforms and indiv= idual + * drivers shall *NOT* touch pin control GPIO calls. */ +int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int o= ffset) +{ + return pinctrl_gpio_direction_output(gc->base + offset); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output_new); + +/* This function is deprecated and will be removed. Don't use. */ int pinctrl_gpio_set_config(unsigned gpio, unsigned long config) { unsigned long configs[] =3D { config }; @@ -926,6 +959,23 @@ int pinctrl_gpio_set_config(unsigned gpio, unsigned lo= ng config) } EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config); =20 +/** + * pinctrl_gpio_set_config_new() - Apply config to given GPIO pin + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller + * @config: the configuration to apply to the GPIO + * + * This function should *ONLY* be used from gpiolib-based GPIO drivers, if + * they need to call the underlying pin controller to change GPIO config + * (for example set debounce time). + */ +int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, + unsigned long config) +{ + return pinctrl_gpio_set_config(gc->base + offset, config); +} +EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config_new); + static struct pinctrl_state *find_state(struct pinctrl *p, const char *name) { diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 22eef0a513ce..c95c13983376 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -17,6 +17,7 @@ #include =20 struct device; +struct gpio_chip; =20 /* This struct is private to the core and should be regarded as a cookie */ struct pinctrl; @@ -26,11 +27,20 @@ struct pinctrl_state; =20 /* External interface to pin control */ bool pinctrl_gpio_can_use_line(unsigned gpio); +bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); int pinctrl_gpio_request(unsigned gpio); +int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free(unsigned gpio); +void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input(unsigned gpio); +int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, + unsigned int offset); int pinctrl_gpio_direction_output(unsigned gpio); +int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, + unsigned int offset); int pinctrl_gpio_set_config(unsigned gpio, unsigned long config); +int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, + unsigned long config); =20 struct pinctrl * __must_check pinctrl_get(struct device *dev); void pinctrl_put(struct pinctrl *p); @@ -68,30 +78,66 @@ static inline bool pinctrl_gpio_can_use_line(unsigned g= pio) return true; } =20 +static inline bool +pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset) +{ + return true; +} + static inline int pinctrl_gpio_request(unsigned gpio) { return 0; } =20 +static inline int +pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) +{ + return 0; +} + static inline void pinctrl_gpio_free(unsigned gpio) { } =20 +static inline void +pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) +{ +} + static inline int pinctrl_gpio_direction_input(unsigned gpio) { return 0; } =20 +static inline int +pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset) +{ + return 0; +} + static inline int pinctrl_gpio_direction_output(unsigned gpio) { return 0; } =20 +static inline int +pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offse= t) +{ + return 0; +} + static inline int pinctrl_gpio_set_config(unsigned gpio, unsigned long con= fig) { return 0; } =20 +static inline int +pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, + unsigned long config) +{ + return 0; +} + static inline struct pinctrl * __must_check pinctrl_get(struct device *dev) { return NULL; --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1BDA9CDB485 for ; Tue, 17 Oct 2023 12:05:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234829AbjJQMFB (ORCPT ); Tue, 17 Oct 2023 08:05:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60650 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234650AbjJQME5 (ORCPT ); Tue, 17 Oct 2023 08:04:57 -0400 Received: from mail-lj1-x236.google.com (mail-lj1-x236.google.com [IPv6:2a00:1450:4864:20::236]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 07A5CF7 for ; Tue, 17 Oct 2023 05:04:53 -0700 (PDT) Received: by mail-lj1-x236.google.com with SMTP id 38308e7fff4ca-2c518a1d83fso40408451fa.3 for ; Tue, 17 Oct 2023 05:04:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544291; x=1698149091; darn=vger.kernel.org; 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=AJdD7DyqFPsbeX9i2wGTnakQ0HgNh9JVzW41FU4431I=; b=2XsPkO5nb8BZE5s9wof5pYssgL9kKVX6kvC6p8KZh2/lGIKgmJ7Mo7xd6Komh8Lfp4 eEuelPHpeNsdgoB2xQ9+j/N12DpBEJ1Fnbc7TvGZxt7+pXzDBKFOOEH45XRn/qdYX2U8 1Ym/WaXxEu9VQOVYcPbkIjBN/V+xa8tpKeMFVsBWlM8vGs01CpSwfZEohxKr+qGNow7i ujkEIndtV/RwfUSG3tTdmWUOTE73BfKkC8f1gYAN5A+xuR6Idhyn+GB0GSjnMLD7hDqQ TscPvnr9/BFCfSep6FMSbd5qC0Uj3ZWN3qJaM5Ler87pyIPC4JquLiwtIAQGPp608NLD VIRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544291; x=1698149091; 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=AJdD7DyqFPsbeX9i2wGTnakQ0HgNh9JVzW41FU4431I=; b=EvPpS3ODVfompBDZGtfoKbt4T9FsxI9sxsA5fXELkQiF2wuZJp+WLbMKDrUzhzyx+F Fw5gDHk5oRPAN5TcSmD0WswEGEkFcZKyAvIrTYzgWanXKNF+UHehtl7IcpR98jQrkE8b Lc9VaR8eOqSOgT9okmyI0cI0cxDzfv81/PujkjkNaXC/xfL/ZnW+kuXQ4+vLjGAUlPdB I7KkBCa4v5ym+sjRyxV3UX05lh9F8Y4x2QBiu/sblaYuQ0UrR0ZPjbj5+7s9eB7/FyzD UOght5/UDBaMr1qqRC+pUEA+QHqxZ/pF9ZYZNi7xIYmzkLwQKaBOIgU+NR6I4Fr6GzRa dVPQ== X-Gm-Message-State: AOJu0Yy8UHDq6Y71CZ0x29C1Iu4IJCGQGXekc4hztEU5xqzNY8TwrAFR eK1uQHYRzRxafwQg0DgX1LUZgA== X-Google-Smtp-Source: AGHT+IExhqcdf/1IDWyAPkp4H4CzGnYQk+Cl1WQIoBRI+QOxlOzWXsSjWsKNbvBxqRISzeP31uvlcg== X-Received: by 2002:a2e:9613:0:b0:2bf:7905:12c3 with SMTP id v19-20020a2e9613000000b002bf790512c3mr1427084ljh.40.1697544291285; Tue, 17 Oct 2023 05:04:51 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:50 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andy Shevchenko Subject: [PATCH v3 03/73] gpiolib: generic: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:21 +0200 Message-Id: <20231017120431.68847-4-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/gpio/gpiolib.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index cbafcd95243e..37c1df78437f 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -2036,7 +2036,7 @@ int gpiochip_generic_request(struct gpio_chip *gc, un= signed int offset) return 0; #endif =20 - return pinctrl_gpio_request(gc->gpiodev->base + offset); + return pinctrl_gpio_request_new(gc, offset); } EXPORT_SYMBOL_GPL(gpiochip_generic_request); =20 @@ -2052,7 +2052,7 @@ void gpiochip_generic_free(struct gpio_chip *gc, unsi= gned int offset) return; #endif =20 - pinctrl_gpio_free(gc->gpiodev->base + offset); + pinctrl_gpio_free_new(gc, offset); } EXPORT_SYMBOL_GPL(gpiochip_generic_free); =20 @@ -2065,7 +2065,7 @@ EXPORT_SYMBOL_GPL(gpiochip_generic_free); int gpiochip_generic_config(struct gpio_chip *gc, unsigned int offset, unsigned long config) { - return pinctrl_gpio_set_config(gc->gpiodev->base + offset, config); + return pinctrl_gpio_set_config_new(gc, offset, config); } EXPORT_SYMBOL_GPL(gpiochip_generic_config); =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CCB6DCDB474 for ; Tue, 17 Oct 2023 12:05:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343514AbjJQMFM (ORCPT ); Tue, 17 Oct 2023 08:05:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234752AbjJQME6 (ORCPT ); Tue, 17 Oct 2023 08:04:58 -0400 Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EA47AF2 for ; Tue, 17 Oct 2023 05:04:53 -0700 (PDT) Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2c501bd6ff1so61887061fa.3 for ; Tue, 17 Oct 2023 05:04:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544292; x=1698149092; darn=vger.kernel.org; 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=eqSvTTUiCAxcdVsqPtP3QRiyb3qISoSChjkUUgG3668=; b=SueKBiqmIZUOBtnSpA7PCqgvsexnr/Z/EBBwRZ+sWrWr2fCH1iFKOWhJVE5U7KMUvO x5IcHqS1rUl8vEWKSWEyFvFDLjJpH4sNngHggnHs6X8r8XFbuk6580J07czQKupfKP3G 2s7NIT1sc56DPfK80KZ+3kDnHNfcFJiLsukLGKILsSiTpCcNz7s+dMsp/YAglMufGRED Vaw8HbIbKAVznIqXfM60agbxJ7PFluJwEqLr3ZUlZKgIbmBMqkZ+0IIjdxKGJ+Sb/Lfj O4xPDOdd1SNJtxRu2BjzN1SGCH2dVaKWkrUUEJJypSp34PLxuf9IRzfNsYKncKcWYFPa AjqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544292; x=1698149092; 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=eqSvTTUiCAxcdVsqPtP3QRiyb3qISoSChjkUUgG3668=; b=d0sxYCKQ+4f07+JAPc76t69e6zwjB1Upu00ZQxrMv3FSPFODf9p89SJ73FfXZQCE7D jiv9DVhvacxuyo07zg0qAZ7F/GJHQKayK5jUpQNqpHBp/JZ/roAcPfFsJNuVvTsvSIUr eBS1WC9+5W6IqHZCUbHwDFCWP+WeSobiS/XNDDqx7sXBtxSS7tu5ES0wmnBw+QlBjMP5 HWVs6FH+6l6ZI83HvTe2iwI/fAqb8o8j+F3imsqY/9U4rn9Ch764bl+qLT0BkjyIes// gUTklCWP5Jb96uCsYs7J/eIcIHa5G94L0vRbWJhe9emkHiQ+gO3dBo7pCE1c6wSBwR3u 9pBQ== X-Gm-Message-State: AOJu0YyYrf2w5blWAJvzVzw57QY8sONN5D1Ld9eb+NGQuf4XA+feFrhB PC0t9EnAni+JK8yyYDdL9jbXlnwT5CbKkxQ6rLg= X-Google-Smtp-Source: AGHT+IFdNGufBtvxHVT2PYigX8VGTwzhNOTUcTb1bos7CHU1BhiK+V/FOUi1kwpeYNQkD1kZB9oNJA== X-Received: by 2002:a05:651c:b29:b0:2c5:380:2a10 with SMTP id b41-20020a05651c0b2900b002c503802a10mr1919281ljr.25.1697544292084; Tue, 17 Oct 2023 05:04:52 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:51 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 04/73] gpio: cdev: use pinctrl_gpio_can_use_line_new() Date: Tue, 17 Oct 2023 14:03:22 +0200 Message-Id: <20231017120431.68847-5-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Use the improved variant of pinctrl_gpio_can_use_line() which takes a pointer to the gpio_chip and a controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/gpio/gpiolib-cdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c index 31fc71a612c2..54ee075410db 100644 --- a/drivers/gpio/gpiolib-cdev.c +++ b/drivers/gpio/gpiolib-cdev.c @@ -2287,8 +2287,7 @@ static void gpio_desc_to_lineinfo(struct gpio_desc *d= esc, * FIXME: find a non-racy way to retrieve this information. Maybe a * lock common to both frameworks? */ - ok_for_pinctrl =3D - pinctrl_gpio_can_use_line(gc->base + info->offset); + ok_for_pinctrl =3D pinctrl_gpio_can_use_line_new(gc, info->offset); =20 spin_lock_irqsave(&gpio_lock, flags); =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5077ACDB474 for ; Tue, 17 Oct 2023 12:05:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234877AbjJQMFF (ORCPT ); Tue, 17 Oct 2023 08:05:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60680 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234659AbjJQME5 (ORCPT ); Tue, 17 Oct 2023 08:04:57 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3C097EA for ; Tue, 17 Oct 2023 05:04:55 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-405417465aaso53787155e9.1 for ; Tue, 17 Oct 2023 05:04:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544293; x=1698149093; darn=vger.kernel.org; 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=Vai4SzqfuocTRSn5ctHCW9VKMc1EsxJBBmmicKiWbek=; b=u4qfHNLqnys7uHtSLjuIw2hM1O0yo5BQuVJUAFnLyIxGZEsIUwbvzgd8YX4ir2dab2 SkZ9GUxW8nGlW4ALVEHQTRpc+VEGDLRWNLKxI2xS8gtYtu0X3h3za5Kyx33huyQRzmdf PXwFg7Vd7dORjdGSNm6f0bVxnniaj4PBkx7GNWKo7g2+OAZ29qY7uWlrWk7qvn7hh5js qgvd1rJmCXOFabl6ToJINWl/GyTK0mNRVqu6NbRY6aISTMDbYjw+bs9nUo39ATz7pefY hX27EUadYldk2ulIJZXVpj+0cOevq/hAlA/6LLuLGLjYTjAiAR+HtT0YnX2FiQdN3Rrn 8YLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544293; x=1698149093; 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=Vai4SzqfuocTRSn5ctHCW9VKMc1EsxJBBmmicKiWbek=; b=EKcnD1gVa7pYX3KV7iIgETmseXeXuLDP2PV2y0dG1OqOipOocKlHBlJr7/fh4ceaAG pfcy9sk9WK++MBqoWLBqbBw86XsvSKZtKhAUm5fBOjKZOgzc5DBsL0SPXA0vx/ykB/rs l5yb6cR4QMRUlIaJ/0/kxsKx1Nj5WmiXiN+fNx/fI/EvQMPSICCZg2jMWBmSyHU5T/4s 4l8C6qGOTKqQfpMNsS+QDpvEwVJHzrZAKuGVAyZBmMWCwaellZYnFe4PRssI/SLAlbb6 E5Q9t7UGgmvGyKe/TaUP6vQ7WvVQCerA26LBUnIsVnHiFYf51Yv1gBaH7HQ7tczt+Nll av5g== X-Gm-Message-State: AOJu0YxPekGPAHqYR366mYfJxgj36gz9w/oW4og7mG0sQ/JEWjkQwa0c BizzJw7m/HEmJGcrRCpVv52+eQ== X-Google-Smtp-Source: AGHT+IHU7NuREtU+mqWpMnxYMyb4RRiRqkHq8pgJY1a4J3z3rIp2pbmFjoy6xY63ywlgfvgfuWxy/w== X-Received: by 2002:a05:600c:3ca3:b0:406:6964:7e96 with SMTP id bg35-20020a05600c3ca300b0040669647e96mr1657118wmb.13.1697544293118; Tue, 17 Oct 2023 05:04:53 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:52 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Geert Uytterhoeven Subject: [PATCH v3 05/73] gpio: rcar: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:23 +0200 Message-Id: <20231017120431.68847-6-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Geert Uytterhoeven Acked-by: Geert Uytterhoeven Acked-by: Linus Walleij --- drivers/gpio/gpio-rcar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-rcar.c b/drivers/gpio/gpio-rcar.c index d8b1baae6357..47121e1a6d4e 100644 --- a/drivers/gpio/gpio-rcar.c +++ b/drivers/gpio/gpio-rcar.c @@ -275,7 +275,7 @@ static int gpio_rcar_request(struct gpio_chip *chip, un= signed offset) return error; } =20 - error =3D pinctrl_gpio_request(chip->base + offset); + error =3D pinctrl_gpio_request_new(chip, offset); if (error) pm_runtime_put(p->dev); =20 @@ -286,7 +286,7 @@ static void gpio_rcar_free(struct gpio_chip *chip, unsi= gned offset) { struct gpio_rcar_priv *p =3D gpiochip_get_data(chip); =20 - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); =20 /* * Set the GPIO as an input to ensure that the next GPIO request won't --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5ABEFCDB474 for ; Tue, 17 Oct 2023 12:05:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343503AbjJQMFJ (ORCPT ); Tue, 17 Oct 2023 08:05:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60650 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234760AbjJQME6 (ORCPT ); Tue, 17 Oct 2023 08:04:58 -0400 Received: from mail-lj1-x232.google.com (mail-lj1-x232.google.com [IPv6:2a00:1450:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 383EFFF for ; Tue, 17 Oct 2023 05:04:56 -0700 (PDT) Received: by mail-lj1-x232.google.com with SMTP id 38308e7fff4ca-2c5087d19a6so52210981fa.0 for ; Tue, 17 Oct 2023 05:04:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544294; x=1698149094; darn=vger.kernel.org; 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=PJlcPxZYJ+2xOtgJ5lT3aANbc/q/A7LyEHQjQgc784Q=; b=fJfvs3CnP2qp5WbXgHrOpeYrdgkw15gut4Sa2lJmawhADnds+CBtLRhddGne0nJKze luRwQ+KLcciyw2wjmPtqTWd2nbXdSxV+TAAuVNGQHl++PwaIJF7xHZGnF4LO7m3ln/Ph LlFj0vjjciZiO4owfbToqgT+IHYdYeGNYKce/t/y2RoPrEdyttG9OSp3+f97gsYTO3uk WdDp8LZeMLCC3KW+m47/HvJBCKLO+c9IDvcpsQx/XJ2gK/e1ELmWwxYyGLzWGObnFyOF MxnZGXC1qsj/EROSJBkOmUzjJ1ASy7w0Alo81k57ZFmmeIS8+x4nOi4j0kPFjIR1WOGs 0UZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544294; x=1698149094; 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=PJlcPxZYJ+2xOtgJ5lT3aANbc/q/A7LyEHQjQgc784Q=; b=pXJWjD7wWeBSCKeizlKMUZHM8fQDr/JJq+VTVeVZOP6CTnC0Admv95eGvR+g/mMJhy sJXlo2DOkJSw9as0SoWClNYmM9GKgpqCj+4HXuOhFEII5M4uExY7c01T6RR0ZEemt8Fx 8wM2lQmPgMG5KuRiwd1/M+kTlKftf85Tfl6yKFZSEdYr8HAyECA9ZcgMVr8XaYKc3iac bSPwZerGh7pixO6WcpUUuSKYEw4mq3/6I6W9V7cbiSqmfYq37dfJwXpMhqQnalkFCSUv rYUHqa2VVToCAIuHlvBZ4E/U5vkopHQGd4/7d+s/xbKQaiLalWSM297LV4qMD9Ak9caH Q0ww== X-Gm-Message-State: AOJu0YxYxiHp2oJC/4LUAlRx8m+mVPRS7VR1smO+lFK9DeIV+m/AqviC Rn9u/HioAyDlAfA928HWg7Aiig== X-Google-Smtp-Source: AGHT+IEO2/sj/qTg2E4G20vfzB2LnuPMvz2vyam82jVzc62j2bqztktVHSf9Uq4DvlJtqAeTSYxYFw== X-Received: by 2002:a2e:9604:0:b0:2c5:1603:9c48 with SMTP id v4-20020a2e9604000000b002c516039c48mr1638646ljh.20.1697544294507; Tue, 17 Oct 2023 05:04:54 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:54 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 06/73] gpio: tegra: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:24 +0200 Message-Id: <20231017120431.68847-7-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-tegra.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index ea715582bcf3..08951ddcd294 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -139,14 +139,14 @@ static void tegra_gpio_disable(struct tegra_gpio_info= *tgi, unsigned int gpio) =20 static int tegra_gpio_request(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_request(chip->base + offset); + return pinctrl_gpio_request_new(chip, offset); } =20 static void tegra_gpio_free(struct gpio_chip *chip, unsigned int offset) { struct tegra_gpio_info *tgi =3D gpiochip_get_data(chip); =20 - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); tegra_gpio_disable(tgi, offset); } =20 @@ -179,7 +179,7 @@ static int tegra_gpio_direction_input(struct gpio_chip = *chip, tegra_gpio_mask_write(tgi, GPIO_MSK_OE(tgi, offset), offset, 0); tegra_gpio_enable(tgi, offset); =20 - ret =3D pinctrl_gpio_direction_input(chip->base + offset); + ret =3D pinctrl_gpio_direction_input_new(chip, offset); if (ret < 0) dev_err(tgi->dev, "Failed to set pinctrl input direction of GPIO %d: %d", @@ -199,7 +199,7 @@ static int tegra_gpio_direction_output(struct gpio_chip= *chip, tegra_gpio_mask_write(tgi, GPIO_MSK_OE(tgi, offset), offset, 1); tegra_gpio_enable(tgi, offset); =20 - ret =3D pinctrl_gpio_direction_output(chip->base + offset); + ret =3D pinctrl_gpio_direction_output_new(chip, offset); if (ret < 0) dev_err(tgi->dev, "Failed to set pinctrl output direction of GPIO %d: %d", --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 047D3CDB474 for ; Tue, 17 Oct 2023 12:05:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343523AbjJQMFO (ORCPT ); Tue, 17 Oct 2023 08:05:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234651AbjJQME7 (ORCPT ); Tue, 17 Oct 2023 08:04:59 -0400 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 1B449101 for ; Tue, 17 Oct 2023 05:04:57 -0700 (PDT) Received: by mail-lj1-x235.google.com with SMTP id 38308e7fff4ca-2c5087d19a6so52211201fa.0 for ; Tue, 17 Oct 2023 05:04:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544295; x=1698149095; darn=vger.kernel.org; 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=H58FBovONkBFAtGhn37zN4A9drmVE/E2kcDVb0X5d1o=; b=fX6d6qEdmAsmceVcSpA7mQ7qD+xAzTnz9mQ8KUMGvXzR/Ipmzboud/6TS+ddyZqoos t2iiclvUWhgasFMv/tkzsI5GqSU0l4IfXTL+JNDFKj2lcPOAJT1HeNW4oAwrogYM/4c+ yT8zw08FMi83BAflBF+SrmDwKYR+l9VmUyz2ikInkdJ2rWUR9STPMCYQfnm1WpUHJxIW qN/1V1n3XYg24fWI9ieVSbs8yErODyfnKeTwer1EK/IDvbr8ELXWST733fIrgijHZtNR ObcyEkiWljy8aqEj34ue3x3WP0u1e4HXXlutwATG+h3s2XGoUAZ1v2hKaqPfJwrfEhzH yRoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544295; x=1698149095; 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=H58FBovONkBFAtGhn37zN4A9drmVE/E2kcDVb0X5d1o=; b=xMGdDyXEmuhmKXBrHyQ/VOnZY6HFj8B5eY7dbsH/6BOnelSgqtEcxMgvsBUlSnSgLZ J/D9+HnzWXVSjnwq8k7Q6dOkFRD1nvOP8Zx2WKwxwiBvh/2aCtHmnS1FzLOLvv6jqrjP kBgLmos9sLVYIiGHyXG/z2GmHIVvY3u+km1D6Q4z/lKAsjcdBbs9FZivgroXBmbBeTWl ExjioRhDYTq3R7WzLaWHCaSCumwpHpFy/NzuHiImWS9WvOFpNpyIIe2HQ4qDE2va/hjE AVHgJAf6sHfFeVydPNOKo2ahQH+dDUU5FmNvBejYPM+WBWU/en2bq8vesCKLQvPVp6dp k66Q== X-Gm-Message-State: AOJu0YyREEMzZJybX+tXoGEZNpatvI0SfhFKouxpmBE+Wp+VRbldz09U cvOxTdMa/U1q3I2dTrPkbsxmQA== X-Google-Smtp-Source: AGHT+IG2o2TVreK+sIzBOu5Lvk/VaxgdmDKdcIm9WFJlnrjvvhxD0ilbK3saJQYIFzZIHRUVNO22rQ== X-Received: by 2002:a2e:9396:0:b0:2c5:275b:c5fc with SMTP id g22-20020a2e9396000000b002c5275bc5fcmr1585322ljh.0.1697544295299; Tue, 17 Oct 2023 05:04:55 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:54 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 07/73] gpio: em: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:25 +0200 Message-Id: <20231017120431.68847-8-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-em.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-em.c b/drivers/gpio/gpio-em.c index 858e6ebbb584..35c65ff43f71 100644 --- a/drivers/gpio/gpio-em.c +++ b/drivers/gpio/gpio-em.c @@ -229,12 +229,12 @@ static int em_gio_to_irq(struct gpio_chip *chip, unsi= gned offset) =20 static int em_gio_request(struct gpio_chip *chip, unsigned offset) { - return pinctrl_gpio_request(chip->base + offset); + return pinctrl_gpio_request_new(chip, offset); } =20 static void em_gio_free(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); =20 /* Set the GPIO as an input to ensure that the next GPIO request won't * drive the GPIO pin as an output. --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C0396CDB474 for ; Tue, 17 Oct 2023 12:05:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343541AbjJQMFp (ORCPT ); Tue, 17 Oct 2023 08:05:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232593AbjJQMFT (ORCPT ); Tue, 17 Oct 2023 08:05:19 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 769FA12A for ; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40651a726acso50639765e9.1 for ; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544301; x=1698149101; darn=vger.kernel.org; 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=XfWYSE8ThvfQSJQ9/Fq2M/H6j3nV1pBrLUi6/wp2wmg=; b=I8/jxjVcGmbzuiyNmyRR5oYWm17jbLEIoWeIUS77KwUk7rdRb7RKMRpTsNGAjz9AhH 5/oyNEPr+NgglaCqTeEfQRZrOUKaNE4ST30TVYApwl8u4w3CcmBajkshYrJyIMkOaWrK Y4pxdyMfjV6LFhKsbKvqW9CHPygu6FxPnz0prljvZ3OMLtN7bLnp6PQz3XVOXp66/u/Z Gj+SYqkJoRihDmjdzM5MjwcECuxEDHK3hJgxt71cQSactp1muplsVVp97pzAeRDees4F kr98t014kDZ5lHo9LnhLXqhPuyar1Ajt2vE2hmxv0LMAm/LEAFSyLkoEhgJXfnan9CXH KRqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544301; x=1698149101; 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=XfWYSE8ThvfQSJQ9/Fq2M/H6j3nV1pBrLUi6/wp2wmg=; b=SZLIuYfwQ3/gfo79hS+T0//Msr35a9TBmrn9LtdQEN6h88ly5q0FYn5UUFlwwkh2eU X7xdNAmivTZOBnu3XLmcAoeLRbhwrzzwhK4igHekqX1RLyPdStrNt0tCot/1x1hp79+U HUC6TYGBn+i+6ldsf+cdXO1jdwafDVI48kvcSvrEHXv7aphykBPLrErpbXPoWKvdG4Ry XoRhMf6eXxgqg1mW8VgqvJrYYB7qbZqrqoUN5GwZg5G0E8cDtlockKn/Acjvsb8wI/j8 bClRpa3ZuE9Ssm0wDWyz5Hn+tEI4nvpfZRAIy7mAopbqgPq9BIVYCqoS4Ij9RvLkY16c LB8Q== X-Gm-Message-State: AOJu0YxHnB4IslHo3HQpi7SSf9I/u8L84WimRHugLBgquvUijXao895i WfdjXFG+00AeNlEaKqrPORIOvQ== X-Google-Smtp-Source: AGHT+IHZg+Ea7NCU4m7eBzeT7ivGJI5rD+ML7hobIKQtqDtCWG5KVKYjI4E9NTJ9Gllb+IOWK+wUSQ== X-Received: by 2002:a05:600c:4f85:b0:405:3a14:aa1a with SMTP id n5-20020a05600c4f8500b004053a14aa1amr1685911wmq.18.1697544296151; Tue, 17 Oct 2023 05:04:56 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:55 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andrew Jeffery , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Subject: [PATCH v3 08/73] gpio: aspeed: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:26 +0200 Message-Id: <20231017120431.68847-9-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andrew Jeffery Acked-by: Uwe Kleine-K=C3=B6nig Acked-by: Linus Walleij --- drivers/gpio/gpio-aspeed.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpio/gpio-aspeed.c b/drivers/gpio/gpio-aspeed.c index 58f107194fda..d3aa1cfd4ace 100644 --- a/drivers/gpio/gpio-aspeed.c +++ b/drivers/gpio/gpio-aspeed.c @@ -750,12 +750,12 @@ static int aspeed_gpio_request(struct gpio_chip *chip= , unsigned int offset) if (!have_gpio(gpiochip_get_data(chip), offset)) return -ENODEV; =20 - return pinctrl_gpio_request(chip->base + offset); + return pinctrl_gpio_request_new(chip, offset); } =20 static void aspeed_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); } =20 static int usecs_to_cycles(struct aspeed_gpio *gpio, unsigned long usecs, @@ -973,7 +973,7 @@ static int aspeed_gpio_set_config(struct gpio_chip *chi= p, unsigned int offset, else if (param =3D=3D PIN_CONFIG_BIAS_DISABLE || param =3D=3D PIN_CONFIG_BIAS_PULL_DOWN || param =3D=3D PIN_CONFIG_DRIVE_STRENGTH) - return pinctrl_gpio_set_config(chip->base + offset, config); + return pinctrl_gpio_set_config_new(chip, offset, config); else if (param =3D=3D PIN_CONFIG_DRIVE_OPEN_DRAIN || param =3D=3D PIN_CONFIG_DRIVE_OPEN_SOURCE) /* Return -ENOTSUPP to trigger emulation, as per datasheet */ --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9B08CDB474 for ; Tue, 17 Oct 2023 12:05:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234930AbjJQMFQ (ORCPT ); Tue, 17 Oct 2023 08:05:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60696 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234891AbjJQMFC (ORCPT ); Tue, 17 Oct 2023 08:05:02 -0400 Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 47AE5107 for ; Tue, 17 Oct 2023 05:05:00 -0700 (PDT) Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2bfed7c4e6dso69721711fa.1 for ; Tue, 17 Oct 2023 05:05:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544298; x=1698149098; darn=vger.kernel.org; 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=oKklGkxfnAqinncSlSkchK2k3CX/0axnYu/+hfRNakU=; b=WSnxP7xBtD730Xep5nlPEijSvGnZHzTpNPlq1MNrfg/rm0sjZontk9k3cTBmDrGXHZ dg2okQU4obug0GHkGppX87hjISVsb29oegkbjOxRSJ5IFPNim0kFtbW0tGknQwYPpopo JrWKLBNuhVzck+wLPaHBL5PLNBCtlEZBC+FF/6AfaZMW1+JNIF7/26StgxvHvViqBECl wFG9jlRUeZiu2OdcYqCTBYSzULmlbCZy6LdXB/aFCNJpPo+oXMyBARmKZcowQBNteDiP nY5kxwsghCp1wn1NGbzSGdQxH9crdB8NNaFx8DewLQmwUf86I3xt9OgpXHQK0ZrL08V7 ZKDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544298; x=1698149098; 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=oKklGkxfnAqinncSlSkchK2k3CX/0axnYu/+hfRNakU=; b=bBB5wX00Qf2bZW4rxuxZmrqXK/a5VZhg4Fn++b/zRCqAEyfa0JoUbu0sfOtFGkrPld wbnjHbTND93E4b6EOyj70N+bcPV3tMpdPNYdf1J/n67xZVjNMWUCmJ2pxPIar+it0LP9 2Kn+EtybVxUcuFxqiCzFxldiE7INrSvOgow1/TmTse3NJNobrsY8QMuAQbIOw1e3OHlY IqmvILJlLYDMdXQkBWWDhFwMHQyE94xtyMtNdF4jLgu1lbE40XofjO+uv3htvklv0Wqt hS7hLqP46HBpkRnbFs09RZUMlxWh/SEGbzEogerItVgsWE7dQbZr/rZPOza6fgfMpoMW vYXA== X-Gm-Message-State: AOJu0YwfUB50RDHLbhx1DbM9MSzb7SKTPdEOK2vtYJtxtwG5nrZ+LgeO ZaGuPaUJmlErmZch+Js0uYS3meLFPmqZH0WGDfk= X-Google-Smtp-Source: AGHT+IFIoEycxqJm+0fa4YLHQ/Skq1X8nEXW95SRXywJZA6ysN644CwjpjhTVM4ZoIxEBTIIkDY6cA== X-Received: by 2002:a2e:7e0b:0:b0:2bc:efa4:2c32 with SMTP id z11-20020a2e7e0b000000b002bcefa42c32mr1382001ljc.37.1697544298531; Tue, 17 Oct 2023 05:04:58 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:57 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Subject: [PATCH v3 09/73] gpio: mvebu: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:27 +0200 Message-Id: <20231017120431.68847-10-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Uwe Kleine-K=C3=B6nig Acked-by: Linus Walleij --- drivers/gpio/gpio-mvebu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c index e5f2c2d2a721..c0ca0aa7b5cd 100644 --- a/drivers/gpio/gpio-mvebu.c +++ b/drivers/gpio/gpio-mvebu.c @@ -346,7 +346,7 @@ static int mvebu_gpio_direction_input(struct gpio_chip = *chip, unsigned int pin) * Check with the pinctrl driver whether this pin is usable as * an input GPIO */ - ret =3D pinctrl_gpio_direction_input(chip->base + pin); + ret =3D pinctrl_gpio_direction_input_new(chip, pin); if (ret) return ret; =20 @@ -366,7 +366,7 @@ static int mvebu_gpio_direction_output(struct gpio_chip= *chip, unsigned int pin, * Check with the pinctrl driver whether this pin is usable as * an output GPIO */ - ret =3D pinctrl_gpio_direction_output(chip->base + pin); + ret =3D pinctrl_gpio_direction_output_new(chip, pin); if (ret) return ret; =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD1D3CDB474 for ; Tue, 17 Oct 2023 12:05:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234391AbjJQMFX (ORCPT ); Tue, 17 Oct 2023 08:05:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234903AbjJQMFD (ORCPT ); Tue, 17 Oct 2023 08:05:03 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C261101 for ; Tue, 17 Oct 2023 05:05:00 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-40684f53ef3so59002635e9.3 for ; Tue, 17 Oct 2023 05:05:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544299; x=1698149099; darn=vger.kernel.org; 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=n2xq1c7gkK7UBvFiiWYtPT4/dVB/RGOfCXDnH3L0uQ8=; b=0YcswjkxOD7Y+pHjiFMzaeyEv8ofWJMRCeHfhsSwCR4XiMTA+FeFJrmsj/iTTTy5nI zI7ObaRZJn2fWLW2qOtt7+8dVvcIK6xTL11ga2QnGfBEdtko1CbJlMf7dLTNq5gue4iH ReSxBvdqaATQxsjiTYtTouYFzTg/BrE5fld/KY/TryAPrhvnEOaRNrrsBaDgAvG4o1uA Zu7JW/TrEbihLUkiFegQp8biXdUlo4+YRTM4/8jpJBsDWeluf6+1uj6AvY+gq7jUWLiA fnQ8XEBEPJ4yDsN4L7XG1nF461ub1jLobrY/1TEl6DynQdM1aencFDT2u87wiOmpCpWm A6fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544299; x=1698149099; 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=n2xq1c7gkK7UBvFiiWYtPT4/dVB/RGOfCXDnH3L0uQ8=; b=T08Y56/Vqp3Z/cheT6NFgaXKUKxN7OfQPFiFf3R5WUziKYthmQPU8Z29AUno3mujUh pE5cTswLBna3kZxQU7H7txDlD8KOOpmTlp55rU/T/1DDwemxSH5RZsXMWkEuyjdSILXT ydURKeM0gMlQbZwivAZOPijriKQI9j09VSye+RJmJ4zwgW5ryq1MfSLnC2b3ygmW6TcL 9be8XLwzx+x8v7DuY1cOMT5TIBv4kBgdkbozMegE0OXBOk0ZmsKTrHUVQcsXsVGG8t7E n1Y669AE+/L8U8tSiCMv0D9YaiBliGcu87sWeMw4ofzxLcf6mq2/gOS7jl2KT+muYQAG mEmg== X-Gm-Message-State: AOJu0Yy6QKVb3uY6oMDS+IqDLQ/LqfAWDFBNdTqRBam2gqPlJZahE5GZ y+3aEmXd9xDFKGPoC4vE9BZ5Hw== X-Google-Smtp-Source: AGHT+IGnWU+mJuU4E2+/B9aQfR5VmwG2gli9VycMLIZY5jBGMeCe3BVwCbX5rvXMoQA0bR6REeCPWA== X-Received: by 2002:a05:600c:3148:b0:405:514d:eb13 with SMTP id h8-20020a05600c314800b00405514deb13mr1541271wmo.24.1697544299528; Tue, 17 Oct 2023 05:04:59 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:58 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 10/73] gpio: pxa: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:28 +0200 Message-Id: <20231017120431.68847-11-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-pxa.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-pxa.c b/drivers/gpio/gpio-pxa.c index cae9661862fe..2fd797b91270 100644 --- a/drivers/gpio/gpio-pxa.c +++ b/drivers/gpio/gpio-pxa.c @@ -260,7 +260,7 @@ static int pxa_gpio_direction_input(struct gpio_chip *c= hip, unsigned offset) int ret; =20 if (pxa_gpio_has_pinctrl()) { - ret =3D pinctrl_gpio_direction_input(chip->base + offset); + ret =3D pinctrl_gpio_direction_input_new(chip, offset); if (ret) return ret; } @@ -289,7 +289,7 @@ static int pxa_gpio_direction_output(struct gpio_chip *= chip, writel_relaxed(mask, base + (value ? GPSR_OFFSET : GPCR_OFFSET)); =20 if (pxa_gpio_has_pinctrl()) { - ret =3D pinctrl_gpio_direction_output(chip->base + offset); + ret =3D pinctrl_gpio_direction_output_new(chip, offset); if (ret) return ret; } --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A52E4CDB474 for ; Tue, 17 Oct 2023 12:05:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235004AbjJQMFd (ORCPT ); Tue, 17 Oct 2023 08:05:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43360 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343542AbjJQMFR (ORCPT ); Tue, 17 Oct 2023 08:05:17 -0400 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 D792810E for ; Tue, 17 Oct 2023 05:05:02 -0700 (PDT) Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-2c504a5e1deso62209581fa.2 for ; Tue, 17 Oct 2023 05:05:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544300; x=1698149100; darn=vger.kernel.org; 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=Rjj2L8rLah6r0INEUdpiOGWMpBQyEZBDFUolDbEZ0p0=; b=z/CyUMd1BPEubs6df4EZ7TvD76p7XdwoP7J/wDmr0XDNILiLu32z00X2wIvEW5SdsL 6ncY78DkTmq56BdtHwrHgrhKt+woMqevkAqMQsakShO/ok44/4n5G8lo+nnIsK1m3tpN 6nfyrKg4mSh8vUYrlGHyFoTNBNe2ORUpl9jDDGS7SHJjZCyBIoee3kfwFD00BbWGnftY o5qmVTSd4aVcH42pY2XGzXrlkNjxaLO9WZxz8dBaXLQ+/QdMBgONWFLSOl2fP10B117O 64cMuq5ykyjZRv0SpTeICMWZkAUGMRQaEiRf1FtYqhMXpztz8D/I7opkx4In0d4UqDYo C1mQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544300; x=1698149100; 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=Rjj2L8rLah6r0INEUdpiOGWMpBQyEZBDFUolDbEZ0p0=; b=L9b1CCKwgKThWzvPGW/MtTk0T46GaOCO82wErg+yrnaRm4eeggGROzITNNnM/ezl+M J9ClfZv4zfL7uMxfovp8GhMS324WlCzWKR4xuSylXIKIQKvE3140h1hqk97hegtaeR9B B6KTITJHziKi7wa7kXPDe1El1/C+TdK17k1W1fwV4KPZjPhoKGJojDHKGK2X17TbHOn8 YFR1vEHjXIJ6QDgmEf+YhAcJCsW9umQaw98cGJYGVqQThvsZ1kCEgaIhUH7g93doeo8l 0HF4A4tz4Wi/4l8OX2IFaHVUcCdcdBagiZw/uVNzUAMSS/RgzKcVqI6H+CZSK1y1r2IJ zxxg== X-Gm-Message-State: AOJu0YzehyqTmAu2mJuFB2ddP5kC5ge3iGb7IFee/60ZxysnuThyMql4 SBTs2D+ByWma6A1FwdVX9UOIrg== X-Google-Smtp-Source: AGHT+IF6xYqWu+N/+NmMuEJHiscRxkTxhmGb4u2hRcEmQfkg+3wVWPO6ruzuVOlWxi45cXpF52kaWA== X-Received: by 2002:a2e:9613:0:b0:2bf:7905:12c3 with SMTP id v19-20020a2e9613000000b002bf790512c3mr1427429ljh.40.1697544300349; Tue, 17 Oct 2023 05:05:00 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.04.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:04:59 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Heiko Stuebner Subject: [PATCH v3 11/73] gpio: rockchip: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:29 +0200 Message-Id: <20231017120431.68847-12-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Heiko Stuebner Acked-by: Linus Walleij --- drivers/gpio/gpio-rockchip.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-rockchip.c b/drivers/gpio/gpio-rockchip.c index 23040a8cea34..3576793f0bd9 100644 --- a/drivers/gpio/gpio-rockchip.c +++ b/drivers/gpio/gpio-rockchip.c @@ -159,9 +159,9 @@ static int rockchip_gpio_set_direction(struct gpio_chip= *chip, =20 =20 if (input) - pinctrl_gpio_direction_input(bank->pin_base + offset); + pinctrl_gpio_direction_input_new(chip, offset); else - pinctrl_gpio_direction_output(bank->pin_base + offset); + pinctrl_gpio_direction_output_new(chip, offset); =20 raw_spin_lock_irqsave(&bank->slock, flags); rockchip_gpio_writel_bit(bank, offset, data, bank->gpio_regs->port_ddr); --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CA1DACDB484 for ; Tue, 17 Oct 2023 12:05:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232093AbjJQMFh (ORCPT ); Tue, 17 Oct 2023 08:05:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343545AbjJQMFT (ORCPT ); Tue, 17 Oct 2023 08:05:19 -0400 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 75AE6107 for ; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-2c503da4fd6so56571861fa.1 for ; Tue, 17 Oct 2023 05:05:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544301; x=1698149101; darn=vger.kernel.org; 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=NRDXdsqovOpFqQlW6NMXq89oYY2ugyvGcK/dIwIm0sQ=; b=AVXa3Tfzl3rav88xlFsyfnoFwSZsbQQt8eBC++dVnjBZZ9UfYBy6XsKBdKVY8FE4Ut XYYZGqnJTT9gJw7xyjkh5icGGhOYZJnSvRC0i4Rg4HyBMZD4vwxwXdSOM+TaLEMN6EDC JP1tRnuaxN56jpo2sP18sBmddk+ONOdYJQUcYjNbmm1U2g2BhZTDEwxGfWatCKL/OSEW FPZLr9hsEM0HnUVcOC/95k/cVxrBpFe5Poc0B6/0cN3LNn4faQoHuIKl00qCAkNuREvb RKORyYr4YBtRjNiII8d/DkgJ0hBInPqf5Gip9Rl1ZoDIrIRwzEWk/kL2EkCa15KqKOQH MhRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544301; x=1698149101; 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=NRDXdsqovOpFqQlW6NMXq89oYY2ugyvGcK/dIwIm0sQ=; b=LCcknYFKz06rs6xiZmfC7Ok8O5m8i9fd0pYKQwH8nAE3VuLkgE7zCe0IogIdyFpCOQ PxkxwiHi/97szV3d/KhiRp/V3Brz0Moh0Ab9cl3b+iyGh+QVQSOk/ekX/wCvs+rN7Wvd RtkFfxooPQPkuknSTN9eR4z2/Ikw+va8ul+Fy2J1hW1l0O/25tqgJGdrHnqyzbgQ8+Az x2+n8qggkkoiwdAnM5YZIy6MJrVzDCGaeEcm8m1BsuhKIU9JUPoixWyi7v66uR/SjnpS GflTKzyes5ytHdAFElFrujGwZX8M+4WDmPKdTvEH3wyf2gm8iQ/+t7R7KghDs6woZ3aG rWwg== X-Gm-Message-State: AOJu0YzN+7Zh8+ys5ebnfkKUB/3y7RSoeR0HdokcU/4hwYHYGXBBRavK Gcb2kECHnAywtMWVmOAG/zds9Q== X-Google-Smtp-Source: AGHT+IGFdSq5yv35rcnk3spnwirE3Sg8RRrCIpFX291tKimiy2IrcXTLdu2jVgFX3XJX1uSRtKRQbA== X-Received: by 2002:a05:651c:54b:b0:2c5:106f:5416 with SMTP id q11-20020a05651c054b00b002c5106f5416mr1557572ljp.53.1697544301101; Tue, 17 Oct 2023 05:05:01 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:00 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 12/73] gpio: vf610: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:30 +0200 Message-Id: <20231017120431.68847-13-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-vf610.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-vf610.c b/drivers/gpio/gpio-vf610.c index a89ae84a1fa0..2c22a31ffbdc 100644 --- a/drivers/gpio/gpio-vf610.c +++ b/drivers/gpio/gpio-vf610.c @@ -130,7 +130,7 @@ static int vf610_gpio_direction_input(struct gpio_chip = *chip, unsigned gpio) vf610_gpio_writel(val, port->gpio_base + GPIO_PDDR); } =20 - return pinctrl_gpio_direction_input(chip->base + gpio); + return pinctrl_gpio_direction_input_new(chip, gpio); } =20 static int vf610_gpio_direction_output(struct gpio_chip *chip, unsigned gp= io, @@ -148,7 +148,7 @@ static int vf610_gpio_direction_output(struct gpio_chip= *chip, unsigned gpio, =20 vf610_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output(chip->base + gpio); + return pinctrl_gpio_direction_output_new(chip, gpio); } =20 static void vf610_gpio_irq_handler(struct irq_desc *desc) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2F81FCDB474 for ; Tue, 17 Oct 2023 12:05:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232115AbjJQMFk (ORCPT ); Tue, 17 Oct 2023 08:05:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43432 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234875AbjJQMFU (ORCPT ); Tue, 17 Oct 2023 08:05:20 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DE0CC12F for ; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-405361bb94eso62866485e9.0 for ; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544302; x=1698149102; darn=vger.kernel.org; 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=tHI6d381lpIvDTYFHvoZ0PRRcyIxnTmGZ3C+R5KwSLA=; b=xpGnHqrZuoCz6+EV12Afs8+S1U5sJTTraQOcG4CxG5k5r234LOCcZsW+Ub34LyYR4A m2y/Zyu7Ed7KxqnBtrXHNsK4LKrff36ZjSbZGzU/kkTrbzqWFvZT9P+fp8Y5RfAjps3j Ec2y6N51A7yprRuAoLof+Q+abltqPWl42bQaAE8FS16EckYbxTNQSCWyPL0iRzdIdEuc qoxa8mrMGxPeYWacg4/m0UqtQL/JXGy1eFPypeZSeN6d5L5qF3iJNSKWH+OCrq7sIg4m t2pOg8vqY2sIBz0hC1QL5/7mvY7diwN6WefDda1qANwgbnCp4fUdWpmVoe7TXmbtvlOX 6zfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544302; x=1698149102; 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=tHI6d381lpIvDTYFHvoZ0PRRcyIxnTmGZ3C+R5KwSLA=; b=c9HAANhdojgbdzDLLIn227eoowbvpG+KjgAaNI1yKaa8CacceO/RZaM9Zo3ouEVpeM 7090lchvbG/+Awhm5YbLmd8jvxGwnc4iqS6uOf7SzU+SFaU27FnYa5lWEKluJNIiG6tJ A405GaiJcDWidJ85ifFOGXOkdrAnG5VE41+VYt60PeW9J/J1waHyxcskeczIdZyj38Ze JX2Wb3Vdj5S1OzSc4Y5E/XCB2sEslSySHgANw1OFeQvlHSenzyTkGElm+rcgHxBHnfI7 vbYcF2RPURI+ZeZTMyVRP7ZIJgaf1/DcrJqqcatSu6OzGyRCbmKMBdyMHkOzrufWMNxY onfg== X-Gm-Message-State: AOJu0Yy/nup/ZxOmBJrX0PPWJZ8HrkzXnttS7sfMCWrcQ+9P88WcvnUa 9YvV7WWp8AymO3o1TvxAIr/MJQ== X-Google-Smtp-Source: AGHT+IEZXS/C3l9TxoArNZaOgJVdtOfkTccpusxbFvRTIJTxzaX3Jx0VGHsyc/KxyBQRFu/tYhvF0g== X-Received: by 2002:a05:600c:3b13:b0:3fb:feb0:6f40 with SMTP id m19-20020a05600c3b1300b003fbfeb06f40mr1702876wms.11.1697544301931; Tue, 17 Oct 2023 05:05:01 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:01 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 13/73] pinctrl: nuvoton: npcm7xx: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:31 +0200 Message-Id: <20231017120431.68847-14-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index 8bdd0124e2eb..62134a7f0b4e 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -171,7 +171,7 @@ static int npcmgpio_direction_input(struct gpio_chip *c= hip, unsigned int offset) struct npcm7xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_input(offset + chip->base); + ret =3D pinctrl_gpio_direction_input_new(chip, offset); if (ret) return ret; =20 @@ -188,7 +188,7 @@ static int npcmgpio_direction_output(struct gpio_chip *= chip, dev_dbg(chip->parent, "gpio_direction_output: offset%d =3D %x\n", offset, value); =20 - ret =3D pinctrl_gpio_direction_output(offset + chip->base); + ret =3D pinctrl_gpio_direction_output_new(chip, offset); if (ret) return ret; =20 @@ -201,7 +201,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) int ret; =20 dev_dbg(chip->parent, "gpio_request: offset%d\n", offset); - ret =3D pinctrl_gpio_request(offset + chip->base); + ret =3D pinctrl_gpio_request_new(chip, offset); if (ret) return ret; =20 @@ -211,7 +211,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) { dev_dbg(chip->parent, "gpio_free: offset%d\n", offset); - pinctrl_gpio_free(offset + chip->base); + pinctrl_gpio_free_new(chip, offset); } =20 static void npcmgpio_irq_handler(struct irq_desc *desc) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 13043CDB483 for ; Tue, 17 Oct 2023 12:05:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234933AbjJQMF4 (ORCPT ); Tue, 17 Oct 2023 08:05:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234957AbjJQMFa (ORCPT ); Tue, 17 Oct 2023 08:05:30 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4456B139 for ; Tue, 17 Oct 2023 05:05:05 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-40572aeb73cso55553205e9.3 for ; Tue, 17 Oct 2023 05:05:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544303; x=1698149103; darn=vger.kernel.org; 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=GIzjlRTW4yfBl8pe7XEMggW85sINbfz/7P42+EtFezw=; b=hc2K9WhajDXrpdRDmotdM1wbScc+dlTDRiEWbc7dfslxftTkYVQMn+NtbyjDK4LNWp /biGYzskhP6EYf8NdYUCFNgfG4elbQnnKluLXPIlqkiOkPwGmUapLV8pFZlWWV7MjAOG ZT6ZRlyg1elJjhLkLjD7PSbSNjvGpnBJruwY31cwzDz1+4DzNDOB+vOS1YecDyJ1vVZn 4aXhXsj4Kk5ofv+a/EwiIqw6wCIBbqFgcW9595EMXqFAklWTwzx4EBK6xp5w0QJnd2Hh CZkfWi7s1ZsO5JTebJgCtmI3jGTQgl/aWSkE0tKpn5E9kFsdjBdzviQg+DT8CqemIAp6 BF8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544303; x=1698149103; 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=GIzjlRTW4yfBl8pe7XEMggW85sINbfz/7P42+EtFezw=; b=u0LxTRTiTNlnWsfL1AgW8tw93QM3/GUDFhwyYWp0PCCYErI1nv4CWbk1eP65cjM5k0 mME9U0iSC5ZwKWsZ3jWo5Gv8aZU97PArrOzy1FN9vwjtk1fJuhsq4RM7TT8iOxFP6cVj 5k7FET8AgDqJ+m27Vsm3xcSCKLkMmJ5jk++j8Qa6ls+3J6+a8AROBssO2sfIMl6nW1Yx 3JZAS+4kSI+esknCFRxCqDs2YsAqALmhnfUAKG8iCn1g8WlgK1UX6XexE8bQ4c2goI/O J3QWAWrfvFSV0TGVKlVkqlZhJdaNC2ZTSxgdaNaoLGtJym6uYgkjLuw5AfnsmtONvDLl 2QZA== X-Gm-Message-State: AOJu0Yxwehr3Jmypg6SdWwo6p0WXmzVhCGvnTtua1ha2vzv62XUfk70S MhanHPVVYVfpcO1yIp9gzyRPQg== X-Google-Smtp-Source: AGHT+IFg8FOTE4zP5B3q7qGa25TCcqxV8CloFWWfCWlRUmvZ4ifvpBaTm+98+xnkdNuxO4C1+z2+FA== X-Received: by 2002:a05:600c:4f42:b0:405:3455:d603 with SMTP id m2-20020a05600c4f4200b004053455d603mr1564336wmq.17.1697544303497; Tue, 17 Oct 2023 05:05:03 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:03 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 14/73] pinctrl: nuvoton: npcm8xx: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:32 +0200 Message-Id: <20231017120431.68847-15-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index da21f6a45888..0b6d6964087e 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -173,7 +173,7 @@ static int npcmgpio_direction_input(struct gpio_chip *c= hip, unsigned int offset) struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_input(offset + chip->base); + ret =3D pinctrl_gpio_direction_input_new(chip, offset); if (ret) return ret; =20 @@ -186,7 +186,7 @@ static int npcmgpio_direction_output(struct gpio_chip *= chip, struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_output(offset + chip->base); + ret =3D pinctrl_gpio_direction_output_new(chip, offset); if (ret) return ret; =20 @@ -198,7 +198,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_request(offset + chip->base); + ret =3D pinctrl_gpio_request_new(chip, offset); if (ret) return ret; =20 @@ -207,7 +207,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) =20 static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free(offset + chip->base); + pinctrl_gpio_free_new(chip, offset); } =20 static void npcmgpio_irq_handler(struct irq_desc *desc) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF580CDB474 for ; Tue, 17 Oct 2023 12:06:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234928AbjJQMGK (ORCPT ); Tue, 17 Oct 2023 08:06:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60760 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234935AbjJQMFb (ORCPT ); Tue, 17 Oct 2023 08:05:31 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C429E194 for ; Tue, 17 Oct 2023 05:05:06 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-40566f8a093so54066925e9.3 for ; Tue, 17 Oct 2023 05:05:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544304; x=1698149104; darn=vger.kernel.org; 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=ta+JXTCEvoYCkfYdZVmNUE+yvh6PoUsZ4OUodo3JS+4=; b=qp61ulenASzeO4vCFg/S3btMccU2ji6nnoWqw2LS4MBIQMMITXlzR8QKWnexnVgcYO 9vfVpJnpa4d9r1DBrWnVreekLfV/bVYSCMjrNCP6bsOriMLIRw5pmk7JC1J5hsKBv4HA hjPxjNHbfAf5ha6GRM60McUc18yZkixgvpWNh1L2f7Tnd0I98/Wu/teuRVyTTvpPpfEu gxUd3QUHPApHOfdsqhIJKqzbitf+5sZQua+nWFfhF4dGKcQ5UOvgtkzwVg5XP1kF6mhk aqRzzD4hBBEMjRrM/+DcYnVdBGblVqka4/nAExc5badWtLMPW5HC09oH78c6C4ilAN7Y zW9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544304; x=1698149104; 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=ta+JXTCEvoYCkfYdZVmNUE+yvh6PoUsZ4OUodo3JS+4=; b=ek+H5h+m64BEXEHhlVYEAYY6AB2Lw4/lh5m0YOLmnakHNUUeNlscYs0/VIeBZO4nE2 Z0ZAtrBiu3d3qSFE1QVEeDGgpbihS3/d1FTGeVuxjp8ra6Wg7FYAUNY1fc5scFHCdOZ8 DWTBvUN8lG8QBsO9yznkU5vGG1E662ULOJMvF49nqgVqsXALg+H2EwW/tDYhoKRONPV1 dz5ef/nNSYCMgrPGKjxpd/CnVIFD4RpYjApkkMw9PXW0fGggYP+gB5SbSoPtNDd6P88X S3NlCAhWXoT+3h0ghNWMKM/mOzz+WkWNSREsAjNmAD2dnoq/LxzFndX2sbh9jUxbxQeh EPSA== X-Gm-Message-State: AOJu0YzJaK0vDruafdqITxgPAgsGGANyGUeM12ptY61pp7QTn57Uqijp TvSj9JxDm6b/Tqz+BFzpXTDmew== X-Google-Smtp-Source: AGHT+IHxiIn/wqd5crz6PHnRl0Lr/UaCsryg1PSyc97t9TzH2DAAWw7CedNCmdQLrkP/7m+zpeL3VA== X-Received: by 2002:a05:600c:294c:b0:405:499a:7fc1 with SMTP id n12-20020a05600c294c00b00405499a7fc1mr1429909wmd.40.1697544304325; Tue, 17 Oct 2023 05:05:04 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:03 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Geert Uytterhoeven Subject: [PATCH v3 15/73] pinctrl: renesas: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:33 +0200 Message-Id: <20231017120431.68847-16-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Geert Uytterhoeven Acked-by: Geert Uytterhoeven Acked-by: Linus Walleij --- drivers/pinctrl/renesas/gpio.c | 8 ++++---- drivers/pinctrl/renesas/pinctrl-rzg2l.c | 4 ++-- drivers/pinctrl/renesas/pinctrl-rzv2m.c | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/pinctrl/renesas/gpio.c b/drivers/pinctrl/renesas/gpio.c index 5758daf94fe2..e7771a57e6d1 100644 --- a/drivers/pinctrl/renesas/gpio.c +++ b/drivers/pinctrl/renesas/gpio.c @@ -135,12 +135,12 @@ static int gpio_pin_request(struct gpio_chip *gc, uns= igned offset) if (idx < 0 || pfc->info->pins[idx].enum_id =3D=3D 0) return -EINVAL; =20 - return pinctrl_gpio_request(gc->base + offset); + return pinctrl_gpio_request_new(gc, offset); } =20 static void gpio_pin_free(struct gpio_chip *gc, unsigned offset) { - return pinctrl_gpio_free(gc->base + offset); + return pinctrl_gpio_free_new(gc, offset); } =20 static void gpio_pin_set_value(struct sh_pfc_chip *chip, unsigned offset, @@ -164,7 +164,7 @@ static void gpio_pin_set_value(struct sh_pfc_chip *chip= , unsigned offset, =20 static int gpio_pin_direction_input(struct gpio_chip *gc, unsigned offset) { - return pinctrl_gpio_direction_input(gc->base + offset); + return pinctrl_gpio_direction_input_new(gc, offset); } =20 static int gpio_pin_direction_output(struct gpio_chip *gc, unsigned offset, @@ -172,7 +172,7 @@ static int gpio_pin_direction_output(struct gpio_chip *= gc, unsigned offset, { gpio_pin_set_value(gpiochip_get_data(gc), offset, value); =20 - return pinctrl_gpio_direction_output(gc->base + offset); + return pinctrl_gpio_direction_output_new(gc, offset); } =20 static int gpio_pin_get(struct gpio_chip *gc, unsigned offset) diff --git a/drivers/pinctrl/renesas/pinctrl-rzg2l.c b/drivers/pinctrl/rene= sas/pinctrl-rzg2l.c index c7c6d912a975..22d4ab7d228c 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzg2l.c +++ b/drivers/pinctrl/renesas/pinctrl-rzg2l.c @@ -1056,7 +1056,7 @@ static int rzg2l_gpio_request(struct gpio_chip *chip,= unsigned int offset) if (ret) return ret; =20 - ret =3D pinctrl_gpio_request(chip->base + offset); + ret =3D pinctrl_gpio_request_new(chip, offset); if (ret) return ret; =20 @@ -1181,7 +1181,7 @@ static void rzg2l_gpio_free(struct gpio_chip *chip, u= nsigned int offset) { unsigned int virq; =20 - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); =20 virq =3D irq_find_mapping(chip->irq.domain, offset); if (virq) diff --git a/drivers/pinctrl/renesas/pinctrl-rzv2m.c b/drivers/pinctrl/rene= sas/pinctrl-rzv2m.c index 52aeafaba4b6..3d29c77a5aad 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzv2m.c +++ b/drivers/pinctrl/renesas/pinctrl-rzv2m.c @@ -754,7 +754,7 @@ static int rzv2m_gpio_request(struct gpio_chip *chip, u= nsigned int offset) u8 bit =3D RZV2M_PIN_ID_TO_PIN(offset); int ret; =20 - ret =3D pinctrl_gpio_request(chip->base + offset); + ret =3D pinctrl_gpio_request_new(chip, offset); if (ret) return ret; =20 @@ -832,7 +832,7 @@ static int rzv2m_gpio_get(struct gpio_chip *chip, unsig= ned int offset) =20 static void rzv2m_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); =20 /* * Set the GPIO as an input to ensure that the next GPIO request won't --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 93A1BCDB474 for ; Tue, 17 Oct 2023 12:06:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234832AbjJQMGD (ORCPT ); Tue, 17 Oct 2023 08:06:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50986 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234988AbjJQMFb (ORCPT ); Tue, 17 Oct 2023 08:05:31 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4270319D for ; Tue, 17 Oct 2023 05:05:06 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40806e4106dso2990605e9.1 for ; Tue, 17 Oct 2023 05:05:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544305; x=1698149105; darn=vger.kernel.org; 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=6CbdpxA2yoiqOdTkvvgzFYeQ0S/2apw7f0m7nJ4Vrkk=; b=Ksc0BEO0uniL77xulNSoapsduPfB59WZzHCJqulnsaAO8aKENVK2w88gANTm8Eg0b1 ujs8YOH6PDK90DJNCTM9nxQTDgq+6dCiHGZ1/J7Q77UWP38soZL6xUpjD1s7+Gss9mDk 7PM5Lzo2Ffutm1IfOdO66jTlIKRDbmdTGhOorNYmqaiu8wSfbxjLVa0CB5zBiLMElUrq T0/rgizoyDrOcPOoDpwUoq98ZuT/Gz5U2TRm3ihqxSIDOHMgwlpaOHtgfNn0tNXhuQ5M h5g08XrVn6+UyMlpcdFql4o3SXVHyyaluu+lcazHpbQlaU3DWtSGfOf4uwTTMWpHsK/1 UFtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544305; x=1698149105; 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=6CbdpxA2yoiqOdTkvvgzFYeQ0S/2apw7f0m7nJ4Vrkk=; b=KnjDSQI52FrCXg+d/QGRxa0iQ2UvpBMQkit69KRq5beg0YXt0onBp5rJuiBK0Uzt2K LPPW1saRtkaf1NfaMSgMgBoD/FQzD2V09rPKO0dq6yW/QJNObGfZn1VKx53NSA1u2+fv FFMZSWyP1xTS7jXncQQWqlOPNUZeZzPeBSWJHeL6HHooyHqf9Tu1GAHQQ5uADxXa3HXe zCH362QV77DLbA+Sp6JtUGeGJwiIEjlni731WTYy9Tp2wlUE0ZIPxPo9xEqNb6m/QNBm nt9awGJpFIUy2jY/H/KtVF7AsMIvwFVibyGNLNm/3N4RAgjIA4fkspXuto44JMh7y1nD vveg== X-Gm-Message-State: AOJu0YxgSQ5flR0s2gsJzXtLgWe6bB2+MFnX/wgSzojPK0eVnUrB84nc e7LG+aKvGXeVzZ8OU0Q6dtL0zg== X-Google-Smtp-Source: AGHT+IFf+OmIb8KXJS2ZkopH1GoMeY8rCnnDQP9EsEwpiPcrwzJmSCB/WSLyz86HviPM31NGQkLsOw== X-Received: by 2002:a05:600c:6012:b0:3fe:d67d:5040 with SMTP id az18-20020a05600c601200b003fed67d5040mr1766789wmb.5.1697544305075; Tue, 17 Oct 2023 05:05:05 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:04 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 16/73] pinctrl: bcm: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:34 +0200 Message-Id: <20231017120431.68847-17-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm= /pinctrl-iproc-gpio.c index bc7bb9876e57..fb98c3e14743 100644 --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c @@ -330,24 +330,22 @@ static const struct irq_chip iproc_gpio_irq_chip =3D { static int iproc_gpio_request(struct gpio_chip *gc, unsigned offset) { struct iproc_gpio *chip =3D gpiochip_get_data(gc); - unsigned gpio =3D gc->base + offset; =20 /* not all Iproc GPIO pins can be muxed individually */ if (!chip->pinmux_is_supported) return 0; =20 - return pinctrl_gpio_request(gpio); + return pinctrl_gpio_request_new(gc, offset); } =20 static void iproc_gpio_free(struct gpio_chip *gc, unsigned offset) { struct iproc_gpio *chip =3D gpiochip_get_data(gc); - unsigned gpio =3D gc->base + offset; =20 if (!chip->pinmux_is_supported) return; =20 - pinctrl_gpio_free(gpio); + pinctrl_gpio_free_new(gc, offset); } =20 static int iproc_gpio_direction_input(struct gpio_chip *gc, unsigned gpio) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 76311CDB482 for ; Tue, 17 Oct 2023 12:06:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234925AbjJQMGR (ORCPT ); Tue, 17 Oct 2023 08:06:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43360 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234807AbjJQMFr (ORCPT ); Tue, 17 Oct 2023 08:05:47 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BCBF11A6 for ; Tue, 17 Oct 2023 05:05:07 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-40776b1ff73so32489095e9.2 for ; Tue, 17 Oct 2023 05:05:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544306; x=1698149106; darn=vger.kernel.org; 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=wPwuEwfRZF39P0qe4RqCU1p549Ra/xLyaMOsvkr04jY=; b=ALlXbgt/Wpe+uIRa0DokBqYy/kZo82Z+L2+Cf/9xz3lfmlQBonaNTjnMFjim9LjYiK W1qzz5BH5n21avQv6kGCq4UlEenyN7lYE3Km1kznSb2LZv/B03EHiSnWOnemFFzuM9jg lP/aFTLxhelLJr6uSBWavQaGSvVIUoPVWJQpxqwqBQc1Up888s6X5MWeOkm+EXh0fsR9 +hRgYd/b5SmWq+b9t1bZAfk2+recJdvhmRXlsqCT/azwsvb/lE7lsOAUbQU/XL5qzJ/M LWR4jTokYfqgDCXDF6e6Rhfx5EVG/hJUiMKdlFw/7MnA1aeZxuLiopfPMzKx88/qgCmw VNhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544306; x=1698149106; 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=wPwuEwfRZF39P0qe4RqCU1p549Ra/xLyaMOsvkr04jY=; b=OFQWPVyrDiC4CfMQjCzRjyRXaK+lWPLyBBL18U0lgOKofQH2fIjlsdUzM0ldr+VgZA hMitnVZD6fQyZKJOpgY4h8/7LqJ0xx/jJVMVgnh5LHu8HNW3w+Ghea4o+lwwnhGc7aW3 /ob7RuF8FnjB/u3Ykvds1Rcrvpu/k6Q66l0jBXxpjalW6Gg72m+9W3bsXbZSJ6UMadyC 4CDCvSw7kcHrZX4GG0aqE1+HWny203VJBQZRlo82w99iY8Skp70O+Yqh0G7WNwHxPUIR oSAtRqDvlp2VVVTAarVsipPmaO7432ebe30JRvTl28tMqE9xwuPjjr1QiKEU/DHmiRqw 64/Q== X-Gm-Message-State: AOJu0Yx2hXlI20nxcY0Qclt1rtLoxLSVeXDPJBa0CB7HKaJRGb5NI7vD agbg3TL6OMlTnXoXiKVdZ0nZWA== X-Google-Smtp-Source: AGHT+IESz/519coifuniggGRbm/pl4zw6Mdj+LHiTmP7DPt4+Q992oqG7iyXA89aU5ehDoX/56Nzqw== X-Received: by 2002:a05:600c:4e89:b0:406:3977:eccd with SMTP id f9-20020a05600c4e8900b004063977eccdmr1494323wmq.33.1697544305855; Tue, 17 Oct 2023 05:05:05 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:05 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 17/73] pinctrl: stm32: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:35 +0200 Message-Id: <20231017120431.68847-18-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/stm32/pinctrl-stm32.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index a73385a431de..11d9f07934bd 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -217,12 +217,12 @@ static int stm32_gpio_request(struct gpio_chip *chip,= unsigned offset) return -EINVAL; } =20 - return pinctrl_gpio_request(chip->base + offset); + return pinctrl_gpio_request_new(chip, offset); } =20 static void stm32_gpio_free(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_free(chip->base + offset); + pinctrl_gpio_free_new(chip, offset); } =20 static int stm32_gpio_get(struct gpio_chip *chip, unsigned offset) @@ -241,7 +241,7 @@ static void stm32_gpio_set(struct gpio_chip *chip, unsi= gned offset, int value) =20 static int stm32_gpio_direction_input(struct gpio_chip *chip, unsigned off= set) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int stm32_gpio_direction_output(struct gpio_chip *chip, @@ -250,7 +250,7 @@ static int stm32_gpio_direction_output(struct gpio_chip= *chip, struct stm32_gpio_bank *bank =3D gpiochip_get_data(chip); =20 __stm32_gpio_set(bank, offset, value); - pinctrl_gpio_direction_output(chip->base + offset); + pinctrl_gpio_direction_output_new(chip, offset); =20 return 0; } --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 56B0AC41513 for ; Tue, 17 Oct 2023 12:06:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234860AbjJQMG2 (ORCPT ); Tue, 17 Oct 2023 08:06:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59168 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235036AbjJQMFx (ORCPT ); Tue, 17 Oct 2023 08:05:53 -0400 Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CA7E0D57 for ; Tue, 17 Oct 2023 05:05:10 -0700 (PDT) Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-40675f06f1fso41091285e9.1 for ; Tue, 17 Oct 2023 05:05:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544306; x=1698149106; darn=vger.kernel.org; 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=dPRzIFIU2I284yl/ON43iSE6foshfftHmva92Etqe/c=; b=VNgmRJc/Gsx85JpIDQw7ac2UDfMhWoKdeb/5WtOfSUGYjMTadqXs+SNkvvRLkHPL2+ CaaQ4CmpbjyfBViyA3v90fBf7ugWr8PIpOjKR+OLazUHTqcEhUQwXBdcKOYPF3XgIUB/ TIcvIDQxoiHy2s8/Zmn/op+uOjOV2h9s3r5p2NhVUPHynN9w7rB+SE0K8LrGPG07iojb mXiZw8TbbjmZ1un3fcGRNjXFiCK6vkrqLUZ6iFTzPdliWBJ8EqAEvBvoSbE6VMTFGO3+ ufiALeOB2xVpuedOgLouUsZZILU0AwVm4yrmPh6JulUqYp2eOxhqjZRM7aDRg9tqLfHm OpSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544306; x=1698149106; 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=dPRzIFIU2I284yl/ON43iSE6foshfftHmva92Etqe/c=; b=JsK3UMRRGHPT3gPUip2oEUhfKwrN1Hv2NfHyBBBB3RJos/grtN8ibiCPxjbLX065c+ CUUESV8SGNIncGAvqYdAUCxX5dEqH+c+Uk6BUQ5CpSLTn3cuIy9+c/QlMLyzaeXUozzn gbda5bL1A3gsPwcfRcJqKlNqPgc8vIaUoODIdmbNWnT+baoNyKCEp9dMM163zNkxQTvS sEYOa7er94GGIlUHVlWtJMf0eav832dLbJCpWYjyo5hEDUIu/ZX03wEqShChnKR4DpkU GACehmn7BrB3xpoHRV/mi7v7VZzEaBTt+1+t+Mz8efb9/HuV9qymiJ7z0aiWz8Uayoke f/dQ== X-Gm-Message-State: AOJu0YxNlj/PPvyoWFqarnuO5TQ+Rq7dgE3S9ZrSmLkjK/xs7MFOCen5 pFbYs25BboHp0i95a7xjAqAkXA== X-Google-Smtp-Source: AGHT+IGWkJeri8jyS0Ae6jZs+nKZuzy4WzXnyJfZIWeKjQDhfyINCb06MdhjhV4hz1V1AM7IEE6reQ== X-Received: by 2002:a05:600c:1912:b0:405:3924:3cad with SMTP id j18-20020a05600c191200b0040539243cadmr1659061wmq.15.1697544306662; Tue, 17 Oct 2023 05:05:06 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:06 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Viresh Kumar Subject: [PATCH v3 18/73] pinctrl: spear: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:36 +0200 Message-Id: <20231017120431.68847-19-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Viresh Kumar Acked-by: Linus Walleij --- drivers/pinctrl/spear/pinctrl-plgpio.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/spear/pinctrl-plgpio.c b/drivers/pinctrl/spear= /pinctrl-plgpio.c index 722681e0b89b..7488f6394318 100644 --- a/drivers/pinctrl/spear/pinctrl-plgpio.c +++ b/drivers/pinctrl/spear/pinctrl-plgpio.c @@ -204,14 +204,13 @@ static void plgpio_set_value(struct gpio_chip *chip, = unsigned offset, int value) static int plgpio_request(struct gpio_chip *chip, unsigned offset) { struct plgpio *plgpio =3D gpiochip_get_data(chip); - int gpio =3D chip->base + offset; unsigned long flags; int ret =3D 0; =20 if (offset >=3D chip->ngpio) return -EINVAL; =20 - ret =3D pinctrl_gpio_request(gpio); + ret =3D pinctrl_gpio_request_new(chip, offset); if (ret) return ret; =20 @@ -249,14 +248,13 @@ static int plgpio_request(struct gpio_chip *chip, uns= igned offset) if (!IS_ERR(plgpio->clk)) clk_disable(plgpio->clk); err0: - pinctrl_gpio_free(gpio); + pinctrl_gpio_free_new(chip, offset); return ret; } =20 static void plgpio_free(struct gpio_chip *chip, unsigned offset) { struct plgpio *plgpio =3D gpiochip_get_data(chip); - int gpio =3D chip->base + offset; unsigned long flags; =20 if (offset >=3D chip->ngpio) @@ -280,7 +278,7 @@ static void plgpio_free(struct gpio_chip *chip, unsigne= d offset) if (!IS_ERR(plgpio->clk)) clk_disable(plgpio->clk); =20 - pinctrl_gpio_free(gpio); + pinctrl_gpio_free_new(chip, offset); } =20 /* PLGPIO IRQ */ --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3E7F3CDB474 for ; Tue, 17 Oct 2023 12:06:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343628AbjJQMGc (ORCPT ); Tue, 17 Oct 2023 08:06:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50966 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234760AbjJQMFy (ORCPT ); Tue, 17 Oct 2023 08:05:54 -0400 Received: from mail-wm1-x332.google.com (mail-wm1-x332.google.com [IPv6:2a00:1450:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A7AD0D63 for ; Tue, 17 Oct 2023 05:05:11 -0700 (PDT) Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-40572aeb673so53900615e9.0 for ; Tue, 17 Oct 2023 05:05:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544307; x=1698149107; darn=vger.kernel.org; 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=8H3QKxaZyWg3ZP7YHeatEgOsl69MRzJ/Cd/1HakMRZU=; b=LC9crqaBN8/Opclvtzk+b44mGVYLZ6eyPjzNAQUDefjVpbCXV3jRHJp8ziqo2ub0t4 m6kF4jQEGkaRqh5cq1E68b0Ttnr6T7SN16qoFVaexlrx9ga1TU+m9H5JGvTBF5SwQERl uJsSVIAk4mDN5xT/x6KJSUi9q9ZT6zsoMjXGjj7Qy/BlF5I3hShDyvjKdR4oJlaPHIex Jco6ve03WiB6jZ2rjDIaWtASVr9DvRH7vTZ5Vthn25/avG4boKdyjhL+xXwGbNeJuTP8 wtsSPIOCNfc3yhCS6wZQ8z5DYEb+bYk9cnil3Ki82RmZRhV34Kmd5dapB8MGhqq83zWI kuMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544307; x=1698149107; 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=8H3QKxaZyWg3ZP7YHeatEgOsl69MRzJ/Cd/1HakMRZU=; b=c1qOYPRnURDFk4IJuriGaW2I4s4sg7Pm867ElTzEaWiSYBbIneyXA4XIvDcTb1PwYK KE3L15xr18ondnNwIrFZx+FxwQedUlgdnGP7ivgySbEog1p49vRHe2W6hGpDxjNh1WwU WF9Mmwgkp6or7javoMsv+VazodqcfdFk0q3ohA4B7VkG/HLoAzJK8BuXZLxy9XSfY3yb 01EKyjFr1pVKaSP52xCUKKC3AXsZ7HZvkMNczQ3mOp/dOgjDWwT/iF3/LY+4hIAKV7ay M/8Cvj9FxArthFEmKgVwtIU6dx4+EnyQnay0q2CoZxHZHgTw11SBs6kRKMWQ7M9gRPoG D+4w== X-Gm-Message-State: AOJu0YyY0jTYfBIa5iiba/0jNGGMJwxwU346yxxc/h9Hlvy+jtN7UEEA g+1cbSrENnAQ99qURQjlZkUAVA== X-Google-Smtp-Source: AGHT+IFkms7KmMc5I89ZrROxrFEKHacfqXoc3Yne1I/ZE7AGfAMn6xMFwVA9mrORkKXIzfO/xo0lrA== X-Received: by 2002:a05:600c:a47:b0:402:95a0:b2ae with SMTP id c7-20020a05600c0a4700b0040295a0b2aemr1788066wmq.32.1697544307571; Tue, 17 Oct 2023 05:05:07 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:07 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 19/73] pinctrl: starfive: jh7100: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:37 +0200 Message-Id: <20231017120431.68847-20-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7100.c index 530fe340a9a1..22a2db8fa315 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c @@ -918,12 +918,12 @@ static struct pinctrl_desc starfive_desc =3D { =20 static int starfive_gpio_request(struct gpio_chip *gc, unsigned int gpio) { - return pinctrl_gpio_request(gc->base + gpio); + return pinctrl_gpio_request_new(gc, gpio); } =20 static void starfive_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free(gc->base + gpio); + pinctrl_gpio_free_new(gc, gpio); } =20 static int starfive_gpio_get_direction(struct gpio_chip *gc, unsigned int = gpio) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 73506CDB474 for ; Tue, 17 Oct 2023 12:06:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343651AbjJQMGh (ORCPT ); Tue, 17 Oct 2023 08:06:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43416 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234987AbjJQMF5 (ORCPT ); Tue, 17 Oct 2023 08:05:57 -0400 Received: from mail-lj1-x236.google.com (mail-lj1-x236.google.com [IPv6:2a00:1450:4864:20::236]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A5250D6E for ; Tue, 17 Oct 2023 05:05:12 -0700 (PDT) Received: by mail-lj1-x236.google.com with SMTP id 38308e7fff4ca-2c501bd6ff1so61891731fa.3 for ; Tue, 17 Oct 2023 05:05:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544308; x=1698149108; darn=vger.kernel.org; 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=bJw60bvTofR8qZvXWplxQFllGHB1oEM7kWCtPgsLTlc=; b=uSbNJi62ypO16TmTwo7X63ldRq28O14OUqM3J8XiqpFP+97o63RvUIfBLeYspZzWtx a7RFKvKBqJxYYSs7yErmXDPfEoeDXGVUNI8NmUuD5J+QELa2879syo/f5SzXlper4DeT nUBcOfv/EomnTsS4CgXHbW7E9yZaAgU5LaMN+r4oHSlNYwjCYd9rjtvgjbvDZ7NOVny9 eyPkYUGqDieCeJGpu6RyiBdill2vjtyMt7bdE9vKJHLah3kvNslF8em+w0/Wp70KF1Rs UbI5VzihKbJKot5gXVgevA3ILB4ZSUHScIagXzhlvZGHHYqS+9P1uN5uDGBhBY69ysP7 miqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544308; x=1698149108; 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=bJw60bvTofR8qZvXWplxQFllGHB1oEM7kWCtPgsLTlc=; b=ZFn4jXPFO7DFpif++cogUVnkCqaID7Eehsdx6vFPU6OPzTEWqWu1m/lPdcHK142JIR FyzsragH4VDXNAXjNANn4GUWyIj82+tSMAHlVS45hrPzyxiRG5rLl8k4obg3cDYvR5dz 1JvlCObC3AEy1f7SyZn3tLtzmLkB2jHLVL+R5A8DUHaFEYBq3EFHcK14PQQoepFnSlgy TRTQUTd9YMVO2XoiSoT5Ae4RrX/GorK1hBnb7UVO4FvV8NI0vMTzFI1hGotQRaoH3hVw 7CfuEw4JsMuemaTo47wrg9VK00zCz/xQVatw4xEo9q8011E0iI+Fo6EAORldK5Cznz89 nKiA== X-Gm-Message-State: AOJu0YzYmBzBzYkja2haBY9ZvLh52CJEEA6irbpdaACtzVifZKXuRR/r hy6+pdrt/eaIVKT+vg4Rti2zwA== X-Google-Smtp-Source: AGHT+IHLepSxDvIfZp7gFDezQH1gl/4yTCL9vjA9vC+7blRw7kvyufotAOsLm9SCIxMRMd+MHjG4Sw== X-Received: by 2002:a19:6557:0:b0:505:7371:ec83 with SMTP id c23-20020a196557000000b005057371ec83mr1533434lfj.48.1697544308381; Tue, 17 Oct 2023 05:05:08 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:07 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 20/73] pinctrl: starfive: jh7110: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:38 +0200 Message-Id: <20231017120431.68847-21-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7110.c index 640f827a9b2c..5557ef3fbeb2 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c @@ -547,12 +547,12 @@ static const struct pinconf_ops jh7110_pinconf_ops = =3D { =20 static int jh7110_gpio_request(struct gpio_chip *gc, unsigned int gpio) { - return pinctrl_gpio_request(gc->base + gpio); + return pinctrl_gpio_request_new(gc, gpio); } =20 static void jh7110_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free(gc->base + gpio); + pinctrl_gpio_free_new(gc, gpio); } =20 static int jh7110_gpio_get_direction(struct gpio_chip *gc, --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 47482CDB474 for ; Tue, 17 Oct 2023 12:06:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343640AbjJQMGf (ORCPT ); Tue, 17 Oct 2023 08:06:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36454 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235073AbjJQMF6 (ORCPT ); Tue, 17 Oct 2023 08:05:58 -0400 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1A84BD7F for ; Tue, 17 Oct 2023 05:05:12 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-40806e40fccso3493615e9.2 for ; Tue, 17 Oct 2023 05:05:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544309; x=1698149109; darn=vger.kernel.org; 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=b0sgIJXyiWCMH9BTQoi/ajBzkcQtsuv8BX1pVGl7zGQ=; b=Cq/DzslR6rIOsCqA4OXdxVyPASyc3VkHN8hplAOPyHr7VUIZdP4DevglLmjuaQjrHc 4N24wOvafiQb0FVvApx7aUAs5dwqzM8rsgWRGYY4wKolpz6QSxryOID1Cqt0F9R6RECE cfJA8kJv6YOUbIA/FysOezBnzhHIruKm2Jq7dWe0LPkSaZJsBDaPwdmKeuvswbEXAPTk ZAxvFGAQ5dwWPqnZOSNDw8MI6upZhqznj06erZqLo6Zzjo/IU19CTKF8muN0AnR1t58J +YpNtL/VH7Mvf9WhYutCGqdAU/t5mtrW3VB2zF9ZVZqeGjb2dIPioqKk3ArmRRDatvII itAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544309; x=1698149109; 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=b0sgIJXyiWCMH9BTQoi/ajBzkcQtsuv8BX1pVGl7zGQ=; b=CtGophJYqKBME8D/7V4EH63bGbgd6lm3xf39r5aCEA3m/u7utPN/fIh1ddgd0I2gdb UyvSeQR2Qim6UYqyeNhLhheX0gl7sH8+9wchQnXyk99dbmy1rBJXFsuBVUKD555Dq7lh WiJdSzq5jQtXeoR8PbGKLTe8okimyzDysatPH+OONi6uSD9HExfxUpDfBKbB+oqDUxXp iB6tdwelmUfAMGkYUpCb699NoRX4jSFtK0sY2p8I2dwyU4ry5etoRLYIbOZsyiPmQSFz jV8h5feW84q4srHWuqzfD+CGf9TyrO7lFsPDXfm29b39pF3VZdajSVgyNm4BX31/cXz9 TKJg== X-Gm-Message-State: AOJu0YxesvBc4bPc7icABR8+5eAfk7bGJCeIFnPfXNG1ZJncvPJdceXH pibD6NL2ByZ+WLsao53i+kWBVQ== X-Google-Smtp-Source: AGHT+IE/nc5I9+GQ/o41DO0BGiv6vt7/H/Y2JrbO9sOo2jK12NQjN+mMyMStCbfFk/vnHBmjDZb6zA== X-Received: by 2002:a05:600c:1550:b0:405:4f78:e128 with SMTP id f16-20020a05600c155000b004054f78e128mr1625995wmg.4.1697544309333; Tue, 17 Oct 2023 05:05:09 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:08 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 21/73] pinctrl: ocelot: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:39 +0200 Message-Id: <20231017120431.68847-22-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-ocelot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-oce= lot.c index f8ae2e974221..a6022d44ad6c 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1779,7 +1779,7 @@ static int ocelot_gpio_get_direction(struct gpio_chip= *chip, static int ocelot_gpio_direction_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int ocelot_gpio_direction_output(struct gpio_chip *chip, @@ -1795,7 +1795,7 @@ static int ocelot_gpio_direction_output(struct gpio_c= hip *chip, regmap_write(info->map, REG(OCELOT_GPIO_OUT_CLR, info, offset), pin); =20 - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static const struct gpio_chip ocelot_gpiolib_chip =3D { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7F969CDB474 for ; Tue, 17 Oct 2023 12:06:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343665AbjJQMGk (ORCPT ); Tue, 17 Oct 2023 08:06:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36478 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232593AbjJQMGF (ORCPT ); Tue, 17 Oct 2023 08:06:05 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7162A10C8 for ; Tue, 17 Oct 2023 05:05:13 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-4083740f92dso1510955e9.3 for ; Tue, 17 Oct 2023 05:05:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544310; x=1698149110; darn=vger.kernel.org; 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=SgDYd9Rguhjm4qQEjlLUgCLw45ItMDY7i661tMI87TY=; b=LlSS2DtzY4fcgC9sZwnpYo0Io/0oc/oxalLxA3j4fGHMLITZD3mHE5v+B82dYk77zg r0alUG0mKl5JAshaTAbg26j5b3/tyRzp9FRtXUK6u1TUbezllzC5rqqjDPLEHIjv3Kbv 9bJmU1Btd2ql63Xz7m8aqrj8GnZpTXpz3ZThvgC+kFJ0H4QfenSBiFHJDLME0CizsvtE nJ9jwTvhxiW5de87KH8VL8K54uC6RLW1gwtwYZ03Wt3SCr4vaKNUMXii+mXnqxnLDMwK 9ndkQBAb3RWmPd4vxTTI/0xSrHE1tsC7GPm1A7mtR98QzJI3C/EeWzkm69eTVAkoMS4K I4HA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544310; x=1698149110; 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=SgDYd9Rguhjm4qQEjlLUgCLw45ItMDY7i661tMI87TY=; b=Qxu/8ITZoPbyEVdOHt7y9YY1YFkW+WflRqHCVNE8B86af3OTHoxCLvupAQvJkZsxs4 hdB6gDC8+sDnB7Ldv669y66JBM+FZcuk2JzpANA5AXNoxXHuynumAtGfZW7m7TvUo8GV VfyvlduGzhT3gBZ5zOrYFjJsWkBi5yGkv0K24/RSaCsb4u0vCYFz1Jxk3RJpWrX6t1Kk KUHDS48uYZQesuDASF+v/g02K4EinWYJSJBX0tZvPX1NjK7zZJKvpVkzKJrLqQr2HVJq 7RDNa1kfWummhY6/15mPt9qbmIlXKOdvIk875V5R60UPKHc0Qdt35ncXosRZaqlVZ3go ZiqQ== X-Gm-Message-State: AOJu0YwdZRIN8ipafl8+M9TGr2kLGjHyo9fpIle8w0YsjNCUE/NM8kO1 MrHQvPSVyh7PDMjjG9MZPKDciw== X-Google-Smtp-Source: AGHT+IHoqOXAdwuaCibM3AvmWGcF7ULgsBaShA2+HrC8/rd7yKj5B3ysn1O2JoofsH7u7HJrI45SGA== X-Received: by 2002:a05:600c:4455:b0:406:4a32:1919 with SMTP id v21-20020a05600c445500b004064a321919mr1546165wmn.29.1697544310101; Tue, 17 Oct 2023 05:05:10 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:09 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 22/73] pinctrl: rk805: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:40 +0200 Message-Id: <20231017120431.68847-23-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-rk805.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-rk805.c b/drivers/pinctrl/pinctrl-rk80= 5.c index 2639a9ee82cd..58e6dd932bc7 100644 --- a/drivers/pinctrl/pinctrl-rk805.c +++ b/drivers/pinctrl/pinctrl-rk805.c @@ -289,14 +289,14 @@ static void rk805_gpio_set(struct gpio_chip *chip, static int rk805_gpio_direction_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int rk805_gpio_direction_output(struct gpio_chip *chip, unsigned int offset, int value) { rk805_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int rk805_gpio_get_direction(struct gpio_chip *chip, unsigned int o= ffset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DE11BCDB483 for ; Tue, 17 Oct 2023 12:06:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234983AbjJQMGr (ORCPT ); Tue, 17 Oct 2023 08:06:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50882 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343536AbjJQMGH (ORCPT ); Tue, 17 Oct 2023 08:06:07 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 503E710D4 for ; Tue, 17 Oct 2023 05:05:14 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-406402933edso55832805e9.2 for ; Tue, 17 Oct 2023 05:05:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544311; x=1698149111; darn=vger.kernel.org; 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=B7mQAW/gcS7bWGdM82oN9G3UwAV92bdGrqJQuitFsrM=; b=lr7mzP4MsyiUqnqqwfT9kA05p6E7NRFjKKLoTq/KCa5pGM2HqcO2UInBL+EjH53fzL 8dwMHMJngYAAZ7tj+THX7x/6kcT+k1SMYC5zJXkyWLUkks8BBrl/we8nMfbpzvfkHRM9 /cbM4w/6LlBs2T2E178pbsvuwpIyTd20mF7oiPNdi7yjOvY5Z5Sx02caFTTFUPOEtg+Z nNvVqBWENk9FpKvbhSahTJEZWU6E+S0fpfcDy/1on8/eDmyvQForm0rk2wHPxDKLwz96 CdD9BuechMLrghdvMsbcKKny661D4Yf/JhnNbLa13kIT+sX9YtPHQp4MRDAjWo4gwUGq FVlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544311; x=1698149111; 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=B7mQAW/gcS7bWGdM82oN9G3UwAV92bdGrqJQuitFsrM=; b=dW+vFgkjawJ6kYmuARDEDkCE8h0HoDBXIZ62PIo9lcZwmugJogwOg+2Xzb1OeoQklU UoqgXjuTHvHtW0AUpbIc73a2GAJRGZk3Rj1aqhNDKIuq+j8yhWZRLlNkFYm1BrGC6do1 CFjIG1OoBaBOEW7lQIokED9+4n8O6udkz3IaP0lELKBpAwT3oBESgBEPDLN1z/IaLlUX QMXOdKx6FnL27ZWsMpUgvZD45QQn+r/PwJg2nRH6uxSuB9dFR33YrO7Y8uQaAt43Lq06 bXHxJ8d4PoHcEL9M6pbb4BCl6KdtU/p7Leh1ioLL+rSN/Lfb8wYPwYlaFlzeCRXcsXpz CLMw== X-Gm-Message-State: AOJu0YxNGOxj5g5Zxd1PIBKPnuno836trQj42Muw0G+dXPZbrNefxd3V ZvkAFfLozOxH7lDdxj/bJxoCJw== X-Google-Smtp-Source: AGHT+IEzhjgOi2CL2N9u/A2zUe36QP/uG4RQiBPIaBY0sv5A2CMkLJO65L4EQaqfAQVA6Bb3QdLp/A== X-Received: by 2002:a05:600c:4e8c:b0:401:906b:7e9d with SMTP id f12-20020a05600c4e8c00b00401906b7e9dmr1617989wmq.18.1697544310895; Tue, 17 Oct 2023 05:05:10 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:10 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Charles Keepax Subject: [PATCH v3 23/73] pinctrl: cirrus: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:41 +0200 Message-Id: <20231017120431.68847-24-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Charles Keepax Acked-by: Linus Walleij --- drivers/pinctrl/cirrus/pinctrl-cs42l43.c | 4 ++-- drivers/pinctrl/cirrus/pinctrl-lochnagar.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c b/drivers/pinctrl/cir= rus/pinctrl-cs42l43.c index c09646318419..097e4dcdda36 100644 --- a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c +++ b/drivers/pinctrl/cirrus/pinctrl-cs42l43.c @@ -508,7 +508,7 @@ static void cs42l43_gpio_set(struct gpio_chip *chip, un= signed int offset, int va =20 static int cs42l43_gpio_direction_in(struct gpio_chip *chip, unsigned int = offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int cs42l43_gpio_direction_out(struct gpio_chip *chip, @@ -516,7 +516,7 @@ static int cs42l43_gpio_direction_out(struct gpio_chip = *chip, { cs42l43_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int cs42l43_gpio_add_pin_ranges(struct gpio_chip *chip) diff --git a/drivers/pinctrl/cirrus/pinctrl-lochnagar.c b/drivers/pinctrl/c= irrus/pinctrl-lochnagar.c index 0b78cf611afe..f3c8a8c14e14 100644 --- a/drivers/pinctrl/cirrus/pinctrl-lochnagar.c +++ b/drivers/pinctrl/cirrus/pinctrl-lochnagar.c @@ -1098,7 +1098,7 @@ static int lochnagar_gpio_direction_out(struct gpio_c= hip *chip, { lochnagar_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int lochnagar_fill_func_groups(struct lochnagar_pin_priv *priv) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CF107CDB484 for ; Tue, 17 Oct 2023 12:06:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234807AbjJQMGu (ORCPT ); Tue, 17 Oct 2023 08:06:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48754 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234896AbjJQMGJ (ORCPT ); Tue, 17 Oct 2023 08:06:09 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 19F0D10E2 for ; Tue, 17 Oct 2023 05:05:14 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id 38308e7fff4ca-2c514cbbe7eso39798621fa.1 for ; Tue, 17 Oct 2023 05:05:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544311; x=1698149111; darn=vger.kernel.org; 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=2gwFIIe2dfNDoGPAPdODaCL9BQnYwvvv05SCfNCv7tA=; b=lT367uBlb6sO5KXgrzhqkqk2lngX6LCcNuxCBeTvBRj7E1IT3xMYdlRNObF6YWUYlE LPiKXwOguC4oc9ASr4thH40jZwbRjqA7eoYqd44CsUHNu3rKzbhU+G8HuNA6M87khGq9 ab0e/QHHWcClc/qeVM9DZsHSKGFbQ/CvRLwFTsunnf6HspqlKfvRTvGIBFHcABj12oHS 4zc/7NhwO5wMAzjU4XM40UHTMzI3v4g4pEcXw0LlmTHkpImDGYxhwyynualDpkCHJXU8 pdEWHUsVrrkf8tQ3iMjijGLAeNl3aoAqnfhtQm77vV2+8E1/j1CHdSHrJWxTc8b4+5d2 AF5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544312; x=1698149112; 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=2gwFIIe2dfNDoGPAPdODaCL9BQnYwvvv05SCfNCv7tA=; b=dC/9nqnHd1C7+M8UElwwumg689TfPTmAqQo4hMQJVSCX0ytypTpZc5LJIeHyqjShoo 2j/sSKRriSuLP1mQlITQaf97TyG+dR23jqUj+Yc7EbduV4bBypdIQ5elF2dcM9clLwNQ 5LRPUcGIbLdiuJTC+8dFljb7xkEgKUnI8jhRfjBs8GUJLreHQHMVR98rafaUL1fnuBl1 +KrGWL0FuBAIidkbjSACfbMs8ii4ePJX954Zf7GGYDbRmRqlBUMzfg39Q19CVu/IfzYG npl0nuBrGpg/0J00g9G90kx08DJ7AagRiJfK2X3Y/S2bzCQCMmyO2bC/q6x2UtvBexzx 95Uw== X-Gm-Message-State: AOJu0YyyDzwpSNh91SW8HUlG/OmUy+9hnkdg1EemHMi8t/wx+5JwRPqQ 6Yr675FzNBHo/DmUoLajq6iNlQ== X-Google-Smtp-Source: AGHT+IFPnfwTXwP5Ba7yZVLbUSatrBfgtyIfQlbxAbURCyrKo6+vT2Y+zU/Iq19GqXfNqUWmmmmHBg== X-Received: by 2002:a2e:9c55:0:b0:2c5:d10:248f with SMTP id t21-20020a2e9c55000000b002c50d10248fmr1362032ljj.49.1697544311725; Tue, 17 Oct 2023 05:05:11 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:11 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 24/73] pinctrl: mediatek: moore: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:42 +0200 Message-Id: <20231017120431.68847-25-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/mediatek/pinctrl-moore.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/mediatek/pinctrl-moore.c b/drivers/pinctrl/med= iatek/pinctrl-moore.c index 889469c7ac26..dc41ffa31357 100644 --- a/drivers/pinctrl/mediatek/pinctrl-moore.c +++ b/drivers/pinctrl/mediatek/pinctrl-moore.c @@ -512,7 +512,7 @@ static void mtk_gpio_set(struct gpio_chip *chip, unsign= ed int gpio, int value) =20 static int mtk_gpio_direction_input(struct gpio_chip *chip, unsigned int g= pio) { - return pinctrl_gpio_direction_input(chip->base + gpio); + return pinctrl_gpio_direction_input_new(chip, gpio); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned int = gpio, @@ -520,7 +520,7 @@ static int mtk_gpio_direction_output(struct gpio_chip *= chip, unsigned int gpio, { mtk_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output(chip->base + gpio); + return pinctrl_gpio_direction_output_new(chip, gpio); } =20 static int mtk_gpio_to_irq(struct gpio_chip *chip, unsigned int offset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id F156FCDB474 for ; Tue, 17 Oct 2023 12:06:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343721AbjJQMGy (ORCPT ); Tue, 17 Oct 2023 08:06:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59088 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235009AbjJQMGN (ORCPT ); Tue, 17 Oct 2023 08:06:13 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2644210E4 for ; Tue, 17 Oct 2023 05:05:14 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-405361bba99so50469165e9.2 for ; Tue, 17 Oct 2023 05:05:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544312; x=1698149112; darn=vger.kernel.org; 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=HdnE9k6DVeHGrvZCSuP7SVSND1kB1XJeLK7GE1Az69U=; b=oXw1rqN4mcsSF8ydsyhFpLf1UecjcsglhSTaqP0kuglB7kZFYyvQburueo7QIAngz4 qTpmaLApW5y0FAQh1K+7mgRnmE0KKUVtDND8rcZOjIM87WWR1uvfHLGaRBtC+8Hlx4EF JP09f5Ykee2tWCzfkZldzrM16p6XpevEE3HG9RCHcP9Ou36Vfzyugq9ZdNU3+KoZdYwF IGc49wNDtHD0LFNNn3LkZzdyZuymC9/4jTBWabNqhEHLrMXwrWyIl3Oci2ROXIuRna+4 qQM305y2x8xi4FQugxPaRCHfWYeixth/RtVt5mdHSOZ3aa3XyfzeOdosGXCB0fF/OEc/ Cpsw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544312; x=1698149112; 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=HdnE9k6DVeHGrvZCSuP7SVSND1kB1XJeLK7GE1Az69U=; b=b808k4D3eLlJDhlpz9BXJFLcxfyUT/jCX2V88PvYgJ5dQvRuU2+I00mncEQAoZ0fDu KrVJ0yCvturpHWLgxktV1MUiFSV6gljqzvyQLIHdpilqLwbNQsl5VywcywpibJ3pBIq+ YDEY2sfIS2c8j3q1VfyIpyBzBcoDGJq48LyVfTSlUcBzoIbw7h4ctZQTpYaPmBbIaGaC fBbH8TYpb0JTTxE9z/2oa+tIAzwfNRqwCOnWlJyIVSK0uIBuHhG1DP9o0p5lF/Vl65mz 6nOUt6YxeY1kOB4X626R7cuHAwOrnu6dnUaIkxrcGWAGsuJxTwuaNMhyYot2/SooShu7 G/NA== X-Gm-Message-State: AOJu0Ywj+IhAj8Hsrj0A/ULpRBziwcjvuSgfI+Unbgt8ya82dN1WQKCP 3rlZKK+oyDPrwX3aa48pSKETbg== X-Google-Smtp-Source: AGHT+IGwJeUCVVtl0VXCv31bIhc4qf3kZ1e4jEHKPmsBw29Uj066LVCiRTpsAVFEJ6zxhf22EXGv5g== X-Received: by 2002:a05:600c:3590:b0:406:7074:301d with SMTP id p16-20020a05600c359000b004067074301dmr1622360wmq.11.1697544312505; Tue, 17 Oct 2023 05:05:12 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:12 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 25/73] pinctrl: mediatek: common: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:43 +0200 Message-Id: <20231017120431.68847-26-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c b/drivers/pinctr= l/mediatek/pinctrl-mtk-common.c index 74b15952b742..fc046415b567 100644 --- a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c +++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common.c @@ -811,14 +811,14 @@ static const struct pinmux_ops mtk_pmx_ops =3D { static int mtk_gpio_direction_input(struct gpio_chip *chip, unsigned offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { mtk_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int mtk_gpio_get_direction(struct gpio_chip *chip, unsigned offset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 32E63CDB483 for ; Tue, 17 Oct 2023 12:07:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343772AbjJQMG6 (ORCPT ); Tue, 17 Oct 2023 08:06:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60640 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235085AbjJQMGS (ORCPT ); Tue, 17 Oct 2023 08:06:18 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 44AF610F6 for ; Tue, 17 Oct 2023 05:05:15 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-4079ed65471so4276275e9.1 for ; Tue, 17 Oct 2023 05:05:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544313; x=1698149113; darn=vger.kernel.org; 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=BYro6G3w7HrOUdE8TTDPmtksHa63Nm7WFMk5y+Hqbus=; b=HO3cgG5HtWVNL/eHwjKF9OxvlSI3gRHsXFysHisKTvAg1Hl21pjrperPF6HxhojRUj tXZ0LIH/wA+uieRIeu7An13uU8WpbocMbhBHYDgzbMBZpn1nVRMM1dxvQALfihBpk0sy XZKz2vSftvDT1KkQbFqEm2+2ZhpBX7Oz4qEZKLUFAC6j4PeX15f4yIF0vIiLn5jMKLcp OiLrBjjZr9CCvTdQL5OiUnpV7UxQrq9ySBTzI93x3ooxPbOcNyODzf4LoA1Csgsd4w53 AsnBD6PtTD3m+zs/GwKznbCLQmF9QRDDN3qxG9CN9JCnsAuA6KG+kyMjOhuQFXAA1+mU lPSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544313; x=1698149113; 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=BYro6G3w7HrOUdE8TTDPmtksHa63Nm7WFMk5y+Hqbus=; b=ahcfu/pVQwdM/FhNdsWWMBKhlkrMXesrxkIhly32rqYOGs7v9khPBwoSYGcZwxqG9D eOXUkqTvBH2RYWy0g/g/saZN3C4sanRLbxhiP3WtsUmeDASdY4LQ9scOU1C41Vfn8wJx 2RDFU1MLPmFseQSMHRMSuSo88+spXSr9rmY293cqv7V0v5kH9IABMMre6PFFCQ2Surmv Y6yoWs2vCczBVoWXYsJCdwPZxCzfkcgpBY0VEePoqnsPnvhQqRNRnBbzbPd6ZDeHlr7L LKZUDMEL47Kk2UwzU/5/DQ6ktmPeVDbNRa2e+ggeLojO8GDtiyIQ0Bc8HkCmLM9hxmTO d6Gw== X-Gm-Message-State: AOJu0YwAcA66yc06tjbxf9m2Ato27MQlkgVPQkjD/p70HS+k1WtKAzb6 GJPmIbDQQHgOTibAuyt8JyyDPw== X-Google-Smtp-Source: AGHT+IGqgrFNJnX4083DaEGlzOWm4AX6euSW8yG2lHeltS1Z8qyJDpdDLodz8VIumOZY4JmbU+S6tQ== X-Received: by 2002:a05:600c:1c96:b0:407:7ea1:e99f with SMTP id k22-20020a05600c1c9600b004077ea1e99fmr1416956wms.17.1697544313282; Tue, 17 Oct 2023 05:05:13 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:12 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 26/73] pinctrl: mediatek: paris: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:44 +0200 Message-Id: <20231017120431.68847-27-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/mediatek/pinctrl-paris.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/mediatek/pinctrl-paris.c b/drivers/pinctrl/med= iatek/pinctrl-paris.c index b7cb5a1f1060..14b151aec2f9 100644 --- a/drivers/pinctrl/mediatek/pinctrl-paris.c +++ b/drivers/pinctrl/mediatek/pinctrl-paris.c @@ -916,7 +916,7 @@ static int mtk_gpio_direction_input(struct gpio_chip *c= hip, unsigned int gpio) if (gpio >=3D hw->soc->npins) return -EINVAL; =20 - return pinctrl_gpio_direction_input(chip->base + gpio); + return pinctrl_gpio_direction_input_new(chip, gpio); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned int = gpio, @@ -929,7 +929,7 @@ static int mtk_gpio_direction_output(struct gpio_chip *= chip, unsigned int gpio, =20 mtk_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output(chip->base + gpio); + return pinctrl_gpio_direction_output_new(chip, gpio); } =20 static int mtk_gpio_to_irq(struct gpio_chip *chip, unsigned int offset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2E067CDB474 for ; Tue, 17 Oct 2023 12:07:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343779AbjJQMHC (ORCPT ); Tue, 17 Oct 2023 08:07:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235030AbjJQMGZ (ORCPT ); Tue, 17 Oct 2023 08:06:25 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 157AB102 for ; Tue, 17 Oct 2023 05:05:17 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-4064867903cso62407485e9.2 for ; Tue, 17 Oct 2023 05:05:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544314; x=1698149114; darn=vger.kernel.org; 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=L71FhZFxQS/v+Kb2FZmLTi+Zct1vRjkWo7sxYZsb/pk=; b=OzWcgGNq9Oxgo6yJZAWnlQ6vMj5oNCtBRrN96cSd/P5R3mc6Uy/m4+JnbAJTpU4bJS hOOraKK+gd2alG7JczrPlLMsYt1GwFVTXXxCbVzLk989utgfI7vf/2t4QwiehxRyIvHf MLkpZrz0rAFCHaJ1r1MkQFb6oOMSk0uerIlF7bfJJYpeyAPRKOEAJs7SVPM+m7wmzvTw vSYlO6sKjfCf+gAZyTajgnEt7ysSEzp84/EJVpwpo3Nx88e5dnLWu5LPkHXcVPLyoDqX /0lbRh2ceStmfHvkOdtccGwmP6WfuWqXTMTUaOA24WYTNgRmjoRNS3QuNgB2e/205O7I zTzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544314; x=1698149114; 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=L71FhZFxQS/v+Kb2FZmLTi+Zct1vRjkWo7sxYZsb/pk=; b=ErvY6xTeeUOp+AiCrFDh+WdxhxyfIeKq/hK319rdqPO8NGiRlYhUGjsjdmT6UfXZ7Y QHgD3NSdv65X2g4KmQ89RWf2U0nPMlR5V6+IC2XA9h7oSzYzVbMo4rt+0p2Wi5U9fNvN oGPtZBzy6FYf1N/0ZJb1clPlI+ChzZVS+9tEu9QkkSrfpb3p2aoeOaeDLk02rXhQ6hMS K7LKeMArYm1EIpC+MvI6LMDhVfZKdo1vkoWWyrOp9V+J2xNbumLZIBd1RUDUaHzNaDGP MBghHuEiCDPywq1ZvrZGyTeVM5pgaWfV2Jn5rbJKRTQD834pk0/CXeO3YLK06ML+25gb bU2g== X-Gm-Message-State: AOJu0Yzr3I0s8MqrI/wWyJKejv9h0dytAb+0i10cy1Z34mJ9nHn8RHHy G6yJRXLRRHk+BiYF+a6Uh60Fww== X-Google-Smtp-Source: AGHT+IGyY0BhYJoi9GBHM2koiMY1E4AKDEZvAJalE0lYHdYx8MM0298X43yGetUqZJGFXD0K/KKLrw== X-Received: by 2002:a05:600c:450b:b0:405:359e:ee43 with SMTP id t11-20020a05600c450b00b00405359eee43mr1665215wmo.1.1697544313995; Tue, 17 Oct 2023 05:05:13 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:13 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 27/73] pinctrl: axp209: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:45 +0200 Message-Id: <20231017120431.68847-28-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-axp209.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp= 209.c index 9f5b3ab8e184..d7f081f1d1f6 100644 --- a/drivers/pinctrl/pinctrl-axp209.c +++ b/drivers/pinctrl/pinctrl-axp209.c @@ -126,7 +126,7 @@ static int axp20x_gpio_get_reg(unsigned int offset) =20 static int axp20x_gpio_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int axp20x_gpio_get(struct gpio_chip *chip, unsigned int offset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7D9C7CDB474 for ; Tue, 17 Oct 2023 12:07:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234978AbjJQMHJ (ORCPT ); Tue, 17 Oct 2023 08:07:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60722 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234975AbjJQMG0 (ORCPT ); Tue, 17 Oct 2023 08:06:26 -0400 Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8FB67170F for ; Tue, 17 Oct 2023 05:05:18 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-406609df1a6so53621185e9.3 for ; Tue, 17 Oct 2023 05:05:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544315; x=1698149115; darn=vger.kernel.org; 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=gdciYkeI9ojIVFf6NUkn/u7//A2Bey8sZm2LXyWrQBM=; b=OcLcF0XKyCGVyiccFqPnH9QSZRvSuYSlI+2LQhQZLu3QUZ3JnAIF/ZvgoJw3ZmWSzV GBsciGiqASk0rZgv8yQg1pKQCeMERZgc3gjtIhBoxi39ihGnm57ZXUVKmeWyq2Eu0d07 6EMEVCLUk/6br29JIaUOOWmAs3r6alkXy2+XjTyF8Hw5xpOBZ5SMHoNFBHDWrZYfDu41 dvA+bU35NAb57cwphgKduCmmUq9Lr55ce2yGzcpmfJ2CzY5Z88xaIgYTCuBHMbE3k+ML o9KKeexf/KzxsfJHF9e0XAbP9yC7P+t7uI6dMLuCkMtXi7mjJ6gh1VT+u0CNnabPcZQX QIaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544315; x=1698149115; 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=gdciYkeI9ojIVFf6NUkn/u7//A2Bey8sZm2LXyWrQBM=; b=R3N8MN65xHjubSLisZ7WvXnlogb6aSysBt137dBu1sjKvlcojZ5qXOL3zudr48wIdO dsNXfEQmjmr4USOqbl5R5HgQrvtRR1czWJwrJsZ31xao/iMUl/gH0HBdo5e/J3WE2gEF w4tj3ano/PJV1Pzg/yLXuRbIuCdAlWvGtlrPehyet7QzN/hlm59f8j1qoARYzCDHQxZg 13BNvIBmlECrtiRq2DS3tcs9sUc/u5amJodXoQ3IIvm95Tn0R8LzmurhOjWJJ7UluG2n 3dogGcnF0LSthqcQHfje9CYDrND30FdDF3+XY/OtuIl/oAnL0PRUrb08pSpblEEQKkCJ +8AQ== X-Gm-Message-State: AOJu0Yx5GisStGYIcVfrZHn9rA4z4/PgwY4POGaN7KDhy/pCEJf5Cyr+ eC9crllATgaUz7QkC2eQe0nhVptIZ8vmIkBOGXU= X-Google-Smtp-Source: AGHT+IFSVq5JoWAceD6FGW/0GO/cXkV8dwhzAtwN4BQDG2RryN6S73PsaBbeb7ILo9VDKOgp136/lg== X-Received: by 2002:a05:600c:4f95:b0:402:f536:2d3e with SMTP id n21-20020a05600c4f9500b00402f5362d3emr1801117wmq.14.1697544315055; Tue, 17 Oct 2023 05:05:15 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:14 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 28/73] pinctrl: vt8500: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:46 +0200 Message-Id: <20231017120431.68847-29-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/vt8500/pinctrl-wmt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/vt8500/pinctrl-wmt.c b/drivers/pinctrl/vt8500/= pinctrl-wmt.c index 6fac30de1c6a..1a313295611e 100644 --- a/drivers/pinctrl/vt8500/pinctrl-wmt.c +++ b/drivers/pinctrl/vt8500/pinctrl-wmt.c @@ -528,14 +528,14 @@ static void wmt_gpio_set_value(struct gpio_chip *chip= , unsigned offset, =20 static int wmt_gpio_direction_input(struct gpio_chip *chip, unsigned offse= t) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int wmt_gpio_direction_output(struct gpio_chip *chip, unsigned offs= et, int value) { wmt_gpio_set_value(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static const struct gpio_chip wmt_gpio_chip =3D { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8172ECDB474 for ; Tue, 17 Oct 2023 12:07:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235008AbjJQMHN (ORCPT ); Tue, 17 Oct 2023 08:07:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60748 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343569AbjJQMG1 (ORCPT ); Tue, 17 Oct 2023 08:06:27 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9329F1733 for ; Tue, 17 Oct 2023 05:05:21 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-4060b623e64so35182615e9.0 for ; Tue, 17 Oct 2023 05:05:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544316; x=1698149116; darn=vger.kernel.org; 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=iTV/yldDdNeFa7KR560LkbzuRdncwWStAsZOIrIjz5U=; b=va1M7kmCWEvSEgK4tGclH4CB57MDbCIwjECHGPYA+7WGBS+zk+tl1XNx3B5iAbSO/z /Yikn4MP6VO+qU7miBO0zbOMOxWLAMAiOO0elMa0BrpAxwAcAThfpIp9HUIPNBPZhPrA Wb+KhAjh4ItYM0AaCC4D/DrnnhKAWHcSL6+Pg148wnet2B+HyaWBFeakCFYO+jXop0mv lGplCLqRb51/Mu6G4tfpi6kmW18M0V+tbgVDcMhK3SXOWAxf7BRDSEz1BdtRX0d2oSgV 2x9wL9OnxJK+gkV+URilXCRFZj7fFAJWdKiUEhj2kfQq/fFheDnfYBnDvcpgWKxcTlT0 MtuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544316; x=1698149116; 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=iTV/yldDdNeFa7KR560LkbzuRdncwWStAsZOIrIjz5U=; b=GFCahWvGGHiQgz/0MEmvaKbtNfRA7wkW2TtBy1UXYTx0bQ4L2a7y8wuYATSA09VI5i 2+ewD/QJZBrlfPSSoRUqhRvMzHLuhfTJ2hjjCjwc4mRiYRbWB5jggkjcH5XFv429977S RbSwePzrhQxwVB0+vBmhJBnfWMTCw6H8uZ1uqtviF1eGlE64Ze1xjcAQrUN0wGq7aKjp MobU+2eyBWTX6/fOYRNG63vu2GnL8GOv+nRJuqKIdzlPSJcJ77D6zrpH3UQxZoqIYh3g ArHg+9EcQ+2pwkKh3gq4XsKJRS3oYl7d4Q964KkxFPnXiyYjyWxZecCwOfCjCTgUjGnA Bs5w== X-Gm-Message-State: AOJu0YwYIeJMExxuF8oeTR1YnRmt8nqsxrcSgkR8ZJRnPw7Jcff1e/F9 uMHaxCEVO+ILWfsNmWtBU88Gi2jsrsXEOjyynfs= X-Google-Smtp-Source: AGHT+IFQLVUXIThEYFlcpVZui9z0ZEhY3hev5QDVIobWDexRbxXUzXAcmLC/qIsZmEiGqYPetepnxw== X-Received: by 2002:a05:600c:4e09:b0:401:b425:2414 with SMTP id b9-20020a05600c4e0900b00401b4252414mr1645323wmq.18.1697544315935; Tue, 17 Oct 2023 05:05:15 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:15 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andy Shevchenko Subject: [PATCH v3 29/73] pinctrl: cy8c95x0: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:47 +0200 Message-Id: <20231017120431.68847-30-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-cy8c95x0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-c= y8c95x0.c index fae80b52a6fc..8c6006353515 100644 --- a/drivers/pinctrl/pinctrl-cy8c95x0.c +++ b/drivers/pinctrl/pinctrl-cy8c95x0.c @@ -554,7 +554,7 @@ static int cy8c95x0_read_regs_mask(struct cy8c95x0_pinc= trl *chip, int reg, =20 static int cy8c95x0_gpio_direction_input(struct gpio_chip *gc, unsigned in= t off) { - return pinctrl_gpio_direction_input(gc->base + off); + return pinctrl_gpio_direction_input_new(gc, off); } =20 static int cy8c95x0_gpio_direction_output(struct gpio_chip *gc, @@ -571,7 +571,7 @@ static int cy8c95x0_gpio_direction_output(struct gpio_c= hip *gc, if (ret) return ret; =20 - return pinctrl_gpio_direction_output(gc->base + off); + return pinctrl_gpio_direction_output_new(gc, off); } =20 static int cy8c95x0_gpio_get_value(struct gpio_chip *gc, unsigned int off) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6A5DCCDB474 for ; Tue, 17 Oct 2023 12:21:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235136AbjJQMVp (ORCPT ); Tue, 17 Oct 2023 08:21:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235143AbjJQMV0 (ORCPT ); Tue, 17 Oct 2023 08:21:26 -0400 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 625B01980 for ; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) Received: by mail-lf1-x132.google.com with SMTP id 2adb3069b0e04-50435a9f800so7041072e87.2 for ; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544317; x=1698149117; darn=vger.kernel.org; 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=647iAq3iBI+ayvQVhhErvz6gPvZUyIZ/SN8sLbjPkvs=; b=PrZmBJnCFQbSaYmMWwaI9AeJY7fxDFfdHwF8NX26R3vDo8OZTWe6gqPdO2qh08/jZ/ oluVvqojNnMi2o3WWdzcdmuL01mJtpV1hZ/UK9wF1ASk5ArgzKkBdyaGxciVRWD5dZjv cMneXcZqDp16IrEPMn4qpP+a2KYAUB6hpzL1w1ERdYstYMhiUeTn8OQJaiES7V1QnNBC tFsSlY8jHFn3QQo0Us+RF0unQgV0s++m4pAnQakjnrJ8Gx/2cVsEkXI/uO4TNxpP6BCa V5n5CTe8ObXNlIl73izYEe22IdFNshuPjjvD4IruAYc0z4xL2q5Wh5x6vtJGwBv54gOF kHfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544317; x=1698149117; 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=647iAq3iBI+ayvQVhhErvz6gPvZUyIZ/SN8sLbjPkvs=; b=anAMvrDQIiZRxVkbY6wv9+uGhSUWiPJZsjMfLO0MQX7OYtP6Q5KMITPVp9gbZov+Bf Pl3K5switeGlBIITNX12ln4QSrmGQpsiDg1R+mTttL0GIk0l5DUxk8un1HK9S1IDN6El 6l/K7fDpDRc5T+9V+hAOo7HHiODl27M+deVgOZlrfo3h1wmyaYBUUKN85lBQUdRSsGka hJ2UuQo72R9vdERa2vSqJHzX2nWY2aE2ilf0O3/tde7vfHxGvJOZgOFpIG3KhS1Pf+fB DOAFTNSDopPdRROeYEnWiaqiuYXhbJhSioghwPEBKvoIxGIXbKDyEGezhB6s+N5w9+Jp de0g== X-Gm-Message-State: AOJu0YyoXvChKlq3TALOOvma9nBXEWjODFPhyVYeWPI86eDvkWG8uBPb +fEiPkhDgqsr2hB4nYqz0NYRZg== X-Google-Smtp-Source: AGHT+IGNXONS2yCN4qhnOennX9MnXyI6ctcbHek+iYyOS02Bqbyc/A8eFqvuzL3jPIeOQy2QLGcD1w== X-Received: by 2002:ac2:5585:0:b0:507:9608:4a87 with SMTP id v5-20020ac25585000000b0050796084a87mr1573902lfg.56.1697544316763; Tue, 17 Oct 2023 05:05:16 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:16 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 30/73] pinctrl: as3722: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:48 +0200 Message-Id: <20231017120431.68847-31-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-as3722.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-as3722.c b/drivers/pinctrl/pinctrl-as3= 722.c index 84b47a6cc3a6..205937f7f9a1 100644 --- a/drivers/pinctrl/pinctrl-as3722.c +++ b/drivers/pinctrl/pinctrl-as3722.c @@ -502,14 +502,14 @@ static void as3722_gpio_set(struct gpio_chip *chip, u= nsigned offset, =20 static int as3722_gpio_direction_input(struct gpio_chip *chip, unsigned of= fset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int as3722_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { as3722_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int as3722_gpio_to_irq(struct gpio_chip *chip, unsigned offset) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E526CCDB474 for ; Tue, 17 Oct 2023 12:23:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230440AbjJQMXU (ORCPT ); Tue, 17 Oct 2023 08:23:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48572 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235263AbjJQMXB (ORCPT ); Tue, 17 Oct 2023 08:23:01 -0400 Received: from mail-lj1-x232.google.com (mail-lj1-x232.google.com [IPv6:2a00:1450:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5B1A1988 for ; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) Received: by mail-lj1-x232.google.com with SMTP id 38308e7fff4ca-2c5087d19a6so52217381fa.0 for ; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544318; x=1698149118; darn=vger.kernel.org; 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=gwciMDEJmwkjhMDgP1JPMADTRBiS8hEPWAh7DlNBT2c=; b=KJ6TxornkPx4ML8GSGSmxf6o4mZYPwV+vEtSFYpOPuaycfqCm5CI2ExoIV5MYzeBCb Ig80DTGZcqgLjKsYJ/12/UejLdQtw5zzUNabg4CYbc74qzr3G8iBIQOH+SgwlFTWYDGE jxEH50Npl6ZYkQVP3e25uXrUqq1K9tw/rcCo4W53WTSqtgDm5mKdZmRU3+0iqaVAleCa bWxWScKEPvqrU3fr8WSgbLejdRkzjg48APEkDrFZ/2NIexHJVHQvRnbvEACiYomo6u5P KUsEQDLTi+ZvBQnSL3t0wVPDQGeZu9EsAJRSIjDHBBtEwQcHE4obYjpSGvmjrVQAKMqK WJIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544318; x=1698149118; 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=gwciMDEJmwkjhMDgP1JPMADTRBiS8hEPWAh7DlNBT2c=; b=MvMka2nFck+ssYZkeMfbx9dFnBh+ioOgOygMLG9evC8Uqs0ohoI1w7m0s6BcYGJXsZ KR9fiV3F2/vICuurQxSXt6TqGjGTSJuGj7jJ0D4FIjhT8P/5nwz2b6Rqn5MXTTfJlG5g 6+54kOmB7rbNnm8R8UbcsSOfNXiRsE2wLnIn07t3gLKEClUziDHOV2VJAAgA2P5afGNz ReFZuFXHhVbdLtkKEHaRuv4KmIGxu5zO/ktoIv3i4PHn/T8qNsDBxJA+6LRi5YRi7Ngz ZksZ3S3WgIeUaRNF/Enycm28rMhnOII2zBFaFyyGFHXhd3mmUQluM1kCNuDt3uGsFqGa s8iQ== X-Gm-Message-State: AOJu0YwaBcb28YLxKp0tSpnwvXK8komfDWS9WGYX6krfg5f246ZfuMxB /EvIE7uR8+lGCDoSKi5LZZC6yA== X-Google-Smtp-Source: AGHT+IHhzZONAYHNx3gqc4pIA0lEbPEqPBfq0qcFjG7SYfmr12HY78Q6mpZGLRdrOVOx+JChdGnpZw== X-Received: by 2002:a2e:9902:0:b0:2b9:e6a0:5c3a with SMTP id v2-20020a2e9902000000b002b9e6a05c3amr1655865lji.48.1697544318317; Tue, 17 Oct 2023 05:05:18 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:17 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 31/73] pinctrl: ingenic: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:49 +0200 Message-Id: <20231017120431.68847-32-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-ingenic.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/drivers/pinctrl/pinctrl-ingenic.c b/drivers/pinctrl/pinctrl-in= genic.c index 2f220a47b749..5072fb907193 100644 --- a/drivers/pinctrl/pinctrl-ingenic.c +++ b/drivers/pinctrl/pinctrl-ingenic.c @@ -133,6 +133,8 @@ struct ingenic_pinctrl { struct pinctrl_pin_desc *pdesc; =20 const struct ingenic_chip_info *info; + + struct gpio_chip *gc; }; =20 struct ingenic_gpio_chip { @@ -3561,14 +3563,14 @@ static int ingenic_gpio_get(struct gpio_chip *gc, u= nsigned int offset) static int ingenic_gpio_direction_input(struct gpio_chip *gc, unsigned int offset) { - return pinctrl_gpio_direction_input(gc->base + offset); + return pinctrl_gpio_direction_input_new(gc, offset); } =20 static int ingenic_gpio_direction_output(struct gpio_chip *gc, unsigned int offset, int value) { ingenic_gpio_set(gc, offset, value); - return pinctrl_gpio_direction_output(gc->base + offset); + return pinctrl_gpio_direction_output_new(gc, offset); } =20 static inline void ingenic_config_pin(struct ingenic_pinctrl *jzpc, @@ -4052,7 +4054,8 @@ static int ingenic_pinconf_set(struct pinctrl_dev *pc= tldev, unsigned int pin, break; =20 case PIN_CONFIG_OUTPUT: - ret =3D pinctrl_gpio_direction_output(pin); + ret =3D pinctrl_gpio_direction_output_new(jzpc->gc, + pin - jzpc->gc->base); if (ret) return ret; =20 @@ -4172,6 +4175,8 @@ static int __init ingenic_gpio_probe(struct ingenic_p= inctrl *jzpc, if (!jzgc) return -ENOMEM; =20 + jzpc->gc =3D &jzgc->gc; + jzgc->jzpc =3D jzpc; jzgc->reg_base =3D bank * jzpc->info->reg_offset; =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 43532CDB482 for ; Tue, 17 Oct 2023 12:07:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234969AbjJQMH6 (ORCPT ); Tue, 17 Oct 2023 08:07:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343759AbjJQMHL (ORCPT ); Tue, 17 Oct 2023 08:07:11 -0400 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B6121992 for ; Tue, 17 Oct 2023 05:05:23 -0700 (PDT) Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-407da05f05aso3973705e9.3 for ; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544319; x=1698149119; darn=vger.kernel.org; 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=t4vMZiIUWAcFjSUyJWdkZqLSvd59iWFi9llO7wZj/o0=; b=QbCX45hNaLu6XKChuiuAhVoFLWZhUxIjoxLGFbcR2Qphvsl9w2WgkfLD1zItmatcJV HfPrLAP8DUqOLcJpxyWauMuzSNBZrWTSJ++x9vBQ1tUKAAW3zAXNWOnLRBETcxTcOY+w C1wiMAPtKbonTdI7qX5wBQcNXZtCF6sC54At9zqV8/DfIr+n8TnG9jCmZLvlok8/g9L0 rqiLpu+PtPwoRbTz9h8Fxh0ibR4OOKxxA381tDnmgSP9jOqJ73nYf7RXVjd0J/LKOv5l yUpduYR8vb26/rqaoo0ZkvY1IC6cgp7Q80zJzBGfJ/7HPddSak3PYXzkCQhKuXHFqfV0 89ng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544319; x=1698149119; 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=t4vMZiIUWAcFjSUyJWdkZqLSvd59iWFi9llO7wZj/o0=; b=asXxusWuNEwpAuTzP/nwNh5pr/8TP/KaegnAxEp4TzN7bikfVbsU0tbMrvXywIKtFv 1qCIWtr7xrxovFak6SsfvZosNbBJWur0i3msYy+CK1CUalHKt5TNmOxLBhLuOi60Aylw zWHkSk3xKEIbzbBEo6orOKKK0z6JTSli7Dc6EZyK4TJpBIeZOLOtMBCWXgxXqJ2eQZOv ayusTU5bUTenZHo9G3MMFjxBuDxSckbZmgVMqNUnsuRglue8Tco7lmVLjyh5iN1QsVgj TbxuOFY1AcRMO0cvWCE6f7BF65KeZML4+TgwyIfMjwVCrqz3dn2bnUQkJgUbA2Zgue8s 6bdQ== X-Gm-Message-State: AOJu0YyXf8KMrDzxXhctuEoufnRLnoHvZGbpp81Va7irOuq711K+LmEe Oa+af2Wi4T6v9HCUJzs1r+r6DiGWUQtDRGlMR4M= X-Google-Smtp-Source: AGHT+IF3y2rQr3XG8SJodLdmImsnXG0VynEltv/HXiA/nxoiiFZ9fjfV55isMP6Fs66+HofYAUOeuA== X-Received: by 2002:a05:600c:818:b0:407:7e5f:ffac with SMTP id k24-20020a05600c081800b004077e5fffacmr1517642wmp.41.1697544319212; Tue, 17 Oct 2023 05:05:19 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:18 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andy Shevchenko , Mika Westerberg Subject: [PATCH v3 32/73] pinctrl: intel: cherryview: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:50 +0200 Message-Id: <20231017120431.68847-33-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Mika Westerberg Acked-by: Linus Walleij --- drivers/pinctrl/intel/pinctrl-cherryview.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-cherryview.c b/drivers/pinctrl/i= ntel/pinctrl-cherryview.c index b1d8f6136f99..f806b7ce086b 100644 --- a/drivers/pinctrl/intel/pinctrl-cherryview.c +++ b/drivers/pinctrl/intel/pinctrl-cherryview.c @@ -1148,14 +1148,14 @@ static int chv_gpio_get_direction(struct gpio_chip = *chip, unsigned int offset) =20 static int chv_gpio_direction_input(struct gpio_chip *chip, unsigned int o= ffset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int chv_gpio_direction_output(struct gpio_chip *chip, unsigned int = offset, int value) { chv_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static const struct gpio_chip chv_gpio_chip =3D { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 49E5CCDB482 for ; Tue, 17 Oct 2023 12:07:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343574AbjJQMHc (ORCPT ); Tue, 17 Oct 2023 08:07:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343561AbjJQMGr (ORCPT ); Tue, 17 Oct 2023 08:06:47 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AFCE9199E for ; Tue, 17 Oct 2023 05:05:24 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-40684f53d11so62516505e9.1 for ; Tue, 17 Oct 2023 05:05:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544320; x=1698149120; darn=vger.kernel.org; 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=/mhvT3LGVBR3ArbIn65CBOCRrTrRmKVKXHcP7Km8akM=; b=FAxRI6s4n6cJU5UiEJKgX7H14xb5ird95C6Jl0iFf1+rI0yUv6c68bKvW6+AG8UCFY z1l09HcYjUNXjJjwiGBj4/steMwp4lKIPAiuvqMs4KkmYFCc2aoDhsfVB7liSm5hX1rD LjxrQWXa2jGndYNpjRjXjXItpBCRH8Ilw9LTCJyrTXpESIhGRqtzIBoPv473wLBdAjAr EJkXhT31E3p7+VNCv6/Qs/QeuafSZf6JhzhmH7V7JHwSYJ3bquuAyd5pnO4w4Y0hdScQ RGrkCnunKWM3e8pOVz66HhoTtstTrQxFXj/PoJdK6wI+sYwwGaxyCU7IstcgPArGihSp ufjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544320; x=1698149120; 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=/mhvT3LGVBR3ArbIn65CBOCRrTrRmKVKXHcP7Km8akM=; b=MbKXUmZAiVhHnIa7j1+N16fwq5p0O4qOH4plMi3JcWyGXmBRKNfLLOnbFQH6wFBHRd r2wLsbI/U3xi77vGqOoBzdPGinmlpfQFJKwjhbB3y0x5CKlSVXmJAcA3vgt2sV04vLhn O3mpJPLpaOe/Y1tmmYx4yysOf9NtMANOsDdy9mQgT8Fgu0QBg9JEV0nukZUnTftTSCTO vqP6CMWR1Ya5i65AYcM0JEJzjz8p5l9ehIyz+VdnFLrxFz0u69shIqw21sKu2f1z8XUR i8P39MSqcaGILp4xGKcWa8f+vDa+8Iz1Tmro0f4nIg7v5fKifi7hbHtMJ7GynXwTn8GV FYMQ== X-Gm-Message-State: AOJu0YzbNmc8v5aLNgspmFs5FCqH7GgNqWwX881/UA+tgdPKZMNJbwcp RW3VoqlRfzAe6tDf5INc5vANfw== X-Google-Smtp-Source: AGHT+IErM7HnvqvaqMkWd8NEyyIV6oAV292EvRRFdV8DIMa3hBhS+ET4hre3xImM2+EUmufX/Y58fg== X-Received: by 2002:a05:600c:5490:b0:3f9:b244:c294 with SMTP id iv16-20020a05600c549000b003f9b244c294mr1727964wmb.35.1697544320063; Tue, 17 Oct 2023 05:05:20 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:19 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andy Shevchenko , Mika Westerberg Subject: [PATCH v3 33/73] pinctrl: intel: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:51 +0200 Message-Id: <20231017120431.68847-34-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Mika Westerberg Acked-by: Linus Walleij --- drivers/pinctrl/intel/pinctrl-intel.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-intel.c b/drivers/pinctrl/intel/= pinctrl-intel.c index 9731a3acb23c..f403eb78f355 100644 --- a/drivers/pinctrl/intel/pinctrl-intel.c +++ b/drivers/pinctrl/intel/pinctrl-intel.c @@ -992,14 +992,14 @@ static int intel_gpio_get_direction(struct gpio_chip = *chip, unsigned int offset) =20 static int intel_gpio_direction_input(struct gpio_chip *chip, unsigned int= offset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int intel_gpio_direction_output(struct gpio_chip *chip, unsigned in= t offset, int value) { intel_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static const struct gpio_chip intel_gpio_chip =3D { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C8420CDB482 for ; Tue, 17 Oct 2023 12:07:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343560AbjJQMHZ (ORCPT ); Tue, 17 Oct 2023 08:07:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48710 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343504AbjJQMGo (ORCPT ); Tue, 17 Oct 2023 08:06:44 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D75E19B2 for ; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-4079ed65471so4277315e9.1 for ; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544321; x=1698149121; darn=vger.kernel.org; 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=IZbQcNg3B/LU86gXN0G+aZQrL0mShPNyFWtL4aswWFs=; b=0wJzVaaGbXiIWzduFcHWPdUwaQ4zl9zp7gYqSW58RdmXX8Bh+z9nWxA8qVKxIZnFpn hZ8utH+XJLBLEiEuPoOGt/y4N+D6AA2gq/bPq65OHBCw745CtYCFzsdVbUdBFCHDibVH wFbxZXPauT50ukx0BkAu5S/Xtd9G3shtqHCKEbkyWyHMyl/yT+W2BHvLpaynDkqGeHbJ GQ1+MiErYYLFte505KQ25B406n1uvNVGvAEd4WATKbXeMm8ZVuP5Ioj7lCPPMlX02Qxs PWxep3iKI5sDpoG6MXXz2Nfxvx7PsprwxF4JWz3GoTAywMjYAnTeVDRfCgldtcs6ZiHs 7lPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544321; x=1698149121; 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=IZbQcNg3B/LU86gXN0G+aZQrL0mShPNyFWtL4aswWFs=; b=m03s180TTArhKn/vJfTuP9CCcnJCMKG7Vb8NJEfOroaJdsHKqZX2r9z+SgtT18qXeh Lc3p8UMUOYje5MEJV+z6gqs/9k+Da35xDy8cIpWw3RmluV4XITv06h/VHPcd5VQWJNke aJJvznMWumMyycNamkd7/azzpTaCw/TlSSFMPKtBdEGU/NAxRhiQ0YFM8o2n2bb+//cM 6TJN9FG7AH6RZu8LDIPdK2nTpbBlmYfIywPvpuIyO2MwKjlf2tLrNRCIGLsvnDGIvywz GCAw9mgoY4ZZNVEweCrPPAHlK2pSL7cXhWcP0KandW2uiPz2vJGrpetrY5j3ayRsQcJ5 9x3g== X-Gm-Message-State: AOJu0YzfAWGM+QwVqPk7NqyVQQhfFRSLtCHQKMOFiAUt74hiasJdJX2n GEiabJMukgcNQiZxJLWz4imH8Q== X-Google-Smtp-Source: AGHT+IEGqhje/Lg4Q9uWy5d7TptwFdHZ6a1KmpZGQ6Lm5urjoTanWnJa92JWj+6WVwM4Gk+L1e0kLw== X-Received: by 2002:a05:600c:1c26:b0:402:f501:447c with SMTP id j38-20020a05600c1c2600b00402f501447cmr1604758wms.0.1697544320913; Tue, 17 Oct 2023 05:05:20 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:20 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Andy Shevchenko , Mika Westerberg Subject: [PATCH v3 34/73] pinctrl: intel: lynxpoint: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:52 +0200 Message-Id: <20231017120431.68847-35-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Mika Westerberg Acked-by: Linus Walleij --- drivers/pinctrl/intel/pinctrl-lynxpoint.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-lynxpoint.c b/drivers/pinctrl/in= tel/pinctrl-lynxpoint.c index d7bc9ef29fcc..91d228fead45 100644 --- a/drivers/pinctrl/intel/pinctrl-lynxpoint.c +++ b/drivers/pinctrl/intel/pinctrl-lynxpoint.c @@ -541,7 +541,7 @@ static void lp_gpio_set(struct gpio_chip *chip, unsigne= d int offset, int value) =20 static int lp_gpio_direction_input(struct gpio_chip *chip, unsigned int of= fset) { - return pinctrl_gpio_direction_input(chip->base + offset); + return pinctrl_gpio_direction_input_new(chip, offset); } =20 static int lp_gpio_direction_output(struct gpio_chip *chip, unsigned int o= ffset, @@ -549,7 +549,7 @@ static int lp_gpio_direction_output(struct gpio_chip *c= hip, unsigned int offset, { lp_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } =20 static int lp_gpio_get_direction(struct gpio_chip *chip, unsigned int offs= et) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 40128CDB474 for ; Tue, 17 Oct 2023 12:08:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343774AbjJQMII (ORCPT ); Tue, 17 Oct 2023 08:08:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50874 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235030AbjJQMHV (ORCPT ); Tue, 17 Oct 2023 08:07:21 -0400 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF77E19BB for ; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-4064867903cso62408435e9.2 for ; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544321; x=1698149121; darn=vger.kernel.org; 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=yEGizAbOxMwHBeRhJGcb8ss//xXj+RtWLOdU8JMZ+S4=; b=GIUDjfOeExe7e8WYs8tVMrgzRTUUx5dBVFxo6ksvEFa3/ohDpIyDJuQYP6xjFqki4U 4Cs8s7K4XaZb7vyUsJ5hrW0g1y9spP/wgvFxTaFH+TGFsVP7fkQ75xQBBT/y/86O/Yr3 boZ5ufFXIgKDgos+NOjZDJQlulU4UWmyNtxpXDeHHJkLTGUwy1OcwlGfwlN1eBGyAN1D IZeUI019B6iBhBV2jCdlcb8i53g2zVdNqA8R9FVhkFXfByhjlNQUGi8m7pRrCeant/fy DpEhjTeNGEjoG2un4xmjtMFanCq8nWM+HHpz/I+2QN2Y3BVvf73qPZg7zQr5Tw+jD2qG l/1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544321; x=1698149121; 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=yEGizAbOxMwHBeRhJGcb8ss//xXj+RtWLOdU8JMZ+S4=; b=Eq6KchUt8CetwCezUOgkv5zldFoH8tevGg7on+92Gzbr9XQMQUxH+nEHMHj8yJyEuX 2On/jFRhsp7SNfWV9E2BqT21IlXGzG6rkKg/0I1GNT6pc011K3DLb6bRh6+/OmAESX47 zh9kdAo5WvOzCdG40TTijn72MBKv6OSbqlPc5O/mel9p+iTr70RHB0TivJjo78On2zl1 Nfyo+P18MFW6iF3vypwXTCjuGA50+dxlP/iFmKFFLXKgTtTac/IHOGxpCpDrfgO+nBXH +OH4fxhqPUrP7ZZQaQnQk02oAtgVCquG6lWlYs14otKwzckm6ySPVx/Ez0j/phEnUmvd X8Qg== X-Gm-Message-State: AOJu0Yy8ljC8VsdCpChYloBqrl6wAYGiYIn/7AGfHF4NZBiYfM5ifN7q DWqAY3DV+xVuS+ZGr4vK9ZUeHg== X-Google-Smtp-Source: AGHT+IFIOngxq1pIAToZEwbs7J6cyGu+pyUOwiSkrMvmFdYAHXIOcaxr312ZZreBXjxOFPU3xWKx8Q== X-Received: by 2002:a05:600c:4fc8:b0:406:53ab:a9af with SMTP id o8-20020a05600c4fc800b0040653aba9afmr1615188wmq.10.1697544321692; Tue, 17 Oct 2023 05:05:21 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:21 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski , Patrice Chotard Subject: [PATCH v3 35/73] pinctrl: st: use new pinctrl GPIO helpers Date: Tue, 17 Oct 2023 14:03:53 +0200 Message-Id: <20231017120431.68847-36-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Replace the pinctrl helpers taking the global GPIO number as argument with the improved variants that instead take a pointer to the GPIO chip and the controller-relative offset. Signed-off-by: Bartosz Golaszewski Reviewed-by: Patrice Chotard Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-st.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c index c1f36b164ea5..ec763572ab3e 100644 --- a/drivers/pinctrl/pinctrl-st.c +++ b/drivers/pinctrl/pinctrl-st.c @@ -719,7 +719,7 @@ static void st_gpio_set(struct gpio_chip *chip, unsigne= d offset, int value) =20 static int st_gpio_direction_input(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_direction_input(chip->base + offset); + pinctrl_gpio_direction_input_new(chip, offset); =20 return 0; } @@ -730,7 +730,7 @@ static int st_gpio_direction_output(struct gpio_chip *c= hip, struct st_gpio_bank *bank =3D gpiochip_get_data(chip); =20 __st_gpio_set(bank, offset, value); - pinctrl_gpio_direction_output(chip->base + offset); + pinctrl_gpio_direction_output_new(chip, offset); =20 return 0; } --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 426D8CDB474 for ; Tue, 17 Oct 2023 12:22:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235061AbjJQMWa (ORCPT ); Tue, 17 Oct 2023 08:22:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49048 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235279AbjJQMWS (ORCPT ); Tue, 17 Oct 2023 08:22:18 -0400 Received: from mail-lj1-x231.google.com (mail-lj1-x231.google.com [IPv6:2a00:1450:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 93BD31BC5 for ; Tue, 17 Oct 2023 05:05:26 -0700 (PDT) Received: by mail-lj1-x231.google.com with SMTP id 38308e7fff4ca-2c50d1b9f22so43149301fa.0 for ; Tue, 17 Oct 2023 05:05:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544323; x=1698149123; darn=vger.kernel.org; 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=lpqrGhJK+18/r5lO164Y1VLFbc+qN04GBTg0zj9N4Wc=; b=eaCeUgsiAVd0h+9h/QR0D3qmJDOm5OzjdE3X/10qZdUJrrmmY6FU0z9TP/ItgK0fN1 2ooDuq/KyN95l+tkWvqBJ9CvwQBj7nJRvrvZ6EIXRWzGap49SQmCyrOJaSvZRRqVE3a9 gnG8KDL5E4++6Y81c6lYiEDE6Cg8xBUi6i+NMBS0yGF3u9hr6SOAtBqF8IrIsPBU8phd r0qEZQBN9yI5lIOb98q5Zdh67we44p+Vt+U4CG6F+8y71CE6zXdE0gfE8AR67HdUjiBT iG25JL1RKGYIkuY4EP+MKXr1bTOyGhzN/o2X7oTbeMPacrhUULlMTQ5ZmvMcPoiaUtYL JVUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544323; x=1698149123; 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=lpqrGhJK+18/r5lO164Y1VLFbc+qN04GBTg0zj9N4Wc=; b=miNnv27cXD5aNUugYcftw+QXjNcd6KnFE/Q191PMsAtxK8zYuMsvw/XDmCeq1y75oO pPjgfoYrhS0ibhqaA0MIjdnDnhlxxA3wAmCXosdS2oeCumpHuXYKEovdWGvushmXgle7 2uCZe5/QcP3CKCl0Sw3iDT4i/bMx+wQCN6GcGMBsoCz607vHYlpP9/0MhLCS9SJmzlwr d45mV0tFxvlieGfunZJTieIrfv07OV71YSgpZI7pOtqdTrlHkAplGzEWKm0y2d+N3+lS pfpe6Md51Rf/bHx5yY3gc+k/V7eT/EvBksFER6Dyp1QjpP+9PmLzc3J+LZ/QuPKdceUG 0hXQ== X-Gm-Message-State: AOJu0YwytFFcH16e6afDkcp8BxCIl+hH3gBmL8Z7r2KnC1cBAwEsf2uS 72ewk1K9+BvfxAEOOFcBbdJFHWQT45Wu0U63Kqw= X-Google-Smtp-Source: AGHT+IHK/wQpTD0H/VP6BTqN/ldOaoLF6WzOwgxxEbF7kAD97EF1ozrzuWDiyy4yxzvW6Qv+6YC44Q== X-Received: by 2002:a2e:9bce:0:b0:2c0:20c4:925a with SMTP id w14-20020a2e9bce000000b002c020c4925amr1595683ljj.26.1697544322442; Tue, 17 Oct 2023 05:05:22 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:22 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 36/73] pinctrl: remove pinctrl_gpio_can_use_line() Date: Tue, 17 Oct 2023 14:03:54 +0200 Message-Id: <20231017120431.68847-37-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_can_use_line() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 12 +++--------- include/linux/pinctrl/consumer.h | 6 ------ 2 files changed, 3 insertions(+), 15 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 6cd22829544c..4a03fc1c6ba0 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -755,7 +755,7 @@ int pinctrl_get_group_selector(struct pinctrl_dev *pctl= dev, return -EINVAL; } =20 -bool pinctrl_gpio_can_use_line(unsigned gpio) +bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et) { struct pinctrl_dev *pctldev; struct pinctrl_gpio_range *range; @@ -767,13 +767,13 @@ bool pinctrl_gpio_can_use_line(unsigned gpio) * we're probably dealing with GPIO driver * without a backing pin controller - bail out. */ - if (pinctrl_get_device_gpio_range(gpio, &pctldev, &range)) + if (pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, &range)) return true; =20 mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gpio); + pin =3D gpio_to_pin(range, gc->base + offset); =20 result =3D pinmux_can_be_used_for_gpio(pctldev, pin); =20 @@ -781,12 +781,6 @@ bool pinctrl_gpio_can_use_line(unsigned gpio) =20 return result; } -EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line); - -bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et) -{ - return pinctrl_gpio_can_use_line(gc->base + offset); -} EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line_new); =20 /* This function is deprecated and will be removed. Don't use. */ diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index c95c13983376..3991271cc39f 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -26,7 +26,6 @@ struct pinctrl_state; #ifdef CONFIG_PINCTRL =20 /* External interface to pin control */ -bool pinctrl_gpio_can_use_line(unsigned gpio); bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); int pinctrl_gpio_request(unsigned gpio); int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); @@ -73,11 +72,6 @@ static inline int pinctrl_pm_select_idle_state(struct de= vice *dev) =20 #else /* !CONFIG_PINCTRL */ =20 -static inline bool pinctrl_gpio_can_use_line(unsigned gpio) -{ - return true; -} - static inline bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id F0633CDB474 for ; Tue, 17 Oct 2023 12:07:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234948AbjJQMH2 (ORCPT ); Tue, 17 Oct 2023 08:07:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59096 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234988AbjJQMGr (ORCPT ); Tue, 17 Oct 2023 08:06:47 -0400 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 DE49E1BD5 for ; Tue, 17 Oct 2023 05:05:27 -0700 (PDT) Received: by mail-lj1-x235.google.com with SMTP id 38308e7fff4ca-2c5056059e0so60229691fa.3 for ; Tue, 17 Oct 2023 05:05:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544324; x=1698149124; darn=vger.kernel.org; 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=ThsW6Nt0Ih6GF++2vb41tY1BX2+xdfHi/vH+KQlice4=; b=Yk4ph482avhWk/MYlv0kIGPLxEzt83see/jgBL+IZYkMhxz9E/awwBvsxqXTwT1DJq AnoJ58RuANwNmpfIyF3yHkZZX+lFv0fupL8ycIzZTo5434kMOc78rFRI3fRjaogXnvA4 OFg+wvOLD0uuvqeNkEcbm/JyuFsqSfPNCjAI38t4Fq9o8JFYl+lPqnUEVtZZ8RId1LzT hVCnE7XD+rZoZs+NwNViZypRal5iN9q2A7d2j6iLHBkr2uG4ZLXQ9FsZ14f8Yv0QAXXl uMNZCXb7Nh7uRy0Y10fgxntS1NaXcuMis5uypUcwj6TSG1haTs5BkN+FfaXJwzgqMn7S hO3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544324; x=1698149124; 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=ThsW6Nt0Ih6GF++2vb41tY1BX2+xdfHi/vH+KQlice4=; b=Js6ld9R3BEJHzmS9TGf/Sj8bqNLIbb5HLwUJXXuPJuIC5D2wfcVLb1gFuNKK0SJTuu p45hNrD485yFQ1nqkEVOSpcL6RM4VaNg1tH+ISnX5182FZw/qNr/jZScia7Y4zbVY0p/ ZdHaPXxARAUC31wvkha5gXQRoLj+pK0rn9hc9q1eSNEzGoDS4QZkg0z1I8kGubY/ttr6 qkg7OBZryV632ROaIXZ/KwPJJRE4KLPkibvvUARWCQPxZy2S3YiQobrKIL29jymT2T02 8hH1yZpZFjqKOdEXTegYYCbTvPjnzRrsJ5KPlLMkHOhmix79Dc3h2ArZEoQ6pA1UfPB7 t+FA== X-Gm-Message-State: AOJu0YxxuLT8wuLS4s/93kwKnrQRIxntOqwhrJkEh1mauJLtsmH1T4HD s+OpqwrabWxKnYexmv0evKRhvA== X-Google-Smtp-Source: AGHT+IENICqafjLYY10wi9nR/Umwr+zTDxyRM3/yBS1hFKG9yVCHdjHVHH+gzhq2045irW3jhD0rZg== X-Received: by 2002:a05:651c:102f:b0:2c5:47f:8ff7 with SMTP id w15-20020a05651c102f00b002c5047f8ff7mr1579491ljm.18.1697544324183; Tue, 17 Oct 2023 05:05:24 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:23 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 37/73] pinctrl: remove pinctrl_gpio_request() Date: Tue, 17 Oct 2023 14:03:55 +0200 Message-Id: <20231017120431.68847-38-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_request() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 51 ++++++++++++++------------------ include/linux/pinctrl/consumer.h | 6 ---- 2 files changed, 22 insertions(+), 35 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 4a03fc1c6ba0..46e5fe90718b 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -783,34 +783,6 @@ bool pinctrl_gpio_can_use_line_new(struct gpio_chip *g= c, unsigned int offset) } EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line_new); =20 -/* This function is deprecated and will be removed. Don't use. */ -int pinctrl_gpio_request(unsigned gpio) -{ - struct pinctrl_dev *pctldev; - struct pinctrl_gpio_range *range; - int ret; - int pin; - - ret =3D pinctrl_get_device_gpio_range(gpio, &pctldev, &range); - if (ret) { - if (pinctrl_ready_for_gpio_range(gpio)) - ret =3D 0; - return ret; - } - - mutex_lock(&pctldev->mutex); - - /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gpio); - - ret =3D pinmux_request_gpio(pctldev, range, pin, gpio); - - mutex_unlock(&pctldev->mutex); - - return ret; -} -EXPORT_SYMBOL_GPL(pinctrl_gpio_request); - /** * pinctrl_gpio_request_new() - request a single pin to be used as GPIO * @gc: GPIO chip structure from the GPIO subsystem @@ -822,7 +794,28 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_request); */ int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) { - return pinctrl_gpio_request(gc->base + offset); + struct pinctrl_gpio_range *range; + struct pinctrl_dev *pctldev; + int ret, pin; + + ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, + &range); + if (ret) { + if (pinctrl_ready_for_gpio_range(gc->base + offset)) + ret =3D 0; + return ret; + } + + mutex_lock(&pctldev->mutex); + + /* Convert to the pin controllers number space */ + pin =3D gpio_to_pin(range, gc->base + offset); + + ret =3D pinmux_request_gpio(pctldev, range, pin, gc->base + offset); + + mutex_unlock(&pctldev->mutex); + + return ret; } EXPORT_SYMBOL_GPL(pinctrl_gpio_request_new); =20 diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 3991271cc39f..83a414a347cf 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -27,7 +27,6 @@ struct pinctrl_state; =20 /* External interface to pin control */ bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); -int pinctrl_gpio_request(unsigned gpio); int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free(unsigned gpio); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); @@ -78,11 +77,6 @@ pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsi= gned int offset) return true; } =20 -static inline int pinctrl_gpio_request(unsigned gpio) -{ - return 0; -} - static inline int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 089CACDB474 for ; Tue, 17 Oct 2023 12:07:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343643AbjJQMHf (ORCPT ); Tue, 17 Oct 2023 08:07:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343689AbjJQMGs (ORCPT ); Tue, 17 Oct 2023 08:06:48 -0400 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 31F2410E for ; Tue, 17 Oct 2023 05:05:28 -0700 (PDT) Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-2c51388ccebso38602041fa.3 for ; Tue, 17 Oct 2023 05:05:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544325; x=1698149125; darn=vger.kernel.org; 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=UTp45qpeTF/+gPzHARMv2KmOGY0Alfi//g8E89OVTQM=; b=lnqIygFwxJPZDnH9pan8NDRztJbA2YqC1qs3fLsxb/tRKPzEuYWYGFf28qwvN+7w8w 2ShK8I5u6DSNkkrx6NY95kvqO0e+yWU1J4fSKHyJ/KbBp+NwpU5bZk/+xC9Y76lxhHZw jRgLRrtuZEWyRXctqf5+noGpCFz4IE6uOVcOcxt5z5fAy1qjJg0fJ/s0TAIU903GWZOy qiTFhDq0FTNzDBCHv08/m/adH8eLXtaSM+fjBpbsFjydLoPmNGDjH9/X62sLubRBIU8f ueXeV+d6IKzBfmqVoZ7IAqPoi6uR6ceSLrrsM/OaSzwH2zFrik4O4ampCqid2liVUCB3 TMgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544325; x=1698149125; 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=UTp45qpeTF/+gPzHARMv2KmOGY0Alfi//g8E89OVTQM=; b=hMhrPinnju2A6pI+G4FhZZEGbFJF8LmZHPKp6b7bMhOeBiCiRjbG30UUayNQ9dVagI GwIpvzw7hRgFbnYmMuw3SrO54yEnD9IRaXTaxnuutrJBvv3+O5JEkneJMhyN2TfT5grB hVKGcObKUWk+pm7Xwm3Gmi52gdEqLGN0fHrkO+DshK+16uqy+uXTeQgwH0F4vQyT61t+ KoZTpd8+g0OHeiOI6z550ehtHdd7/M/YIXZWbkUCEqy3dqZgSX61xZrilo5X3e+hksQs QRR8vZtVNqWL81PDqGooqLaHTEEcFlm8J3Uc+W5j0P6QAjbVvS7Idfh5VBdxtI7VDRXu rAEA== X-Gm-Message-State: AOJu0YzZjiXcLhVYX/UfTJFQ6ofD5iiyAM+jasbVeblBQhUl5oetLjEa i2+20Eh+f4jCbYVRyl6pxodLJQ== X-Google-Smtp-Source: AGHT+IGdoHFWz6qAcVFDGAMc7KnLo665dhnHhEtx9RUpTzfX4R2j7ZSCVSU8KKqG9zlUAWhnHQlB/Q== X-Received: by 2002:a2e:7e0b:0:b0:2bc:efa4:2c32 with SMTP id z11-20020a2e7e0b000000b002bcefa42c32mr1383090ljc.37.1697544325140; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:24 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 38/73] pinctrl: remove pinctrl_gpio_free() Date: Tue, 17 Oct 2023 14:03:56 +0200 Message-Id: <20231017120431.68847-39-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_free() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 41 +++++++++++++------------------- include/linux/pinctrl/consumer.h | 5 ---- 2 files changed, 17 insertions(+), 29 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 46e5fe90718b..5a1414bfeacc 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -819,29 +819,6 @@ int pinctrl_gpio_request_new(struct gpio_chip *gc, uns= igned int offset) } EXPORT_SYMBOL_GPL(pinctrl_gpio_request_new); =20 -/* This function is deprecated and will be removed. Don't use. */ -void pinctrl_gpio_free(unsigned gpio) -{ - struct pinctrl_dev *pctldev; - struct pinctrl_gpio_range *range; - int ret; - int pin; - - ret =3D pinctrl_get_device_gpio_range(gpio, &pctldev, &range); - if (ret) { - return; - } - mutex_lock(&pctldev->mutex); - - /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gpio); - - pinmux_free_gpio(pctldev, pin, range); - - mutex_unlock(&pctldev->mutex); -} -EXPORT_SYMBOL_GPL(pinctrl_gpio_free); - /** * pinctrl_gpio_free_new() - free control on a single pin, currently used = as GPIO * @gc: GPIO chip structure from the GPIO subsystem @@ -853,7 +830,23 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_free); */ void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) { - return pinctrl_gpio_free(gc->base + offset); + struct pinctrl_gpio_range *range; + struct pinctrl_dev *pctldev; + int ret, pin; + + ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, + &range); + if (ret) + return; + + mutex_lock(&pctldev->mutex); + + /* Convert to the pin controllers number space */ + pin =3D gpio_to_pin(range, gc->base + offset); + + pinmux_free_gpio(pctldev, pin, range); + + mutex_unlock(&pctldev->mutex); } EXPORT_SYMBOL_GPL(pinctrl_gpio_free_new); =20 diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 83a414a347cf..90b2f0b78c4b 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -28,7 +28,6 @@ struct pinctrl_state; /* External interface to pin control */ bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); -void pinctrl_gpio_free(unsigned gpio); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input(unsigned gpio); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, @@ -83,10 +82,6 @@ pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned = int offset) return 0; } =20 -static inline void pinctrl_gpio_free(unsigned gpio) -{ -} - static inline void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5463ACDB474 for ; Tue, 17 Oct 2023 12:23:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234350AbjJQMXG (ORCPT ); Tue, 17 Oct 2023 08:23:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48588 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233640AbjJQMWr (ORCPT ); Tue, 17 Oct 2023 08:22:47 -0400 Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C28C0112 for ; Tue, 17 Oct 2023 05:05:29 -0700 (PDT) Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-407c3adef8eso4127315e9.2 for ; Tue, 17 Oct 2023 05:05:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544326; x=1698149126; darn=vger.kernel.org; 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=Sp1LIUfvDYE1l/aL1VLqxtchd//6yPiTcnPiXQzQOTs=; b=rUhTnV0DudQiYo2r4dgVuPQzHWWsBnd1nkljDIdFDe2mUrukjHBUKEWiUc81v6gwLK CNu+J1Of4hPzTMf7lhT+SMOqa/qsgb+MNUvSey4o+rpF6nOcTNykImFDmU+avmS5ca5m y9bRe2nocQr02oqPe2JjY26hNOiYQfr+1BK2Qhl2zKF4MmVNV7xnUBZvv5/Qx3hApGwV GSNFtCX2yEnMgkxlsuLmmf8TmM1LMM1B2mBw30q95mArY/pQqHpdFgC2WnKpUIxnsxzb 0ptvftZXZqdhbGDjuIdqYMBiF/2XTJ/6uBa3L6rAgOlG2qh5Num6p4DQmBI4gxhQaTI4 +tVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544326; x=1698149126; 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=Sp1LIUfvDYE1l/aL1VLqxtchd//6yPiTcnPiXQzQOTs=; b=PEz3/u+iE/xyGlmADbJ1fJ0SPphiVA1tyg0eP70O6S800QIVlYczCNDfZI/ryQ4ezv hcBlqyMoWIt9ZqB5Wsj/o0SOuvDWoWyEQ0MahXnoDoqDQzlunC8iuXEpa/Eox+sm4Avn ODdheTasXTcS8NVH+lA/qr5UUkRJ+Fty+FRjt8VNKp1wAmh1tHZDdR7vIzSM5j4yC/0f PuBLXEhutDJoRZ4Gu5D32wSVcrKgTvQBvMFY0NfbKXftY92bNjMKIxc1bvZ03RrChdal rLQHncBwiQjcxzdPPl5AqbiMz0W5I4ZyOfpQSsdS6imptvyYN/fPhAExC1vybnnWBWhf ctOA== X-Gm-Message-State: AOJu0YynfwcscIrZLvUPDyhNyk2mBcjfDPCLRcya6Uv+1Hpyj0Mwwp4H x+HihNQ5q2mXN4Qo2dzmYeeE4A== X-Google-Smtp-Source: AGHT+IFKE4p8HewSElt7IrWW+9f7VTBcLC5Ondi/Z9HT3X00nCq/DNt6DFg4b1GbJEhZRl4wJ23erw== X-Received: by 2002:a05:600c:a48:b0:405:3d41:5646 with SMTP id c8-20020a05600c0a4800b004053d415646mr1554434wmq.2.1697544325925; Tue, 17 Oct 2023 05:05:25 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:25 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 39/73] pinctrl: remove pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:03:57 +0200 Message-Id: <20231017120431.68847-40-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_direction_input() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 9 +-------- include/linux/pinctrl/consumer.h | 6 ------ 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 5a1414bfeacc..80f565aac707 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -873,13 +873,6 @@ static int pinctrl_gpio_direction(unsigned gpio, bool = input) return ret; } =20 -/* This function is deprecated and will be removed. Don't use. */ -int pinctrl_gpio_direction_input(unsigned gpio) -{ - return pinctrl_gpio_direction(gpio, true); -} -EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); - /** * pinctrl_gpio_direction_input_new() - request a GPIO pin to go into inpu= t mode * @gc: GPIO chip structure from the GPIO subsystem @@ -891,7 +884,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); */ int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int of= fset) { - return pinctrl_gpio_direction_input(gc->base + offset); + return pinctrl_gpio_direction(gc->base + offset, true); } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input_new); =20 diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 90b2f0b78c4b..249bb28a52d6 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -29,7 +29,6 @@ struct pinctrl_state; bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_direction_input(unsigned gpio); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_output(unsigned gpio); @@ -87,11 +86,6 @@ pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int= offset) { } =20 -static inline int pinctrl_gpio_direction_input(unsigned gpio) -{ - return 0; -} - static inline int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EB80BCDB474 for ; Tue, 17 Oct 2023 12:20:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343699AbjJQMUa (ORCPT ); Tue, 17 Oct 2023 08:20:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48372 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235032AbjJQMUH (ORCPT ); Tue, 17 Oct 2023 08:20:07 -0400 Received: from mail-lj1-x233.google.com (mail-lj1-x233.google.com [IPv6:2a00:1450:4864:20::233]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 232281BF5 for ; Tue, 17 Oct 2023 05:05:30 -0700 (PDT) Received: by mail-lj1-x233.google.com with SMTP id 38308e7fff4ca-2bb9a063f26so70228851fa.2 for ; Tue, 17 Oct 2023 05:05:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544327; x=1698149127; darn=vger.kernel.org; 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=I6cZJ9iOvjAsdg8L9d8ZBjfJOuY8giQz9BcQIlxiHnc=; b=IrEtUnYzM7bU4f67RzhcQwixNd1/M3ZvXP3tJSRGcLCO2NDoZB1yU4jbS9q4NJmI1n udYlHIHj+Abct2VVgJssgDAEyLL5CChp09Y6uYjFKLHFDXJunAfz+L6akd9EE9RE6uLz Po8Ww934yIUKK1IOItcSnLfujyfpwjsMIw1L6r/dFOND7/jXK59JyJsd2OYoXsqHex+/ rXWeM27RQ1tfd8hZULY3Hk0AliXKRtwvOgJLlIe5eW2dDQPCF00wfQuBbxvNviulCBO7 AGkF7YJ+W/8oo+HLp7hU1LnE56Sw6axCrQewfPbwxn9GgGtRVzAPitu03vLoUUl8b+U1 gjSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544327; x=1698149127; 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=I6cZJ9iOvjAsdg8L9d8ZBjfJOuY8giQz9BcQIlxiHnc=; b=GXp5CbxYfjM7afbF9OcsJJ/feJcGXcRiP9CiRbES2m3huz/z9n9+0QFbuXSGGtFPKP sziKywsGdGKuwpjqdljMse1x6DqePMvILGR67It0qW694TV7JtM7qLfpaYzuzFoR/+OX rg1ZhtAKADk9GZAZoNmryZ0xR8P4Mo4UXfrG+e/z9BgcnkqLR/1JegS9c4QN//yTta0E EKT7NlrAvHKNm6d8HAlZCTRfOYGkPAbG1ltJHESk9uxzVxaxatSYMcTRBgw9v0GTWEXw OmREoTIlMw5qklQYrT1PPNCZ0pBez8qGFd9yhtFbKye2m3IE93aPO4Abm+lNp/UjWvkN aMgA== X-Gm-Message-State: AOJu0Ywceqlt+xHLDNuLeEVKGpzoKz67LKTmECutET8Sa99rg9c71tbw YUZiyi1EzblVBoDXXwA2KBuWOQ== X-Google-Smtp-Source: AGHT+IHIx2IT1ps4wbETt4/2aJXXyDnFuR04+EKtk22Vy46nsZK+31vJnPA+tvs9MQ98GtqknoVxWQ== X-Received: by 2002:a2e:6e17:0:b0:2c5:17ac:77f7 with SMTP id j23-20020a2e6e17000000b002c517ac77f7mr1411851ljc.1.1697544327089; Tue, 17 Oct 2023 05:05:27 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:26 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 40/73] pinctrl: remove pinctrl_gpio_direction_output() Date: Tue, 17 Oct 2023 14:03:58 +0200 Message-Id: <20231017120431.68847-41-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_direction_output() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 9 +-------- include/linux/pinctrl/consumer.h | 6 ------ 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 80f565aac707..0d66b3d5e685 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -888,13 +888,6 @@ int pinctrl_gpio_direction_input_new(struct gpio_chip = *gc, unsigned int offset) } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input_new); =20 -/* This function is deprecated and will be removed. Don't use. */ -int pinctrl_gpio_direction_output(unsigned gpio) -{ - return pinctrl_gpio_direction(gpio, false); -} -EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); - /** * pinctrl_gpio_direction_output_new() - request a GPIO pin to go into out= put * mode @@ -907,7 +900,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); */ int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int o= ffset) { - return pinctrl_gpio_direction_output(gc->base + offset); + return pinctrl_gpio_direction(gc->base + offset, false); } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output_new); =20 diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 249bb28a52d6..e25e9b0599ac 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -31,7 +31,6 @@ int pinctrl_gpio_request_new(struct gpio_chip *gc, unsign= ed int offset); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_direction_output(unsigned gpio); int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_set_config(unsigned gpio, unsigned long config); @@ -92,11 +91,6 @@ pinctrl_gpio_direction_input_new(struct gpio_chip *gc, u= nsigned int offset) return 0; } =20 -static inline int pinctrl_gpio_direction_output(unsigned gpio) -{ - return 0; -} - static inline int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offse= t) { --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6D99CCDB474 for ; Tue, 17 Oct 2023 12:20:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235192AbjJQMU4 (ORCPT ); Tue, 17 Oct 2023 08:20:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48566 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235137AbjJQMUi (ORCPT ); Tue, 17 Oct 2023 08:20:38 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 361561BF6 for ; Tue, 17 Oct 2023 05:05:30 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-4064867903cso62409455e9.2 for ; Tue, 17 Oct 2023 05:05:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544328; x=1698149128; darn=vger.kernel.org; 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=Lqh80WdRi0gOj4xJupqHqeCuK7TYCSZZE8MoyG0FXMc=; b=Jp9HR6nFwhdnzZ3rk2trcvAffihrRRbD9skIVXxL4UrSkktfEAcQ0zEBNNgc7DA57o lg6prSQKRZhqhDb7R1abWL0PdiKfT9ZZ02gunA+qoYz2GAhmDIz2US8pNmzZC/R6hqkn iaSHSLts84BPCmm3AH/+M2s3KFNqDpwdxxKMAwy/kY9qpTTQWELq6z+4T9F9uhQ5sHOF gRJV3rrQefVLG7dFeTsjOZ4NMgv0ETSZpvtE+34IzWQDjP1mBWjwMxk6nEtaz+WNIAzs mO1CD0WBwKZPoRQglRTWGREK9jZzammWM+SMsrS5Fv2ymUArnannog0ymacwrs2xHlgL FEmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544328; x=1698149128; 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=Lqh80WdRi0gOj4xJupqHqeCuK7TYCSZZE8MoyG0FXMc=; b=qgss9RXRJbCqhh+Pnxj+bw7TCNbpf/pLXc3oeutFKKnpconOoEBYaDf/DMZ70q071l Uo5SvJdDXsbcFWLw2tYpUeyQqfNYbsR1qpCoxEBpsCSyro8iI69w5TbqaCTicl9d0H3a sbYQbQVx3U0Ds+Rypifd+0rNWcKXI6s2jp8S/KsutkKCL5iVpnSEYQQqxkLGxmjhH8dQ xQtXR7FQktABFBNdhl+mTESj+waL3Mo+l/uaLi+zOSWfT2J7CM1ccu/9bO+f0g/bxpJl CMRFQliZKs7KfQ/JY5G9A7HKhgdYu4VcwEsn12oZikcAijua7AL2CVt1SPrppd9bYzFL +fDA== X-Gm-Message-State: AOJu0YxcN3GPg+KScu3jP83R96ODvw8fO2LvDVge32jN6HBX6JSFfjxy 4HoJFPB543tZY5Jxw9fhybsZV4lduOCEpnJPQhQ= X-Google-Smtp-Source: AGHT+IGtqD2NSdKrkdy2YLUUP3llJ/HF4BUPh1V5oC58M9d5555REcKLTl3cSqEFX6D3mS1v1zF0ww== X-Received: by 2002:a05:600c:4f0d:b0:405:37bb:d940 with SMTP id l13-20020a05600c4f0d00b0040537bbd940mr1723644wmq.0.1697544328006; Tue, 17 Oct 2023 05:05:28 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:27 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 41/73] pinctrl: remove pinctrl_gpio_set_config() Date: Tue, 17 Oct 2023 14:03:59 +0200 Message-Id: <20231017120431.68847-42-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski There are no more users of pinctrl_gpio_set_config() so remove it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 38 ++++++++++++++------------------ include/linux/pinctrl/consumer.h | 6 ----- 2 files changed, 16 insertions(+), 28 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 0d66b3d5e685..881845395885 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -904,27 +904,6 @@ int pinctrl_gpio_direction_output_new(struct gpio_chip= *gc, unsigned int offset) } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output_new); =20 -/* This function is deprecated and will be removed. Don't use. */ -int pinctrl_gpio_set_config(unsigned gpio, unsigned long config) -{ - unsigned long configs[] =3D { config }; - struct pinctrl_gpio_range *range; - struct pinctrl_dev *pctldev; - int ret, pin; - - ret =3D pinctrl_get_device_gpio_range(gpio, &pctldev, &range); - if (ret) - return ret; - - mutex_lock(&pctldev->mutex); - pin =3D gpio_to_pin(range, gpio); - ret =3D pinconf_set_config(pctldev, pin, configs, ARRAY_SIZE(configs)); - mutex_unlock(&pctldev->mutex); - - return ret; -} -EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config); - /** * pinctrl_gpio_set_config_new() - Apply config to given GPIO pin * @gc: GPIO chip structure from the GPIO subsystem @@ -938,7 +917,22 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config); int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, unsigned long config) { - return pinctrl_gpio_set_config(gc->base + offset, config); + unsigned long configs[] =3D { config }; + struct pinctrl_gpio_range *range; + struct pinctrl_dev *pctldev; + int ret, pin; + + ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, + &range); + if (ret) + return ret; + + mutex_lock(&pctldev->mutex); + pin =3D gpio_to_pin(range, gc->base + offset); + ret =3D pinconf_set_config(pctldev, pin, configs, ARRAY_SIZE(configs)); + mutex_unlock(&pctldev->mutex); + + return ret; } EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config_new); =20 diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index e25e9b0599ac..aa3a7a7ca52d 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -33,7 +33,6 @@ int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_set_config(unsigned gpio, unsigned long config); int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, unsigned long config); =20 @@ -97,11 +96,6 @@ pinctrl_gpio_direction_output_new(struct gpio_chip *gc, = unsigned int offset) return 0; } =20 -static inline int pinctrl_gpio_set_config(unsigned gpio, unsigned long con= fig) -{ - return 0; -} - static inline int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, unsigned long config) --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6F23ACDB474 for ; Tue, 17 Oct 2023 12:07:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343671AbjJQMHi (ORCPT ); Tue, 17 Oct 2023 08:07:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60760 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343780AbjJQMHD (ORCPT ); Tue, 17 Oct 2023 08:07:03 -0400 Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0DA4F1FC4 for ; Tue, 17 Oct 2023 05:05:31 -0700 (PDT) Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2c5028e5b88so59482961fa.3 for ; Tue, 17 Oct 2023 05:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544329; x=1698149129; darn=vger.kernel.org; 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=ZmbOot5RLrw4dhGM35wwQDK66NpZcPzXz+VcMMZhqQw=; b=AR6rAWDOWbPt1AtkTSN3PTMBPkj1L2qTPmKSbC9w0hTqO3CZlDkRQk3iFVCDT5gwLx ETKyUcbJrqsrrVE2pjFKzSh/j7Vhu2tFcSSd+O+oKrpBdxSfCni1365N9URaBGeDgyK5 SliNmYGXGX/6G0Hn4KptzXL5RJXDPkkOsg8KRcZvh0kXk73gvJlmcsOEDv/61ldsVhlC szomGA2dGTqt92j3MytV0lVW9sDtI1zlc3eA7n5AY5us7Br3m8YU4f0YgX0WMKFu70L/ thDl3wFILRP+G3q/+7h1/RcjFxyh2p9bvHfqSwjh1tq754bxxLBkLrELf7vY0CW5UrOW vumg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544329; x=1698149129; 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=ZmbOot5RLrw4dhGM35wwQDK66NpZcPzXz+VcMMZhqQw=; b=mWXxcX6pKmNf0h97becFPWwTfmukFmCk8UndF/Y30eVptzC/Rt2PRSfvVuvCDpm6M5 rsMrtlsGd9McRhwc1P866atY6MYqPlEvXlEj+K+5eVytTsKdgOx6YDVKWQ2YmDKpjuFJ ycwec8grncdE7bZsEXOldSW6+kpT0PH4FWkb0G1w1mlD7ev6huHiQO1DES9GqKALvfwF q8w8fRi1YTYV2IknsomcZD9AOZsqZGgbHCYqphhL/EVI6ISN3epl82h9/u4uKh9GP9Cg Nsz6UiSvBipWKASGEKbrIk8hSO5K+AgfPgWkTkBdweR6aSzfh4GH1zaitJa0xWsbOcyS 4AOg== X-Gm-Message-State: AOJu0YzlGmpE4Amjr+gxYKv7CatlmvNzlJ2SpV74PPztmNRcLI/hN1Sk 21HInxcFf4GaPTggUXPKHEnfzA== X-Google-Smtp-Source: AGHT+IHnnbArgK7X3e7NA50LhtLme/ELgZolnw+hJhzIV6zoyJbs7diRLj3gP/grQYP7SGxh9SaD3g== X-Received: by 2002:a05:651c:314:b0:2c0:21b6:e82e with SMTP id a20-20020a05651c031400b002c021b6e82emr1509394ljp.4.1697544328832; Tue, 17 Oct 2023 05:05:28 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:28 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 42/73] treewide: rename pinctrl_gpio_can_use_line_new() Date: Tue, 17 Oct 2023 14:04:00 +0200 Message-Id: <20231017120431.68847-43-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_can_use_line() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpiolib-cdev.c | 2 +- drivers/pinctrl/core.c | 4 ++-- include/linux/pinctrl/consumer.h | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c index 54ee075410db..02ffda6c1e51 100644 --- a/drivers/gpio/gpiolib-cdev.c +++ b/drivers/gpio/gpiolib-cdev.c @@ -2287,7 +2287,7 @@ static void gpio_desc_to_lineinfo(struct gpio_desc *d= esc, * FIXME: find a non-racy way to retrieve this information. Maybe a * lock common to both frameworks? */ - ok_for_pinctrl =3D pinctrl_gpio_can_use_line_new(gc, info->offset); + ok_for_pinctrl =3D pinctrl_gpio_can_use_line(gc, info->offset); =20 spin_lock_irqsave(&gpio_lock, flags); =20 diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 881845395885..20f4b655aa08 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -755,7 +755,7 @@ int pinctrl_get_group_selector(struct pinctrl_dev *pctl= dev, return -EINVAL; } =20 -bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et) +bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset) { struct pinctrl_dev *pctldev; struct pinctrl_gpio_range *range; @@ -781,7 +781,7 @@ bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc= , unsigned int offset) =20 return result; } -EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line); =20 /** * pinctrl_gpio_request_new() - request a single pin to be used as GPIO diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index aa3a7a7ca52d..4f9ead7f65d2 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -26,7 +26,7 @@ struct pinctrl_state; #ifdef CONFIG_PINCTRL =20 /* External interface to pin control */ -bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offs= et); +bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, @@ -68,7 +68,7 @@ static inline int pinctrl_pm_select_idle_state(struct dev= ice *dev) #else /* !CONFIG_PINCTRL */ =20 static inline bool -pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset) +pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset) { return true; } --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CF7C7CDB474 for ; Tue, 17 Oct 2023 12:08:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235001AbjJQMIB (ORCPT ); Tue, 17 Oct 2023 08:08:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36454 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343644AbjJQMHL (ORCPT ); Tue, 17 Oct 2023 08:07:11 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 799321FCC for ; Tue, 17 Oct 2023 05:05:32 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-405361bb9f7so55479345e9.2 for ; Tue, 17 Oct 2023 05:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544329; x=1698149129; darn=vger.kernel.org; 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=p42f61CpUtMnJj/47/fYVjanoYa1QidKwMzIa52vOno=; b=uilx1vwS6vDfUa72y9oJf0tw4KFMENZ7iDorK6yc1XsGSdj4vwnGwgwmSGRKsV8se7 HUrs+ix/1UGQ8sNEHpvfWWMt5EXA7nMGwBADRQeRIEeUZUnhDdxX7zbiSpvQKIES3Q2Q NWz8Iaue6jYURMoPQWNCw+tkV2v4ZvjwWTL6YdAMVmgIhDffJ3Bppt8/g5xBeWFkdM8n G16rlnjVeu+nbPj3DoVaWd2QBOLfWDD9aP8TSXNQW3pFw2JBDwch9swBalqTs85EBJF7 oYE6GXHjCJriGMcBGJGEXgOwVWLGcADs7d7Vk2MI4WH8c6L1YShh79WkuVpuJcGinTD2 5g3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544329; x=1698149129; 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=p42f61CpUtMnJj/47/fYVjanoYa1QidKwMzIa52vOno=; b=nMT2svzLZ9c7AQ+d7BOe02Gj3p8hmIgcooUMMabiAoPVFSE1N1zJjWft6PcEyCAvS2 VfEW5ok8WAu+vDVhuETdzFffjste+DHOI1zl3s6jpB0f+7rysjRbw93wZB7l3Xv17HVk dyxZ4T9pqtUkn75LGG0x7xPM4rKDs2S6SyyfOzREKKzmYdhM4jHyLrL48cfVd0iEUUd2 JJbI0MS0KhCqtUh/Fl8GiJRJcz7TFGLxeFuFpUIYBPbkFCwISija6adKq7eBpf014pE3 vqbxnOn96h0gCoc3SeYsG2UGj4RWevjjVUg5YiCu1e5E8J/6BTkplpY6nIXcBCYP0BEM 8wuA== X-Gm-Message-State: AOJu0Yx17ls4P+93dulNRqkxoCNcc2xZxbPnZVtqRxzufVrcBeZxw0Kr 7WOaHxN6t3D+7XCEQ0UnzKpInQ== X-Google-Smtp-Source: AGHT+IGv2Xe4CwTYDNz2u/cfF/4691A8eOUhjlPtHXifLJJRaCGAGtZ1ZAtF4IGeFWLnhYHGPpN+7A== X-Received: by 2002:a05:600c:46c6:b0:406:7d74:a2a6 with SMTP id q6-20020a05600c46c600b004067d74a2a6mr1664614wmo.24.1697544329693; Tue, 17 Oct 2023 05:05:29 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:29 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 43/73] treewide: rename pinctrl_gpio_request_new() Date: Tue, 17 Oct 2023 14:04:01 +0200 Message-Id: <20231017120431.68847-44-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_request() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-aspeed.c | 2 +- drivers/gpio/gpio-em.c | 2 +- drivers/gpio/gpio-rcar.c | 2 +- drivers/gpio/gpio-tegra.c | 2 +- drivers/gpio/gpiolib.c | 2 +- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 2 +- drivers/pinctrl/core.c | 6 +++--- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 2 +- drivers/pinctrl/renesas/gpio.c | 2 +- drivers/pinctrl/renesas/pinctrl-rzg2l.c | 2 +- drivers/pinctrl/renesas/pinctrl-rzv2m.c | 2 +- drivers/pinctrl/spear/pinctrl-plgpio.c | 2 +- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 2 +- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 2 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- include/linux/pinctrl/consumer.h | 4 ++-- 17 files changed, 20 insertions(+), 20 deletions(-) diff --git a/drivers/gpio/gpio-aspeed.c b/drivers/gpio/gpio-aspeed.c index d3aa1cfd4ace..af851c89cacc 100644 --- a/drivers/gpio/gpio-aspeed.c +++ b/drivers/gpio/gpio-aspeed.c @@ -750,7 +750,7 @@ static int aspeed_gpio_request(struct gpio_chip *chip, = unsigned int offset) if (!have_gpio(gpiochip_get_data(chip), offset)) return -ENODEV; =20 - return pinctrl_gpio_request_new(chip, offset); + return pinctrl_gpio_request(chip, offset); } =20 static void aspeed_gpio_free(struct gpio_chip *chip, unsigned int offset) diff --git a/drivers/gpio/gpio-em.c b/drivers/gpio/gpio-em.c index 35c65ff43f71..08c5427deb71 100644 --- a/drivers/gpio/gpio-em.c +++ b/drivers/gpio/gpio-em.c @@ -229,7 +229,7 @@ static int em_gio_to_irq(struct gpio_chip *chip, unsign= ed offset) =20 static int em_gio_request(struct gpio_chip *chip, unsigned offset) { - return pinctrl_gpio_request_new(chip, offset); + return pinctrl_gpio_request(chip, offset); } =20 static void em_gio_free(struct gpio_chip *chip, unsigned offset) diff --git a/drivers/gpio/gpio-rcar.c b/drivers/gpio/gpio-rcar.c index 47121e1a6d4e..8c98730a7ad2 100644 --- a/drivers/gpio/gpio-rcar.c +++ b/drivers/gpio/gpio-rcar.c @@ -275,7 +275,7 @@ static int gpio_rcar_request(struct gpio_chip *chip, un= signed offset) return error; } =20 - error =3D pinctrl_gpio_request_new(chip, offset); + error =3D pinctrl_gpio_request(chip, offset); if (error) pm_runtime_put(p->dev); =20 diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index 08951ddcd294..c974ba368d18 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -139,7 +139,7 @@ static void tegra_gpio_disable(struct tegra_gpio_info *= tgi, unsigned int gpio) =20 static int tegra_gpio_request(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_request_new(chip, offset); + return pinctrl_gpio_request(chip, offset); } =20 static void tegra_gpio_free(struct gpio_chip *chip, unsigned int offset) diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 37c1df78437f..794408be7109 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -2036,7 +2036,7 @@ int gpiochip_generic_request(struct gpio_chip *gc, un= signed int offset) return 0; #endif =20 - return pinctrl_gpio_request_new(gc, offset); + return pinctrl_gpio_request(gc, offset); } EXPORT_SYMBOL_GPL(gpiochip_generic_request); =20 diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm= /pinctrl-iproc-gpio.c index fb98c3e14743..8162dd840933 100644 --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c @@ -335,7 +335,7 @@ static int iproc_gpio_request(struct gpio_chip *gc, uns= igned offset) if (!chip->pinmux_is_supported) return 0; =20 - return pinctrl_gpio_request_new(gc, offset); + return pinctrl_gpio_request(gc, offset); } =20 static void iproc_gpio_free(struct gpio_chip *gc, unsigned offset) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 20f4b655aa08..d200a887dc5d 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -784,7 +784,7 @@ bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, un= signed int offset) EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line); =20 /** - * pinctrl_gpio_request_new() - request a single pin to be used as GPIO + * pinctrl_gpio_request() - request a single pin to be used as GPIO * @gc: GPIO chip structure from the GPIO subsystem * @offset: hardware offset of the GPIO relative to the controller * @@ -792,7 +792,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line); * as part of their gpio_request() semantics, platforms and individual dri= vers * shall *NOT* request GPIO pins to be muxed in. */ -int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) +int pinctrl_gpio_request(struct gpio_chip *gc, unsigned int offset) { struct pinctrl_gpio_range *range; struct pinctrl_dev *pctldev; @@ -817,7 +817,7 @@ int pinctrl_gpio_request_new(struct gpio_chip *gc, unsi= gned int offset) =20 return ret; } -EXPORT_SYMBOL_GPL(pinctrl_gpio_request_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_request); =20 /** * pinctrl_gpio_free_new() - free control on a single pin, currently used = as GPIO diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index 62134a7f0b4e..ad39b8c060b7 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -201,7 +201,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) int ret; =20 dev_dbg(chip->parent, "gpio_request: offset%d\n", offset); - ret =3D pinctrl_gpio_request_new(chip, offset); + ret =3D pinctrl_gpio_request(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index 0b6d6964087e..dd4532ae62bf 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -198,7 +198,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_request_new(chip, offset); + ret =3D pinctrl_gpio_request(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/renesas/gpio.c b/drivers/pinctrl/renesas/gpio.c index e7771a57e6d1..0c4f4d8d0891 100644 --- a/drivers/pinctrl/renesas/gpio.c +++ b/drivers/pinctrl/renesas/gpio.c @@ -135,7 +135,7 @@ static int gpio_pin_request(struct gpio_chip *gc, unsig= ned offset) if (idx < 0 || pfc->info->pins[idx].enum_id =3D=3D 0) return -EINVAL; =20 - return pinctrl_gpio_request_new(gc, offset); + return pinctrl_gpio_request(gc, offset); } =20 static void gpio_pin_free(struct gpio_chip *gc, unsigned offset) diff --git a/drivers/pinctrl/renesas/pinctrl-rzg2l.c b/drivers/pinctrl/rene= sas/pinctrl-rzg2l.c index 22d4ab7d228c..c5d247d24374 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzg2l.c +++ b/drivers/pinctrl/renesas/pinctrl-rzg2l.c @@ -1056,7 +1056,7 @@ static int rzg2l_gpio_request(struct gpio_chip *chip,= unsigned int offset) if (ret) return ret; =20 - ret =3D pinctrl_gpio_request_new(chip, offset); + ret =3D pinctrl_gpio_request(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/renesas/pinctrl-rzv2m.c b/drivers/pinctrl/rene= sas/pinctrl-rzv2m.c index 3d29c77a5aad..1ec0922f735c 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzv2m.c +++ b/drivers/pinctrl/renesas/pinctrl-rzv2m.c @@ -754,7 +754,7 @@ static int rzv2m_gpio_request(struct gpio_chip *chip, u= nsigned int offset) u8 bit =3D RZV2M_PIN_ID_TO_PIN(offset); int ret; =20 - ret =3D pinctrl_gpio_request_new(chip, offset); + ret =3D pinctrl_gpio_request(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/spear/pinctrl-plgpio.c b/drivers/pinctrl/spear= /pinctrl-plgpio.c index 7488f6394318..6d3b7ce1c35a 100644 --- a/drivers/pinctrl/spear/pinctrl-plgpio.c +++ b/drivers/pinctrl/spear/pinctrl-plgpio.c @@ -210,7 +210,7 @@ static int plgpio_request(struct gpio_chip *chip, unsig= ned offset) if (offset >=3D chip->ngpio) return -EINVAL; =20 - ret =3D pinctrl_gpio_request_new(chip, offset); + ret =3D pinctrl_gpio_request(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7100.c index 22a2db8fa315..88e39f68ef25 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c @@ -918,7 +918,7 @@ static struct pinctrl_desc starfive_desc =3D { =20 static int starfive_gpio_request(struct gpio_chip *gc, unsigned int gpio) { - return pinctrl_gpio_request_new(gc, gpio); + return pinctrl_gpio_request(gc, gpio); } =20 static void starfive_gpio_free(struct gpio_chip *gc, unsigned int gpio) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7110.c index 5557ef3fbeb2..c458c6fb992f 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c @@ -547,7 +547,7 @@ static const struct pinconf_ops jh7110_pinconf_ops =3D { =20 static int jh7110_gpio_request(struct gpio_chip *gc, unsigned int gpio) { - return pinctrl_gpio_request_new(gc, gpio); + return pinctrl_gpio_request(gc, gpio); } =20 static void jh7110_gpio_free(struct gpio_chip *gc, unsigned int gpio) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index 11d9f07934bd..dddbdc1a64c5 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -217,7 +217,7 @@ static int stm32_gpio_request(struct gpio_chip *chip, u= nsigned offset) return -EINVAL; } =20 - return pinctrl_gpio_request_new(chip, offset); + return pinctrl_gpio_request(chip, offset); } =20 static void stm32_gpio_free(struct gpio_chip *chip, unsigned offset) diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 4f9ead7f65d2..05b2dae05f24 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -27,7 +27,7 @@ struct pinctrl_state; =20 /* External interface to pin control */ bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset); +int pinctrl_gpio_request(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset); @@ -74,7 +74,7 @@ pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned = int offset) } =20 static inline int -pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset) +pinctrl_gpio_request(struct gpio_chip *gc, unsigned int offset) { return 0; } --=20 2.39.2 From nobody Sat Feb 7 20:25:23 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6F081CDB474 for ; Tue, 17 Oct 2023 12:20:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343813AbjJQMUP (ORCPT ); Tue, 17 Oct 2023 08:20:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48538 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235156AbjJQMUA (ORCPT ); Tue, 17 Oct 2023 08:20:00 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1421C1FDA for ; Tue, 17 Oct 2023 05:05:32 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-40572aeb673so53903875e9.0 for ; Tue, 17 Oct 2023 05:05:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544331; x=1698149131; darn=vger.kernel.org; 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=CUI+RK0dSqyYZaeI61u77qIZqUqMiGdn4pfRi7va2/E=; b=uwre9TYIMZXoe/QIshrxf029enzYGkdB04/VWfdn1FB0ON5rJ+FkqVTGvJlGJ5mME/ V6la/a031MLFvgqQRhI+tB7XU39mElLo3CcihcnuPPfPo2WiWcVjxmf/pw1YyKO5fd1r +OkIT8/fN0JnFAbhSw+zV4/ABUlG3WKd9QzYi3mmpfxLS88GEb+ttNAL6HACynbVnRZu hDKq9Vd9TvErTzxRCr/kBCGFn4or4VEBBXwkpamk9e7HLtdZCpYrkxIR8NbUFKQ78q0R 9dUGSkmNn3bXxwt7Ou4JaGzTrm7UH8arcYc2+uUv3SXhQOX0OLfhIy1+m0Tcn7DUfGFc +09Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544331; x=1698149131; 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=CUI+RK0dSqyYZaeI61u77qIZqUqMiGdn4pfRi7va2/E=; b=pdDS+Cy9XDz8sYk8Ar0Ww1APv7P3Du7umO/n2N8utWw+HY3XydEaDFoMRtIS+z4BM5 1aOSgpa5kCF5zrfNEtLbUwzBkR9AR5SkdMWCJheTTHHAntKCWYQ+G4XM8VpAZyfm1xVq pzmhetO4cgCnlNTbJ8PuV8wCYV+0IDHd8Oe6Hy91cbFky5jsysDwfek+dVko65d+le2X SkQWlPNypXkUtAi8ng6OpaQCxPwuHZMkS9LF6wkkP8iNSQM6urmwHT5+PRyKw2ZRbiod ProROXlyIMHY79/drjKil2Ze/A/M1es+GoD109effD+/YD86SpN7dctJgPzVCCVfSq55 JgSQ== X-Gm-Message-State: AOJu0Yzyuz7Cvi2IGvlz/l0ZOHiGiZQgQxgSkXRnEs8wFq1/cWWP+lvA +g1FKuK7KR0EOqAiRjKx5Uglxw== X-Google-Smtp-Source: AGHT+IFg2V4Zc6AkX/O2Vatm+e9Hdj2bRElDVWnfsubinuJZpDwUdf4naqucfOoT5ylcVLFqP8VyGg== X-Received: by 2002:a05:600c:1c29:b0:406:5227:86f0 with SMTP id j41-20020a05600c1c2900b00406522786f0mr1644532wms.5.1697544330762; Tue, 17 Oct 2023 05:05:30 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:30 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 44/73] treewide: rename pinctrl_gpio_free_new() Date: Tue, 17 Oct 2023 14:04:02 +0200 Message-Id: <20231017120431.68847-45-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_free()() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-aspeed.c | 2 +- drivers/gpio/gpio-em.c | 2 +- drivers/gpio/gpio-rcar.c | 2 +- drivers/gpio/gpio-tegra.c | 2 +- drivers/gpio/gpiolib.c | 2 +- drivers/pinctrl/bcm/pinctrl-iproc-gpio.c | 2 +- drivers/pinctrl/core.c | 6 +++--- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 2 +- drivers/pinctrl/renesas/gpio.c | 2 +- drivers/pinctrl/renesas/pinctrl-rzg2l.c | 2 +- drivers/pinctrl/renesas/pinctrl-rzv2m.c | 2 +- drivers/pinctrl/spear/pinctrl-plgpio.c | 4 ++-- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 2 +- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 2 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- include/linux/pinctrl/consumer.h | 4 ++-- 17 files changed, 21 insertions(+), 21 deletions(-) diff --git a/drivers/gpio/gpio-aspeed.c b/drivers/gpio/gpio-aspeed.c index af851c89cacc..4c417c8486dd 100644 --- a/drivers/gpio/gpio-aspeed.c +++ b/drivers/gpio/gpio-aspeed.c @@ -755,7 +755,7 @@ static int aspeed_gpio_request(struct gpio_chip *chip, = unsigned int offset) =20 static void aspeed_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); } =20 static int usecs_to_cycles(struct aspeed_gpio *gpio, unsigned long usecs, diff --git a/drivers/gpio/gpio-em.c b/drivers/gpio/gpio-em.c index 08c5427deb71..aa31c189d0ef 100644 --- a/drivers/gpio/gpio-em.c +++ b/drivers/gpio/gpio-em.c @@ -234,7 +234,7 @@ static int em_gio_request(struct gpio_chip *chip, unsig= ned offset) =20 static void em_gio_free(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); =20 /* Set the GPIO as an input to ensure that the next GPIO request won't * drive the GPIO pin as an output. diff --git a/drivers/gpio/gpio-rcar.c b/drivers/gpio/gpio-rcar.c index 8c98730a7ad2..6159fda38d5d 100644 --- a/drivers/gpio/gpio-rcar.c +++ b/drivers/gpio/gpio-rcar.c @@ -286,7 +286,7 @@ static void gpio_rcar_free(struct gpio_chip *chip, unsi= gned offset) { struct gpio_rcar_priv *p =3D gpiochip_get_data(chip); =20 - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); =20 /* * Set the GPIO as an input to ensure that the next GPIO request won't diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index c974ba368d18..fcb3b474d1df 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -146,7 +146,7 @@ static void tegra_gpio_free(struct gpio_chip *chip, uns= igned int offset) { struct tegra_gpio_info *tgi =3D gpiochip_get_data(chip); =20 - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); tegra_gpio_disable(tgi, offset); } =20 diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 794408be7109..53dce41d649a 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -2052,7 +2052,7 @@ void gpiochip_generic_free(struct gpio_chip *gc, unsi= gned int offset) return; #endif =20 - pinctrl_gpio_free_new(gc, offset); + pinctrl_gpio_free(gc, offset); } EXPORT_SYMBOL_GPL(gpiochip_generic_free); =20 diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm= /pinctrl-iproc-gpio.c index 8162dd840933..fd5ce52d05b1 100644 --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c @@ -345,7 +345,7 @@ static void iproc_gpio_free(struct gpio_chip *gc, unsig= ned offset) if (!chip->pinmux_is_supported) return; =20 - pinctrl_gpio_free_new(gc, offset); + pinctrl_gpio_free(gc, offset); } =20 static int iproc_gpio_direction_input(struct gpio_chip *gc, unsigned gpio) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index d200a887dc5d..6872614c4a95 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -820,7 +820,7 @@ int pinctrl_gpio_request(struct gpio_chip *gc, unsigned= int offset) EXPORT_SYMBOL_GPL(pinctrl_gpio_request); =20 /** - * pinctrl_gpio_free_new() - free control on a single pin, currently used = as GPIO + * pinctrl_gpio_free() - free control on a single pin, currently used as G= PIO * @gc: GPIO chip structure from the GPIO subsystem * @offset: hardware offset of the GPIO relative to the controller * @@ -828,7 +828,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_request); * as part of their gpio_request() semantics, platforms and individual dri= vers * shall *NOT* request GPIO pins to be muxed in. */ -void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) +void pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offset) { struct pinctrl_gpio_range *range; struct pinctrl_dev *pctldev; @@ -848,7 +848,7 @@ void pinctrl_gpio_free_new(struct gpio_chip *gc, unsign= ed int offset) =20 mutex_unlock(&pctldev->mutex); } -EXPORT_SYMBOL_GPL(pinctrl_gpio_free_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_free); =20 static int pinctrl_gpio_direction(unsigned gpio, bool input) { diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index ad39b8c060b7..ab7cfc1e66f0 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -211,7 +211,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) { dev_dbg(chip->parent, "gpio_free: offset%d\n", offset); - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); } =20 static void npcmgpio_irq_handler(struct irq_desc *desc) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index dd4532ae62bf..78dbeef6af86 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -207,7 +207,7 @@ static int npcmgpio_gpio_request(struct gpio_chip *chip= , unsigned int offset) =20 static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); } =20 static void npcmgpio_irq_handler(struct irq_desc *desc) diff --git a/drivers/pinctrl/renesas/gpio.c b/drivers/pinctrl/renesas/gpio.c index 0c4f4d8d0891..b39125a632b0 100644 --- a/drivers/pinctrl/renesas/gpio.c +++ b/drivers/pinctrl/renesas/gpio.c @@ -140,7 +140,7 @@ static int gpio_pin_request(struct gpio_chip *gc, unsig= ned offset) =20 static void gpio_pin_free(struct gpio_chip *gc, unsigned offset) { - return pinctrl_gpio_free_new(gc, offset); + return pinctrl_gpio_free(gc, offset); } =20 static void gpio_pin_set_value(struct sh_pfc_chip *chip, unsigned offset, diff --git a/drivers/pinctrl/renesas/pinctrl-rzg2l.c b/drivers/pinctrl/rene= sas/pinctrl-rzg2l.c index c5d247d24374..9de350ad7e7d 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzg2l.c +++ b/drivers/pinctrl/renesas/pinctrl-rzg2l.c @@ -1181,7 +1181,7 @@ static void rzg2l_gpio_free(struct gpio_chip *chip, u= nsigned int offset) { unsigned int virq; =20 - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); =20 virq =3D irq_find_mapping(chip->irq.domain, offset); if (virq) diff --git a/drivers/pinctrl/renesas/pinctrl-rzv2m.c b/drivers/pinctrl/rene= sas/pinctrl-rzv2m.c index 1ec0922f735c..21d7d5ac8c4a 100644 --- a/drivers/pinctrl/renesas/pinctrl-rzv2m.c +++ b/drivers/pinctrl/renesas/pinctrl-rzv2m.c @@ -832,7 +832,7 @@ static int rzv2m_gpio_get(struct gpio_chip *chip, unsig= ned int offset) =20 static void rzv2m_gpio_free(struct gpio_chip *chip, unsigned int offset) { - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); =20 /* * Set the GPIO as an input to ensure that the next GPIO request won't diff --git a/drivers/pinctrl/spear/pinctrl-plgpio.c b/drivers/pinctrl/spear= /pinctrl-plgpio.c index 6d3b7ce1c35a..a05570c7d833 100644 --- a/drivers/pinctrl/spear/pinctrl-plgpio.c +++ b/drivers/pinctrl/spear/pinctrl-plgpio.c @@ -248,7 +248,7 @@ static int plgpio_request(struct gpio_chip *chip, unsig= ned offset) if (!IS_ERR(plgpio->clk)) clk_disable(plgpio->clk); err0: - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); return ret; } =20 @@ -278,7 +278,7 @@ static void plgpio_free(struct gpio_chip *chip, unsigne= d offset) if (!IS_ERR(plgpio->clk)) clk_disable(plgpio->clk); =20 - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); } =20 /* PLGPIO IRQ */ diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7100.c index 88e39f68ef25..7beed57d665a 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c @@ -923,7 +923,7 @@ static int starfive_gpio_request(struct gpio_chip *gc, = unsigned int gpio) =20 static void starfive_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free_new(gc, gpio); + pinctrl_gpio_free(gc, gpio); } =20 static int starfive_gpio_get_direction(struct gpio_chip *gc, unsigned int = gpio) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7110.c index c458c6fb992f..695c8c0a6e8b 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c @@ -552,7 +552,7 @@ static int jh7110_gpio_request(struct gpio_chip *gc, un= signed int gpio) =20 static void jh7110_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free_new(gc, gpio); + pinctrl_gpio_free(gc, gpio); } =20 static int jh7110_gpio_get_direction(struct gpio_chip *gc, diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index dddbdc1a64c5..e4453fa58f9e 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -222,7 +222,7 @@ static int stm32_gpio_request(struct gpio_chip *chip, u= nsigned offset) =20 static void stm32_gpio_free(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_free_new(chip, offset); + pinctrl_gpio_free(chip, offset); } =20 static int stm32_gpio_get(struct gpio_chip *chip, unsigned offset) diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 05b2dae05f24..55b465edaff1 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -28,7 +28,7 @@ struct pinctrl_state; /* External interface to pin control */ bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_request(struct gpio_chip *gc, unsigned int offset); -void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset); +void pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, @@ -80,7 +80,7 @@ pinctrl_gpio_request(struct gpio_chip *gc, unsigned int o= ffset) } =20 static inline void -pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset) +pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offset) { } =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0B34ACDB483 for ; Tue, 17 Oct 2023 12:41:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343652AbjJQMWE (ORCPT ); Tue, 17 Oct 2023 08:22:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235199AbjJQMVu (ORCPT ); Tue, 17 Oct 2023 08:21:50 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 70B4D1FDC for ; Tue, 17 Oct 2023 05:05:33 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-40837ebba42so824455e9.0 for ; Tue, 17 Oct 2023 05:05:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544331; x=1698149131; darn=vger.kernel.org; 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=qvcpVfHBT1ioZV4rtJYhpr2yYteam0jg6LilLlpkpAQ=; b=ByNoGA6g+KZLZ1Thdh2u333n5fIQHNONL6VDQYmDngMxgwrohqMnWmJRasVG2v9Hg1 2Nuogw1Rs2TReFdCjvIRe9WVFZ1Ec9EN8pBp/w1a3Y1qiv4zOZzsigXYw1b5/3f7XecK VfjmIjCg/6BODDOTe4xb8UHMr2t3c/DrFYc/AEcU/NoRmf4BzV/eMQw7ntdEVZldXeCy GOGe+3jDpYSvsX25myi/fOVeypDSbwPYNjIDlN+Q48LczAPbAEaB3p0WlPB5bnvEQD7d 9Y7qa7Z5hUWL+u3rw6RQsKpzBsjUCYvOFVhvKsABPsajCmNZHhjoolyi352U5ohN3/hv ufCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544331; x=1698149131; 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=qvcpVfHBT1ioZV4rtJYhpr2yYteam0jg6LilLlpkpAQ=; b=jMUP9r4EBRtNw+X+K/7SDwybEqsRmP/ByFXjag6yomxtf6BXrec5Z1l+Dh2k3yh14Y G6r3jbuXss0XVrXn3ha/5ki01AWX8atseIuJhybkCoWFAsbeVymG20KDPjOCzLc1M5fx xxxYZ5lNvmlBoPm0RsTZFsDzTbToyAgBOPf1oL+FsG+BRit1W7XjC28FmKytjD6b/Max K03W9zk31/ZS9R8zEwK4W2KcbxscdAwxUev9FfS1YcUOw1U6eQYUeUB+C/7XQyncYDr/ JbCNRolRj04IC2R8UF5fD52fMcRTPUbtjjUB2Bxn3j37yBPzg9bsdefD0QL8VXGnsbr4 x9Tw== X-Gm-Message-State: AOJu0YyUhFCy8cdqcBsCLA6IIThhfz1XXVyMrVGi0w0vPTW8SCN4gmcF hKvYfJYbeCPeK7URnyMx7hc8ew== X-Google-Smtp-Source: AGHT+IEdpHNoEPbxCgAIi2ENMc5sDcdMwGKQ85LmL1s6Z47xEo1PPTlnhpR2eRjOvLTqA0ljLAmrWQ== X-Received: by 2002:a05:600c:4e8f:b0:406:545a:f8fe with SMTP id f15-20020a05600c4e8f00b00406545af8femr1578699wmq.29.1697544331697; Tue, 17 Oct 2023 05:05:31 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:31 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 45/73] treewide: rename pinctrl_gpio_direction_input_new() Date: Tue, 17 Oct 2023 14:04:03 +0200 Message-Id: <20231017120431.68847-46-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_direction_input() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-mvebu.c | 2 +- drivers/gpio/gpio-pxa.c | 2 +- drivers/gpio/gpio-rockchip.c | 2 +- drivers/gpio/gpio-tegra.c | 2 +- drivers/gpio/gpio-vf610.c | 2 +- drivers/pinctrl/cirrus/pinctrl-cs42l43.c | 2 +- drivers/pinctrl/core.c | 6 +++--- drivers/pinctrl/intel/pinctrl-cherryview.c | 2 +- drivers/pinctrl/intel/pinctrl-intel.c | 2 +- drivers/pinctrl/intel/pinctrl-lynxpoint.c | 2 +- drivers/pinctrl/mediatek/pinctrl-moore.c | 2 +- drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 2 +- drivers/pinctrl/mediatek/pinctrl-paris.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 2 +- drivers/pinctrl/pinctrl-as3722.c | 2 +- drivers/pinctrl/pinctrl-axp209.c | 2 +- drivers/pinctrl/pinctrl-cy8c95x0.c | 2 +- drivers/pinctrl/pinctrl-ingenic.c | 2 +- drivers/pinctrl/pinctrl-ocelot.c | 2 +- drivers/pinctrl/pinctrl-rk805.c | 2 +- drivers/pinctrl/pinctrl-st.c | 2 +- drivers/pinctrl/renesas/gpio.c | 2 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- drivers/pinctrl/vt8500/pinctrl-wmt.c | 2 +- include/linux/pinctrl/consumer.h | 6 +++--- 26 files changed, 30 insertions(+), 30 deletions(-) diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c index c0ca0aa7b5cd..159a302486ac 100644 --- a/drivers/gpio/gpio-mvebu.c +++ b/drivers/gpio/gpio-mvebu.c @@ -346,7 +346,7 @@ static int mvebu_gpio_direction_input(struct gpio_chip = *chip, unsigned int pin) * Check with the pinctrl driver whether this pin is usable as * an input GPIO */ - ret =3D pinctrl_gpio_direction_input_new(chip, pin); + ret =3D pinctrl_gpio_direction_input(chip, pin); if (ret) return ret; =20 diff --git a/drivers/gpio/gpio-pxa.c b/drivers/gpio/gpio-pxa.c index 2fd797b91270..c60197d5fde0 100644 --- a/drivers/gpio/gpio-pxa.c +++ b/drivers/gpio/gpio-pxa.c @@ -260,7 +260,7 @@ static int pxa_gpio_direction_input(struct gpio_chip *c= hip, unsigned offset) int ret; =20 if (pxa_gpio_has_pinctrl()) { - ret =3D pinctrl_gpio_direction_input_new(chip, offset); + ret =3D pinctrl_gpio_direction_input(chip, offset); if (ret) return ret; } diff --git a/drivers/gpio/gpio-rockchip.c b/drivers/gpio/gpio-rockchip.c index 3576793f0bd9..05afb67fd677 100644 --- a/drivers/gpio/gpio-rockchip.c +++ b/drivers/gpio/gpio-rockchip.c @@ -159,7 +159,7 @@ static int rockchip_gpio_set_direction(struct gpio_chip= *chip, =20 =20 if (input) - pinctrl_gpio_direction_input_new(chip, offset); + pinctrl_gpio_direction_input(chip, offset); else pinctrl_gpio_direction_output_new(chip, offset); =20 diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index fcb3b474d1df..a9a00b28cc55 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -179,7 +179,7 @@ static int tegra_gpio_direction_input(struct gpio_chip = *chip, tegra_gpio_mask_write(tgi, GPIO_MSK_OE(tgi, offset), offset, 0); tegra_gpio_enable(tgi, offset); =20 - ret =3D pinctrl_gpio_direction_input_new(chip, offset); + ret =3D pinctrl_gpio_direction_input(chip, offset); if (ret < 0) dev_err(tgi->dev, "Failed to set pinctrl input direction of GPIO %d: %d", diff --git a/drivers/gpio/gpio-vf610.c b/drivers/gpio/gpio-vf610.c index 2c22a31ffbdc..fd1c06abb5a7 100644 --- a/drivers/gpio/gpio-vf610.c +++ b/drivers/gpio/gpio-vf610.c @@ -130,7 +130,7 @@ static int vf610_gpio_direction_input(struct gpio_chip = *chip, unsigned gpio) vf610_gpio_writel(val, port->gpio_base + GPIO_PDDR); } =20 - return pinctrl_gpio_direction_input_new(chip, gpio); + return pinctrl_gpio_direction_input(chip, gpio); } =20 static int vf610_gpio_direction_output(struct gpio_chip *chip, unsigned gp= io, diff --git a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c b/drivers/pinctrl/cir= rus/pinctrl-cs42l43.c index 097e4dcdda36..e35964359381 100644 --- a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c +++ b/drivers/pinctrl/cirrus/pinctrl-cs42l43.c @@ -508,7 +508,7 @@ static void cs42l43_gpio_set(struct gpio_chip *chip, un= signed int offset, int va =20 static int cs42l43_gpio_direction_in(struct gpio_chip *chip, unsigned int = offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int cs42l43_gpio_direction_out(struct gpio_chip *chip, diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 6872614c4a95..242357f96238 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -874,7 +874,7 @@ static int pinctrl_gpio_direction(unsigned gpio, bool i= nput) } =20 /** - * pinctrl_gpio_direction_input_new() - request a GPIO pin to go into inpu= t mode + * pinctrl_gpio_direction_input() - request a GPIO pin to go into input mo= de * @gc: GPIO chip structure from the GPIO subsystem * @offset: hardware offset of the GPIO relative to the controller * @@ -882,11 +882,11 @@ static int pinctrl_gpio_direction(unsigned gpio, bool= input) * as part of their gpio_direction_input() semantics, platforms and indivi= dual * drivers shall *NOT* touch pin control GPIO calls. */ -int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int of= fset) +int pinctrl_gpio_direction_input(struct gpio_chip *gc, unsigned int offset) { return pinctrl_gpio_direction(gc->base + offset, true); } -EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); =20 /** * pinctrl_gpio_direction_output_new() - request a GPIO pin to go into out= put diff --git a/drivers/pinctrl/intel/pinctrl-cherryview.c b/drivers/pinctrl/i= ntel/pinctrl-cherryview.c index f806b7ce086b..baf32a8156c4 100644 --- a/drivers/pinctrl/intel/pinctrl-cherryview.c +++ b/drivers/pinctrl/intel/pinctrl-cherryview.c @@ -1148,7 +1148,7 @@ static int chv_gpio_get_direction(struct gpio_chip *c= hip, unsigned int offset) =20 static int chv_gpio_direction_input(struct gpio_chip *chip, unsigned int o= ffset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int chv_gpio_direction_output(struct gpio_chip *chip, unsigned int = offset, diff --git a/drivers/pinctrl/intel/pinctrl-intel.c b/drivers/pinctrl/intel/= pinctrl-intel.c index f403eb78f355..2b0d418418f2 100644 --- a/drivers/pinctrl/intel/pinctrl-intel.c +++ b/drivers/pinctrl/intel/pinctrl-intel.c @@ -992,7 +992,7 @@ static int intel_gpio_get_direction(struct gpio_chip *c= hip, unsigned int offset) =20 static int intel_gpio_direction_input(struct gpio_chip *chip, unsigned int= offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int intel_gpio_direction_output(struct gpio_chip *chip, unsigned in= t offset, diff --git a/drivers/pinctrl/intel/pinctrl-lynxpoint.c b/drivers/pinctrl/in= tel/pinctrl-lynxpoint.c index 91d228fead45..b4174829e1f9 100644 --- a/drivers/pinctrl/intel/pinctrl-lynxpoint.c +++ b/drivers/pinctrl/intel/pinctrl-lynxpoint.c @@ -541,7 +541,7 @@ static void lp_gpio_set(struct gpio_chip *chip, unsigne= d int offset, int value) =20 static int lp_gpio_direction_input(struct gpio_chip *chip, unsigned int of= fset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int lp_gpio_direction_output(struct gpio_chip *chip, unsigned int o= ffset, diff --git a/drivers/pinctrl/mediatek/pinctrl-moore.c b/drivers/pinctrl/med= iatek/pinctrl-moore.c index dc41ffa31357..5a5ec00e32ea 100644 --- a/drivers/pinctrl/mediatek/pinctrl-moore.c +++ b/drivers/pinctrl/mediatek/pinctrl-moore.c @@ -512,7 +512,7 @@ static void mtk_gpio_set(struct gpio_chip *chip, unsign= ed int gpio, int value) =20 static int mtk_gpio_direction_input(struct gpio_chip *chip, unsigned int g= pio) { - return pinctrl_gpio_direction_input_new(chip, gpio); + return pinctrl_gpio_direction_input(chip, gpio); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned int = gpio, diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c b/drivers/pinctr= l/mediatek/pinctrl-mtk-common.c index fc046415b567..b2dc3072050a 100644 --- a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c +++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common.c @@ -811,7 +811,7 @@ static const struct pinmux_ops mtk_pmx_ops =3D { static int mtk_gpio_direction_input(struct gpio_chip *chip, unsigned offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, diff --git a/drivers/pinctrl/mediatek/pinctrl-paris.c b/drivers/pinctrl/med= iatek/pinctrl-paris.c index 14b151aec2f9..d8c969e506ce 100644 --- a/drivers/pinctrl/mediatek/pinctrl-paris.c +++ b/drivers/pinctrl/mediatek/pinctrl-paris.c @@ -916,7 +916,7 @@ static int mtk_gpio_direction_input(struct gpio_chip *c= hip, unsigned int gpio) if (gpio >=3D hw->soc->npins) return -EINVAL; =20 - return pinctrl_gpio_direction_input_new(chip, gpio); + return pinctrl_gpio_direction_input(chip, gpio); } =20 static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned int = gpio, diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index ab7cfc1e66f0..d7ce67242248 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -171,7 +171,7 @@ static int npcmgpio_direction_input(struct gpio_chip *c= hip, unsigned int offset) struct npcm7xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_input_new(chip, offset); + ret =3D pinctrl_gpio_direction_input(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index 78dbeef6af86..c22513e30068 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -173,7 +173,7 @@ static int npcmgpio_direction_input(struct gpio_chip *c= hip, unsigned int offset) struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_input_new(chip, offset); + ret =3D pinctrl_gpio_direction_input(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/pinctrl-as3722.c b/drivers/pinctrl/pinctrl-as3= 722.c index 205937f7f9a1..e77b180155f4 100644 --- a/drivers/pinctrl/pinctrl-as3722.c +++ b/drivers/pinctrl/pinctrl-as3722.c @@ -502,7 +502,7 @@ static void as3722_gpio_set(struct gpio_chip *chip, uns= igned offset, =20 static int as3722_gpio_direction_input(struct gpio_chip *chip, unsigned of= fset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int as3722_gpio_direction_output(struct gpio_chip *chip, diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp= 209.c index d7f081f1d1f6..a6eb3b866a23 100644 --- a/drivers/pinctrl/pinctrl-axp209.c +++ b/drivers/pinctrl/pinctrl-axp209.c @@ -126,7 +126,7 @@ static int axp20x_gpio_get_reg(unsigned int offset) =20 static int axp20x_gpio_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int axp20x_gpio_get(struct gpio_chip *chip, unsigned int offset) diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-c= y8c95x0.c index 8c6006353515..729c13a249ef 100644 --- a/drivers/pinctrl/pinctrl-cy8c95x0.c +++ b/drivers/pinctrl/pinctrl-cy8c95x0.c @@ -554,7 +554,7 @@ static int cy8c95x0_read_regs_mask(struct cy8c95x0_pinc= trl *chip, int reg, =20 static int cy8c95x0_gpio_direction_input(struct gpio_chip *gc, unsigned in= t off) { - return pinctrl_gpio_direction_input_new(gc, off); + return pinctrl_gpio_direction_input(gc, off); } =20 static int cy8c95x0_gpio_direction_output(struct gpio_chip *gc, diff --git a/drivers/pinctrl/pinctrl-ingenic.c b/drivers/pinctrl/pinctrl-in= genic.c index 5072fb907193..df36141edbf3 100644 --- a/drivers/pinctrl/pinctrl-ingenic.c +++ b/drivers/pinctrl/pinctrl-ingenic.c @@ -3563,7 +3563,7 @@ static int ingenic_gpio_get(struct gpio_chip *gc, uns= igned int offset) static int ingenic_gpio_direction_input(struct gpio_chip *gc, unsigned int offset) { - return pinctrl_gpio_direction_input_new(gc, offset); + return pinctrl_gpio_direction_input(gc, offset); } =20 static int ingenic_gpio_direction_output(struct gpio_chip *gc, diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-oce= lot.c index a6022d44ad6c..d02d16084f33 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1779,7 +1779,7 @@ static int ocelot_gpio_get_direction(struct gpio_chip= *chip, static int ocelot_gpio_direction_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int ocelot_gpio_direction_output(struct gpio_chip *chip, diff --git a/drivers/pinctrl/pinctrl-rk805.c b/drivers/pinctrl/pinctrl-rk80= 5.c index 58e6dd932bc7..f0feb3a8e630 100644 --- a/drivers/pinctrl/pinctrl-rk805.c +++ b/drivers/pinctrl/pinctrl-rk805.c @@ -289,7 +289,7 @@ static void rk805_gpio_set(struct gpio_chip *chip, static int rk805_gpio_direction_input(struct gpio_chip *chip, unsigned int offset) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int rk805_gpio_direction_output(struct gpio_chip *chip, diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c index ec763572ab3e..3f6631716779 100644 --- a/drivers/pinctrl/pinctrl-st.c +++ b/drivers/pinctrl/pinctrl-st.c @@ -719,7 +719,7 @@ static void st_gpio_set(struct gpio_chip *chip, unsigne= d offset, int value) =20 static int st_gpio_direction_input(struct gpio_chip *chip, unsigned offset) { - pinctrl_gpio_direction_input_new(chip, offset); + pinctrl_gpio_direction_input(chip, offset); =20 return 0; } diff --git a/drivers/pinctrl/renesas/gpio.c b/drivers/pinctrl/renesas/gpio.c index b39125a632b0..54346b7fcdef 100644 --- a/drivers/pinctrl/renesas/gpio.c +++ b/drivers/pinctrl/renesas/gpio.c @@ -164,7 +164,7 @@ static void gpio_pin_set_value(struct sh_pfc_chip *chip= , unsigned offset, =20 static int gpio_pin_direction_input(struct gpio_chip *gc, unsigned offset) { - return pinctrl_gpio_direction_input_new(gc, offset); + return pinctrl_gpio_direction_input(gc, offset); } =20 static int gpio_pin_direction_output(struct gpio_chip *gc, unsigned offset, diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index e4453fa58f9e..cbe306f47c0a 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -241,7 +241,7 @@ static void stm32_gpio_set(struct gpio_chip *chip, unsi= gned offset, int value) =20 static int stm32_gpio_direction_input(struct gpio_chip *chip, unsigned off= set) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int stm32_gpio_direction_output(struct gpio_chip *chip, diff --git a/drivers/pinctrl/vt8500/pinctrl-wmt.c b/drivers/pinctrl/vt8500/= pinctrl-wmt.c index 1a313295611e..54cd556a16b8 100644 --- a/drivers/pinctrl/vt8500/pinctrl-wmt.c +++ b/drivers/pinctrl/vt8500/pinctrl-wmt.c @@ -528,7 +528,7 @@ static void wmt_gpio_set_value(struct gpio_chip *chip, = unsigned offset, =20 static int wmt_gpio_direction_input(struct gpio_chip *chip, unsigned offse= t) { - return pinctrl_gpio_direction_input_new(chip, offset); + return pinctrl_gpio_direction_input(chip, offset); } =20 static int wmt_gpio_direction_output(struct gpio_chip *chip, unsigned offs= et, diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 55b465edaff1..9531595d1abd 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -29,8 +29,8 @@ struct pinctrl_state; bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_request(struct gpio_chip *gc, unsigned int offset); void pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_direction_input_new(struct gpio_chip *gc, - unsigned int offset); +int pinctrl_gpio_direction_input(struct gpio_chip *gc, + unsigned int offset); int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, @@ -85,7 +85,7 @@ pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offs= et) } =20 static inline int -pinctrl_gpio_direction_input_new(struct gpio_chip *gc, unsigned int offset) +pinctrl_gpio_direction_input(struct gpio_chip *gc, unsigned int offset) { return 0; } --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E85A4CDB474 for ; Tue, 17 Oct 2023 12:07:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232907AbjJQMHy (ORCPT ); Tue, 17 Oct 2023 08:07:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43432 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343599AbjJQMHF (ORCPT ); Tue, 17 Oct 2023 08:07:05 -0400 Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 958C51FE3 for ; Tue, 17 Oct 2023 05:05:34 -0700 (PDT) Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-32da4ffd7e5so1821545f8f.0 for ; Tue, 17 Oct 2023 05:05:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544333; x=1698149133; darn=vger.kernel.org; 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=IgEzgtHzG8N8G+CkiEotPXz+q9aJqznix46yYuhbqa4=; b=VYFAHVvkJilZpcT8z1X+vJoMwCmV5eMvoVD923p1H9i1+BQbffc/ZPTLW5zbxBU0ze bnwkkc3M2dsPN2y/mwlqGuvZgcDmkVv+mYMURNVTiuoPEKIKJVURqQFl8DJtM4hIyGjl 0l5qziyIpnt7wjw6OhT9i+OhQOrlScAxsQppX2g5SItGdR3wD2F5CBP4hk1xPqUsaB2l nEHiv30qD+senvlzzy7GLq4rn9vpqegRBFip9+yvxRL6yktgGCnP8bCXINXuG3zm1zTL uhnkfM80pYgMIQXD1QAIbbYMTO7nU8stMVW+/JuHlrCT5lfA8YDIcO4qZnXAg+JLWrY+ XaDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544333; x=1698149133; 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=IgEzgtHzG8N8G+CkiEotPXz+q9aJqznix46yYuhbqa4=; b=gXCaQV94n48exB+tKaJ2XcAqDssFG//halzdyIB+/4hMQ5qCRUMQAyvyEpZiOAZvik KNn46uYj/5g2WNOhbFNCEWGEofUtBpRWsmnyfTMeR4M8ZddcXa/JexmMqh9PrNJSvUte tJA6yntFBPscEbMkZQke7JtbwNLfreg8sr3dlOE1TZXD3UysSLjLE2zxdr7LLZ720ceY Y+Qm+AlVGzSI5t8KgTLcgJShan9DRwcQZprfPShN+8nGY3IxjP9ISijpRfpMEX+k1aRq k+EY6pWWjCt8KuFXUtLKUJYElE2Xa4zpDo7yFneOw5tAfp+J/GJWO8IKw3yyfrQzbc+L d0Mw== X-Gm-Message-State: AOJu0YwfTlRzAzhaMUmXE1JW6JC75G7R4wvlnRJUCeN7lNUfzybE83uz YgoTmWG/vOCI/yteNr3AbNWuQg== X-Google-Smtp-Source: AGHT+IH+B9Hp06oTxN6Yofmqzqxhoge/34JZeZvk585UPynzGfFuY7+gCeWEBJYo9tHJTcVxfd3QBA== X-Received: by 2002:a05:6000:114a:b0:32d:c8a4:84be with SMTP id d10-20020a056000114a00b0032dc8a484bemr1108864wrx.33.1697544332722; Tue, 17 Oct 2023 05:05:32 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:32 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 46/73] treewide: rename pinctrl_gpio_direction_output_new() Date: Tue, 17 Oct 2023 14:04:04 +0200 Message-Id: <20231017120431.68847-47-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_direction_output() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-mvebu.c | 2 +- drivers/gpio/gpio-pxa.c | 2 +- drivers/gpio/gpio-rockchip.c | 2 +- drivers/gpio/gpio-tegra.c | 2 +- drivers/gpio/gpio-vf610.c | 2 +- drivers/pinctrl/cirrus/pinctrl-cs42l43.c | 2 +- drivers/pinctrl/cirrus/pinctrl-lochnagar.c | 2 +- drivers/pinctrl/core.c | 7 +++---- drivers/pinctrl/intel/pinctrl-cherryview.c | 2 +- drivers/pinctrl/intel/pinctrl-intel.c | 2 +- drivers/pinctrl/intel/pinctrl-lynxpoint.c | 2 +- drivers/pinctrl/mediatek/pinctrl-moore.c | 2 +- drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 2 +- drivers/pinctrl/mediatek/pinctrl-paris.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 2 +- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 2 +- drivers/pinctrl/pinctrl-as3722.c | 2 +- drivers/pinctrl/pinctrl-cy8c95x0.c | 2 +- drivers/pinctrl/pinctrl-ingenic.c | 4 ++-- drivers/pinctrl/pinctrl-ocelot.c | 2 +- drivers/pinctrl/pinctrl-rk805.c | 2 +- drivers/pinctrl/pinctrl-st.c | 2 +- drivers/pinctrl/renesas/gpio.c | 2 +- drivers/pinctrl/stm32/pinctrl-stm32.c | 2 +- drivers/pinctrl/vt8500/pinctrl-wmt.c | 2 +- include/linux/pinctrl/consumer.h | 6 +++--- 26 files changed, 31 insertions(+), 32 deletions(-) diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c index 159a302486ac..a13f3c18ccd4 100644 --- a/drivers/gpio/gpio-mvebu.c +++ b/drivers/gpio/gpio-mvebu.c @@ -366,7 +366,7 @@ static int mvebu_gpio_direction_output(struct gpio_chip= *chip, unsigned int pin, * Check with the pinctrl driver whether this pin is usable as * an output GPIO */ - ret =3D pinctrl_gpio_direction_output_new(chip, pin); + ret =3D pinctrl_gpio_direction_output(chip, pin); if (ret) return ret; =20 diff --git a/drivers/gpio/gpio-pxa.c b/drivers/gpio/gpio-pxa.c index c60197d5fde0..91cea97255fa 100644 --- a/drivers/gpio/gpio-pxa.c +++ b/drivers/gpio/gpio-pxa.c @@ -289,7 +289,7 @@ static int pxa_gpio_direction_output(struct gpio_chip *= chip, writel_relaxed(mask, base + (value ? GPSR_OFFSET : GPCR_OFFSET)); =20 if (pxa_gpio_has_pinctrl()) { - ret =3D pinctrl_gpio_direction_output_new(chip, offset); + ret =3D pinctrl_gpio_direction_output(chip, offset); if (ret) return ret; } diff --git a/drivers/gpio/gpio-rockchip.c b/drivers/gpio/gpio-rockchip.c index 05afb67fd677..0bd339813110 100644 --- a/drivers/gpio/gpio-rockchip.c +++ b/drivers/gpio/gpio-rockchip.c @@ -161,7 +161,7 @@ static int rockchip_gpio_set_direction(struct gpio_chip= *chip, if (input) pinctrl_gpio_direction_input(chip, offset); else - pinctrl_gpio_direction_output_new(chip, offset); + pinctrl_gpio_direction_output(chip, offset); =20 raw_spin_lock_irqsave(&bank->slock, flags); rockchip_gpio_writel_bit(bank, offset, data, bank->gpio_regs->port_ddr); diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index a9a00b28cc55..adfbed62eff1 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -199,7 +199,7 @@ static int tegra_gpio_direction_output(struct gpio_chip= *chip, tegra_gpio_mask_write(tgi, GPIO_MSK_OE(tgi, offset), offset, 1); tegra_gpio_enable(tgi, offset); =20 - ret =3D pinctrl_gpio_direction_output_new(chip, offset); + ret =3D pinctrl_gpio_direction_output(chip, offset); if (ret < 0) dev_err(tgi->dev, "Failed to set pinctrl output direction of GPIO %d: %d", diff --git a/drivers/gpio/gpio-vf610.c b/drivers/gpio/gpio-vf610.c index fd1c06abb5a7..e3427a6aecff 100644 --- a/drivers/gpio/gpio-vf610.c +++ b/drivers/gpio/gpio-vf610.c @@ -148,7 +148,7 @@ static int vf610_gpio_direction_output(struct gpio_chip= *chip, unsigned gpio, =20 vf610_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output_new(chip, gpio); + return pinctrl_gpio_direction_output(chip, gpio); } =20 static void vf610_gpio_irq_handler(struct irq_desc *desc) diff --git a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c b/drivers/pinctrl/cir= rus/pinctrl-cs42l43.c index e35964359381..1ba89cf279fb 100644 --- a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c +++ b/drivers/pinctrl/cirrus/pinctrl-cs42l43.c @@ -516,7 +516,7 @@ static int cs42l43_gpio_direction_out(struct gpio_chip = *chip, { cs42l43_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int cs42l43_gpio_add_pin_ranges(struct gpio_chip *chip) diff --git a/drivers/pinctrl/cirrus/pinctrl-lochnagar.c b/drivers/pinctrl/c= irrus/pinctrl-lochnagar.c index f3c8a8c14e14..014297a3fbd2 100644 --- a/drivers/pinctrl/cirrus/pinctrl-lochnagar.c +++ b/drivers/pinctrl/cirrus/pinctrl-lochnagar.c @@ -1098,7 +1098,7 @@ static int lochnagar_gpio_direction_out(struct gpio_c= hip *chip, { lochnagar_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int lochnagar_fill_func_groups(struct lochnagar_pin_priv *priv) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 242357f96238..0c2c18536242 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -889,8 +889,7 @@ int pinctrl_gpio_direction_input(struct gpio_chip *gc, = unsigned int offset) EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); =20 /** - * pinctrl_gpio_direction_output_new() - request a GPIO pin to go into out= put - * mode + * pinctrl_gpio_direction_output() - request a GPIO pin to go into output = mode * @gc: GPIO chip structure from the GPIO subsystem * @offset: hardware offset of the GPIO relative to the controller * @@ -898,11 +897,11 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); * as part of their gpio_direction_output() semantics, platforms and indiv= idual * drivers shall *NOT* touch pin control GPIO calls. */ -int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int o= ffset) +int pinctrl_gpio_direction_output(struct gpio_chip *gc, unsigned int offse= t) { return pinctrl_gpio_direction(gc->base + offset, false); } -EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); =20 /** * pinctrl_gpio_set_config_new() - Apply config to given GPIO pin diff --git a/drivers/pinctrl/intel/pinctrl-cherryview.c b/drivers/pinctrl/i= ntel/pinctrl-cherryview.c index baf32a8156c4..067b0d344f0e 100644 --- a/drivers/pinctrl/intel/pinctrl-cherryview.c +++ b/drivers/pinctrl/intel/pinctrl-cherryview.c @@ -1155,7 +1155,7 @@ static int chv_gpio_direction_output(struct gpio_chip= *chip, unsigned int offset int value) { chv_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static const struct gpio_chip chv_gpio_chip =3D { diff --git a/drivers/pinctrl/intel/pinctrl-intel.c b/drivers/pinctrl/intel/= pinctrl-intel.c index 2b0d418418f2..0f8e27d16929 100644 --- a/drivers/pinctrl/intel/pinctrl-intel.c +++ b/drivers/pinctrl/intel/pinctrl-intel.c @@ -999,7 +999,7 @@ static int intel_gpio_direction_output(struct gpio_chip= *chip, unsigned int offs int value) { intel_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static const struct gpio_chip intel_gpio_chip =3D { diff --git a/drivers/pinctrl/intel/pinctrl-lynxpoint.c b/drivers/pinctrl/in= tel/pinctrl-lynxpoint.c index b4174829e1f9..e6878e4cf20c 100644 --- a/drivers/pinctrl/intel/pinctrl-lynxpoint.c +++ b/drivers/pinctrl/intel/pinctrl-lynxpoint.c @@ -549,7 +549,7 @@ static int lp_gpio_direction_output(struct gpio_chip *c= hip, unsigned int offset, { lp_gpio_set(chip, offset, value); =20 - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int lp_gpio_get_direction(struct gpio_chip *chip, unsigned int offs= et) diff --git a/drivers/pinctrl/mediatek/pinctrl-moore.c b/drivers/pinctrl/med= iatek/pinctrl-moore.c index 5a5ec00e32ea..c3f33f96f920 100644 --- a/drivers/pinctrl/mediatek/pinctrl-moore.c +++ b/drivers/pinctrl/mediatek/pinctrl-moore.c @@ -520,7 +520,7 @@ static int mtk_gpio_direction_output(struct gpio_chip *= chip, unsigned int gpio, { mtk_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output_new(chip, gpio); + return pinctrl_gpio_direction_output(chip, gpio); } =20 static int mtk_gpio_to_irq(struct gpio_chip *chip, unsigned int offset) diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c b/drivers/pinctr= l/mediatek/pinctrl-mtk-common.c index b2dc3072050a..41e9847e3085 100644 --- a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c +++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common.c @@ -818,7 +818,7 @@ static int mtk_gpio_direction_output(struct gpio_chip *= chip, unsigned offset, int value) { mtk_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int mtk_gpio_get_direction(struct gpio_chip *chip, unsigned offset) diff --git a/drivers/pinctrl/mediatek/pinctrl-paris.c b/drivers/pinctrl/med= iatek/pinctrl-paris.c index d8c969e506ce..6392f1e05d02 100644 --- a/drivers/pinctrl/mediatek/pinctrl-paris.c +++ b/drivers/pinctrl/mediatek/pinctrl-paris.c @@ -929,7 +929,7 @@ static int mtk_gpio_direction_output(struct gpio_chip *= chip, unsigned int gpio, =20 mtk_gpio_set(chip, gpio, value); =20 - return pinctrl_gpio_direction_output_new(chip, gpio); + return pinctrl_gpio_direction_output(chip, gpio); } =20 static int mtk_gpio_to_irq(struct gpio_chip *chip, unsigned int offset) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index d7ce67242248..51aeac7ecc79 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -188,7 +188,7 @@ static int npcmgpio_direction_output(struct gpio_chip *= chip, dev_dbg(chip->parent, "gpio_direction_output: offset%d =3D %x\n", offset, value); =20 - ret =3D pinctrl_gpio_direction_output_new(chip, offset); + ret =3D pinctrl_gpio_direction_output(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index c22513e30068..140fdbbe8458 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -186,7 +186,7 @@ static int npcmgpio_direction_output(struct gpio_chip *= chip, struct npcm8xx_gpio *bank =3D gpiochip_get_data(chip); int ret; =20 - ret =3D pinctrl_gpio_direction_output_new(chip, offset); + ret =3D pinctrl_gpio_direction_output(chip, offset); if (ret) return ret; =20 diff --git a/drivers/pinctrl/pinctrl-as3722.c b/drivers/pinctrl/pinctrl-as3= 722.c index e77b180155f4..5ebd1939663f 100644 --- a/drivers/pinctrl/pinctrl-as3722.c +++ b/drivers/pinctrl/pinctrl-as3722.c @@ -509,7 +509,7 @@ static int as3722_gpio_direction_output(struct gpio_chi= p *chip, unsigned offset, int value) { as3722_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int as3722_gpio_to_irq(struct gpio_chip *chip, unsigned offset) diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-c= y8c95x0.c index 729c13a249ef..04285c930e94 100644 --- a/drivers/pinctrl/pinctrl-cy8c95x0.c +++ b/drivers/pinctrl/pinctrl-cy8c95x0.c @@ -571,7 +571,7 @@ static int cy8c95x0_gpio_direction_output(struct gpio_c= hip *gc, if (ret) return ret; =20 - return pinctrl_gpio_direction_output_new(gc, off); + return pinctrl_gpio_direction_output(gc, off); } =20 static int cy8c95x0_gpio_get_value(struct gpio_chip *gc, unsigned int off) diff --git a/drivers/pinctrl/pinctrl-ingenic.c b/drivers/pinctrl/pinctrl-in= genic.c index df36141edbf3..ca58c9db5c2c 100644 --- a/drivers/pinctrl/pinctrl-ingenic.c +++ b/drivers/pinctrl/pinctrl-ingenic.c @@ -3570,7 +3570,7 @@ static int ingenic_gpio_direction_output(struct gpio_= chip *gc, unsigned int offset, int value) { ingenic_gpio_set(gc, offset, value); - return pinctrl_gpio_direction_output_new(gc, offset); + return pinctrl_gpio_direction_output(gc, offset); } =20 static inline void ingenic_config_pin(struct ingenic_pinctrl *jzpc, @@ -4054,7 +4054,7 @@ static int ingenic_pinconf_set(struct pinctrl_dev *pc= tldev, unsigned int pin, break; =20 case PIN_CONFIG_OUTPUT: - ret =3D pinctrl_gpio_direction_output_new(jzpc->gc, + ret =3D pinctrl_gpio_direction_output(jzpc->gc, pin - jzpc->gc->base); if (ret) return ret; diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-oce= lot.c index d02d16084f33..96b4e9fceb78 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1795,7 +1795,7 @@ static int ocelot_gpio_direction_output(struct gpio_c= hip *chip, regmap_write(info->map, REG(OCELOT_GPIO_OUT_CLR, info, offset), pin); =20 - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static const struct gpio_chip ocelot_gpiolib_chip =3D { diff --git a/drivers/pinctrl/pinctrl-rk805.c b/drivers/pinctrl/pinctrl-rk80= 5.c index f0feb3a8e630..968f066eb9da 100644 --- a/drivers/pinctrl/pinctrl-rk805.c +++ b/drivers/pinctrl/pinctrl-rk805.c @@ -296,7 +296,7 @@ static int rk805_gpio_direction_output(struct gpio_chip= *chip, unsigned int offset, int value) { rk805_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static int rk805_gpio_get_direction(struct gpio_chip *chip, unsigned int o= ffset) diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c index 3f6631716779..db511dbd50e5 100644 --- a/drivers/pinctrl/pinctrl-st.c +++ b/drivers/pinctrl/pinctrl-st.c @@ -730,7 +730,7 @@ static int st_gpio_direction_output(struct gpio_chip *c= hip, struct st_gpio_bank *bank =3D gpiochip_get_data(chip); =20 __st_gpio_set(bank, offset, value); - pinctrl_gpio_direction_output_new(chip, offset); + pinctrl_gpio_direction_output(chip, offset); =20 return 0; } diff --git a/drivers/pinctrl/renesas/gpio.c b/drivers/pinctrl/renesas/gpio.c index 54346b7fcdef..a5136dacaaf2 100644 --- a/drivers/pinctrl/renesas/gpio.c +++ b/drivers/pinctrl/renesas/gpio.c @@ -172,7 +172,7 @@ static int gpio_pin_direction_output(struct gpio_chip *= gc, unsigned offset, { gpio_pin_set_value(gpiochip_get_data(gc), offset, value); =20 - return pinctrl_gpio_direction_output_new(gc, offset); + return pinctrl_gpio_direction_output(gc, offset); } =20 static int gpio_pin_get(struct gpio_chip *gc, unsigned offset) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index cbe306f47c0a..917b87acbf0d 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -250,7 +250,7 @@ static int stm32_gpio_direction_output(struct gpio_chip= *chip, struct stm32_gpio_bank *bank =3D gpiochip_get_data(chip); =20 __stm32_gpio_set(bank, offset, value); - pinctrl_gpio_direction_output_new(chip, offset); + pinctrl_gpio_direction_output(chip, offset); =20 return 0; } diff --git a/drivers/pinctrl/vt8500/pinctrl-wmt.c b/drivers/pinctrl/vt8500/= pinctrl-wmt.c index 54cd556a16b8..639446bba373 100644 --- a/drivers/pinctrl/vt8500/pinctrl-wmt.c +++ b/drivers/pinctrl/vt8500/pinctrl-wmt.c @@ -535,7 +535,7 @@ static int wmt_gpio_direction_output(struct gpio_chip *= chip, unsigned offset, int value) { wmt_gpio_set_value(chip, offset, value); - return pinctrl_gpio_direction_output_new(chip, offset); + return pinctrl_gpio_direction_output(chip, offset); } =20 static const struct gpio_chip wmt_gpio_chip =3D { diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index 9531595d1abd..e7d660e98e86 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -31,8 +31,8 @@ int pinctrl_gpio_request(struct gpio_chip *gc, unsigned i= nt offset); void pinctrl_gpio_free(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_input(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_direction_output_new(struct gpio_chip *gc, - unsigned int offset); +int pinctrl_gpio_direction_output(struct gpio_chip *gc, + unsigned int offset); int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, unsigned long config); =20 @@ -91,7 +91,7 @@ pinctrl_gpio_direction_input(struct gpio_chip *gc, unsign= ed int offset) } =20 static inline int -pinctrl_gpio_direction_output_new(struct gpio_chip *gc, unsigned int offse= t) +pinctrl_gpio_direction_output(struct gpio_chip *gc, unsigned int offset) { return 0; } --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E10BCCDB474 for ; Tue, 17 Oct 2023 12:20:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343755AbjJQMUX (ORCPT ); Tue, 17 Oct 2023 08:20:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48920 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343650AbjJQMUD (ORCPT ); Tue, 17 Oct 2023 08:20:03 -0400 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 172C81FEB for ; Tue, 17 Oct 2023 05:05:35 -0700 (PDT) Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-4083740f92dso1513165e9.3 for ; Tue, 17 Oct 2023 05:05:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544334; x=1698149134; darn=vger.kernel.org; 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=BlBZOMBlUKdAOFHUnVNJUA/QQF61w0Yv6D/2R5YhEYo=; b=Yj+z0YYQnnV27M13hDW8rHaOhWd/OSYedYCeuP1EdPquuBn4P6Qd7H4+AAIBD6+FoQ nwqiI1vuwHLGphoOmCVQVRw7T8Ld8D9gJxwnyoCYJsIEr9f1NPAYxv2HEvetYNWSNxcg 0I3GXEeTvlf7Ocoh9XTexEpXJLT2HdBnN6OT7w4fOD3gf6DnJYoWafTCvi9TyLDANOmP y37U8Jc1RFrIh7cKA7/2tRIHUDR/dGgWZWzn3ubLfC4A9+RV/A1ACvcIkOqnx3PZ569p 3r9+4m1a3r0maL2oPoAqx19yb52eXLvoKUi8vZ5jN+qlzdxaYw7PExl+PIJwUG0NG+AX 1r2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544334; x=1698149134; 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=BlBZOMBlUKdAOFHUnVNJUA/QQF61w0Yv6D/2R5YhEYo=; b=ATuWjm6kcIy/DiH3mcyrHNJ4m6LX3eR3pFTnyHgSmuoIYWZDYMZr41g3P1JRAWkqo9 HyHVQi4qt9YtK2NNolav3y4hgT1c7tiCaVxlJs7Qugc+8eYDqEsxS7W+XhrYztckWPks ICdSah7eebKUCsJTT9ldlOr1OWZSXrCHqtMVVIBkGBWvFrfD7/7U0zYo8YAXcoP24iUt yW+FLoc1Cu0MXSi5a6i6HSQHSwrWYl85Ft65GsBELqIjGEAD5QwBOyJN46jv1s5CE6H8 fz8fCh3Gg9bvwnDrAH0dheJAapBU/3tDlElEbRxIVx+X+rj056Ts9/gWyz1D/THmsBcy dMWg== X-Gm-Message-State: AOJu0YwYig812LxKWz6G26rzB9eLcOYDXQA5w/q17Mtb6rb4Hy41gRTd gqkKV3XDBIvqaQodzhnnxHnblg== X-Google-Smtp-Source: AGHT+IHHo/SgTs5SbAYA1U38mF32tiSX6qdMgwB4BaLRtTdNYl2mocFbRqEMqxStSnYwPitZyNXo6g== X-Received: by 2002:a05:600c:3590:b0:406:7074:301d with SMTP id p16-20020a05600c359000b004067074301dmr1623378wmq.11.1697544333763; Tue, 17 Oct 2023 05:05:33 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:33 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 47/73] treewide: rename pinctrl_gpio_set_config_new() Date: Tue, 17 Oct 2023 14:04:05 +0200 Message-Id: <20231017120431.68847-48-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Now that pinctrl_gpio_set_config() is no longer used, let's drop the '_new' suffix from its improved variant. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-aspeed.c | 2 +- drivers/gpio/gpiolib.c | 2 +- drivers/pinctrl/core.c | 6 +++--- include/linux/pinctrl/consumer.h | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/gpio/gpio-aspeed.c b/drivers/gpio/gpio-aspeed.c index 4c417c8486dd..04c03402db6d 100644 --- a/drivers/gpio/gpio-aspeed.c +++ b/drivers/gpio/gpio-aspeed.c @@ -973,7 +973,7 @@ static int aspeed_gpio_set_config(struct gpio_chip *chi= p, unsigned int offset, else if (param =3D=3D PIN_CONFIG_BIAS_DISABLE || param =3D=3D PIN_CONFIG_BIAS_PULL_DOWN || param =3D=3D PIN_CONFIG_DRIVE_STRENGTH) - return pinctrl_gpio_set_config_new(chip, offset, config); + return pinctrl_gpio_set_config(chip, offset, config); else if (param =3D=3D PIN_CONFIG_DRIVE_OPEN_DRAIN || param =3D=3D PIN_CONFIG_DRIVE_OPEN_SOURCE) /* Return -ENOTSUPP to trigger emulation, as per datasheet */ diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 53dce41d649a..729a30e494cd 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -2065,7 +2065,7 @@ EXPORT_SYMBOL_GPL(gpiochip_generic_free); int gpiochip_generic_config(struct gpio_chip *gc, unsigned int offset, unsigned long config) { - return pinctrl_gpio_set_config_new(gc, offset, config); + return pinctrl_gpio_set_config(gc, offset, config); } EXPORT_SYMBOL_GPL(gpiochip_generic_config); =20 diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 0c2c18536242..d4a615eb1c39 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -904,7 +904,7 @@ int pinctrl_gpio_direction_output(struct gpio_chip *gc,= unsigned int offset) EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); =20 /** - * pinctrl_gpio_set_config_new() - Apply config to given GPIO pin + * pinctrl_gpio_set_config() - Apply config to given GPIO pin * @gc: GPIO chip structure from the GPIO subsystem * @offset: hardware offset of the GPIO relative to the controller * @config: the configuration to apply to the GPIO @@ -913,7 +913,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); * they need to call the underlying pin controller to change GPIO config * (for example set debounce time). */ -int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, +int pinctrl_gpio_set_config(struct gpio_chip *gc, unsigned int offset, unsigned long config) { unsigned long configs[] =3D { config }; @@ -933,7 +933,7 @@ int pinctrl_gpio_set_config_new(struct gpio_chip *gc, u= nsigned int offset, =20 return ret; } -EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config_new); +EXPORT_SYMBOL_GPL(pinctrl_gpio_set_config); =20 static struct pinctrl_state *find_state(struct pinctrl *p, const char *name) diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consu= mer.h index e7d660e98e86..73de70362b98 100644 --- a/include/linux/pinctrl/consumer.h +++ b/include/linux/pinctrl/consumer.h @@ -33,7 +33,7 @@ int pinctrl_gpio_direction_input(struct gpio_chip *gc, unsigned int offset); int pinctrl_gpio_direction_output(struct gpio_chip *gc, unsigned int offset); -int pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, +int pinctrl_gpio_set_config(struct gpio_chip *gc, unsigned int offset, unsigned long config); =20 struct pinctrl * __must_check pinctrl_get(struct device *dev); @@ -97,7 +97,7 @@ pinctrl_gpio_direction_output(struct gpio_chip *gc, unsig= ned int offset) } =20 static inline int -pinctrl_gpio_set_config_new(struct gpio_chip *gc, unsigned int offset, +pinctrl_gpio_set_config(struct gpio_chip *gc, unsigned int offset, unsigned long config) { return 0; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A89F8CDB483 for ; Tue, 17 Oct 2023 12:07:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234990AbjJQMHt (ORCPT ); Tue, 17 Oct 2023 08:07:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50992 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343793AbjJQMHE (ORCPT ); Tue, 17 Oct 2023 08:07:04 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5DF632100 for ; Tue, 17 Oct 2023 05:05:37 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-4064867903cso62410605e9.2 for ; Tue, 17 Oct 2023 05:05:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544335; x=1698149135; darn=vger.kernel.org; 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=DqYDdpwSMHdixfarzmEYN9Owj/ALsHDXsFbQ9TIrKwc=; b=flztOwpWuuW2aUJbyYp//Q2Uqamnmhj4YctQ/aZ5PzmpE2c7tfR8raBKy3ZVmRRPTM p9ay+QTQreDqGW+DWRicnKl2M2aUMeHaX17B1AT3kAnwce2d23XRsRKlTMh4iQ5Uf9h8 dehkQ9ODUdGbOoBqq0X2/Y9iGxnyzZHibjHfvD7JYDXDv7maSPeCe4ZjwUmMzBaRJmXT tFBREOe4y4E9hjarWZGSQ6RyRuuoAB0aJqzPze/zQbSOEkxqoFLeKqS9JvPORCsnIoik rDiCrbpJBbk+fstZ5JPk9nt7StLbqtJC6Gw3G30bOj+k7GLQrJYwo6By1kVGpQDoX+HU VhHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544335; x=1698149135; 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=DqYDdpwSMHdixfarzmEYN9Owj/ALsHDXsFbQ9TIrKwc=; b=ik7TyHccGW7Fn/IwYmLgZC77dsDBVqdXM6ZbHZ9nlcZyNI+4gcE/jwKAriVbLTMM28 xizuN7WgnaQrEBNRex5bKNm/Pg5WXPK6wh/9K77XKbP8O0ggAd2uQOj3o8KS9oemDrmM ViaOx/tT5Eoy6MQDaOR8ssG+Wd8BoIzj3iedzJ/n2OHqu1IduC3M0scwT9ytIrDIAFom jRy1EtR9eUiiiqF0c5cIuxhEe3eqbuUNi41lkQ64HD5Hw+kM3MHfJ+YJPblaOrE0S3Oh W678NWfR/6tu/yev5REkVCeBnUzrJ/Kgd10MQfaDuC/WUiybbXTI0ZZXiNpIqEyB7zLf 1EAQ== X-Gm-Message-State: AOJu0YxvfuzBuu9REQlYFl3Yq7CsKozlT5Cq7/L95bIRsNbknKwDei/N X9ZPZ92uHuVkee52Pea1vZYHwQ== X-Google-Smtp-Source: AGHT+IGXaO/+/HmoIehSue+LQn4AH2sJqYjhveacHqteldmyuF6SKygUWSf3bKZslzRs2TEj2+gYWQ== X-Received: by 2002:a05:600c:3590:b0:404:4b6f:d70d with SMTP id p16-20020a05600c359000b004044b6fd70dmr1539396wmq.17.1697544334471; Tue, 17 Oct 2023 05:05:34 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:34 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 48/73] pinctrl: change the signature of pinctrl_gpio_direction() Date: Tue, 17 Oct 2023 14:04:06 +0200 Message-Id: <20231017120431.68847-49-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Modify pinctrl_gpio_direction() to be in line with public GPIO helpers and take a pair of GPIO chip & offset as arguments. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index d4a615eb1c39..b92047af7b9f 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -850,14 +850,16 @@ void pinctrl_gpio_free(struct gpio_chip *gc, unsigned= int offset) } EXPORT_SYMBOL_GPL(pinctrl_gpio_free); =20 -static int pinctrl_gpio_direction(unsigned gpio, bool input) +static int pinctrl_gpio_direction(struct gpio_chip *gc, unsigned int offse= t, + bool input) { struct pinctrl_dev *pctldev; struct pinctrl_gpio_range *range; int ret; int pin; =20 - ret =3D pinctrl_get_device_gpio_range(gpio, &pctldev, &range); + ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, + &range); if (ret) { return ret; } @@ -865,7 +867,7 @@ static int pinctrl_gpio_direction(unsigned gpio, bool i= nput) mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gpio); + pin =3D gpio_to_pin(range, gc->base + offset); ret =3D pinmux_gpio_direction(pctldev, range, pin, input); =20 mutex_unlock(&pctldev->mutex); @@ -884,7 +886,7 @@ static int pinctrl_gpio_direction(unsigned gpio, bool i= nput) */ int pinctrl_gpio_direction_input(struct gpio_chip *gc, unsigned int offset) { - return pinctrl_gpio_direction(gc->base + offset, true); + return pinctrl_gpio_direction(gc, offset, true); } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); =20 @@ -899,7 +901,7 @@ EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_input); */ int pinctrl_gpio_direction_output(struct gpio_chip *gc, unsigned int offse= t) { - return pinctrl_gpio_direction(gc->base + offset, false); + return pinctrl_gpio_direction(gc, offset, false); } EXPORT_SYMBOL_GPL(pinctrl_gpio_direction_output); =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DA07ACDB474 for ; Tue, 17 Oct 2023 12:08:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343621AbjJQMIF (ORCPT ); Tue, 17 Oct 2023 08:08:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60650 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235010AbjJQMHO (ORCPT ); Tue, 17 Oct 2023 08:07:14 -0400 Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5C7EA2108 for ; Tue, 17 Oct 2023 05:05:38 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-4081ccf69dcso2764535e9.0 for ; Tue, 17 Oct 2023 05:05:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544336; x=1698149136; darn=vger.kernel.org; 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=OzbUjPGvfQ55lrc91Ueu/fWATZc6Tre3CC80/9IHyOA=; b=cY8A2TCY7h8Hkp9+PSQ5ed1PXmxWrnGr1fGcBcRVgriL9c/IdK+/wKjAfYXJy8rBw9 p7DvdnG/f1aWObUIw6B9ccI7i8h1rLHx53eduMHASqmSNmumoPp1gneFID3WAoSWkWjQ KHvmJzozcaZeJAlNa3jvO3QO2vzpa/eu2gxd86sKZUFi6X671tv1cnv8TeC0jRE/6ih6 rGmO/VFKUOMWGYtR/W84hcBlLWYd8xNVdh9eLPUbgDCnWNZtQu9B3UoFrOmq6BX9T8xa y3hUZphAxVv2aavwBF95Ai0BpDgWHWQIayh9c0St1dBFPaAEdaKHHPgOGIdrreOajcV6 RwbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544336; x=1698149136; 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=OzbUjPGvfQ55lrc91Ueu/fWATZc6Tre3CC80/9IHyOA=; b=kbmNAzbDRXNaOLy9vafi/vlYbN2uXlpH4IvfojgdPv0EAUbIfcIyqBW/RxLV3aasv0 hoMRkjX5jO231cEiLHWukcndg6P1Nwf4qTiYH9JDRITo1tIkqkAdK4gZ7Nhp+SefjPsu ozBP5ZCQmNHuGZmhNQ79f9SaKVkcVRkiuZc/pZlkQc3IvxoRnKWk/HBHmZJ4xpc17b5Z X4G463O/ruMqlTB+kqEl5UjJxKxyIIK6Bdl4evwgUcc5Ch8pRFpISZS+v+w+TDNnrHar AcLtJdEkgB6NOUsHQ3Fcgmz+TaXWrH832UauCUO0zVdHHnikd8lvonxDEK5MTaxS2RJ0 VoIw== X-Gm-Message-State: AOJu0Ywm1gbNtUv8AiNorjD7CTjTExb8CUWGU1ks0luhz8kRqzEOMHJ1 9J3xfrCz8LGXa96O4nawz+de0w== X-Google-Smtp-Source: AGHT+IETciMioDwEXZ757QvLkU/Q+PJQuwEycMdpZ6EA1ZpK6cTX7paCGX3w99LIF9axZWAMyYILig== X-Received: by 2002:a05:600c:458c:b0:406:44fc:65c9 with SMTP id r12-20020a05600c458c00b0040644fc65c9mr1658658wmo.8.1697544336560; Tue, 17 Oct 2023 05:05:36 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:36 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 49/73] pinctrl: change the signature of pinctrl_get_device_gpio_range() Date: Tue, 17 Oct 2023 14:04:07 +0200 Message-Id: <20231017120431.68847-50-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Modify pinctrl_get_device_gpio_range() to be in line with public GPIO helpers and take a pair of GPIO chip & offset as arguments. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index b92047af7b9f..80f1db0ec074 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -372,7 +372,8 @@ static bool pinctrl_ready_for_gpio_range(unsigned gpio)= { return true; } =20 /** * pinctrl_get_device_gpio_range() - find device for GPIO range - * @gpio: the pin to locate the pin controller for + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * @outdev: the pin control device if found * @outrange: the GPIO range if found * @@ -381,7 +382,8 @@ static bool pinctrl_ready_for_gpio_range(unsigned gpio)= { return true; } * -EPROBE_DEFER if the GPIO range could not be found in any device since = it * may still have not been registered. */ -static int pinctrl_get_device_gpio_range(unsigned gpio, +static int pinctrl_get_device_gpio_range(struct gpio_chip *gc, + unsigned int offset, struct pinctrl_dev **outdev, struct pinctrl_gpio_range **outrange) { @@ -393,7 +395,7 @@ static int pinctrl_get_device_gpio_range(unsigned gpio, list_for_each_entry(pctldev, &pinctrldev_list, node) { struct pinctrl_gpio_range *range; =20 - range =3D pinctrl_match_gpio_range(pctldev, gpio); + range =3D pinctrl_match_gpio_range(pctldev, gc->base + offset); if (range) { *outdev =3D pctldev; *outrange =3D range; @@ -767,7 +769,7 @@ bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, un= signed int offset) * we're probably dealing with GPIO driver * without a backing pin controller - bail out. */ - if (pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, &range)) + if (pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range)) return true; =20 mutex_lock(&pctldev->mutex); @@ -798,8 +800,7 @@ int pinctrl_gpio_request(struct gpio_chip *gc, unsigned= int offset) struct pinctrl_dev *pctldev; int ret, pin; =20 - ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, - &range); + ret =3D pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range); if (ret) { if (pinctrl_ready_for_gpio_range(gc->base + offset)) ret =3D 0; @@ -834,8 +835,7 @@ void pinctrl_gpio_free(struct gpio_chip *gc, unsigned i= nt offset) struct pinctrl_dev *pctldev; int ret, pin; =20 - ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, - &range); + ret =3D pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range); if (ret) return; =20 @@ -858,8 +858,7 @@ static int pinctrl_gpio_direction(struct gpio_chip *gc,= unsigned int offset, int ret; int pin; =20 - ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, - &range); + ret =3D pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range); if (ret) { return ret; } @@ -923,8 +922,7 @@ int pinctrl_gpio_set_config(struct gpio_chip *gc, unsig= ned int offset, struct pinctrl_dev *pctldev; int ret, pin; =20 - ret =3D pinctrl_get_device_gpio_range(gc->base + offset, &pctldev, - &range); + ret =3D pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range); if (ret) return ret; =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9E0EACDB474 for ; Tue, 17 Oct 2023 12:08:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343765AbjJQMIM (ORCPT ); Tue, 17 Oct 2023 08:08:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48732 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235038AbjJQMHW (ORCPT ); Tue, 17 Oct 2023 08:07:22 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 320442113 for ; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40566f89f6eso62512765e9.3 for ; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544337; x=1698149137; darn=vger.kernel.org; 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=+4CqFcvuUjz2M/MS1KWCWQlIQoK+ivVHKbPT1o2HxyI=; b=r2YnnYNAzXjV+8vENDlDrgbbw4SmN+FQLIcKfVfOMecYJJ+U9JNP2vr+DD2GYZhO7Y vTisADJZgwZp8dni6evcu1Lh7HyhTND8J9LcaOY45N6rch/lrd6FLAB1/fH2QZcY6wlD YI2GpyY9Nv7inL4pl3cqhh7kGWwz6tUpTNWoz+Z1h/9DuApjnExqlmfemDYx0m8DVvhT XumA3rz1Ax3OrQXaPh21o2gvT8Yv1kGLGqAW2LcUg40GXQAkp8CEqlK0yt9JGvRTUJPT AxVPhLv5ExvBP5RKksfpKs/tybdq7FnjV/8+x9EyIBSvxK6sI7/PoandWB3utXjXnHD1 RiVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544337; x=1698149137; 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=+4CqFcvuUjz2M/MS1KWCWQlIQoK+ivVHKbPT1o2HxyI=; b=QfDD8tAGXsPQeSWvsyMRwMMUL8eZr5eyXzBLwg9H80cjzSK92zUSmbPTjLyF0WJXwj TllUN3jAXxJ/d7vgGpCSl3VwMFC335WBoFSDwxeH2Jvpdt8cQu2XCA9x6+KSGU+XUuFv RBFOgN4r9/CfXuPcHXrk01pm+igFqqa4Q3L3XfUqB238cXZwyq4/EdcSWyfWheZ66CUA GP/IAqYG45MuZJfPlHlxs/qo6xyQC1sNa3qkPi8FGKOKfZ1aPjOPqEaqO1AoVoDZ2htz sddHET7UeOHcSJoxj+y5E2mcc/kGVeh6hqclB7lKRgLpGU6Xzot6xNWyWE+LTZIZJ5OE mZ+A== X-Gm-Message-State: AOJu0Yycl61kWYIgwGnaQXreMzTxrQlc9/01HMdtsj/py54fWri6T+aV XjF9bN0WOIpP7d69fmKKvcRCrg== X-Google-Smtp-Source: AGHT+IEcz+6S64y8VXs/vk2gA6SNC68GiE+ghH3lXVhsrchGyyw80vzthXCTmJ631MBWqtDvabC4/w== X-Received: by 2002:a05:600c:a47:b0:403:8fb9:8d69 with SMTP id c7-20020a05600c0a4700b004038fb98d69mr1688040wmq.25.1697544337487; Tue, 17 Oct 2023 05:05:37 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:36 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 50/73] pinctrl: change the signature of pinctrl_match_gpio_range() Date: Tue, 17 Oct 2023 14:04:08 +0200 Message-Id: <20231017120431.68847-51-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Modify pinctrl_match_gpio_range() to be in line with public GPIO helpers and take a pair of GPIO chip & offset as arguments. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 80f1db0ec074..ec78a75a5d7c 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -292,13 +292,15 @@ static inline int gpio_to_pin(struct pinctrl_gpio_ran= ge *range, /** * pinctrl_match_gpio_range() - check if a certain GPIO pin is in range * @pctldev: pin controller device to check - * @gpio: gpio pin to check taken from the global GPIO pin space + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * * Tries to match a GPIO pin number to the ranges handled by a certain pin * controller, return the range or NULL */ static struct pinctrl_gpio_range * -pinctrl_match_gpio_range(struct pinctrl_dev *pctldev, unsigned gpio) +pinctrl_match_gpio_range(struct pinctrl_dev *pctldev, struct gpio_chip *gc, + unsigned int offset) { struct pinctrl_gpio_range *range; =20 @@ -306,8 +308,8 @@ pinctrl_match_gpio_range(struct pinctrl_dev *pctldev, u= nsigned gpio) /* Loop over the ranges */ list_for_each_entry(range, &pctldev->gpio_ranges, node) { /* Check if we're in the valid range */ - if (gpio >=3D range->base && - gpio < range->base + range->npins) { + if ((gc->base + offset) >=3D range->base && + (gc->base + offset) < range->base + range->npins) { mutex_unlock(&pctldev->mutex); return range; } @@ -395,7 +397,7 @@ static int pinctrl_get_device_gpio_range(struct gpio_ch= ip *gc, list_for_each_entry(pctldev, &pinctrldev_list, node) { struct pinctrl_gpio_range *range; =20 - range =3D pinctrl_match_gpio_range(pctldev, gc->base + offset); + range =3D pinctrl_match_gpio_range(pctldev, gc, offset); if (range) { *outdev =3D pctldev; *outrange =3D range; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D80C5CDB474 for ; Tue, 17 Oct 2023 12:08:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234961AbjJQMIV (ORCPT ); Tue, 17 Oct 2023 08:08:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343550AbjJQMHY (ORCPT ); Tue, 17 Oct 2023 08:07:24 -0400 Received: from mail-wm1-x332.google.com (mail-wm1-x332.google.com [IPv6:2a00:1450:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 165B52118 for ; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-408382da7f0so623075e9.0 for ; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544338; x=1698149138; darn=vger.kernel.org; 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=d8yAQcDn5NqavITdTu+94YWVTuN3+Lvdw4mYFyDalzc=; b=3HqZrJ0pMNTJhLp55B7mfeuFV97tJozM1ARjbt3FCu9eVoX1oADAYvh7oGqDKbKLZ5 dytmZSrHdDhPn8rVc4r0Y3R7+Oe0mw3N88MAhHH1H3bjGemDEHtIqmwwGvI9w5bqWBBW 1sxJt/Old9yWIX+vZ6H/hqyu15MFpbNVB8i1hHdiHw5sVtc/1jvdtp2oPHcleCBnj1O6 sRktwMpgXr3pq1+6z8QtF6ZFJc2oGT5+3dD2ckrdxly6Eo2l10AqzRv3zUoivhcpZzc2 ZBB50JgOZogLLXm/OGTBlaBfdp9LnoLcMMmFQGkKJ8/xIxVzgR1peArY6hCVgz848dyA 1vGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544338; x=1698149138; 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=d8yAQcDn5NqavITdTu+94YWVTuN3+Lvdw4mYFyDalzc=; b=EgfLyE55KdRGr298YIYm8qyHsFohYyJGFV/YZuUxKS+4tiWF7Sq97/eAsWLo18q2hh rDx+y6W0z84QqtQxfbdQb2uAJi6+/B4GA4ZafDN+IRCaw70i6mWphSFAA9e9/frKI/p0 CqqhXdIt2KJayvCDP1yqRV4zSXmZpgHDy98Ma0nAevDLBM0mfywwJApUK16kQNSohtkv b6PmDDf4OL3qCyxkMpmTJOIIhipVtmioXjhAxy4JOj6VN/XrfaW+E1sPfJOWG5EMz6Tk YA9uZcaVssn2v1Kofv+oabfikOBh2+WNHUuqCsxdkE4smo/G41rJMCI9ULoEOgXVkE02 hVNA== X-Gm-Message-State: AOJu0Yzp0S2M1lvs7y6Wc8/dPQyLUgXGuhnruWV+aAWqYTxlRuWeRfDt LXTbssJIDTgoMEosFgvdPbOZQg== X-Google-Smtp-Source: AGHT+IHpq57euEx4cvlqeeY4qTce39hHLaQEQolHZiN9d1I6xCBqMADth37mmsTUBz+dCa97s2EOWA== X-Received: by 2002:a05:600c:1f8f:b0:406:849f:f3cd with SMTP id je15-20020a05600c1f8f00b00406849ff3cdmr1511927wmb.29.1697544338272; Tue, 17 Oct 2023 05:05:38 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:37 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 51/73] pinctrl: change the signature of gpio_to_pin() Date: Tue, 17 Oct 2023 14:04:09 +0200 Message-Id: <20231017120431.68847-52-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Modify gpio_to_pin() to be in line with public GPIO helpers and take a pair of GPIO chip & offset as arguments. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index ec78a75a5d7c..da5d716f154d 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -269,7 +269,8 @@ static int pinctrl_register_pins(struct pinctrl_dev *pc= tldev, /** * gpio_to_pin() - GPIO range GPIO number to pin number translation * @range: GPIO range used for the translation - * @gpio: gpio pin to translate to a pin number + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * * Finds the pin number for a given GPIO using the specified GPIO range * as a base for translation. The distinction between linear GPIO ranges @@ -280,13 +281,13 @@ static int pinctrl_register_pins(struct pinctrl_dev *= pctldev, * result of successful pinctrl_get_device_gpio_range calls)! */ static inline int gpio_to_pin(struct pinctrl_gpio_range *range, - unsigned int gpio) + struct gpio_chip *gc, unsigned int offset) { - unsigned int offset =3D gpio - range->base; + unsigned int pin =3D gc->base + offset - range->base; if (range->pins) - return range->pins[offset]; + return range->pins[pin]; else - return range->pin_base + offset; + return range->pin_base + pin; } =20 /** @@ -777,7 +778,7 @@ bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, un= signed int offset) mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gc->base + offset); + pin =3D gpio_to_pin(range, gc, offset); =20 result =3D pinmux_can_be_used_for_gpio(pctldev, pin); =20 @@ -812,7 +813,7 @@ int pinctrl_gpio_request(struct gpio_chip *gc, unsigned= int offset) mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gc->base + offset); + pin =3D gpio_to_pin(range, gc, offset); =20 ret =3D pinmux_request_gpio(pctldev, range, pin, gc->base + offset); =20 @@ -844,7 +845,7 @@ void pinctrl_gpio_free(struct gpio_chip *gc, unsigned i= nt offset) mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gc->base + offset); + pin =3D gpio_to_pin(range, gc, offset); =20 pinmux_free_gpio(pctldev, pin, range); =20 @@ -868,7 +869,7 @@ static int pinctrl_gpio_direction(struct gpio_chip *gc,= unsigned int offset, mutex_lock(&pctldev->mutex); =20 /* Convert to the pin controllers number space */ - pin =3D gpio_to_pin(range, gc->base + offset); + pin =3D gpio_to_pin(range, gc, offset); ret =3D pinmux_gpio_direction(pctldev, range, pin, input); =20 mutex_unlock(&pctldev->mutex); @@ -929,7 +930,7 @@ int pinctrl_gpio_set_config(struct gpio_chip *gc, unsig= ned int offset, return ret; =20 mutex_lock(&pctldev->mutex); - pin =3D gpio_to_pin(range, gc->base + offset); + pin =3D gpio_to_pin(range, gc, offset); ret =3D pinconf_set_config(pctldev, pin, configs, ARRAY_SIZE(configs)); mutex_unlock(&pctldev->mutex); =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BBAD6CDB474 for ; Tue, 17 Oct 2023 12:41:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235011AbjJQMIv (ORCPT ); Tue, 17 Oct 2023 08:08:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60666 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234889AbjJQMHd (ORCPT ); Tue, 17 Oct 2023 08:07:33 -0400 Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B8014211C for ; Tue, 17 Oct 2023 05:05:40 -0700 (PDT) Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-4065dea9a33so52640915e9.3 for ; Tue, 17 Oct 2023 05:05:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544339; x=1698149139; darn=vger.kernel.org; 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=eJlmvjClNYUGDO9zWdiE9QW26eZ74vwLTwImlwEqdgA=; b=CEpZd2qVeeMGuYMjOwPiJPAW0Ucq1BhxbN69wfZllsr9FsELlxC3P5AtIqpc481wzz +DdGfPoflsAxAxOsSnudjvwD/Lh/CndCpsngPznGhSNV0dIEfefbtTMaFYWHaD8Zl5T0 NJOKEqzSBAIg2orALZczMnzvK8Kq63auYE3Kj8Uvc/fWm3lO28drBVz0BbqHN3JPN7nY CaJieTgK0RmTWqKJY4786UVs4JF2PumlGCbGSsEQwQWhEtDahId9kS7DIHY+lrnP8g+J QxCA5iEG37+M3IMkp8xRt3qps5clCaf498pHJ03efq7N2ER9Zs9cPct4zqArd0XMdO0k Grug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544339; x=1698149139; 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=eJlmvjClNYUGDO9zWdiE9QW26eZ74vwLTwImlwEqdgA=; b=LA0CJW0jMrt+wPPcqIppgcNG/Nk1uJSJBnQ2XGJiBqe7l5gCZmpfp3Fti+KI0940Iv a8FuprtJ82jdTJAxYal+AXfMkqCRBsxzQnfgj4jl/4whxkmn0FFZvBxNycFVAoO/5z+X xH1RfiBJBRotCByj165iwidn9Ef6QFwuPQk7xR2YudR1ZogGB+Bigva21ZYpCy5TICfc pY7WTgZkookHKJwzxZyG74oPj4yaeOV4na/2e53kbpDQcyroxjM6Zv6IKAj/QYlX741l d3nxAPnjX9Gp3JLLffg/TRrvq9mRlH1tlR6ld0l2auJabKiwSzFsr7e4PACCj0ktL7OH jtnw== X-Gm-Message-State: AOJu0YzG8yjJ5Yz8r3QmhWFdSR3/wpdmhTILsf+rsPPyeGSn0WYVubjb CSjICjgN8q90pXoHKunMW45Cnw== X-Google-Smtp-Source: AGHT+IGGXXduwT+h/y+ce8+VQO6v5Nn3aPm/K1JNY6WwLKZo05Jjc0x7kKnf6WImcaPW7tNO7SKkGg== X-Received: by 2002:a05:600c:511b:b0:403:272:4414 with SMTP id o27-20020a05600c511b00b0040302724414mr1672045wms.0.1697544339037; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:38 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 52/73] pinctrl: change the signature of pinctrl_ready_for_gpio_range() Date: Tue, 17 Oct 2023 14:04:10 +0200 Message-Id: <20231017120431.68847-53-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski Modify pinctrl_ready_for_gpio_range() to be in line with public GPIO helpers and take a pair of GPIO chip & offset as arguments Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko Acked-by: Linus Walleij --- drivers/pinctrl/core.c | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index da5d716f154d..932bbcdc0eb1 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -322,7 +322,8 @@ pinctrl_match_gpio_range(struct pinctrl_dev *pctldev, s= truct gpio_chip *gc, /** * pinctrl_ready_for_gpio_range() - check if other GPIO pins of * the same GPIO chip are in range - * @gpio: gpio pin to check taken from the global GPIO pin space + * @gc: GPIO chip structure from the GPIO subsystem + * @offset: hardware offset of the GPIO relative to the controller * * This function is complement of pinctrl_match_gpio_range(). If the return * value of pinctrl_match_gpio_range() is NULL, this function could be used @@ -333,19 +334,11 @@ pinctrl_match_gpio_range(struct pinctrl_dev *pctldev,= struct gpio_chip *gc, * is false, it means that pinctrl device may not be ready. */ #ifdef CONFIG_GPIOLIB -static bool pinctrl_ready_for_gpio_range(unsigned gpio) +static bool pinctrl_ready_for_gpio_range(struct gpio_chip *gc, + unsigned int offset) { struct pinctrl_dev *pctldev; struct pinctrl_gpio_range *range =3D NULL; - /* - * FIXME: "gpio" here is a number in the global GPIO numberspace. - * get rid of this from the ranges eventually and get the GPIO - * descriptor from the gpio_chip. - */ - struct gpio_chip *chip =3D gpiod_to_chip(gpio_to_desc(gpio)); - - if (WARN(!chip, "no gpio_chip for gpio%i?", gpio)) - return false; =20 mutex_lock(&pinctrldev_list_mutex); =20 @@ -355,8 +348,8 @@ static bool pinctrl_ready_for_gpio_range(unsigned gpio) mutex_lock(&pctldev->mutex); list_for_each_entry(range, &pctldev->gpio_ranges, node) { /* Check if any gpio range overlapped with gpio chip */ - if (range->base + range->npins - 1 < chip->base || - range->base > chip->base + chip->ngpio - 1) + if (range->base + range->npins - 1 < gc->base || + range->base > gc->base + gc->ngpio - 1) continue; mutex_unlock(&pctldev->mutex); mutex_unlock(&pinctrldev_list_mutex); @@ -370,7 +363,11 @@ static bool pinctrl_ready_for_gpio_range(unsigned gpio) return false; } #else -static bool pinctrl_ready_for_gpio_range(unsigned gpio) { return true; } +static inline bool +pinctrl_ready_for_gpio_range(struct gpio_chip *gc, unsigned int offset) +{ + return true; +} #endif =20 /** @@ -805,7 +802,7 @@ int pinctrl_gpio_request(struct gpio_chip *gc, unsigned= int offset) =20 ret =3D pinctrl_get_device_gpio_range(gc, offset, &pctldev, &range); if (ret) { - if (pinctrl_ready_for_gpio_range(gc->base + offset)) + if (pinctrl_ready_for_gpio_range(gc, offset)) ret =3D 0; return ret; } --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0480BCDB483 for ; Tue, 17 Oct 2023 12:08:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343561AbjJQMIg (ORCPT ); Tue, 17 Oct 2023 08:08:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59160 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234956AbjJQMH1 (ORCPT ); Tue, 17 Oct 2023 08:07:27 -0400 Received: from mail-wm1-x32f.google.com (mail-wm1-x32f.google.com [IPv6:2a00:1450:4864:20::32f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 624CC2125 for ; Tue, 17 Oct 2023 05:05:41 -0700 (PDT) Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-406402933edso55836155e9.2 for ; Tue, 17 Oct 2023 05:05:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544339; x=1698149139; darn=vger.kernel.org; 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=IpzD63FKTnDkoNuJq4Z0rqQ6O9C3QSfgDXXMR4608kY=; b=07QgEBSVAhhSADoKzJRmmqC51TqHYqrlj8l0RkLHTIlnAAKJWd4vourKYo3Luqfu3T yy+4N8wczQHTuvFGjCfzCvQ3NXE8ablCvICit1QU5B4OTkVZZuDFJdNk/yPz3PvLQ0A5 WyvpvmtJwnsDiG9vDL3ph6QkH1teax/9xXcOicgORnJ6/1lzXOD/G3TsZWjfaOESUY+E bULrtbITrAnBancIIFmg2z7LhOhxilRSi9vmf+qcgeKPe3z4j+6C/kBGzxgzj+XpRCHy R+jkrH7dl7B9I/pcKfD/OA0ffVOZQ9P3kNod7Ih6LiAd1lxAdNewdYpH4+8gQY2kHlis Pg7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544339; x=1698149139; 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=IpzD63FKTnDkoNuJq4Z0rqQ6O9C3QSfgDXXMR4608kY=; b=WdsRSz07SqqPLzaoLohxRJBV8RhL4yy/HmdY20PD+MwgQFpzR0YCzNekJKTUzn5krC wodvqdkre517It13tBWbR7pmC6At7B7s4PokHjBCHYpF5EvK9JOQzuqznRqmWy5OskzR MNFVtupklWwVXVi3mlrfXbFA5m0pMuqD88RUY1hS/Pqpa01lErVIVldqsV+FvOVnCm8k E1Rps0+KJSVA/T1/4+/lqZLFRXNEprkRs9hpH/yv9jAGCCOqXO3xLD17I+dGUnHrODS/ JKhQE1d9Mm0Kwr/YPWWQua9JASenshgOsO3KBCTkzBvZWHiPowcUvchyT1AYKqFTouxw m63A== X-Gm-Message-State: AOJu0YxOrlJGtRmGXrWvsA4BbhWWjWnVj63ApJ8MDCt7Lw/85Av8qe19 EKWmYvznsUIYJ9BhOgKhx8m+XA== X-Google-Smtp-Source: AGHT+IFQ4s1y11wlkTn4KHGm3cMaFynX33qrPaSxSiQBylbccwIVK/48jQ16/iA51GQIQbVpC+ySug== X-Received: by 2002:a05:600c:a01:b0:405:3f19:fc49 with SMTP id z1-20020a05600c0a0100b004053f19fc49mr1487521wmp.34.1697544339820; Tue, 17 Oct 2023 05:05:39 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:39 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 53/73] pinctrl: intel: lynxpoint: drop the wrappers around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:11 +0200 Message-Id: <20231017120431.68847-54-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrappers around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij Reviewed-by: Andy Shevchenko --- drivers/pinctrl/intel/pinctrl-lynxpoint.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-lynxpoint.c b/drivers/pinctrl/in= tel/pinctrl-lynxpoint.c index e6878e4cf20c..303aaca341ea 100644 --- a/drivers/pinctrl/intel/pinctrl-lynxpoint.c +++ b/drivers/pinctrl/intel/pinctrl-lynxpoint.c @@ -539,11 +539,6 @@ static void lp_gpio_set(struct gpio_chip *chip, unsign= ed int offset, int value) raw_spin_unlock_irqrestore(&lg->lock, flags); } =20 -static int lp_gpio_direction_input(struct gpio_chip *chip, unsigned int of= fset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int lp_gpio_direction_output(struct gpio_chip *chip, unsigned int o= ffset, int value) { @@ -799,7 +794,7 @@ static int lp_gpio_probe(struct platform_device *pdev) gc->owner =3D THIS_MODULE; gc->request =3D gpiochip_generic_request; gc->free =3D gpiochip_generic_free; - gc->direction_input =3D lp_gpio_direction_input; + gc->direction_input =3D pinctrl_gpio_direction_input; gc->direction_output =3D lp_gpio_direction_output; gc->get =3D lp_gpio_get; gc->set =3D lp_gpio_set; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9E68DCDB474 for ; Tue, 17 Oct 2023 12:08:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234637AbjJQMIa (ORCPT ); Tue, 17 Oct 2023 08:08:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59124 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343619AbjJQMH0 (ORCPT ); Tue, 17 Oct 2023 08:07:26 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4A9FC213F for ; Tue, 17 Oct 2023 05:05:43 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id 38308e7fff4ca-2c50906f941so56970931fa.2 for ; Tue, 17 Oct 2023 05:05:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544340; x=1698149140; darn=vger.kernel.org; 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=IDbQa4pbNgPSy0Q7qNPPuIZ1OX8+KoCwyythnm8P9i8=; b=mYI4b8ge26f4cBfLQjNoyAP6xewpEAX+N+wtc/jQGGHm78NJMqKsuXaJHxKprHo1J+ kz+LCQAVjftP+LL/Oj1Fg8vOVrLpdTpWxJkAiiWzlt09cj+IoFPQCoZHxrqy2m2e0AX+ /KcvB9rBOzEHjZw5M5lK0dpx9ayOfj/jetxPzGqgza/9Yy6r9mnEh/qFe3b0jIEulKH4 0JSaj8G6xOOc/jO5X8a+G7oGMfSPR3I1c61JcduGy7ZgQv3rcYgi2pkdUV/S1QUrypHM P4OiSVznNPwULTQxfS9jrcXxYLngx4rKR4bx4floMwUfk3SL120pC/sLvwn0QdsvN4hy 48hQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544340; x=1698149140; 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=IDbQa4pbNgPSy0Q7qNPPuIZ1OX8+KoCwyythnm8P9i8=; b=UIdlogsjnFpWgEmLrpzSDirk0uWbJKsqtjBfr43RV5eSz4J/DPupCpeT4l/pL963FF VqzwbUiULTa4nyAsY8/WErky4py8+486a7FtNo+zbZWkNp6JY9FYNnOs/bknPPpoi6B7 FtOmEcKgS6gQm6/o4izyDrEQMXcrfovDG9waBxoQ9v7B5LvPzMcFCnZrX32flIhVTo3T J//BctDQu8UHxUJuZzLL51YylVrNekXoXr+I5umjT9A7dK8O+pzIAsXKSOws4wRR3+1/ 6slUaDH0yorv5J5HkLWCIxTaAkrwNmCJTnCE/1fOUuv9Zwjafd3ShXIujlAF3IM1RAn/ CSyA== X-Gm-Message-State: AOJu0YxywmhL7AKvjIx9mSS0G+LsdDSvlfM+RuTZXnkZkNAmrGVqpIvP HwpV0TQ7mZL6XyWhJhaW9WuYIA== X-Google-Smtp-Source: AGHT+IHN/WqckhmUqxmQwvvCJ12TWzSuYj9MFFn4yz5D/MYVMFJ2znX2y6gYLUB9FdDFmJon/erAlw== X-Received: by 2002:a2e:a162:0:b0:2bc:f5a0:cc25 with SMTP id u2-20020a2ea162000000b002bcf5a0cc25mr1529232ljl.2.1697544340583; Tue, 17 Oct 2023 05:05:40 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:40 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 54/73] pinctrl: intel: drop the wrappers around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:12 +0200 Message-Id: <20231017120431.68847-55-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrappers around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij Reviewed-by: Andy Shevchenko --- drivers/pinctrl/intel/pinctrl-intel.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-intel.c b/drivers/pinctrl/intel/= pinctrl-intel.c index 0f8e27d16929..f772be70e56d 100644 --- a/drivers/pinctrl/intel/pinctrl-intel.c +++ b/drivers/pinctrl/intel/pinctrl-intel.c @@ -990,11 +990,6 @@ static int intel_gpio_get_direction(struct gpio_chip *= chip, unsigned int offset) return GPIO_LINE_DIRECTION_OUT; } =20 -static int intel_gpio_direction_input(struct gpio_chip *chip, unsigned int= offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int intel_gpio_direction_output(struct gpio_chip *chip, unsigned in= t offset, int value) { @@ -1007,7 +1002,7 @@ static const struct gpio_chip intel_gpio_chip =3D { .request =3D gpiochip_generic_request, .free =3D gpiochip_generic_free, .get_direction =3D intel_gpio_get_direction, - .direction_input =3D intel_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D intel_gpio_direction_output, .get =3D intel_gpio_get, .set =3D intel_gpio_set, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 154E2CDB482 for ; Tue, 17 Oct 2023 12:08:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343547AbjJQMIR (ORCPT ); Tue, 17 Oct 2023 08:08:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59096 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235055AbjJQMHX (ORCPT ); Tue, 17 Oct 2023 08:07:23 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A8659268C for ; Tue, 17 Oct 2023 05:05:44 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-40566f89f6eso62513285e9.3 for ; Tue, 17 Oct 2023 05:05:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544342; x=1698149142; darn=vger.kernel.org; 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=dZA9jxM2qedMisgaI2wTgRjsyEvc4vcg/mOILSJ3QTQ=; b=cZaK5JFhE3fQcdHqt9Y2ut45fX2MRu4Iul6awgxoaIS7u39iWg3EmRv4YMH8gbi/dv FHUbfO7pfm4WM33Ni1c8vRm7fhhbTitAfyL/22QTRNGgS2HkvQi49Kih0wirb1iBMUtb YPKsYqYJi3mIiqoATGQ4z5+GzKJOR92V/fTclxOfYtSB8PjFgQhQOjseq6wXoElPwNja f9D4Yjkk0SnGWFWVSNpQmJ/nsA1ZW8bCS7MPgyQziG2vde3x06IlDWxjSDOFXhfsWII5 oAj56XbM4kBCgMv30n4apvJ1KCmCWdwsQ7muMwJcnRBjH3aq4w4/aAyP7ReQN5OudUOS g4Cw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544342; x=1698149142; 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=dZA9jxM2qedMisgaI2wTgRjsyEvc4vcg/mOILSJ3QTQ=; b=nYOZsFQ1xrwTFy9hjuC8jqpq17VQWLj6y6aA8EGzhND4OnPD0zIEUXYgMZE3f2O9pf PnSgGZFBjO1dnJB0iGlu2xF544RfKEvfQOLJ+0BNYxxhVx1I9RUeN9lMSGc+/eYzIZal 7QAk5y3vas8ynPlg6vInHd3QdXt31clGkxA+mdqvG9KOJWg0W+24QjCtr/nWSBx1MDe6 456Mk0S76+hYW6lGypxuFnERCqVLRoLNOupTAmcdzioHvYL5cokrO+eNLwjMM1j7nJPm 9ZZbb/2bk9MOBENzjFfikmLiIf/zr3usAxVQeNTjnhq2SIZMB4jBsVQI1ixHF8pp99LK rs0w== X-Gm-Message-State: AOJu0YwM6ROkEofXIQa0K7utPTjAWcJ7qeU/bt2nSz37kr2EvL79sCac z5ojcVplf+eGfZC9LM/8qdFxJQ== X-Google-Smtp-Source: AGHT+IEqZN3vjK9m7+TPCHjXqsDkxrsq/FZ9dHcs+XebmA+Waahesh5JLijgb1Q3MNPO84Gg3IGu2g== X-Received: by 2002:a05:600c:a0a:b0:406:4a32:52fc with SMTP id z10-20020a05600c0a0a00b004064a3252fcmr1528311wmp.21.1697544341404; Tue, 17 Oct 2023 05:05:41 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:41 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 55/73] pinctrl: intel: cherryview: drop the wrappers around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:13 +0200 Message-Id: <20231017120431.68847-56-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrappers around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij Reviewed-by: Andy Shevchenko --- drivers/pinctrl/intel/pinctrl-cherryview.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/intel/pinctrl-cherryview.c b/drivers/pinctrl/i= ntel/pinctrl-cherryview.c index 067b0d344f0e..d1315cf027ce 100644 --- a/drivers/pinctrl/intel/pinctrl-cherryview.c +++ b/drivers/pinctrl/intel/pinctrl-cherryview.c @@ -1146,11 +1146,6 @@ static int chv_gpio_get_direction(struct gpio_chip *= chip, unsigned int offset) return GPIO_LINE_DIRECTION_IN; } =20 -static int chv_gpio_direction_input(struct gpio_chip *chip, unsigned int o= ffset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int chv_gpio_direction_output(struct gpio_chip *chip, unsigned int = offset, int value) { @@ -1163,7 +1158,7 @@ static const struct gpio_chip chv_gpio_chip =3D { .request =3D gpiochip_generic_request, .free =3D gpiochip_generic_free, .get_direction =3D chv_gpio_get_direction, - .direction_input =3D chv_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D chv_gpio_direction_output, .get =3D chv_gpio_get, .set =3D chv_gpio_set, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 42B1FCDB483 for ; Tue, 17 Oct 2023 12:10:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234525AbjJQMKE (ORCPT ); Tue, 17 Oct 2023 08:10:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59236 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343784AbjJQMJ0 (ORCPT ); Tue, 17 Oct 2023 08:09:26 -0400 Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 54B262693 for ; Tue, 17 Oct 2023 05:05:44 -0700 (PDT) Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2c5056059e0so60233491fa.3 for ; Tue, 17 Oct 2023 05:05:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544343; x=1698149143; darn=vger.kernel.org; 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=O3y3UgqVY6nN2yuJKg1qLnssekXYPB1hZ4I9p5/uy+k=; b=xwHlbuDzt2SzWHX3ZUsSQijj9TcUNwYqPkN+PAB9EfN6AfIliL2GO9+nGQ6Ibm10/N VwLbbliD9ONy4RbcJ+dF/vyXvzx8mo97EVMXvgG1EAuiEeBrB0OC/t8i0ASLOI/Q5KVU /pD8tOgMLKRr/9GF6E8mO/2qqDDS29C6uPGFA4QebLSY0jPWPHlPxLW4yDDHzs6NulMP J4+MANeTtMv+x4hk03i3ZCIrl3WYMkgXTyOfb3Hz+5fFPp7oH+a3iDpO9f6JV5yjgdvq AmWargOYvQhJpAqAd39C1n4gpFOFjtwYca87lyGVsO+zxUFhvc38e3MlAMUbGYk4ZFeX Dd2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544343; x=1698149143; 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=O3y3UgqVY6nN2yuJKg1qLnssekXYPB1hZ4I9p5/uy+k=; b=o5bbMAhiX18u2zf3UQfTuR/C4AXDkW8P2xS4+uM8WiPPQD837Xt/f2znHigeWp+e1i ELEdN9OqW5wMJq2vgT+oX6ADas044aUK3gA2gtPXSkXARQgaloAci6uaKhB2vjlJwFzS PaypHR99VAPYbYiL5nBZU3wIAE3VJsnghHZbqvRy0Jvn46+snsndh4aDV9U+GMMF4gHS XpS8zHKQU11/tLhGMqTknmysOzI7niiB/DCemxTOvdTJ9N1gP0oyZo8Jf8Usq0xcqNQe ypyuTFxoYqel81vKnFKrgs2qSo3983UV1n/j1Z8GWqC6RjwS3xJ9270mkkxmHBqfzg1v o+KQ== X-Gm-Message-State: AOJu0YxhbzfnbYDU6mjVClUY6Y5sA/bqPDEygSHFfxVGvdysuO/uyB40 ZrSVtTF+iBmDhGsBto3x+9jSxw== X-Google-Smtp-Source: AGHT+IF6ECMWmhqjzqbgShi0omVxCc5i3+lrCmLK5UV9zA2MGFiXGSi3U8Akd0N4yBX0NbciHbXrxA== X-Received: by 2002:a2e:a44b:0:b0:2bc:dcd6:97b1 with SMTP id v11-20020a2ea44b000000b002bcdcd697b1mr1390356ljn.47.1697544342875; Tue, 17 Oct 2023 05:05:42 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:42 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 56/73] pinctrl: st: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:14 +0200 Message-Id: <20231017120431.68847-57-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop it. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-st.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/drivers/pinctrl/pinctrl-st.c b/drivers/pinctrl/pinctrl-st.c index db511dbd50e5..1485573b523c 100644 --- a/drivers/pinctrl/pinctrl-st.c +++ b/drivers/pinctrl/pinctrl-st.c @@ -717,13 +717,6 @@ static void st_gpio_set(struct gpio_chip *chip, unsign= ed offset, int value) __st_gpio_set(bank, offset, value); } =20 -static int st_gpio_direction_input(struct gpio_chip *chip, unsigned offset) -{ - pinctrl_gpio_direction_input(chip, offset); - - return 0; -} - static int st_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { @@ -1330,7 +1323,7 @@ static int st_gpio_irq_request_resources(struct irq_d= ata *d) { struct gpio_chip *gc =3D irq_data_get_irq_chip_data(d); =20 - st_gpio_direction_input(gc, d->hwirq); + pinctrl_gpio_direction_input(gc, d->hwirq); =20 return gpiochip_reqres_irq(gc, d->hwirq); } @@ -1488,7 +1481,7 @@ static const struct gpio_chip st_gpio_template =3D { .free =3D gpiochip_generic_free, .get =3D st_gpio_get, .set =3D st_gpio_set, - .direction_input =3D st_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D st_gpio_direction_output, .get_direction =3D st_gpio_get_direction, .ngpio =3D ST_GPIO_PINS_PER_BANK, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0D4A6C41513 for ; Tue, 17 Oct 2023 12:21:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235215AbjJQMVL (ORCPT ); Tue, 17 Oct 2023 08:21:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48786 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235184AbjJQMUx (ORCPT ); Tue, 17 Oct 2023 08:20:53 -0400 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 493EF269E for ; Tue, 17 Oct 2023 05:05:45 -0700 (PDT) Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-2c51388ccebso38607761fa.3 for ; Tue, 17 Oct 2023 05:05:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544344; x=1698149144; darn=vger.kernel.org; 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=o1iLMtevXqv9Kk30l8xkOyL7j4m4nBnZ6GmTsolOeXI=; b=O97EudNVovcb0qpaj6WbMdhCSA2OhxBf31LcRXLw95bnn6b2/b/PqyGGXTSZAkCiVK DuqWwWt//1a1beR0XKEMbo3kkI6FNJOrqV0LUWRU/v9rtvtb0dsDo8QCM1aHVmpEZMHf zNPId+qTRkQOKb4Mh442kdD3LslFrk+18ou/fpkjfIUqBju3XG3V0gPf917RfBaZLOZJ oNLR4AD14I8VRTAhmWmgBFa0NANtrCeJlQ6VFxKhJfV+f2ZqvYCf6xLTEjYwP/AkA0qM yWUIl1QTtK9uR5kIig7o4zjd8uD7XM1nkXMKTn0UUz3LJP0P96jzJ2sbSxFdSr4lCI/o toMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544344; x=1698149144; 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=o1iLMtevXqv9Kk30l8xkOyL7j4m4nBnZ6GmTsolOeXI=; b=a0Wyj1KAKTJh879IjFVI/xJWsMGsjpuHd+2VlSLDBQ+ZNiL7v/v9PNbkBkNPhYeYWU GqssKRZJ1S6GnfoLg6YuAzVhvYrltHFKUn5hrZxwQYO43mZ9f7Ko812zvgDRpGePE50/ rxj5XslLjpT1yDlekrBs4tTiIDHzdKFqHop8R9F6rnLStVPdSXiBC9VdXAKjfvjltc/4 AQViq9C2Fx2xYBdrRjP2Ms2rVYE3meH7p6i8qmcIQUUSXKmdhU/9zFiVsfSdzeNj8AD8 qf3A6FwfYJyPX7aJL0BxxWK3HfrAYVJCMxLlOYcM8Goaoh6uBH+RiUnxmAnoBIzVzG4d n8bw== X-Gm-Message-State: AOJu0YypyWA0qKGyYMdG1stA4Es0P3TNxbPhfj7qDOc2/HNk5/Mpq10Y EgR2rEOIyvw9KiGX/Bjhoq3Rqg== X-Google-Smtp-Source: AGHT+IGIhyvVVbD8TxHXLHtevk8gNVe0Lr5ecjDDfhwX8W5M+5ZF9ZmG97gs+TOH9v37zALtgq7KMg== X-Received: by 2002:a2e:8ec5:0:b0:2c5:19ea:b6ac with SMTP id e5-20020a2e8ec5000000b002c519eab6acmr1587986ljl.21.1697544343973; Tue, 17 Oct 2023 05:05:43 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:43 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 57/73] pinctrl: ingenic: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:15 +0200 Message-Id: <20231017120431.68847-58-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-ingenic.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/drivers/pinctrl/pinctrl-ingenic.c b/drivers/pinctrl/pinctrl-in= genic.c index ca58c9db5c2c..ee718f6e2556 100644 --- a/drivers/pinctrl/pinctrl-ingenic.c +++ b/drivers/pinctrl/pinctrl-ingenic.c @@ -3560,12 +3560,6 @@ static int ingenic_gpio_get(struct gpio_chip *gc, un= signed int offset) return (int) ingenic_gpio_get_value(jzgc, offset); } =20 -static int ingenic_gpio_direction_input(struct gpio_chip *gc, - unsigned int offset) -{ - return pinctrl_gpio_direction_input(gc, offset); -} - static int ingenic_gpio_direction_output(struct gpio_chip *gc, unsigned int offset, int value) { @@ -3680,7 +3674,7 @@ static int ingenic_gpio_irq_request(struct irq_data *= data) irq_hw_number_t irq =3D irqd_to_hwirq(data); int ret; =20 - ret =3D ingenic_gpio_direction_input(gpio_chip, irq); + ret =3D pinctrl_gpio_direction_input(gpio_chip, irq); if (ret) return ret; =20 @@ -4197,7 +4191,7 @@ static int __init ingenic_gpio_probe(struct ingenic_p= inctrl *jzpc, =20 jzgc->gc.set =3D ingenic_gpio_set; jzgc->gc.get =3D ingenic_gpio_get; - jzgc->gc.direction_input =3D ingenic_gpio_direction_input; + jzgc->gc.direction_input =3D pinctrl_gpio_direction_input; jzgc->gc.direction_output =3D ingenic_gpio_direction_output; jzgc->gc.get_direction =3D ingenic_gpio_get_direction; jzgc->gc.request =3D gpiochip_generic_request; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6C082CDB474 for ; Tue, 17 Oct 2023 12:08:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343626AbjJQMI0 (ORCPT ); Tue, 17 Oct 2023 08:08:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59110 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343620AbjJQMH0 (ORCPT ); Tue, 17 Oct 2023 08:07:26 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C4F726A9 for ; Tue, 17 Oct 2023 05:05:46 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-40806e4106dso2994965e9.1 for ; Tue, 17 Oct 2023 05:05:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544344; x=1698149144; darn=vger.kernel.org; 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=G7vwTYIFniGiyz7XRLA7xg+vLp9rwMPLvTrSR1tRaqM=; b=nukhAjCGdeoLzDn4zvxP8sKIiwsjZzUizJ21uBsT2vzDuxr0gbiWrOmMFjWrYgnFC9 S1w4vqEJM8u6MkhL2xUAX5yaLffzgmWIN0srq+r2Evi0cTDyWzZUc27bX+N218TwhrLJ FGOIxkrjCwBtfmUIpFSXetwqAKrE/84XcDUpfI5XdckWQPPxvQ0vKtEOVGNZT/O0UEZG ghwbtAHY1nq5jRW1tVWBZhQdaCeMU9Y6OPe91b5444CjwbFAzOqFXjYOSOegQjI9qlDL TAvbwnpRBrC+6MoLkT/UX1i+KiZ/JVko6yZlX2/GL1ls86ahYi8d/nGiWR2DgILipzG/ fqog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544344; x=1698149144; 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=G7vwTYIFniGiyz7XRLA7xg+vLp9rwMPLvTrSR1tRaqM=; b=o9Ln29gJRZhltuph+rGo7XXp0xGhkqy1UfAFQNC1RcC5P89sAhClqShyXp2Azk8oUX 2XJsQGTyS8P9VkvhTMByqDWo0tBVtthGMb+BSwyqSeNxmchQLlKJYk54ryMCtDvlggoM ESbTOgfJUt8gOIhjsLRLWORGHnkg1f0sYbM9IsOSgnU/v8QOURbIxsoQojIGKwNONKYx hQh3oe1NIoUEStc4MbW0qqdu1+gmOlxJC+obJZ1tl43I0eLexYY8Oo+gcCo8eNNmakq3 sMq2HsuAl0176JeFFCoMbPpS7lt5XouINGV3oeO/kTahoJaznrBGPiDM9Uh9gHDk8SYC Fo+Q== X-Gm-Message-State: AOJu0YxppnFaxTb/S9NVggdrtgTQUN40ViKN7fN5WyZEywjHdLrWVQIF 0TssqWjZgHGCGMwKD1q2G84tpw== X-Google-Smtp-Source: AGHT+IFIgfi7pZ3g+7aVZOm45Ji9thDsax/eelHNrrvfzHb5t4na36ifzcVgwLAo0t47nAKQBKWORQ== X-Received: by 2002:a05:600c:3b82:b0:406:80b4:efd5 with SMTP id n2-20020a05600c3b8200b0040680b4efd5mr1581862wms.14.1697544344711; Tue, 17 Oct 2023 05:05:44 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:44 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 58/73] pinctrl: as3722: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:16 +0200 Message-Id: <20231017120431.68847-59-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-as3722.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/pinctrl-as3722.c b/drivers/pinctrl/pinctrl-as3= 722.c index 5ebd1939663f..6a5f23cf7a2a 100644 --- a/drivers/pinctrl/pinctrl-as3722.c +++ b/drivers/pinctrl/pinctrl-as3722.c @@ -500,11 +500,6 @@ static void as3722_gpio_set(struct gpio_chip *chip, un= signed offset, "GPIO_SIGNAL_OUT_REG update failed: %d\n", ret); } =20 -static int as3722_gpio_direction_input(struct gpio_chip *chip, unsigned of= fset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int as3722_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { @@ -526,7 +521,7 @@ static const struct gpio_chip as3722_gpio_chip =3D { .free =3D gpiochip_generic_free, .get =3D as3722_gpio_get, .set =3D as3722_gpio_set, - .direction_input =3D as3722_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D as3722_gpio_direction_output, .to_irq =3D as3722_gpio_to_irq, .can_sleep =3D true, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4C7E4CDB474 for ; Tue, 17 Oct 2023 12:09:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343563AbjJQMJN (ORCPT ); Tue, 17 Oct 2023 08:09:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60700 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234996AbjJQMHu (ORCPT ); Tue, 17 Oct 2023 08:07:50 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5794426A8 for ; Tue, 17 Oct 2023 05:05:47 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-407c3adef8eso4129595e9.2 for ; Tue, 17 Oct 2023 05:05:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544345; x=1698149145; darn=vger.kernel.org; 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=qZqsH4ukWg8dp7mZFhLrP2ADJHJW7V1bq0dpTxn7+d4=; b=Iq1DEkCJyf74Eh8GJ/Efr891aLtBnfMpBjFVOBThjueAGkIcYWTn84YwEg1jIkjkzj /1yLkN/BT5jJOkAQkOrxX7pX27R2YawzkBnpj0jhWgOfpaU5k3GXyPh/XgsE6upNz5bW /sSV/zYp1O7jO5+QES3HjYe5VSfUeHASkiMdsBEZ+BJMQOV1PCbsVKZwtS32sG93Cm9X YWDXIncFJ7iA6sjNDNa/UcuTT/QG4BRCXL6577wK4BMPaHnTW9VRCLCdiQiZ2etB+kCK 4ASmM0H7LYfSsmWnK6mDNs1boApbmLd7IKo7Zy0wIKN+PWpbM+zQXTbSl2zf0oZd+uT+ gCCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544345; x=1698149145; 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=qZqsH4ukWg8dp7mZFhLrP2ADJHJW7V1bq0dpTxn7+d4=; b=CbUQ9ieDTl1GY4LxwuBF7R7Pat2Y4f4xLb6CPZAwkmZBTMGTWKKxC9/E+q111Q30NE osinCFEizL//jjEVKUYwwp8uqxz84d8C/V8VwJTZVfMx2dX0tanq1uOj425RhSpFT0YY xz0nb//mziqKsjkyBA9SpC3IF0JmX16hxuKb5PfanqLGVHz27G46fVSO53SUk4bLrEsW FliQ+/GVvxLhqzfldRAGBcTSiIB4VQrfkmD9lidi7DIZLYnXNkEj18UdVkP6zSrFk0Un fLuIKrw2gqLTw1IjJLmGeaeo4A3IEA7I+8xhZ+7flKCdZTQfmKnmW0BSJpLVH6Fyht7K jMsg== X-Gm-Message-State: AOJu0Yy3VJbvutuZsvlkP/tXn8UimQm8n+CMFK/LZGaE9/O3a5NMogSt p5tS1z4puCJ87WoZKUhxNxkglw== X-Google-Smtp-Source: AGHT+IH0yWFOp9rKJ0cOBfUSaAmYAWjud/N6WGuc8A1DibebU/JZOq50dqOAWD6Ha/rOJpk+qlKpfw== X-Received: by 2002:a05:600c:1392:b0:405:3955:5872 with SMTP id u18-20020a05600c139200b0040539555872mr1630146wmf.18.1697544345467; Tue, 17 Oct 2023 05:05:45 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:45 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 59/73] pinctrl: cy8c95x0: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:17 +0200 Message-Id: <20231017120431.68847-60-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij Reviewed-by: Andy Shevchenko --- drivers/pinctrl/pinctrl-cy8c95x0.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/pinctrl-cy8c95x0.c b/drivers/pinctrl/pinctrl-c= y8c95x0.c index 04285c930e94..adecb7d85da1 100644 --- a/drivers/pinctrl/pinctrl-cy8c95x0.c +++ b/drivers/pinctrl/pinctrl-cy8c95x0.c @@ -552,11 +552,6 @@ static int cy8c95x0_read_regs_mask(struct cy8c95x0_pin= ctrl *chip, int reg, return ret; } =20 -static int cy8c95x0_gpio_direction_input(struct gpio_chip *gc, unsigned in= t off) -{ - return pinctrl_gpio_direction_input(gc, off); -} - static int cy8c95x0_gpio_direction_output(struct gpio_chip *gc, unsigned int off, int val) { @@ -814,7 +809,7 @@ static int cy8c95x0_setup_gpiochip(struct cy8c95x0_pinc= trl *chip) =20 gc->request =3D gpiochip_generic_request; gc->free =3D gpiochip_generic_free; - gc->direction_input =3D cy8c95x0_gpio_direction_input; + gc->direction_input =3D pinctrl_gpio_direction_input; gc->direction_output =3D cy8c95x0_gpio_direction_output; gc->get =3D cy8c95x0_gpio_get_value; gc->set =3D cy8c95x0_gpio_set_value; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3A085CDB482 for ; Tue, 17 Oct 2023 12:09:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343736AbjJQMJV (ORCPT ); Tue, 17 Oct 2023 08:09:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48702 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235046AbjJQMHw (ORCPT ); Tue, 17 Oct 2023 08:07:52 -0400 Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 98EC126B2 for ; Tue, 17 Oct 2023 05:05:48 -0700 (PDT) Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-40684f53ef3so59008325e9.3 for ; Tue, 17 Oct 2023 05:05:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544346; x=1698149146; darn=vger.kernel.org; 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=1fJ2QmhXWplWv9DEf43iP6RhPqRuukfw3F4hurk2iKc=; b=0md2dvRtqR2x5GkHHCg4ioGCoiPf3FwJgVndGKUXjO5Hxybp5BstnIK8HzFihYuUpn RWChBD5mUaftVlj9I98ajJlAU1SheBJ640pOAxdKeJtQG2R0k9ETd7Jan8BU9x6Jn6yy p60UCXSOrZ9TYN+xr3iIQlF0Df09oAoljm3B0Z118ae6dYXA57wPwtoY9PEa7Wu/H0jd ITLXG5T6es6S9tZWzyOiTwSrsu+/imM/lLoz8o+b1tjLTKmA2vwxqsFjFoV1cBo/paKu KePKM//OKFioXKgc3k/W9Yhy0JVX34d3tv8wN93GKRklfysGfapGlvWbLIaemW1Oj6x3 Y4LA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544346; x=1698149146; 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=1fJ2QmhXWplWv9DEf43iP6RhPqRuukfw3F4hurk2iKc=; b=Oc11RQOfhmTE6K3iKGl7W+NbExOprWbhPUGarJg4AcGIlOr0k0d2g6wj+D6DVuRaps E/yaSQV46XhGs+H6cbPwmcKPeo+Gz64pASb6dHoawXh8naLiD34O/2k+/jGhhkPKsd9z o1ab2MFOzK32HGxZMoQmBGpUcQwMKHE/x+0nZaJSU0YNb8Fs5ANukz/HhlmY9ALcvqm6 tLMz1mkHsnbxXAFC77o+Bn2OxmaXfrhEi//RRbUeD8cI7sAGAPjI75qXlkgbO6vxDyj6 6a/pGsMLMA0byKJQYoDIsWDLu0kEq9ZD7f+UD8cFYW/pfoYYZr27JarL+JVXGMH/lG1G oZaw== X-Gm-Message-State: AOJu0YwNfkHn49EvuHZekxvgrg8rJuJHqy4ZmJTIfB+8eN1AKdDIfaZ3 ALlPiovpJYaOewp6zabuTn4Czw== X-Google-Smtp-Source: AGHT+IFrm8m6PkO2MeoJBk8M+cQ5If/Je9u9hgzNaFX6Deg2XbQvzpcCpeRdkVruesr+LhmTiyHeDA== X-Received: by 2002:a05:600c:46c3:b0:407:5adc:4497 with SMTP id q3-20020a05600c46c300b004075adc4497mr1544354wmo.9.1697544346333; Tue, 17 Oct 2023 05:05:46 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:45 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 60/73] pinctrl: vt8500: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:18 +0200 Message-Id: <20231017120431.68847-61-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/vt8500/pinctrl-wmt.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/vt8500/pinctrl-wmt.c b/drivers/pinctrl/vt8500/= pinctrl-wmt.c index 639446bba373..fce92111a32e 100644 --- a/drivers/pinctrl/vt8500/pinctrl-wmt.c +++ b/drivers/pinctrl/vt8500/pinctrl-wmt.c @@ -526,11 +526,6 @@ static void wmt_gpio_set_value(struct gpio_chip *chip,= unsigned offset, wmt_clearbits(data, reg_data_out, BIT(bit)); } =20 -static int wmt_gpio_direction_input(struct gpio_chip *chip, unsigned offse= t) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int wmt_gpio_direction_output(struct gpio_chip *chip, unsigned offs= et, int value) { @@ -544,7 +539,7 @@ static const struct gpio_chip wmt_gpio_chip =3D { .request =3D gpiochip_generic_request, .free =3D gpiochip_generic_free, .get_direction =3D wmt_gpio_get_direction, - .direction_input =3D wmt_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D wmt_gpio_direction_output, .get =3D wmt_gpio_get_value, .set =3D wmt_gpio_set_value, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4673BCDB474 for ; Tue, 17 Oct 2023 12:09:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343629AbjJQMJR (ORCPT ); Tue, 17 Oct 2023 08:09:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36494 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232984AbjJQMHw (ORCPT ); Tue, 17 Oct 2023 08:07:52 -0400 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2151C270E for ; Tue, 17 Oct 2023 05:05:49 -0700 (PDT) Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-50305abe5f0so7345230e87.2 for ; Tue, 17 Oct 2023 05:05:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544347; x=1698149147; darn=vger.kernel.org; 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=hnHBRfmIODSTWCjwzxjk920VZIB9kQcoosTVsaf2qL0=; b=DPTny//8JkPTV/yeGyGgKFrQ90kOmCAjy6nNMQFWIAIm9t7EY8tMfrO9bPMN6SPiTb sLtT6enM6yntjK3S4lcKIq8bi0ku8fX/c4UEBMLwZr0zHLvjDNLyQDDNYM11sOKdb3MT DtoiKcjXY9wIqlqFw/7hB49aUetvIk7pYzrInLwMm3pBHjx5g8N2ZjYOkccc+94N3pS0 CIs1eSMVfAo9VPtj1IvPMgHpmqMoQENCNoSaDUW5jObvHwsEWCXvRUVF0icFD/aYMywi X1BlJV+DQs3PG4R+TEBeMpfbejKFdTiYUOOqm83K09YsopPHJ5DvvCZFyD7IKksgr+Qa 029w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544347; x=1698149147; 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=hnHBRfmIODSTWCjwzxjk920VZIB9kQcoosTVsaf2qL0=; b=tVg4bpO6GqwZ/DlN8fXH/qpYYjnpbbbJqUsbxiRJCKbpLqPKOBEFIZt8KEYjS4lgNp ywh5eKSifmO6Qt0vL660S2Q7uGNwjDNfR7cfdqWLFstLsFO9IyOTwNX/x2WC5FDDJQMw 1IvTXak5aXbPe+vZpDAx2231HGzCmHv+yD3OvLQBpIdJhdIcnWZX8yD43FztCLow4pob BrklJ14MvpDlttlzZR8ZhTHnvEQRfd5ZoyxF3GCtOU8G4Hqfz/zv+ntpbl/4av6lTDQ5 FsG0NCNrWpJrykSXmHbdQoPlZ7pE7zjxqMnW/2jMPxtREfKhcITrMQ/NyO0n54BsjTaF G6/A== X-Gm-Message-State: AOJu0YzM9u7BkbURIQHCil+khcdw8OMa16L+C2a2Qy0zYS/AJ8oJOrZg W9St/z15cK83GJjUC7rrTpiIcg== X-Google-Smtp-Source: AGHT+IFI+8jFW5dfO7T9dgcHWZhR+S/KmvgCIN5BPI5Kwog50KV7w/GfkWP1rUvx1hp4i/9emVH/8A== X-Received: by 2002:a05:6512:3b14:b0:507:9fcf:42ce with SMTP id f20-20020a0565123b1400b005079fcf42cemr2026931lfv.57.1697544347127; Tue, 17 Oct 2023 05:05:47 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:46 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 61/73] pinctrl: axp209: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:19 +0200 Message-Id: <20231017120431.68847-62-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-axp209.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/pinctrl-axp209.c b/drivers/pinctrl/pinctrl-axp= 209.c index a6eb3b866a23..2b4805e74eed 100644 --- a/drivers/pinctrl/pinctrl-axp209.c +++ b/drivers/pinctrl/pinctrl-axp209.c @@ -124,11 +124,6 @@ static int axp20x_gpio_get_reg(unsigned int offset) return -EINVAL; } =20 -static int axp20x_gpio_input(struct gpio_chip *chip, unsigned int offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int axp20x_gpio_get(struct gpio_chip *chip, unsigned int offset) { struct axp20x_pctl *pctl =3D gpiochip_get_data(chip); @@ -474,7 +469,7 @@ static int axp20x_pctl_probe(struct platform_device *pd= ev) pctl->chip.get =3D axp20x_gpio_get; pctl->chip.get_direction =3D axp20x_gpio_get_direction; pctl->chip.set =3D axp20x_gpio_set; - pctl->chip.direction_input =3D axp20x_gpio_input; + pctl->chip.direction_input =3D pinctrl_gpio_direction_input; pctl->chip.direction_output =3D axp20x_gpio_output; =20 pctl->desc =3D of_device_get_match_data(dev); --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B5690CDB474 for ; Tue, 17 Oct 2023 12:08:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235017AbjJQMI4 (ORCPT ); Tue, 17 Oct 2023 08:08:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343585AbjJQMHp (ORCPT ); Tue, 17 Oct 2023 08:07:45 -0400 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2087F270B for ; Tue, 17 Oct 2023 05:05:49 -0700 (PDT) Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-40572aeb73cso55558495e9.3 for ; Tue, 17 Oct 2023 05:05:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544348; x=1698149148; darn=vger.kernel.org; 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=4mWMEsrepSOyp3f33hvoi4PwifoeQU9K1dcaB1U/fvQ=; b=lt0otnXuA0fRwjdGxBS2T9ffQSHVaBNOdDaKniXDdeNy7j2ytKFjfILQlMOABif4v5 16/6pvzYJBI7jpAgtn7hxIXl4IUVJjp9YIo47bZ4JI0TAoeDExCrEq/Wz5wTV7TMkXvO E59NILp9WCG6rBx7SSYXs92BnlgWFHCcGE0NluvYajj3g4CkahAxhHdTNa34q7SkzmyW u1z8BHEUPbfBAQcAo/Mg88szNqb7O3l3YKyfcFRE0N7NsQbCjBO0RIFKlWuQFzMLa2j/ Y9Ftd8/KZ0iWOYLAudHq4JX2q5plQj7qR/wwwaRBJXfp6+/2JMDtKf+ivybMqJCLt3vh NHdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544348; x=1698149148; 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=4mWMEsrepSOyp3f33hvoi4PwifoeQU9K1dcaB1U/fvQ=; b=BMedJUjs5/7a9U7rYxy2txK5cGxIpja7m9HCmnAEES8KY8mbZtFPXSFwUGaBlovFdn 0GhXyWVmnXRR4kxqDNePGBvkjLAisbTBy57eMSKIhZkbS5DuUH3ni2wOeWD5KRJlUgQI isoYS0/qXWB9s7QUeVsUw9ndCf09zC830LM6ytCFlvEhOa1eJXoFNcoqv1pUBo+O0DcQ pbJlPI1V4NVX7Gv6WiZ/Scw9ewgxgy6E5d6VuMUGJ/oN1wAhX7t+Oh67GDYoynYqUjTt SPHz3ELSkxzoHdYB2SRNUQDmnGnykUzrxyVFYWVbPUQf28uH33KIdYwM6KRbdMRk2DMB EVOg== X-Gm-Message-State: AOJu0YydLxjCdY1MxqQFH+CmuhMFZcF4wlQ6xa6h8P5tm+DzbxxKHrGj 9VFp/H+31TQEskvHbw4bSP8cug== X-Google-Smtp-Source: AGHT+IG8mdi9OfL/mb4nEczReux6y+URj0QBaTlkrL93RcdQsWKDQTtHT10AMRkdA0nw1j2biSEk8w== X-Received: by 2002:a05:600c:1d94:b0:404:74e3:27a4 with SMTP id p20-20020a05600c1d9400b0040474e327a4mr1593975wms.40.1697544348017; Tue, 17 Oct 2023 05:05:48 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:47 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 62/73] pinctrl: rk805: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:20 +0200 Message-Id: <20231017120431.68847-63-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-rk805.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/pinctrl/pinctrl-rk805.c b/drivers/pinctrl/pinctrl-rk80= 5.c index 968f066eb9da..56d916f2cee6 100644 --- a/drivers/pinctrl/pinctrl-rk805.c +++ b/drivers/pinctrl/pinctrl-rk805.c @@ -286,12 +286,6 @@ static void rk805_gpio_set(struct gpio_chip *chip, offset, value); } =20 -static int rk805_gpio_direction_input(struct gpio_chip *chip, - unsigned int offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int rk805_gpio_direction_output(struct gpio_chip *chip, unsigned int offset, int value) { @@ -330,7 +324,7 @@ static const struct gpio_chip rk805_gpio_chip =3D { .get_direction =3D rk805_gpio_get_direction, .get =3D rk805_gpio_get, .set =3D rk805_gpio_set, - .direction_input =3D rk805_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D rk805_gpio_direction_output, .can_sleep =3D true, .base =3D -1, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4C74ECDB483 for ; Tue, 17 Oct 2023 12:09:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235035AbjJQMJB (ORCPT ); Tue, 17 Oct 2023 08:09:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36428 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343703AbjJQMHq (ORCPT ); Tue, 17 Oct 2023 08:07:46 -0400 Received: from mail-lj1-x22b.google.com (mail-lj1-x22b.google.com [IPv6:2a00:1450:4864:20::22b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8F72E2711 for ; Tue, 17 Oct 2023 05:05:50 -0700 (PDT) Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-2c53c5f7aaaso5720011fa.0 for ; Tue, 17 Oct 2023 05:05:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544349; x=1698149149; darn=vger.kernel.org; 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=U6y2fYAElMK3+9pk+W11zZcwrJV986RWR1hlU2SY+8Q=; b=pHXetQdlnqM/PILM0DQmHEJEQIT4tt2KAEVKB27+l378t4fVg4MST6JUl7LN8WkZ3W AmRHS0g4n/sd02aWw0kFBgCXG89DImfWL2Gz+O++7bdZ+30Jp0fz4Yrh3OGt6emXBM+O a8QDY9Kl4/Z7C/DqOhXb34FvL9F2aK7xEcEKCttQQlRJK6Obfsop1ERXJERnRO0Bsuaz b6rRQjxqqRD7uxDCVHhwU7c61BR8WM55Rd6fsoruHT9kXpM+nWagQ4swB8UEfaoqwN6m qH7/CHcPRbyJtHJCIz7atJm63RtHCh2o7EcmJmPfo30sg7+VR2njAaaaLtHFa/JaYMdZ n/Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544349; x=1698149149; 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=U6y2fYAElMK3+9pk+W11zZcwrJV986RWR1hlU2SY+8Q=; b=gXtaKDyQ/duyr59aml9AwW2Z7y44OKBJaKSvm3P3A7hx4H/i6Mga+8eiV0OLOsDNXw F6TzWtHAqfuhuCjnJGfh651uAeh4BLdJ9/n8Xu8i2V6P7B7m6A/leluVFTCD5r39reZ9 8ce5IP1EyaUtMEOkf3ymnBS4iu6+cPZGMB0FyZZZtxTzjhyJOIAsR6h8MGWzcb1VEvAE ptRFC1MSMXRBzaxWMUs4KOd4+M0INWEeWxJ85rSpxFVT0LKOHzwBNAsq9L57Tpi3Bhrt Nf4+eLLd3WdC0pSeIQHyumu1ad+41TQcfvWcHAouMwQjM9WVspev1QTODCmBxLRz6DLF 0TnQ== X-Gm-Message-State: AOJu0YyfXRf5vwG5vBxK72c0ExH2GJmdvbVpo50PaYRcr7T2gVmtPdgK aXn6q/4jcjh33Q6LlpwiM37vE7P34n9XbNYiiI8= X-Google-Smtp-Source: AGHT+IHUy24UWBIJaS9b96FoOT4wD4I4WLrdfwflESnQjHgtLwgxwa97eFVem8CyyrWWcBpnxTt0Pw== X-Received: by 2002:a2e:a58c:0:b0:2c5:8a4:9e6f with SMTP id m12-20020a2ea58c000000b002c508a49e6fmr1501787ljp.37.1697544348815; Tue, 17 Oct 2023 05:05:48 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:48 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 63/73] pinctrl: mediatek: moore: drop the wrappers around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:21 +0200 Message-Id: <20231017120431.68847-64-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrappers around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/mediatek/pinctrl-moore.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/mediatek/pinctrl-moore.c b/drivers/pinctrl/med= iatek/pinctrl-moore.c index c3f33f96f920..c3d59eddd994 100644 --- a/drivers/pinctrl/mediatek/pinctrl-moore.c +++ b/drivers/pinctrl/mediatek/pinctrl-moore.c @@ -510,11 +510,6 @@ static void mtk_gpio_set(struct gpio_chip *chip, unsig= ned int gpio, int value) mtk_hw_set_value(hw, desc, PINCTRL_PIN_REG_DO, !!value); } =20 -static int mtk_gpio_direction_input(struct gpio_chip *chip, unsigned int g= pio) -{ - return pinctrl_gpio_direction_input(chip, gpio); -} - static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned int = gpio, int value) { @@ -569,7 +564,7 @@ static int mtk_build_gpiochip(struct mtk_pinctrl *hw) chip->parent =3D hw->dev; chip->request =3D gpiochip_generic_request; chip->free =3D gpiochip_generic_free; - chip->direction_input =3D mtk_gpio_direction_input; + chip->direction_input =3D pinctrl_gpio_direction_input; chip->direction_output =3D mtk_gpio_direction_output; chip->get =3D mtk_gpio_get; chip->set =3D mtk_gpio_set; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 824D2CDB474 for ; Tue, 17 Oct 2023 12:08:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343542AbjJQMIn (ORCPT ); Tue, 17 Oct 2023 08:08:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59296 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343675AbjJQMHj (ORCPT ); Tue, 17 Oct 2023 08:07:39 -0400 Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9E0CF2713 for ; Tue, 17 Oct 2023 05:05:52 -0700 (PDT) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40572aeb73cso55558775e9.3 for ; Tue, 17 Oct 2023 05:05:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544349; x=1698149149; darn=vger.kernel.org; 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=UlzkIOQCjUnaLQIijso5Hp4dS0y/amt7GTYGhDxNGpk=; b=vILeJu/SGi8uYS7u4bdsmG8n+Jt2CcWOXKNhBuN6LgS5+tB8xba+e8mkgpwF4P/B4t 6bwraGL59wnQoyCYAT3Fpo72ThdLRCmyCC5JoQ4bUIWMPkvXdFmq1P6qylCXLQQE7DSP tPDee4dG7B9jyaPG0NiK3f/ydnMLIk3VwEQRQzucdnQibu0MiFjr0EiPjWro4xmYgXvY l/+xv5S0NjwOh1x0CuavjlJvOiqsMWnBSHapiR7EEU6cHgyMNb4gPuAr/xw7NWJhBvOo HT/GATKUD5GpY1Cx4OcooAF3WLcG3AXZvvk92ZsAz2ZmqR7SueGc+4QiPQAoWd0QNWpQ qNQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544349; x=1698149149; 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=UlzkIOQCjUnaLQIijso5Hp4dS0y/amt7GTYGhDxNGpk=; b=OzZKgKvNJON95Oe5KKnku6IvagA3D0GhhtdgqWtjbSp8wp3BJuerfTbYb/hIydLtdT fHqSIKkyuni2GyW8R/DigDOm6UzPK2J9wOPTPg7uwlwRmC48qommxczidpmwoVnBHHgI fzjwc5qx2OZAMaTaU+F2afdO44M013A0DRb4QwK6XDozQqOB32+tQbwdQCL2k90i2z3z fp+exXB+J7sLGlP3qHZVqA4TXMHll9G5Vf5HCXPz2QdAJMRrqb6Ffpsc2JlguGSAHd19 cVte9gtmnrSmhcoBxyhYLqMP6GwR2yjZhSs3c4JdYmXUStPsHr+pHCVr6iZREAJ4hR2J BbfA== X-Gm-Message-State: AOJu0YwXU2pJU/Bds7dcQSkVeyTp8s6u+pXMf+7dHFWJ3bxKHwh7W78B k+8ibgMvpAm8VFv6znPBAIPirA== X-Google-Smtp-Source: AGHT+IHKAhNxHGMZwD12fpBu9rtiYo7vwmeRY7ABks2s9oTibAZ6b5mFhWbrDyN7Os3NcQouNImWvw== X-Received: by 2002:a05:600c:1392:b0:406:513d:7373 with SMTP id u18-20020a05600c139200b00406513d7373mr1749009wmf.11.1697544349588; Tue, 17 Oct 2023 05:05:49 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:49 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 64/73] pinctrl: mediatek: common: drop the wrappers around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:22 +0200 Message-Id: <20231017120431.68847-65-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrappers around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/mediatek/pinctrl-mtk-common.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c b/drivers/pinctr= l/mediatek/pinctrl-mtk-common.c index 41e9847e3085..e79d66a04194 100644 --- a/drivers/pinctrl/mediatek/pinctrl-mtk-common.c +++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common.c @@ -808,12 +808,6 @@ static const struct pinmux_ops mtk_pmx_ops =3D { .gpio_request_enable =3D mtk_pmx_gpio_request_enable, }; =20 -static int mtk_gpio_direction_input(struct gpio_chip *chip, - unsigned offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int mtk_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { @@ -898,7 +892,7 @@ static const struct gpio_chip mtk_gpio_chip =3D { .request =3D gpiochip_generic_request, .free =3D gpiochip_generic_free, .get_direction =3D mtk_gpio_get_direction, - .direction_input =3D mtk_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D mtk_gpio_direction_output, .get =3D mtk_gpio_get, .set =3D mtk_gpio_set, --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9EAE2CDB474 for ; Tue, 17 Oct 2023 12:09:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234867AbjJQMJJ (ORCPT ); Tue, 17 Oct 2023 08:09:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43360 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343736AbjJQMHt (ORCPT ); Tue, 17 Oct 2023 08:07:49 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C052D2717 for ; Tue, 17 Oct 2023 05:05:52 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-4079ed65471so4281465e9.1 for ; Tue, 17 Oct 2023 05:05:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544350; x=1698149150; darn=vger.kernel.org; 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=+7umkbBqVb4ekwk4qPLSYyQOmuMCZz6eMQtDEbYpxk8=; b=DTbSWCKpDG/jUEeSfmrLvMU4MEY1pibSgoetUeyDSc+/x0/6lvrx1lUTQUwLlMPyFZ VSNeSdC/2VI8jagtMok7JI1bi94Nl/Tnq5EOYnK0bE21KdudYVkcXnqXqMfErbtzj7Z9 M1WfIMhRYbUYl8U9PfX/+Oy2IrkdGqNmnZ63LFCw9zJATt4/Jirw8c1+PuILFjIgke6q gqHKxL3s2WehVnFzCQyRA36cSeCWljMVTxrAu+y/vQn2MjINnuCd47u1Kmdl9SC8BOLe hE22VdKyJ2IDvyiRBK8eW0AxnLBJTGbuAMOA3M1fxrvrMjPEDHfK+8yySMlsaBk8cd0L Mhzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544350; x=1698149150; 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=+7umkbBqVb4ekwk4qPLSYyQOmuMCZz6eMQtDEbYpxk8=; b=CIxvWdQ4r8IFVjsBhvhmCMrKByH9hiaA74T8tFnw3zZE/Z7xTH2fCXoOWvHtFnZr7W 8wpB/3sUBPHR9fSP0b2csfi3VbR1RT4slQSDKczA8OhMSurThvhCqsUR7DinJsT6tZN8 ocMblvi5TVtDQfrvH5rTGH75XStXuOV5kRVAsGdLXlpG4MoouGrl7/Senjfu+E7Eg2Ah r78j+wvnyxNT3UKuKIxbFa49y1+g9Z49kEHeg3uGzzS/XZN8xh36tToMC0fC9L5oAGno 2b32kvwn4Ysgn7slDPsOS6CvNLWe7SSUCGIeMxasJaPbRln7mxv7avR1affDa3Z4yvLw 27KA== X-Gm-Message-State: AOJu0Yz3EFXDatynjplgMSfTLkXjRKsbIsMJ9YhhbG+S9zJm14W+yudX dO5ap9tRYBRyVRaKUPkikefgxg== X-Google-Smtp-Source: AGHT+IE0eRbJCAPW2WyjT/DeIQ3VS3VGyTRM4QXko4rn1KqlJyr8bR674mvIx143owLp7uPcfTMmJg== X-Received: by 2002:a05:600c:1f8f:b0:406:849f:f3cd with SMTP id je15-20020a05600c1f8f00b00406849ff3cdmr1512482wmb.29.1697544350581; Tue, 17 Oct 2023 05:05:50 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:49 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 65/73] pinctrl: cirrus: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:23 +0200 Message-Id: <20231017120431.68847-66-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/cirrus/pinctrl-cs42l43.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c b/drivers/pinctrl/cir= rus/pinctrl-cs42l43.c index 1ba89cf279fb..012b0a3bad5a 100644 --- a/drivers/pinctrl/cirrus/pinctrl-cs42l43.c +++ b/drivers/pinctrl/cirrus/pinctrl-cs42l43.c @@ -506,11 +506,6 @@ static void cs42l43_gpio_set(struct gpio_chip *chip, u= nsigned int offset, int va pm_runtime_put(priv->dev); } =20 -static int cs42l43_gpio_direction_in(struct gpio_chip *chip, unsigned int = offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int cs42l43_gpio_direction_out(struct gpio_chip *chip, unsigned int offset, int value) { @@ -551,7 +546,7 @@ static int cs42l43_pin_probe(struct platform_device *pd= ev) =20 priv->gpio_chip.request =3D gpiochip_generic_request; priv->gpio_chip.free =3D gpiochip_generic_free; - priv->gpio_chip.direction_input =3D cs42l43_gpio_direction_in; + priv->gpio_chip.direction_input =3D pinctrl_gpio_direction_input; priv->gpio_chip.direction_output =3D cs42l43_gpio_direction_out; priv->gpio_chip.add_pin_ranges =3D cs42l43_gpio_add_pin_ranges; priv->gpio_chip.get =3D cs42l43_gpio_get; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 83D66CDB474 for ; Tue, 17 Oct 2023 12:21:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235183AbjJQMVl (ORCPT ); Tue, 17 Oct 2023 08:21:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48806 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235113AbjJQMVZ (ORCPT ); Tue, 17 Oct 2023 08:21:25 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5243B272A for ; Tue, 17 Oct 2023 05:05:54 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id 38308e7fff4ca-2bb9a063f26so70235391fa.2 for ; Tue, 17 Oct 2023 05:05:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544351; x=1698149151; darn=vger.kernel.org; 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=8hYD07DORFpnS7uYBoHZE2h5e1OIf1dxiUrdwCdcwh8=; b=YIu5VoLUyDZdc4GzzY4yeQngmFMEqNxsOge6vYW5iH6Z1pTmdpXiQBZF2X7ZsyWg8U WK1l3RrgIux+ccszK1RyYVF64sdX8L0BwbjX9LxCSBqZqt+1n0uv5AEK1oz1kDRsMHRI KPbMILCveEPNjjSZWQ3VC7GZzgjP1zbiBnRJfeHOZmeAOrNnkWFKcl+GImw0dahe8qeC ZNCLDrzKoXGUUJiw/jZrx8qzqIRan86FjkUbQZdIhc+02ku+R4TtUljU6WYTnm7sOkO8 VivntbruAkQMGVJ0/x68mf3/LRJxO/1ebgcTNeSSejzjJOqHh4g/ZICj4MvProGVn4hs X2kQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544351; x=1698149151; 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=8hYD07DORFpnS7uYBoHZE2h5e1OIf1dxiUrdwCdcwh8=; b=YKMqfwEhzimoyWqJtQ3HTk9pB2aAlp2gUO1ts8B1d8YQfI/GuEYKNx8Mw+KHsRHF/0 8OSfAQOFv+zaw3RuEKFCmgQ2pty4RIo7qhfwn3lxbLD5UCzLPqiU10T1ZR+ZYhZqL4KB /9Z0BhUTDLaUGi/lPEF0MPcOeY5DgoV1TbCScRnApE0OBVXaZnFGPmgMhnMKVaKjR/7/ Mf5q4ik3q7IGGhUwuDXAO6cQCkkhwt1s3n4IIu0k0jGvj/hDOeUTtgQdQa/ykCXONFvF ymkmNsF5ZBLWTT4V9qtkN37mnY9PaISJUgGslhOaEv0E91liyTBJnXsodmIHE4Oqagt5 ADKA== X-Gm-Message-State: AOJu0YxttN6+xe/3ROIHA+/MGcmwcYFaSvL/3F4s1gwB++xReMp1Lv2N N7Cc5E1m37gpi2+3wGGcrFkIOzWsDNnVXphEYSA= X-Google-Smtp-Source: AGHT+IGHA0KTHjACmMppnOrbLys7zmg8kwaZANk8Z3VE+lQNYP7/N7ei5QDPueZ3kNClunLrIiSSvw== X-Received: by 2002:a2e:b893:0:b0:2c5:924:e8b1 with SMTP id r19-20020a2eb893000000b002c50924e8b1mr1638200ljp.19.1697544351561; Tue, 17 Oct 2023 05:05:51 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:50 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 66/73] pinctrl: ocelot: drop the wrapper around pinctrl_gpio_direction_input() Date: Tue, 17 Oct 2023 14:04:24 +0200 Message-Id: <20231017120431.68847-67-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_direction_input() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/pinctrl-ocelot.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-oce= lot.c index 96b4e9fceb78..52aadd6d72a8 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1776,12 +1776,6 @@ static int ocelot_gpio_get_direction(struct gpio_chi= p *chip, return GPIO_LINE_DIRECTION_IN; } =20 -static int ocelot_gpio_direction_input(struct gpio_chip *chip, - unsigned int offset) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int ocelot_gpio_direction_output(struct gpio_chip *chip, unsigned int offset, int value) { @@ -1804,7 +1798,7 @@ static const struct gpio_chip ocelot_gpiolib_chip =3D= { .set =3D ocelot_gpio_set, .get =3D ocelot_gpio_get, .get_direction =3D ocelot_gpio_get_direction, - .direction_input =3D ocelot_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D ocelot_gpio_direction_output, .owner =3D THIS_MODULE, }; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 17734CDB474 for ; Tue, 17 Oct 2023 12:09:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343730AbjJQMJF (ORCPT ); Tue, 17 Oct 2023 08:09:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51046 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343726AbjJQMHr (ORCPT ); Tue, 17 Oct 2023 08:07:47 -0400 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7BE9B272C for ; Tue, 17 Oct 2023 05:05:54 -0700 (PDT) Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-40806e4106dso2995865e9.1 for ; Tue, 17 Oct 2023 05:05:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544352; x=1698149152; darn=vger.kernel.org; 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=6qenkA6xUaauonLvrFTXXD5sPq5v8M/Ht2ghe2Ntrw0=; b=yl015W87x66JjdrmgBYlXhSC1ilptn8QMzY+J4MiiJ99/Arogz0msko+061uEx506q M7gQ18qfTXz4dsrb3q7DIr7kgEznANR7lWSVML0pHJbOn33G4KNbpt/YU3z0wZFmXeWZ Wt+JBXegCnRu8z0iLPAE5VkmYvyZ9z/Zv4KHmz19jadfoMsqGQG44iRBuQz+WASMnEeP 3NuAzb/LJKVHTsueIBALTMpfXYBqGafMKI2vqJPff5dNf2E9PNk4fgp8vIMVGL3K6ojy 7Y/0GWR1ETy5o33/x9FwqxFowDyeyhQetbvIlFGVHce3wcu+DH5Xny1uV5k5NGVw0u54 FTTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544352; x=1698149152; 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=6qenkA6xUaauonLvrFTXXD5sPq5v8M/Ht2ghe2Ntrw0=; b=WiawTtUxTVDEBUHGqmdeB3GNTgwgIKIR8xvOH9LnhYKnH+vNgR8RL+ktwzYs0/bm8u 5xc6DtbXx0R5/WfBNjb5r/N5fuXRhCnP1S2c06ELi2JFrwDBiWLBGrh5r3DTDOBO5WPL QZ3UeJg5rezXOiddA6c6pQcqsAoVOBtFz2ty+A2c4kXHj0imWLnAJONQLP6g5S5skXt5 4I3o/myMFjdsGia319yddCFUeyV/aZ+PID5oaY1O3ityaKPC2igttZg97MxcjTA+BQEi RPqEGw4mOxx7i6kW/rv5JO739UYaqC3jnAYQrRaBDwOlY3bEMjHjhDVvdFyHdtJnnf3O FFyw== X-Gm-Message-State: AOJu0YxxEmM4h5ogA+KPRj7L2HTTz1jrgnWhzQPeB83aoA5iklI2c18z nxb0gF97g2Q5Jbsfp7vD/Pv4tQ== X-Google-Smtp-Source: AGHT+IG006eiZyEKvcOuI2B3LRPUl2eJRkiEOnDMJ8eFEPmWL+95NbnHDFnkRuQ7844hEA8IaFsYmg== X-Received: by 2002:a05:600c:4fd3:b0:402:e68f:8a4f with SMTP id o19-20020a05600c4fd300b00402e68f8a4fmr1608219wmq.0.1697544352447; Tue, 17 Oct 2023 05:05:52 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:51 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 67/73] pinctrl: starfive: jh7100: drop wrappers around pinctrl_gpio_request/free() Date: Tue, 17 Oct 2023 14:04:25 +0200 Message-Id: <20231017120431.68847-68-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_*() helpers now have signatures corresponding with those of the GPIOLIB callbacks. We can drop the wrappers. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7100.c index 7beed57d665a..ea70b8c61679 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c @@ -916,16 +916,6 @@ static struct pinctrl_desc starfive_desc =3D { .custom_conf_items =3D starfive_pinconf_custom_conf_items, }; =20 -static int starfive_gpio_request(struct gpio_chip *gc, unsigned int gpio) -{ - return pinctrl_gpio_request(gc, gpio); -} - -static void starfive_gpio_free(struct gpio_chip *gc, unsigned int gpio) -{ - pinctrl_gpio_free(gc, gpio); -} - static int starfive_gpio_get_direction(struct gpio_chip *gc, unsigned int = gpio) { struct starfive_pinctrl *sfp =3D container_of(gc, struct starfive_pinctrl= , gc); @@ -1309,8 +1299,8 @@ static int starfive_probe(struct platform_device *pde= v) =20 sfp->gc.label =3D dev_name(dev); sfp->gc.owner =3D THIS_MODULE; - sfp->gc.request =3D starfive_gpio_request; - sfp->gc.free =3D starfive_gpio_free; + sfp->gc.request =3D pinctrl_gpio_request; + sfp->gc.free =3D pinctrl_gpio_free; sfp->gc.get_direction =3D starfive_gpio_get_direction; sfp->gc.direction_input =3D starfive_gpio_direction_input; sfp->gc.direction_output =3D starfive_gpio_direction_output; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AC105CDB483 for ; Tue, 17 Oct 2023 12:22:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235285AbjJQMWt (ORCPT ); Tue, 17 Oct 2023 08:22:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48572 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234514AbjJQMWa (ORCPT ); Tue, 17 Oct 2023 08:22:30 -0400 Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B4651273C for ; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) Received: by mail-wm1-x335.google.com with SMTP id 5b1f17b1804b1-405497850dbso54310505e9.0 for ; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544353; x=1698149153; darn=vger.kernel.org; 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=CHG7rxCq2i//+W4yV7nUKawChQHAlvElG2FQaJzxjCc=; b=2AVAlLyD9FUtIXez4bcoI60LAyIjPmwwmkRyufVmQ4GUX5Q56QcKWN06/sUQq6YBKA yaDzmZAs9r26yTMCJh27RVb0w941th+mCnYYdF+LFrbFxx5mzCyVx3M1BrUArs6ITAOW nngz6pXM680n5EMzj19bH0U1011JZF9tcIez/NpFny1hc6Rzgk5FxTzgPtUFW0HJaR1y MINfhKNpPvvtlIrZ4Opmc31dScPe5RqjWmYNgzZ6gOtK85XdQ8ZNSoYpUittgzQWtkCf HiqWjNog7yD4DMkGSGVgfm5iVZ4OPTd8vCcIyOZj+F5JRuZ1DiABDokf5aKe4up2KjaT 7iDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544353; x=1698149153; 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=CHG7rxCq2i//+W4yV7nUKawChQHAlvElG2FQaJzxjCc=; b=tW/IHUqcggGTE68Bvz3pQsfFbkBgDvTehBPv1diSBZiFOMQrsQgnZpqbE6xu2OI4Yb RSzSe4OPsFvqRTG+4IYJxO65/yxTrAySVHqrnrkwSoE4IdM6351EDoK8u9vd/pya6hzg QnUvti1t9mqzS9H3ocL/QJuRf9iwWvbXfvwHf4ucodIISVdEuk/1M6BtosvFrALtTbZ9 q3iT/q3REdlv/fcGPKvSrfuCP5yZqb57D+tfx5C+uW3qjXc/mGkPOgRtkqRkpDOcyCjg 5pvyxZd1ts1iKI7QrTs+szvPxpta4RKzXYI9hIvOxBQVoac7guvK1mYfjUUe9glCeB21 215w== X-Gm-Message-State: AOJu0YySv/evGbuVK8oRRAK6SYyD67VQIugHampIjIfXKg39a129oIZg 7A5mL6Q+KqKbkiaDfnNjkeFHOQ== X-Google-Smtp-Source: AGHT+IHWlh4sDTH1SG2bWxKx5NGny8dO2LAca7pX4mI/k9lxdTYSnlxOxcknmQlpQof7BRuNfggmEA== X-Received: by 2002:a05:600c:350f:b0:405:3dbb:ec5a with SMTP id h15-20020a05600c350f00b004053dbbec5amr1558009wmq.1.1697544353151; Tue, 17 Oct 2023 05:05:53 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:52 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 68/73] pinctrl: starfive: jh7110: drop wrappers around pinctrl_gpio_request/free() Date: Tue, 17 Oct 2023 14:04:26 +0200 Message-Id: <20231017120431.68847-69-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_*() helpers now have signatures corresponding with those of the GPIOLIB callbacks. We can drop the wrappers. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c b/drivers/p= inctrl/starfive/pinctrl-starfive-jh7110.c index 695c8c0a6e8b..9d71e8c13310 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c @@ -545,16 +545,6 @@ static const struct pinconf_ops jh7110_pinconf_ops =3D= { .is_generic =3D true, }; =20 -static int jh7110_gpio_request(struct gpio_chip *gc, unsigned int gpio) -{ - return pinctrl_gpio_request(gc, gpio); -} - -static void jh7110_gpio_free(struct gpio_chip *gc, unsigned int gpio) -{ - pinctrl_gpio_free(gc, gpio); -} - static int jh7110_gpio_get_direction(struct gpio_chip *gc, unsigned int gpio) { @@ -940,8 +930,8 @@ int jh7110_pinctrl_probe(struct platform_device *pdev) =20 sfp->gc.label =3D dev_name(dev); sfp->gc.owner =3D THIS_MODULE; - sfp->gc.request =3D jh7110_gpio_request; - sfp->gc.free =3D jh7110_gpio_free; + sfp->gc.request =3D pinctrl_gpio_request; + sfp->gc.free =3D pinctrl_gpio_free; sfp->gc.get_direction =3D jh7110_gpio_get_direction; sfp->gc.direction_input =3D jh7110_gpio_direction_input; sfp->gc.direction_output =3D jh7110_gpio_direction_output; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1482CCDB474 for ; Tue, 17 Oct 2023 12:20:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234975AbjJQMUG (ORCPT ); Tue, 17 Oct 2023 08:20:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48894 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343855AbjJQMTu (ORCPT ); Tue, 17 Oct 2023 08:19:50 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 05932273E for ; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-4065dea9a33so52642165e9.3 for ; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544354; x=1698149154; darn=vger.kernel.org; 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=nUbVE7EnprLRCHg/IupG2aGO0MyUMAidx/+KUyiUqH8=; b=xMHDUv+fjSV9unbVsPuGNBL2e45kTOBSZiuAjMqcrWJYowvnPGFlSg9jjnYKdd0/Gq hEoHm25h+IMnYyeVLTMY2VNGh5T5LHE6+gsSaxs+evFxDalnzNidLQ0dh51Wfrj7RXNa vga4dqFozH9kcl+tjLicTtwTdDIiNrEshslikUnT3LILLfxgqRdBVrvbW5FmSujQx2Op 3HjbiyhwnOfME1RqGbYIaeNa0jA3HOCxbXjb7vmOZItslVWkry48zeHDeymCBGdPhVeF a8OAszY6mxRrtMKLERK5rC+yffuzGbTIagvH5N4AxKo2zHnJqQtlZ1qev8IqSQy02KcH 840g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544354; x=1698149154; 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=nUbVE7EnprLRCHg/IupG2aGO0MyUMAidx/+KUyiUqH8=; b=lMk2TviH4uyjy0ZA7OdWAmVQoij3VTB1ksVGD54tCvb44iEDDiYkR/FewbZTiKFfz7 CH2BbfhhB+76Df3QIiTg+qaC3X18ry0Ny0p+38yGfc5E3ICOggEGQQcOjXJSkxkkAokA f2iNuXHIFfgEiWuwaTvH/e9trMUJgFdQcwopIoYLMFPYjovCwPEEu9Eomy46kCQoD6sc 0oZ1kapkScx5YewIt/jZRY4p3jnKCFuB8rrU9lAqM22sGD2QHcOyVtV7mFEC9UM5K48f 1ZDakIeoRupqGxQYNfqTGL12NkSburP9Kj5HF2nitUS3jO8ove1Lzhl9rzSoPc6xmhjW PCLg== X-Gm-Message-State: AOJu0YwH/MAR3IFqYbEPAHu+osAeNeLexEHayvHpyElEhuI2XEYNO+Jw 5hspnifSvVTv6xF0ze4j20K/sA== X-Google-Smtp-Source: AGHT+IEQJmajdRG259Azur9kK4aLJz58vsY+Ji8pyKRpIU01MvG8yUxaV5SJfIXAnU492LUJVpBCYQ== X-Received: by 2002:a05:600c:1550:b0:405:4f78:e128 with SMTP id f16-20020a05600c155000b004054f78e128mr1627510wmg.4.1697544353982; Tue, 17 Oct 2023 05:05:53 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:53 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 69/73] pinctrl: stm32: drop wrappers around pinctrl_gpio_free/input() Date: Tue, 17 Oct 2023 14:04:27 +0200 Message-Id: <20231017120431.68847-70-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_*() helpers now have signatures corresponding with those of the GPIOLIB callbacks. We can drop the wrappers. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/stm32/pinctrl-stm32.c | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/drivers/pinctrl/stm32/pinctrl-stm32.c b/drivers/pinctrl/stm32/= pinctrl-stm32.c index 917b87acbf0d..64e8201c7eac 100644 --- a/drivers/pinctrl/stm32/pinctrl-stm32.c +++ b/drivers/pinctrl/stm32/pinctrl-stm32.c @@ -220,11 +220,6 @@ static int stm32_gpio_request(struct gpio_chip *chip, = unsigned offset) return pinctrl_gpio_request(chip, offset); } =20 -static void stm32_gpio_free(struct gpio_chip *chip, unsigned offset) -{ - pinctrl_gpio_free(chip, offset); -} - static int stm32_gpio_get(struct gpio_chip *chip, unsigned offset) { struct stm32_gpio_bank *bank =3D gpiochip_get_data(chip); @@ -239,11 +234,6 @@ static void stm32_gpio_set(struct gpio_chip *chip, uns= igned offset, int value) __stm32_gpio_set(bank, offset, value); } =20 -static int stm32_gpio_direction_input(struct gpio_chip *chip, unsigned off= set) -{ - return pinctrl_gpio_direction_input(chip, offset); -} - static int stm32_gpio_direction_output(struct gpio_chip *chip, unsigned offset, int value) { @@ -316,10 +306,10 @@ static int stm32_gpio_init_valid_mask(struct gpio_chi= p *chip, =20 static const struct gpio_chip stm32_gpio_template =3D { .request =3D stm32_gpio_request, - .free =3D stm32_gpio_free, + .free =3D pinctrl_gpio_free, .get =3D stm32_gpio_get, .set =3D stm32_gpio_set, - .direction_input =3D stm32_gpio_direction_input, + .direction_input =3D pinctrl_gpio_direction_input, .direction_output =3D stm32_gpio_direction_output, .to_irq =3D stm32_gpio_to_irq, .get_direction =3D stm32_gpio_get_direction, @@ -381,7 +371,7 @@ static int stm32_gpio_irq_request_resources(struct irq_= data *irq_data) struct stm32_pinctrl *pctl =3D dev_get_drvdata(bank->gpio_chip.parent); int ret; =20 - ret =3D stm32_gpio_direction_input(&bank->gpio_chip, irq_data->hwirq); + ret =3D pinctrl_gpio_direction_input(&bank->gpio_chip, irq_data->hwirq); if (ret) return ret; =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 69C48CDB483 for ; Tue, 17 Oct 2023 12:09:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230331AbjJQMJc (ORCPT ); Tue, 17 Oct 2023 08:09:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59220 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343619AbjJQMIe (ORCPT ); Tue, 17 Oct 2023 08:08:34 -0400 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 209A72D46 for ; Tue, 17 Oct 2023 05:05:56 -0700 (PDT) Received: by mail-lf1-x132.google.com with SMTP id 2adb3069b0e04-507a936f4a9so3040560e87.1 for ; Tue, 17 Oct 2023 05:05:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544355; x=1698149155; darn=vger.kernel.org; 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=rvAiclzYBXz54ZfUbD1kCo7tfLM2DvIrls2CuKVDYu0=; b=aZW+JreSbECKa1vngWbyqDTBjSkP/CZwBV+K2ovxhC5UMZmQS/WAIWIe2dfhSOBKtj SPUhMJb8mSbCxk+vrAA5GE0rzAU1USSNeRr07tTXjAmDf+MeRZU2gLelFaOSsIU9o0KV VH6fziwYraWXfbgHKoSLoy+aznTIrLygoGd/XYscCnHCM8IT36S7AhWzqXPJZUZUYM7p 8Y7iH4326d6iyxLqGsvdmaRKLTZdfAom87HFBXYpAJVERQwBVd+lZ6vx8tGTYXkqcE3N YyR364bf6lfKlyHWuVz887vwDkyT3xXgE0NpIg/BZnYwebFlYcpaWs5KGOadzfFaqqgt Zreg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544355; x=1698149155; 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=rvAiclzYBXz54ZfUbD1kCo7tfLM2DvIrls2CuKVDYu0=; b=ZdXIx/cQ7mb58CQf5yxvSiN58RzCxOb4RlBS+02tkHVDJNjbUE25QpLbwig5/yTeCw dE0S//pYgkqu5KkVV8BCuTR27s9Y0NmZAz5kJBz0cNfNy0weeHj6L74GMsKiYJryCDRo vIDDab/lvNo15RoMpeqKqp1s+MrlxnLel8y51uG7b00/MNhiOdsGJD/40k0G6s8hUn4m HCKpNTaN6/MFmtoTmaYs7t4eOWrRf6tGvw8Hk8LTKlJS21mI+wSS2O/8UpskiBAhvK8p 6xL2+qSo+BYD+jpfKzI9uVATP1LDxQ60Kn3JwbHAAsGRpzmswU1oKp4gc6tvS1r7lw9I pd/w== X-Gm-Message-State: AOJu0YxenwaeCYPYwS0QrZqsKL0y8ZPqKK0Q+nhlTwMmpOig947DpVR0 aA2rSBI/jPTVzACljAe+Xfq3Mg== X-Google-Smtp-Source: AGHT+IFjObtVg9WwA/yvyP0k1hEElLXc08dQMyqWvtp8tfJXU+iEFMwb/KdsxYo7u8j+NqKwUkmOEQ== X-Received: by 2002:a05:651c:60a:b0:2c2:966f:8cc with SMTP id k10-20020a05651c060a00b002c2966f08ccmr1326065lje.0.1697544355167; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:54 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 70/73] pinctrl: nuvoton: npcm7xx: drop wrappers around pinctrl_gpio_request/free() Date: Tue, 17 Oct 2023 14:04:28 +0200 Message-Id: <20231017120431.68847-71-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_*() helpers now have signatures corresponding with those of the GPIOLIB callbacks. We can drop the wrappers. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm7xx.c index 51aeac7ecc79..1e658721aaba 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm7xx.c @@ -208,12 +208,6 @@ static int npcmgpio_gpio_request(struct gpio_chip *chi= p, unsigned int offset) return bank->request(chip, offset); } =20 -static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) -{ - dev_dbg(chip->parent, "gpio_free: offset%d\n", offset); - pinctrl_gpio_free(chip, offset); -} - static void npcmgpio_irq_handler(struct irq_desc *desc) { struct gpio_chip *gc; @@ -1916,7 +1910,7 @@ static int npcm7xx_gpio_of(struct npcm7xx_pinctrl *pc= trl) pctrl->gpio_bank[id].gc.direction_output =3D npcmgpio_direction_output; pctrl->gpio_bank[id].request =3D pctrl->gpio_bank[id].gc.request; pctrl->gpio_bank[id].gc.request =3D npcmgpio_gpio_request; - pctrl->gpio_bank[id].gc.free =3D npcmgpio_gpio_free; + pctrl->gpio_bank[id].gc.free =3D pinctrl_gpio_free; id++; } =20 --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 50754CDB474 for ; Tue, 17 Oct 2023 12:09:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343648AbjJQMJZ (ORCPT ); Tue, 17 Oct 2023 08:09:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59152 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343630AbjJQMI0 (ORCPT ); Tue, 17 Oct 2023 08:08:26 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 510142D50 for ; Tue, 17 Oct 2023 05:05:57 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-4065dea9a33so52642295e9.3 for ; Tue, 17 Oct 2023 05:05:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544356; x=1698149156; darn=vger.kernel.org; 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=jFr6QY4eYLHOc0l8IDUIWTqpQdT11W1FKFRdkIoRPQg=; b=ghgZqeTtDAKbSvx4tlkoqTWvfg8HtDmDOE7aIMpAFs/VqnbaIEWd+uTED8FKsJx4k7 7n7GTzedxzwz2UjuWDYUNbbXPZUuPDBV6jbHyjTwon0N13TdugHEujo6TMwaU7qRfzfO dIzMGxGGVIRE0lGaHvsTbnjvRgkeK1yoWlsHEw9Q/Waf/KntEfQ4tALF97xYyDUAeVqG YRp+VwMvmyZvlSVxVqgzKMjJQauY5Xvt0/yEGDlMgdZUz8gXpFBIwgyznPVnluZZYbbR oWSkYkpP37/IuGIFog1XK5JiyRfNKMaybLjeJMznwx7ihjleCXGJ1MhP3l3XwwSuIB4S jP9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544356; x=1698149156; 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=jFr6QY4eYLHOc0l8IDUIWTqpQdT11W1FKFRdkIoRPQg=; b=uO7aSVw/FjYqjvOq84NGe3LF+Z2gW2g/OUkklRvtTnx6uiTX+xbRPMwio7/7cW0WyW FOs03NdeokytDJZMXmVg8jEEgwMhnLguaX+mw2LGeUVBQUghWeyEIbHq+nDapYxAGdM6 348qgVfWpzNNhNQfTsTfLlAY2WR8ciBDmnOvnw0d7Qd2fNyrODHRarZ5kEm+PM3vmD7d FDCWlxsRMnjbevxdKPVVFCmjvQmamBHQNX3CpULoxgEo6OVWula+gUOcZ4sW5sTXUeRy dMAIerQjYVx+DfY4gPrpR0t+3s726zBNm9YX8S/d6zYlXRLD3Ia36PgrWsGl9NCKX0wb jKCg== X-Gm-Message-State: AOJu0YzD+OBgnWBQ2+3z5nP4vonomZ0fK2v+mgcGRLYtY5WWKZMkmA+a cKb1vnFN6L2lGsPx9sM4TVyDug== X-Google-Smtp-Source: AGHT+IGECM7QoHgQLkn+z0jqNBZrYL350nPR+9uCcxQUMyXZBzyjmzw27zG6PUgXLvkccP0VYZsurg== X-Received: by 2002:a05:600c:4f15:b0:401:bdd7:49ae with SMTP id l21-20020a05600c4f1500b00401bdd749aemr1687396wmq.18.1697544355901; Tue, 17 Oct 2023 05:05:55 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:55 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 71/73] pinctrl: nuvoton: npcm8xx: drop wrappers around pinctrl_gpio_request/free() Date: Tue, 17 Oct 2023 14:04:29 +0200 Message-Id: <20231017120431.68847-72-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_*() helpers now have signatures corresponding with those of the GPIOLIB callbacks. We can drop the wrappers. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c b/drivers/pinctrl/nu= voton/pinctrl-npcm8xx.c index 140fdbbe8458..a377d36b0eb0 100644 --- a/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c +++ b/drivers/pinctrl/nuvoton/pinctrl-npcm8xx.c @@ -205,11 +205,6 @@ static int npcmgpio_gpio_request(struct gpio_chip *chi= p, unsigned int offset) return bank->request(chip, offset); } =20 -static void npcmgpio_gpio_free(struct gpio_chip *chip, unsigned int offset) -{ - pinctrl_gpio_free(chip, offset); -} - static void npcmgpio_irq_handler(struct irq_desc *desc) { unsigned long sts, en, bit; @@ -2388,7 +2383,7 @@ static int npcm8xx_gpio_fw(struct npcm8xx_pinctrl *pc= trl) pctrl->gpio_bank[id].gc.direction_output =3D npcmgpio_direction_output; pctrl->gpio_bank[id].request =3D pctrl->gpio_bank[id].gc.request; pctrl->gpio_bank[id].gc.request =3D npcmgpio_gpio_request; - pctrl->gpio_bank[id].gc.free =3D npcmgpio_gpio_free; + pctrl->gpio_bank[id].gc.free =3D pinctrl_gpio_free; for (i =3D 0 ; i < NPCM8XX_DEBOUNCE_MAX ; i++) pctrl->gpio_bank[id].debounce.set_val[i] =3D false; pctrl->gpio_bank[id].gc.add_pin_ranges =3D npcmgpio_add_pin_ranges; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DA608CDB474 for ; Tue, 17 Oct 2023 12:09:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234938AbjJQMJj (ORCPT ); Tue, 17 Oct 2023 08:09:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343599AbjJQMIw (ORCPT ); Tue, 17 Oct 2023 08:08:52 -0400 Received: from mail-lf1-x133.google.com (mail-lf1-x133.google.com [IPv6:2a00:1450:4864:20::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 391A72D5D for ; Tue, 17 Oct 2023 05:05:59 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id 2adb3069b0e04-5079f9675c6so5150535e87.2 for ; Tue, 17 Oct 2023 05:05:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544357; x=1698149157; darn=vger.kernel.org; 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=4LZIUlewtVfNK9nVoiXqaExbYoS0xfZdDyCSvk2gByo=; b=jL07/cVxYCCC+CtplPPUszGZBGuwotsCU2JC63QagvjZj1sM/S0vpeVc1c1fHGO+1p X9NHIJcd5TjW4cQ7otTbk/ZYH263ZnunAjShlvYOUJht57WEGNYoif1BdQnUbYt3PZmd zQ/9rZTiNwCda9iKARCx69SNniPIlo9QgJGkyUVrSnLREpNYM9piAZN6HgWYt0uHGiBV kCuErqVW2T/UFbhpKW49X6eJ7yDXK4hdIYEnxDkLz+VnEUniK1eh2Q9yOiP8qZDFMcpC Asy0o7MaNm2SOm4ydAcmvWLMlhRMaCw+zGV9ou9QICxChJcKiZI+HaVSs7jJMrp7iW/o GQHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544357; x=1698149157; 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=4LZIUlewtVfNK9nVoiXqaExbYoS0xfZdDyCSvk2gByo=; b=fMkFYe3oBGXxMWaQNdetw2nIUbaN+hY+1BF3nOFb9HqcnX7w7AVPXnP8CfSNM+UvXS mnRKEVoyUUIkJmBKQD42VLcvfgN99CKBO8gA4j8UTdVHRkVcA13qdsEorXNzNF0Wgtbq 7YSBnIU12BWifDLxp+DMj5S8ZFe0QR2cr1kGJu0Wo1uBEE+YIwE6CyuQn7ug5L5GwYAX OuABEW1z4v77YtY1uBR4y5kZzg6m5vLvn87yxhKxUx6+g8wwZjbIlyrWxxfhTmx7Ymfm hOjxUZ69feZWTgf0PNZK8/44mbA39hiUQ1BrJmFRw5o8TypmsE+JNvxKFq5SyDWlMITm DsyQ== X-Gm-Message-State: AOJu0YytBFfy4qk197nLupSGNz2XqEGzQw1/fn8qaBt48zNo33uRWaVO Uy6Xmz3yWQ1OL4+R1F9si66fGOC1X3FEwPWgqik= X-Google-Smtp-Source: AGHT+IEsouD0yLpmwXgotL/syrsZOgAR3eI6h2ScNnUAVSqPFxbO998HY/2CIcq7NlzryOczWqHO9g== X-Received: by 2002:ac2:43ab:0:b0:504:33da:b659 with SMTP id t11-20020ac243ab000000b0050433dab659mr1620734lfl.57.1697544357085; Tue, 17 Oct 2023 05:05:57 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:56 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 72/73] pinctrl: em: drop the wrapper around pinctrl_gpio_request() Date: Tue, 17 Oct 2023 14:04:30 +0200 Message-Id: <20231017120431.68847-73-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_request() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-em.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/gpio/gpio-em.c b/drivers/gpio/gpio-em.c index aa31c189d0ef..6c862c572322 100644 --- a/drivers/gpio/gpio-em.c +++ b/drivers/gpio/gpio-em.c @@ -227,11 +227,6 @@ static int em_gio_to_irq(struct gpio_chip *chip, unsig= ned offset) return irq_create_mapping(gpio_to_priv(chip)->irq_domain, offset); } =20 -static int em_gio_request(struct gpio_chip *chip, unsigned offset) -{ - return pinctrl_gpio_request(chip, offset); -} - static void em_gio_free(struct gpio_chip *chip, unsigned offset) { pinctrl_gpio_free(chip, offset); @@ -311,7 +306,7 @@ static int em_gio_probe(struct platform_device *pdev) gpio_chip->direction_output =3D em_gio_direction_output; gpio_chip->set =3D em_gio_set; gpio_chip->to_irq =3D em_gio_to_irq; - gpio_chip->request =3D em_gio_request; + gpio_chip->request =3D pinctrl_gpio_request; gpio_chip->free =3D em_gio_free; gpio_chip->label =3D name; gpio_chip->parent =3D dev; --=20 2.39.2 From nobody Sat Feb 7 20:25:24 2026 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0F0FCCDB474 for ; Tue, 17 Oct 2023 12:21:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343556AbjJQMU7 (ORCPT ); Tue, 17 Oct 2023 08:20:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48822 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235197AbjJQMUk (ORCPT ); Tue, 17 Oct 2023 08:20:40 -0400 Received: from mail-lf1-x134.google.com (mail-lf1-x134.google.com [IPv6:2a00:1450:4864:20::134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3F3622D67 for ; Tue, 17 Oct 2023 05:05:59 -0700 (PDT) Received: by mail-lf1-x134.google.com with SMTP id 2adb3069b0e04-5041d6d8b10so7323364e87.2 for ; Tue, 17 Oct 2023 05:05:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697544358; x=1698149158; darn=vger.kernel.org; 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=EYaubAEjb8jIz/ZTOGnBQzJ0oe0Kyc/ixkibc3BZPzU=; b=TxCPmBsDFrIYBZbD1BD6MTPMmcvonyonBh7l+lkpxOGn71qvhw8lZPIqd2UAuohLQI JWu/9LZ7CBWRNAtZ2GD4Licp58/3ixH4tmm8+62c+5mWfU2O1DBuuzHaUSIlDlY5iD8v pr3tbqDxk/S/0lxPLv5J4WjoL4a4uGOmhvN8C+e94uMJ9BTZG0LRLCXDbsVZ1TtRXwof cHQs3mUuDf90758mI2eyYQXI2o6iaqQ60fSZ3rRA0dMczefrOF62H0WK4V/pLpMKD1e/ +AHCSTahL5lUZ9fsSH28HP6AjcVaFpnkaIUhBe6OQHx/ftvNGDKXhJ5wLNta7/aGTVc/ +M3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697544358; x=1698149158; 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=EYaubAEjb8jIz/ZTOGnBQzJ0oe0Kyc/ixkibc3BZPzU=; b=FM8UdIoQxQOG5IAbst5mytgRkOdNlpQVCgvNPBkSce80nyzxEYlPpbL2Fa3U3ZCNDu W2zA8r4eInzZPLcIfTrVY3EA49nScztrFX2Q3MiBk3Y4V5AyzmL6igCoYFzbISLe6zcx NGQWlgHP2c+zCE4YgWUEuFrNxQsz45P/09AEfVlpEF6z1K3C0diVSJJ+EEEDbLVgh6X5 Ru4SdMtvstsE0/pcxwfZs3ks9BTuBY62TQdk1aoupUi7Gn+Nt8IfM+R+BMVxH+1MT+9M Kx8a1bO584I/qqY9Yq5eVMxyQQm3HZ2jSsElQ/Mse6yHmuIVSR7jNKJSuo/oSSIlhNQL Eu2A== X-Gm-Message-State: AOJu0YxSIbb9Z9VIrSUhwQZavkAs8BNK24m0/rhNOGRzXCUqmuAP6uSs fDg0JpMKtQ9xTANoDG4i81LJ9g== X-Google-Smtp-Source: AGHT+IHFfggU/iVMT2uhVuiqDu89DYpCOVc9nnY6TSYTY6Q7+HEkOQ938g+e5PqbgFZsXfapdExNfQ== X-Received: by 2002:ac2:4304:0:b0:503:1c07:f7f9 with SMTP id l4-20020ac24304000000b005031c07f7f9mr1743793lfh.29.1697544357879; Tue, 17 Oct 2023 05:05:57 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:f1ee:b000:ce90:ed14]) by smtp.gmail.com with ESMTPSA id a2-20020a05600c224200b00405442edc69sm1353859wmm.14.2023.10.17.05.05.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:05:57 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Andy Shevchenko Cc: linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 73/73] pinctrl: tegra: drop the wrapper around pinctrl_gpio_request() Date: Tue, 17 Oct 2023 14:04:31 +0200 Message-Id: <20231017120431.68847-74-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231017120431.68847-1-brgl@bgdev.pl> References: <20231017120431.68847-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Bartosz Golaszewski pinctrl_gpio_request() now has the same signature as the wrapper around it so we can drop them. Signed-off-by: Bartosz Golaszewski Acked-by: Linus Walleij --- drivers/gpio/gpio-tegra.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index adfbed62eff1..ea5f9cc14bc4 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -137,11 +137,6 @@ static void tegra_gpio_disable(struct tegra_gpio_info = *tgi, unsigned int gpio) tegra_gpio_mask_write(tgi, GPIO_MSK_CNF(tgi, gpio), gpio, 0); } =20 -static int tegra_gpio_request(struct gpio_chip *chip, unsigned int offset) -{ - return pinctrl_gpio_request(chip, offset); -} - static void tegra_gpio_free(struct gpio_chip *chip, unsigned int offset) { struct tegra_gpio_info *tgi =3D gpiochip_get_data(chip); @@ -717,7 +712,7 @@ static int tegra_gpio_probe(struct platform_device *pde= v) } =20 tgi->gc.label =3D "tegra-gpio"; - tgi->gc.request =3D tegra_gpio_request; + tgi->gc.request =3D pinctrl_gpio_request; tgi->gc.free =3D tegra_gpio_free; tgi->gc.direction_input =3D tegra_gpio_direction_input; tgi->gc.get =3D tegra_gpio_get; --=20 2.39.2