aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/sh/Kconfig16
-rw-r--r--arch/sh/Makefile19
2 files changed, 21 insertions, 14 deletions
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
index b95dbb8db66..d62183f355a 100644
--- a/arch/sh/Kconfig
+++ b/arch/sh/Kconfig
@@ -294,12 +294,20 @@ config CF_BASE_ADDR
294 294
295menu "Processor features" 295menu "Processor features"
296 296
297config CPU_LITTLE_ENDIAN 297choice
298 bool "Little Endian" 298 prompt "Endianess selection"
299 default CPU_LITTLE_ENDIAN
299 help 300 help
300 Some SuperH machines can be configured for either little or big 301 Some SuperH machines can be configured for either little or big
301 endian byte order. These modes require different kernels. Say Y if 302 endian byte order. These modes require different kernels.
302 your machine is little endian, N if it's a big endian machine. 303
304config CPU_LITTLE_ENDIAN
305 bool "Little Endian"
306
307config CPU_BIG_ENDIAN
308 bool "Big Endian"
309
310endchoice
303 311
304config SH_FPU 312config SH_FPU
305 bool "FPU support" 313 bool "FPU support"
diff --git a/arch/sh/Makefile b/arch/sh/Makefile
index dc43984bd4b..6b3af5ce66a 100644
--- a/arch/sh/Makefile
+++ b/arch/sh/Makefile
@@ -13,10 +13,6 @@
13# for "archclean" and "archdep" for cleaning up and making dependencies for 13# for "archclean" and "archdep" for cleaning up and making dependencies for
14# this architecture 14# this architecture
15# 15#
16
17cflags-y := -mb
18cflags-$(CONFIG_CPU_LITTLE_ENDIAN) := -ml
19
20isa-y := any 16isa-y := any
21isa-$(CONFIG_SH_DSP) := sh 17isa-$(CONFIG_SH_DSP) := sh
22isa-$(CONFIG_CPU_SH2) := sh2 18isa-$(CONFIG_CPU_SH2) := sh2
@@ -38,13 +34,16 @@ isa-y := $(isa-y)-nofpu
38endif 34endif
39endif 35endif
40 36
41cflags-y += $(call as-option,-Wa$(comma)-isa=$(isa-y),) 37cflags-$(CONFIG_CPU_SH2) := -m2
42 38cflags-$(CONFIG_CPU_SH3) := -m3
43cflags-$(CONFIG_CPU_SH2) += -m2 39cflags-$(CONFIG_CPU_SH4) := -m4 \
44cflags-$(CONFIG_CPU_SH3) += -m3
45cflags-$(CONFIG_CPU_SH4) += -m4 \
46 $(call cc-option,-mno-implicit-fp,-m4-nofpu) 40 $(call cc-option,-mno-implicit-fp,-m4-nofpu)
47cflags-$(CONFIG_CPU_SH4A) += $(call cc-option,-m4a-nofpu,) 41cflags-$(CONFIG_CPU_SH4A) := -m4a $(call cc-option,-m4a-nofpu,)
42
43cflags-$(CONFIG_CPU_BIG_ENDIAN) += -mb
44cflags-$(CONFIG_CPU_LITTLE_ENDIAN) += -ml
45
46cflags-y += $(call as-option,-Wa$(comma)-isa=$(isa-y),)
48 47
49cflags-$(CONFIG_SH_DSP) += -Wa,-dsp 48cflags-$(CONFIG_SH_DSP) += -Wa,-dsp
50cflags-$(CONFIG_SH_KGDB) += -g 49cflags-$(CONFIG_SH_KGDB) += -g