From: sashiko-bot@kernel.org
To: "Yu-Chun Lin" <eleanor.lin@realtek.com>
Cc: conor+dt@kernel.org, linux-clk@vger.kernel.org,
devicetree@vger.kernel.org, robh@kernel.org
Subject: Re: [PATCH v15 09/11] clk: realtek: Add RTD1625-CRT clock controller driver
Date: Fri, 02 Oct 2026 09:14:43 +0000 [thread overview]
Message-ID: <20261002091443.E6DF91F000FF@smtp.kernel.org> (raw)
In-Reply-To: <20261002074331.3066919-10-eleanor.lin@realtek.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] clk: realtek: incorrect bitmask FREQ_MNO_MASK truncates O field for VODMA PLL
--
commit 0728493fca904449d29102f41b0c4a133dfc60a6
Author: Cheng-Yu Lee <cylee12@realtek.com>
clk: realtek: Add RTD1625-CRT clock controller driver
This commit introduces support for the Realtek RTD1625-CRT clock controller,
adding various clock sources, multiplexers, and gates. It also defines
frequency tables and masks for the PLLs used by the device.
> diff --git a/drivers/clk/realtek/clk-rtd1625-crt.c b/drivers/clk/realtek/clk-rtd1625-crt.c
> new file mode 100644
> index 0000000000000..b25717eb6301b
> --- /dev/null
> +++ b/drivers/clk/realtek/clk-rtd1625-crt.c
> @@ -0,0 +1,822 @@
[ ... ]
> +#define FREQ_NF_MASK 0x7ffff
> +#define FREQ_NF(_r, _nf) {.rate = _r, .val = (_nf),}
> +
> +/* PLL VODMA: M (11:4) / N (13:12) / O (19:17) */
> +#define FREQ_MNO_MASK 0x63ff0
[Severity: Medium]
Does this mask inadvertently exclude bit 19?
The comment documents the O field as covering bits 19:17, but the value
0x63ff0 (which covers bits 18:17, 13:12, and 11:4) leaves bit 19 unset.
If a bootloader configures the hardware with an O divider that requires
bit 19 to be set, would this cause the driver to incorrectly mask out that
bit, resulting in an incorrect frequency calculation during initialization?
It appears the mask should be 0xe3ff0 to fully cover the O field.
> +#define FREQ_MNO(_r, _m, _n, _o) { .rate = (_r), .val = ((_m) << 4) | \
> + ((_n) << 12) | ((_o) << 17), }
> +
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261002074331.3066919-1-eleanor.lin@realtek.com?part=9
next prev parent reply other threads:[~2026-10-02 9:14 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-02 7:43 [PATCH v15 00/11] clk / reset: realtek: Add RTD1625 clock and reset support Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 01/11] dt-bindings: clock: Add Realtek RTD1625 Clock & Reset Controller Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 02/11] reset: Add Realtek basic reset support Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 03/11] reset: realtek: Add RTD1625 reset controller driver Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 04/11] clk: realtek: Introduce common probe() Yu-Chun Lin
2026-10-02 9:14 ` sashiko-bot
2026-10-02 7:43 ` [PATCH v15 05/11] clk: realtek: Add support for phase locked loops (PLLs) Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 06/11] clk: realtek: Add support for gate clock Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 07/11] clk: realtek: Add support for mux clock Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 08/11] clk: realtek: Add support for MMC-tuned PLL clocks Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 09/11] clk: realtek: Add RTD1625-CRT clock controller driver Yu-Chun Lin
2026-10-02 9:14 ` sashiko-bot [this message]
2026-10-02 7:43 ` [PATCH v15 10/11] clk: realtek: Add RTD1625-ISO " Yu-Chun Lin
2026-10-02 7:43 ` [PATCH v15 11/11] arm64: dts: realtek: Add clock support for RTD1625 Yu-Chun Lin
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=20261002091443.E6DF91F000FF@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=eleanor.lin@realtek.com \
--cc=linux-clk@vger.kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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