From: Wolfram Sang <wsa+renesas@sang-engineering.com>
To: Magnus Damm <damm@opensource.se>
Cc: linux-renesas-soc@vger.kernel.org, geert+renesas@glider.be,
linux-gpio@vger.kernel.org, linus.walleij@linaro.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] pinctrl: renesas: rza1: Check pin state before configuring
Date: Wed, 23 Jul 2025 09:02:00 +0200 [thread overview]
Message-ID: <aICI6M61N9_PH35L@ninjato> (raw)
In-Reply-To: <175233393885.19419.10468322450742766513.sendpatchset@Bjoern-Magnuss-MacBook-Pro.local>
[-- Attachment #1: Type: text/plain, Size: 1181 bytes --]
Hi Magnus,
On Sat, Jul 12, 2025 at 05:25:38PM +0200, Magnus Damm wrote:
> From: Magnus Damm <damm@opensource.se>
>
> Add code to the RZ/A1 pinctrl driver to check the state of the pin before
> writing any registers. As it is without this patch, resetting the pin state
> for every pin regardless of preious state might negatively be affecting
> certain shared pins like for instance address and data bus pins.
>
> Signed-off-by: Magnus Damm <damm@opensource.se>
> ---
>
> This makes the following patch work with Linux:
> [PATCH] Update r7s72100 Genmai DTS to include NOR Flash pinctrl
True that.
Tested-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
I can't say if it is feasible to have this code in the driver. I leave
this for Geert or the RZ team. But I can say it works with the above DTS
patch.
> +static int rza1_pin_mux_needs_update(struct rza1_pinctrl *rza1_pctl,
> + struct rza1_mux_conf *mux_conf)
Minor: I'd make this a bool, though...
> + if (!!(mux_flags & MUX_FLAGS_BIDIR) !=
> + !!rza1_get_bit(port, RZA1_PBDC_REG, pin))
> + return 1;
... and treturn true / false.
Happy hacking,
Wolfram
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2025-07-23 7:02 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-12 15:25 [PATCH] pinctrl: renesas: rza1: Check pin state before configuring Magnus Damm
2025-07-23 7:02 ` Wolfram Sang [this message]
2025-07-23 7:13 ` Wolfram Sang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aICI6M61N9_PH35L@ninjato \
--to=wsa+renesas@sang-engineering.com \
--cc=damm@opensource.se \
--cc=geert+renesas@glider.be \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.