Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp3108530rdg; Tue, 17 Oct 2023 05:07:24 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEy6PFKEU+zO5SjWA4TkdB1zWhf3/LNWyNTTdsMg636R41l0StEsI4CRcNryWx/28SWm4ys X-Received: by 2002:a05:6359:5ea0:b0:166:d379:93c1 with SMTP id px32-20020a0563595ea000b00166d37993c1mr1921209rwb.20.1697544443777; Tue, 17 Oct 2023 05:07:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697544443; cv=none; d=google.com; s=arc-20160816; b=gC+twxRceNj0L/+jNxQ/setfdGWWWlPmjMN9PDzaw3geGk1Mb9tqS42SNkKNX22tt8 jla9jRUN/meZG938O9vUiPZGzab3q9cioxkDGiLqr0Xipk8YbgVsreGSWwC8OfxWB1+4 c3fS+m6/2PSa2321OXyNF+IAhFp7iNd707Fr0AbokZHHbS3FXSdKgu80DCr9YbAhbbD9 YzbiUuAHZuy/76SKfTTNevWSPkoqkYhwrrS1GRq49cB3BvEXaJIJX1P+v/iVhh+A+H9a CWnaLDRYbu2dWKtjgHNOG5rKfIqhWpmXV+RtpvnpOkWSOQm5zhY5ha4jAD/JcQTLoZR3 EhAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=B7mQAW/gcS7bWGdM82oN9G3UwAV92bdGrqJQuitFsrM=; fh=nVenUU/5j3rydL1Evt1qCDIQphGQoNODFIuKJsWU3VE=; b=gHiqq6hYkPbGkOrwsp67lJyobj/bVc2+m3i1zalQKyOvcoz8eClEu072xsoCGbaZk7 fafrb8ijzQCDC6aeQMIA7CRkMf65XkB1UUD0b05OXs6fcBmWplrllQZuop4dta7+XAft s6W0bZHRurYUd+LqSwTBZw/uqPVzHI1nhHudJgR7EAyjtgxx0dmzBGw522jsFJMfwUfX cIGIcTIYK353WlA1xttjm7HyT1hJYQTHGAYTD/n9r0e2IRXFrPNPyQloWz0Pt01sTm9K 5BDxr1EBuXDOv/hLjzyvnGHwpAh+nLNiXJuqKH9qRjoysh308AumiMpzOlZPg7arYx+e 7ETw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=lr7mzP4M; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id h11-20020a65480b000000b00563d791d978si1540762pgs.750.2023.10.17.05.07.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Oct 2023 05:07:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=lr7mzP4M; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 2A4A5801DE41; Tue, 17 Oct 2023 05:07:00 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234909AbjJQMGq (ORCPT + 99 others); Tue, 17 Oct 2023 08:06:46 -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-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: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Tue, 17 Oct 2023 05:07:00 -0700 (PDT) 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 --- 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/cirrus/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, unsigned int offset, int va 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); } 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); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } static int cs42l43_gpio_add_pin_ranges(struct gpio_chip *chip) diff --git a/drivers/pinctrl/cirrus/pinctrl-lochnagar.c b/drivers/pinctrl/cirrus/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_chip *chip, { lochnagar_gpio_set(chip, offset, value); - return pinctrl_gpio_direction_output(chip->base + offset); + return pinctrl_gpio_direction_output_new(chip, offset); } static int lochnagar_fill_func_groups(struct lochnagar_pin_priv *priv) -- 2.39.2