Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp4698872rdh; Wed, 29 Nov 2023 08:17:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IEGzvWMGNUTtY/bCytJSQMNVWTlSxOH5P54jlRktbujvQRjwtvLdQ+jOxU3pT8sPytZxRKa X-Received: by 2002:a17:903:234a:b0:1cf:e9b5:90ee with SMTP id c10-20020a170903234a00b001cfe9b590eemr11486375plh.24.1701274630878; Wed, 29 Nov 2023 08:17:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701274630; cv=none; d=google.com; s=arc-20160816; b=Af+/g1JVUNLUW7h581YuL0DWH2WlJwRH/FFrNNhnkcWY2Vd9H2z1ehdD/6OscIIfsm T+NwBAegXT+t606KF8EBZCzOiJbdLtqZj64S7M9beI8GcqDX56VDRienUlb7bjSquBtY 1YpBevV/l3M0yGdekAVFWjC3hM0XyUCC2R72HFcMXJbn54XEPFrsjvvXfh0tVtvhZBr+ XpaJUQROpQsxuBBfYUZ0+8amLyR2/9iozDHwexd7dkqBuSH+lKE0k9wCdIFTDCZRdMyu 2If3+SpOTVlWQPj0cdBpFdt5OBaIZxxANCY7udx3CJgz1lt1X99qVWIs4BIqce+GBMzX S2ow== 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=GowjPTZqE0Smv4YJ/cKzcAfCEv2JanCnDlRvdPyHm+A=; fh=Q1TGieY8NYQuaG8XdznxVIWY6Zzqtp1ugb4TRlCegEQ=; b=PWtl82f9O+I16kFlB8hAG5bS7xwao0VRacoJIYhXMwb7vQBUSHSjzcMl0qA4Dxnj3l 198uIRkphDE+h6fhdxqKNnbN7dmEInnGeeTZWKk1voRubJooKevP7RBuRTmNqls65Q57 lzs595uUIseiYzXLBB+ReWRy5KxCEetiHO7ZC376dDrdVk5qWJmcW6uCq+X+oyp9mW6E sL+tjasH9rG+8sDFWHFUhb5v0n5UHm5XCVHORz6/g4itJmdvKUVAh3JRMT9t+JVRx3B2 utjHWTj5MX3p7uaEu93x+Hf/ubGI2XV8HaZr7GoLQY4G14SZdQq0JeZsUDKBdq2CrVBL xBuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=lEkzgVIT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id jg17-20020a17090326d100b001cf68d3e90csi14346104plb.98.2023.11.29.08.16.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Nov 2023 08:17:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=lEkzgVIT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 21EFF803FC11; Wed, 29 Nov 2023 08:16:56 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234146AbjK2QQh (ORCPT + 99 others); Wed, 29 Nov 2023 11:16:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233878AbjK2QQB (ORCPT ); Wed, 29 Nov 2023 11:16:01 -0500 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2A9F81721; Wed, 29 Nov 2023 08:15:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1701274537; x=1732810537; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=zSzJJSBORuSF8Rt+BZ5mH8g+0I9DsPIRgct4EsYRglY=; b=lEkzgVIT2pSiNU0LqFo7Hmf/4E3uQAgfqQXKMNXUC5jhjx6xGAlrnUVf 8CNaTn8arULCh6QrB/bKXlyCStmf6cg7rcuLo7yrDpgIpKMKEqfME0B+5 mwTB6RZ7kH+zBcQevwMQxy5d4EO37SBqt1u51sUiLCYo8zGn9VSOnsvgO KMoJeYqiICdvjuHrnouiwrux+QKArmfAgBRIs5fdvO6Sz6uMn+FO5gTKg dqa3QZ00noQI231X1G4Yvh7JvBf208A3lEjArv0I3NSlqP3xQM2EW9HGd g/9iIe0/uOlhj8gTlhn/hoSZ9kk1H+aCpjDl3d8B1fwCfwf1KGY232AKJ w==; X-IronPort-AV: E=McAfee;i="6600,9927,10909"; a="373372905" X-IronPort-AV: E=Sophos;i="6.04,235,1695711600"; d="scan'208";a="373372905" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Nov 2023 08:15:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10909"; a="892498912" X-IronPort-AV: E=Sophos;i="6.04,235,1695711600"; d="scan'208";a="892498912" Received: from black.fi.intel.com ([10.237.72.28]) by orsmga004.jf.intel.com with ESMTP; 29 Nov 2023 08:15:21 -0800 Received: by black.fi.intel.com (Postfix, from userid 1003) id 717EBCA9; Wed, 29 Nov 2023 18:15:02 +0200 (EET) From: Andy Shevchenko To: Linus Walleij , Bartosz Golaszewski , Andy Shevchenko , Rasmus Villemoes , =?UTF-8?q?Jonathan=20Neusch=C3=A4fer?= , Krzysztof Kozlowski , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Geert Uytterhoeven , Biju Das , Claudiu Beznea , Jianlong Huang , linux-arm-kernel@lists.infradead.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, openbmc@lists.ozlabs.org, linux-mips@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-renesas-soc@vger.kernel.org Cc: Ray Jui , Scott Branden , Broadcom internal kernel review list , Dong Aisheng , Fabio Estevam , Shawn Guo , Jacky Bai , Pengutronix Kernel Team , Sascha Hauer , NXP Linux Team , Sean Wang , Paul Cercueil , Lakshmi Sowjanya D , Bjorn Andersson , Andy Gross , Konrad Dybcio , Emil Renner Berthing , Hal Feng , Emil Renner Berthing Subject: [PATCH v4 21/23] pinctrl: starfive: Convert to use grp member Date: Wed, 29 Nov 2023 18:06:44 +0200 Message-ID: <20231129161459.1002323-22-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.43.0.rc1.1.gbec44491f096 In-Reply-To: <20231129161459.1002323-1-andriy.shevchenko@linux.intel.com> References: <20231129161459.1002323-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.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 (agentk.vger.email [0.0.0.0]); Wed, 29 Nov 2023 08:16:56 -0800 (PST) Convert drivers to use grp member embedded in struct group_desc. Reviewed-by: Emil Renner Berthing Signed-off-by: Andy Shevchenko --- drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c | 8 ++++---- drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c index ea70b8c61679..21bfbbaede72 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7100.c @@ -654,7 +654,7 @@ static int starfive_set_mux(struct pinctrl_dev *pctldev, return -EINVAL; pinmux = group->data; - for (i = 0; i < group->num_pins; i++) { + for (i = 0; i < group->grp.npins; i++) { u32 v = pinmux[i]; unsigned int gpio = starfive_pinmux_to_gpio(v); u32 dout = starfive_pinmux_to_dout(v); @@ -797,7 +797,7 @@ static int starfive_pinconf_group_get(struct pinctrl_dev *pctldev, if (!group) return -EINVAL; - return starfive_pinconf_get(pctldev, group->pins[0], config); + return starfive_pinconf_get(pctldev, group->grp.pins[0], config); } static int starfive_pinconf_group_set(struct pinctrl_dev *pctldev, @@ -876,8 +876,8 @@ static int starfive_pinconf_group_set(struct pinctrl_dev *pctldev, } } - for (i = 0; i < group->num_pins; i++) - starfive_padctl_rmw(sfp, group->pins[i], mask, value); + for (i = 0; i < group->grp.npins; i++) + starfive_padctl_rmw(sfp, group->grp.pins[i], mask, value); return 0; } diff --git a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c index 9d71e8c13310..60160965cd29 100644 --- a/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c +++ b/drivers/pinctrl/starfive/pinctrl-starfive-jh7110.c @@ -307,7 +307,7 @@ static int jh7110_set_mux(struct pinctrl_dev *pctldev, return -EINVAL; pinmux = group->data; - for (i = 0; i < group->num_pins; i++) { + for (i = 0; i < group->grp.npins; i++) { u32 v = pinmux[i]; if (info->jh7110_set_one_pin_mux) @@ -437,7 +437,7 @@ static int jh7110_pinconf_group_get(struct pinctrl_dev *pctldev, if (!group) return -EINVAL; - return jh7110_pinconf_get(pctldev, group->pins[0], config); + return jh7110_pinconf_get(pctldev, group->grp.pins[0], config); } static int jh7110_pinconf_group_set(struct pinctrl_dev *pctldev, @@ -508,8 +508,8 @@ static int jh7110_pinconf_group_set(struct pinctrl_dev *pctldev, } } - for (i = 0; i < group->num_pins; i++) - jh7110_padcfg_rmw(sfp, group->pins[i], mask, value); + for (i = 0; i < group->grp.npins; i++) + jh7110_padcfg_rmw(sfp, group->grp.pins[i], mask, value); return 0; } -- 2.43.0.rc1.1.gbec44491f096