blob: 907b134b785d630d34558cead194f509c8c65a17 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/*
* linux/arch/mips/philips/nino/power.c
*
* Copyright (C) 2000 Jim Pick <jim@jimpick.com>
* Copyright (C) 2001 Steven Hill (sjhill@realitydiluted.com)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* Routines for power management on the Nino.
*/
#include <asm/philips/pr31700.h>
void nino_wait(void)
{
/* We stop the CPU to conserve power */
PowerControl |= PWR_STOPCPU;
/*
* We wait until an interrupt happens...
*/
/* We resume here */
PowerControl &= ~PWR_STOPCPU;
/* Give ourselves a little delay */
__asm__ __volatile__(
"nop\n\t"
"nop\n\t"
"nop\n\t"
"nop\n\t"
"nop\n\t"
"nop\n\t"
"nop\n\t");
}
|