public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Rogan Dawes <rogan@dawes.za.net>
To: u-boot@lists.denx.de
Subject: [U-Boot] Debugging why my kernel won't start
Date: Tue, 17 Aug 2010 12:21:32 +0200	[thread overview]
Message-ID: <4C6A62AC.6010206@dawes.za.net> (raw)
In-Reply-To: <4C6A600B.5020809@free.fr>

On 2010/08/17 12:10 PM, Albert ARIBAUD wrote:
> (quick note to Wolfgang: yes, there is RAM at 0x00008000 on these 
> machines. All orion5x based machines have RAM start at 0, and u-boot 
> makes sure SDRAM is set up this way)
> 
> Rogan,
> 
> You cannot tell from your log output that memmove never completes. It 
> could as well be the kernel not outputting to the console, or failing to 
> start at all even though the move was ok.

Actually, I can tell that the memmove never completes (or if it does, it
alters the code flow in the process):

>> So I changed memmove_wd to use the watchdog style of memmove'ing, in
>> small chunks to try to track down where the problem arises. I used 1kB
>> chunks, and got:
>>
>> Moving 1024 of 611612 bytes from ff8f6840 to 000de800
>> Moving 1024 of 610588 bytes from ff8f6c40 to 000dec00
>> Moving 1024 of 609564 bytes from ff8f7040 to 000df000
>>
>> before it finally hung.

I had a debug statement in the loop, printing out the above at each
iteration. Since it never completed the loop, copying/moving the entire
kernel (609564 bytes remaining), I think it is safe to assume that it
never got to the point of trying to boot the kernel.

Additionally, just doing a cp with the above parameters also hangs.

> The first thing you should do is make sure that you pass the right 
> machine-id, but also that you pass ATAGs correctly to the kernel -- it 
> seems that at least some LaCie custom u-boot  implementations use an env 
> variable ('mainlineKernel', IIRC) to differenciate between mainline and 
> LaCie custom kernels. Maybe your HW was designed the same way. Best is 
> you look up the u-boot source code provided by the manufacturer of your 
> machine.
> 
> The second thing is to make sure your kernel uses the right console. Are 
> you using netconsole? Maybe the manufacturer's kernel does not have 
> netconsole. Do you use a serial (RS-232) console? Make sure the kernel 
> has command line arguments to use it too.
> 
> Amicalement,

I'll check those once I have got the copy working correctly :-)

FWIW, I'm using a serial console, not netconsole. And the bootargs
include the console definition.

Based on what Wolfgang has said, perhaps the address space registers are
set up differently in the vendor u-boot to what the current mainline is
doing. I'll check that next, I think.

I'm just struggling to understand how the last command that I executed
ended up in the memory where I was trying to copy the kernel to. That
suggests that U-boot is actively using that memory for some reason, and
copying the kernel image over the top of it seems like a very good way
to cause u-boot to stop behaving consistently, and hang.

Thanks anyway.

Rogan

  reply	other threads:[~2010-08-17 10:21 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-16  7:24 [U-Boot] Debugging why my kernel won't start Rogan Dawes
2010-08-16  8:34 ` Gérald Kerma
2010-08-16  8:38   ` Rogan Dawes
2010-08-16 20:15 ` Rogan Dawes
2010-08-16 20:29   ` Wolfgang Denk
2010-08-16 21:08     ` Rogan Dawes
2010-08-16 21:11       ` [U-Boot] [PATCH] non-working dns323 config Rogan Dawes
2010-08-18 22:23         ` Wolfgang Denk
2010-08-19  5:25           ` Rogan Dawes
2010-08-19  5:35             ` Wolfgang Denk
2010-08-19  6:37               ` Rogan Dawes
2010-08-19  6:49                 ` Wolfgang Denk
2010-08-16 22:03       ` [U-Boot] Debugging why my kernel won't start Wolfgang Denk
2010-08-17  4:30         ` Rogan Dawes
2010-08-17 10:10   ` Albert ARIBAUD
2010-08-17 10:21     ` Rogan Dawes [this message]
2010-08-17 10:41       ` Albert ARIBAUD
2010-08-17 11:19         ` Rogan Dawes
2010-08-17 11:42           ` Rogan Dawes
2010-08-17 15:38             ` Albert ARIBAUD
2010-08-17 19:56               ` Rogan Dawes
2010-08-17 20:09                 ` Rogan Dawes
2010-08-17 21:20                   ` Wolfgang Denk
2010-08-17 21:54                     ` Rogan Dawes
2010-08-17 22:04                       ` Wolfgang Denk
2010-08-17 22:10                         ` Rogan Dawes
2010-08-18  5:51                           ` Wolfgang Denk
2010-08-18  9:48                             ` Rogan Dawes
2010-08-18 10:54                               ` Wolfgang Denk
2010-08-18 14:42                                 ` Rogan Dawes
2010-08-18 15:33                                   ` Wolfgang Denk
2010-08-18 16:32                                     ` Rogan Dawes
2010-08-18 17:00                                       ` Wolfgang Denk
2010-08-17 21:18                 ` Wolfgang Denk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4C6A62AC.6010206@dawes.za.net \
    --to=rogan@dawes.za.net \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox