Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-23 Thread Joakim Tjernlund
Mike Frysinger vap...@gentoo.org wrote on 2010/10/22 19:06:14: On Friday, October 22, 2010 12:40:07 Joakim Tjernlund wrote: Mike Frysinger wrote on 2010/10/22 17:18:05: On Friday, October 22, 2010 04:34:52 Joakim Tjernlund wrote: Don't you want to know if the app screwed up

Re: [U-Boot] [MPC83xx] broken patch do not fixup NULL ptrs ?

2010-10-23 Thread Joakim Tjernlund
André Schwarz andre.schw...@matrix-vision.de wrote on 2010/10/22 21:25:34: On Fri, 2010-10-22 at 16:56 +0200, Joakim Tjernlund wrote: André Schwarz andre.schw...@matrix-vision.de wrote on 2010/10/22 16:30:49: Joakim, your commit d1e0b10accdbac2e0a8b2cbf7c589645442f87c5 renders

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-23 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/22 19:36:33: On Fri, 22 Oct 2010 03:55:49 -0400 Mike Frysinger vap...@gentoo.org wrote: On Friday, October 22, 2010 03:37:43 Joakim Tjernlund wrote: Mike Frysinger wrote on 2010/10/22 09:20:22: On Friday, October 22, 2010 02:10:16

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-22 Thread Joakim Tjernlund
Mike Frysinger vap...@gentoo.org wrote on 2010/10/21 21:51:53: On Thursday, October 21, 2010 07:45:10 Joakim Tjernlund wrote: Wolfgang Denk wrote on 2010/10/21 13:32:54: Joakim Tjernlund you wrote: - if ((long)bytes 0) return 0; + if ((long)bytes = 0) return 0; I

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-22 Thread Joakim Tjernlund
Mike Frysinger vap...@gentoo.org wrote on 2010/10/22 09:20:22: On Friday, October 22, 2010 02:10:16 Joakim Tjernlund wrote: Mike Frysinger wrote on 2010/10/21 21:51:53: it is useful for malloc(0) == NULL. the glibc behavior is downright obnoxious. we disable this for uClibc and dont

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-22 Thread Joakim Tjernlund
Reinhard Meyer u-b...@emk-elektronik.de wrote on 2010/10/22 09:18:02: Dear Joakim Tjernlund, Mike Frysinger vap...@gentoo.org wrote on 2010/10/21 21:51:53: On Thursday, October 21, 2010 07:45:10 Joakim Tjernlund wrote: Wolfgang Denk wrote on 2010/10/21 13:32:54: Joakim Tjernlund you

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-22 Thread Joakim Tjernlund
Mike Frysinger vap...@gentoo.org wrote on 2010/10/22 09:55:49: On Friday, October 22, 2010 03:37:43 Joakim Tjernlund wrote: Mike Frysinger wrote on 2010/10/22 09:20:22: On Friday, October 22, 2010 02:10:16 Joakim Tjernlund wrote: does not set errno which screws error handling. One have

Re: [U-Boot] [MPC83xx] broken patch do not fixup NULL ptrs ?

2010-10-22 Thread Joakim Tjernlund
André Schwarz andre.schw...@matrix-vision.de wrote on 2010/10/22 16:30:49: Joakim, your commit d1e0b10accdbac2e0a8b2cbf7c589645442f87c5 renders my MPC8377 based board unbootable. Two weeks ago I got this after power on : U-Boot 2010.09-00486-gfda6278-dirty (Oct 22 2010 -

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-22 Thread Joakim Tjernlund
Mike Frysinger vap...@gentoo.org wrote on 2010/10/22 17:18:05: On Friday, October 22, 2010 04:34:52 Joakim Tjernlund wrote: Don't you want to know if the app screwed up or if the system is out of memory? The only upside to malloc(0) == NULL I can see is an extra check for apps

Re: [U-Boot] ELF_RELOC causes strange I-cache issues

2010-10-21 Thread Joakim Tjernlund
Hello Albert, Albert Aribaud wrote: Wolfgang (and others who can/want), Please test this patch; it should add a complete barrier to make sure that all fixups are written to RAM before jumping there, and that no remnants subsist of the old unfixed code in the instruction paths.

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-21 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/21 13:51:26: Dear Joakim Tjernlund, In message OFD5ABFC5E.96E88C93-ONC12577C3.00406E0E-C12577C3. 00408...@transmode.se you wrote: It is legal for malloc() to return NULL in case of size==0, and for the sake of simplicity I recommend we do

Re: [U-Boot] [PATCH] Prevent malloc with size 0

2010-10-21 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/21 14:02:39: Dear Joakim Tjernlund, In message OF9AD66E3F.36E9C654-ONC12577C3.004134FD-C12577C3. 0041a...@transmode.se you wrote: Of course we could return some valid pointer like glibc does, i. e. implement something like

Re: [U-Boot] [PATCH] powerpc: always print the RAM relocated address when boot up

2010-10-21 Thread Joakim Tjernlund
The RAM relocated address is useful when debugging or there is u-boot crash dump. So always print it instead of debug. Signed-off-by: Roy Zang tie-fei.z...@freescale.com Cc: Wood Scott-B07421 b07...@freescale.com I use a similar patch here too so: Acked-by: Joakim Tjernlund joakim.tjernl

Re: [U-Boot] [PATCHv3] mpc83xx: Add -fpic relocation support

2010-10-20 Thread Joakim Tjernlund
From: Joakim Tjernlund joakim.tjernl...@transmode.se To: u-boot@lists.denx.de, Scott Wood scottw...@freescale.com, Kim Phillips kim.phill...@freescale.com Cc: Joakim Tjernlund joakim.tjernl...@transmode.se Date: 2010/10/13 23:12 Subject: [U-Boot] [PATCHv3] mpc83xx: Add -fpic relocation

Re: [U-Boot] ELF_RELOC causes strange I-cache issues

2010-10-20 Thread Joakim Tjernlund
Dear Albert ARIBAUD, In message 4cbf4d17.6020...@free.fr you wrote: Is the data cache on or off when you experience the issue? If it was on, DC is always off. DC on has always casued problems with lots of drivers, including USB, so we never attempted doing that (except for

[U-Boot] commit powerpc: Remove warm reset entry point does not work on mpc83xx

2010-10-19 Thread Joakim Tjernlund
My board has a problem with this change. I added it manually to my tree and now it wont boot at all(only with BDI2000 connected). It seems like my board uses the warm start vector at all times. Padding with 4 nop's after the _start symbol fixes the problem. It might be due to a somewhat peculiar

Re: [U-Boot] commit powerpc: Remove warm reset entry point does not work on mpc83xx

2010-10-19 Thread Joakim Tjernlund
Peter Tyser pty...@xes-inc.com wrote on 2010/10/19 17:51:11: On Tue, 2010-10-19 at 12:07 +0200, Joakim Tjernlund wrote: My board has a problem with this change. I added it manually to my tree and now it wont boot at all(only with BDI2000 connected). Just to clarify, it won't boot

Re: [U-Boot] commit powerpc: Remove warm reset entry point does not work on mpc83xx

2010-10-19 Thread Joakim Tjernlund
Peter Tyser pty...@xes-inc.com wrote on 2010/10/19 20:39:41: It seems like my board uses the warm start vector at all times. Padding with 4 nop's after the _start symbol fixes the problem. It might be due to a somewhat peculiar reset design but I cannot understand why. Does

Re: [U-Boot] commit powerpc: Remove warm reset entry point does not work on mpc83xx

2010-10-19 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/19 22:04:17: Dear Joakim Tjernlund, In message OFBC383CCF.86B567D6-ONC12577C1.006A80D5-C12577C1. 006aa...@transmode.se you wrote: During normal use I thought that the reset entry point was always 0xX100 and a warm reset would never

Re: [U-Boot] commit powerpc: Remove warm reset entry point does not work on mpc83xx

2010-10-19 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/19 23:13:59: Dear Joakim Tjernlund, In message OF7EBFC833.2F0E9C3D-ONC12577C1.00737E7A-C12577C1. 0073e...@transmode.se you wrote: There is one thing though: At address 0x100(and 0x110) we have a branch to where the boot is really located

Re: [U-Boot] Kirkwood: no console messages from init_sequence?

2010-10-18 Thread Joakim Tjernlund
Dear Eric Cooper, On Sun, Oct 17, 2010 at 08:40:31PM -0400, Eric Cooper wrote: I no longer see any of the early console messages that should result from display_banner, print_cpuinfo, etc. The first thing I see is the NAND information: [...] But if I load the same u-boot image

[U-Boot] [PATCH] dlmalloc.c: Fix gcc alias warning

2010-10-14 Thread Joakim Tjernlund
Fix these warnings: dlmalloc.c: In function 'free': dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break strict-aliasing rules dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break strict-aliasing rules dlmalloc.c:2507: warning: dereferencing pointer

[U-Boot] [PATCHv2] dlmalloc.c: Fix gcc alias warning

2010-10-14 Thread Joakim Tjernlund
'({anonymous})' does break strict-aliasing rules Some page(http://blog.worldofcoding.com/2010/02/solving-gcc-44-strict-aliasing-problems.html) suggests adding __attribute__((__may_alias__)). Doing so makes the warnings go away. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se

Re: [U-Boot] [PATCH] dlmalloc.c: Fix gcc alias warning

2010-10-14 Thread Joakim Tjernlund
Alexander Stein alexander.st...@systec-electronic.com wrote on 2010/10/14 08:50:29: Hello, On Thursday 14 October 2010, 08:41:20 Joakim Tjernlund wrote: Fix these warnings: dlmalloc.c: In function 'free': dlmalloc.c:2507: warning: dereferencing pointer '({anonymous})' does break

Re: [U-Boot] RFC: introduce malloc_cleared() ?

2010-10-14 Thread Joakim Tjernlund
Wolfgang Denk schrieb: Dear Reinhard Meyer, In message 4cb6a110.6080...@emk-elektronik.de you wrote: instead of adding or having the sequence of malloc(), memset() in all places where a definitely sane initialized structure is required it would make more sense to introduce a

[U-Boot] [PATCH] powerpc: do not fixup NULL ptrs

2010-10-14 Thread Joakim Tjernlund
but it is not. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- arch/powerpc/cpu/74xx_7xx/start.S |4 +++- arch/powerpc/cpu/mpc512x/start.S |4 +++- arch/powerpc/cpu/mpc5xx/start.S |4 +++- arch/powerpc/cpu/mpc5xxx/start.S |4 +++- arch/powerpc/cpu/mpc8220/start.S |4

Re: [U-Boot] RFC: introduce malloc_cleared() ?

2010-10-14 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/14 11:38:57: Dear Joakim Tjernlund, In message OF32166834.809C7D71-ONC12577BC.0031112B-C12577BC. 00313...@transmode.se you wrote: I would borrow the naming from linux and call it mallocz ... except that Linux does not use any mallocz

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
Albert ARIBAUD albert.arib...@free.fr wrote on 2010/10/13 08:30:33: Le 12/10/2010 23:00, Joakim Tjernlund a écrit : Yes, but the difference isn't really the arch. It is the -mrelocatable flag that is the big difference. Not only: obviously, implementing GOT relocation is not done

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
On 10/12/2010 11:30 PM, Albert ARIBAUD wrote: Le 12/10/2010 23:00, Joakim Tjernlund a écrit : Yes, but the difference isn't really the arch. It is the -mrelocatable flag that is the big difference. Not only: obviously, implementing GOT relocation is not done the same on both

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
Albert ARIBAUD albert.arib...@free.fr wrote on 2010/10/13 11:05:09: Le 13/10/2010 09:07, Joakim Tjernlund a écrit : Did you use -msingle-pic-base too with -fpic/-fPIC? This is what makes a difference(together with -fpic). The most interesting size is the total flash size IMHO. Reducing

[U-Boot] [PATCHv2] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
3e7f3 u-boot size with -mbss-plt -fpic -msingle-pic-base text data bss dec hex filename 222091 658024228 252899 3dbe3 u-boot Note: -msingle-pic-base is not supported upstarem yet. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- v2: Better commit

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 21:54:10: On Tue, 12 Oct 2010 21:17:38 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Yes, it is a simple symbol to add. I will do it twm if you don't beat me to it. it would be nice if you could try what works

[U-Boot] gcc patch to support -fpic with -mrelocatable

2010-10-13 Thread Joakim Tjernlund
Here is the gcc patch I did to support -fpic with -mrelocatable In case someone wants to try it out. Jocke From d8ff0b3f0b44480542eab04d1659f4368b6b09cf Mon Sep 17 00:00:00 2001 From: Joakim Tjernlund joakim.tjernl...@transmode.se Date: Sun, 10 Oct 2010 10:34:50 +0200 Subject: [PATCH

[U-Boot] gcc: add -msingle-pic-base option.

2010-10-13 Thread Joakim Tjernlund
Here is the -msingle-pic-base patch to gcc in case anyone wants to try it. Jocke From b418def9575d6ea3698077888157ae52631e52f3 Mon Sep 17 00:00:00 2001 From: Joakim Tjernlund joakim.tjernl...@transmode.se Date: Sat, 9 Oct 2010 12:45:39 +0200 Subject: [PATCH] PowerPC: Add msingle-pic-base

[U-Boot] [PATCHv3] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
255987 3e7f3 u-boot size with -mbss-plt -fpic -msingle-pic-base text data bss dec hex filename 222091 658024228 252899 3dbe3 u-boot Note: -msingle-pic-base is not supported upstream yet. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- v3: - Make

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-13 Thread Joakim Tjernlund
Albert ARIBAUD albert.arib...@free.fr wrote on 2010/10/13 11:05:09: Le 13/10/2010 09:07, Joakim Tjernlund a écrit : Did you use -msingle-pic-base too with -fpic/-fPIC? This is what makes a difference(together with -fpic). The most interesting size is the total flash size IMHO

[U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
This add relocation of .got entries produced by -fpic. -fpic produces 2-3% smaller code and is faster. Unfortunately gcc promotes -fpic to -fPIC when -mrelocatable is used so one need a very small patch to gcc too(sent upstream). Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/12 14:52:18: Dear Joakim Tjernlund, In message 1286887081-23172-1-git-send-email-joakim.tjernl...@transmode.se you wrote: This add relocation of .got entries produced by -fpic. -fpic produces 2-3% smaller code and is faster. Unfortunately

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/12 15:47:19: Dear Joakim Tjernlund, In message OF4DCFBD28.58E81A84-ONC12577BA.0047150B-C12577BA. 0047d...@transmode.se you wrote: What happens when one uses this patch in combination with a standard (i. e. older, unpatched) GCC

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/12 17:52:58: On Tue, 12 Oct 2010 15:04:31 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: _GLOBAL_OFFSET_TABLE_ is a predefined symbol that the linker defines to be in the middle of the -fpic GOT table. It marks the end

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 19:31:25: On Tue, 12 Oct 2010 16:10:33 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Wolfgang Denk w...@denx.de wrote on 2010/10/12 15:47:19: Dear Joakim Tjernlund, In message OF4DCFBD28.58E81A84

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Le 12/10/2010 19:11, Joakim Tjernlund a écrit : Figured I should mention that I have added -msingle-pic-base(from ARM) which works nicely with -fpic(not sure if -fPIC is possible) and reduces size even more: Since you seem to be following the same path as I did on ARM, I may

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/12 20:25:40: On Tue, 12 Oct 2010 13:19:38 -0500 Kim Phillips kim.phill...@freescale.com wrote: On Tue, 12 Oct 2010 19:41:56 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Kim Phillips kim.phill...@freescale.com wrote

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 20:19:38: On Tue, 12 Oct 2010 19:41:56 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 19:31:25: that moderate size increase in start.S breaks nand builds

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Yes, it is a simple symbol to add. I will do it twm if you don't beat me to it. it would be nice if you could try what works and not though. Could not wait, does this work for you? diff --git a/nand_spl/board/freescale/mpc8313erdb/u-boot.lds

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/12 21:20:26: On Tue, 12 Oct 2010 21:13:19 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 20:19:38: On Tue, 12 Oct 2010 19:41:56 +0200 Joakim Tjernlund

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/12 22:16:14: On Tue, 12 Oct 2010 21:51:44 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Scott Wood scottw...@freescale.com wrote on 2010/10/12 21:20:26: We do need to relocate with NAND SPL. We start in the NAND buffer

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Albert ARIBAUD albert.arib...@free.fr wrote on 2010/10/12 22:37:54: Le 12/10/2010 20:11, Joakim Tjernlund a écrit : Le 12/10/2010 19:11, Joakim Tjernlund a écrit : Figured I should mention that I have added -msingle-pic-base(from ARM) which works nicely with -fpic(not sure if -fPIC

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/10/12 22:48:59: On Tue, 12 Oct 2010 22:40:27 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Scott Wood scottw...@freescale.com wrote on 2010/10/12 22:16:14: The link address is of the pre-relocation NAND buffer. hmm

Re: [U-Boot] [PATCH] mpc83xx: Add -fpic relocation support

2010-10-12 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/10/12 21:54:10: On Tue, 12 Oct 2010 21:17:38 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Yes, it is a simple symbol to add. I will do it twm if you don't beat me to it. it would be nice if you could try what works

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-05 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/10/04 23:10:31: Dear Joakim Tjernlund, In message OFF06E784F.A10A5A15-ONC12577B2.0065FB3C-C12577B2. 0066d...@transmode.se you wrote: :), actually it wasn't that bad. Wolfgang nearly accepted the code even :) Yes, I was really tempted because I do

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-04 Thread Joakim Tjernlund
Hi Wolfgang, snip Well, please keep in mind that all this code is working find on PowerPC, which has been using relocation right from the beginning. It is my understanding that we don't suffer from this issue any more on PPC - Peter Tyser posted relocation fixup patches for PPC

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-04 Thread Joakim Tjernlund
Le 04/10/2010 09:36, Joakim Tjernlund a écrit : However, I think we will loose the possibility to add link once, burn and run anywhere feature I impl. once(but it was at the time deemed to intrusive) if we skip -fPIC and go for the linker -pie relocation. On ARM at least, I don't think

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-04 Thread Joakim Tjernlund
Le 04/10/2010 10:57, Heiko Schocher a écrit : ./MAKEALL edminiv2 results: text databssdechexfilename 141376 4388 16640 162404 27a64./u-boot (for GOT reloc) 150160 3819 16640 170619 29a7b

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-04 Thread Joakim Tjernlund
Albert ARIBAUD albert.arib...@free.fr wrote on 2010/10/04 10:33:05: Le 04/10/2010 10:28, Joakim Tjernlund a écrit : Le 04/10/2010 09:36, Joakim Tjernlund a écrit : However, I think we will loose the possibility to add link once, burn and run anywhere feature I impl. once

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-04 Thread Joakim Tjernlund
J. William Campbell jwilliamcampb...@comcast.net wrote on 2010/10/04 19:59:47: On 10/4/2010 10:06 AM, Wolfgang Denk wrote: Dear J. William Campbell, In message 4ca9f294.8080...@comcast.net you wrote: Yes, I think Wolfgang is correct. This is not going to be easy to do in general. To run

Re: [U-Boot] ARM relocation, question to Heiko

2010-10-02 Thread Joakim Tjernlund
Hello Reinhard, Reinhard Meyer wrote: Dear Albert ARIBAUD, I try to understand how the relocation process could handle pointers (to functions or other data) in const or data sections. Your code cannot know what is data and what is a pointer that needs adjustment? Best Regards,

Re: [U-Boot] 83xx fails to boot with moderately sized kernels

2010-09-13 Thread Joakim Tjernlund
Scott Wood scottw...@freescale.com wrote on 2010/09/13 21:21:33: On Sat, 11 Sep 2010 09:19:34 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Dear Ira W. Snyder, In message 20100910181022.ga18...@ovro.caltech.edu you wrote: Would you prefer a patch only

Re: [U-Boot] 83xx fails to boot with moderately sized kernels

2010-09-11 Thread Joakim Tjernlund
Dear Ira W. Snyder, In message 20100910181022.ga18...@ovro.caltech.edu you wrote: Would you prefer a patch only for the MPC8349EMDS, or should I try and convert the other boards too? How should I know which boards are safe? Grep for CONFIG_E300? I think we should try and update all

Re: [U-Boot] Start/stop of network devices (was: Re: [PATCH] UEC PHY: Speed up initial PHY neg.)

2010-08-24 Thread Joakim Tjernlund
Hi Ben, [Jocke deleted from CC as this is not about the patch anymore] But I still want to know what will happen to it. I didn't send this patch to start another discussion :) Jocke ___ U-Boot mailing list U-Boot@lists.denx.de

Re: [U-Boot] [PATCH] UEC PHY: Speed up initial PHY neg.

2010-08-23 Thread Joakim Tjernlund
Ben Warren biggerbadder...@gmail.com wrote on 2010/08/23 16:12:07: Hi Jocke, On Monday, August 23, 2010, Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Ben Warren biggerbadder...@gmail.com wrote on 2010/08/23 09:08:17:   Hi Detlev, On 8/13/2010 1:20 AM, Detlev Zundel wrote

[U-Boot] [PATCHv2] net: Fix faulty definition of uec_initialize()

2010-08-19 Thread Joakim Tjernlund
The correct definition is in drivers/qe/uec.h so just remove this one. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- include/netdev.h |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/include/netdev.h b/include/netdev.h index 882642a..65833e2 100644

Re: [U-Boot] [PATCH 1/2] UEC: Don't udelay needlessly

2010-08-18 Thread Joakim Tjernlund
On Wed, 11 Aug 2010 11:44:21 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: uec_init() adds an udelay(10) even though the PHY status read went well, don't do that. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- Acked-by: Kim Phillips kim.phill

Re: [U-Boot] [PATCH 2/2] UEC PHY: Remove strange 0.5 sec delay

2010-08-18 Thread Joakim Tjernlund
On Wed, 11 Aug 2010 11:44:22 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: This udelay looks bogus and doesn't help my board. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- This delay was introduced by ee62ed3286f83b98b7785e0318dc6379e78f7ff6

Re: [U-Boot] [PATCH 2/2] UEC PHY: Remove strange 0.5 sec delay

2010-08-18 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/08/12 07:17:49: On Wed, 11 Aug 2010 11:44:22 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: This udelay looks bogus and doesn't help my board. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se

Re: [U-Boot] [PATCH] UEC PHY: Speed up initial PHY neg.

2010-08-13 Thread Joakim Tjernlund
Detlev Zundel d...@denx.de wrote on 2010/08/13 10:20:46: Hi Jocke, Instead of always performing an autoneg, check if the PHY already has a link and if it matches one of the requested modes. Initially only 100MbFD is optimized this way. Isn't it about time that we think about _not_

Re: [U-Boot] [PATCH 2/2] UEC PHY: Remove strange 0.5 sec delay

2010-08-12 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010/08/12 07:17:49: On Wed, 11 Aug 2010 11:44:22 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: This udelay looks bogus and doesn't help my board. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se

Re: [U-Boot] [PATCH] UEC PHY: Speed up initial PHY neg.

2010-08-12 Thread Joakim Tjernlund
Detlev Zundel d...@denx.de wrote on 2010/08/12 14:58:47: Hi Jocke, Instead of always performing an autoneg, check if the PHY already has a link and if it matches one of the requested modes. Initially only 100MbFD is optimized this way. Isn't it about time that we think about _not_

Re: [U-Boot] Early I2C bus availability

2010-08-12 Thread Joakim Tjernlund
Hi, We're contemplating a new embedded design based on the MPC8641. This design is going to have the processor potentially running at two different clock frequencies and therefore (or so we're told by Freescale) the memory will need to run at different clock rates (same physical memory,

Re: [U-Boot] [PATCH] UEC PHY: Speed up initial PHY neg.

2010-08-11 Thread Joakim Tjernlund
vapierfil...@gmail.com wrote on 2010/08/10 22:23:19: On Tue, Aug 10, 2010 at 10:36 AM, Joakim Tjernlund wrote: Instead of always performing an autoneg, check if the PHY already has a link and if it matches one of the requested modes. Initially only 100MbFD is optimized this way. wish

[U-Boot] [PATCH 1/2] UEC: Don't udelay needlessly

2010-08-11 Thread Joakim Tjernlund
uec_init() adds an udelay(10) even though the PHY status read went well, don't do that. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- drivers/qe/uec.c |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/drivers/qe/uec.c b/drivers/qe/uec.c index

[U-Boot] [PATCH 2/2] UEC PHY: Remove strange 0.5 sec delay

2010-08-11 Thread Joakim Tjernlund
This udelay looks bogus and doesn't help my board. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- This delay was introduced by ee62ed3286f83b98b7785e0318dc6379e78f7ff6 Kim, is this really needed for you? drivers/qe/uec_phy.c |1 - 1 files changed, 0 insertions(+), 1

Re: [U-Boot] [PATCH] net: Fix faulty definition of uec_initialize()

2010-08-10 Thread Joakim Tjernlund
vapierfil...@gmail.com wrote on 2010/08/10 08:04:02: On Tue, Aug 10, 2010 at 1:52 AM, Joakim Tjernlund wrote: Ben Warren wrote on 2010/08/09 22:54:10:  On 8/9/2010 1:18 PM, Mike Frysinger wrote: On Mon, Aug 9, 2010 at 3:15 PM, Joakim Tjernlund wrote: The correct definition

[U-Boot] [PATCHv2] net: Fix faulty definition of uec_initialize()

2010-08-10 Thread Joakim Tjernlund
The correct definition is in drivers/qe/uec.h so just remove this one. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- include/netdev.h |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/include/netdev.h b/include/netdev.h index 882642a..65833e2 100644

[U-Boot] [PATCH] UEC PHY: Speed up initial PHY neg.

2010-08-10 Thread Joakim Tjernlund
Instead of always performing an autoneg, check if the PHY already has a link and if it matches one of the requested modes. Initially only 100MbFD is optimized this way. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- drivers/qe/uec_phy.c |9 + 1 files changed, 9

Re: [U-Boot] [PATCHv2 CFI flash]: Workaround for Numonyx Axcell P33/P30 256-Mbit 65nm bug

2010-08-09 Thread Joakim Tjernlund
Dear Stefan, In message 20100623131040.ga23...@frolo.macqel Philippe De Muyter wrote: Hello Wolfgang list, This is a revised patch, with comments and indentation fixed, I hope. I have ported U-boot to a in house made board with Numonyx Axcell P33/P30 256-Mbit 65nm flash chips.

Re: [U-Boot] [PATCHv2 CFI flash]: Workaround for Numonyx Axcell P33/P30 256-Mbit 65nm bug

2010-08-09 Thread Joakim Tjernlund
Philippe De Muyter p...@macqel.be wrote on 2010/08/09 14:57:27: Hello Joakim, On Mon, Aug 09, 2010 at 10:32:25AM +0200, Joakim Tjernlund wrote: Dear Stefan, In message 20100623131040.ga23...@frolo.macqel Philippe De Muyter wrote: Hello Wolfgang list, This is a revised

[U-Boot] [PATCH] net: Fix faulty definition of uec_initialize()

2010-08-09 Thread Joakim Tjernlund
The correct definition is in drivers/qe/uec.h so just include that one instead. Signed-off-by: Joakim Tjernlund joakim.tjernl...@transmode.se --- This is only compile tested on my board but hopefully it will do. If not, I urge Freescale to clean up this mess. include/netdev.h |4 +--- 1

Re: [U-Boot] [PATCH] net: Fix faulty definition of uec_initialize()

2010-08-09 Thread Joakim Tjernlund
Ben Warren biggerbadder...@gmail.com wrote on 2010/08/09 22:54:10: On 8/9/2010 1:18 PM, Mike Frysinger wrote: On Mon, Aug 9, 2010 at 3:15 PM, Joakim Tjernlund wrote: The correct definition is in drivers/qe/uec.h so just include that one instead. ... except that bleeds a ton of crap

[U-Boot] 83xx UEC compile error

2010-08-03 Thread Joakim Tjernlund
Got this while trying to upgrade: ../../drivers/qe/uec.h:766: error: conflicting types for 'uec_initialize' /usr/local/src/cutu2uboot/include/netdev.h:86: error: previous declaration of 'uec_initialize' ../../drivers/qe/uec.h:766: error: conflicting types for 'uec_initialize'

[U-Boot] UEC numbering broken in uec_initialize

2010-08-03 Thread Joakim Tjernlund
Commit qe: Pass in uec_info struct through uec_initialize (8e55258f144764de8902e9f078a7ad4c6c022c2f) changed the FSL UEC# numbering: - sprintf(dev-name, FSL UEC%d, index); + sprintf(dev-name, FSL UEC%d, uec_info-uf_info.ucc_num); from logical(zero based)to physical UCC number. This

Re: [U-Boot] uboot redundancy.

2010-07-21 Thread Joakim Tjernlund
before i spent much time on this. Also if anyone has already done similar implentation for any of the boards let me know. -Sagar On Mon, Jul 19, 2010 at 4:36 PM, Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Sagar Heroorkar sagar.heroor...@gmail.com wrote on 2010/07/19 15:26:20: Hi

Re: [U-Boot] uboot redundancy.

2010-07-21 Thread Joakim Tjernlund
. Jocke On Wed, Jul 21, 2010 at 12:27 PM, Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Sagar Heroorkar sagar.heroor...@gmail.com wrote on 2010/07/21 17:21:31: Hi All, Before i start using your ( Joakim )approach. I would like to get some tips from Wolfgang or someone who

Re: [U-Boot] [PATCH] MPC512x: workaround data corruption for unaligned local bus accesses

2010-06-29 Thread Joakim Tjernlund
Dear Detlev Zundel, In message m2vd9283ew@ohwell.denx.de you wrote: Acked-by: Detlev Zundel d...@denx.de thanks. The only thing I wonder is the filename 'memcpy_mpc5200.c' as the code doesn't really have any 5200 specifics in it. What about As far as I understand this

Re: [U-Boot] [PATCH] MPC512x: workaround data corruption for unaligned local bus accesses

2010-06-29 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/06/29 14:55:44: Dear Joakim Tjernlund, In message OFEB4E68BC.F6B8C9D0-ONC1257751.0045AE08-C1257751. 0045d...@transmode.se you wrote: I could not come up with a better name... What is align32wrap supposed to mean? mpc5200_memcpy_fromio

Re: [U-Boot] [PATCH] MPC512x: workaround data corruption for unaligned local bus accesses

2010-06-29 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/06/29 14:55:44: Dear Joakim Tjernlund, In message OFEB4E68BC.F6B8C9D0-ONC1257751.0045AE08-C1257751. 0045d...@transmode.se you wrote: I could not come up with a better name... What is align32wrap supposed to mean

Re: [U-Boot] [PATCH] MPC512x: workaround data corruption forunaligned local bus accesses

2010-06-29 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010/06/29 21:24:03: Dear Steve Deiters, In message 181804936abc2349be503168465576460f272...@exchserver.basler.com you wrote: I just posted a patch on the linuxppc-dev list that simply uses a slightly modified version of memcpy to always keep the

Re: [U-Boot] [x86] Success! - Linux is UP

2010-04-29 Thread Joakim Tjernlund
Hi All, Just a really quick message to say that I now have Linux Kernel 2.6.33 and a JFFS2 Root File System up and running on my AMD SC520 board. I big thanks to everyone for helping out on this 'little' project of mine. There is no way I could have possibly gained so much personal

Re: [U-Boot] mpc8313 SPL, relocate_code, large page NAND

2010-04-20 Thread Joakim Tjernlund
On Tue, 20 Apr 2010 10:36:08 +0200, Peter Vollmer pvollmer-u-b...@innominate.com wrote: I then inserted 8 pairs of lwzu/stwu inside the loop to see when exactly the problem occurs: 1: lwzur0,4(r8) stwur0,4(r7) lwzur0,4(r8) stwur0,4(r7) ...

Re: [U-Boot] mpc8313 SPL, relocate_code, large page NAND

2010-04-20 Thread Joakim Tjernlund
Peter Vollmer pvollmer-u-b...@innominate.com wrote on 2010/04/20 14:12:41: On Tue, 20 Apr 2010 11:57:09 +0200, Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Probably a BDI2000 issue. If memory serves right BDI2000 flushes the cache when it hits a BP. Try this addin this to your

Re: [U-Boot] [PATCH] POST: Added ECC memory test for mpc83xx.

2010-04-17 Thread Joakim Tjernlund
Michael Zaidman michael.zaid...@gmail.com wrote on 2010/04/16 18:44:12: On Fri, Apr 16, 2010 at 1:25 AM, Kim Phillips kim.phill...@freescale.com wrote: On Thu, 8 Apr 2010 10:37:08 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Kim Phillips kim.phill...@freescale.com wrote

Re: [U-Boot] [PATCH] POST: Added ECC memory test for mpc83xx.

2010-04-17 Thread Joakim Tjernlund
Michael Zaidman michael.zaid...@gmail.com wrote on 2010/04/16 18:44:12: On Fri, Apr 16, 2010 at 1:25 AM, Kim Phillips kim.phill...@freescale.com wrote: On Thu, 8 Apr 2010 10:37:08 +0200 Joakim Tjernlund joakim.tjernl...@transmode.se wrote: Kim Phillips kim.phill

Re: [U-Boot] Bad Data CRC ERROR: can't get kernel image!

2010-04-15 Thread Joakim Tjernlund
Hi Detlev, I used iminfo 0xffdc and got following log    Image Name:   Linux-2.6.31-LE    Image Type:   PowerPC Linux Kernel Image (gzip compressed)    Data Size:    936145 Bytes = 914.2 kB    Load Address:    Entry Point:     Bad Data CRC Here i am confused that

Re: [U-Boot] [PATCH] POST: Added ECC memory test for mpc83xx.

2010-04-08 Thread Joakim Tjernlund
Kim Phillips kim.phill...@freescale.com wrote on 2010-04-08 10:27:03: On Thu, 8 Apr 2010 09:49:08 +0300 Michael Zaidman michael.zaid...@gmail.com wrote: On Wed, Apr 7, 2010 at 7:01 PM, Joakim Tjernlund joakim.tjernl...@transmode.se wrote: On Wed, Apr 7, 2010 at 6:10 PM, Timur Tabi

Re: [U-Boot] U-boot env variables parsing

2010-04-08 Thread Joakim Tjernlund
Detlev Zundel d...@denx.de wrote on 2010-04-08 12:00:05: Hi Jocke, Hi Detlev :) To me it looks like the new code would indeed do a greedy substitution only stopping when no more substitutions can be done. This is very un-unixy and thus not something I'd like to see as a

Re: [U-Boot] U-boot env variables parsing

2010-04-08 Thread Joakim Tjernlund
Detlev Zundel d...@denx.de wrote on 2010-04-08 18:06:40: Hi Jocke, Hi again :) [...] Since an escape char appear to exist, one should be able to use it much like you did above so I don't think that any use case disappears. Instead the common usage becomes simpler and the so far

[U-Boot] CONFIG_PRAM and CONFIG_SYS_MEM_TOP_HIDE ?

2010-04-07 Thread Joakim Tjernlund
Just started to look at reserving some RAM from u-boot and the kernel and got a bit confused about what config options to use. I found CONFIG_PRAM and CONFIG_SYS_MEM_TOP_HIDE and from what I can tell one needs to set both to hide some memory from both u-boot and linux but CONFIG_SYS_MEM_TOP_HIDE

Re: [U-Boot] [PATCH] POST: Added ECC memory test for mpc83xx.

2010-04-07 Thread Joakim Tjernlund
On Wed, Apr 7, 2010 at 6:10 PM, Timur Tabi timur.t...@gmail.com wrote: On Wed, Apr 7, 2010 at 9:47 AM, Michael Zaidman michael.zaid...@gmail.com wrote: The version #2 of the patch is located here http://lists.denx.de/pipermail/u-boot/2010-April/069579.html What is ppcDWstore(), and

Re: [U-Boot] U-boot env variables parsing

2010-04-01 Thread Joakim Tjernlund
Hi Nitin, Hi! I am doing env settings some thing like this, ROOT1=/dev/mmcblk0p1 ROOT2=/dev/mmcblk0p2 ROOT=${ROOT1} bootargs1=console=ttyS0,115200n8 mem=256M noinitrd rw rootdelay=1 ${ROOT} when I say 'setenv bootargs ${bootargs1}', ${ROOT} gets resolved to 'ROOT1', it does

Re: [U-Boot] U-boot env variables parsing

2010-04-01 Thread Joakim Tjernlund
Wolfgang Denk w...@denx.de wrote on 2010-04-01 14:47:45: Dear Joakim Tjernlund, In message OFEBF95CA1.44E68372-ONC12576F8.0043F4F7-C12576F8. 0044d...@transmode.se you wrote: linuxip=ip=$(ipaddr)::$(gatewayip):$(netmask):$(hostname):$(linuxif):off tboot=setenv bootargs $(linuxroot

<    1   2   3   4   5   6   7   8   >