示例#1
0
文件: setup.c 项目: anchowee/linino
void
bcm947xx_machine_restart(char *command)
{
	printk("Please stand by while rebooting the system...\n");

	/* Set the watchdog timer to reset immediately */
	__cli();
	sb_watchdog(sbh, 1);
	while (1);
}
示例#2
0
文件: setup.c 项目: anchowee/linino
void
bcm947xx_machine_halt(void)
{
	printk("System halted\n");

	/* Disable interrupts and watchdog and spin forever */
	__cli();
	sb_watchdog(sbh, 0);
	while (1);
}
示例#3
0
文件: time.c 项目: prime5711/blackbox
static irqreturn_t
bcm947xx_timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
{

	/* Generic MIPS timer code */
	timer_interrupt(irq, dev_id, regs);

	/* Set the watchdog timer to reset after the specified number of ms */
	if (watchdog > 0)
		sb_watchdog(sbh, WATCHDOG_CLOCK / 1000 * watchdog);

#ifdef	CONFIG_HWSIM
	(*((int *) 0xa0000f1c))++;
#else
	/* Blink one of the LEDs in the external UART */
	if (mcr && !(jiffies % (HZ / 2)))
		writeb(readb(mcr) ^ UART_MCR_OUT2, mcr);
#endif
	return IRQ_HANDLED;
}