* Re: USB On PCM043?
From: Jerry Kirk @ 2012-07-19 20:56 UTC (permalink / raw)
To: barebox
In-Reply-To: <20120719161139.GB30009@pengutronix.de>
> > We have been attempting to get USB Host mode working under Barebox(2012-07-0)
> > a PCM043 platform (i.mx35), but we are having a bit of trouble.
>
> Could it be that the USB clock operates at the wrong rate? I think it
> should be 60MHz.
We're not certain how to verify the clock setting for USB in Barebox.
We have used "dump_clocks" but are not certain which of these clocks
the USB clock is derived from. We think we have it set to the same
settings as the Eukrea board.
Do you know of anyone that has used USB on the pcm043 board?
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* Re: [PATCH 8/9] ARM: Separate assembler functions into their own section
From: Sascha Hauer @ 2012-07-19 20:45 UTC (permalink / raw)
To: Marc Kleine-Budde; +Cc: barebox
In-Reply-To: <20120719140834.GY30009@pengutronix.de>
On Thu, Jul 19, 2012 at 04:08:34PM +0200, Sascha Hauer wrote:
> On Thu, Jul 19, 2012 at 12:38:03PM +0200, Marc Kleine-Budde wrote:
> > On 07/19/2012 10:13 AM, Sascha Hauer wrote:
> > > To let the linker remove unused functions.
> > >
> > > Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> > > ---
> > > arch/arm/cpu/cache-armv4.S | 7 ++++++-
> > > arch/arm/cpu/cache-armv5.S | 7 ++++++-
> > > arch/arm/cpu/cache-armv6.S | 11 +++++++++--
> > > arch/arm/cpu/cache-armv7.S | 8 ++++++--
> > > arch/arm/lib/ashldi3.S | 1 +
> > > arch/arm/lib/ashrdi3.S | 1 +
> > > arch/arm/lib/findbit.S | 9 +++++++++
> > > arch/arm/lib/io-writesw-armv4.S | 2 ++
> > > arch/arm/lib/lib1funcs.S | 7 +++++++
> > > arch/arm/lib/lshrdi3.S | 1 +
> > > 10 files changed, 48 insertions(+), 6 deletions(-)
> > >
> > > diff --git a/arch/arm/cpu/cache-armv4.S b/arch/arm/cpu/cache-armv4.S
> > > index 6d03565..2231eee 100644
> > > --- a/arch/arm/cpu/cache-armv4.S
> > > +++ b/arch/arm/cpu/cache-armv4.S
> > > @@ -3,6 +3,7 @@
> > >
> > > #define CACHE_DLINESIZE 32
> > >
> > > +.section .text.__mmu_cache_on
> > > ENTRY(__mmu_cache_on)
> >
> > Is it possible to add the section to the ENTRY macro?
>
> I'm not sure. I was pretty sure that some assembly functions fall
> through to the next function. I cannot find any examples though.
For example we have this:
.section .text.__divsi3
ENTRY(__divsi3)
ENTRY(__aeabi_idiv)
...
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
* Re: [PATCH 9/9] Add compressed image support
From: Sascha Hauer @ 2012-07-19 20:42 UTC (permalink / raw)
To: Johannes Stezenbach; +Cc: barebox
In-Reply-To: <20120719183238.GA3721@sig21.net>
On Thu, Jul 19, 2012 at 08:32:38PM +0200, Johannes Stezenbach wrote:
> > > ...
> > > LD barebox
> > > arm-linux-ld -EL -Map barebox.map -static --gc-sections -o barebox \
> > > -T arch/arm/lib/barebox-compressed.lds \
> > > --start-group common/built-in.o drivers/built-in.o commands/built-in.o lib/built-in.o crypto/built-in.o net/built-in.o fs/built-in.o arch/arm/boards/foo/built-in.o arch/arm/mach-foo/built-in.o arch/arm/lib/built-in.o arch/arm/cpu/built-in.o piggy.lzo.o --end-group
> > >
> > >
> > > It shouldn't link all the -built-in.o into the uncompressor, should it?
> > > Or is it supposed to work via --gc-sections trick?
> >
> > Yes, it works using --gc-sections. Are you building a defconfig or a
> > custom one? If the error above is correct start_barebox is referenced
> > from the decompressor code. This should not happen.
>
> I'm building a custom one (unpublished code). It has some SPI flash
> boot assembly code, I guess that might cause the issue wrt the new section
> annotations. I'll look at it tomorrow. However, I still wonder
> about the empty $(barebox-compressed)?
It's empty here aswell, so this shouldn't be a problem. Though I should
probably simpy remove it.
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
* Re: Compressed barebox image support
From: Robert Jarzmik @ 2012-07-19 20:11 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <1342685582-13244-1-git-send-email-s.hauer@pengutronix.de>
Sascha Hauer <s.hauer@pengutronix.de> writes:
> Nevertheless I would be happy about Tested-by (and does-not-work-for) tags.
>
> Sascha
I tried on Xscale PXA (mioa701 board, armv5te).
It works like a charm.
Therefore, feel free to add my :
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
--
Robert
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* [PATCH] ARM/Samsung: add the vendor FriendlyARM to the board's directory name
From: Juergen Beisert @ 2012-07-19 20:08 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342728533-3750-1-git-send-email-jbe@pengutronix.de>
Since a look into "arch/arm/boards/" offers various boards starting with the
vendor's name in their directory name (like 'eukrea' and 'freescale').
This patch does the same with the currently existing FriendlyARM boards
Mini2440 and Tiny210. More boards of this vendor will follow.
Signed-off-by: Juergen Beisert <jbe@pengutronix.de>
---
arch/arm/Makefile | 4 ++--
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Kconfig | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Makefile | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/config.h | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/env/config | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/lowlevel_init.S | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/mini2440.c | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/Makefile | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/config.h | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/lowlevel.c | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/tiny210.c | 0
.../configs/{mini2440_defconfig => friendlyarm_mini2440_defconfig} | 2 +-
.../configs/{tiny210_defconfig => friendlyarm_tiny210_defconfig} | 0
arch/arm/mach-samsung/Kconfig | 2 +-
14 files changed, 4 insertions(+), 4 deletions(-)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Kconfig (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Makefile (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/config.h (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/env/config (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/lowlevel_init.S (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/mini2440.c (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/Makefile (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/config.h (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/lowlevel.c (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/tiny210.c (100%)
rename arch/arm/configs/{mini2440_defconfig => friendlyarm_mini2440_defconfig} (92%)
rename arch/arm/configs/{tiny210_defconfig => friendlyarm_tiny210_defconfig} (100%)
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 9488359..8d661a4 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -122,7 +122,7 @@ board-$(CONFIG_MACH_FREESCALE_MX51_PDK) := freescale-mx51-pdk
board-$(CONFIG_MACH_FREESCALE_MX53_LOCO) := freescale-mx53-loco
board-$(CONFIG_MACH_FREESCALE_MX53_SMD) := freescale-mx53-smd
board-$(CONFIG_MACH_GUF_CUPID) := guf-cupid
-board-$(CONFIG_MACH_MINI2440) := mini2440
+board-$(CONFIG_MACH_MINI2440) := friendlyarm-mini2440
board-$(CONFIG_MACH_QIL_A9260) := qil-a9260
board-$(CONFIG_MACH_TNY_A9260) := tny-a926x
board-$(CONFIG_MACH_TNY_A9263) := tny-a926x
@@ -137,7 +137,7 @@ board-$(CONFIG_MACH_TX51) := karo-tx51
board-$(CONFIG_MACH_MX6Q_ARM2) := freescale-mx6-arm2
board-$(CONFIG_MACH_TOSHIBA_AC100) := toshiba-ac100
board-$(CONFIG_MACH_CCMX51) := ccxmx51
-board-$(CONFIG_MACH_TINY210) := tiny210
+board-$(CONFIG_MACH_TINY210) := friendlyarm-tiny210
machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
diff --git a/arch/arm/boards/mini2440/Kconfig b/arch/arm/boards/friendlyarm-mini2440/Kconfig
similarity index 100%
rename from arch/arm/boards/mini2440/Kconfig
rename to arch/arm/boards/friendlyarm-mini2440/Kconfig
diff --git a/arch/arm/boards/mini2440/Makefile b/arch/arm/boards/friendlyarm-mini2440/Makefile
similarity index 100%
rename from arch/arm/boards/mini2440/Makefile
rename to arch/arm/boards/friendlyarm-mini2440/Makefile
diff --git a/arch/arm/boards/mini2440/config.h b/arch/arm/boards/friendlyarm-mini2440/config.h
similarity index 100%
rename from arch/arm/boards/mini2440/config.h
rename to arch/arm/boards/friendlyarm-mini2440/config.h
diff --git a/arch/arm/boards/mini2440/env/config b/arch/arm/boards/friendlyarm-mini2440/env/config
similarity index 100%
rename from arch/arm/boards/mini2440/env/config
rename to arch/arm/boards/friendlyarm-mini2440/env/config
diff --git a/arch/arm/boards/mini2440/lowlevel_init.S b/arch/arm/boards/friendlyarm-mini2440/lowlevel_init.S
similarity index 100%
rename from arch/arm/boards/mini2440/lowlevel_init.S
rename to arch/arm/boards/friendlyarm-mini2440/lowlevel_init.S
diff --git a/arch/arm/boards/mini2440/mini2440.c b/arch/arm/boards/friendlyarm-mini2440/mini2440.c
similarity index 100%
rename from arch/arm/boards/mini2440/mini2440.c
rename to arch/arm/boards/friendlyarm-mini2440/mini2440.c
diff --git a/arch/arm/boards/tiny210/Makefile b/arch/arm/boards/friendlyarm-tiny210/Makefile
similarity index 100%
rename from arch/arm/boards/tiny210/Makefile
rename to arch/arm/boards/friendlyarm-tiny210/Makefile
diff --git a/arch/arm/boards/tiny210/config.h b/arch/arm/boards/friendlyarm-tiny210/config.h
similarity index 100%
rename from arch/arm/boards/tiny210/config.h
rename to arch/arm/boards/friendlyarm-tiny210/config.h
diff --git a/arch/arm/boards/tiny210/lowlevel.c b/arch/arm/boards/friendlyarm-tiny210/lowlevel.c
similarity index 100%
rename from arch/arm/boards/tiny210/lowlevel.c
rename to arch/arm/boards/friendlyarm-tiny210/lowlevel.c
diff --git a/arch/arm/boards/tiny210/tiny210.c b/arch/arm/boards/friendlyarm-tiny210/tiny210.c
similarity index 100%
rename from arch/arm/boards/tiny210/tiny210.c
rename to arch/arm/boards/friendlyarm-tiny210/tiny210.c
diff --git a/arch/arm/configs/mini2440_defconfig b/arch/arm/configs/friendlyarm_mini2440_defconfig
similarity index 92%
rename from arch/arm/configs/mini2440_defconfig
rename to arch/arm/configs/friendlyarm_mini2440_defconfig
index efe76e4..5551ffe 100644
--- a/arch/arm/configs/mini2440_defconfig
+++ b/arch/arm/configs/friendlyarm_mini2440_defconfig
@@ -12,7 +12,7 @@ CONFIG_GLOB=y
CONFIG_CMDLINE_EDITING=y
CONFIG_AUTO_COMPLETE=y
CONFIG_DEFAULT_ENVIRONMENT_GENERIC=y
-CONFIG_DEFAULT_ENVIRONMENT_PATH="arch/arm/boards/mini2440/env"
+CONFIG_DEFAULT_ENVIRONMENT_PATH="arch/arm/boards/friendlyarm-mini2440/env"
CONFIG_DEBUG_INFO=y
CONFIG_CMD_EDIT=y
CONFIG_CMD_SLEEP=y
diff --git a/arch/arm/configs/tiny210_defconfig b/arch/arm/configs/friendlyarm_tiny210_defconfig
similarity index 100%
rename from arch/arm/configs/tiny210_defconfig
rename to arch/arm/configs/friendlyarm_tiny210_defconfig
diff --git a/arch/arm/mach-samsung/Kconfig b/arch/arm/mach-samsung/Kconfig
index 90cda30..b28cf1f 100644
--- a/arch/arm/mach-samsung/Kconfig
+++ b/arch/arm/mach-samsung/Kconfig
@@ -80,7 +80,7 @@ config MACH_A9M2410DEV
endchoice
-source arch/arm/boards/mini2440/Kconfig
+source arch/arm/boards/friendlyarm-mini2440/Kconfig
endmenu
--
1.7.10.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH] ARM: add the vendor 'FriendlyARM' to its board's directory names
From: Juergen Beisert @ 2012-07-19 20:08 UTC (permalink / raw)
To: barebox
Since a look into "arch/arm/boards/" offers various boards starting with the
vendor's name in their directory name (like 'eukrea' and 'freescale').
This patch does the same with the currently existing FriendlyARM boards
Mini2440 and Tiny210.
Note: I hope I have used the '-M' parameter in a correct manner ;)
Juergen
The following changes since commit a7953f6e56b1e7e4b6973bf44b016169886f5430:
Merge branch 'for-next/reset-source' into next (2012-07-18 16:21:48 +0200)
are available in the git repository at:
git://git.pengutronix.de/git/jbe/barebox.git next_rename_fa_boardsV1
for you to fetch changes up to 7061e9e4337e70972923c3b967494ffb7fe20f5e:
ARM/Samsung: add the vendor FriendlyARM to the board's directory name (2012-07-19 21:52:12 +0200)
----------------------------------------------------------------
Juergen Beisert (1):
ARM/Samsung: add the vendor FriendlyARM to the board's directory name
arch/arm/Makefile | 4 ++--
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Kconfig | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Makefile | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/config.h | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/env/config | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/lowlevel_init.S | 0
arch/arm/boards/{mini2440 => friendlyarm-mini2440}/mini2440.c | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/Makefile | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/config.h | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/lowlevel.c | 0
arch/arm/boards/{tiny210 => friendlyarm-tiny210}/tiny210.c | 0
.../configs/{mini2440_defconfig => friendlyarm_mini2440_defconfig} | 2 +-
.../configs/{tiny210_defconfig => friendlyarm_tiny210_defconfig} | 0
arch/arm/mach-samsung/Kconfig | 2 +-
14 files changed, 4 insertions(+), 4 deletions(-)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Kconfig (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/Makefile (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/config.h (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/env/config (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/lowlevel_init.S (100%)
rename arch/arm/boards/{mini2440 => friendlyarm-mini2440}/mini2440.c (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/Makefile (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/config.h (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/lowlevel.c (100%)
rename arch/arm/boards/{tiny210 => friendlyarm-tiny210}/tiny210.c (100%)
rename arch/arm/configs/{mini2440_defconfig => friendlyarm_mini2440_defconfig} (92%)
rename arch/arm/configs/{tiny210_defconfig => friendlyarm_tiny210_defconfig} (100%)
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* [PATCH 6/6] PCM038: Read UID from fuses and pass this value to kernel as serial number
From: Alexander Shiyan @ 2012-07-19 18:49 UTC (permalink / raw)
To: barebox
In-Reply-To: <20120719181252.GF30009@pengutronix.de>
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/pcm038/pcm038.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index 5b0afc3..1bdb93c 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -40,6 +40,7 @@
#include <mach/spi.h>
#include <mach/iomux-mx27.h>
#include <mach/devices-imx27.h>
+#include <mach/iim.h>
#include <mfd/mc13xxx.h>
#include "pll.h"
@@ -193,6 +194,7 @@ mem_initcall(pcm038_mem_init);
static int pcm038_devices_init(void)
{
int i;
+ u64 uid = 0;
char *envdev;
unsigned int mode[] = {
@@ -316,6 +318,8 @@ static int pcm038_devices_init(void)
printf("Using environment in %s Flash\n", envdev);
+ if (imx_iim_read(1, 1, &uid, 6) == 6)
+ armlinux_set_serial(uid);
armlinux_set_bootparams((void *)0xa0000100);
armlinux_set_architecture(MACH_TYPE_PCM038);
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* Re[2]: [PATCH 6/6] PCM038: Read UID from fuses and pass this value to kernel as serial number
From: Alexander Shiyan @ 2012-07-19 18:48 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <20120719181252.GF30009@pengutronix.de>
Hello.
Thu, 19 Jul 2012 20:12:52 +0200 от Sascha Hauer <s.hauer@pengutronix.de>:
> On Thu, Jul 19, 2012 at 07:30:17PM +0400, Alexander Shiyan wrote:
> >
> > Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
> > ---
> > arch/arm/boards/pcm038/pcm038.c | 4 ++++
> > 1 files changed, 4 insertions(+), 0 deletions(-)
> >
> > diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
> > index 5b0afc3..1bdb93c 100644
> > --- a/arch/arm/boards/pcm038/pcm038.c
> > +++ b/arch/arm/boards/pcm038/pcm038.c
> > @@ -40,6 +40,7 @@
> > #include <mach/spi.h>
> > #include <mach/iomux-mx27.h>
> > #include <mach/devices-imx27.h>
> > +#include <mach/iim.h>
> > #include <mfd/mc13xxx.h>
> >
> > #include "pll.h"
> > @@ -193,6 +194,7 @@ mem_initcall(pcm038_mem_init);
> > static int pcm038_devices_init(void)
> > {
> > int i;
> > + u64 uid;
>
> The upper two bytes of uid are used unitialized.
You are right. I'll send updated version for this one patch.
> > char *envdev;
> >
> > unsigned int mode[] = {
> > @@ -316,6 +318,8 @@ static int pcm038_devices_init(void)
> >
> > printf("Using environment in %s Flash\n", envdev);
> >
> > + if (imx_iim_read(1, 1, &uid, 6) == 6)
> > + armlinux_set_serial(uid);
>
> With this patch I just realized that my serial becomes:
>
> -6345008925011607552
>
> Having negative numbers here is a bit odd. Looking at it export_env_ull
> does:
>
> char *valstr = asprintf("%lld", val);
>
> Which clearly is a signed number. Maybe this should be changed to "0x%016llx"
> (which of course is not your fault)
I think this will solve the problem. But it's certainly a job for another patch.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* Re: [PATCH 9/9] Add compressed image support
From: Johannes Stezenbach @ 2012-07-19 18:32 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <20120719174125.GC30009@pengutronix.de>
On Thu, Jul 19, 2012 at 07:41:25PM +0200, Sascha Hauer wrote:
> On Thu, Jul 19, 2012 at 07:08:45PM +0200, Johannes Stezenbach wrote:
> > On Thu, Jul 19, 2012 at 10:13:02AM +0200, Sascha Hauer wrote:
> > > --- a/Makefile
> > > +++ b/Makefile
> > ...
> > > +ifdef CONFIG_IMAGE_COMPRESSION_LZO
> > > +barebox: piggy.lzo.o
> > > + @echo " LD " $@
> > > + $(Q)$(LD) $(LDFLAGS) $(LDFLAGS_barebox) -o $@ \
> > > + -T $(barebox-compressed-lds) $(barebox-compressed) \
> > > + --start-group $(barebox-common) piggy.lzo.o --end-group
> > > +else
> >
> > Where is barebox-compressed set?
> >
> > I tried it and it fails to link:
> >
> > LD arch/arm/lib/built-in.o
> > LD barebox-uncompressed
> > SYSMAP System.map
> > OBJCOPY barebox-uncompressed.bin
> > LZO barebox-uncompressed.bin.lzo
> > CC piggy.lzo.o
> > LD barebox
> > common/built-in.o: In function `start_barebox':
> > .../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_start'
> > .../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_end'
> >
> > $ make V=1
> > ...
> > LD barebox
> > arm-linux-ld -EL -Map barebox.map -static --gc-sections -o barebox \
> > -T arch/arm/lib/barebox-compressed.lds \
> > --start-group common/built-in.o drivers/built-in.o commands/built-in.o lib/built-in.o crypto/built-in.o net/built-in.o fs/built-in.o arch/arm/boards/foo/built-in.o arch/arm/mach-foo/built-in.o arch/arm/lib/built-in.o arch/arm/cpu/built-in.o piggy.lzo.o --end-group
> >
> >
> > It shouldn't link all the -built-in.o into the uncompressor, should it?
> > Or is it supposed to work via --gc-sections trick?
>
> Yes, it works using --gc-sections. Are you building a defconfig or a
> custom one? If the error above is correct start_barebox is referenced
> from the decompressor code. This should not happen.
I'm building a custom one (unpublished code). It has some SPI flash
boot assembly code, I guess that might cause the issue wrt the new section
annotations. I'll look at it tomorrow. However, I still wonder
about the empty $(barebox-compressed)?
Thanks
Johannes
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* Re: [PATCH 6/6] PCM038: Read UID from fuses and pass this value to kernel as serial number
From: Sascha Hauer @ 2012-07-19 18:12 UTC (permalink / raw)
To: Alexander Shiyan; +Cc: barebox
In-Reply-To: <1342711817-866-6-git-send-email-shc_work@mail.ru>
On Thu, Jul 19, 2012 at 07:30:17PM +0400, Alexander Shiyan wrote:
>
> Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
> ---
> arch/arm/boards/pcm038/pcm038.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
> index 5b0afc3..1bdb93c 100644
> --- a/arch/arm/boards/pcm038/pcm038.c
> +++ b/arch/arm/boards/pcm038/pcm038.c
> @@ -40,6 +40,7 @@
> #include <mach/spi.h>
> #include <mach/iomux-mx27.h>
> #include <mach/devices-imx27.h>
> +#include <mach/iim.h>
> #include <mfd/mc13xxx.h>
>
> #include "pll.h"
> @@ -193,6 +194,7 @@ mem_initcall(pcm038_mem_init);
> static int pcm038_devices_init(void)
> {
> int i;
> + u64 uid;
The upper two bytes of uid are used unitialized.
> char *envdev;
>
> unsigned int mode[] = {
> @@ -316,6 +318,8 @@ static int pcm038_devices_init(void)
>
> printf("Using environment in %s Flash\n", envdev);
>
> + if (imx_iim_read(1, 1, &uid, 6) == 6)
> + armlinux_set_serial(uid);
With this patch I just realized that my serial becomes:
-6345008925011607552
Having negative numbers here is a bit odd. Looking at it export_env_ull
does:
char *valstr = asprintf("%lld", val);
Which clearly is a signed number. Maybe this should be changed to "0x%016llx"
(which of course is not your fault)
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
* Re: [PATCH] pca-a-l1: added memory device for int. 60kB RAM.
From: Jürgen Kilb @ 2012-07-19 18:04 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <20120719131024.GX30009@pengutronix.de>
Hi Sascha,
On 19.07.2012 15:10, Sascha Hauer wrote:
> Hi Jürgen,
>
> On Wed, Jul 18, 2012 at 02:58:46PM +0200, Juergen Kilb wrote:
>> Signed-off-by: Juergen Kilb <J.Kilb@phytec.de>
>> ---
>> arch/arm/boards/phycard-a-l1/pca-a-l1.c | 2 ++
>> arch/arm/mach-omap/include/mach/omap3-silicon.h | 1 +
>> 2 files changed, 3 insertions(+), 0 deletions(-)
>>
>> diff --git a/arch/arm/boards/phycard-a-l1/pca-a-l1.c b/arch/arm/boards/phycard-a-l1/pca-a-l1.c
>> index 1cc2815..8fae405 100644
>> --- a/arch/arm/boards/phycard-a-l1/pca-a-l1.c
>> +++ b/arch/arm/boards/phycard-a-l1/pca-a-l1.c
>> @@ -292,6 +292,8 @@ static int pcaal1_mem_init(void)
>> */
>> gpmc_generic_init(0x10);
>> #endif
>> + add_mem_device("sram0", OMAP_SRAM_BASE, 60 * SZ_1K,
>> + IORESOURCE_MEM_WRITEABLE);
> Isn't this 64K? Or does the ROM code store stuff in the upper 4k which
> you want to preserve?
Yes it is a 64K memory range but it is splitted into 5 regions and they are
used during the booting process.
0x4020_0000 - 0x4020_EFFF => Used for storing a downloaded booting image
0x4020_F000 - 0x4020_FCAF => Public Stack (reserved for stacks)
0x4020_FCB0 - 0x4020_FFC7 => Tracing Data
0x4020_FFC8 - 0x4020_FFFF => RAM exception Vectors
We can increase the size to 0xFCB0 but I think it's better to use only 60K.
At least the tracing vectors should be preserved.
> Sascha
>
Jürgen
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* Re: [PATCH 3/6] mc13xxx: Added dummy definition for mc13xxx_get() if CONFIG_MFD_MC13XXX is not set
From: Sascha Hauer @ 2012-07-19 17:56 UTC (permalink / raw)
To: Alexander Shiyan; +Cc: barebox
In-Reply-To: <1342711817-866-3-git-send-email-shc_work@mail.ru>
On Thu, Jul 19, 2012 at 07:30:14PM +0400, Alexander Shiyan wrote:
>
> Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
> ---
> arch/arm/boards/pcm038/pcm038.c | 2 --
> include/mfd/mc13xxx.h | 4 ++++
> 2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
> index fa82b02..875081b 100644
> --- a/arch/arm/boards/pcm038/pcm038.c
> +++ b/arch/arm/boards/pcm038/pcm038.c
> @@ -124,7 +124,6 @@ static inline uint32_t get_pll_spctl10(void)
> */
> static int pcm038_power_init(void)
> {
> -#ifdef CONFIG_MFD_MC13XXX
> uint32_t spctl0 = get_pll_spctl10();
> struct mc13xxx *mc13xxx = mc13xxx_get();
>
> @@ -158,7 +157,6 @@ static int pcm038_power_init(void)
> printf("Failed to initialize PMIC. Will continue with low CPU speed\n");
> }
> }
> -#endif
>
> /* clock gating enable */
> GPCR = 0x00050f08;
> diff --git a/include/mfd/mc13xxx.h b/include/mfd/mc13xxx.h
> index 2880307..51cfdd9 100644
> --- a/include/mfd/mc13xxx.h
> +++ b/include/mfd/mc13xxx.h
> @@ -163,7 +163,11 @@ struct mc13xxx {
> int revision;
> };
>
> +#ifdef CONFIG_MFD_MC13XXX
> extern struct mc13xxx *mc13xxx_get(void);
> +#else
> +#define mc13xxx_get() (NULL)
Better a static inline function.
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
* Re: [PATCH 1/6] mc13xxx: Define maximum SPI clock frequency global to driver
From: Sascha Hauer @ 2012-07-19 17:55 UTC (permalink / raw)
To: Alexander Shiyan; +Cc: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
On Thu, Jul 19, 2012 at 07:30:12PM +0400, Alexander Shiyan wrote:
> This patch provide setup for SPI clk frequency global to driver.
> For MC13783 maximum clock frequency is 20 MHz,
> for MC13892 maximum clock frequency is 26 MHz,
> so we define 20 MHz as a maximum SPI clk.
>
> Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
> ---
> arch/arm/boards/ccxmx51/ccxmx51.c | 1 -
> arch/arm/boards/freescale-mx51-pdk/board.c | 1 -
> arch/arm/boards/pcm038/pcm038.c | 1 -
> drivers/mfd/mc13xxx.c | 1 +
> 4 files changed, 1 insertions(+), 3 deletions(-)
>
> diff --git a/arch/arm/boards/ccxmx51/ccxmx51.c b/arch/arm/boards/ccxmx51/ccxmx51.c
> index f494174..f309e0c 100644
> --- a/arch/arm/boards/ccxmx51/ccxmx51.c
> +++ b/arch/arm/boards/ccxmx51/ccxmx51.c
> @@ -191,7 +191,6 @@ static struct spi_imx_master ecspi_0_data = {
> static const struct spi_board_info ccxmx51_spi_board_info[] = {
> {
> .name = "mc13xxx-spi",
> - .max_speed_hz = 6000000,
> .bus_num = 0,
> .chip_select = 0,
> },
> diff --git a/arch/arm/boards/freescale-mx51-pdk/board.c b/arch/arm/boards/freescale-mx51-pdk/board.c
> index 3a568d0..7c2c8fe 100644
> --- a/arch/arm/boards/freescale-mx51-pdk/board.c
> +++ b/arch/arm/boards/freescale-mx51-pdk/board.c
> @@ -117,7 +117,6 @@ static struct spi_imx_master spi_0_data = {
> static const struct spi_board_info mx51_babbage_spi_board_info[] = {
> {
> .name = "mc13xxx-spi",
> - .max_speed_hz = 300000,
> .bus_num = 0,
> .chip_select = 0,
> },
> diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
> index badc978..fa82b02 100644
> --- a/arch/arm/boards/pcm038/pcm038.c
> +++ b/arch/arm/boards/pcm038/pcm038.c
> @@ -59,7 +59,6 @@ static struct spi_imx_master pcm038_spi_0_data = {
> static struct spi_board_info pcm038_spi_board_info[] = {
> {
> .name = "mc13xxx-spi",
> - .max_speed_hz = 3000000,
> .bus_num = 0,
> .chip_select = 0,
> }
> diff --git a/drivers/mfd/mc13xxx.c b/drivers/mfd/mc13xxx.c
> index 2934e9d..8bb0d00 100644
> --- a/drivers/mfd/mc13xxx.c
> +++ b/drivers/mfd/mc13xxx.c
> @@ -297,6 +297,7 @@ static int mc_probe(struct device_d *dev, enum mc13xxx_mode mode)
> mc_dev->spi = dev->type_data;
> mc_dev->spi->mode = SPI_MODE_0 | SPI_CS_HIGH;
> mc_dev->spi->bits_per_word = 32;
> + mc_dev->spi->max_speed_hz = 20000000;
The values indeed look quite arbitrary, but it may be that a hardware
design does not support such high frequencies. Maybe better
if (!mc_dev->spi->max_speed_hz)
mc_dev->spi->max_speed_hz = 20000000
?
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
* Re: [PATCH 9/9] Add compressed image support
From: Sascha Hauer @ 2012-07-19 17:41 UTC (permalink / raw)
To: Johannes Stezenbach; +Cc: barebox
In-Reply-To: <20120719170845.GA3303@sig21.net>
On Thu, Jul 19, 2012 at 07:08:45PM +0200, Johannes Stezenbach wrote:
> Hi,
>
> On Thu, Jul 19, 2012 at 10:13:02AM +0200, Sascha Hauer wrote:
> > --- a/Makefile
> > +++ b/Makefile
> ...
> > +ifdef CONFIG_IMAGE_COMPRESSION_LZO
> > +barebox: piggy.lzo.o
> > + @echo " LD " $@
> > + $(Q)$(LD) $(LDFLAGS) $(LDFLAGS_barebox) -o $@ \
> > + -T $(barebox-compressed-lds) $(barebox-compressed) \
> > + --start-group $(barebox-common) piggy.lzo.o --end-group
> > +else
>
> Where is barebox-compressed set?
>
> I tried it and it fails to link:
>
> LD arch/arm/lib/built-in.o
> LD barebox-uncompressed
> SYSMAP System.map
> OBJCOPY barebox-uncompressed.bin
> LZO barebox-uncompressed.bin.lzo
> CC piggy.lzo.o
> LD barebox
> common/built-in.o: In function `start_barebox':
> .../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_start'
> .../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_end'
>
> $ make V=1
> ...
> LD barebox
> arm-linux-ld -EL -Map barebox.map -static --gc-sections -o barebox \
> -T arch/arm/lib/barebox-compressed.lds \
> --start-group common/built-in.o drivers/built-in.o commands/built-in.o lib/built-in.o crypto/built-in.o net/built-in.o fs/built-in.o arch/arm/boards/foo/built-in.o arch/arm/mach-foo/built-in.o arch/arm/lib/built-in.o arch/arm/cpu/built-in.o piggy.lzo.o --end-group
>
>
> It shouldn't link all the -built-in.o into the uncompressor, should it?
> Or is it supposed to work via --gc-sections trick?
Yes, it works using --gc-sections. Are you building a defconfig or a
custom one? If the error above is correct start_barebox is referenced
from the decompressor code. This should not happen.
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
* Re: [PATCH 9/9] Add compressed image support
From: Johannes Stezenbach @ 2012-07-19 17:08 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <1342685582-13244-10-git-send-email-s.hauer@pengutronix.de>
Hi,
On Thu, Jul 19, 2012 at 10:13:02AM +0200, Sascha Hauer wrote:
> --- a/Makefile
> +++ b/Makefile
...
> +ifdef CONFIG_IMAGE_COMPRESSION_LZO
> +barebox: piggy.lzo.o
> + @echo " LD " $@
> + $(Q)$(LD) $(LDFLAGS) $(LDFLAGS_barebox) -o $@ \
> + -T $(barebox-compressed-lds) $(barebox-compressed) \
> + --start-group $(barebox-common) piggy.lzo.o --end-group
> +else
Where is barebox-compressed set?
I tried it and it fails to link:
LD arch/arm/lib/built-in.o
LD barebox-uncompressed
SYSMAP System.map
OBJCOPY barebox-uncompressed.bin
LZO barebox-uncompressed.bin.lzo
CC piggy.lzo.o
LD barebox
common/built-in.o: In function `start_barebox':
.../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_start'
.../barebox/common/startup.c:154: undefined reference to `__barebox_initcalls_end'
$ make V=1
...
LD barebox
arm-linux-ld -EL -Map barebox.map -static --gc-sections -o barebox \
-T arch/arm/lib/barebox-compressed.lds \
--start-group common/built-in.o drivers/built-in.o commands/built-in.o lib/built-in.o crypto/built-in.o net/built-in.o fs/built-in.o arch/arm/boards/foo/built-in.o arch/arm/mach-foo/built-in.o arch/arm/lib/built-in.o arch/arm/cpu/built-in.o piggy.lzo.o --end-group
It shouldn't link all the -built-in.o into the uncompressor, should it?
Or is it supposed to work via --gc-sections trick?
Thanks,
Johannes
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* Re: USB On PCM043?
From: Sascha Hauer @ 2012-07-19 16:11 UTC (permalink / raw)
To: Jerry Kirk; +Cc: barebox
In-Reply-To: <loom.20120719T173418-826@post.gmane.org>
On Thu, Jul 19, 2012 at 03:37:47PM +0000, Jerry Kirk wrote:
> We have been attempting to get USB Host mode working under Barebox(2012-07-0) on
> a PCM043 platform (i.mx35), but we are having a bit of trouble.
>
> We have merged the CONFIG_USB specific code for "imx35_devices_init" and
> "imx35_usb_init" from the Eukrea platform into pcm043.c, added the
> "MX35_PAD_I2C2_CLK__USB_TOP_USBH2_PWR" and "MX35_PAD_I2C2_DAT__USB_TOP_USBH2_OC"
> pad definitions (as per the main kernel pcm043.c file), added the "tmp |= 0x3 <<
> CCM_CGR2_USB_SHIFT" to enable the USB clock to "pcm043_core_setup", built
> everything with the "usb" command enabled, and then loaded the new Barebox image
> into our pcm043 board. We have USB_EHCI and USB_STORAGE enabled in the Barebox
> config.
>
> If I execute the "usb" command then it returns that it has found 1 EHCI
> controller. If I plug in any device, the only one it has EVER detected has been
> a USB mouse. It will be detected most of the time following a reset and after
> unplugging/replugging the mouse -- but will never be detected again after this
> unless I do a reset/replug operation (and never on a "usb -f" forced redetect).
>
> Basically, our goal is to get USB flash drives working for use as a means of
> upgrading our Linux kernel in the field -- but right now it won't even EVER
> recognize a USB flash drive when it is plugged into the unit. We also know it is
> not a hardware problem as all USB devices work just fine once the full kernel
> finishes booting.
>
> From what we have read, it looks like the Eukrea platform had USB working in it,
> and we have attempted to use it as a guide, but we still aren't having any luck.
>
> Does anyone know of any steps we might be missing? Or of anyone who has gotten
> USB host mode working on a pcm043 under Barebox before?
>
> I think we are close, but something (obviously) still isn't right.
Could it be that the USB clock operates at the wrong rate? I think it
should be 60MHz.
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
* Re: Compressed barebox image support
From: Sascha Hauer @ 2012-07-19 16:05 UTC (permalink / raw)
To: Jean-Christophe PLAGNIOL-VILLARD; +Cc: barebox
In-Reply-To: <20120719150832.GG22657@game.jcrosoft.org>
On Thu, Jul 19, 2012 at 05:08:32PM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 10:12 Thu 19 Jul , Sascha Hauer wrote:
> > The following series allows to create a self extracting barebox image.
> > This is done by linking barebox twice, once for the actual binary, but
> > without lowlevel initstuff and once for the lowlevel init stuff, the
> > decompressor and the compressed image.
> >
> > Using lzo compression the pcm038 image shrinks from 252k to 155k. The
> > series has been tested on the pcm038 second stage, first stage NAND and
> > first stage NOR and also on an i.MX53 LOCO board (also in thumb2 mode)
> >
> > Using compressed images currently adds to the boot time, at least on
> > my slower arm9 systems. Using the MMU during decompression would help,
> > but this currently isn't implemented.
> >
> > I think the preparation patches should be ready for merging. The last
> > patch in this series adding compression support I am not that confident
> > with. Currently I am not very happy with the Makefile changes which
> > somehow look like bypassing the kbuild mechanism and handcrufting
> > something that looks like kbuild. If someone has ideas how to improve
> > this, let me know. Nevertheless I would be happy about Tested-by
> > (and does-not-work-for) tags.
> >
> > Sascha
> >
> > ----------------------------------------------------------------
> > Sascha Hauer (9):
> > lzo: Allow for static inlining
> > ARM lds: remove unused got
> > ARM: remove board linker script option
> > ARM: remove exception vectors from boards
> > ARM startup: calculate offset instead of runtime address
> > ARM ep93xx: Get rid of special handling in linker file
> > ARM boards: Use _text rather than TEXT_BASE
> > ARM: Separate assembler functions into their own section
> > Add compressed image support
>
> can you push it on a git?
Here you are. I partly integrated your comments already.
Sascha
The following changes since commit 2f6b1f7690640f571f8e72fc2f2564acb2e13778:
ARM/MXS: the GPIO bitkeeper enable logic is inverse to the pullup enable logic (2012-07-16 23:30:14 +0200)
are available in the git repository at:
git://git.pengutronix.de/git/barebox.git work/compressed-image
for you to fetch changes up to af1de0f86036ab8cb8f4a434708a31db21b33de2:
Add compressed image support (2012-07-19 18:02:02 +0200)
----------------------------------------------------------------
Sascha Hauer (9):
lzo: Allow for static inlining
ARM lds: remove unused got
ARM: remove board linker script option
ARM: remove exception vectors from boards
ARM startup: calculate offset instead of runtime address
ARM ep93xx: Get rid of special handling in linker file
ARM boards: Use _text rather than TEXT_BASE
ARM: Separate assembler functions into their own section
Add compressed image support
Makefile | 31 ++++++-
arch/arm/Kconfig | 13 +--
arch/arm/Makefile | 4 +-
arch/arm/boards/a9m2410/a9m2410.c | 3 +-
arch/arm/boards/a9m2440/a9m2440.c | 3 +-
arch/arm/boards/eukrea_cpuimx25/eukrea_cpuimx25.c | 7 +-
arch/arm/boards/eukrea_cpuimx25/lowlevel.c | 4 +-
arch/arm/boards/eukrea_cpuimx27/eukrea_cpuimx27.c | 4 +-
arch/arm/boards/eukrea_cpuimx27/lowlevel_init.S | 11 +--
arch/arm/boards/eukrea_cpuimx35/flash_header.c | 2 -
arch/arm/boards/eukrea_cpuimx35/lowlevel.c | 4 +-
arch/arm/boards/freescale-mx25-3-stack/3stack.c | 8 +-
.../boards/freescale-mx25-3-stack/lowlevel_init.S | 11 +--
arch/arm/boards/freescale-mx35-3-stack/3stack.c | 4 +-
.../boards/freescale-mx35-3-stack/flash_header.c | 4 +-
.../boards/freescale-mx35-3-stack/lowlevel_init.S | 11 +--
arch/arm/boards/freescale-mx53-loco/flash_header.c | 2 +-
arch/arm/boards/freescale-mx53-smd/flash_header.c | 2 +-
arch/arm/boards/freescale-mx6-arm2/flash_header.c | 5 +-
arch/arm/boards/guf-cupid/lowlevel.c | 4 +-
arch/arm/boards/guf-neso/lowlevel.c | 4 +-
arch/arm/boards/imx21ads/imx21ads.c | 4 +-
arch/arm/boards/imx21ads/lowlevel_init.S | 10 +--
arch/arm/boards/karo-tx25/board.c | 3 +-
arch/arm/boards/karo-tx25/lowlevel.c | 4 +-
arch/arm/boards/karo-tx51/flash_header.c | 2 +-
arch/arm/boards/mini2440/mini2440.c | 3 +-
arch/arm/boards/pcm037/lowlevel_init.S | 7 +-
arch/arm/boards/pcm037/pcm037.c | 4 +-
arch/arm/boards/pcm038/lowlevel.c | 4 +-
arch/arm/boards/pcm043/lowlevel.c | 4 +-
arch/arm/boards/phycard-i.MX27/lowlevel_init.S | 8 +-
arch/arm/boards/phycard-i.MX27/pca100.c | 2 +-
arch/arm/boards/tqma53/flash_header.c | 5 +-
arch/arm/cpu/cache-armv4.S | 7 +-
arch/arm/cpu/cache-armv5.S | 7 +-
arch/arm/cpu/cache-armv6.S | 11 ++-
arch/arm/cpu/cache-armv7.S | 8 +-
arch/arm/cpu/start.c | 87 +++++++++++++++++---
arch/arm/lib/Makefile | 4 +-
arch/arm/lib/ashldi3.S | 1 +
arch/arm/lib/ashrdi3.S | 1 +
arch/arm/lib/barebox-compressed.lds.S | 70 ++++++++++++++++
arch/arm/lib/barebox.lds.S | 11 +--
arch/arm/lib/findbit.S | 9 ++
arch/arm/lib/io-writesw-armv4.S | 2 +
arch/arm/lib/lib1funcs.S | 7 ++
arch/arm/lib/lshrdi3.S | 1 +
arch/arm/mach-ep93xx/Makefile | 2 +-
arch/arm/mach-ep93xx/header.c | 8 ++
arch/arm/mach-ep93xx/include/mach/barebox.lds.h | 9 ++
common/Kconfig | 12 +++
include/asm-generic/barebox.lds.h | 3 +-
include/asm-generic/memory_layout.h | 2 +
include/lzo.h | 8 +-
lib/decompress_unlzo.c | 9 +-
lib/lzo/lzo1x_decompress.c | 2 +-
lib/vsprintf.c | 2 +-
piggy.lzo.S | 6 ++
59 files changed, 358 insertions(+), 132 deletions(-)
create mode 100644 arch/arm/lib/barebox-compressed.lds.S
create mode 100644 arch/arm/mach-ep93xx/header.c
create mode 100644 arch/arm/mach-ep93xx/include/mach/barebox.lds.h
create mode 100644 piggy.lzo.S
--
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
* USB On PCM043?
From: Jerry Kirk @ 2012-07-19 15:37 UTC (permalink / raw)
To: barebox
We have been attempting to get USB Host mode working under Barebox(2012-07-0) on
a PCM043 platform (i.mx35), but we are having a bit of trouble.
We have merged the CONFIG_USB specific code for "imx35_devices_init" and
"imx35_usb_init" from the Eukrea platform into pcm043.c, added the
"MX35_PAD_I2C2_CLK__USB_TOP_USBH2_PWR" and "MX35_PAD_I2C2_DAT__USB_TOP_USBH2_OC"
pad definitions (as per the main kernel pcm043.c file), added the "tmp |= 0x3 <<
CCM_CGR2_USB_SHIFT" to enable the USB clock to "pcm043_core_setup", built
everything with the "usb" command enabled, and then loaded the new Barebox image
into our pcm043 board. We have USB_EHCI and USB_STORAGE enabled in the Barebox
config.
If I execute the "usb" command then it returns that it has found 1 EHCI
controller. If I plug in any device, the only one it has EVER detected has been
a USB mouse. It will be detected most of the time following a reset and after
unplugging/replugging the mouse -- but will never be detected again after this
unless I do a reset/replug operation (and never on a "usb -f" forced redetect).
Basically, our goal is to get USB flash drives working for use as a means of
upgrading our Linux kernel in the field -- but right now it won't even EVER
recognize a USB flash drive when it is plugged into the unit. We also know it is
not a hardware problem as all USB devices work just fine once the full kernel
finishes booting.
From what we have read, it looks like the Eukrea platform had USB working in it,
and we have attempted to use it as a guide, but we still aren't having any luck.
Does anyone know of any steps we might be missing? Or of anyone who has gotten
USB host mode working on a pcm043 under Barebox before?
I think we are close, but something (obviously) still isn't right.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
* [PATCH 5/6] PCM970: Add MMC support
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
Here is a test output:
barebox 2012.07.0-00136-ge3ab4bc-dirty #23 Tue Jul 3 23:10:44 MSK 2012
Board: Phytec phyCORE-i.MX27
mc13xxx-spi@mc13xxx-spi0: Found MC13783 ID: 0x00009b [Rev: 3.1]
cfi_flash@cfi_flash0: found cfi flash at c0000000, size 33554432
NAND device: Manufacturer ID: 0x20, Chip ID: 0x36 (ST Micro NAND 64MiB 1,8V 8-bit)
Bad block table found at page 131040, version 0x01
Bad block table found at page 131008, version 0x01
imxfb@imxfb0: i.MX Framebuffer driver
cfi_protect: protect 0xc0080000 (size 1048576)
Using environment in NOR Flash
Found NXP ISP150x ULPI transceiver (0x04cc:0x1504).
ehci@ehci0: USB EHCI 1.00
imx-mmc@mci0: registered as mci0
Malloc space: 0xa6f00000 -> 0xa7efffff (size 16 MB)
Stack space : 0xa6ef8000 -> 0xa6f00000 (size 32 kB)
running /env/bin/init...
Hit m for menu or any other key to stop autoboot: 3
type exit to get to the menu
barebox@Phytec phyCORE-i.MX27:/ mci0.probe=1
mci@mci0: registered disk0
barebox@Phytec phyCORE-i.MX27:/ devinfo mci0
resources:
driver: mci
Card:
Attached is an SD Card (Version: 1.10)
Capacity: 1962 MiB
CID: 1C535653-44432020-1000013C-7E007200
CSD: 005E0032-5F5A83D5-2DB7FFBF-96800000
Max. transfer speed: 25000000 Hz
Manufacturer ID: 1C
OEM/Application ID: 5356
Product name: 'SDC '
Product revision: 1.0
Serial no: 81022
Manufacturing date: 2.2007
Parameters:
probe = 1
barebox@Phytec phyCORE-i.MX27:/ mkdir /d
barebox@Phytec phyCORE-i.MX27:/ mount /dev/disk0.0 fat /d
barebox@Phytec phyCORE-i.MX27:/ ls /d
barebox.bin
barebox@Phytec phyCORE-i.MX27:/
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/pcm038/pcm038.c | 16 ++++++++++++++++
arch/arm/boards/pcm038/pcm970.c | 24 ++++++++++++++++++++++++
2 files changed, 40 insertions(+), 0 deletions(-)
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index 875081b..5b0afc3 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -145,6 +145,22 @@ static int pcm038_power_init(void)
MC13783_SW1B_SOFTSTART |
MC13783_SW_PLL_FACTOR(32));
+ /* Setup VMMC voltage */
+ if (IS_ENABLED(CONFIG_MCI_IMX)) {
+ u32 val;
+
+ mc13xxx_reg_read(mc13xxx, MC13783_REG_REG_SETTING(1), &val);
+ /* VMMC1 = 3.00 V */
+ val &= ~(7 << 6);
+ val |= 6 << 6;
+ mc13xxx_reg_write(mc13xxx, MC13783_REG_REG_SETTING(1), val);
+
+ mc13xxx_reg_read(mc13xxx, MC13783_REG_REG_MODE(1), &val);
+ /* Enable VMMC1 */
+ val |= 1 << 18;
+ mc13xxx_reg_write(mc13xxx, MC13783_REG_REG_MODE(1), val);
+ }
+
/* wait for required power level to run the CPU at 400 MHz */
udelay(100000);
CSCR = CSCR_VAL_FINAL;
diff --git a/arch/arm/boards/pcm038/pcm970.c b/arch/arm/boards/pcm038/pcm970.c
index df9b852..b956482 100644
--- a/arch/arm/boards/pcm038/pcm970.c
+++ b/arch/arm/boards/pcm038/pcm970.c
@@ -23,6 +23,7 @@
#include <mach/imx-regs.h>
#include <mach/iomux-mx27.h>
#include <mach/gpio.h>
+#include <mach/devices-imx27.h>
#include <usb/ulpi.h>
#define GPIO_IDE_POWER (GPIO_PORTE + 18)
@@ -148,6 +149,26 @@ static void pcm970_ide_init(void)
}
#endif
+static void pcm970_mmc_init(void)
+{
+ uint32_t i;
+ unsigned int mode[] = {
+ /* SD2 */
+ PB4_PF_SD2_D0,
+ PB5_PF_SD2_D1,
+ PB6_PF_SD2_D2,
+ PB7_PF_SD2_D3,
+ PB8_PF_SD2_CMD,
+ PB9_PF_SD2_CLK,
+ };
+
+ for (i = 0; i < ARRAY_SIZE(mode); i++)
+ imx_gpio_mode(mode[i]);
+
+ PCCR0 |= PCCR0_SDHC2_EN;
+ imx27_add_mmc1(NULL);
+}
+
static int pcm970_init(void)
{
int i;
@@ -181,6 +202,9 @@ static int pcm970_init(void)
pcm970_ide_init();
#endif
+ if (IS_ENABLED(CONFIG_MCI_IMX))
+ pcm970_mmc_init();
+
return 0;
}
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH 4/6] tx51: Unused mc13xxx.h include removed
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/karo-tx51/tx51.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/arch/arm/boards/karo-tx51/tx51.c b/arch/arm/boards/karo-tx51/tx51.c
index 096683a..5adaaa6 100644
--- a/arch/arm/boards/karo-tx51/tx51.c
+++ b/arch/arm/boards/karo-tx51/tx51.c
@@ -32,7 +32,6 @@
#include <fcntl.h>
#include <nand.h>
#include <spi/spi.h>
-#include <mfd/mc13xxx.h>
#include <io.h>
#include <asm/mmu.h>
#include <mach/imx5.h>
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH 3/6] mc13xxx: Added dummy definition for mc13xxx_get() if CONFIG_MFD_MC13XXX is not set
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/pcm038/pcm038.c | 2 --
include/mfd/mc13xxx.h | 4 ++++
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index fa82b02..875081b 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -124,7 +124,6 @@ static inline uint32_t get_pll_spctl10(void)
*/
static int pcm038_power_init(void)
{
-#ifdef CONFIG_MFD_MC13XXX
uint32_t spctl0 = get_pll_spctl10();
struct mc13xxx *mc13xxx = mc13xxx_get();
@@ -158,7 +157,6 @@ static int pcm038_power_init(void)
printf("Failed to initialize PMIC. Will continue with low CPU speed\n");
}
}
-#endif
/* clock gating enable */
GPCR = 0x00050f08;
diff --git a/include/mfd/mc13xxx.h b/include/mfd/mc13xxx.h
index 2880307..51cfdd9 100644
--- a/include/mfd/mc13xxx.h
+++ b/include/mfd/mc13xxx.h
@@ -163,7 +163,11 @@ struct mc13xxx {
int revision;
};
+#ifdef CONFIG_MFD_MC13XXX
extern struct mc13xxx *mc13xxx_get(void);
+#else
+#define mc13xxx_get() (NULL)
+#endif
extern int mc13xxx_reg_read(struct mc13xxx *mc13xxx, u8 reg, u32 *val);
extern int mc13xxx_reg_write(struct mc13xxx *mc13xxx, u8 reg, u32 val);
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH 6/6] PCM038: Read UID from fuses and pass this value to kernel as serial number
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/pcm038/pcm038.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index 5b0afc3..1bdb93c 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -40,6 +40,7 @@
#include <mach/spi.h>
#include <mach/iomux-mx27.h>
#include <mach/devices-imx27.h>
+#include <mach/iim.h>
#include <mfd/mc13xxx.h>
#include "pll.h"
@@ -193,6 +194,7 @@ mem_initcall(pcm038_mem_init);
static int pcm038_devices_init(void)
{
int i;
+ u64 uid;
char *envdev;
unsigned int mode[] = {
@@ -316,6 +318,8 @@ static int pcm038_devices_init(void)
printf("Using environment in %s Flash\n", envdev);
+ if (imx_iim_read(1, 1, &uid, 6) == 6)
+ armlinux_set_serial(uid);
armlinux_set_bootparams((void *)0xa0000100);
armlinux_set_architecture(MACH_TYPE_PCM038);
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH 2/6] i.MX: Removed unused declaration for imx_iim_get_mac
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
In-Reply-To: <1342711817-866-1-git-send-email-shc_work@mail.ru>
Procedure is missing, so remove its declaration.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/mach-imx/include/mach/iim.h | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-imx/include/mach/iim.h b/arch/arm/mach-imx/include/mach/iim.h
index b97c742..ef7b25d 100644
--- a/arch/arm/mach-imx/include/mach/iim.h
+++ b/arch/arm/mach-imx/include/mach/iim.h
@@ -48,7 +48,6 @@ struct imx_iim_platform_data {
#ifdef CONFIG_IMX_IIM
int imx_iim_read(unsigned int bank, int offset, void *buf, int count);
-int imx_iim_get_mac(unsigned char *mac);
#else
static inline int imx_iim_read(unsigned int bank, int offset, void *buf,
int count)
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* [PATCH 1/6] mc13xxx: Define maximum SPI clock frequency global to driver
From: Alexander Shiyan @ 2012-07-19 15:30 UTC (permalink / raw)
To: barebox
This patch provide setup for SPI clk frequency global to driver.
For MC13783 maximum clock frequency is 20 MHz,
for MC13892 maximum clock frequency is 26 MHz,
so we define 20 MHz as a maximum SPI clk.
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
---
arch/arm/boards/ccxmx51/ccxmx51.c | 1 -
arch/arm/boards/freescale-mx51-pdk/board.c | 1 -
arch/arm/boards/pcm038/pcm038.c | 1 -
drivers/mfd/mc13xxx.c | 1 +
4 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/arch/arm/boards/ccxmx51/ccxmx51.c b/arch/arm/boards/ccxmx51/ccxmx51.c
index f494174..f309e0c 100644
--- a/arch/arm/boards/ccxmx51/ccxmx51.c
+++ b/arch/arm/boards/ccxmx51/ccxmx51.c
@@ -191,7 +191,6 @@ static struct spi_imx_master ecspi_0_data = {
static const struct spi_board_info ccxmx51_spi_board_info[] = {
{
.name = "mc13xxx-spi",
- .max_speed_hz = 6000000,
.bus_num = 0,
.chip_select = 0,
},
diff --git a/arch/arm/boards/freescale-mx51-pdk/board.c b/arch/arm/boards/freescale-mx51-pdk/board.c
index 3a568d0..7c2c8fe 100644
--- a/arch/arm/boards/freescale-mx51-pdk/board.c
+++ b/arch/arm/boards/freescale-mx51-pdk/board.c
@@ -117,7 +117,6 @@ static struct spi_imx_master spi_0_data = {
static const struct spi_board_info mx51_babbage_spi_board_info[] = {
{
.name = "mc13xxx-spi",
- .max_speed_hz = 300000,
.bus_num = 0,
.chip_select = 0,
},
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index badc978..fa82b02 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -59,7 +59,6 @@ static struct spi_imx_master pcm038_spi_0_data = {
static struct spi_board_info pcm038_spi_board_info[] = {
{
.name = "mc13xxx-spi",
- .max_speed_hz = 3000000,
.bus_num = 0,
.chip_select = 0,
}
diff --git a/drivers/mfd/mc13xxx.c b/drivers/mfd/mc13xxx.c
index 2934e9d..8bb0d00 100644
--- a/drivers/mfd/mc13xxx.c
+++ b/drivers/mfd/mc13xxx.c
@@ -297,6 +297,7 @@ static int mc_probe(struct device_d *dev, enum mc13xxx_mode mode)
mc_dev->spi = dev->type_data;
mc_dev->spi->mode = SPI_MODE_0 | SPI_CS_HIGH;
mc_dev->spi->bits_per_word = 32;
+ mc_dev->spi->max_speed_hz = 20000000;
}
mc_dev->cdev.size = 256;
mc_dev->cdev.dev = dev;
--
1.7.3.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply related
* Re: Compressed barebox image support
From: Jean-Christophe PLAGNIOL-VILLARD @ 2012-07-19 15:08 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
In-Reply-To: <1342685582-13244-1-git-send-email-s.hauer@pengutronix.de>
On 10:12 Thu 19 Jul , Sascha Hauer wrote:
> The following series allows to create a self extracting barebox image.
> This is done by linking barebox twice, once for the actual binary, but
> without lowlevel initstuff and once for the lowlevel init stuff, the
> decompressor and the compressed image.
>
> Using lzo compression the pcm038 image shrinks from 252k to 155k. The
> series has been tested on the pcm038 second stage, first stage NAND and
> first stage NOR and also on an i.MX53 LOCO board (also in thumb2 mode)
>
> Using compressed images currently adds to the boot time, at least on
> my slower arm9 systems. Using the MMU during decompression would help,
> but this currently isn't implemented.
>
> I think the preparation patches should be ready for merging. The last
> patch in this series adding compression support I am not that confident
> with. Currently I am not very happy with the Makefile changes which
> somehow look like bypassing the kbuild mechanism and handcrufting
> something that looks like kbuild. If someone has ideas how to improve
> this, let me know. Nevertheless I would be happy about Tested-by
> (and does-not-work-for) tags.
>
> Sascha
>
> ----------------------------------------------------------------
> Sascha Hauer (9):
> lzo: Allow for static inlining
> ARM lds: remove unused got
> ARM: remove board linker script option
> ARM: remove exception vectors from boards
> ARM startup: calculate offset instead of runtime address
> ARM ep93xx: Get rid of special handling in linker file
> ARM boards: Use _text rather than TEXT_BASE
> ARM: Separate assembler functions into their own section
> Add compressed image support
can you push it on a git?
Best Regards,
J.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox