[Crash-utility] [RFC 0/4] Add support to extract hardware device dumps from vmcore

Dave Anderson anderson at redhat.com
Fri Apr 12 19:09:09 UTC 2019


Hi Surenda,

Great -- I've been looking forward for this patch set to arrive.

A couple things...

First, I'm going to need two sample vmcores (one ELF, one compressed kdump)
along with the associated vmlinux.  You can contact me off-list with details
on how we can arrange a transfer.

Second, I do not want to add a new command.  I rarely do so -- in fact, 
the only times since the original crash utility was released was in 2012,
when the "ipcs" and "tree" commands were added in crash-6.0.7 and crash-6.0.8.
New functionality is typically added as an option to an existing command.
And in this case, the natural location to put it is in the existing "dev" 
command, and the devdump_extract() function can be moved into dev.c.
(FWIW, you can add your Chelsio copyright at the top of that file)

Third, there are some aesthetic changes that should be made in order
to have the display use a more traditional output format like those
used by other commands, e.g., with a single header with NAME, OFFSET and 
SIZE columns.

Other than that, this looks good on paper!

Thanks,
  Dave


----- Original Message -----
> When kernel panic happens and kdump crash kernel is loaded, device
> drivers enabled in the kdump crash kernel collect device specific
> snapshot of the hardware/firmware state of their underlying devices.
> These snapshots are exported as ELF notes with note type NT_VMCOREDD
> (i.e., 0x700) in vmcore [1].
> 
> This series of patches enhance crash utility to analyze and
> extract these hardware specific device dumps from vmcore using
> a new "devdump" command.
> 
> Patches 1 and 2 enhance help -D to parse NT_VMCOREDD ELF notes
> in ELF vmcore and KDUMP vmcore, respectively.
> 
> Patches 3 and 4 implement devdump command to analyze and extract
> hardware specific device dumps from ELF vmcore and KDUMP vmcore,
> respectively.
> 
> Suggestions and feedback will be much appreciated.
> 
> Thanks,
> Surendra
> 
> [1] https://lkml.org/lkml/2018/5/2/190
> 
> Surendra Mobiya (4):
>   parse NT_VMCOREDD ELF notes in ELF vmcore
>   parse NT_VMCOREDD ELF notes in KDUMP vmcore
>   add devdump command to extract NT_VMCOREDD from ELF vmcore
>   enhance devdump command to extract NT_VMCOREDD from KDUMP vmcore
> 
>  Makefile      |   4 +--
>  defs.h        |  16 +++++++++
>  devdump.c     | 114
>  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  diskdump.c    |  71 +++++++++++++++++++++++++++++++++++-
>  global_data.c |   1 +
>  help.c        |  23 ++++++++++++
>  memory.c      |   7 ++++
>  netdump.c     |  89 +++++++++++++++++++++++++++++++++++++++++++--
>  netdump.h     |   3 ++
>  vmcore.h      |  36 +++++++++++++++++++
>  10 files changed, 359 insertions(+), 5 deletions(-)
>  create mode 100644 devdump.c
>  create mode 100644 vmcore.h
> 
> --
> 1.8.3.1
> 
> 




More information about the Crash-utility mailing list