読者です 読者をやめる 読者になる 読者になる

ぼくの技術日誌

日誌って銘打っていますが、更新頻度が…

ZedboardでPetalinux 2015.4を動かす

はじめに

以前、一度PetaLinux 2014.2をビルドをしてみようとしたものの、途中でやめてしまいました。
思い出したかのようにまたやろうして調べてみると、新しいバージョン(PetaLinux 2015.4)がリリースされていたので、環境構築からやり直すことにしました。


この記事の実行環境は下記のとおりです。

ビルド環境の構築

必要なパッケージのインストール

PetaLinux Reference Guideや他のインストール手順を参考に下記のパッケージをインストールします。

yosuke@yosuke-vm:~$ sudo apt-get install tofrodos iproute tftpd-hpa gawk gcc git-core make net-tools libncurses5-dev zlib1g-dev libssl-dev flex bison lib32z1 lib32ncurses5 lib32bz2-1.0 lib32stdc++6 libselinux1

PetaLinux SDKのインストール

Xilinx公式ページから、SDKのインストール用シェルスクリプトをダウンロードします。

シェルスクリプトを実行し、SDKをインストールします。
シェルの引数でSDKのインストール先ディレクトリを指定することができます。
今回は/opt/petalinuxにインストールを行いました。余談ですが、Xilinxの開発ツールであるVivadoを標準インストールすると、/optに入ります。

yosuke@yosuke-vm:~$ sudo mkdir /opt/petalinux/
yosuke@yosuke-vm:~$ sudo mv ~/petalinux-v2015.4-final-installer-dec.run /opt/petalinux/
yosuke@yosuke-vm:~$ cd /opt/petalinux/
yosuke@yosuke-vm:/opt/petalinux$ sudo chmod +x petalinux-v2015.4-final-installer-dec.run 
yosuke@yosuke-vm:/opt/petalinux$ sudo ./petalinux-v2015.4-final-installer-dec.run 
INFO: Checking installer checksum...
INFO: Extracting PetaLinux installer...
INFO: Installing PetaLinux...
*********************************************
WARNING: You haven't specified the installation location.
*********************************************
*********************************************
WARNING: By default, it will be installed in your working directory: /opt/petalinux
*********************************************
Please input "y" to proceed the installation, exit otherwise:y
INFO: Checking PetaLinux installer integrity...
INFO: Extracting Installation files...

LICENSE AGREEMENTS

PetaLinux SDK contains software from a number of sources.  Please review
the following licenses and indicate your acceptance of each to continue.

You do not have to accept the licenses, however if you do not then you may 
not use PetaLinux SDK.

Use PgUp/PgDn to navigate the license viewer, and press 'q' to close

Press Enter to display the license agreements
Do you accept Xilinx End User License Agreement? [y/N] > y
Do you accept Webtalk Terms and Conditions? [y/N] > y
Do you accept Third Party End User License Agreement? [y/N] > y
INFO: Checking installation environment requirements...
INFO: Checking free disk space
INFO: Checking installed tools
INFO: Checking installed development libraries
INFO: Checking network and other services
INFO: Installing PetaLinux SDK to "/opt/petalinux/petalinux-v2015.4-final"
INFO: PetaLinux SDK has been installed to /opt/petalinux/petalinux-v2015.4-final
yosuke@yosuke-vm:/opt/petalinux$ 

sourceコマンドを実行します。これで環境変数SDKのパスが登録されるようです。
と、その前にUbuntuのシェルをdashからbashへ変更します。下記コマンドを実行後、「いいえ」を選択します。

yosuke@yosuke-vm:~$ sudo dpkg-reconfigure dash

以降のビルドはsuユーザーで実行します。
sourceコマンドを実行すると、下記の表示が出ます。

yosuke@yosuke-vm:~$ sudo su
[sudo] password for yosuke: 
root@yosuke-vm:/home/yosuke# source /opt/petalinux/petalinux-v2015.4-final/settings.sh
PetaLinux environment set to '/opt/petalinux/petalinux-v2015.4-final'
INFO: Checking free disk space
INFO: Checking installed tools
INFO: Checking installed development libraries
INFO: Checking network and other services
root@yosuke-vm:~/$

PetaLinuxプロジェクトの作成

次にビルドの対象となるプロジェクトを作成します。
先程、PetaLinux SDKをダウンロードしたページから、Zedboard用のbsp(Board Support Package)をダウンロードします。

petalinux-createコマンドを実行してプロジェクトを生成します。コマンド引数にはダウンロードしたbspを入力します。

root@yosuke-vm:/opt/petalinux# mkdir build
root@yosuke-vm:/opt/petalinux# cd build/
root@yosuke-vm:/opt/petalinux/build# petalinux-create -t project -s /opt/petalinux/Avnet-Digilent-ZedBoard-v2015.4-final.bsp 
INFO: Create project: 
INFO: Projects: 
INFO: 	* Avnet-Digilent-ZedBoard-2015.4
INFO: has been successfully installed to /opt/petalinux/build/
INFO: New project successfully created in /opt/petalinux/build/
root@yosuke-vm:/opt/petalinux/build# cd Avnet-Digilent-ZedBoard-2015.4/

ビルド実行

作成したプロジェクトのディレクトリに移ってビルド用のコマンドを実行します。

root@yosuke-vm:/opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4# LANG=C petalinux-build
INFO: Checking component...
INFO: Generating make files and build linux
INFO: Generating make files for the subcomponents of linux
INFO: Building linux
[INFO ] pre-build linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] pre-build linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] pre-build linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] pre-build linux/rootfs/rpmsg_user_dev_driver
[INFO ] pre-build linux/rootfs/echo_test
[INFO ] pre-build linux/rootfs/fwupgrade
[INFO ] pre-build linux/rootfs/mat_mul_demo
[INFO ] pre-build linux/rootfs/peekpoke
[INFO ] pre-build linux/rootfs/proxy_app
[INFO ] build system.dtb
[INFO ] build linux/kernel
[INFO ] generate linux/u-boot configuration files
[INFO ] update linux/u-boot source
[INFO ] build linux/u-boot
[INFO ] build zynq_fsbl
[INFO ] Setting up stage config
[INFO ] Setting up rootfs config
[INFO ] Updating for cortexa9-vfp-neon
[INFO ] Updating package manager
[INFO ] Expanding stagefs
[INFO ] build kernel in-tree modules
[INFO ] modules linux/kernel
[INFO ] build linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] modules linux/kernel
[INFO ] build linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] modules linux/kernel
[INFO ] build linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] modules linux/kernel
[INFO ] build linux/rootfs/rpmsg_user_dev_driver
[INFO ] modules linux/kernel
[INFO ] build linux/rootfs/echo_test
[INFO ] build linux/rootfs/fwupgrade
[INFO ] build linux/rootfs/mat_mul_demo
[INFO ] build linux/rootfs/peekpoke
[INFO ] build linux/rootfs/proxy_app
[INFO ] post-build linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] post-build linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] post-build linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] post-build linux/rootfs/rpmsg_user_dev_driver
[INFO ] post-build linux/rootfs/echo_test
[INFO ] post-build linux/rootfs/fwupgrade
[INFO ] post-build linux/rootfs/mat_mul_demo
[INFO ] post-build linux/rootfs/peekpoke
[INFO ] post-build linux/rootfs/proxy_app
[INFO ] pre-install linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] pre-install linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] pre-install linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] pre-install linux/rootfs/rpmsg_user_dev_driver
[INFO ] pre-install linux/rootfs/echo_test
[INFO ] pre-install linux/rootfs/fwupgrade
[INFO ] pre-install linux/rootfs/mat_mul_demo
[INFO ] pre-install linux/rootfs/peekpoke
[INFO ] pre-install linux/rootfs/proxy_app
[INFO ] install system.dtb
[INFO ] install linux/kernel
[INFO ] generate linux/u-boot configuration files
[INFO ] update linux/u-boot source
[INFO ] build linux/u-boot
[INFO ] install linux/u-boot
[INFO ] Expanding rootfs
[INFO ] install sys_init
[INFO ] install kernel in-tree modules
[INFO ] modules_install linux/kernel
[INFO ] install linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] modules_install linux/kernel
[INFO ] install linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] modules_install linux/kernel
[INFO ] install linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] modules_install linux/kernel
[INFO ] install linux/rootfs/rpmsg_user_dev_driver
[INFO ] modules_install linux/kernel
[INFO ] install linux/rootfs/echo_test
[INFO ] install linux/rootfs/fwupgrade
[INFO ] install linux/rootfs/mat_mul_demo
[INFO ] install linux/rootfs/peekpoke
[INFO ] install linux/rootfs/proxy_app
[INFO ] post-install linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] post-install linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] post-install linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] post-install linux/rootfs/rpmsg_user_dev_driver
[INFO ] post-install linux/rootfs/echo_test
[INFO ] post-install linux/rootfs/fwupgrade
[INFO ] post-install linux/rootfs/mat_mul_demo
[INFO ] post-install linux/rootfs/peekpoke
[INFO ] post-install linux/rootfs/proxy_app
[INFO ] package rootfs.cpio to /opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4/images/linux
[INFO ] Update and install vmlinux image
[INFO ] vmlinux linux/kernel
[INFO ] install linux/kernel
[INFO ] package zImage
[INFO ] zImage linux/kernel
[INFO ] install linux/kernel
[INFO ] Package HDF bitstream
root@yosuke-vm:/opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4# 

自分のUbuntuの言語は日本語だったのですが、英語以外の環境?(少なくとも日本語環境)でビルドを実行すると、途中で以下のエラーになってビルドが終了してしまいます。

root@yosuke-vm:/opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4# petalinux-build
INFO: Checking component...
<略>
[INFO ] post-install linux/rootfs/rpmsg_echo_test_kern_app
[INFO ] post-install linux/rootfs/rpmsg_mat_mul_kern_app
[INFO ] post-install linux/rootfs/rpmsg_proxy_dev_driver
[INFO ] post-install linux/rootfs/rpmsg_user_dev_driver
[INFO ] post-install linux/rootfs/echo_test
[INFO ] post-install linux/rootfs/fwupgrade
[INFO ] post-install linux/rootfs/gpio-demo
[INFO ] post-install linux/rootfs/mat_mul_demo
[INFO ] post-install linux/rootfs/peekpoke
[INFO ] post-install linux/rootfs/proxy_app
[INFO ] package rootfs.cpio to /opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4/images/linux
[INFO ] Update and install vmlinux image
[INFO ] vmlinux linux/kernel
[INFO ] install linux/kernel
[INFO ] package zImage
[INFO ] zImage linux/kernel
[INFO ] install linux/kernel
[ERROR] ERROR: Invalid ELF file '/opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4/images/linux/vmlinux'
ERROR: Failed to build linux
root@yosuke-vm:/opt/petalinux/build/Avnet-Digilent-ZedBoard-2015.4# 

はじめはネットでエラーを検索した結果から、32bit系パッケージが足らないのが原因ではないかと疑って色々入れてみたり、環境を作り直したりしたのですが、解決せず…
結果的にはLANG=Cを付けて実行することでビルドを完了することができました!

他のpetalinuxコマンドを使うことでkernelのみのビルドを行ったり、menuconfigを出してビルドの設定を変更したりすることができます。

起動

ビルドしてできたイメージファイルをSDカードへ書き込み、Zedboardで起動させます。
SDカードはfatでフォーマットし、プロジェクトの/images/linuxの中にあるBOOT.binとimage.ubを順番にコピーします。

BOOT.binはbitstreamとFSBL、u-bootをひとつのバイナリに結合したもので、image.ubはkernelとrootfs、デバイスツリーのようです。

ZedboardにSDカードを挿入し、電源を投入します。この際、Zedboardのジャンパを切り替えてブートの設定を変更する必要があります。
Zedboard上のUSBシリアルの口をPCに接続し、シリアルターミナルを起動します。
シリアルターミナルのボーレートを115200bpsに設定すると、ブートログとログイン画面を見ることができます。

minicom へようこそ 2.7

オプション: I18n 
コンパイルされた日時は:  Jan  1 2014, 17:13:19.
ポート /dev/ttyACM0, 15:39:47

CTRL-A Z を押すと、説明画面になります。



U-Boot 2015.07 (Feb 03 2016 - 14:17:01 +0900)

DRAM:  ECC disabled 512 MiB
MMC:   zynq_sdhci: 0
SF: Detected S25FL256S_64K with page size 256 Bytes, erase size 64 KiB, total 3B
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   Gem.e000b000
U-BOOT for Avnet-Digilent-ZedBoard-2015_4
                                                                                
Gem.e000b000 Waiting for PHY auto negotiation to complete......... TIMEOUT !    
Gem.e000b000: No link.                                                          
Hit any key to stop autoboot:  0                                                
Device: zynq_sdhci                                                              
Manufacturer ID: 89                                                             
OEM: 303                                                                        
Name: NCard                                                                     
Tran Speed: 50000000                                                            
Rd Block Len: 512                                                               
SD version 3.0                                                                  
High Capacity: Yes                                                              
Capacity: 3.7 GiB                                                               
Bus Width: 4-bit                                                                
Erase Group Size: 512 Bytes                                                     
reading image.ub                                                                
6730232 bytes read in 605 ms (10.6 MiB/s)                                       
## Loading kernel from FIT Image at 01000000 ...                                
   Using 'conf@1' configuration                                                 
   Verifying Hash Integrity ... OK                                              
   Trying 'kernel@1' kernel subimage                                            
     Description:  PetaLinux Kernel                                             
     Type:         Kernel Image                                                 
     Compression:  gzip compressed                                              
     Data Start:   0x010000f0                                                   
     Data Size:    6714052 Bytes = 6.4 MiB                                      
     Architecture: ARM                                                          
     OS:           Linux                                                        
     Load Address: 0x00008000                                                   
     Entry Point:  0x00008000                                                   
     Hash algo:    crc32                                                        
     Hash value:   953b9274                                                     
   Verifying Hash Integrity ... crc32+ OK                                       
## Loading fdt from FIT Image at 01000000 ...                                   
   Using 'conf@1' configuration                                                 
   Trying 'fdt@1' fdt subimage                                                  
     Description:  Flattened Device Tree blob                                   
     Type:         Flat Device Tree                                             
     Compression:  uncompressed                                                 
     Data Start:   0x01667498                                                   
     Data Size:    14882 Bytes = 14.5 KiB                                       
     Architecture: ARM                                                          
     Hash algo:    crc32                                                        
     Hash value:   af256fdb                                                     
   Verifying Hash Integrity ... crc32+ OK                                       
   Booting using the fdt blob at 0x1667498                                      
   Uncompressing Kernel Image ... OK                                            
   Loading Device Tree to 07ff9000, end 07fffa21 ... OK                         
                                                                                
Starting kernel ...                                                             
                                                                                
Booting Linux on physical CPU 0x0                                               
Linux version 4.0.0-xilinx (root@ssd-vm) (gcc version 4.9.2 (Sourcery CodeBench6
CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5387d                 
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache        
Machine model: Avnet-Digilent-ZedBoard-2015.4                                   
bootconsole [earlycon0] enabled                                                 
cma: Reserved 16 MiB at 0x1f000000                                              
Memory policy: Data cache writealloc                                            
PERCPU: Embedded 11 pages/cpu @debce000 s12672 r8192 d24192 u45056              
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048     
Kernel command line: console=ttyPS0,115200 earlyprintk                          
PID hash table entries: 2048 (order: 1, 8192 bytes)                             
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)                 
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)                  
Memory: 492912K/524288K available (4759K kernel code, 223K rwdata, 1708K rodata)
Virtual kernel memory layout:                                                   
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)                               
    fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)                               
    vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)                               
    lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)                               
    pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)                               
    modules : 0xbf000000 - 0xbfe00000   (  14 MB)                               
      .text : 0xc0008000 - 0xc0658efc   (6468 kB)                               
      .init : 0xc0659000 - 0xc09a2000   (3364 kB)                               
      .data : 0xc09a2000 - 0xc09d9de0   ( 224 kB)                               
       .bss : 0xc09d9de0 - 0xc0a0e0f4   ( 209 kB)                               
Preemptible hierarchical RCU implementation.                                    
        Additional per-CPU info printed with stalls.                            
        RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2.                    
RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2                    
NR_IRQS:16 nr_irqs:16 16                                                        
L2C: platform modifies aux control register: 0x72360000 -> 0x72760000           
L2C: DT/platform modifies aux control register: 0x72360000 -> 0x72760000        
L2C-310 erratum 769419 enabled                                                  
L2C-310 enabling early BRESP for Cortex-A9                                      
L2C-310 full line of zeros enabled for Cortex-A9                                
L2C-310 ID prefetch enabled, offset 1 lines                                     
L2C-310 dynamic clock gating enabled, standby mode enabled                      
L2C-310 cache controller enabled, 8 ways, 512 kB                                
L2C-310: CACHE_ID 0x410000c8, AUX_CTRL 0x76760001                               
slcr mapped to e0804000                                                         
zynq_clock_init: clkc starts at e0804100                                        
Zynq clock init                                                                 
sched_clock: 64 bits at 333MHz, resolution 3ns, wraps every 3298534883328ns     
timer #0 at e0808000, irq=17                                                    
Console: colour dummy device 80x30                                              
Calibrating delay loop... 1332.01 BogoMIPS (lpj=6660096)                        
pid_max: default: 32768 minimum: 301                                            
Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)                     
Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)                
CPU: Testing write buffer coherency: ok                                         
CPU0: thread -1, cpu 0, socket 0, mpidr 80000000                                
Setting up static identity map for 0x481788 - 0x4817e0                          
CPU1: thread -1, cpu 1, socket 0, mpidr 80000001                                
Brought up 2 CPUs                                                               
SMP: Total of 2 processors activated (2664.03 BogoMIPS).                        
CPU: All CPU(s) started in SVC mode.                                            
devtmpfs: initialized                                                           
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4         
pinctrl core: initialized pinctrl subsystem                                     
NET: Registered protocol family 16                                              
DMA: preallocated 256 KiB pool for atomic coherent allocations                  
cpuidle: using governor ladder                                                  
cpuidle: using governor menu                                                    
hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.     
hw-breakpoint: maximum watchpoint size is 4 bytes.                              
zynq-ocm f800c000.ocmc: ZYNQ OCM pool: 256 KiB @ 0xe0880000                     
GPIO IRQ not connected                                                          
XGpio: /amba_pl/gpio@41200000: registered, base is 901                          
GPIO IRQ not connected                                                          
XGpio: /amba_pl/gpio@41210000: registered, base is 893                          
GPIO IRQ not connected                                                          
XGpio: /amba_pl/gpio@41220000: registered, base is 885                          
vgaarb: loaded                                                                  
SCSI subsystem initialized                                                      
usbcore: registered new interface driver usbfs                                  
usbcore: registered new interface driver hub                                    
usbcore: registered new device driver usb                                       
media: Linux media interface: v0.10                                             
Linux video capture interface: v2.00                                            
pps_core: LinuxPPS API ver. 1 registered                                        
pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@>
PTP clock support registered                                                    
EDAC MC: Ver: 3.0.0                                                             
Advanced Linux Sound Architecture Driver Initialized.                           
Switched to clocksource arm_global_timer                                        
NET: Registered protocol family 2                                               
TCP established hash table entries: 4096 (order: 2, 16384 bytes)                
TCP bind hash table entries: 4096 (order: 3, 32768 bytes)                       
TCP: Hash tables configured (established 4096 bind 4096)                        
TCP: reno registered                                                            
UDP hash table entries: 256 (order: 1, 8192 bytes)                              
UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)                         
NET: Registered protocol family 1                                               
RPC: Registered named UNIX socket transport module.                             
RPC: Registered udp transport module.                                           
RPC: Registered tcp transport module.                                           
RPC: Registered tcp NFSv4.1 backchannel transport module.                       
hw perfevents: enabled with armv7_cortex_a9 PMU driver, 7 counters available    
futex hash table entries: 512 (order: 3, 32768 bytes)                           
jffs2: version 2.2. (NAND) (SUMMARY)  �© 2001-2006 Red Hat, Inc.                
io scheduler noop registered                                                    
io scheduler deadline registered                                                
io scheduler cfq registered (default)                                           
zynq-pinctrl 700.pinctrl: zynq pinctrl initialized                              
dma-pl330 f8003000.dmac: Loaded driver for PL330 DMAC-241330                    
dma-pl330 f8003000.dmac:        DBUFF-128x8bytes Num_Chans-8 Num_Peri-4 Num_Eve6
e0001000.serial: ttyPS0 at MMIO 0xe0001000 (irq = 143, base_baud = 3125000) is s
�console [ttyPS0] enabled                                                       
console [ttyPS0] enabled                                                        
bootconsole [earlycon0] disabled                                                
bootconsole [earlycon0] disabled                                                
xdevcfg f8007000.devcfg: ioremap 0xf8007000 to e081a000                         
[drm] Initialized drm 1.1.0 20060810                                            
brd: module loaded                                                              
loop: module loaded                                                             
m25p80 spi0.0: s25fl256s1 (32768 Kbytes)                                        
4 ofpart partitions found on MTD device spi0.0                                  
Creating 4 MTD partitions on "spi0.0":                                          
0x000000000000-0x000000500000 : "boot"                                          
0x000000500000-0x000000520000 : "bootenv"                                       
0x000000520000-0x000000fa0000 : "kernel"                                        
0x000000fa0000-0x000002000000 : "spare"                                         
CAN device driver interface                                                     
libphy: MACB_mii_bus: probed                                                    
mdio_bus e000b000.etherne: /amba/ethernet@e000b000/mdio has invalid PHY address 
mdio_bus e000b000.etherne: scan phy mdio at address 0                           
mdio_bus e000b000.etherne: scan phy mdio at address 1                           
mdio_bus e000b000.etherne: scan phy mdio at address 2                           
mdio_bus e000b000.etherne: scan phy mdio at address 3                           
mdio_bus e000b000.etherne: scan phy mdio at address 4                           
mdio_bus e000b000.etherne: scan phy mdio at address 5                           
mdio_bus e000b000.etherne: scan phy mdio at address 6                           
mdio_bus e000b000.etherne: scan phy mdio at address 7                           
mdio_bus e000b000.etherne: scan phy mdio at address 8                           
mdio_bus e000b000.etherne: scan phy mdio at address 9                           
mdio_bus e000b000.etherne: scan phy mdio at address 10                          
mdio_bus e000b000.etherne: scan phy mdio at address 11                          
mdio_bus e000b000.etherne: scan phy mdio at address 12                          
mdio_bus e000b000.etherne: scan phy mdio at address 13                          
mdio_bus e000b000.etherne: scan phy mdio at address 14                          
mdio_bus e000b000.etherne: scan phy mdio at address 15                          
mdio_bus e000b000.etherne: scan phy mdio at address 16                          
mdio_bus e000b000.etherne: scan phy mdio at address 17                          
mdio_bus e000b000.etherne: scan phy mdio at address 18                          
mdio_bus e000b000.etherne: scan phy mdio at address 19                          
mdio_bus e000b000.etherne: scan phy mdio at address 20                          
mdio_bus e000b000.etherne: scan phy mdio at address 21                          
mdio_bus e000b000.etherne: scan phy mdio at address 22                          
mdio_bus e000b000.etherne: scan phy mdio at address 23                          
mdio_bus e000b000.etherne: scan phy mdio at address 24                          
mdio_bus e000b000.etherne: scan phy mdio at address 25                          
mdio_bus e000b000.etherne: scan phy mdio at address 26                          
mdio_bus e000b000.etherne: scan phy mdio at address 27                          
mdio_bus e000b000.etherne: scan phy mdio at address 28                          
mdio_bus e000b000.etherne: scan phy mdio at address 29                          
mdio_bus e000b000.etherne: scan phy mdio at address 30                          
mdio_bus e000b000.etherne: scan phy mdio at address 31                          
macb e000b000.ethernet eth0: Cadence GEM rev 0x00020118 at 0xe000b000 irq 145 ()
macb e000b000.ethernet eth0: attached PHY driver [Marvell 88E1510] (mii_bus:phy)
e1000e: Intel(R) PRO/1000 Network Driver - 2.3.2-k                              
e1000e: Copyright(c) 1999 - 2014 Intel Corporation.                             
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver                      
ehci-pci: EHCI PCI platform driver                                              
usbcore: registered new interface driver usb-storage                            
e0002000.usb supply vbus not found, using dummy regulator                       
ULPI transceiver vendor/product ID 0x0451/0x1507                                
Found TI TUSB1210 ULPI transceiver.                                             
ULPI integrity check: passed.                                                   
mousedev: PS/2 mouse device common for all mice                                 
i2c /dev entries driver                                                         
Xilinx Zynq CpuIdle Driver started                                              
Driver 'mmcblk' needs updating - please use bus_type methods                    
sdhci: Secure Digital Host Controller Interface driver                          
sdhci: Copyright(c) Pierre Ossman                                               
sdhci-pltfm: SDHCI platform and OF driver helper                                
sdhci-arasan e0100000.sdhci: No vmmc regulator found                            
sdhci-arasan e0100000.sdhci: No vqmmc regulator found                           
mmc0: SDHCI controller on e0100000.sdhci [e0100000.sdhci] using ADMA            
ledtrig-cpu: registered to indicate activity on CPUs                            
usbcore: registered new interface driver usbhid                                 
usbhid: USB HID core driver                                                     
TCP: cubic registered                                                           
NET: Registered protocol family 17                                              
can: controller area network core (rev 20120528 abi 9)                          
NET: Registered protocol family 29                                              
can: raw protocol (rev 20120528)                                                
can: broadcast manager protocol (rev 20120528 t)                                
can: netlink gateway (rev 20130117) max_hops=1                                  
Registering SWP/SWPB emulation handler                                          
/opt/Petalinux/petalinux-v2015.4-final/components/linux-kernel/xlnx-4.0/drivers)
mmc0: new high speed SDHC card at address b368                                  
mmcblk0: mmc0:b368 NCard 3.73 GiB                                               
 mmcblk0: p1                                                                    
ALSA device list:                                                               
  No soundcards found.                                                          
Freeing unused kernel memory: 3364K (c0659000 - c09a2000)                       
INIT: version 2.88 booting                                                      
FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt.
Creating /dev/flash/* device nodes                                              
random: dd urandom read with 1 bits of entropy available                        
Starting internet superserver: inetd.                                           
update-rc.d: /etc/init.d/run-postinsts exists during rc.d purge (continuing)    
 Removing any system startup links for run-postinsts ...                        
INIT: Entering runlevel: 5                                                      
Configuring network interfaces... udhcpc (v1.23.1) started                      
Sending discover...                                                             
Sending discover...                                                             
Sending discover...                                                             
No lease, forking to background                                                 
done.                                                                           
                                                                                
Built with PetaLinux v2015.4 (Yocto 1.8) Avnet-Digilent-ZedBoard-2015_4 /dev/tt0
Avnet-Digilent-ZedBoard-2015_4 login: 

起動時のコンソールに「yocto1.8」と書かれていることから、PetaLinuxはyoctoベースだとわかりますね。

さいごに

今回はZedboardでPetaLinuxが動作することが確認できました。
今後はVivadoでbitstreamやFSBLを作って、LinuxからFPGA部分を使う方法を調査したいと思います。
また、bspの作り方やブートデバイスをSDカードからQSPI Flashへ変更して動かす方法も気になっています。
わかるかなぁー

参考Webページ

公式ドキュメントの他、以下の記事が大変参考になりました。

公式リファレンス

PetaLinuビルド手順Blog

petalinux- build中に発生したエラー