MPC5121eADS

From openSUSE

Geeko
Warning - This is a work in progress...


Contents

Platform Information

Some information about the board;

  • The MPC5121e is a Power Architecture SoC from Freescale Semiconductor
  • The MPC5121eADS evaluation board includes 512MB of RAM. It was designed by Silicon Turnkey Express who refer to it as the ADS512101.
  • U-Boot is used as firmware, which relies on the kernel/initrd being converted into a special format to be able to boot (mkimage), and a flattened device-tree (FDT) for the board also needs to be loaded.
  • MPC5121e Development is co-sponsored by Genesi and Freescale

Requirements

To get started with installation a number of requirements needs to be met:

  • a "null-modem" serial console cable to reach the machines console during the boot process
  • a terminal software to reach the console (HyperTerminal or PuTTY on Windows or Minicom on Linux)
  • a TFTP server for booting
  • a NFS server for the root partition (if you don't have a Rev 4.0 board)
  • a working fast Internet connection or a local installation server (NFS preferred, but FTP/HTTP also works)

If you have a revision 4.0 board you may install using a local hard disk and even a CDROM connected to the PATA port.

Known Problems

  • when installing openSUSE 11.0, detailed software selection during installation crashes. This can be worked around by using a driver update: just add the following boot parameter (or download the file to a local server, and load from there):
dud=http://download.opensuse.org/update/11.0/driverupdate
  • apparmor and other technologies depending on a newer kernel version or a patched openSUSE kernel don't work
  • the board comes configured for a kernel smaller than 1MB. This needs to be changed:
=> setenv fdt_addr_r 500000
=> setenv ramdisk_addr_r 600000
=> saveenv
  • only drivers necessary to boot the board are compiled into the kernel, as a 2MB+ kernel image does not seem to load, even if the above variable are set to higher values
  • The service nscd eats all CPU -> it is safe to remove it (use insserv -r nscd or zypper to remove it completely)
  • hwinfo does not know about the on-board Ethernet: use manual=2 to be able to set up networking
  • the Ethernet port does not always recognize that a cable is plugged in, power cycling the board usually helps

Board Revision Specific Problems

MPC5121eADS 3.2

  • on-board PATA/SATA adapters do not function correctly, so installation needs to be carried out to an NFS share
  • PATA and PCI conflict on the board level and PCI must be disabled to use the PATA port.
  • USB keyboard / mouse can't be used, as the kernel crashes when the USB support is compiled in or when loaded, so you are pretty much stuck with VNC if you need a desktop (no crash, when latest git kernel is used)
  • U-Boot 1.3.3 and CPLD update to version 0x09 should be downloaded and installed if the board is not already up to this version.
  • As of today (2008-07-23) not all drivers are upstream yet, a modified 2.6.24 kernel can be used from the MPC5121e BSP on Freescale's website
  • One can also use a kernel built from git sources ( http://git.denx.de/linux-mpc512x.git/ ), which is more stable and has more features.

MPC5121eADS 4.0

Early Adopter Boards (shipped before 2008-09-08)
  • Early versions of the V4 board were shipped to early adopters (and a few of the later boards) with a different PATA connector which makes it hard to connect any disk, "shaving" of cables or the PATA connector sheath may be required. Most CompactFlash and Industrial ATA Flash drives will fit without problems.
  • The same early versions of the V4 board come with an older U-Boot firmware and an older CPLD revision, requiring an update which can be found on the Silicon Turnkey Express website. To update the CPLD to revision 0x05 you will need a USB/Parallel programmer for the MAXII CPLD on the board.
  • Batteries may not be installed so the board will not keep time. In previous versions the RTC battery did not work anyway.
Production Revision 4.0 (shipped after 2008-09-08)
  • A design error on the board requires a fix by STx to fix a fuse issue which may disable the PowerVR MBX Lite core and cause the chip to mis-identify. There is an updated U-Boot (a pre-release of U-Boot 2008.10) to install for this issue on the STx website.
All Revision 4.0 boards
  • PATA support requires jumper P11 (next to the PATA connector) to be shorted over pins 2-3 (closest to the PATA connector) to supply current to the connector. However serial resistors specified in the ATA specification are not present so disk support may still be unreliable in certain fairly rare configurations.
  • At the time of writing, the SATA port has no driver, but will be functional as and when it appears (could be as late as 2Q 2009)
  • DIU needs up to date kernel sources from http://git.denx.de/linux-mpc512x.git/ to function and Preemptible Kernel needs to be set instead of the SuSE default Voluntary Kernel Preemption. Otherwise the DIU shows just a gray screen.

Preparations

The ADS512101 ships with U-Boot, which needs to be set up for TFTP booting. For this, the ramdisk image file name and network parameters need to be configured and saved.

=> setenv ramdiskfile /ads5121/uinitrd32
=> setenv ipaddr 192.168.2.181
=> setenv serverip 192.168.2.52
=> setenv gatewayip 192.168.2.52
=> saveenv

Download the files necessary for booting and loading the installer (URL: TBD) to the machine with the TFTP server. Extract it in the servers data directory, usually /tftpboot. The three files are: ads5121/uinitrd32, ads5121/uImage and ads5121/ads5121.dtb.

The supplied kernel is non-modular, all features necessary for booting the machine and for a basic installation are built in. RAID/LVM/Crypto filesystems are not supported, nor are any drivers which are not used in the evaluation system. A kernel based on the current openSUSE 11.0 kernel (2.6.25.9 as at the time of writing) will be made available soon. As the BSP kernel version is different from the one used by openSUSE, warning messages on the screen appear during installation and on first boot. Most of these can be safely ignored for the time being.

The same set of files can be used to install openSUSE 11.0 and openSUSE 11.1 (currently Factory). The later version brought considerable speedup, especially for KDE.

Installation

Installation of openSUSE can be carried out in many different ways. The most convenient is using a network installation source and a remote VNC console. Using the serial console and VNC combined also helps to keep installation simpler and easier to catch problems on the serial console.

The following example shows how to boot the installer using TFTP, based on the net_self macro and adding some openSUSE specific boot parameters for debugging. For more parameters please check the Linuxrc documentation.

=> tftp ${kernel_addr_r} ${bootfile};tftp ${ramdisk_addr_r} ${ramdiskfile};tftp ${fdt_addr_r} ${fdtfile};run ramargs addip addtty
=> setenv bootargs ${bootargs} vnc=1 LinuxrcLog=/dev/console linuxrcdebug=2 install=http://download.opensuse.org/distribution/SL-OSS-factory/inst-source/ manual=2
=> bootm ${kernel_addr_r} ${ramdisk_addr_r} ${fdt_addr_r}

On openSUSE 11.0, don't forget to add the dud parameter if you are planning to make complex package selections.

From here installation of openSUSE almost the same as on any other platforms. First kernel messages are shown on the serial console, then the installer starts. After a few minutes it prints some information how to reach the installer by VNC. A comprehensive walk-through of installation is available: Installation/11.0_DVD_Install. There are some minor differences to note: compared to the walk-through, the switch to stage2 is not as smooth as on x86 as there is no kexec on ppc32, and the boot process is obviously different (see below).

Finishing installation on nfs

Before starting stage2, one can extract the modules archive to the freshly installed system on the NFS server to /lib/modules, which helps to achieve a more pleasant boot experience (no warnings, that modules are missing).

For booting the installed system, a single command is enough:

=> run net_nfs

Before this, one might need to adjust the variable rootpath to the correct path. Those who have their TFTP and NFS servers on separate IP addresses will need to play with U-Boot parameters.

On the first boot second stage of the installation will be executed. It defaults to a completely automatic process, one can watch on VNC what is being configured at the moment. Once it is ready, there is a bug preventing the system from continuing booting, the Ethernet interface is deactivated making the NFS filesystem unavailable. This will also affect system shutdown. Once this message is shown on the serial console, the board can be turned off or rebooted by the combined power/reset button.

Finishing installation on local HDD

On Rev4 board only.

For booting the installed system, one can use the following commands:

=> tftp ${kernel_addr_r} ${bootfile}
=> tftp ${fdt_addr_r} ${fdtfile}
=> setenv bootargs console=ttyPSC0,115200 root=/dev/hda2                       
=> bootm ${kernel_addr_r} - ${fdt_addr_r}

On the first boot second stage of the installation will be executed. It defaults to a completely automatic process, one can watch on VNC what is being configured at the moment. Once ready, modules should be extracted to /lib/modules.

Passed QA check: Fsundermeyer 11:36, 12 June 2009 (UTC)