From: "Heiko Stübner" <heiko@sntech.de>
To: Ye Zhang <ye.zhang@rock-chips.com>,
Linus Walleij <linus.walleij@linaro.org>,
Ye Zhang <ye.zhang@rock-chips.com>
Cc: Bartosz Golaszewski <brgl@bgdev.pl>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
linux-gpio@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org,
tao.huang@rock-chips.com
Subject: Re: [PATCH v2 6/8] dt-bindings: pinctrl: Add header for Rockchip RK3506 RMIO
Date: Tue, 09 Dec 2025 13:41:14 +0100 [thread overview]
Message-ID: <2681672.Lt9SDvczpP@diego> (raw)
In-Reply-To: <20251206050844.402958-7-ye.zhang@rock-chips.com>
Hi Ye Zhang,
Am Samstag, 6. Dezember 2025, 06:08:42 Mitteleuropäische Normalzeit schrieb Ye Zhang:
> Add header file with constants for RMIO pin and function IDs for the
> Rockchip RK3506 SoC.
>
> Signed-off-by: Ye Zhang <ye.zhang@rock-chips.com>
> ---
> .../pinctrl/rockchip,rk3506-rmio.h | 143 ++++++++++++++++++
> 1 file changed, 143 insertions(+)
> create mode 100644 include/dt-bindings/pinctrl/rockchip,rk3506-rmio.h
>
> diff --git a/include/dt-bindings/pinctrl/rockchip,rk3506-rmio.h b/include/dt-bindings/pinctrl/rockchip,rk3506-rmio.h
> new file mode 100644
> index 000000000000..5d39690a0b28
> --- /dev/null
> +++ b/include/dt-bindings/pinctrl/rockchip,rk3506-rmio.h
> @@ -0,0 +1,143 @@
> +/* SPDX-License-Identifier: (GPL-2.0 OR MIT) */
> +/*
> + * Copyright (c) 2025 Rockchip Electronics Co., Ltd.
> + */
> +
> +#ifndef __DT_BINDINGS_PINCTRL_ROCKCHIP_RK3506_RMIO_H
> +#define __DT_BINDINGS_PINCTRL_ROCKCHIP_RK3506_RMIO_H
> +
> +/* RMIO pins definetion */
> +#define RMIO_PIN0 0
> +#define RMIO_PIN1 1
> +#define RMIO_PIN2 2
> +#define RMIO_PIN3 3
> +#define RMIO_PIN4 4
[...]
> +#define RMIO_PIN29 29
> +#define RMIO_PIN30 30
> +#define RMIO_PIN31 31
additionally to Krzysztof's comments, please also don't introduce
unhelpful mappings. Having constants mapping pin31 to 31 is not
helpful at all, as there is no value added.
We'll already know that it's pin31 by reading the 31 when used.
In contrast, the constants below add a lot of value, because you can't
infer the that the function "14" means the CLK_32K function without
consulting the TRM, so _those_ are helpful.
> +/* RMIO function definetion */
typeo "definition"
> +#define RMIO_UART1_TX 1
> +#define RMIO_UART1_RX 2
> +#define RMIO_UART2_TX 3
> +#define RMIO_UART2_RX 4
> +#define RMIO_UART3_TX 5
Thanks a lot
Heiko
next prev parent reply other threads:[~2025-12-09 12:41 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-06 5:08 [PATCH v2 0/8] pinctrl: rockchip: Add RK3506 and RV1126B pinctrl and RMIO support Ye Zhang
2025-12-06 5:08 ` [PATCH v2 1/8] dt-bindings: pinctrl: Add rk3506 pinctrl support Ye Zhang
2025-12-08 6:26 ` Krzysztof Kozlowski
2025-12-09 12:35 ` Heiko Stübner
2025-12-06 5:08 ` [PATCH v2 2/8] pinctrl: rockchip: " Ye Zhang
2025-12-06 5:08 ` [PATCH v2 3/8] dt-bindings: pinctrl: Add rv1126b " Ye Zhang
2025-12-08 6:25 ` Krzysztof Kozlowski
2025-12-06 5:08 ` [PATCH v2 4/8] pinctrl: rockchip: " Ye Zhang
2025-12-06 5:08 ` [PATCH v2 5/8] gpio: rockchip: support new version GPIO Ye Zhang
2025-12-06 11:04 ` Bartosz Golaszewski
2025-12-06 5:08 ` [PATCH v2 6/8] dt-bindings: pinctrl: Add header for Rockchip RK3506 RMIO Ye Zhang
2025-12-08 6:27 ` Krzysztof Kozlowski
2025-12-09 12:41 ` Heiko Stübner [this message]
2025-12-06 5:08 ` [PATCH v2 7/8] dt-bindings: pinctrl: rockchip: Add RMIO controller binding Ye Zhang
2025-12-08 6:29 ` Krzysztof Kozlowski
[not found] ` <AGkAlwDSJz*Fj0POUP7xe4pV.3.1765201861250.Hmail.ye.zhang@rock-chips.com>
2025-12-09 6:04 ` Krzysztof Kozlowski
2025-12-06 5:08 ` [PATCH v2 8/8] pinctrl: rockchip: add rmio support Ye Zhang
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=2681672.Lt9SDvczpP@diego \
--to=heiko@sntech.de \
--cc=brgl@bgdev.pl \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=robh@kernel.org \
--cc=tao.huang@rock-chips.com \
--cc=ye.zhang@rock-chips.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).