On Sat, 10 Jul 2021 at 03:07, Doug Anderson <diand...@chromium.org> wrote: > > Hi, > > On Fri, Jul 9, 2021 at 3:43 AM Sumit Garg <sumit.g...@linaro.org> wrote: > > > > Switch to use a linked list instead of dynamic array which makes > > allocation of kdb macro and traversing the kdb macro commands list > > simpler. > > > > Suggested-by: Daniel Thompson <daniel.thomp...@linaro.org> > > Signed-off-by: Sumit Garg <sumit.g...@linaro.org> > > --- > > kernel/debug/kdb/kdb_main.c | 107 +++++++++++++++++++----------------- > > 1 file changed, 58 insertions(+), 49 deletions(-) > > > > diff --git a/kernel/debug/kdb/kdb_main.c b/kernel/debug/kdb/kdb_main.c > > index 6d9ff4048e7d..371983c03223 100644 > > --- a/kernel/debug/kdb/kdb_main.c > > +++ b/kernel/debug/kdb/kdb_main.c > > @@ -654,13 +654,16 @@ static void kdb_cmderror(int diag) > > * zero for success, a kdb diagnostic if error > > */ > > struct kdb_macro_t { > > - int count; > > - bool usable; > > - kdbtab_t cmd; > > - char **command; > > + kdbtab_t cmd; /* Macro command */ > > + struct list_head statements; /* Associated statement list */ > > }; > > + > > +struct kdb_macro_statement_t { > > + char *statement; /* Statement name */ > > This is still not really the name. This is the actual statement, > right? Like it might contain "ftdump -1", right? It seems really weird > to call that the "name". You could drop the word "name", or change > this to "Statement text", or just totally drop the comment. >
Let me use "Statement text" instead. > Other than that this looks good to me. > > Reviewed-by: Douglas Anderson <diand...@chromium.org> Thanks, -Sumit _______________________________________________ Kgdb-bugreport mailing list Kgdb-bugreport@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kgdb-bugreport