Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph...
[pandora-kernel.git] / arch / arm / mach-shmobile / include / mach / sdhi-sh7372.h
1 #ifndef SDHI_SH7372_H
2 #define SDHI_SH7372_H
3
4 #define SDGENCNTA       0xfe40009c
5
6 /* The countdown of SDGENCNTA is controlled by
7  * ZB3D2CLK which runs at 149.5MHz.
8  * That is 149.5ticks/us. Approximate this as 150ticks/us.
9  */
10 static void udelay(int us)
11 {
12         __raw_writel(us * 150, SDGENCNTA);
13         while(__raw_readl(SDGENCNTA)) ;
14 }
15
16 static void msleep(int ms)
17 {
18         udelay(ms * 1000);
19 }
20
21 #endif