summerofcode2014:microblazebringup

This is an old revision of the document!


  • Student: estaszuk at FreeBSD dot org
  • Mentor: gber at FreeBSD dot org

This project is about porting FreeBSD for MicroBlaze architecture. MicroBlaze is a soft-processor which could be embedded as part of FPGA project. It is highly configurable and extensible making good alternative for adding a external CPU core in embedded systems based on FPGA chips. Current aim is to make bootable version of FreeBSD for MicroBlaze with ability to use console by serial interface.

I would like to prepare full bootstrap and kernel loader for MicroBlaze architecture. Current approach assumes using GNU toolchain for building kernel (as it support MicroBlaze target), using CLang is long run goal but not within GSoC. I chose QEMU emulator as test platform. Later real FPGA with embedded MicroBlaze will be used (after kernel loading will be done).

First aim is to load minimal kernel with only basic necessary parts and stubs, next goal is to build necessary drivers.

  • Bootstrap
  • Kernel loader
  • Other architecture dependent parts of FreeBSD code needed to load kernel
  • Stripped kernel configuration proved to proper building
  • GENERIC/DEFAULT kernel configurations
  • Drivers necessary to provide working console

This section will be available until 5th june

  • June 17: Start of coding
  • July 29-August 2: Mid-term Evaluations
  • September 16: End of coding (soft)
  • September 23: End of coding (hard)

At the moment kernel is not able to run. However it can be built and this is the base for future work. Code can be fetched from here: https://socsvn.freebsd.org/socsvn/soc2014/estaszuk/microblaze-head/head/

Building steps are:

This file contains most recent instructions about building current version of FreeBSD for microblaze target

To begin a proper toolchain will be needed. Currently the easiest way to obtain a toolchain is using a bash script './microblaze-gcc/build-toolchain.sh'.

You can then put created install dir whatever you want it. Next edit './src.conf' file and change 'MB-TOOLCHAIN' value to the path where toolchain has been moved (remember about 'bin' subdirectory).

After that type 'make kernel-toolchain' and wait to complete. This step currently does not build microblaze toolchain, but will make some necessary tools for next steps (config, etc.).

Now it's time to set env value 'TARGET_ARCH' to 'microblaze'.

You can change the MAKEOBJDIRPREFIX env if you do not want to use default directory (/usr/obj/microblaze.microblaze).

And finally this can be executed: make SRCCONF=${PWD}/src.conf buildkernel

  • summerofcode2014/microblazebringup.1403787460.txt.gz
  • Last modified: 2014/06/26 12:57
  • by ErnestStaszuk