[meta-xilinx] meta-zynq

Edward Vidal vidal.develone at gmail.com
Wed Jan 8 10:21:50 PST 2014


Hi all,
First I would like to thank all who have provided help in the kernel and
u-boot problem.  The work of Mike Looijmans and Philip Balister has not
only helped with u-boot & kernel,  but with bitbake & git also.

Any and all help is welcomed.

I also have not been sucessful in reading the autorun.scr at boot time.
testing Mike Looijmans layer meta-zynq which is a fork of meta-xilinx
with dora
My first build of u-boot-zynq appeared to have 2013.01 error Controller
never released inhibit bit(s) error. I started looking at the
/home/vidal/POKY/zynq_looijmans/poky/meta-zynq/conf/machine/zedboard.conf
to see where to see where the 2013.01 for u-boot was set but found that UBI
parameters were uncommented and u-boot parameters were commented
#UBOOT_MACHINE = "zynq_zed_config"
#UBOOT_ENTRYPOINT = "0x40000000"
#UBOOT_LOADADDRESS = "0x40000000"

MKUBIFS_ARGS = "-m 1 -e 65408 -c 440"
UBINIZE_ARGS = "-m 1 -p 64KiB"
UBI_VOLNAME = "qspi-rootfs"
I uncomment the u-boot parameters and commented the UBI parameters see
above.
Same u-boot 2013.01 error Controller never released inhibit bit(s) error.
My older  2013.07 BOOT.BIN was used test the reading of autorun.scr.
The follow are the steps that I follow to test meta-zynq with poky.


The following repo meta-zynq was forked from https://github.com/milosoftwareto
https://github.com/develone 01/07/14

/home/vidal/develone_github/meta-zynq
commit b0090af372ef256a851086423ee490a443268248
Author: Mike Looijmans <mike.looijmans at topic.nl>
Date:   Tue Jan 7 11:13:09 2014 +0100

    linux-milo: Fix QSPI flash

    Grab the commit that fixes the flash.

cd ~/POKY
mkdir zynq_looijmans
cd zynq_looijmans/
cp -R ../test_meta/kernel_poky/poky/ .
cd poky
git checkout -b dora origin/dora
commit 9cea2e49d025a5493b43f826b69deca09bc9f400
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
Date:   Mon Dec 2 17:41:58 2013 +0000

    bitbake: imagedetailspage: Fix crash with more than 15 layers

    If you had more than 15 layers the system would crash since one more
    value is added to one array than the other. This fixes the code
    so equal numbers of values are added to the arrays and hence
    doesn't crash when many layers are enabled.

    (Bitbake rev: ae420d37fd57a567cf3d2d8096cc9aa28ed01385)

    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
cp -R ~/develone_github/meta-zynq/ .
cd meta-zynq
git checkout -b 3.12 origin/kernel-3.12
commit 7a9ac02de989865595105a0bd1b48769978d4f5d
Author: Mike Looijmans <mike.looijmans at topic.nl>
Date:   Thu Dec 5 15:47:25 2013 +0100

    zedboard: Add PModOLED to drivers in defconfig

    Build the OLED driver as module so that the logo is displayed once more.
cd ../
. oe-init-build-env
fix the local.conf and bblayers.conf
MACHINE=zedboard bitbake virtual/kernel
Build Configuration:
BB_VERSION        = "1.20.0"
BUILD_SYS         = "x86_64-linux"
NATIVELSBSTRING   = "Fedora-19"
TARGET_SYS        = "arm-poky-linux-gnueabi"
MACHINE           = "zedboard"
DISTRO            = "poky"
DISTRO_VERSION    = "1.5.1"
TUNE_FEATURES     = "armv7a vfp neon"
TARGET_FPU        = "vfp-neon"
meta
meta-yocto        = "dora:9cea2e49d025a5493b43f826b69deca09bc9f400"
meta-zynq         = "3.12:7a9ac02de989865595105a0bd1b48769978d4f5d"
meta-yocto-bsp    = "dora:9cea2e49d025a5493b43f826b69deca09bc9f400"

Variables needed in local.conf for BOOT.BIN generation
MACHINE ?= "zedboard"
ZYNQ_BOOTGEN = "bootgen"
BOARD_DESIGN_URI = "git://ws009://home/vidal/test_file_git"
ZYNQ_BITFILE = "/home/vidal/yocto010514/system.bit"

This file as downloaded during the u-boot-zynq build
/home/vidal/POKY/zynq_looijmans/poky/build/tmp/work/zedboard-poky-linux-gnueabi/u-boot-zynq/xilinx-zynq-r5/fsbl.elf


md5sum fsbl.elf
838e23bf26e5b61928fcbe07d3de8761  fsbl.elf

This file was generated to create a BOOT.BIN
/home/vidal/POKY/zynq_looijmans/poky/build/tmp/work/zedboard-poky-linux-gnueabi/u-boot-zynq/xilinx-zynq-r5/git/bootimage.bif
the_ROM_image:
{
 [bootloader]/home/vidal/POKY/zynq_looijmans/poky/build/tmp/work/zedboard-poky-linux-gnueabi/u-boot-zynq/xilinx-zynq-r5/fsbl.elf
 /home/vidal/yocto010514/system.bit
 [load = 0x04000000, startup =
0x04000000]/home/vidal/POKY/zynq_looijmans/poky/build/tmp/work/zedboard-poky-linux-gnueabi/u-boot-zynq/xilinx-zynq-r5/git/u-boot.bin
}
MACHINE=zedboard bitbake sd-bootscript generates the file
/zynq_looijmans/poky/build/tmp/deploy/images/zedboard/autorun.scr
mkimage -l  tmp/deploy/images/zedboard/autorun.scr
Image Name:   autorun
Created:      Wed Jan  8 09:35:06 2014
Image Type:   ARM Linux Script (uncompressed)
Data Size:    271 Bytes = 0.26 kB = 0.00 MB
Load Address: 00000000
Entry Point:  00000000
Contents:
   Image 0: 263 Bytes = 0.26 kB = 0.00 MB
which uses the file
/zynq_looijmans/poky/meta-zynq/recipes-bsp/bootscripts/sd-bootscript/autorun.scr
echo "Load kernel from SD card..."
fatload mmc 0 ${kernel_addr} ${kernel_image}
fatload mmc 0 0x2A00000 ${devicetree_image}
setenv bootargs "console=ttyPS0,115200 root=/dev/mmcblk0p2 rw
rootfstype=ext4 rootwait"
echo "Booting..."
bootm ${kernel_addr} - 0x2A00000
The follow is just for determining how the script is loaded into the binary
file autoscr.scr
0000040 0000 0701 0000 0000 6365 6f68 2220 6f4c --> echo "Load kernel from
SD card..."
0000050 6461 6b20 7265 656e 206c 7266 6d6f 5320
0000060 2044 6163 6472 2e2e 222e 660a 7461 6f6c

00000a0  6d6d 2063 2030 7830 4132 3030 3030 2030 --> 0x2A00000

0000140  7d72 2d20 3020 3278 3041 3030 3030 000a --> 0x2A00000
[root at sim4 ~]# cp /home/vidal/zynq_looijmans_files/BOOT.bin
/run/media/vidal/ZED_BOOT/BOOT.BIN
cp: overwrite ‘/run/media/vidal/ZED_BOOT/BOOT.BIN’? y
[root at sim4 ~]# cp /home/vidal/zynq_looijmans_files/uImage
/run/media/vidal/ZED_BOOT/
cp: overwrite ‘/run/media/vidal/ZED_BOOT/uImage’? y
[root at sim4 ~]# cp
/home/vidal/zynq_looijmans_files/uImage-zynq-zed-adv7511.dtb
/run/media/vidal/ZED_BOOT/devicetree.dtb
cp: overwrite ‘/run/media/vidal/ZED_BOOT/devicetree.dtb’? y
[root at sim4 ~]# cp /home/vidal/zynq_looijmans_files/uImage
/run/media/vidal/ROOT_FS/boot/
cp /home/vidal/zynq_looijmans_files/autorun.scr /run/media/vidal/ZED_BOOT/

Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-xilinx/attachments/20140108/eecab531/attachment.html>


More information about the meta-xilinx mailing list