From: Sascha Hauer <s.hauer@pengutronix.de>
To: barebox@lists.infradead.org
Subject: [PATCH 15/15] ARM: i.MX: Karo TX25: Switch to multiboard support
Date: Fri, 31 Jan 2014 15:23:24 +0100 [thread overview]
Message-ID: <1391178204-20889-16-git-send-email-s.hauer@pengutronix.de> (raw)
In-Reply-To: <1391178204-20889-1-git-send-email-s.hauer@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/boards/karo-tx25/board.c | 2 +-
arch/arm/boards/karo-tx25/lowlevel.c | 26 +++++++++++++++-----------
arch/arm/configs/tx25stk5_defconfig | 20 ++++++++++++++++----
arch/arm/mach-imx/Kconfig | 14 +++++++-------
images/Makefile.imx | 5 +++++
5 files changed, 44 insertions(+), 23 deletions(-)
diff --git a/arch/arm/boards/karo-tx25/board.c b/arch/arm/boards/karo-tx25/board.c
index b4d553e..59c81b2 100644
--- a/arch/arm/boards/karo-tx25/board.c
+++ b/arch/arm/boards/karo-tx25/board.c
@@ -89,7 +89,7 @@ static int tx25_init(void)
armlinux_set_architecture(MACH_TYPE_TX25);
armlinux_set_serial(imx_uid());
- imx_bbu_external_nand_register_handler("nand", "/dev/nand0.barebox",
+ imx_bbu_external_nand_register_handler("nand", "/dev/nand0.boot",
BBU_HANDLER_FLAG_DEFAULT);
return 0;
diff --git a/arch/arm/boards/karo-tx25/lowlevel.c b/arch/arm/boards/karo-tx25/lowlevel.c
index a3a7784..be27bc7 100644
--- a/arch/arm/boards/karo-tx25/lowlevel.c
+++ b/arch/arm/boards/karo-tx25/lowlevel.c
@@ -75,12 +75,9 @@ static inline void __bare_init setup_sdram(uint32_t base, uint32_t esdctl,
writel(esdctl, esdctlreg);
}
-extern char __dtb_imx25_karo_tx25_start[];
-
-void __bare_init __naked barebox_arm_reset_vector(void)
+static void __bare_init karo_tx25_common_init(uint32_t fdt)
{
uint32_t r;
- uint32_t fdt;
arm_cpu_lowlevel_init();
@@ -139,8 +136,6 @@ void __bare_init __naked barebox_arm_reset_vector(void)
setup_uart();
- fdt = (uint32_t)__dtb_imx25_karo_tx25_start - get_runtime_offset();
-
/* Skip SDRAM initialization if we run from RAM */
r = get_pc();
if (r > 0x80000000 && r < 0xa0000000)
@@ -162,12 +157,21 @@ void __bare_init __naked barebox_arm_reset_vector(void)
setup_sdram(0x80000000, ESDCTLVAL, ESDCFGVAL);
setup_sdram(0x90000000, ESDCTLVAL, ESDCFGVAL);
-#ifdef CONFIG_NAND_IMX_BOOT
- /* setup a stack to be able to call imx25_barebox_boot_nand_external() */
- arm_setup_stack(MX25_IRAM_BASE_ADDR + MX25_IRAM_SIZE - 8);
-
imx25_barebox_boot_nand_external(fdt);
-#endif
+
out:
imx25_barebox_entry(fdt);
}
+
+extern char __dtb_imx25_karo_tx25_start[];
+
+ENTRY_FUNCTION(start_imx25_karo_tx25, r0, r1, r2)
+{
+ uint32_t fdt;
+
+ arm_setup_stack(MX25_IRAM_BASE_ADDR + MX25_IRAM_SIZE - 8);
+
+ fdt = (uint32_t)__dtb_imx25_karo_tx25_start - get_runtime_offset();
+
+ karo_tx25_common_init(fdt);
+}
diff --git a/arch/arm/configs/tx25stk5_defconfig b/arch/arm/configs/tx25stk5_defconfig
index 32a6183..5c9338d 100644
--- a/arch/arm/configs/tx25stk5_defconfig
+++ b/arch/arm/configs/tx25stk5_defconfig
@@ -1,14 +1,24 @@
-CONFIG_BUILTIN_DTB=y
-CONFIG_BUILTIN_DTB_NAME="imx25-karo-tx25"
CONFIG_ARCH_IMX=y
-CONFIG_ARCH_IMX_EXTERNAL_BOOT=y
CONFIG_ARCH_IMX_EXTERNAL_BOOT_NAND=y
+CONFIG_IMX_MULTI_BOARDS=y
CONFIG_MACH_TX25=y
+CONFIG_MACH_EFIKA_MX_SMARTBOOK=y
+CONFIG_MACH_FREESCALE_MX51_PDK=y
+CONFIG_MACH_FREESCALE_MX53_LOCO=y
+CONFIG_MACH_TQMA53=y
+CONFIG_MACH_FREESCALE_MX53_VMX53=y
+CONFIG_MACH_PHYTEC_PFLA02=y
+CONFIG_MACH_DFI_FS700_M60=y
+CONFIG_MACH_REALQ7=y
+CONFIG_MACH_GK802=y
+CONFIG_MACH_TQMA6X=y
+CONFIG_MACH_SABRELITE=y
+CONFIG_MACH_NITROGEN6X=y
+CONFIG_MACH_SOLIDRUN_HUMMINGBOARD=y
CONFIG_IMX_IIM=y
CONFIG_AEABI=y
CONFIG_ARM_OPTIMZED_STRING_FUNCTIONS=y
CONFIG_ARM_UNWIND=y
-CONFIG_PBL_IMAGE=y
CONFIG_MMU=y
CONFIG_TEXT_BASE=0x91d00000
CONFIG_MALLOC_SIZE=0x1000000
@@ -26,6 +36,7 @@ CONFIG_CMD_EDIT=y
CONFIG_CMD_SLEEP=y
CONFIG_CMD_MSLEEP=y
CONFIG_CMD_SAVEENV=y
+CONFIG_CMD_LOADENV=y
CONFIG_CMD_EXPORT=y
CONFIG_CMD_PRINTENV=y
CONFIG_CMD_READLINE=y
@@ -77,6 +88,7 @@ CONFIG_NAND=y
CONFIG_NAND_IMX=y
CONFIG_VIDEO=y
CONFIG_DRIVER_VIDEO_IMX=y
+CONFIG_IMXFB_DRIVER_VIDEO_IMX_OVERLAY=y
CONFIG_MCI=y
CONFIG_MCI_IMX_ESDHC=y
CONFIG_SRAM=y
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index 55038e8..f60ef2c 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -167,6 +167,13 @@ config IMX_MULTI_BOARDS
if IMX_MULTI_BOARDS
+config MACH_TX25
+ bool "Ka-Ro TX25"
+ select ARCH_IMX25
+ select ARCH_IMX_EXTERNAL_BOOT_NAND
+ help
+ Say Y here if you are using the Ka-Ro tx25 board
+
config MACH_EFIKA_MX_SMARTBOOK
bool "Efika MX smartbook"
select ARCH_IMX51
@@ -275,13 +282,6 @@ config MACH_FREESCALE_MX25_3STACK
Say Y here if you are using the Freescale MX25 3stack board equipped
with a Freescale i.MX25 Processor
-config MACH_TX25
- bool "Ka-Ro TX25"
- select ARCH_IMX25
- select HAVE_DEFAULT_ENVIRONMENT_NEW
- help
- Say Y here if you are using the Ka-Ro tx25 board
-
# ----------------------------------------------------------
comment "i.MX27 Boards"
diff --git a/images/Makefile.imx b/images/Makefile.imx
index 3318fcf..dd12242 100644
--- a/images/Makefile.imx
+++ b/images/Makefile.imx
@@ -9,6 +9,11 @@ $(obj)/%.imximg: $(obj)/% FORCE
board = $(srctree)/arch/$(ARCH)/boards
+# ----------------------- i.MX25 based boards ---------------------------
+pblx-$(CONFIG_MACH_TX25) += start_imx25_karo_tx25
+FILE_barebox-karo-tx25.img = start_imx25_karo_tx25.pblx
+image-$(CONFIG_MACH_TX25) += barebox-karo-tx25.img
+
# ----------------------- i.MX51 based boards ---------------------------
pblx-$(CONFIG_MACH_FREESCALE_MX51_PDK) += start_imx51_babbage
CFG_start_imx51_babbage.pblx.imximg = $(board)/freescale-mx51-pdk/flash-header-imx51-babbage.imxcfg
--
1.8.5.3
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
prev parent reply other threads:[~2014-01-31 14:24 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-31 14:23 i.MX25 devicetree support Sascha Hauer
2014-01-31 14:23 ` [PATCH 01/15] mci: imx-esdhc: Add i.MX25 compatible entry Sascha Hauer
2014-01-31 14:23 ` [PATCH 02/15] ARM: dts: Add i.MX25 devicetree files Sascha Hauer
2014-01-31 14:23 ` [PATCH 03/15] ARM: dts: i.MX25: Add mmc aliases Sascha Hauer
2014-01-31 14:23 ` [PATCH 04/15] ARM: dts: i.MX25: remove disabled status of usbmisc unit Sascha Hauer
2014-01-31 14:23 ` [PATCH 05/15] ARM: i.MX25: Add missing GPT clock lookups Sascha Hauer
2014-01-31 14:23 ` [PATCH 06/15] ARM: dts: Add i.MX25 Karo TX25 dts Sascha Hauer
2014-01-31 14:23 ` [PATCH 07/15] ARM: dts: i.MX25: Add iram to devicetree Sascha Hauer
2014-01-31 14:23 ` [PATCH 08/15] ARM: dts: Karo TX25: Add pinctrl nodes Sascha Hauer
2014-01-31 14:23 ` [PATCH 09/15] ARM: dts: Karo TX25: Add phy-reset-gpio Sascha Hauer
2014-01-31 14:23 ` [PATCH 10/15] ARM: dts: Karo TX25: add missing nfc properties Sascha Hauer
2014-01-31 14:23 ` [PATCH 11/15] ARM: dts: Karo TX25: add phy supply for fec Sascha Hauer
2014-01-31 14:23 ` [PATCH 12/15] ARM: dts: Karo TX25: add barebox specifics Sascha Hauer
2014-01-31 14:23 ` [PATCH 13/15] ARM: i.MX25: Karo TX25: Switch to devicetree support Sascha Hauer
2014-01-31 14:35 ` Alexander Shiyan
2014-02-01 18:13 ` Sascha Hauer
2014-02-01 18:24 ` Alexander Shiyan
2014-02-01 18:37 ` Sascha Hauer
2014-01-31 14:23 ` [PATCH 14/15] ARM: i.MX: cleanup bootmode selection Sascha Hauer
2014-01-31 14:23 ` Sascha Hauer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1391178204-20889-16-git-send-email-s.hauer@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox