Module Name:    src
Committed By:   jakllsch
Date:           Sun Jul 22 16:59:10 UTC 2012

Modified Files:
        src/sys/arch/arm/marvell: mvsoctmr.c

Log Message:
The maximum watchdog period is dependant on mvTclk; calculate at runtime.
This gets the maximum period up to 25 seconds at 166⅔MHz mvTclk.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/marvell/mvsoctmr.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/arm/marvell/mvsoctmr.c
diff -u src/sys/arch/arm/marvell/mvsoctmr.c:1.6 src/sys/arch/arm/marvell/mvsoctmr.c:1.7
--- src/sys/arch/arm/marvell/mvsoctmr.c:1.6	Sun Jul 22 16:54:35 2012
+++ src/sys/arch/arm/marvell/mvsoctmr.c	Sun Jul 22 16:59:10 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: mvsoctmr.c,v 1.6 2012/07/22 16:54:35 jakllsch Exp $	*/
+/*	$NetBSD: mvsoctmr.c,v 1.7 2012/07/22 16:59:10 jakllsch Exp $	*/
 /*
  * Copyright (c) 2007, 2008 KIYOHARA Takashi
  * All rights reserved.
@@ -25,7 +25,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mvsoctmr.c,v 1.6 2012/07/22 16:54:35 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mvsoctmr.c,v 1.7 2012/07/22 16:59:10 jakllsch Exp $");
 
 #include "opt_ddb.h"
 
@@ -86,7 +86,7 @@ static int mvsoctmr_wdog_setmode(struct 
 static void mvsoctmr_wdog_ddb_trap(int);
 #endif
 
-#define MVSOC_WDOG_MAX_PERIOD	21
+#define MVSOC_WDOG_MAX_PERIOD	(0xffffffff / mvTclk)
 
 static struct mvsoctmr_softc *mvsoctmr_sc;
 static struct timecounter mvsoctmr_timecounter = {

Reply via email to