ARM: 7409/1: Do not call flush_cache_user_range with mmap_sem held
[linux/fpc-iii.git] / arch / arm / mach-ks8695 / include / mach / system.h
blobfb1dda9be2d0a8c7fd6a032fb06417af1499455d
1 /*
2 * arch/arm/mach-s3c2410/include/mach/system.h
4 * Copyright (C) 2006 Simtec Electronics
5 * Ben Dooks <ben@simtec.co.uk>
7 * KS8695 - System function defines and includes
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
14 #ifndef __ASM_ARCH_SYSTEM_H
15 #define __ASM_ARCH_SYSTEM_H
17 #include <linux/io.h>
18 #include <mach/regs-timer.h>
20 static void arch_idle(void)
23 * This should do all the clock switching
24 * and wait for interrupt tricks,
26 cpu_do_idle();
30 static void arch_reset(char mode, const char *cmd)
32 unsigned int reg;
34 if (mode == 's')
35 cpu_reset(0);
37 /* disable timer0 */
38 reg = __raw_readl(KS8695_TMR_VA + KS8695_TMCON);
39 __raw_writel(reg & ~TMCON_T0EN, KS8695_TMR_VA + KS8695_TMCON);
41 /* enable watchdog mode */
42 __raw_writel((10 << 8) | T0TC_WATCHDOG, KS8695_TMR_VA + KS8695_T0TC);
44 /* re-enable timer0 */
45 __raw_writel(reg | TMCON_T0EN, KS8695_TMR_VA + KS8695_TMCON);
48 #endif