aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/geode.h
diff options
context:
space:
mode:
authorAndres Salomon <dilinger@collabora.co.uk>2009-12-14 21:00:37 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-15 11:53:28 -0500
commit82dca611bb516ec5fb7d04077733d6a4b70f52d1 (patch)
tree67e085277bcc06e0aa7bf305e586ce856ef11078 /arch/x86/include/asm/geode.h
parent3c55494670745e523f69b56edb66ca0b50a470c2 (diff)
cs5535: add a generic MFGPT driver
This is based on the old code on arch/x86/kernel/mfgpt_32.c, except it's not x86 specific, it's modular, and it makes use of a PCI BAR rather than a random MSR. Currently module unloading is not supported; it's uncertain whether or not it can be made work with the hardware. [akpm@linux-foundation.org: add X86 dependency] Signed-off-by: Andres Salomon <dilinger@collabora.co.uk> Cc: Jordan Crouse <jordan@cosmicpenguin.net> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: john stultz <johnstul@us.ibm.com> Cc: Chris Ball <cjb@laptop.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/x86/include/asm/geode.h')
-rw-r--r--arch/x86/include/asm/geode.h40
1 files changed, 0 insertions, 40 deletions
diff --git a/arch/x86/include/asm/geode.h b/arch/x86/include/asm/geode.h
index 5716214d37d9..547e9642642a 100644
--- a/arch/x86/include/asm/geode.h
+++ b/arch/x86/include/asm/geode.h
@@ -47,16 +47,6 @@ extern int geode_get_dev_base(unsigned int dev);
47 47
48#define MSR_DIVIL_SOFT_RESET 0x51400017 48#define MSR_DIVIL_SOFT_RESET 0x51400017
49 49
50#define MSR_PIC_YSEL_LOW 0x51400020
51#define MSR_PIC_YSEL_HIGH 0x51400021
52#define MSR_PIC_ZSEL_LOW 0x51400022
53#define MSR_PIC_ZSEL_HIGH 0x51400023
54#define MSR_PIC_IRQM_LPC 0x51400025
55
56#define MSR_MFGPT_IRQ 0x51400028
57#define MSR_MFGPT_NR 0x51400029
58#define MSR_MFGPT_SETUP 0x5140002B
59
60#define MSR_LX_SPARE_MSR 0x80000011 /* DC-specific */ 50#define MSR_LX_SPARE_MSR 0x80000011 /* DC-specific */
61 51
62#define MSR_GX_GLD_MSR_CONFIG 0xC0002001 52#define MSR_GX_GLD_MSR_CONFIG 0xC0002001
@@ -169,36 +159,6 @@ static inline int geode_has_vsa2(void)
169} 159}
170#endif 160#endif
171 161
172/* MFGPTs */
173
174#define MFGPT_MAX_TIMERS 8
175#define MFGPT_TIMER_ANY (-1)
176
177#define MFGPT_DOMAIN_WORKING 1
178#define MFGPT_DOMAIN_STANDBY 2
179#define MFGPT_DOMAIN_ANY (MFGPT_DOMAIN_WORKING | MFGPT_DOMAIN_STANDBY)
180
181#define MFGPT_CMP1 0
182#define MFGPT_CMP2 1
183
184#define MFGPT_EVENT_IRQ 0
185#define MFGPT_EVENT_NMI 1
186#define MFGPT_EVENT_RESET 3
187
188#define MFGPT_REG_CMP1 0
189#define MFGPT_REG_CMP2 2
190#define MFGPT_REG_COUNTER 4
191#define MFGPT_REG_SETUP 6
192
193#define MFGPT_SETUP_CNTEN (1 << 15)
194#define MFGPT_SETUP_CMP2 (1 << 14)
195#define MFGPT_SETUP_CMP1 (1 << 13)
196#define MFGPT_SETUP_SETUP (1 << 12)
197#define MFGPT_SETUP_STOPEN (1 << 11)
198#define MFGPT_SETUP_EXTEN (1 << 10)
199#define MFGPT_SETUP_REVEN (1 << 5)
200#define MFGPT_SETUP_CLKSEL (1 << 4)
201
202static inline void geode_mfgpt_write(int timer, u16 reg, u16 value) 162static inline void geode_mfgpt_write(int timer, u16 reg, u16 value)
203{ 163{
204 u32 base = geode_get_dev_base(GEODE_DEV_MFGPT); 164 u32 base = geode_get_dev_base(GEODE_DEV_MFGPT);