Skip to content

Add qdl-ramdump usage documentation and fix segment filter matching#202

Open
igoropaniuk wants to merge 3 commits intolinux-msm:masterfrom
igoropaniuk:refactor/ramdump_improvements
Open

Add qdl-ramdump usage documentation and fix segment filter matching#202
igoropaniuk wants to merge 3 commits intolinux-msm:masterfrom
igoropaniuk:refactor/ramdump_improvements

Conversation

@igoropaniuk
Copy link
Contributor

  • README: new "Collect crash dump" section documenting the 0x900e USB PID, how to trigger a kernel crash, qdl-ramdump invocation, and the segment filter syntax
  • qdl-ramdump: replace the single-line synopsis with a full per-option help text
  • sahara: fix segment filter silently skipping everything - bare names like OCIMEM never matched device-advertised filenames like OCIMEM.BIN because pattern_match() requires an exact match; the filter now also tests against the filename stem

@igoropaniuk
Copy link
Contributor Author

@lumag @andersson

README.md Outdated
echo c > /proc/sysrq-trigger
```

Use `qdl-ramdump` on the host to collect the dump:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see ff1a3bb ("ramdump: Make ramdump a qdl subcommand")

I'd prefer that we phase out qdl-ramdump.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed, thanks!

Let me know if you still wanna keep this commit qdl-ramdump: expand usage help to document all options or better to drop it.

@igoropaniuk igoropaniuk force-pushed the refactor/ramdump_improvements branch from 4aa72d5 to 22a7df2 Compare March 26, 2026 12:10
The device advertises segment filenames with extensions (e.g.
OCIMEM.BIN), but users naturally pass bare names like OCIMEM as filter
tokens. pattern_match() performs an exact match, so OCIMEM never
matched OCIMEM.BIN and all segments were skipped regardless of the
filter.

Match each token against both the full filename and the stem (the part
before the last dot) so that bare names, full names, and wildcard
patterns all work as expected. The stem buffer is zero-initialized and
stem[0] is used to determine whether a valid stem was extracted.

Signed-off-by: Igor Opaniuk <igor.opaniuk@oss.qualcomm.com>
The original help string was a single synopsis line with no explanation
of individual options, making it hard for new users to discover the
--output, --serial, and segment filter arguments without reading the
source code.

Signed-off-by: Igor Opaniuk <igor.opaniuk@oss.qualcomm.com>
The README had no mention of crash dump collection, leaving users
without guidance on which USB PID the device uses after a crash
(0x900e), how to trigger a kernel crash, or how to use the segment
filter.

Signed-off-by: Igor Opaniuk <igor.opaniuk@oss.qualcomm.com>
@igoropaniuk igoropaniuk force-pushed the refactor/ramdump_improvements branch from 22a7df2 to 0af8417 Compare March 26, 2026 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants