* [PATCH] cubox multi image support
@ 2013-08-13 7:26 Sascha Hauer
2013-08-13 7:26 ` [PATCH 1/6] ARM: mvebu: move Makefile entries back to arch/arm/Makefile Sascha Hauer
` (6 more replies)
0 siblings, 7 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
The following converts the cubox to multi image support as a first
step towards merging the different mvebu ports.
Also the kwbimage generation is fixed on current master.
Sascha
----------------------------------------------------------------
Sascha Hauer (6):
ARM: mvebu: move Makefile entries back to arch/arm/Makefile
ARM: dts: cubox: fix stdout-path property
ARM: mvebu: introduce multi image support
ARM: mvebu: dove: use uart from devicetree
ARM: mvebu: dove: use timer from devicetree
ARM: mvebu: cubox: Update defconfig
arch/arm/Makefile | 5 ++++
arch/arm/boards/Makefile | 5 ----
arch/arm/boards/solidrun-cubox/Makefile | 1 +
arch/arm/boards/solidrun-cubox/lowlevel.c | 37 +++++++++++++++++++++++++++++
arch/arm/configs/solidrun_cubox_defconfig | 25 +++++++++++++++----
arch/arm/dts/Makefile | 1 +
arch/arm/dts/dove-cubox.dts | 2 +-
arch/arm/mach-mvebu/Kconfig | 1 +
arch/arm/mach-mvebu/Makefile | 2 +-
arch/arm/mach-mvebu/common.c | 4 ++--
arch/arm/mach-mvebu/dove.c | 19 +--------------
arch/arm/mach-mvebu/include/mach/lowlevel.h | 2 +-
arch/arm/mach-mvebu/lowlevel.c | 2 +-
images/.gitignore | 2 ++
images/Makefile | 4 +++-
images/Makefile.mvebu | 26 ++++++++++++++++++++
scripts/Makefile.lib | 3 +++
17 files changed, 107 insertions(+), 34 deletions(-)
create mode 100644 arch/arm/boards/solidrun-cubox/lowlevel.c
create mode 100644 images/Makefile.mvebu
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 1/6] ARM: mvebu: move Makefile entries back to arch/arm/Makefile
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 7:26 ` [PATCH 2/6] ARM: dts: cubox: fix stdout-path property Sascha Hauer
` (5 subsequent siblings)
6 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
The mvebu boards use the BOARD make variable for the kwbimage
generation. This only exists in the old way, so move the mvebu
board Makefile entries back to arch/arm/Makefile until they
are converted to multiboard.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/Makefile | 5 +++++
arch/arm/boards/Makefile | 5 -----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index d80c12c..4f45d57 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -82,12 +82,17 @@ machine-$(CONFIG_ARCH_ZYNQ) := zynq
board-$(CONFIG_MACH_A9M2410) += a9m2410
board-$(CONFIG_MACH_A9M2440) += a9m2440
board-$(CONFIG_MACH_AT91RM9200EK) += at91rm9200ek
+board-$(CONFIG_MACH_GLOBALSCALE_GURUPLUG) += globalscale-guruplug
+board-$(CONFIG_MACH_GLOBALSCALE_MIRABOX) += globalscale-mirabox
+board-$(CONFIG_MACH_MARVELL_ARMADA_XP_GP) += marvell-armada-xp-gp
board-$(CONFIG_MACH_MINI2440) += friendlyarm-mini2440
board-$(CONFIG_MACH_MINI6410) += friendlyarm-mini6410
board-$(CONFIG_MACH_PCM027) += pcm027
+board-$(CONFIG_MACH_PLATHOME_OPENBLOCKS_AX3) += plathome-openblocks-ax3/
board-$(CONFIG_MACH_SOLIDRUN_CUBOX) += solidrun-cubox
board-$(CONFIG_MACH_TINY210) += friendlyarm-tiny210
board-$(CONFIG_MACH_TINY6410) += friendlyarm-tiny6410
+board-$(CONFIG_MACH_USI_TOPKICK) += usi-topkick
machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
diff --git a/arch/arm/boards/Makefile b/arch/arm/boards/Makefile
index 2e924fd..d94d507 100644
--- a/arch/arm/boards/Makefile
+++ b/arch/arm/boards/Makefile
@@ -37,15 +37,12 @@ obj-$(CONFIG_MACH_FREESCALE_MX53_LOCO) += freescale-mx53-loco/
obj-$(CONFIG_MACH_FREESCALE_MX53_SMD) += freescale-mx53-smd/
obj-$(CONFIG_MACH_GE863) += telit-evk-pro3/
obj-$(CONFIG_MACH_GK802) += gk802/
-obj-$(CONFIG_MACH_GLOBALSCALE_GURUPLUG) += globalscale-guruplug/
-obj-$(CONFIG_MACH_GLOBALSCALE_MIRABOX) += globalscale-mirabox/
obj-$(CONFIG_MACH_GUF_CUPID) += guf-cupid/
obj-$(CONFIG_MACH_GUF_VINCELL) += guf-vincell/
obj-$(CONFIG_MACH_HIGHBANK) += highbank/
obj-$(CONFIG_MACH_IMX21ADS) += imx21ads/
obj-$(CONFIG_MACH_IMX233_OLINUXINO) += imx233-olinuxino/
obj-$(CONFIG_MACH_IMX27ADS) += imx27ads/
-obj-$(CONFIG_MACH_MARVELL_ARMADA_XP_GP) += marvell-armada-xp-gp/
obj-$(CONFIG_MACH_MIOA701) += mioa701/
obj-$(CONFIG_MACH_MMCCPU) += mmccpu/
obj-$(CONFIG_MACH_MX23EVK) += freescale-mx23-evk/
@@ -66,7 +63,6 @@ obj-$(CONFIG_MACH_PCM043) += pcm043/
obj-$(CONFIG_MACH_PCM049) += pcm049/
obj-$(CONFIG_MACH_PCM051) += pcm051/
obj-$(CONFIG_MACH_PHYTEC_PFLA02) += phytec-pfla02/
-obj-$(CONFIG_MACH_PLATHOME_OPENBLOCKS_AX3) += plathome-openblocks-ax3/
obj-$(CONFIG_MACH_PM9261) += pm9261/
obj-$(CONFIG_MACH_PM9263) += pm9263/
obj-$(CONFIG_MACH_PM9G45) += pm9g45/
@@ -91,7 +87,6 @@ obj-$(CONFIG_MACH_TX53) += karo-tx53/
obj-$(CONFIG_MACH_USB_A9260) += usb-a926x/
obj-$(CONFIG_MACH_USB_A9263) += usb-a926x/
obj-$(CONFIG_MACH_USB_A9G20) += usb-a926x/
-obj-$(CONFIG_MACH_USI_TOPKICK) += usi-topkick/
obj-$(CONFIG_MACH_VERSATILEPB) += versatile/
obj-$(CONFIG_MACH_VEXPRESS) += vexpress/
obj-$(CONFIG_MACH_ZEDBOARD) += avnet-zedboard/
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 2/6] ARM: dts: cubox: fix stdout-path property
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
2013-08-13 7:26 ` [PATCH 1/6] ARM: mvebu: move Makefile entries back to arch/arm/Makefile Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 7:26 ` [PATCH 3/6] ARM: mvebu: introduce multi image support Sascha Hauer
` (4 subsequent siblings)
6 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
It's linux,stdout-path, not linux,stdoutpath
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/dts/dove-cubox.dts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/dts/dove-cubox.dts b/arch/arm/dts/dove-cubox.dts
index dd575eb..61f38fe 100644
--- a/arch/arm/dts/dove-cubox.dts
+++ b/arch/arm/dts/dove-cubox.dts
@@ -13,7 +13,7 @@
chosen {
bootargs = "console=ttyS0,115200n8 earlyprintk";
- linux,stdoutpath = &uart0;
+ linux,stdout-path = &uart0;
};
leds {
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
2013-08-13 7:26 ` [PATCH 1/6] ARM: mvebu: move Makefile entries back to arch/arm/Makefile Sascha Hauer
2013-08-13 7:26 ` [PATCH 2/6] ARM: dts: cubox: fix stdout-path property Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 13:30 ` Sebastian Hesselbarth
2013-08-13 15:35 ` Sebastian Hesselbarth
2013-08-13 7:26 ` [PATCH 4/6] ARM: mvebu: dove: use uart from devicetree Sascha Hauer
` (3 subsequent siblings)
6 siblings, 2 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/boards/solidrun-cubox/Makefile | 1 +
arch/arm/boards/solidrun-cubox/lowlevel.c | 37 +++++++++++++++++++++++++++++
arch/arm/configs/solidrun_cubox_defconfig | 6 ++++-
arch/arm/dts/Makefile | 1 +
arch/arm/mach-mvebu/Kconfig | 1 +
arch/arm/mach-mvebu/Makefile | 2 +-
arch/arm/mach-mvebu/common.c | 4 ++--
arch/arm/mach-mvebu/include/mach/lowlevel.h | 2 +-
arch/arm/mach-mvebu/lowlevel.c | 2 +-
images/.gitignore | 2 ++
images/Makefile | 4 +++-
images/Makefile.mvebu | 26 ++++++++++++++++++++
scripts/Makefile.lib | 3 +++
13 files changed, 84 insertions(+), 7 deletions(-)
create mode 100644 arch/arm/boards/solidrun-cubox/lowlevel.c
create mode 100644 images/Makefile.mvebu
diff --git a/arch/arm/boards/solidrun-cubox/Makefile b/arch/arm/boards/solidrun-cubox/Makefile
index dcfc293..01c7a25 100644
--- a/arch/arm/boards/solidrun-cubox/Makefile
+++ b/arch/arm/boards/solidrun-cubox/Makefile
@@ -1 +1,2 @@
obj-y += board.o
+lwl-y += lowlevel.o
diff --git a/arch/arm/boards/solidrun-cubox/lowlevel.c b/arch/arm/boards/solidrun-cubox/lowlevel.c
new file mode 100644
index 0000000..fdf5a7e
--- /dev/null
+++ b/arch/arm/boards/solidrun-cubox/lowlevel.c
@@ -0,0 +1,37 @@
+/*
+ * Copyright (C) 2013
+ * Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+ * Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include <common.h>
+#include <sizes.h>
+#include <asm/barebox-arm.h>
+#include <asm/barebox-arm-head.h>
+#include <mach/lowlevel.h>
+
+extern char __dtb_dove_cubox_start[];
+
+ENTRY_FUNCTION(start_solidrun_cubox)(void)
+{
+ uint32_t fdt;
+
+ __barebox_arm_head();
+
+ arm_cpu_lowlevel_init();
+
+ fdt = (uint32_t)__dtb_dove_cubox_start - get_runtime_offset();
+
+ mvebu_barebox_entry(fdt);
+}
diff --git a/arch/arm/configs/solidrun_cubox_defconfig b/arch/arm/configs/solidrun_cubox_defconfig
index 61195ae..40f5c0d 100644
--- a/arch/arm/configs/solidrun_cubox_defconfig
+++ b/arch/arm/configs/solidrun_cubox_defconfig
@@ -5,11 +5,15 @@ CONFIG_ARCH_DOVE=y
CONFIG_AEABI=y
CONFIG_CMD_ARM_MMUINFO=y
CONFIG_ARM_OPTIMZED_STRING_FUNCTIONS=y
+CONFIG_ARM_UNWIND=y
+CONFIG_MALLOC_TLSF=y
+CONFIG_KALLSYMS=y
+CONFIG_RELOCATABLE=y
CONFIG_LONGHELP=y
CONFIG_CMDLINE_EDITING=y
CONFIG_AUTO_COMPLETE=y
-CONFIG_DEBUG_LL=y
CONFIG_CONSOLE_ACTIVATE_NONE=y
+CONFIG_DEBUG_LL=y
CONFIG_CMD_EDIT=y
CONFIG_CMD_SLEEP=y
CONFIG_CMD_MSLEEP=y
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 77645ff..fb4aa0b 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -18,6 +18,7 @@ pbl-$(CONFIG_MACH_FREESCALE_MX51_PDK) += imx51-babbage.dtb.o
pbl-$(CONFIG_MACH_FREESCALE_MX53_LOCO) += imx53-qsb.dtb.o
pbl-$(CONFIG_MACH_PHYTEC_PFLA02) += imx6q-phytec-pbab01.dtb.o
pbl-$(CONFIG_MACH_REALQ7) += imx6q-dmo-realq7.dtb.o
+pbl-$(CONFIG_MACH_SOLIDRUN_CUBOX) += dove-cubox.dtb.o
pbl-$(CONFIG_MACH_GK802) += imx6q-gk802.dtb.o
pbl-$(CONFIG_MACH_TQMA6X) += imx6dl-mba6x.dtb.o imx6q-mba6x.dtb.o
diff --git a/arch/arm/mach-mvebu/Kconfig b/arch/arm/mach-mvebu/Kconfig
index 3c38642..8bb2ead 100644
--- a/arch/arm/mach-mvebu/Kconfig
+++ b/arch/arm/mach-mvebu/Kconfig
@@ -88,6 +88,7 @@ choice
config MACH_SOLIDRUN_CUBOX
bool "SolidRun CuBox"
+ select HAVE_PBL_MULTI_IMAGES
endchoice
diff --git a/arch/arm/mach-mvebu/Makefile b/arch/arm/mach-mvebu/Makefile
index 80b3947..6e30366 100644
--- a/arch/arm/mach-mvebu/Makefile
+++ b/arch/arm/mach-mvebu/Makefile
@@ -1,5 +1,5 @@
lwl-y += lowlevel.o
-obj-y += common.o
+lwl-y += common.o
obj-$(CONFIG_ARCH_ARMADA_370) += armada-370-xp.o
obj-$(CONFIG_ARCH_ARMADA_XP) += armada-370-xp.o
obj-$(CONFIG_ARCH_DOVE) += dove.o
diff --git a/arch/arm/mach-mvebu/common.c b/arch/arm/mach-mvebu/common.c
index e2092c8..921b515 100644
--- a/arch/arm/mach-mvebu/common.c
+++ b/arch/arm/mach-mvebu/common.c
@@ -49,9 +49,9 @@ static void mvebu_remap_registers(void)
#define MVEBU_BOOTUP_MEMORY_BASE 0x00000000
#define MVEBU_BOOTUP_MEMORY_SIZE SZ_64M
-void __naked __noreturn mvebu_barebox_entry(void)
+void __naked __noreturn mvebu_barebox_entry(uint32_t boarddata)
{
mvebu_remap_registers();
barebox_arm_entry(MVEBU_BOOTUP_MEMORY_BASE,
- MVEBU_BOOTUP_MEMORY_SIZE, 0);
+ MVEBU_BOOTUP_MEMORY_SIZE, boarddata);
}
diff --git a/arch/arm/mach-mvebu/include/mach/lowlevel.h b/arch/arm/mach-mvebu/include/mach/lowlevel.h
index e86d928..9fbf1ea 100644
--- a/arch/arm/mach-mvebu/include/mach/lowlevel.h
+++ b/arch/arm/mach-mvebu/include/mach/lowlevel.h
@@ -18,6 +18,6 @@
#ifndef __MACH_LOWLEVEL_H__
#define __MACH_LOWLEVEL_H__
-void mvebu_barebox_entry(void);
+void mvebu_barebox_entry(uint32_t boarddata);
#endif
diff --git a/arch/arm/mach-mvebu/lowlevel.c b/arch/arm/mach-mvebu/lowlevel.c
index 3f64c4a..11810cc 100644
--- a/arch/arm/mach-mvebu/lowlevel.c
+++ b/arch/arm/mach-mvebu/lowlevel.c
@@ -24,5 +24,5 @@
void __naked barebox_arm_reset_vector(void)
{
arm_cpu_lowlevel_init();
- mvebu_barebox_entry();
+ mvebu_barebox_entry(0);
}
diff --git a/images/.gitignore b/images/.gitignore
index b15d560..9cc1728 100644
--- a/images/.gitignore
+++ b/images/.gitignore
@@ -5,6 +5,8 @@
*.imximg
*.map
*.src
+*.kwbimg
+*.kwbuartimg
pbl.lds
barebox.x
barebox.z
diff --git a/images/Makefile b/images/Makefile
index 65c533a..f17e699 100644
--- a/images/Makefile
+++ b/images/Makefile
@@ -108,6 +108,7 @@ $(obj)/%.img: $(obj)/$$(FILE_$$(@F))
$(call if_changed,shipped)
include $(srctree)/images/Makefile.imx
+include $(srctree)/images/Makefile.mvebu
targets += $(image-y) pbl.lds barebox.x barebox.z
targets += $(patsubst %,%.pblx,$(pblx-y))
@@ -121,5 +122,6 @@ SECONDARY: $(addprefix $(obj)/,$(targets))
images: $(addprefix $(obj)/, $(image-y)) FORCE
@echo "images built:\n" $(patsubst %,%\\n,$(image-y))
-clean-files := *.pbl *.pblb *.pblx *.map start_*.imximg *.img barebox.z
+clean-files := *.pbl *.pblb *.pblx *.map start_*.imximg *.img barebox.z start_*.kwbimg \
+ start_*.kwbuartimg
clean-files += pbl.lds
diff --git a/images/Makefile.mvebu b/images/Makefile.mvebu
new file mode 100644
index 0000000..fe92cc2
--- /dev/null
+++ b/images/Makefile.mvebu
@@ -0,0 +1,26 @@
+#
+# barebox image generation Makefile for Marvell mvebu
+#
+
+# %.kwbimg - convert into kwb image
+# ----------------------------------------------------------------
+$(obj)/%.kwbimg: $(obj)/% FORCE
+ $(call if_changed,kwb_image)
+$(obj)/%.kwbuartimg: $(obj)/% FORCE
+ $(call if_changed,kwb_image)
+
+board = $(srctree)/arch/$(ARCH)/boards
+
+# ----------------------- Dove 88AP510 based boards ---------------------------
+SOLIDRUN_CUBOX_KWBOPTS = -c -i $(board)/solidrun-cubox/kwbimage.cfg -d 0x1000000 -e 0x1000000
+pblx-$(CONFIG_MACH_SOLIDRUN_CUBOX) += start_solidrun_cubox
+OPTS_start_solidrun_cubox.pblx.kwbimg = $(SOLIDRUN_CUBOX_KWBOPTS)
+FILE_barebox-solidrun-cubox.img = start_solidrun_cubox.pblx.kwbimg
+image-$(CONFIG_MACH_SOLIDRUN_CUBOX) += barebox-solidrun-cubox.img
+
+OPTS_start_solidrun_cubox.pblx.kwbuartimg = -m uart $(SOLIDRUN_CUBOX_KWBOPTS)
+FILE_barebox-solidrun-cubox-uart.img = start_solidrun_cubox.pblx.kwbuartimg
+image-$(CONFIG_MACH_SOLIDRUN_CUBOX) += barebox-solidrun-cubox-uart.img
+
+FILE_barebox-solidrun-cubox-2nd.img = start_solidrun_cubox.pblx
+image-$(CONFIG_MACH_SOLIDRUN_CUBOX) += barebox-solidrun-cubox-2nd.img
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 4f34b54..3ff094f 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -343,3 +343,6 @@ imximg-tmp = $(subst $(comma),_,$(dot-target).imxcfg.tmp)
quiet_cmd_imx_image = IMX-IMG $@
cmd_imx_image = $(CPP) $(imxcfg_cpp_flags) -o $(imximg-tmp) $(CFG_$(@F)) ; \
$(objtree)/scripts/imx/imx-image -o $@ -b -c $(imximg-tmp) -f $<
+
+quiet_cmd_kwb_image = KWB $@
+ cmd_kwb_image = scripts/kwbimage -p $< $(OPTS_$(@F)) -o $@
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 4/6] ARM: mvebu: dove: use uart from devicetree
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
` (2 preceding siblings ...)
2013-08-13 7:26 ` [PATCH 3/6] ARM: mvebu: introduce multi image support Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 7:26 ` [PATCH 5/6] ARM: mvebu: dove: use timer " Sascha Hauer
` (2 subsequent siblings)
6 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/mach-mvebu/dove.c | 16 +---------------
1 file changed, 1 insertion(+), 15 deletions(-)
diff --git a/arch/arm/mach-mvebu/dove.c b/arch/arm/mach-mvebu/dove.c
index 16ee116..397e7a3 100644
--- a/arch/arm/mach-mvebu/dove.c
+++ b/arch/arm/mach-mvebu/dove.c
@@ -74,20 +74,6 @@ static inline void dove_memory_find(unsigned long *phys_base,
}
}
-static struct NS16550_plat uart_plat = {
- .shift = 2,
-};
-
-static int dove_add_uart(void)
-{
- uart_plat.clock = clk_get_rate(tclk);
- if (!add_ns16550_device(DEVICE_ID_DYNAMIC,
- (unsigned int)CONSOLE_UART_BASE, 32,
- IORESOURCE_MEM_32BIT, &uart_plat))
- return -ENODEV;
- return 0;
-}
-
/*
* Dove TCLK sample-at-reset configuation
*
@@ -126,12 +112,12 @@ static int dove_init_soc(void)
clkdev_add_physbase(tclk, (unsigned int)DOVE_TIMER_BASE, NULL);
clkdev_add_physbase(tclk, (unsigned int)DOVE_SPI0_BASE, NULL);
clkdev_add_physbase(tclk, (unsigned int)DOVE_SPI1_BASE, NULL);
+ clkdev_add_physbase(tclk, (unsigned int)CONSOLE_UART_BASE, NULL);
add_generic_device("orion-timer", DEVICE_ID_SINGLE, NULL,
(unsigned int)DOVE_TIMER_BASE, 0x30,
IORESOURCE_MEM, NULL);
dove_memory_find(&phys_base, &phys_size);
arm_add_mem_device("ram0", phys_base, phys_size);
- dove_add_uart();
return 0;
}
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 5/6] ARM: mvebu: dove: use timer from devicetree
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
` (3 preceding siblings ...)
2013-08-13 7:26 ` [PATCH 4/6] ARM: mvebu: dove: use uart from devicetree Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 7:26 ` [PATCH 6/6] ARM: mvebu: cubox: Update defconfig Sascha Hauer
2013-08-13 8:12 ` [PATCH] cubox multi image support Thomas Petazzoni
6 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/mach-mvebu/dove.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/arch/arm/mach-mvebu/dove.c b/arch/arm/mach-mvebu/dove.c
index 397e7a3..a943c6d 100644
--- a/arch/arm/mach-mvebu/dove.c
+++ b/arch/arm/mach-mvebu/dove.c
@@ -113,9 +113,6 @@ static int dove_init_soc(void)
clkdev_add_physbase(tclk, (unsigned int)DOVE_SPI0_BASE, NULL);
clkdev_add_physbase(tclk, (unsigned int)DOVE_SPI1_BASE, NULL);
clkdev_add_physbase(tclk, (unsigned int)CONSOLE_UART_BASE, NULL);
- add_generic_device("orion-timer", DEVICE_ID_SINGLE, NULL,
- (unsigned int)DOVE_TIMER_BASE, 0x30,
- IORESOURCE_MEM, NULL);
dove_memory_find(&phys_base, &phys_size);
arm_add_mem_device("ram0", phys_base, phys_size);
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 6/6] ARM: mvebu: cubox: Update defconfig
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
` (4 preceding siblings ...)
2013-08-13 7:26 ` [PATCH 5/6] ARM: mvebu: dove: use timer " Sascha Hauer
@ 2013-08-13 7:26 ` Sascha Hauer
2013-08-13 8:12 ` [PATCH] cubox multi image support Thomas Petazzoni
6 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 7:26 UTC (permalink / raw)
To: barebox; +Cc: Thomas Petazzoni
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/configs/solidrun_cubox_defconfig | 19 ++++++++++++++++---
1 file changed, 16 insertions(+), 3 deletions(-)
diff --git a/arch/arm/configs/solidrun_cubox_defconfig b/arch/arm/configs/solidrun_cubox_defconfig
index 40f5c0d..eca7d7f 100644
--- a/arch/arm/configs/solidrun_cubox_defconfig
+++ b/arch/arm/configs/solidrun_cubox_defconfig
@@ -1,18 +1,23 @@
-CONFIG_BUILTIN_DTB=y
-CONFIG_BUILTIN_DTB_NAME="dove-cubox"
CONFIG_ARCH_MVEBU=y
CONFIG_ARCH_DOVE=y
-CONFIG_AEABI=y
+CONFIG_THUMB2_BAREBOX=y
CONFIG_CMD_ARM_MMUINFO=y
CONFIG_ARM_OPTIMZED_STRING_FUNCTIONS=y
CONFIG_ARM_UNWIND=y
+CONFIG_MMU=y
+CONFIG_TEXT_BASE=0x0
+CONFIG_MALLOC_SIZE=0x0
CONFIG_MALLOC_TLSF=y
CONFIG_KALLSYMS=y
CONFIG_RELOCATABLE=y
CONFIG_LONGHELP=y
+CONFIG_HUSH_FANCY_PROMPT=y
+CONFIG_HUSH_GETOPT=y
CONFIG_CMDLINE_EDITING=y
CONFIG_AUTO_COMPLETE=y
+CONFIG_MENU=y
CONFIG_CONSOLE_ACTIVATE_NONE=y
+CONFIG_PARTITION_DISK_EFI=y
CONFIG_DEBUG_LL=y
CONFIG_CMD_EDIT=y
CONFIG_CMD_SLEEP=y
@@ -22,6 +27,8 @@ CONFIG_CMD_EXPORT=y
CONFIG_CMD_PRINTENV=y
CONFIG_CMD_READLINE=y
CONFIG_CMD_LET=y
+CONFIG_CMD_MENU=y
+CONFIG_CMD_MENU_MANAGEMENT=y
CONFIG_CMD_TIME=y
CONFIG_CMD_GLOBAL=y
CONFIG_CMD_AUTOMOUNT=y
@@ -35,6 +42,8 @@ CONFIG_CMD_LOADY=y
CONFIG_CMD_LOADS=y
CONFIG_CMD_MEMINFO=y
CONFIG_CMD_IOMEM=y
+CONFIG_CMD_CRC=y
+CONFIG_CMD_CRC_CMP=y
CONFIG_CMD_MD5SUM=y
CONFIG_CMD_SHA1SUM=y
CONFIG_CMD_SHA256SUM=y
@@ -45,6 +54,7 @@ CONFIG_CMD_BOOTM_INITRD=y
CONFIG_CMD_BOOTM_OFTREE=y
CONFIG_CMD_BOOTM_OFTREE_UIMAGE=y
CONFIG_CMD_UIMAGE=y
+CONFIG_FLEXIBLE_BOOTARGS=y
CONFIG_CMD_RESET=y
CONFIG_CMD_GO=y
CONFIG_CMD_OFTREE=y
@@ -52,6 +62,8 @@ CONFIG_CMD_OF_PROPERTY=y
CONFIG_CMD_OF_NODE=y
CONFIG_CMD_TIMEOUT=y
CONFIG_CMD_PARTITION=y
+CONFIG_CMD_MAGICVAR=y
+CONFIG_CMD_MAGICVAR_HELP=y
CONFIG_CMD_UNCOMPRESS=y
CONFIG_CMD_I2C=y
CONFIG_CMD_SPI=y
@@ -61,6 +73,7 @@ CONFIG_CMD_CLK=y
CONFIG_CMD_DETECT=y
CONFIG_CMD_WD=y
CONFIG_OFDEVICE=y
+CONFIG_OF_BAREBOX_DRIVERS=y
CONFIG_DRIVER_SERIAL_NS16550=y
CONFIG_DRIVER_SPI_MVEBU=y
CONFIG_I2C=y
--
1.8.4.rc2
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH] cubox multi image support
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
` (5 preceding siblings ...)
2013-08-13 7:26 ` [PATCH 6/6] ARM: mvebu: cubox: Update defconfig Sascha Hauer
@ 2013-08-13 8:12 ` Thomas Petazzoni
2013-08-13 8:16 ` Sascha Hauer
6 siblings, 1 reply; 14+ messages in thread
From: Thomas Petazzoni @ 2013-08-13 8:12 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
Dear Sascha Hauer,
On Tue, 13 Aug 2013 09:26:06 +0200, Sascha Hauer wrote:
> The following converts the cubox to multi image support as a first
> step towards merging the different mvebu ports.
Is there more background about what "multi image support" is ?
Thanks,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH] cubox multi image support
2013-08-13 8:12 ` [PATCH] cubox multi image support Thomas Petazzoni
@ 2013-08-13 8:16 ` Sascha Hauer
0 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 8:16 UTC (permalink / raw)
To: Thomas Petazzoni; +Cc: barebox
On Tue, Aug 13, 2013 at 10:12:15AM +0200, Thomas Petazzoni wrote:
> Dear Sascha Hauer,
>
> On Tue, 13 Aug 2013 09:26:06 +0200, Sascha Hauer wrote:
> > The following converts the cubox to multi image support as a first
> > step towards merging the different mvebu ports.
>
> Is there more background about what "multi image support" is ?
Multi image support is the mechanism for generating multiple (board- or
SoC-) specific images out of the same barebox binary. Basically it makes
it possible to have a single defconfig for all mvebu boards. Try for
example the imx_v7_defconfig, it currently builds:
barebox-freescale-imx51-babbage.img
barebox-genesi-efikasb.img
barebox-freescale-imx53-loco.img
barebox-datamodul-edm-qmx6.img
barebox-gk802.img
barebox-tq-tqma6s-mba6x.img
barebox-tq-tqma6q-mba6x.img
barebox-phytec-pbab01-2gib.img
barebox-phytec-pbab01-1gib.img
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 7:26 ` [PATCH 3/6] ARM: mvebu: introduce multi image support Sascha Hauer
@ 2013-08-13 13:30 ` Sebastian Hesselbarth
2013-08-13 14:15 ` Sascha Hauer
2013-08-13 15:35 ` Sebastian Hesselbarth
1 sibling, 1 reply; 14+ messages in thread
From: Sebastian Hesselbarth @ 2013-08-13 13:30 UTC (permalink / raw)
To: Sascha Hauer; +Cc: Thomas Petazzoni, barebox
On 08/13/13 09:26, Sascha Hauer wrote:
> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> ---
> arch/arm/boards/solidrun-cubox/Makefile | 1 +
> arch/arm/boards/solidrun-cubox/lowlevel.c | 37 +++++++++++++++++++++++++++++
> arch/arm/configs/solidrun_cubox_defconfig | 6 ++++-
> arch/arm/dts/Makefile | 1 +
> arch/arm/mach-mvebu/Kconfig | 1 +
> arch/arm/mach-mvebu/Makefile | 2 +-
> arch/arm/mach-mvebu/common.c | 4 ++--
> arch/arm/mach-mvebu/include/mach/lowlevel.h | 2 +-
> arch/arm/mach-mvebu/lowlevel.c | 2 +-
> images/.gitignore | 2 ++
> images/Makefile | 4 +++-
> images/Makefile.mvebu | 26 ++++++++++++++++++++
> scripts/Makefile.lib | 3 +++
> 13 files changed, 84 insertions(+), 7 deletions(-)
> create mode 100644 arch/arm/boards/solidrun-cubox/lowlevel.c
> create mode 100644 images/Makefile.mvebu
[...]
> diff --git a/arch/arm/boards/solidrun-cubox/lowlevel.c b/arch/arm/boards/solidrun-cubox/lowlevel.c
> new file mode 100644
> index 0000000..fdf5a7e
> --- /dev/null
> +++ b/arch/arm/boards/solidrun-cubox/lowlevel.c
> @@ -0,0 +1,37 @@
[...]
> +ENTRY_FUNCTION(start_solidrun_cubox)(void)
> +{
> + uint32_t fdt;
> +
> + __barebox_arm_head();
> +
> + arm_cpu_lowlevel_init();
> +
> + fdt = (uint32_t)__dtb_dove_cubox_start - get_runtime_offset();
> +
> + mvebu_barebox_entry(fdt);
> +}
[...]
> diff --git a/arch/arm/mach-mvebu/lowlevel.c
b/arch/arm/mach-mvebu/lowlevel.c
> index 3f64c4a..11810cc 100644
> --- a/arch/arm/mach-mvebu/lowlevel.c
> +++ b/arch/arm/mach-mvebu/lowlevel.c
> @@ -24,5 +24,5 @@
> void __naked barebox_arm_reset_vector(void)
> {
> arm_cpu_lowlevel_init();
> - mvebu_barebox_entry();
> + mvebu_barebox_entry(0);
> }
Sascha,
thanks for the patch set, I'll give it a go soon.
I understand that this is just a first step, but you are adding extra
lowlevel init to boards/solidrun-cubox/lowlevel.c but in the end it
should be part of mach-mvebu/lowlevel.c instead?
I have a some MVEBU boards with Dove and Armada 370 available and
could extend the patches to have a single lowlevel init again.
Sebastian
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 13:30 ` Sebastian Hesselbarth
@ 2013-08-13 14:15 ` Sascha Hauer
2013-08-13 14:22 ` Sebastian Hesselbarth
0 siblings, 1 reply; 14+ messages in thread
From: Sascha Hauer @ 2013-08-13 14:15 UTC (permalink / raw)
To: Sebastian Hesselbarth; +Cc: Thomas Petazzoni, barebox
On Tue, Aug 13, 2013 at 03:30:38PM +0200, Sebastian Hesselbarth wrote:
> On 08/13/13 09:26, Sascha Hauer wrote:
> >diff --git a/arch/arm/boards/solidrun-cubox/lowlevel.c b/arch/arm/boards/solidrun-cubox/lowlevel.c
> >new file mode 100644
> >index 0000000..fdf5a7e
> >--- /dev/null
> >+++ b/arch/arm/boards/solidrun-cubox/lowlevel.c
> >@@ -0,0 +1,37 @@
> [...]
> >+ENTRY_FUNCTION(start_solidrun_cubox)(void)
> >+{
> >+ uint32_t fdt;
> >+
> >+ __barebox_arm_head();
> >+
> >+ arm_cpu_lowlevel_init();
> >+
> >+ fdt = (uint32_t)__dtb_dove_cubox_start - get_runtime_offset();
> >+
> >+ mvebu_barebox_entry(fdt);
> >+}
> [...]
> > diff --git a/arch/arm/mach-mvebu/lowlevel.c
> b/arch/arm/mach-mvebu/lowlevel.c
> > index 3f64c4a..11810cc 100644
> > --- a/arch/arm/mach-mvebu/lowlevel.c
> > +++ b/arch/arm/mach-mvebu/lowlevel.c
> > @@ -24,5 +24,5 @@
> > void __naked barebox_arm_reset_vector(void)
> > {
> > arm_cpu_lowlevel_init();
> > - mvebu_barebox_entry();
> > + mvebu_barebox_entry(0);
> > }
>
> Sascha,
>
> thanks for the patch set, I'll give it a go soon.
>
> I understand that this is just a first step, but you are adding extra
> lowlevel init to boards/solidrun-cubox/lowlevel.c but in the end it
> should be part of mach-mvebu/lowlevel.c instead?
>
> I have a some MVEBU boards with Dove and Armada 370 available and
> could extend the patches to have a single lowlevel init again.
The board specific lowlevel init is necessary since this specifies the
dtb to use. Otherwise there's no way to find out on which board you are
running on.
(Another possibility would be to somehow append a devicetree, but I
haven't found a good way to do that)
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 14:15 ` Sascha Hauer
@ 2013-08-13 14:22 ` Sebastian Hesselbarth
2013-08-14 6:20 ` Sascha Hauer
0 siblings, 1 reply; 14+ messages in thread
From: Sebastian Hesselbarth @ 2013-08-13 14:22 UTC (permalink / raw)
To: Sascha Hauer; +Cc: Thomas Petazzoni, barebox
On 08/13/13 16:15, Sascha Hauer wrote:
> On Tue, Aug 13, 2013 at 03:30:38PM +0200, Sebastian Hesselbarth wrote:
>> On 08/13/13 09:26, Sascha Hauer wrote:
>>> diff --git a/arch/arm/boards/solidrun-cubox/lowlevel.c b/arch/arm/boards/solidrun-cubox/lowlevel.c
>>> new file mode 100644
>>> index 0000000..fdf5a7e
>>> --- /dev/null
>>> +++ b/arch/arm/boards/solidrun-cubox/lowlevel.c
>>> @@ -0,0 +1,37 @@
>> [...]
>>> +ENTRY_FUNCTION(start_solidrun_cubox)(void)
>>> +{
>>> + uint32_t fdt;
>>> +
>>> + __barebox_arm_head();
>>> +
>>> + arm_cpu_lowlevel_init();
>>> +
>>> + fdt = (uint32_t)__dtb_dove_cubox_start - get_runtime_offset();
>>> +
>>> + mvebu_barebox_entry(fdt);
>>> +}
>> [...]
>>> diff --git a/arch/arm/mach-mvebu/lowlevel.c
>> b/arch/arm/mach-mvebu/lowlevel.c
>>> index 3f64c4a..11810cc 100644
>>> --- a/arch/arm/mach-mvebu/lowlevel.c
>>> +++ b/arch/arm/mach-mvebu/lowlevel.c
>>> @@ -24,5 +24,5 @@
>>> void __naked barebox_arm_reset_vector(void)
>>> {
>>> arm_cpu_lowlevel_init();
>>> - mvebu_barebox_entry();
>>> + mvebu_barebox_entry(0);
>>> }
>>
>> Sascha,
>>
>> thanks for the patch set, I'll give it a go soon.
>>
>> I understand that this is just a first step, but you are adding extra
>> lowlevel init to boards/solidrun-cubox/lowlevel.c but in the end it
>> should be part of mach-mvebu/lowlevel.c instead?
>>
>> I have a some MVEBU boards with Dove and Armada 370 available and
>> could extend the patches to have a single lowlevel init again.
>
> The board specific lowlevel init is necessary since this specifies the
> dtb to use. Otherwise there's no way to find out on which board you are
> running on.
Ok, but I could try to cook the board lowlevel init down to its bare
minimum and only set fdt address. Or have some mvebu specific
fdt_address variable that can be overwritten. The less board specific
stuff there is, the better.
Sebastian
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 7:26 ` [PATCH 3/6] ARM: mvebu: introduce multi image support Sascha Hauer
2013-08-13 13:30 ` Sebastian Hesselbarth
@ 2013-08-13 15:35 ` Sebastian Hesselbarth
1 sibling, 0 replies; 14+ messages in thread
From: Sebastian Hesselbarth @ 2013-08-13 15:35 UTC (permalink / raw)
To: Sascha Hauer; +Cc: Thomas Petazzoni, barebox
On 08/13/13 09:26, Sascha Hauer wrote:
> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> ---
> arch/arm/boards/solidrun-cubox/Makefile | 1 +
> arch/arm/boards/solidrun-cubox/lowlevel.c | 37 +++++++++++++++++++++++++++++
> arch/arm/configs/solidrun_cubox_defconfig | 6 ++++-
> arch/arm/dts/Makefile | 1 +
> arch/arm/mach-mvebu/Kconfig | 1 +
> arch/arm/mach-mvebu/Makefile | 2 +-
> arch/arm/mach-mvebu/common.c | 4 ++--
> arch/arm/mach-mvebu/include/mach/lowlevel.h | 2 +-
> arch/arm/mach-mvebu/lowlevel.c | 2 +-
> images/.gitignore | 2 ++
> images/Makefile | 4 +++-
> images/Makefile.mvebu | 26 ++++++++++++++++++++
> scripts/Makefile.lib | 3 +++
> 13 files changed, 84 insertions(+), 7 deletions(-)
> create mode 100644 arch/arm/boards/solidrun-cubox/lowlevel.c
> create mode 100644 images/Makefile.mvebu
>
> diff --git a/arch/arm/boards/solidrun-cubox/Makefile b/arch/arm/boards/solidrun-cubox/Makefile
> index dcfc293..01c7a25 100644
> --- a/arch/arm/boards/solidrun-cubox/Makefile
> +++ b/arch/arm/boards/solidrun-cubox/Makefile
> @@ -1 +1,2 @@
> obj-y += board.o
> +lwl-y += lowlevel.o
> diff --git a/arch/arm/boards/solidrun-cubox/lowlevel.c b/arch/arm/boards/solidrun-cubox/lowlevel.c
> new file mode 100644
> index 0000000..fdf5a7e
> --- /dev/null
> +++ b/arch/arm/boards/solidrun-cubox/lowlevel.c
> @@ -0,0 +1,37 @@
> +/*
> + * Copyright (C) 2013
> + * Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> + * Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
> + *
> + * This program is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU General Public License as
> + * published by the Free Software Foundation; either version 2 of
> + * the License, or (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + *
> + */
> +
> +#include <common.h>
> +#include <sizes.h>
> +#include <asm/barebox-arm.h>
> +#include <asm/barebox-arm-head.h>
> +#include <mach/lowlevel.h>
> +
> +extern char __dtb_dove_cubox_start[];
> +
> +ENTRY_FUNCTION(start_solidrun_cubox)(void)
> +{
> + uint32_t fdt;
> +
> + __barebox_arm_head();
> +
> + arm_cpu_lowlevel_init();
> +
> + fdt = (uint32_t)__dtb_dove_cubox_start - get_runtime_offset();
> +
> + mvebu_barebox_entry(fdt);
> +}
Sascha,
I have tested the series on my CuBox, so you can add my Tested-by.
If we find a naming pattern for the entry function above based on
the board name, we could also have a macro for it, e.g. rename
"start_solidrun_cubox" to "start_dove_cubox".
Sebastian
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 3/6] ARM: mvebu: introduce multi image support
2013-08-13 14:22 ` Sebastian Hesselbarth
@ 2013-08-14 6:20 ` Sascha Hauer
0 siblings, 0 replies; 14+ messages in thread
From: Sascha Hauer @ 2013-08-14 6:20 UTC (permalink / raw)
To: Sebastian Hesselbarth; +Cc: Thomas Petazzoni, barebox
On Tue, Aug 13, 2013 at 04:22:43PM +0200, Sebastian Hesselbarth wrote:
> >>>diff --git a/arch/arm/mach-mvebu/lowlevel.c
> >>b/arch/arm/mach-mvebu/lowlevel.c
> >>>index 3f64c4a..11810cc 100644
> >>>--- a/arch/arm/mach-mvebu/lowlevel.c
> >>>+++ b/arch/arm/mach-mvebu/lowlevel.c
> >>>@@ -24,5 +24,5 @@
> >>> void __naked barebox_arm_reset_vector(void)
> >>> {
> >>> arm_cpu_lowlevel_init();
> >>>- mvebu_barebox_entry();
> >>>+ mvebu_barebox_entry(0);
> >>> }
> >>
> >>Sascha,
> >>
> >>thanks for the patch set, I'll give it a go soon.
> >>
> >>I understand that this is just a first step, but you are adding extra
> >>lowlevel init to boards/solidrun-cubox/lowlevel.c but in the end it
> >>should be part of mach-mvebu/lowlevel.c instead?
> >>
> >>I have a some MVEBU boards with Dove and Armada 370 available and
> >>could extend the patches to have a single lowlevel init again.
> >
> >The board specific lowlevel init is necessary since this specifies the
> >dtb to use. Otherwise there's no way to find out on which board you are
> >running on.
>
> Ok, but I could try to cook the board lowlevel init down to its bare
> minimum and only set fdt address. Or have some mvebu specific
> fdt_address variable that can be overwritten. The less board specific
> stuff there is, the better.
If you find ways to redruce the board specific code, go ahead. Note that
this code does not run at the address it's linked at, so accessing
global variables is not possible.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2013-08-14 6:20 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-13 7:26 [PATCH] cubox multi image support Sascha Hauer
2013-08-13 7:26 ` [PATCH 1/6] ARM: mvebu: move Makefile entries back to arch/arm/Makefile Sascha Hauer
2013-08-13 7:26 ` [PATCH 2/6] ARM: dts: cubox: fix stdout-path property Sascha Hauer
2013-08-13 7:26 ` [PATCH 3/6] ARM: mvebu: introduce multi image support Sascha Hauer
2013-08-13 13:30 ` Sebastian Hesselbarth
2013-08-13 14:15 ` Sascha Hauer
2013-08-13 14:22 ` Sebastian Hesselbarth
2013-08-14 6:20 ` Sascha Hauer
2013-08-13 15:35 ` Sebastian Hesselbarth
2013-08-13 7:26 ` [PATCH 4/6] ARM: mvebu: dove: use uart from devicetree Sascha Hauer
2013-08-13 7:26 ` [PATCH 5/6] ARM: mvebu: dove: use timer " Sascha Hauer
2013-08-13 7:26 ` [PATCH 6/6] ARM: mvebu: cubox: Update defconfig Sascha Hauer
2013-08-13 8:12 ` [PATCH] cubox multi image support Thomas Petazzoni
2013-08-13 8:16 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox