Skip to contentSkip to conversation

PM / hibernate: Verify the consistent of e820 memory map by md5 value

PATCH Prarit Bhargava 1 participant 1 message Aug 29, 2016

lore
Share & tools
lore
#0 lore raw

[My apologies for breaking threading. I'm not sub'd to LKML ...]

Review

Quoted 4 lines · Chen Yu
(quoted diff) +4 -0
+	if (memcmp(result, buf, MD5_DIGEST_SIZE)) {
+		pr_err("PM: e820 map conflict detected.\n");
+		panic("BIOS is playing funny tricks with us.\n");
+	}

This should have a better explanation. Perhaps

BUG("PM: BIOS e820 map conflicts with map from previous boot. S4/hibernate is
not supported on this platform. Please contact your hardware vendor.\n");

or

	pr_crit(FW_BUG "BIOS e820 map conflicts with map from previous boot.");
	BUG("PM: S4/hibernate is broken on this platform.  Please contact your hardware

vendor for support.\n");

is more appropriate rather than having them filing a kernel.org BZ or contacting an OS company with a bug that cannot be resolved in software. There are some other instances in the kernel where we've told them to do the same, and it is appropriate to do so here.

P.