----- Original Message ----- > Add a helper function, exist_regs_in_elf_notes(tc), which checks > whether or not register values for a given active task is available in > ELF notes. > > I intend to use the helper function in gcore extension module. vmcore > generated by diskdump has NT_PRSTATUS for a panic task only, and so > specifying get_regs_from_elf_notes() directly to non-panic active > tasks leads to a fatal action. So, it's necessary to check, in > advance, that an active task can get registers from ELF notes, but the > variable holding vmcore's data including ELF notes', nd, is defined as > a static global variable in netdump.c and thus the new helper function > needs to be introduced. Why not make the "nd" pointer available to extension modules? A get_kdump_vmcore_data() function already exists. If you create a new get_netdump_vmcore_data() function, it seems that most (if not all) of this netdump.c code that is *only* used by your extension module could be moved into your extension module source code, where it really belongs. The vmcore_data structure declaration could be moved into defs.h so that you would not have to #include netdump.h. BTW, you seemed to have sent a duplicate patch-set, i.e., 0001-Check-non-support-machine-check-first-01.patch and 0001-Check-non-support-machine-check-first.patch, etc. Dave > > The change includes: > > 1) Add and export exist_regs_in_elf_notes(), and > 2) Merge two kinds of fatal information printed in the case where no > corresponding register values exist in ELF notes. > > defs.h | 1 + > netdump.c | 174 > +++++++++++++++++++++++++++++-------------------------------- > 2 files changed, 83 insertions(+), 92 deletions(-) > > Signed-off-by: HATAYAMA Daisuke <d.hatayama@xxxxxxxxxxxxxx> > > > [Text > Documents:0004-Introduce-and-export-exist_regs_in_elf_notes.patch] > > > [Text > Documents:0003-Unify-error-check-conditions-and-information-printed.patch] > > > [Text > Documents:0002-Move-all-common-error-processings-in-get_arch_regs_f.patch] > > > [Text Documents:0001-Check-non-support-machine-check-first.patch] > > -- > Crash-utility mailing list > Crash-utility@xxxxxxxxxx > https://www.redhat.com/mailman/listinfo/crash-utility -- Crash-utility mailing list Crash-utility@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/crash-utility