Commit 4aef2132 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] AMD Elan is a different subarch

From: Adrian Bunk <bunk@fs.tum.de>

- AMD Elan is a different subarch, you can't configure a kernel that runs
  on both the AMD Elan and other i386 CPUs

- added optimizing CFLAGS for the AMD Elan
parent b26c400f
......@@ -43,6 +43,15 @@ config X86_PC
help
Choose this option if your computer is a standard PC or compatible.
config X86_ELAN
bool "AMD Elan"
help
Select this for an AMD Elan processor.
Do not use this option for K6/Athlon/Opteron processors!
If unsure, choose "PC-compatible" instead.
config X86_VOYAGER
bool "Voyager (NCR)"
help
......@@ -130,6 +139,8 @@ config ES7000_CLUSTERED_APIC
default y
depends on SMP && X86_ES7000 && MPENTIUMIII
if !X86_ELAN
choice
prompt "Processor family"
default M686
......@@ -318,6 +329,8 @@ config X86_GENERIC
when it has moderate overhead. This is intended for generic
distributions kernels.
endif
#
# Define implied options from the CPU selection here
#
......@@ -334,7 +347,7 @@ config X86_XADD
config X86_L1_CACHE_SHIFT
int
default "7" if MPENTIUM4 || X86_GENERIC
default "4" if MELAN || M486 || M386
default "4" if X86_ELAN || M486 || M386
default "5" if MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCRUSOE || MCYRIXIII || MK6 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2
default "6" if MK7 || MK8 || MPENTIUMM
......@@ -380,7 +393,7 @@ config X86_POPAD_OK
config X86_ALIGNMENT_16
bool
depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || M586MMX || M586TSC || M586 || M486 || MVIAC3_2
depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || X86_ELAN || MK6 || M586MMX || M586TSC || M586 || M486 || MVIAC3_2
default y
config X86_GOOD_APIC
......
......@@ -48,6 +48,9 @@ cflags-$(CONFIG_MWINCHIP3D) += $(call check_gcc,-march=winchip2,-march=i586)
cflags-$(CONFIG_MCYRIXIII) += $(call check_gcc,-march=c3,-march=i486) $(align)-functions=0 $(align)-jumps=0 $(align)-loops=0
cflags-$(CONFIG_MVIAC3_2) += $(call check_gcc,-march=c3-2,-march=i686)
# AMD Elan support
cflags-$(CONFIG_X86_ELAN) += -march=i486
CFLAGS += $(cflags-y)
# Default subarch .c files
......
......@@ -776,7 +776,7 @@ end_move_self: # now we are at the right place
# AMD Elan bug fix by Robert Schwebel.
#
#if defined(CONFIG_MELAN)
#if defined(CONFIG_X86_ELAN)
movb $0x02, %al # alternate A20 gate
outb %al, $0x92 # this works on SC410/SC520
a20_elan_wait:
......
......@@ -54,7 +54,7 @@ config X86_ACPI_CPUFREQ_PROC_INTF
config ELAN_CPUFREQ
tristate "AMD Elan"
depends on CPU_FREQ_TABLE && MELAN
depends on CPU_FREQ_TABLE && X86_ELAN
---help---
This adds the CPUFreq driver for AMD Elan SC400 and SC410
processors.
......
......@@ -12,7 +12,7 @@
#ifdef CONFIG_X86_PC9800
extern int CLOCK_TICK_RATE;
#else
#ifdef CONFIG_MELAN
#ifdef CONFIG_X86_ELAN
# define CLOCK_TICK_RATE 1189200 /* AMD Elan has different frequency! */
#else
# define CLOCK_TICK_RATE 1193182 /* Underlying HZ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment