From: Yao Zi <me@ziyao.cc>
To: Junhui Liu <junhui.liu@pigmoral.tech>,
Raymond Mao <raymond.mao@riscstar.com>,
u-boot@lists.u-boot-project.org
Cc: Lukasz Majewski <lukma@denx.de>, Tom Rini <trini@konsulko.com>,
Guodong Xu <guodong@riscstar.com>, Yixun Lan <dlan@kernel.org>,
Coverity Scan <scan-admin@coverity.com>, Yao Zi <me@ziyao.cc>
Subject: Re: [PATCH] clk: spacemit: Fix empty PLL rate table handling
Date: Sat, 1 Aug 2026 16:57:49 +0000 [thread overview]
Message-ID: <am4ljYUAf_Abbjj-@pie> (raw)
In-Reply-To: <20260801-k1-pll-fix-v1-1-5ad65231a361@pigmoral.tech>
On Sat, Aug 01, 2026 at 04:54:24PM +0800, Junhui Liu wrote:
> ccu_pll_lookup_best_rate() leaves best_entry uninitialized when the rate
> table is empty. Initialize it to NULL and have ccu_pll_set_rate() return
> -EINVAL when no matching entry is available.
Does a PLL with no rate entries make any sense? No operation in ccu_pll.c
seems valid with an empty rate table, not only ccu_pll_lookup_best_rate().
And all PLLs defined so far come with at least one entry in their tables.
> Fixes: 3aa2882a3e1a ("clk: spacemit: Add support for K1 SoC")
> Reported-by: Coverity Scan <scan-admin@coverity.com>
So this looks like a false positive.
> Signed-off-by: Junhui Liu <junhui.liu@pigmoral.tech>
Regards,
Yao Zi
prev parent reply other threads:[~2026-08-01 16:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-01 8:54 [PATCH] clk: spacemit: Fix empty PLL rate table handling Junhui Liu
2026-08-01 16:57 ` Yao Zi [this message]
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=am4ljYUAf_Abbjj-@pie \
--to=me@ziyao.cc \
--cc=dlan@kernel.org \
--cc=guodong@riscstar.com \
--cc=junhui.liu@pigmoral.tech \
--cc=lukma@denx.de \
--cc=raymond.mao@riscstar.com \
--cc=scan-admin@coverity.com \
--cc=trini@konsulko.com \
--cc=u-boot@lists.u-boot-project.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.