xtensa: add support for the Xtensa architecture
authorChris Zankel <chris@zankel.net>
Thu, 15 Nov 2012 03:53:51 +0000 (03:53 +0000)
committerPeter Korsgaard <jacmet@sunsite.dk>
Thu, 15 Nov 2012 15:39:43 +0000 (16:39 +0100)
The Xtensa architecture had been removed because it required special
handling and depended on additional directories and files that became
obsolete over time. This change is more aligned to other architectures.

[Thomas: rebased on top of the "arch: improve definition of gcc mtune,
mcpu, etc." patch].

Signed-off-by: Chris Zankel <chris@zankel.net>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
arch/Config.in
arch/Config.in.xtensa [new file with mode: 0644]
linux/Config.in
package/ltrace/Config.in
toolchain/Config.in
toolchain/toolchain-buildroot/Config.in.2
toolchain/toolchain-common.in
toolchain/uClibc/Config.in
toolchain/uClibc/uclibc.mk

index b326cb5abf32811d8229a7e7f2e490ffdd37f5bb..472b10c7b2c18aa899679768bab51b96cef5ee01 100644 (file)
@@ -145,6 +145,13 @@ config BR2_x86_64
          architecture compatible microprocessor).
          http://en.wikipedia.org/wiki/X86_64
 
+config BR2_xtensa
+       bool "Xtensa"
+       help
+         Xtensa is a Tensilica processor IP architecture.
+         http://en.wikipedia.org/wiki/Xtensa
+         http://www.tensilica.com/
+
 endchoice
 
 # The following string values are defined by the individual
@@ -210,3 +217,7 @@ endif
 if BR2_i386 || BR2_x86_64
 source "arch/Config.in.x86"
 endif
+
+if BR2_xtensa
+source "arch/Config.in.xtensa"
+endif
diff --git a/arch/Config.in.xtensa b/arch/Config.in.xtensa
new file mode 100644 (file)
index 0000000..66749ee
--- /dev/null
@@ -0,0 +1,2 @@
+config BR2_ARCH
+       default "xtensa"        if BR2_xtensa
index 277ef0eb1daf194d7c1155733f17ac8155e27412..29a21109e9bcd3ce4fcf69df2183a73dc12c3fa3 100644 (file)
@@ -152,7 +152,8 @@ config BR2_LINUX_KERNEL_BZIMAGE
 
 config BR2_LINUX_KERNEL_ZIMAGE
        bool "zImage"
-       depends on BR2_arm || BR2_armeb || BR2_powerpc || BR2_sparc || BR2_sh || BR2_sh64
+       depends on BR2_arm || BR2_armeb || BR2_powerpc || BR2_sparc || \
+                  BR2_sh || BR2_sh64 || BR2_xtensa
 
 config BR2_LINUX_KERNEL_APPENDED_ZIMAGE
        bool "zImage with appended DT"
index a65ca481e77e3fc517b2d1470f28da18ea861d51..4cce76748cbcf69ebe2a805a42677fb0031dabc4 100644 (file)
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_LTRACE
        bool "ltrace"
        depends on !(BR2_avr32 || BR2_mips || BR2_mipsel || BR2_sh || BR2_sh64)
+       depends on !BR2_xtensa
        select BR2_PACKAGE_LIBELF
        help
          Debugging program which runs a specified command until it exits.
index 29ed2f035b830b22785b0d03122e18da7f60c5d6..7edf82b361856f727032c91c670d7d1bfe571112 100644 (file)
@@ -23,7 +23,7 @@ config BR2_TOOLCHAIN_EXTERNAL
 
 config BR2_TOOLCHAIN_CTNG
        bool "Crosstool-NG toolchain"
-       depends on !BR2_microblaze && !BR2_aarch64
+       depends on !BR2_microblaze && !BR2_aarch64 && !BR2_xtensa
        select BR2_TOOLCHAIN_HAS_SHADOW_PASSWORDS
        select BR2_TOOLCHAIN_HAS_THREADS_DEBUG_IF_NEEDED
        help
index 956ec2fe2dd26ea886200d028ac72b958ee22df3..d27c9f35f574e70a35b1f7a3b3568ffa5b886ab8 100644 (file)
@@ -68,7 +68,7 @@ config BR2_TOOLCHAIN_BUILDROOT_USE_SSP
 
 choice
        prompt "Thread library implementation"
-       default BR2_PTHREADS_NATIVE if (!BR2_UCLIBC_VERSION_0_9_31) && !BR2_ARM_OABI
+       default BR2_PTHREADS_NATIVE if (!BR2_UCLIBC_VERSION_0_9_31) && !BR2_ARM_OABI && !BR2_xtensa
        default BR2_PTHREADS_OLD
        help
          Use this option to select the thread library implementation
@@ -82,6 +82,7 @@ choice
 
        config BR2_PTHREADS
                bool "linuxthreads"
+               depends on !BR2_xtensa
                select BR2_TOOLCHAIN_HAS_THREADS
 
        config BR2_PTHREADS_OLD
@@ -94,6 +95,7 @@ choice
                depends on !BR2_UCLIBC_VERSION_0_9_31
                depends on !BR2_ARM_OABI
                depends on !BR2_x86_i386
+               depends on !BR2_xtensa
 endchoice
 
 source "toolchain/elf2flt/Config.in"
index 4c2a28bf8fb5c63576501ac89e56307db990f86f..9f11a3984ced7e98a6c899c6fab6e459af5ec545 100644 (file)
@@ -93,7 +93,7 @@ config BR2_NEEDS_GETTEXT_IF_LOCALE
        default y if (BR2_NEEDS_GETTEXT && BR2_ENABLE_LOCALE)
 
 config BR2_USE_MMU
-       bool "Enable MMU support" if BR2_arm || BR2_armeb || BR2_mips || BR2_mipsel || BR2_sh
+       bool "Enable MMU support" if BR2_arm || BR2_armeb || BR2_mips || BR2_mipsel || BR2_sh || BR2_xtensa
        default y if !BR2_bfin
        help
          If your target has a MMU, you should say Y here.  If you
index f46a415ac9c0c57244b2000e81c181d528c1a8d9..e47bc9bb09c72330346335c63f04d8cdf919f65d 100644 (file)
@@ -12,14 +12,15 @@ choice
 
        config BR2_UCLIBC_VERSION_0_9_31
                bool "uClibc 0.9.31.x"
+               depends on !BR2_xtensa
 
        config BR2_UCLIBC_VERSION_0_9_32
                bool "uClibc 0.9.32.x"
-               depends on !(BR2_avr32 || BR2_sh)
+               depends on !(BR2_avr32 || BR2_sh || BR2_xtensa)
 
        config BR2_UCLIBC_VERSION_0_9_33
                bool "uClibc 0.9.33.x"
-               depends on !BR2_avr32
+               depends on !(BR2_avr32 || BR2_xtensa)
 
        config BR2_UCLIBC_VERSION_SNAPSHOT
                bool "daily snapshot"
index 8cf59bce7124aca644a92c9d8e5bdd7054021c32..055267cbcb04b8bc1c3cb9d45a14b213f310da9d 100644 (file)
@@ -38,6 +38,7 @@ UCLIBC_TARGET_ARCH:=$(shell $(SHELL) -c "echo $(ARCH) | sed \
                -e 's/sh[234].*/sh/' \
                -e 's/mips.*/mips/' \
                -e 's/cris.*/cris/' \
+               -e 's/xtensa.*/xtensa/' \
 ")
 
 UCLIBC_TARGET_ENDIAN:=$(call qstrip,$(BR2_ENDIAN))