linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: "Heiko Stübner" <heiko@sntech.de>
To: Ulf Hansson <ulf.hansson@linaro.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Michael Turquette <mturquette@baylibre.com>,
	Stephen Boyd <sboyd@kernel.org>,
	Shresth Prasad <shresthprasad7@gmail.com>,
	Cristian Ciocaltea <cristian.ciocaltea@collabora.com>,
	Detlev Casanova <detlev.casanova@collabora.com>,
	Jonas Karlman <jonas@kwiboo.se>, Chukun Pan <amadeus@jmu.edu.cn>,
	Yao Zi <ziyao@disroot.org>
Cc: linux-mmc@vger.kernel.org, devicetree@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org,
	linux-clk@vger.kernel.org, Yao Zi <ziyao@disroot.org>,
	Nicolas Frattaroli <nicolas.frattaroli@collabora.com>
Subject: Re: [PATCH v4 2/5] clk: rockchip: Support MMC clocks in GRF region
Date: Mon, 05 May 2025 23:39:05 +0200	[thread overview]
Message-ID: <2737556.Isy0gbHreE@diego> (raw)
In-Reply-To: <20250417143647.43860-3-ziyao@disroot.org>

Hi,

Am Donnerstag, 17. April 2025, 16:36:44 Mitteleuropäische Sommerzeit schrieb Yao Zi:
> Registers of MMC drive/sample clocks in Rockchip RV1106 and RK3528
> locate in GRF regions. Adjust MMC clock code to support register
> operations through regmap. Also add a helper to ease registration of GRF
> clocks.
> 
> Signed-off-by: Yao Zi <ziyao@disroot.org>

> diff --git a/drivers/clk/rockchip/clk.c b/drivers/clk/rockchip/clk.c
> index cbf93ea119a9..ce2f3323d84e 100644
> --- a/drivers/clk/rockchip/clk.c
> +++ b/drivers/clk/rockchip/clk.c
> @@ -590,6 +590,7 @@ void rockchip_clk_register_branches(struct rockchip_clk_provider *ctx,
>  				list->name,
>  				list->parent_names, list->num_parents,
>  				ctx->reg_base + list->muxdiv_offset,
> +				NULL, 0,
>  				list->div_shift
>  			);
>  			break;
> @@ -619,6 +620,11 @@ void rockchip_clk_register_branches(struct rockchip_clk_provider *ctx,
>  			break;
>  		case branch_linked_gate:
>  			/* must be registered late, fall-through for error message */
> +		case branch_mmc_grf:
> +			/*
> +			 * must be registered through rockchip_clk_register_grf_branches,
> +			 * fall-through for error message
> +			 */
>  			break;

please don't create separate structures for specific clock-types.
Being able to "just define" clock branches is helpful and starting
to require separate blocks just causes issues down the road.

For handling multiple GRF sources, I just merged Nicolas' patches for
handling auxiliary GRFs [0] and GRF-gate clock type [1] .

So ideally, please base off from there.

Thanks a lot
Heiko


[0] https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/commit/?id=70a114daf2077472e58b3cac23ba8998e35352f4
[1] https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/commit/?id=e277168cabe9fd99e647f5dad0bc846d5d6b0093




  reply	other threads:[~2025-05-05 21:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-17 14:36 [PATCH v4 0/5] Support SD/SDIO controllers on RK3528 Yao Zi
2025-04-17 14:36 ` [PATCH v4 1/5] dt-bindings: clock: Add GRF clock definition for RK3528 Yao Zi
2025-04-17 14:36 ` [PATCH v4 2/5] clk: rockchip: Support MMC clocks in GRF region Yao Zi
2025-05-05 21:39   ` Heiko Stübner [this message]
2025-05-06  2:21     ` Yao Zi
2025-04-17 14:36 ` [PATCH v4 3/5] clk: rockchip: rk3528: Add SD/SDIO tuning " Yao Zi
2025-04-17 14:36 ` [PATCH v4 4/5] arm64: dts: rockchip: Add SDMMC/SDIO controllers for RK3528 Yao Zi
2025-05-05 20:55   ` Jonas Karlman
2025-04-17 14:40 ` [PATCH v4 5/5] arm64: dts: rockchip: Enable SD-card interface on Radxa E20C Yao Zi
2025-05-05 21:00   ` Jonas Karlman

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=2737556.Isy0gbHreE@diego \
    --to=heiko@sntech.de \
    --cc=amadeus@jmu.edu.cn \
    --cc=conor+dt@kernel.org \
    --cc=cristian.ciocaltea@collabora.com \
    --cc=detlev.casanova@collabora.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jonas@kwiboo.se \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=mturquette@baylibre.com \
    --cc=nicolas.frattaroli@collabora.com \
    --cc=robh@kernel.org \
    --cc=sboyd@kernel.org \
    --cc=shresthprasad7@gmail.com \
    --cc=ulf.hansson@linaro.org \
    --cc=ziyao@disroot.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 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).