Skip to contentSkip to conversation

Converting vmlinux.initrd to S-RECORD

DISCUSSION Sebastien Articlaux 7 participants 11 messages Feb 9, 2000 – Mar 6, 2000

lore
Share & tools
lore
#0 lore raw

Hi,
I've just read a message posted by Dan in november. He said that he would post in ppc.kernel.org a prog to convert file into S-Records.

He wrote:
The program just strips the 64K ELF header and converts the rest of the file into S-Records. You can use -h to include the header, in case the file isn't ELF and you want the header. You can use -s to specify a different (hex) start address for the S-records.

I think I need it to resolve my problem... But I don't found it, do you know where it is? Or do you have it? or a similar program?

Thank you very much for your reply.

Sebastien ARTICLAUX

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#1 lore raw
Quoted 2 lines · Sebastien Articlaux

He said that he would post in ppc.kernel.org a prog to convert file into S-Records.

	ppc.kernel.org/embedded
		ftp link -> zsrec.c



	-- Dan

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#2 lore raw
In reply to Sebastien Articlaux

In message <[email protected]> you write:

Quoted 8 lines

I've just read a message posted by Dan in november. He said that he would post in ppc.kernel.org a prog to convert file into S-Records.

He wrote:
The program just strips the 64K ELF header and converts the rest of the file into S-Records. You can

No special tools needed. You have everything you need in your toolbox:

# Strip ELF header
dd if=zImage of=image bs=64k skip=1 # Convert to S-records
objcopy -I binary -O srec image image.srec

Wolfgang Denk

--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: [email protected] Heavier than air flying machines are impossible.
-- Lord Kelvin, President, Royal Society, c. 1895

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#3 lore raw

On-Chip-Debugging for MPC 860 ?

Hi everyone,
I am new to this whole stuff. I'm a student working on diploma thesis.

My goal is to have linux running on MBX board -WITHOUT- EPPC-Bug, booting diskless out of the flash-ROM and having a ramdisk and a flash-filesystem.

I use a intel-linux-host and some days before got some LinuxPPC tools from Wolfgang Denk including working GNU cross-compiler and root filesystem which seem to be really helpful.

I will need some help in the next months ... My first question is:

How to make use of MPC's BDM (with a linux host), if possible via GDB ? I know that I need an adapter cable for the parallel port. Actually I have three of them:

* a so-called "EBDI-Lite" from Motorola
* a "CPU32"-cable which was used for debugging the 68360 with GDB
* a very simple cable according to the suggestions of sergey drashnikov (found in graham stoneys mailing from Jan 27th, which I found really helpful. Graham, what is the URL for your HOWTO ?)

I also know that I need some patches for the GDB. I have tested two variants so far:

* Patches working for 68360 from Greg Ungerer. They look professional but there is no support for the 860 BDM, maybe I could adopt them.
* Patches from Sergey Drashnikov for 860 who are very "quick and dirty" and didn't work out of the box (he tested under FreeBSD only).

What would you suggest to do ? Is there any "ready-to-use"-solution ? I know that there are some commercial tools for Windows (Metrowerks, EST) but what about linux ? I thought about adopting the GDB-BDM patches for 360 to 860, but I cannot evaluate how much work it is.

Any suggestions welcome. Thanks.
Tobias

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#4 lore raw

Re: On-Chip-Debugging for MPC 860 ?

Quoted 3 lines · Tobias Otto-Adamczak

I am new to this whole stuff. I'm a student working on diploma thesis. My goal is to have linux running on MBX board -WITHOUT- EPPC-Bug, booting diskless out of the flash-ROM and having a ramdisk and a flash-filesystem.

Cool project; should be a lot of fun. Please do the world a favour in return, and release your startup code under the GPL when you're done.

Quoted 9 lines

How to make use of MPC's BDM (with a linux host), if possible via GDB ? I know that I need an adapter cable for the parallel port. Actually I have three of them:

* a so-called "EBDI-Lite" from Motorola
* a "CPU32"-cable which was used for debugging the 68360 with GDB
* a very simple cable according to the suggestions of sergey drashnikov (found in graham stoneys mailing from Jan 27th, which I found really helpful. Graham, what is the URL for your HOWTO ?)

Glad you found it helpful; that's just the inspiration I need to keep updating it. I don't have it up on the 'net yet; I was hoping to get it (or at least a link to it) put on the "Linux/PPC on Embedded Systems" home page. One problem is putting it somewhere I can update easily & frequently.

Anyway, as far as BDM goes...

Quoted 2 lines

* Patches from Sergey Drashnikov for 860 who are very "quick and dirty" and didn't work out of the box (he tested under FreeBSD only).

I believe this is currently the only option for doing it under Linux. I'd be interested if anyone knows whether Sergey's cable is compatible with any of the simple commercal ones, for those of us who would rather buy something off- the-shelf.

Here's an updated snippet from my HOWTO:

GDB support for PowerPC BDM under Linux isn't yet available. See the thread:
http://www.oarcorp.com/rtems/freesupport/rtemslistArchive/1999/july/msg00057.htm
l

There are many sources of BDM hardware probes and debuggers:

Macraigor Systems: http://www.macraigor.com/
Currently only support Windoze platform, but say Linux support should be available sometime in Q1 2000. Beware that the 1999 version of OCD Commander silently truncates S-records longer than 20 bytes during download.

The Cygwin version of gdb can use the Macraigor DLL, if you're prepared to do your debugging under Windoze.

Build your own: http://cyclone.parad.ru/ppcdbm/

Commercial solutions, none of which support a Linux development host:
Mentor (X-ray):
http://www.mentor.com/embedded/xray/index.html

Huntsville Microsystems (SourceGate):
http://www.hmi.com/bmd.htm

Tasking (CrossView Pro):
http://www.tasking.com/products/PPC/ppcsolution.htm#debugger

SDS (SingleStep):
http://www.sdsi.com/product/powerpc/index.php3#power

Applied Microsystems (PowerTap):
http://www.amc.com/products/powertap.html

EST Corporation:
http://www.estc.com/

Quoted 4 lines

What would you suggest to do ? Is there any "ready-to-use"-solution ? I know that there are some commercial tools for Windows (Metrowerks, EST) but what about linux ? I thought about adopting the GDB-BDM patches for 360 to 860, but I cannot evaluate how much work it is.

If you don't need it right away, my suggestion would be to wait until you do. Things may well have changed by then as far as Linux support goes.

Regards,
Graham

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#5 lore raw

Re: On-Chip-Debugging for MPC 860 ?

Quoted 1 line · Graham Stoney

GDB support for PowerPC BDM under Linux isn't yet available.....

The HMI BMDs for 8xx/5xx/4xx series work just fine with GDB on any host platform. There are many others supported as well, just take a look at all of the remote-* devices in the GDB sources.

	-- Dan

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#6 lore raw

Re: On-Chip-Debugging for MPC 860 ?

Quoted 3 lines
Quoted 1 line · Graham Stoney

GDB support for PowerPC BDM under Linux isn't yet available.....

Quoted 3 lines · Dan Malek

The HMI BMDs for 8xx/5xx/4xx series work just fine with GDB on any host platform. There are many others supported as well, just take a look at all of the remote-* devices in the GDB sources.

Which remote device do the HMI BMDs interface to? I can't see any mention of them in the latest gdb snapshots on sourceware. The only remote- device I can see which supports PowerPC BDM is the Macraigor one in ppc-bdm.c. This uses ocd.c, which which relies on Macraigor's WIGGLERS.DLL and hence will only run under Windows. I'm getting desperate though, so if anyone knows of a pre-built gdb which supports the Macraigor Raven, please let me know, even if it only does runs under Windoze.

Thanks,
Graham

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#7 lore raw

Re: On-Chip-Debugging for MPC 860 ?

Quoted 3 lines · Graham Stoney

Which remote device do the HMI BMDs interface to? I can't see any mention of them in the latest gdb snapshots on sourceware.

Download the patches from their website, then. I think it is ftp.hmi.com.....If you still can't find them, let me know and when I return home after travelling this week I will send them to you.

	-- Dan

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#8 lore raw

Performance 2.2.13 and USB work

In reply to Graham Stoney

We've been using 2.2.5 and wanted to move up to 2.2.13

So, we made a diff on all changes we've done on Malek's 2.2.5 and applied that to 2.2.13.
We then ran a test on it and found 2.2.13 was 3 times slower than 2.2.5!

We haven't analyzed what made the difference (or in fact what changes we've introduced to 2.2.13 with the patch, other than the reported conflicts).

Is there anyone that experienced the same fenomena? What might be the reason for this?

USB,
We've been working on an USB host controller interface for the MPC850 and now it works with the ACM driver. It doesn't support URB for now.

Cheers
Bjorn
--
Björn Lundberg, Coach R&D
Honeywell INUcontrol / H&BC, SW10
Tel: +46 (0)33 23 23 85 Fax: +46 (0)33 23 23 10
[email protected] www.inu.se

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#9 lore raw

Re: Performance 2.2.13 and USB work

Quoted 6 lines · Björn Lundberg

We've been using 2.2.5 and wanted to move up to 2.2.13

So, we made a diff on all changes we've done on Malek's 2.2.5 and applied that to 2.2.13.
We then ran a test on it and found 2.2.13 was 3 times slower than 2.2.5!

Quoted 6 lines

We haven't analyzed what made the difference (or in fact what changes we've introduced to 2.2.13 with the patch, other than the reported conflicts).

Is there anyone that experienced the same fenomena? What might be the reason for this?

The fact that Dan's 2.2.13 uses write through cache is one thing that will affect performance. Grep for DC_SFWT in kernel/head.S and change the #if 0 to #if 1.

I don't know if that's the only reason, but we don't get any performance degradation here with 2.2.13.

//Marcus
--
Signature under construction, please come back later.

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#10 lore raw

Re: Performance 2.2.13 and USB work

Quoted 3 lines · Marcus Sundberg

The fact that Dan's 2.2.13 uses write through cache is one thing that will affect performance. Grep for DC_SFWT in kernel/head.S and change the #if 0 to #if 1.

I did this because many people were using the standard distribution libraries, which don't work with copyback enabled.

For a real treat, download the linuxplanet-2.2.13 kernel sources from MontaVista. It includes some configuration options that will be in the 2.3.xx sources once I get them to compile :-). For example, the copyback cache and 860 Rev. B cpu6 silicon errata are configurable.

	-- Dan

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/