diff options
| author | Tom Rini <[email protected]> | 2023-12-15 17:49:13 -0500 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2023-12-15 17:49:13 -0500 |
| commit | 8bb3cd7fe71ef242118a35e0ecac9b81337dfac9 (patch) | |
| tree | b6e90092a368113c6bfa06c953d3a8819b251f72 /cmd | |
| parent | 57e584d9418c9c6e98bfb13089a7d3fd7fd610aa (diff) | |
| parent | 652d8d4561a34fc71d9bcb6ad2b0035d2c4189c1 (diff) | |
Merge tag 'clk-2024.01-next' of https://source.denx.de/u-boot/custodians/u-boot-clk into next
clock patches for u-boot/next
The main thing in here is Igor's conversion of soc_clk_dump to a clk_ops
member. There's also a write-protect feature for nuvoton clocks.
Signed-off-by: Sean Anderson <[email protected]>
Diffstat (limited to 'cmd')
| -rw-r--r-- | cmd/clk.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/cmd/clk.c b/cmd/clk.c index c7c379d7a61..7bbcbfeda33 100644 --- a/cmd/clk.c +++ b/cmd/clk.c @@ -59,9 +59,10 @@ static void show_clks(struct udevice *dev, int depth, int last_flag) } } -int __weak soc_clk_dump(void) +static int soc_clk_dump(void) { struct udevice *dev; + const struct clk_ops *ops; printf(" Rate Usecnt Name\n"); printf("------------------------------------------\n"); @@ -69,10 +70,18 @@ int __weak soc_clk_dump(void) uclass_foreach_dev_probe(UCLASS_CLK, dev) show_clks(dev, -1, 0); + uclass_foreach_dev_probe(UCLASS_CLK, dev) { + ops = dev_get_driver_ops(dev); + if (ops && ops->dump) { + printf("\n%s %s:\n", dev->driver->name, dev->name); + ops->dump(dev); + } + } + return 0; } #else -int __weak soc_clk_dump(void) +static int soc_clk_dump(void) { puts("Not implemented\n"); return 1; |
