From patchwork Thu Sep 26 10:06:54 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wolfram Sang X-Patchwork-Id: 13813143 X-Patchwork-Delegate: geert@linux-m68k.org Received: from mail.zeus03.de (zeus03.de [194.117.254.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 44C67224D6 for ; Thu, 26 Sep 2024 10:07:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=194.117.254.33 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1727345231; cv=none; b=Te3j4GjX1jHNceNPLbUTGZS8MyO1vL9/AtiJTa/ic2ug6BFkVwphqHK49aIpxCt4yokHi9OP/s6aXr2inSym5/cM3FYxXcuCXfK1Pt67a1gh9QC3wM4dd/QvdZbyWSqfb6ghW6/9J25msRIqcKo16XjoRVcF+jZXlLO+Awt1GMc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1727345231; c=relaxed/simple; bh=LoPQpTOriQJdSu4vmV3g09146e46VFNs93UkugRgVN8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=roci+cOjYbBoJcn5X8gXMzHn3U/S6vs6DLkI+q6Na+myeiHWScKYeOB8KjOD5ByOUYlFLchw9idKQi14he8UWzVXdlEtVXeUpXTqE0oCSIzA24LEJRBAtPRqD+LpZ+n/fJl0x6YSn0lDx5Na/1OtyJK1VLQuHgUCBVon3WwFUkE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=sang-engineering.com; spf=pass smtp.mailfrom=sang-engineering.com; dkim=pass (2048-bit key) header.d=sang-engineering.com header.i=@sang-engineering.com header.b=jRW0hwMU; arc=none smtp.client-ip=194.117.254.33 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=sang-engineering.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sang-engineering.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=sang-engineering.com header.i=@sang-engineering.com header.b="jRW0hwMU" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= sang-engineering.com; h=from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; s=k1; bh=I//2n5gzqshCD+ iGlaHBOXkSgVg15p4QKo+GuiHMZ+E=; b=jRW0hwMUYkoWLzgXClIXWfuzqAhVzy NzMZ1/0dGAbEYH9Mqm1glkoltQ1PsLuFR3zNGNezyoqW+Isi3sbqPiQdAorZKpZA O+oLVtdESIu2IjnGufyWYWNwhp0c6vY1uwaJcXH5Y71kddvzL2Tt//va5kqa7amm qqMjwerorr2ELZzKt5z9HYltOavM94HxlRcgvypF+gcuq7OAjxEyiHh4xvRYuBHf VjKL0cN1mkJHHvS3EuGt2F98faHJnRhnOmcp33DSJQY6w31edhyy1alSD5evpXof zjbLCwm6J8TZwAjkqGiSpilKb66rjMMBlt0hdnCncNV0l8iOv9ZLYOmQ== Received: (qmail 942439 invoked from network); 26 Sep 2024 12:07:05 +0200 Received: by mail.zeus03.de with ESMTPSA (TLS_AES_256_GCM_SHA384 encrypted, authenticated); 26 Sep 2024 12:07:05 +0200 X-UD-Smtp-Session: l3s3148p1@kf6I5gIjorggAwDPXzRXADDuo30Z+IZ9 From: Wolfram Sang To: linux-renesas-soc@vger.kernel.org Cc: Jacopo Mondi , Wolfram Sang , Geert Uytterhoeven , Linus Walleij , linux-gpio@vger.kernel.org Subject: [PATCH] pinctrl: renesas: rza1: mark GPIOs as used Date: Thu, 26 Sep 2024 12:06:54 +0200 Message-ID: <20240926100653.15015-2-wsa+renesas@sang-engineering.com> X-Mailer: git-send-email 2.45.2 Precedence: bulk X-Mailing-List: linux-renesas-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 GPIOs showed up as unclaimed, so they could be muxed to something else even though they were in use. Mark GPIOs as claimed to avoid that. Signed-off-by: Wolfram Sang --- drivers/pinctrl/renesas/pinctrl-rza1.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/pinctrl/renesas/pinctrl-rza1.c b/drivers/pinctrl/renesas/pinctrl-rza1.c index 6527872813dc..797367ce5641 100644 --- a/drivers/pinctrl/renesas/pinctrl-rza1.c +++ b/drivers/pinctrl/renesas/pinctrl-rza1.c @@ -19,6 +19,7 @@ #include #include #include +#include #include #include #include @@ -750,6 +751,11 @@ static int rza1_pin_mux_single(struct rza1_pinctrl *rza1_pctl, static int rza1_gpio_request(struct gpio_chip *chip, unsigned int gpio) { struct rza1_port *port = gpiochip_get_data(chip); + int ret; + + ret = pinctrl_gpio_request(chip, gpio); + if (ret) + return ret; rza1_pin_reset(port, gpio);