Example #1
0
void
tb_timer_start (long period_tsc)
{
    if (period_tsc < 0)
        period_tsc = 0;

    bfin_write_WDOG_CNT (period_tsc / (tb_cclk / tb_sclk));
    bfin_write_WDOG_CTL (0x0004);
}
Example #2
0
void
tb_timer_stop ()
{
    bfin_write_WDOG_CTL (0x8AD6);
    bfin_write_WDOG_CTL (0x8AD6);
}
Example #3
0
static int bfin_wdt_stop(void)
{
	stampit();
	bfin_write_WDOG_CTL(WDEN_DISABLE);
	return 0;
}
Example #4
0
static int bfin_wdt_start(void)
{
	stampit();
	bfin_write_WDOG_CTL(WDEN_ENABLE | ICTL_RESET);
	return 0;
}
void hw_watchdog_init(void)
{
	bfin_write_WDOG_CNT(5 * get_sclk());	/* 5 second timeout */
	hw_watchdog_reset();
	bfin_write_WDOG_CTL(0x0);
}