Patchwork [2/2] m48t59-test: don't touch watchdog

login
register
mail settings
Submitter Gerd Hoffmann
Date Jan. 10, 2013, 2:49 p.m.
Message ID <1357829380-17599-3-git-send-email-kraxel@redhat.com>
Download mbox | patch
Permalink /patch/211089/
State New
Headers show

Comments

Gerd Hoffmann - Jan. 10, 2013, 2:49 p.m.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 tests/m48t59-test.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

Patch

diff --git a/tests/m48t59-test.c b/tests/m48t59-test.c
index 5179681..d79f554 100644
--- a/tests/m48t59-test.c
+++ b/tests/m48t59-test.c
@@ -233,6 +233,11 @@  static void fuzz_registers(void)
         reg = (uint8_t)g_test_rand_int_range(0, 16);
         val = (uint8_t)g_test_rand_int_range(0, 256);
 
+        if (reg == 7) {
+            /* watchdog setup register, may trigger system reset, skip */
+            continue;
+        }
+
         cmos_write(reg, val);
         cmos_read(reg);
     }