Re: [PATCH 3/3] scripts/gdb: Add $lx_clk_core_lookup function

2019-04-23 Thread Stephen Boyd
Quoting Leonard Crestez (2019-04-23 04:12:49) > On 4/22/2019 11:18 PM, Stephen Boyd wrote: > > Do you need to do the .string() for comparison? Or does it work just as > > well to compare a gdb.Value object to a python string? It would be nice > > if the gdb.Value object could figure out that

Re: [PATCH 3/3] scripts/gdb: Add $lx_clk_core_lookup function

2019-04-23 Thread Leonard Crestez
On 4/22/2019 11:18 PM, Stephen Boyd wrote: > Quoting Leonard Crestez (2019-04-22 01:26:57) >> diff --git a/scripts/gdb/linux/clk.py b/scripts/gdb/linux/clk.py >> +class LxClkCoreLookup(gdb.Function): >> +"""Find struct clk_core by name""" >> + >> +def __init__(self): >> +

[PATCH 3/3] scripts/gdb: Add $lx_clk_core_lookup function

2019-04-22 Thread Leonard Crestez
Finding an individual clk_core requires walking the tree which can be quite complicated so add a helper for easy access. (gdb) print *(struct clk_scu*)$lx_clk_core_lookup("uart0_clk")->hw Signed-off-by: Leonard Crestez --- scripts/gdb/linux/clk.py | 23 +++ 1 file changed,