Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-09 Thread Wolfgang Denk
Dear Alexander Stein, In message <201008091351.39800.alexander.st...@systec-electronic.com> you wrote: > > > Better do not build on undefined behaviour. > > Yes, of course. But it seems difficult to recognise thing like a simple > memmove with dest < src as an undefined behavior. See the FAQ:

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-09 Thread Alexander Stein
Dear Wolfgang, August 2010, 13:43:32 schrieb Wolfgang Denk: > > Well, that's at least one possibility but it is very annoying that > > something like memmove that works fine so far suddenly stops working > > when watchdog support is enabled. > > Yes, I understand this. It's also annoying when you

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-09 Thread Wolfgang Denk
Dear Alexander Stein, In message <201008091310.37634.alexander.st...@systec-electronic.com> you wrote: > > > Even if it would work in your case of uncompressed images, it is bound > > to fail for compressed ones where the uncompressed code grows faster > > then compressed data get consumed. > >

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-09 Thread Alexander Stein
Dear Wolfgang, Am Montag, 9. August 2010, 11:26:56 schrieb Wolfgang Denk: > > IIRC the problem arose when i downloaded my image to 0x2000 (SD-RAM) > > using TFTP and my Linux kernel entry point was at 0x20008000. So when > > Don;t do this, then. Such kind of overlap has never been supported.

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-09 Thread Wolfgang Denk
Dear Alexander Stein, In message <201008090857.32705.alexander.st...@systec-electronic.com> you wrote: > > > > common/image.c | 11 --- > > > 1 files changed, 8 insertions(+), 3 deletions(-) > > > > Why would this be needed? Do you have an error scenario? > > IIRC the problem arose

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-08 Thread Alexander Stein
Dear Wolfgang, Am Montag, 9. August 2010, 00:18:19 schrieb Wolfgang Denk: > In message <1279701826-20083-1-git-send-email-alexander.st...@systec- electronic.com> you wrote: > > Signed-off-by: Alexander Stein > > --- > > > > common/image.c | 11 --- > > 1 files changed, 8 insertions(+)

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-08 Thread Wolfgang Denk
Dear Alexander Stein, In message <1279701826-20083-1-git-send-email-alexander.st...@systec-electronic.com> you wrote: > Signed-off-by: Alexander Stein > --- > common/image.c | 11 --- > 1 files changed, 8 insertions(+), 3 deletions(-) And BTW: > + if (to <= from) > +

Re: [U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-08-08 Thread Wolfgang Denk
Dear Alexander Stein, In message <1279701826-20083-1-git-send-email-alexander.st...@systec-electronic.com> you wrote: > Signed-off-by: Alexander Stein > --- > common/image.c | 11 --- > 1 files changed, 8 insertions(+), 3 deletions(-) Why would this be needed? Do you have an error

[U-Boot] [PATCH] memmove_wd: Allow overlapping memory area

2010-07-21 Thread Alexander Stein
Signed-off-by: Alexander Stein --- common/image.c | 11 --- 1 files changed, 8 insertions(+), 3 deletions(-) diff --git a/common/image.c b/common/image.c index 6d8833e..da0fdd5 100644 --- a/common/image.c +++ b/common/image.c @@ -456,9 +456,14 @@ void memmove_wd (void *to, void *from,