41 lines
1.3 KiB
Diff
41 lines
1.3 KiB
Diff
From 8a877e9146d24b21ded98fdc0cbbca9cced83e5d Mon Sep 17 00:00:00 2001
|
|
From: HATAYAMA Daisuke <d.hatayama@fujitsu.com>
|
|
Date: Fri, 25 Dec 2020 15:48:47 +0900
|
|
Subject: [PATCH 06/11] diskdump, zram: Notify necessity of loading zram module
|
|
|
|
By the previous commit, trying to read swapped-out-into-zram-disk
|
|
pages results in inaccessible memory error that is apparently
|
|
irrelevant to zram and users cannot find it necessary to load zram
|
|
module. Thus, let's add a warning message to indicate that as follows:
|
|
|
|
crash> rd -u 0x7f520626e000
|
|
WARNING: Some pages are swapped out to zram. Please run mod -s zram.
|
|
rd: invalid user virtual address: 7f520626e000 type: "64-bit UVADDR"
|
|
|
|
Signed-off-by: HATAYAMA Daisuke <d.hatayama@fujitsu.com>
|
|
---
|
|
diskdump.c | 6 +++++-
|
|
1 file changed, 5 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/diskdump.c b/diskdump.c
|
|
index 2b80e4a96ce4..30cb73fe2e19 100644
|
|
--- a/diskdump.c
|
|
+++ b/diskdump.c
|
|
@@ -2755,8 +2755,12 @@ try_zram_decompress(ulonglong pte_val, unsigned char *buf, ulong len, ulonglong
|
|
|
|
if (INVALID_MEMBER(zram_compressor)) {
|
|
zram_init();
|
|
- if (INVALID_MEMBER(zram_compressor))
|
|
+ if (INVALID_MEMBER(zram_compressor)) {
|
|
+ error(WARNING,
|
|
+ "Some pages are swapped out to zram. "
|
|
+ "Please run mod -s zram.\n");
|
|
return 0;
|
|
+ }
|
|
}
|
|
|
|
if (CRASHDEBUG(2))
|
|
--
|
|
2.29.2
|
|
|