Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp767595rdg; Wed, 11 Oct 2023 05:11:21 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFXGHEjbhkTP0ZpysTatDgDiHHveDODbeCFnJwy7vKWSzavCfJSu9ckJNhLGLyhWIHnMk0C X-Received: by 2002:a05:6e02:1a6f:b0:34f:bac9:f53d with SMTP id w15-20020a056e021a6f00b0034fbac9f53dmr26830049ilv.17.1697026281235; Wed, 11 Oct 2023 05:11:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697026281; cv=none; d=google.com; s=arc-20160816; b=w+fVo7O3NtAo4jdJR2C86S06CJovAEZsuYEqv1WuZmPeZr5I/QpNmXYU8KskvIRLch ZkpA9GLHcyp8Cgr9u8/0A2lVmfsoi+abwHhv7UOZ0honvF9RAseN2qu0mBWHx8ijEX+q dOgHH39gXdrbocNPREmmPb/male2Z3mN4R/B091XrLeG90ufnZaGTU7bp0FplVNXrgQm eFeZgBl6m+qkZg/0bK0W2aWoddqCm0ihX9c3WkKQAaHttwDhC4Q1ik55ZfGoDeXZ1S/p qTKB0xs+zEpRItXNW2P2pvDwpgi30XaH65QM49pJAkmXeLAuoyrzTfAHhQd1TgBKfEML 0j6A== 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=FGIsRy8XjuOZvKHt9t36YQP6zzvIBqko3/T4/ujae7w=; fh=kOxmq+prcfKKX/dgMaMxTb6TRjzyc//QKXZBiaS/a94=; b=i780C7mMhRQjjGOevYyZR0aQFbvI6waEU6IdLUDuO46ut7xwgwtta0fQHqUQUoUnYZ 7r53pBQlLJcOholNSfsgtGL8mtr28+GgywaQhWyxKCLys7WHJZy3T1vVe+zN0hoJfyue Tog27uAujwFewdBoH5F+8Lfm0mTowt5i3RYSLgzwsE5ZZjDFhbU6Xny4U4NiZq2j/iTl s9ITeb2b3OipryGaazHUuXfi5UZUyW29nmmQXhX2c0twhx6QiYBXPonvq/nToKHWwcMR PQm1aehSHMziqfj2t+p9bQWXrLZOoGvtoXQbdpuapyre3sxuI0J6wCXDpN5Kuxpe0GWy geuQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=ogF4wQxO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id l10-20020a63570a000000b00584a9290bd3si14197770pgb.522.2023.10.11.05.11.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Oct 2023 05:11:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=ogF4wQxO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 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 pete.vger.email (Postfix) with ESMTP id 6F33C811875B; Wed, 11 Oct 2023 05:11:06 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346883AbjJKMKV (ORCPT + 99 others); Wed, 11 Oct 2023 08:10:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53600 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346779AbjJKMJf (ORCPT ); Wed, 11 Oct 2023 08:09:35 -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 26F21111 for ; Wed, 11 Oct 2023 05:09:27 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-4064867903cso68964775e9.2 for ; Wed, 11 Oct 2023 05:09:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1697026163; x=1697630963; 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=FGIsRy8XjuOZvKHt9t36YQP6zzvIBqko3/T4/ujae7w=; b=ogF4wQxOzbxNLYMKl2QlYia8LNhS3PDHvYVQtIGsi9yAFbf2qr2O99dX4vnc2BckDv MdgFrSoQaKWNrAIrkk79Juj4sbh1FIkww0L11GST9dAplcr9PZgs/lGPpovK7dC4J1oN LVnEpEzKlJwpP9+iY9dgKo4Jqynsg8MFj+Rr5SltbRSl0Wo6Y4iopD80UIW2wj9Rn+Wv xZtW33yvIbhbAhxYXJKP7KJssSC3Ai3Wt37jdP5zBkXWaQZvHeXX8uEzI9IA9Ls+nY8P q8UpPlpL4S4uYleliQ1Otddj4KeSrakRgnz1t3o7ZmUWGC9WiBjVF6tqiBqG0MPEXO/T z8pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697026163; x=1697630963; 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=FGIsRy8XjuOZvKHt9t36YQP6zzvIBqko3/T4/ujae7w=; b=X/6iBxtEL1e8qxBpbephNjB0s0lFjObkIiSjFfEoFkqRgT1Yl2d0dmJoadA1A6oCF0 /+mx+vzP42GN4XyMfET3/675OzunWyt1hY2DqB8LodDB4YYce8/fsIwicK4XlPNhxuba gBPxxRq6gTTgG4+eNIdNobh/WX7Vh22yVN9DZ/k43JoThUOxAxEgCTT4FPGj/0Tko+Z+ uzCNCutKy5vsLVRgNY3858veFSxHqYtuBuaxHmBg0qvSBdaUmXMj/6AToqQ+NViS6rzt 7qFFbszVeWOdw326vEZZWJgSZ8aKlRWaNz1vflA2j1zn0HX8Su4chY1JzWPIBYeoAUoz Zn8w== X-Gm-Message-State: AOJu0Yxv8gv9tr1tzF7QW/jKc34TEZ0viqX1gl457bs5uKUs1sEJW6zr N+7n3ok1RTI8whMU06LYZ1PYVQ== X-Received: by 2002:a05:600c:294a:b0:3f5:fff8:d4f3 with SMTP id n10-20020a05600c294a00b003f5fff8d4f3mr18972034wmd.7.1697026163661; Wed, 11 Oct 2023 05:09:23 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:e551:3946:26fc:f94]) by smtp.gmail.com with ESMTPSA id w21-20020a05600c015500b0040652e8ca13sm19012253wmm.43.2023.10.11.05.09.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Oct 2023 05:09: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 v2 18/62] pinctrl: starfive: use new pinctrl GPIO helpers Date: Wed, 11 Oct 2023 14:07:46 +0200 Message-Id: <20231011120830.49324-19-brgl@bgdev.pl> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231011120830.49324-1-brgl@bgdev.pl> References: <20231011120830.49324-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=2.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_SBL_CSS, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.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 (pete.vger.email [0.0.0.0]); Wed, 11 Oct 2023 05:11:06 -0700 (PDT) X-Spam-Level: ** 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 --- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 4 ++-- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/pinctrl/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 = { 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); } static void starfive_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free(gc->base + gpio); + pinctrl_gpio_free_new(gc, gpio); } 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/pinctrl/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 = { 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); } static void jh7110_gpio_free(struct gpio_chip *gc, unsigned int gpio) { - pinctrl_gpio_free(gc->base + gpio); + pinctrl_gpio_free_new(gc, gpio); } static int jh7110_gpio_get_direction(struct gpio_chip *gc, -- 2.39.2