PM / Sleep: Mark oops_id as suspend_volatile
authorDoug Anderson <dianders@chromium.org>
Thu, 8 Nov 2012 00:28:02 +0000 (16:28 -0800)
committerGerrit <chrome-bot@google.com>
Thu, 8 Nov 2012 16:27:56 +0000 (08:27 -0800)
Without this if we have a WARN_ON hit in suspend/resume code we'll
detect this as a CRC error.

BUG=chrome-os-partner:15655
TEST=Try to measure timings (which prints out a warning).
  echo Y > /sys/module/pm_check/parameters/pm_check_print_timings
  suspend_stress_test --noerrors_fatal --backup_rtc \
      --suspend_min 15 --suspend_max 15 -c1
Before this CL you'll see a CRC error:
  s3c_pm_check: Restore CRC error at 407bc000 (08e3f07b vs 08e3f079)
  bitfix_recover_chunk: Attempting recovery at 407bc000
  ...fixed 0x407bdeb0 from 0x76d4a47b to 0x76d4a479
After this CL there will be no CRC error.

Change-Id: I276bd69156bea6bd5b4c32274898e7c4ded03eb5
Signed-off-by: Doug Anderson <dianders@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/37591
Reviewed-by: Jon Kliegman <kliegs@chromium.org>
kernel/panic.c

index e8a99ab..be0b763 100644 (file)
@@ -23,6 +23,7 @@
 #include <linux/init.h>
 #include <linux/nmi.h>
 #include <linux/dmi.h>
+#include <linux/pm.h>
 
 #define PANIC_TIMER_STEP 100
 #define PANIC_BLINK_SPD 18
@@ -367,7 +368,7 @@ void oops_enter(void)
 /*
  * 64-bit random ID for oopses:
  */
-static u64 oops_id;
+static u64 __suspend_volatile_bss oops_id;
 
 static int init_oops_id(void)
 {