Home arrow Linix - How to arrow Custom Linux: A Porting Guide

Language Translator

Hacking Zone

Hacking Tools
Attacking

Configure Windows

Windows Configuration

Mix Tutorials

Asterisk
Website Building

Novels

Mix Novels

Human Personality

Body Language
Custom Linux: A Porting Guide Print E-mail
Article Index
Custom Linux: A Porting Guide
Page 2
Page 3
Page 4
Page 5

Custom Linux: A Porting Guide :

Porting LinuxPPC to a Custom SBC

 

              This guide describes a work in progress, to port Linux to a custom PowerPC-based board. This means making the operating system work on unfamiliar hardware. Anyone who is on the same track might benefit from reading this paper, as it highlights the pitfalls and problematic points along the way.
 

Chapter 1. Introduction

1.1. Who needs to read this ?

This guide describes a work in progress, to port Linux to a custom PowerPC-based board. This means making the operating system work on unfamiliar hardware. Anyone who is on the same track might benefit from reading this paper, as it highlights the pitfalls and problematic points along the way.


1.2. What do I need to know (why so much) ?

Before attempting to port Linux, know at least the following: (whenever possible, a link to a proper information source is attached)

  • Hardware: know what hardware you've got, how it works (if it works), and how is it initialized. Get all the hardware manuals you can - you'll probably need them. Also, never assume the hardware works the way it supposed to ! Hardware people do the darnest things :-(

  • Basic understanding of drivers and how they work in Linux. Programming knowledge of simple drivers is an advantage - but not a must. http://www.tldp.org/HOWTO/Module-HOWTO/index.html

  • How to work with Vision-ICE, how configure it and use it to load a binary kernel into the target RAM. Also, at the beginning, you'll need to know how to use ICE to debug in assembly.

  • How to compile and configure a Linux kernel. http://www.tldp.org/HOWTO/Kernel-HOWTO.html

  • The Linux boot process. http://www.tldp.org/HOWTO/BootPrompt-HOWTO.html

  • Working knowledge of C programming is a must. Some assembly is sure to help. Also, it is best to get to know Makefiles. They tend to raise their ugly head once in a while.

  • The Internet is your friend. All the information you need is probably on the net. You just have to know how to find it. Google is a good way to start; mailing lists and news groups usually keep the real gold.

  • How to install Linux, configure it, administrate it and basically take care of everything it needs. This guide does not cover anything regarding system administration, setting up a server etc.


1.3. The tools

This section describes the tools we used during the process. Most are trivial to install and use. When neccesary, consult the appropriate url or manual.

  • HardHat Linux: First and foremost, HHLinux, now known as MontaVista Linux, is the distribution we started with. The distribution contains LSPs (same as BSPs) for PowerPC in a number of board configurations. For porting to our board, we took the LSP which is closest in hardware to our Artysyn PMPPC board, and started from there.

  • LXR: This is THE killer tool, which allowed us to port Linux in a very short time. LXR is a cross referencer, which means it reads a piece of code (the Linux kernel, for example), and then allows browsing the code, searching through it and much more. I cannot emphasize enough how important this tool is. To see what the end result looks like, look at http://lxr.linux.no/source. LXR itself can be downloaded at http://lxr.sf.net

  • VisionICE: A hardware debugger, which has the ability to stop, run and add breakpoint straight in the CPU. VisionIce is very usuful when no operating system is running, and allows to step in the kernel during boot process. The application can also be used to take a binary image of a kernel, load it into the target's RAM memory and run it - useful when you've got no boot loader.

  • CVS: A version control system, allows you to keep multiple versions of the code. Other than backing up the code, it allows diffing between different version, and reverting to older version, when needed.

  • A terminal program, like HyperTerminal or ProCOMM for Windows™, or minicom for Linux.


1.4. The hardware

The board is based on PPC750 (PowerPC) processor. It is 6U VME64 standard. The board is designed to host two PCI Mezzanine cards (CCPMC) - Mezzanine cards that comply with Std CCPMC1386 can be attached.

  • COP connector.

  • 1 MB of L2 cache.

  • CPC700 system controller.

  • 128 MB SDRAM with ECC.

  • Flash memory, divided to boot flash and user flash.

  • NVRAM memory.

  • I/O discretes.

  • RS232 channels.

  • General purpose registers.

  • PCI 2.1 local bus.

  • 10/100 BaseT ethernet channel.

  • VME64 system bus.


1.5. Copyright & License

Copyright (c) 2002 Shie Elrich

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in Appendix A.


 
< Prev   Next >
Your Ad Here

Donate us!!

Enter Amount:

RSS socialnet

Add to MyYahoo!
Subscribe in NewsGator Online
Add to Newsburst
Add to Google
Add to My AOL
Add to Pluck
Subscribe in FeedLounge
Add to Windows Live
Add to NetVibes
Subscribe in Rojo
Subscribe in Bloglines
Add to MyMSN
Add to Plusmo for your cellphone
Add to PageFlakes
Add to Technorati
Add to BlinkBits
get a cheap conveyance online today