Page MenuHomeFreeBSD

linuxkpi: Add `seq_hex_dump()`
AbandonedPublic

Authored by dumbbell on Mar 15 2025, 11:19 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Aug 12, 1:06 PM
Unknown Object (File)
Mon, Aug 10, 4:56 PM
Unknown Object (File)
Mon, Aug 10, 10:19 AM
Unknown Object (File)
Mon, Aug 10, 9:24 AM
Unknown Object (File)
Thu, Aug 6, 12:17 PM
Unknown Object (File)
Sat, Jul 25, 2:43 PM
Unknown Object (File)
Fri, Jul 24, 8:50 PM
Unknown Object (File)
Jun 19 2026, 11:14 AM
Subscribers

Details

Reviewers
bz
Group Reviewers
linuxkpi
Summary

It is a copy of print_hex_dump() but uses a struct sbuf as the destination.

The amdgpu DRM driver started to use it in Linux 6.8.

This is part of the update of DRM drivers to Linux 6.8.

Sponsored by: The FreeBSD Foundation

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

Alternatively I quickly hacked this up -- I don't know which one would be preferable: https://reviews.freebsd.org/D49637

sys/compat/linuxkpi/common/src/linux_seq_file.c
317

For all of these printfs with prefix_str you need an extra %s and check (prefix_str != NULL) ? " " : "" to get the extra space after

320

I think the original implementation of print_hex_dump() got switched to #tx on purpose

bz requested changes to this revision.Apr 2 2025, 6:15 PM
This revision now requires changes to proceed.Apr 2 2025, 6:15 PM