From: Alexander Shiyan <eagle.alexander923@gmail.com>
To: barebox@lists.infradead.org
Cc: Alexander Shiyan <eagle.alexander923@gmail.com>
Subject: [PATCH 2/3] clk: rockchip: fix finding of maximum clock ID
Date: Wed, 9 Apr 2025 12:01:16 +0300 [thread overview]
Message-ID: <20250409090117.32359-2-eagle.alexander923@gmail.com> (raw)
In-Reply-To: <20250409090117.32359-1-eagle.alexander923@gmail.com>
If an ID of a branch's child is greater than current maximum, we should
set new maximum to the child's ID, instead of its parent's.
Signed-off-by: Alexander Shiyan <eagle.alexander923@gmail.com>
---
drivers/clk/rockchip/clk.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/clk/rockchip/clk.c b/drivers/clk/rockchip/clk.c
index d5ecf3fc13..a154495efd 100644
--- a/drivers/clk/rockchip/clk.c
+++ b/drivers/clk/rockchip/clk.c
@@ -393,7 +393,7 @@ unsigned long rockchip_clk_find_max_clk_id(struct rockchip_clk_branch *list,
if (list->id > max)
max = list->id;
if (list->child && list->child->id > max)
- max = list->id;
+ max = list->child->id;
}
return max;
--
2.39.1
next prev parent reply other threads:[~2025-04-09 9:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-09 9:01 [PATCH 1/3] clk: Update clk_fractional_divider driver Alexander Shiyan
2025-04-09 9:01 ` Alexander Shiyan [this message]
2025-04-09 9:01 ` [PATCH 3/3] ARM: rockchip: rk3568: Remove hardcoded clock initialization Alexander Shiyan
2025-04-10 7:21 ` [PATCH 1/3] clk: Update clk_fractional_divider driver Sascha Hauer
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=20250409090117.32359-2-eagle.alexander923@gmail.com \
--to=eagle.alexander923@gmail.com \
--cc=barebox@lists.infradead.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