linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* Moving from 2.4 to 2.6 kernel
@ 2006-05-04 17:32 Chris Dumoulin
  2006-05-04 18:11 ` Grant Likely
  0 siblings, 1 reply; 7+ messages in thread
From: Chris Dumoulin @ 2006-05-04 17:32 UTC (permalink / raw)
  To: linuxppc-embedded

I am trying to take a working embedded linux system from kernel 2.4 to 
2.6. The hardware is a custom board using a Virtex II Pro with PPC405 
processor.
The working system uses u-boot 1.1.1 with linux kernel 2.4.18.

I am using the same u-boot and I am trying to port linux kernel 2.6.15 
to our platform. Using the stuff from the working 2.4 kernel port and 
other PPC4xx platforms in the 2.6.15 code as examples, I believe I have 
done everything required to get the kernel booting. However, the kernel 
seems to hang after being uncompressed. Here is what I see after running 
bootm from u-boot:

## Booting image at 00400000 ...
   Image Name:   Linux-2.6.15 ICS
   Image Type:   PowerPC Linux Kernel Image (gzip compressed)
   Data Size:    605592 Bytes = 591.4 kB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Uncompressing Kernel Image ... OK
## Loading RAMDisk Image at 00800000 ...
   Image Name:   SELF CRD
   Image Type:   PowerPC Linux RAMDisk Image (gzip compressed)
   Data Size:    1430581 Bytes =  1.4 MB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Ramdisk to 03e5c000, end 03fb9435 ... OK

My first thought was that I was simply not setting up the console 
properly, and was not seeing the printk output, but I don't think I'm 
even getting that far. I tried flashing an LED in start_kernel (in the 
file init/main.c) and also in my platform_init function, but I get 
nothing. I think the kernel is hanging somewhere very early on, maybe 
when the MMU is enabled. I tried looking at the log buffer by following 
the steps in section 14.3.3 of the DULG (Linux Post Mortem Analysis), 
but I don't see anything there.

Any ideas would be appreciated.

Regards,
Chris
-- 
*--Christopher Dumoulin--*
Software Team Leader

<http://ics-ltd.com/>
<http://ics-ltd.com/>

Interactive Circuits and Systems Ltd.
5430 Canotek Road
Ottawa, ON
K1J 9G2
(613)749-9241
1-800-267-9794 (USA only)

------------------------------------------------------------------------
This e-mail is private and confidential and is for the addressee only. 
If misdirected, please notify us by telephone and confirm that it has 
been deleted from your system and any hard copies destroyed. You are 
strictly prohibited from using, printing, distributing or disseminating 
it or any information contained in it save to the intended recipient.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-04 17:32 Moving from 2.4 to 2.6 kernel Chris Dumoulin
@ 2006-05-04 18:11 ` Grant Likely
  2006-05-04 19:04   ` Andy Gospodarek
  2006-05-04 19:17   ` Chris Dumoulin
  0 siblings, 2 replies; 7+ messages in thread
From: Grant Likely @ 2006-05-04 18:11 UTC (permalink / raw)
  To: Chris Dumoulin; +Cc: linuxppc-embedded

On 5/4/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
> I am trying to take a working embedded linux system from kernel 2.4 to
> 2.6. The hardware is a custom board using a Virtex II Pro with PPC405
> processor.
> The working system uses u-boot 1.1.1 with linux kernel 2.4.18.
>
> I am using the same u-boot and I am trying to port linux kernel 2.6.15
> to our platform. Using the stuff from the working 2.4 kernel port and
> other PPC4xx platforms in the 2.6.15 code as examples, I believe I have
> done everything required to get the kernel booting. However, the kernel
> seems to hang after being uncompressed. Here is what I see after running
> bootm from u-boot:

The V2pro is already supported in the 2.6 kernel.  Are you using that
code; or starting from scratch?  V2Pro (ML300) and V4FX (ML403) are
both supported in the latest 2.6 kernel.

I had similar problems when I was porting to the V4FX.  Do you have a
JTAG debugger (Like a BDI-2000)?  I think your best bet is to get in
there with a debugger to find out where it goes off into Lala land.

Cheers,
g.

--
Grant Likely, B.Sc. P.Eng.
Secret Lab Technologies Ltd.
(403) 399-0195

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-04 18:11 ` Grant Likely
@ 2006-05-04 19:04   ` Andy Gospodarek
  2006-05-04 19:17   ` Chris Dumoulin
  1 sibling, 0 replies; 7+ messages in thread
From: Andy Gospodarek @ 2006-05-04 19:04 UTC (permalink / raw)
  To: Grant Likely; +Cc: Chris Dumoulin, linuxppc-embedded

On 5/4/06, Grant Likely <grant.likely@secretlab.ca> wrote:
> On 5/4/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
> > I am trying to take a working embedded linux system from kernel 2.4 to
> > 2.6. The hardware is a custom board using a Virtex II Pro with PPC405
> > processor.
> > The working system uses u-boot 1.1.1 with linux kernel 2.4.18.
> >
> > I am using the same u-boot and I am trying to port linux kernel 2.6.15
> > to our platform. Using the stuff from the working 2.4 kernel port and
> > other PPC4xx platforms in the 2.6.15 code as examples, I believe I have
> > done everything required to get the kernel booting. However, the kernel
> > seems to hang after being uncompressed. Here is what I see after runnin=
g
> > bootm from u-boot:
>
> The V2pro is already supported in the 2.6 kernel.  Are you using that
> code; or starting from scratch?  V2Pro (ML300) and V4FX (ML403) are
> both supported in the latest 2.6 kernel.
>
> I had similar problems when I was porting to the V4FX.  Do you have a
> JTAG debugger (Like a BDI-2000)?  I think your best bet is to get in
> there with a debugger to find out where it goes off into Lala land.
>
> Cheers,
> g.
>
> --
> Grant Likely, B.Sc. P.Eng.
> Secret Lab Technologies Ltd.
> (403) 399-0195
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>

You could also try enabling early printk....sometimes that helps tell
you how far you did or didn't get.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-04 18:11 ` Grant Likely
  2006-05-04 19:04   ` Andy Gospodarek
@ 2006-05-04 19:17   ` Chris Dumoulin
  2006-05-04 20:04     ` Grant Likely
  1 sibling, 1 reply; 7+ messages in thread
From: Chris Dumoulin @ 2006-05-04 19:17 UTC (permalink / raw)
  To: Grant Likely; +Cc: linuxppc-embedded

I'm looking into getting a BDI 2000 so I can start stepping through and 
see what is going on.

I looked at the ML300 and V2Pro code in the arch/ppc/platforms/4xx 
folder, but I did not use any of that in my code. It looks like this is 
intended to be used with the BSP that is generated by Xilinx Platform 
Studio. I've tried generating the BSP this way, but the generated code 
is obviously not a complete patch to port Linux to your hardware, and I 
figure that by the time I figure out what I do/don't have to add, I 
might as well write the whole thing by myself. Have you had success 
integrating the automatically generated BSP from Xilinx Platform Studio?

Regards,
Chris

Grant Likely wrote:

> On 5/4/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
>
>> I am trying to take a working embedded linux system from kernel 2.4 to
>> 2.6. The hardware is a custom board using a Virtex II Pro with PPC405
>> processor.
>> The working system uses u-boot 1.1.1 with linux kernel 2.4.18.
>>
>> I am using the same u-boot and I am trying to port linux kernel 2.6.15
>> to our platform. Using the stuff from the working 2.4 kernel port and
>> other PPC4xx platforms in the 2.6.15 code as examples, I believe I have
>> done everything required to get the kernel booting. However, the kernel
>> seems to hang after being uncompressed. Here is what I see after running
>> bootm from u-boot:
>
>
> The V2pro is already supported in the 2.6 kernel.  Are you using that
> code; or starting from scratch?  V2Pro (ML300) and V4FX (ML403) are
> both supported in the latest 2.6 kernel.
>
> I had similar problems when I was porting to the V4FX.  Do you have a
> JTAG debugger (Like a BDI-2000)?  I think your best bet is to get in
> there with a debugger to find out where it goes off into Lala land.
>
> Cheers,
> g.
>
> -- 
> Grant Likely, B.Sc. P.Eng.
> Secret Lab Technologies Ltd.
> (403) 399-0195
>
>


-- 
*--Christopher Dumoulin--*
Software Team Leader

<http://ics-ltd.com/>
<http://ics-ltd.com/>

Interactive Circuits and Systems Ltd.
5430 Canotek Road
Ottawa, ON
K1J 9G2
(613)749-9241
1-800-267-9794 (USA only)

------------------------------------------------------------------------
This e-mail is private and confidential and is for the addressee only. 
If misdirected, please notify us by telephone and confirm that it has 
been deleted from your system and any hard copies destroyed. You are 
strictly prohibited from using, printing, distributing or disseminating 
it or any information contained in it save to the intended recipient.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-04 19:17   ` Chris Dumoulin
@ 2006-05-04 20:04     ` Grant Likely
  2006-05-05 13:39       ` Chris Dumoulin
  0 siblings, 1 reply; 7+ messages in thread
From: Grant Likely @ 2006-05-04 20:04 UTC (permalink / raw)
  To: Chris Dumoulin; +Cc: linuxppc-embedded

On 5/4/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
> I'm looking into getting a BDI 2000 so I can start stepping through and
> see what is going on.
>
> I looked at the ML300 and V2Pro code in the arch/ppc/platforms/4xx
> folder, but I did not use any of that in my code. It looks like this is
> intended to be used with the BSP that is generated by Xilinx Platform
> Studio. I've tried generating the BSP this way, but the generated code
> is obviously not a complete patch to port Linux to your hardware, and I
> figure that by the time I figure out what I do/don't have to add, I
> might as well write the whole thing by myself. Have you had success
> integrating the automatically generated BSP from Xilinx Platform Studio?

No; the stuff in 2.6 is not integrated w/ platform studio.  (only 2.4
is).  However, you do need to extract the xparameters.h file from the
platform studio BSP.  You can generate a Linux BSP w/o actually
telling it where your Linux tree is.  Once its generated; pull out
xparameters.h and drop it into arch/ppc/platforms/4xx/xparameters/ in
your source tree.  Note: it's important that you generate a LINUX BSP;
not a 'standalone' bsp.  If you don't, then you'll be missing a bunch
of #defines.

Let me say that once more for clarity: The only file you need from
platform studio is the generated xparameters.h

This will give you at the very least a serial port driver.  Once your
booting with that, you can focus on other device drivers.

Trust me; this is the path of far less pain.

Cheers,
g.


--
Grant Likely, B.Sc. P.Eng.
Secret Lab Technologies Ltd.
(403) 399-0195

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-04 20:04     ` Grant Likely
@ 2006-05-05 13:39       ` Chris Dumoulin
  2006-05-05 15:31         ` Grant Likely
  0 siblings, 1 reply; 7+ messages in thread
From: Chris Dumoulin @ 2006-05-05 13:39 UTC (permalink / raw)
  To: Grant Likely; +Cc: linuxppc-embedded

Grant Likely wrote:

> On 5/4/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
>
>> I'm looking into getting a BDI 2000 so I can start stepping through and
>> see what is going on.
>>
>> I looked at the ML300 and V2Pro code in the arch/ppc/platforms/4xx
>> folder, but I did not use any of that in my code. It looks like this is
>> intended to be used with the BSP that is generated by Xilinx Platform
>> Studio. I've tried generating the BSP this way, but the generated code
>> is obviously not a complete patch to port Linux to your hardware, and I
>> figure that by the time I figure out what I do/don't have to add, I
>> might as well write the whole thing by myself. Have you had success
>> integrating the automatically generated BSP from Xilinx Platform Studio?
>
>
> No; the stuff in 2.6 is not integrated w/ platform studio.  (only 2.4
> is).  However, you do need to extract the xparameters.h file from the
> platform studio BSP.  You can generate a Linux BSP w/o actually
> telling it where your Linux tree is.  Once its generated; pull out
> xparameters.h and drop it into arch/ppc/platforms/4xx/xparameters/ in
> your source tree.  Note: it's important that you generate a LINUX BSP;
> not a 'standalone' bsp.  If you don't, then you'll be missing a bunch
> of #defines.
>
> Let me say that once more for clarity: The only file you need from
> platform studio is the generated xparameters.h
>
> This will give you at the very least a serial port driver.  Once your
> booting with that, you can focus on other device drivers.
>
> Trust me; this is the path of far less pain.
>
> Cheers,
> g.
>
>
> -- 
> Grant Likely, B.Sc. P.Eng.
> Secret Lab Technologies Ltd.
> (403) 399-0195
>
>
I generated the xparameters_ml300.h file and built my kernel configured 
for the ML300 board, but I still had the same problem. I'm wondering if 
there's something in the hardware that's not being setup by u-boot as 
the linux kernel expects it. I'm looking through the ML300 code in 
u-boot 1.1.4 to see if can spot anything that's being done in there 
that's not being done in my u-boot code. Do you have any ideas about 
some hardware (or other)  initialization that I could be neglecting to 
do in u-boot that might cause things to hang?

On a similar note, is there any guide to porting u-boot that I could 
read that would enumerate all the steps I should be taking in u-boot? I 
know the README in the u-boot source basically says to browse the 
mailing list (which I'm doing), read the DULG (which I've done), and 
read the source (which I'm also doing), but some kind of succinct guide 
would be nice, if it exists.

Cheers,
Chris

-- 
*--Christopher Dumoulin--*
Software Team Leader

<http://ics-ltd.com/>
<http://ics-ltd.com/>

Interactive Circuits and Systems Ltd.
5430 Canotek Road
Ottawa, ON
K1J 9G2
(613)749-9241
1-800-267-9794 (USA only)

------------------------------------------------------------------------
This e-mail is private and confidential and is for the addressee only. 
If misdirected, please notify us by telephone and confirm that it has 
been deleted from your system and any hard copies destroyed. You are 
strictly prohibited from using, printing, distributing or disseminating 
it or any information contained in it save to the intended recipient.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Moving from 2.4 to 2.6 kernel
  2006-05-05 13:39       ` Chris Dumoulin
@ 2006-05-05 15:31         ` Grant Likely
  0 siblings, 0 replies; 7+ messages in thread
From: Grant Likely @ 2006-05-05 15:31 UTC (permalink / raw)
  To: Chris Dumoulin; +Cc: linuxppc-embedded

On 5/5/06, Chris Dumoulin <cdumoulin@ics-ltd.com> wrote:
> I generated the xparameters_ml300.h file and built my kernel configured
> for the ML300 board, but I still had the same problem. I'm wondering if
> there's something in the hardware that's not being setup by u-boot as
> the linux kernel expects it. I'm looking through the ML300 code in
> u-boot 1.1.4 to see if can spot anything that's being done in there
> that's not being done in my u-boot code. Do you have any ideas about
> some hardware (or other)  initialization that I could be neglecting to
> do in u-boot that might cause things to hang?

Probably not;  The nice thing about the V2Pro is that there is pretty
much no setup that needs to be done.  The bitstream takes care of
configuring SDRAM.  :).  For my daily work; I don't even use u-boot.=20
I'm downloading a zImage directly through my BDI 2000.  (But u-boot
does work for me too)

Can you post your xparameters file?  (Or email it to me directly)

Are you using a full UART or UART lite?

> On a similar note, is there any guide to porting u-boot that I could
> read that would enumerate all the steps I should be taking in u-boot? I
> know the README in the u-boot source basically says to browse the
> mailing list (which I'm doing), read the DULG (which I've done), and
> read the source (which I'm also doing), but some kind of succinct guide
> would be nice, if it exists.

Not that I know of; I had to pile throught the same stuff to learn it.

> Interactive Circuits and Systems Ltd.
> 5430 Canotek Road
> Ottawa, ON

Hey; you going to OLS this year?

Cheers,
g.

--
Grant Likely, B.Sc. P.Eng.
Secret Lab Technologies Ltd.
(403) 399-0195

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2006-05-05 15:31 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-05-04 17:32 Moving from 2.4 to 2.6 kernel Chris Dumoulin
2006-05-04 18:11 ` Grant Likely
2006-05-04 19:04   ` Andy Gospodarek
2006-05-04 19:17   ` Chris Dumoulin
2006-05-04 20:04     ` Grant Likely
2006-05-05 13:39       ` Chris Dumoulin
2006-05-05 15:31         ` Grant Likely

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).