Re: [PATCH] clk: Add clk_min/max_rate entries in debugfs
From: Geert Uytterhoeven <geert@linux-m68k.org>
Date: 2019-06-27 15:34:26
Also in:
linux-clk
Hi Leonard, On Thu, Jun 27, 2019 at 5:22 PM Leonard Crestez [off-list ref] wrote:
Add two files to expose min/max clk rates as determined by clk_core_get_boundaries, taking all consumer requests into account. This information does not appear to be otherwise exposed to userspace. Signed-off-by: Leonard Crestez <redacted>
Thanks for your patch!
quoted hunk ↗ jump to hunk
--- a/drivers/clk/clk.c +++ b/drivers/clk/clk.c@@ -3031,10 +3031,34 @@ static int clk_duty_cycle_show(struct seq_file *s, void *data) return 0; } DEFINE_SHOW_ATTRIBUTE(clk_duty_cycle); +static int clk_min_rate_show(struct seq_file *s, void *data) +{ + struct clk_core *core = s->private; + unsigned long min_rate, max_rate; + + clk_core_get_boundaries(core, &min_rate, &max_rate);
Probably you should clk_prepare_lock() first?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel