summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/setup_64.c
diff options
context:
space:
mode:
authorDave Jones <davej@redhat.com>2008-05-22 18:57:25 -0400
committerH. Peter Anvin <hpa@zytor.com>2008-05-30 15:46:30 -0700
commit30a713180b3d08fdec5ca572e5a1cd35253c5d8e (patch)
tree4d286cbf8dbbaaca40241aa8dffe203cb2acd75d /arch/x86/kernel/setup_64.c
parent7e2191127eb414d7d5a11df6552ab6e3845d17a1 (diff)
x86: Move the 64-bit Centaur specific parts out of setup_64.c
Create a separate centaur_64.c file in the cpu/ dir for the useful parts to live in. Signed-off-by: Dave Jones <davej@redhat.com> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/kernel/setup_64.c')
-rw-r--r--arch/x86/kernel/setup_64.c28
1 files changed, 2 insertions, 26 deletions
diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
index c4e6a0b6c303..25afdd80a3cf 100644
--- a/arch/x86/kernel/setup_64.c
+++ b/arch/x86/kernel/setup_64.c
@@ -622,32 +622,6 @@ out:
#endif
}
-static void __cpuinit early_init_centaur(struct cpuinfo_x86 *c)
-{
- if (c->x86 == 0x6 && c->x86_model >= 0xf)
- set_cpu_cap(c, X86_FEATURE_CONSTANT_TSC);
-}
-
-static void __cpuinit init_centaur(struct cpuinfo_x86 *c)
-{
- /* Cache sizes */
- unsigned n;
-
- n = c->extended_cpuid_level;
- if (n >= 0x80000008) {
- unsigned eax = cpuid_eax(0x80000008);
- c->x86_virt_bits = (eax >> 8) & 0xff;
- c->x86_phys_bits = eax & 0xff;
- }
-
- if (c->x86 == 0x6 && c->x86_model >= 0xf) {
- c->x86_cache_alignment = c->x86_clflush_size * 2;
- set_cpu_cap(c, X86_FEATURE_CONSTANT_TSC);
- set_cpu_cap(c, X86_FEATURE_REP_GOOD);
- }
- set_cpu_cap(c, X86_FEATURE_LFENCE_RDTSC);
-}
-
static void __cpuinit get_cpu_vendor(struct cpuinfo_x86 *c)
{
char *v = c->x86_vendor_id;
@@ -667,6 +641,8 @@ extern void __cpuinit early_init_amd(struct cpuinfo_x86 *c);
extern void __cpuinit init_amd(struct cpuinfo_x86 *c);
extern void __cpuinit early_init_intel(struct cpuinfo_x86 *c);
extern void __cpuinit init_intel(struct cpuinfo_x86 *c);
+extern void __cpuinit early_init_centaur(struct cpuinfo_x86 *c);
+extern void __cpuinit init_centaur(struct cpuinfo_x86 *c);
/* Do some early cpuid on the boot CPU to get some parameter that are
needed before check_bugs. Everything advanced is in identify_cpu