]> git.sur5r.net Git - u-boot/commitdiff
MIPS: kconfig: add options for endianess select
authorDaniel Schwierzeck <daniel.schwierzeck@gmail.com>
Sun, 26 Oct 2014 13:14:07 +0000 (14:14 +0100)
committerDaniel Schwierzeck <daniel.schwierzeck@gmail.com>
Sat, 1 Nov 2014 17:17:22 +0000 (18:17 +0100)
Add new Kconfig option to let the user select the targets
endianess. Each target have to select SUPPORTS_BIG_ENDIAN
and/or SUPPORTS_LITTLE_ENDIAN to indicate which endianess
is supported.

Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
26 files changed:
arch/mips/Kconfig
configs/dbau1000_defconfig
configs/dbau1100_defconfig
configs/dbau1500_defconfig
configs/dbau1550_defconfig
configs/dbau1550_el_defconfig
configs/malta_defconfig
configs/maltael_defconfig
configs/pb1000_defconfig
configs/qemu_mips64_defconfig
configs/qemu_mips64el_defconfig
configs/qemu_mips_defconfig
configs/qemu_mipsel_defconfig
configs/vct_platinum_defconfig
configs/vct_platinum_onenand_defconfig
configs/vct_platinum_onenand_small_defconfig
configs/vct_platinum_small_defconfig
configs/vct_platinumavc_defconfig
configs/vct_platinumavc_onenand_defconfig
configs/vct_platinumavc_onenand_small_defconfig
configs/vct_platinumavc_small_defconfig
configs/vct_premium_defconfig
configs/vct_premium_onenand_defconfig
configs/vct_premium_onenand_small_defconfig
configs/vct_premium_small_defconfig
include/configs/pb1x00.h

index 9b72bab56b64884543e1527a2186b388f7d460ca..f2e6a453fc37ee7ff3108437635433a5eabcc490 100644 (file)
@@ -12,21 +12,31 @@ choice
 
 config TARGET_QEMU_MIPS
        bool "Support qemu-mips"
+       select SUPPORTS_BIG_ENDIAN
+       select SUPPORTS_LITTLE_ENDIAN
 
 config TARGET_MALTA
        bool "Support malta"
+       select SUPPORTS_BIG_ENDIAN
+       select SUPPORTS_LITTLE_ENDIAN
 
 config TARGET_VCT
        bool "Support vct"
+       select SUPPORTS_BIG_ENDIAN
 
 config TARGET_DBAU1X00
        bool "Support dbau1x00"
+       select SUPPORTS_BIG_ENDIAN
+       select SUPPORTS_LITTLE_ENDIAN
 
 config TARGET_PB1X00
        bool "Support pb1x00"
+       select SUPPORTS_LITTLE_ENDIAN
 
 config TARGET_QEMU_MIPS64
        bool "Support qemu-mips64"
+       select SUPPORTS_BIG_ENDIAN
+       select SUPPORTS_LITTLE_ENDIAN
 
 endchoice
 
@@ -36,4 +46,32 @@ source "board/micronas/vct/Kconfig"
 source "board/pb1x00/Kconfig"
 source "board/qemu-mips/Kconfig"
 
+if MIPS
+
+choice
+       prompt "Endianness selection"
+       help
+         Some MIPS boards can be configured for either little or big endian
+         byte order. These modes require different U-Boot images. In general there
+         is one preferred byteorder for a particular system but some systems are
+         just as commonly used in the one or the other endianness.
+
+config SYS_BIG_ENDIAN
+       bool "Big endian"
+       depends on SUPPORTS_BIG_ENDIAN
+
+config SYS_LITTLE_ENDIAN
+       bool "Little endian"
+       depends on SUPPORTS_LITTLE_ENDIAN
+
+endchoice
+
+config SUPPORTS_BIG_ENDIAN
+       bool
+
+config SUPPORTS_LITTLE_ENDIAN
+       bool
+
+endif
+
 endmenu
index 7c95629cfb4f2c8b5dd4fde1bff9c877fe1b2d83..aa4d338d435f99acb91468e6c493154d17715be2 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="DBAU1000"
 CONFIG_MIPS=y
 CONFIG_TARGET_DBAU1X00=y
+CONFIG_SYS_BIG_ENDIAN=y
index 506f5da8cac13d97c4b05e3ffb8fad399c459d1f..db6f98ea0046e8e7bea036ea0f21f2dce6d405d0 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="DBAU1100"
 CONFIG_MIPS=y
 CONFIG_TARGET_DBAU1X00=y
+CONFIG_SYS_BIG_ENDIAN=y
index 5a02a78610ed0e2947c3deed0202127c9236d2f6..d2fbff9b38c35a3bb3436fa26a5da8388c2fa894 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="DBAU1500"
 CONFIG_MIPS=y
 CONFIG_TARGET_DBAU1X00=y
+CONFIG_SYS_BIG_ENDIAN=y
index 90150235244414e671185a8586e0152a2279b73e..31423919dbb03c10b173315574bad231a768dbce 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="DBAU1550"
 CONFIG_MIPS=y
 CONFIG_TARGET_DBAU1X00=y
+CONFIG_SYS_BIG_ENDIAN=y
index 53b35ce60f58d68008f9eea00e3d925cfb7c08ab..514f227627a086cf8a38b375ca51f0b291067855 100644 (file)
@@ -1,3 +1,4 @@
-CONFIG_SYS_EXTRA_OPTIONS="DBAU1550,SYS_LITTLE_ENDIAN"
+CONFIG_SYS_EXTRA_OPTIONS="DBAU1550"
 CONFIG_MIPS=y
 CONFIG_TARGET_DBAU1X00=y
+CONFIG_SYS_LITTLE_ENDIAN=y
index f3788b6db1fdd17a4ea2e8409503cbabdd86f01d..5a178a76b31a6cf709cd0af3844894caa9a8e14d 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_BIG_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_MALTA=y
+CONFIG_SYS_BIG_ENDIAN=y
index 97d0e899da345d3e574ccc6bd87171ed0de42f09..011525fc2b5344dbbcacceda08427736bf47fd3e 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_LITTLE_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_MALTA=y
+CONFIG_SYS_LITTLE_ENDIAN=y
index e226358fe2d32ad68bc94c0de270cff97af83ad4..72c22a0876b10c2c5432d952f3b298bbbfb79af5 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="PB1000"
 CONFIG_MIPS=y
 CONFIG_TARGET_PB1X00=y
+CONFIG_SYS_LITTLE_ENDIAN=y
index 2948355769870d02a60d3d9befe81c5084e85032..36897b997b20fdc5a261b6a56cbefd4163e76438 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_BIG_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_QEMU_MIPS64=y
+CONFIG_SYS_BIG_ENDIAN=y
index 13a039f0b81d9ea468f5738c008ca46004a921f7..70d226ae7f3a2d0efa911d78bd70452794adb4be 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_LITTLE_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_QEMU_MIPS64=y
+CONFIG_SYS_LITTLE_ENDIAN=y
index 6b2c0290e97102d44a433ec8c689a92f990cfe22..0a385af2c060c348ce2729762add1d23d4134277 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_BIG_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_QEMU_MIPS=y
+CONFIG_SYS_BIG_ENDIAN=y
index 57c87016c4d9b3f302d77213fc5b5a8b21d48765..d0acb2897226ff467bc65697bfb52a574cd8a146 100644 (file)
@@ -1,3 +1,3 @@
-CONFIG_SYS_EXTRA_OPTIONS="SYS_LITTLE_ENDIAN"
 CONFIG_MIPS=y
 CONFIG_TARGET_QEMU_MIPS=y
+CONFIG_SYS_LITTLE_ENDIAN=y
index 9ff8b684214c534fe89d3c005e1331537d77bf69..85584e37b14322f5cf81f9220261b62bc415d867 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUM"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index f33c97dc8f2a79fc1b8794991aafe1033a7a92dc..0ba7ae67aae8e9c769f085403fa8afea3b34f1de 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUM,VCT_ONENAND"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index 58c79955abf9d6de359e681a2c5b08d57fb9368e..d70a97938be2826005fef0ffa9113c7fc8bc94be 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUM,VCT_ONENAND,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index f4f56c4f4cb03ce9352d9a902e11d513cce498a8..ab5c2e12782928232a7e99d3791b9ec6aba9d3cb 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUM,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index 8aaac56e3defb262519e6405982c9dcfe8216168..691325d0cd929cd752d226563a9bb289502301b9 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUMAVC"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index 926c6e40504b118b9dc1bae07628cea42c42bf8f..1e0c3991ff3125ab923f2026d66df163727353e3 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUMAVC,VCT_ONENAND"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index 31b4c9a8d616fa80a30c64b8b156b3fc7d5b5674..f254ab6ad5dd44faa6bc01432843dc2f6683a1e6 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUMAVC,VCT_ONENAND,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index 23f6561b34ea846b18a9bf4a713075ae23804006..83670ed450ff01e3a9599f9d75b2a00dbbfff095 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PLATINUMAVC,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index 0e16ff9cacda499476e3b644f93189a1337de0c9..24bf87e70085978cc56d3c286fa76eea000ca50c 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PREMIUM"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index 29734b82749f725125638051f86db1d2eeea8e40..0039ec17e4539a2de6372f150a67c7f1e25ee4e6 100644 (file)
@@ -1,3 +1,4 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PREMIUM,VCT_ONENAND"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
index 354793edc858e089721cb27bf24818e99fbd95f6..8fc6ac1cffaeaa2ca5287aa3a07f6696758bfe72 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PREMIUM,VCT_ONENAND,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index a23ddb7e21351b5f718d2501679fa9a753e9ce1a..96bb0ee8c3c0ac0613f81e4a52a8b931f5584a14 100644 (file)
@@ -1,4 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="VCT_PREMIUM,VCT_SMALL_IMAGE"
 CONFIG_MIPS=y
 CONFIG_TARGET_VCT=y
+CONFIG_SYS_BIG_ENDIAN=y
 # CONFIG_CMD_CRC32 is not set
index f92496571bae610ab6b20bdce9086f6672e6f924..1c04a58e9fed7428afaa517c89dc5d68c4c39c08 100644 (file)
@@ -29,8 +29,6 @@
 #endif
 #endif
 
-#define CONFIG_SYS_LITTLE_ENDIAN
-
 #define CONFIG_ETHADDR         DE:AD:BE:EF:01:01    /* Ethernet address */
 
 #define CONFIG_BOOTDELAY       2       /* autoboot after 2 seconds     */