linux-mips
[Top] [All Lists]

[PATCH v2 5/6] Alchemy: DB1300 blink leds on timer tick

To: ralf@linux-mips.org, linux-mips@linux-mips.org
Subject: [PATCH v2 5/6] Alchemy: DB1300 blink leds on timer tick
From: Kevin Hickey <khickey@rmicorp.com>
Date: Fri, 20 Mar 2009 15:51:45 -0500
Cc: Kevin Hickey <khickey@rmicorp.com>
In-reply-to: <1237582306-10800-5-git-send-email-khickey@rmicorp.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <> <1237582306-10800-1-git-send-email-khickey@rmicorp.com> <1237582306-10800-2-git-send-email-khickey@rmicorp.com> <1237582306-10800-3-git-send-email-khickey@rmicorp.com> <1237582306-10800-4-git-send-email-khickey@rmicorp.com> <1237582306-10800-5-git-send-email-khickey@rmicorp.com>
Sender: linux-mips-bounce@linux-mips.org
Blinks the dots on the hex display on the DB1300 board every 1000 timer ticks.
This can help tell the difference between a soft and hard hung board.

Signed-off-by: Kevin Hickey <khickey@rmicorp.com>
---
 arch/mips/alchemy/common/time.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/arch/mips/alchemy/common/time.c b/arch/mips/alchemy/common/time.c
index f58d4ff..d2352c5 100644
--- a/arch/mips/alchemy/common/time.c
+++ b/arch/mips/alchemy/common/time.c
@@ -57,6 +57,8 @@ static struct clocksource au1x_counter1_clocksource = {
        .rating         = 100,
 };
 
+void (*board_timer_ticked)(void) = NULL;
+
 static int au1x_rtcmatch2_set_next_event(unsigned long delta,
                                         struct clock_event_device *cd)
 {
@@ -67,6 +69,9 @@ static int au1x_rtcmatch2_set_next_event(unsigned long delta,
        au_writel(delta, SYS_RTCMATCH2);
        au_sync();
 
+       if (board_timer_ticked)
+               board_timer_ticked();
+
        return 0;
 }
 
-- 
1.5.4.3


<Prev in Thread] Current Thread [Next in Thread>