diff options
| author | David Hildenbrand (Arm) <david@kernel.org> | 2026-07-09 10:13:34 +0530 |
|---|---|---|
| committer | Andrew Morton <akpm@linux-foundation.org> | 2026-08-24 18:42:49 -0700 |
| commit | 092836fedd82cdafc6e2085c4b7a7878bfa3ca1d (patch) | |
| tree | 0f1e1f0d4c3ad2b3ad99e19a223adbee5afa0e38 /include | |
| parent | 1eba458a54d073aa8bd62627ad0e9264ef0f51e3 (diff) | |
mm: standardize printing for pgtable entries
Bad page map reporting currently stores page table entry values in an
unsigned long long and prints them with fixed 64-bit-oriented format
strings. This is inconsistent across call sites and does not work well
for architectures where page table entry values are not naturally
represented as 64-bit values, such as 32-bit or 128-bit entries.
Introduce a common helper to convert raw page table entry values into a
fixed-width hexadecimal string based on the actual entry size. Use it for
bad page map reporting and for dumping the page table walk in
__print_bad_page_map_pgtable().
Pass page table entry values to the reporting path as raw bytes together
with their size, instead of forcing them through an unsigned long long.
It keeps the printed output consistent and avoids truncation or misleading
formatting for non-64-bit page table entries.
Link: https://lore.kernel.org/20260709044334.1741263-1-anshuman.khandual@arm.com
Signed-off-by: David Hildenbrand (Arm) <david@kernel.org>
Co-developed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Signed-off-by: Anshuman Khandual <anshuman.khandual@arm.com>
Cc: Andriy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: David Hildenbrand <david@kernel.org>
Cc: Hugh Dickins <hughd@google.com>
Cc: Matthew Wilcox (Oracle) <willy@infradead.org>
Cc: Ryan Roberts <ryan.roberts@arm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
