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

zybo のカスタムシステムの作成

ボードデザイン

f:id:ippei-r:20150103113553p:plain
とりあえず、オーディオ、グラフィックなしで作ってみる。

report Utilization
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
|           Instance           |               Module              | Total LUTs | Logic LUTs | LUTRAMs | SRLs | FFs | RAMB36 | RAMB18 | DSP48 Blocks |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
| system_wrapper               |                             (top) |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|   (system_wrapper)           |                             (top) |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|   system_i                   |                            system |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|     (system_i)               |                            system |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     axi_interconnect_0       |       system_axi_interconnect_0_0 |         93 |         93 |       0 |    0 |  75 |      0 |      0 |            0 |
|     axi_protocol_converter_0 | system_axi_protocol_converter_0_0 |        395 |        332 |       0 |   63 | 541 |      0 |      0 |            0 |
|     processing_system7_0     |     system_processing_system7_0_0 |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     zybo_sw_led_axi_0        |        system_zybo_sw_led_axi_0_0 |         15 |         15 |       0 |    0 |  32 |      0 |      0 |            0 |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+

カーネルコンフィグ

make ARCH=arm menuconfig

次の3点を変更

  • Device Drivers > Graphics Suport
    • 全部チェックは外す
  • Device Drivers > Sound card supportのチェックはずす
  • Device Drivers > DMA Engine support > Xilinx DMA Engine

CDMAは外す必要なかった。

立ち上がらない?

同様の手順で作ってみたが立ち上がらない。(シリアルコンソールに何も表示されない)あら
DONE LEDはつくからBOOT.binは読めてるっぽい

BOOT.binを入れ替える。

BOOT.binをZYBO base systemで作成したもので起動してみる。
起動した

U-Boot 2014.01-00005-gc29bed9 (Dec 31 2014 - 18:29:40)

I2C:   ready
Memory: ECC disabled
DRAM:  512 MiB
MMC:   zynq_sdhci: 0
SF: Detected S25FL128S_64K with page size 256 Bytes, erase size 64 KiB, total 16 MiB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   Gem.e000b000
Hit any key to stop autoboot:  0 
Device: zynq_sdhci
Manufacturer ID: 2
OEM: 544d
Name: SA08G 
Tran Speed: 50000000
Rd Block Len: 512
SD version 3.0
High Capacity: Yes
Capacity: 7.4 GiB
Bus Width: 4-bit
reading uEnv.txt
116 bytes read in 8 ms (13.7 KiB/s)
Loaded environment from uEnv.txt
Importing environment from SD ...
Running uenvcmd ...
reading uImage
3540320 bytes read in 323 ms (10.5 MiB/s)
reading devicetree.dtb
7406 bytes read in 17 ms (424.8 KiB/s)
## Booting kernel from Legacy Image at 03000000 ...
   Image Name:   Linux-3.14.0-xilinx-13567-g906a2
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3540256 Bytes = 3.4 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 02a00000
   Booting using the fdt blob at 0x2a00000
   Loading Kernel Image ... OK
   Loading Device Tree to 1fb2a000, end 1fb2eced ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 3.14.0-xilinx-13567-g906a2c9 (ippei@T440s) (gcc version 4.8.3 20140320 (5
[    0.000000] CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5387d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Xilinx Zynqnicom 2.7 | VT102 | 切断 | ttyUSB1                           [    0.000000] bootconsole [earlycon0] enabled
[    0.000000] cma: CMA: reserved 128 MiB at 17800000
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] PERCPU: Embedded 8 pages/cpu @dfb9e000 s10752 r8192 d13824 u32768
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048
[    0.000000] Kernel command line: console=ttyPS0,115200 root=/dev/mmcblk0p2 rw earlyprintk rootfsty1
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 376000K/524288K available (4765K kernel code, 308K rwdata, 1696K rodata, 198K )
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
[    0.000000]     vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc06578c4   (6463 kB)
[    0.000000]       .init : 0xc0658000 - 0xc0689a00   ( 199 kB)
[    0.000000]       .data : 0xc068a000 - 0xc06d71f8   ( 309 kB)
[    0.000000]        .bss : 0xc06d7204 - 0xc0c0b908   (5330 kB)
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000]  RCU lockdep checking is enabled.
[    0.000000]  Dump stacks of tasks blocking RCU-preempt GP.
[    0.000000]  RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000000] ps7-slcr mapped to e0802000
[    0.000000] zynq_clock_init: clkc starts at e0802100
[    0.000000] Zynq clock init
[    0.000017] sched_clock: 64 bits at 325MHz, resolution 3ns, wraps every 3383112499200ns
[    0.008511] ps7-ttc #0 at e0804000, irq=43
[    0.013562] Console: colour dummy device 80x30
[    0.017902] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar
[    0.025981] ... MAX_LOCKDEP_SUBCLASSES:  8
[    0.029998] ... MAX_LOCK_DEPTH:          48
[    0.034171] ... MAX_LOCKDEP_KEYS:        8191
[    0.038589] ... CLASSHASH_SIZE:          4096
[    0.042943] ... MAX_LOCKDEP_ENTRIES:     16384
[    0.047414] ... MAX_LOCKDEP_CHAINS:      32768
[    0.051917] ... CHAINHASH_SIZE:          16384
[    0.056361]  memory used by lock dependency info: 3695 kB
[    0.061805]  per task-struct memory footprint: 1152 bytes
[    0.067253] Calibrating delay loop... 1292.69 BogoMIPS (lpj=6463488)
[    0.110964] pid_max: default: 32768 minimum: 301
[    0.116263] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.122802] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.137294] CPU: Testing write buffer coherency: ok
[    0.143581] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.149222] Setting up static identity map for 0x485d00 - 0x485d58
[    0.155594] L310 cache controller enabled
[    0.159551] l2x0: 8 ways, CACHE_ID 0x410000c8, AUX_CTRL 0x72760000, Cache size: 512 kB
[    0.240360] CPU1: Booted secondary processor
[    0.328292] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
[    0.329298] Brought up 2 CPUs
[    0.342169] SMP: Total of 2 processors activated.
[    0.346869] CPU: All CPU(s) started in SVC mode.
[    0.354989] devtmpfs: initialized
[    0.365736] VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
[    0.380061] regulator-dummy: no parameters
[    0.393257] NET: Registered protocol family 16
[    0.402061] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.415628] cpuidle: using governor ladder
[    0.419610] cpuidle: using governor menu
[    0.446670] syscon f8000000.ps7-slcr: regmap [mem 0xf8000000-0xf8000fff] registered
[    0.458568] hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
[    0.466416] hw-breakpoint: maximum watchpoint size is 4 bytes.
[    0.472759] zynq-ocm f800c000.ps7-ocmc: ZYNQ OCM pool: 256 KiB @ 0xe0880000
[    0.537879] bio: create slab <bio-0> at 0
[    0.547051] SCSI subsystem initialized
[    0.553237] usbcore: registered new interface driver usbfs
[    0.559087] usbcore: registered new interface driver hub
[    0.564839] usbcore: registered new device driver usb
[    0.571358] media: Linux media interface: v0.10
[    0.576200] Linux video capture interface: v2.00
[    0.581430] pps_core: LinuxPPS API ver. 1 registered
[    0.586266] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.i>
[    0.595820] PTP clock support registered
[    0.600829] EDAC MC: Ver: 3.0.0
[    0.616124] DMA-API: preallocated 4096 debug entries
[    0.621100] DMA-API: debugging enabled by kernel config
[    0.626775] Switched to clocksource arm_global_timer
[    0.690199] NET: Registered protocol family 2
[    0.697632] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    0.704720] TCP bind hash table entries: 4096 (order: 5, 147456 bytes)
[    0.713229] TCP: Hash tables configured (established 4096 bind 4096)
[    0.719824] TCP: reno registered
[    0.722962] UDP hash table entries: 256 (order: 2, 20480 bytes)
[    0.729154] UDP-Lite hash table entries: 256 (order: 2, 20480 bytes)
[    0.736649] NET: Registered protocol family 1
[    0.742696] RPC: Registered named UNIX socket transport module.
[    0.748553] RPC: Registered udp transport module.
[    0.753209] RPC: Registered tcp transport module.
[    0.757970] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.765809] hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
[    0.779681] futex hash table entries: 512 (order: 3, 32768 bytes)
[    0.793239] jffs2: version 2.2. (NAND) (SUMMARY)  �© 2001-2006 Red Hat, Inc.
[    0.800749] msgmni has been set to 990
[    0.806024] io scheduler noop registered
[    0.809903] io scheduler deadline registered
[    0.814229] io scheduler cfq registered (default)
[    0.834156] dma-pl330 f8003000.ps7-dma: Loaded driver for PL330 DMAC-2364208
[    0.841146] dma-pl330 f8003000.ps7-dma:      DBUFF-128x8bytes Num_Chans-8 Num_Peri-4 Num_Events-16
[    0.852255] e0001000.serial: ttyPS0 at MMIO 0xe0001000 (irq = 82, base_baud = 3125000) is a xuartps
[    0.861692] console [ttyPS0] enabled
[    0.861692] console [ttyPS0] enabled
[    0.868816] bootconsole [earlycon0] disabled
[    0.868816] bootconsole [earlycon0] disabled
[    0.879962] xdevcfg f8007000.ps7-dev-cfg: ioremap 0xf8007000 to e0866000
[    0.921458] brd: module loaded
[    0.944597] loop: module loaded
[    0.960669] m25p80 spi0.0: found s25fl128s1, expected n25q128
[    0.966376] m25p80 spi0.0: s25fl128s1 (16384 Kbytes)
[    0.971490] 4 ofpart partitions found on MTD device spi0.0
[    0.977381] Creating 4 MTD partitions on "spi0.0":
[    0.982121] 0x000000000000-0x000000400000 : "qspi-fsbl-uboot"
[    0.995740] 0x000000400000-0x000000900000 : "qspi-linux"
[    1.005803] 0x000000900000-0x000000920000 : "qspi-device-tree"
[    1.016323] 0x000000920000-0x000001000000 : "qspi-user"
[    1.035475] e1000e: Intel(R) PRO/1000 Network Driver - 2.3.2-k
[    1.041329] e1000e: Copyright(c) 1999 - 2013 Intel Corporation.
[    1.052955] libphy: XEMACPS mii bus: probed
[    1.059574] xemacps e000b000.ps7-ethernet: pdev->id -1, baseaddr 0xe000b000, irq 54
[    1.070483] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.077580] ehci-pci: EHCI PCI platform driver
[    1.085207] zynq-dr e0002000.ps7-usb: Unable to init USB phy, missing?
[    1.092644] usbcore: registered new interface driver usb-storage
[    1.101654] mousedev: PS/2 mouse device common for all mice
[    1.109309] i2c /dev entries driver
[    1.121711] zynq-edac f8006000.ps7-ddrc: ecc not enabled
[    1.127936] cpufreq_cpu0: failed to get cpu0 regulator: -19
[    1.136213] Xilinx Zynq CpuIdle Driver started
[    1.142610] sdhci: Secure Digital Host Controller Interface driver
[    1.148883] sdhci: Copyright(c) Pierre Ossman
[    1.153156] sdhci-pltfm: SDHCI platform and OF driver helper
[    1.159384] mmc0: no vqmmc regulator found
[    1.163408] mmc0: no vmmc regulator found
[    1.206776] mmc0: SDHCI controller on e0100000.ps7-sdio [e0100000.ps7-sdio] using ADMA
[    1.224022] usbcore: registered new interface driver usbhid
[    1.231652] usbhid: USB HID core driver
[    1.243281] TCP: cubic registered
[    1.246572] NET: Registered protocol family 17
[    1.251497] Registering SWP/SWPB emulation handler
[    1.258907] regulator-dummy: disabling
[    1.263339] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[    1.280639] mmc0: new high speed SDHC card at address 1234
[    1.288873] mmcblk0: mmc0:1234 SA08G 7.42 GiB 
[    1.299954]  mmcblk0: p1 p2
[    1.334961] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    1.343229] VFS: Mounted root (ext4 filesystem) on device 179:2.
[    1.359127] devtmpfs: mounted
[    1.362371] Freeing unused kernel memory: 196K (c0658000 - c0689000)
�+HH��1.894731] init: ureadahead main process (550) terminated with status 5
Last login: Thu Jan  1 00:00:06 UTC 1970 on tty1
Welcome to Linaro 12.11 (GNU/Linux 3.14.0-xilinx-13567-g906a2c9 armv7l)

 * Documentation:  https://wiki.linaro.org/
root@linaro-nano:~# 

デザイン修正

f:id:ippei-r:20150103150509p:plain
SD_WPを0を接続

+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
|           Instance           |               Module              | Total LUTs | Logic LUTs | LUTRAMs | SRLs | FFs | RAMB36 | RAMB18 | DSP48 Blocks |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
| system_wrapper               |                             (top) |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|   (system_wrapper)           |                             (top) |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|   system_i                   |                            system |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|     (system_i)               |                            system |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     axi_interconnect_0       |       system_axi_interconnect_0_0 |         93 |         93 |       0 |    0 |  75 |      0 |      0 |            0 |
|     axi_protocol_converter_0 | system_axi_protocol_converter_0_0 |        395 |        332 |       0 |   63 | 541 |      0 |      0 |            0 |
|     processing_system7_0     |     system_processing_system7_0_0 |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     xlconstant_0             |             system_xlconstant_0_0 |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     zybo_sw_led_axi_0        |        system_zybo_sw_led_axi_0_0 |         15 |         15 |       0 |    0 |  32 |      0 |      0 |            0 |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+

FSBLのデバッグメッセージ

fsbl_debug.hに

#define FSBL_DEBUG_INFO

を追加して実行してみた
参考
ZYNQのFSBLが動かない場合の対処法: なひたふJTAG日記

Xilinx First Stage Boot Loader 
Release 2014.4  Jan  3 2015-15:14:41
Devcfg driver initialized 
Silicon Version 3.1
Boot mode is SD
SD: rc= 0
SD Init Done 
Flash Base Address: 0xE0100000
Reboot status register: 0x60600000
Multiboot Register: 0x0000C000
Image Start Address: 0x00000000
Partition Header Offset:0x00000C80
Partition Count: 3
Partition Number: 1
Header Dump
Image Word Len: 0x0007F2E8
Data Word Len: 0x0007F2E8
Partition Word Len:0x0007F2E8
Load Addr: 0x00000000
Exec Addr: 0x00000000
Partition Start: 0x000075D0
Partition Attr: 0x00000020
Partition Checksum Offset: 0x00000000
Section Count: 0x00000001
Checksum: 0xFFE7AF06
Bitstream
In FsblHookBeforeBitstreamDload function 
PCAP:StatusReg = 0x40000A30
PCAP:device ready
PCAP:Clear done
Level Shifter Value = 0xA 
Devcfg Status register = 0x40000A30 
PCAP:Fabric is Initialized done
PCAP register dump:
PCAP CTRL 0xF8007000: 0x4C00E07F
PCAP LOCK 0xF8007004: 0x0000001A
PCAP CONFIG 0xF8007008: 0x00000508
PCAP ISR 0xF800700C: 0x0802000B
PCAP IMR 0xF8007010: 0xFFFFFFFF
PCAP STATUS 0xF8007014: 0x50000F30
PCAP DMA SRC ADDR 0xF8007018: 0x00100001
PCAP DMA DEST ADDR 0xF800701C: 0xFFFFFFFF
PCAP DMA SRC LEN 0xF8007020: 0x0007F2E8
PCAP DMA DEST LEN 0xF8007024: 0x0007F2E8
PCAP ROM SHADOW CTRL 0xF8007028: 0xFFFFFFFF
PCAP MBOOT 0xF800702C: 0x0000C000
PCAP SW ID 0xF8007030: 0x00000000
PCAP UNLOCK 0xF8007034: 0x757BDF0D
PCAP MCTRL 0xF8007080: 0x30800100

DMA Done ! 

FPGA Done ! 
In FsblHookAfterBitstreamDload function 
Partition Number: 2
Header Dump
Image Word Len: 0x0001475C
Data Word Len: 0x0001475C
Partition Word Len:0x0001475C
Load Addr: 0x04000000
Exec Addr: 0x04000000
Partition Start: 0x000868C0
Partition Attr: 0x00000010
Partition Checksum Offset: 0x00000000
Section Count: 0x00000001
Checksum: 0xF7F3BEBA
Application
Handoff Address: 0x04000000
In FsblHookBeforeHandoff function 
Look Up I2C Configuration
I2C Initialization
Set I2C Clock
Set Memory Read Address

問題箇所

fsbl_fooks.c

		fsbl_printf(DEBUG_GENERAL,"Set Memory Read Address\n\r");
		XIicPs_MasterSendPolled(&Iic, mac_addr, 1, 0x50);
		while(XIicPs_BusIsBusy(&Iic));

もしかして、ブロックデザインでI2Cポートを出力してなかったからMACアドレスを読みに行ってもずっとビジーだった?

起動

I2Cのポートをブロックデザインに追加したら無事linuxまで起動した。
f:id:ippei-r:20150103160934p:plain

report_util
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
|           Instance           |               Module              | Total LUTs | Logic LUTs | LUTRAMs | SRLs | FFs | RAMB36 | RAMB18 | DSP48 Blocks |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
| system_wrapper               |                             (top) |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|   (system_wrapper)           |                             (top) |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|   system_i                   |                            system |        503 |        440 |       0 |   63 | 648 |      0 |      0 |            0 |
|     (system_i)               |                            system |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     axi_interconnect_0       |       system_axi_interconnect_0_0 |         93 |         93 |       0 |    0 |  75 |      0 |      0 |            0 |
|     axi_protocol_converter_0 | system_axi_protocol_converter_0_0 |        393 |        330 |       0 |   63 | 541 |      0 |      0 |            0 |
|     processing_system7_0     |     system_processing_system7_0_0 |          2 |          2 |       0 |    0 |   0 |      0 |      0 |            0 |
|     xlconstant_0             |             system_xlconstant_0_0 |          0 |          0 |       0 |    0 |   0 |      0 |      0 |            0 |
|     zybo_sw_led_axi_0        |        system_zybo_sw_led_axi_0_0 |         15 |         15 |       0 |    0 |  32 |      0 |      0 |            0 |
+------------------------------+-----------------------------------+------------+------------+---------+------+-----+--------+--------+--------------+
xdc
set_property PACKAGE_PIN D18 [get_ports {LED[3]}]
set_property PACKAGE_PIN G14 [get_ports {LED[2]}]
set_property PACKAGE_PIN M15 [get_ports {LED[1]}]
set_property PACKAGE_PIN M14 [get_ports {LED[0]}]
set_property IOSTANDARD LVCMOS33 [get_ports {LED[3]}]
set_property IOSTANDARD LVCMOS33 [get_ports {LED[2]}]
set_property IOSTANDARD LVCMOS33 [get_ports {LED[1]}]
set_property IOSTANDARD LVCMOS33 [get_ports {LED[0]}]
set_property PACKAGE_PIN Y16 [get_ports {PUSH_SW[3]}]
set_property PACKAGE_PIN V16 [get_ports {PUSH_SW[2]}]
set_property PACKAGE_PIN P16 [get_ports {PUSH_SW[1]}]
set_property PACKAGE_PIN R18 [get_ports {PUSH_SW[0]}]
set_property IOSTANDARD LVCMOS33 [get_ports {PUSH_SW[3]}]
set_property IOSTANDARD LVCMOS33 [get_ports {PUSH_SW[2]}]
set_property IOSTANDARD LVCMOS33 [get_ports {PUSH_SW[1]}]
set_property IOSTANDARD LVCMOS33 [get_ports {PUSH_SW[0]}]
set_property PACKAGE_PIN T16 [get_ports {SLIDE_SW[3]}]
set_property PACKAGE_PIN W13 [get_ports {SLIDE_SW[2]}]
set_property PACKAGE_PIN P15 [get_ports {SLIDE_SW[1]}]
set_property PACKAGE_PIN G15 [get_ports {SLIDE_SW[0]}]
set_property IOSTANDARD LVCMOS33 [get_ports {SLIDE_SW[3]}]
set_property IOSTANDARD LVCMOS33 [get_ports {SLIDE_SW[2]}]
set_property IOSTANDARD LVCMOS33 [get_ports {SLIDE_SW[1]}]
set_property IOSTANDARD LVCMOS33 [get_ports {SLIDE_SW[0]}]

set_property PACKAGE_PIN N18 [get_ports iic_0_scl_io]
set_property IOSTANDARD LVCMOS33 [get_ports iic_0_scl_io]
set_property PACKAGE_PIN N17 [get_ports iic_0_sda_io]
set_property IOSTANDARD LVCMOS33 [get_ports iic_0_sda_io]
起動ログ
Xilinx First Stage Boot Loader 
Release 2014.4  Jan  3 2015-16:03:13
Devcfg driver initialized 
Silicon Version 3.1
Boot mode is SD
SD: rc= 0
SD Init Done 
Flash Base Address: 0xE0100000
Reboot status register: 0x60480000
Multiboot Register: 0x0000C000
Image Start Address: 0x00000000
Partition Header Offset:0x00000C80
Partition Count: 3
Partition Number: 1
Header Dump
Image Word Len: 0x0007F2E8
Data Word Len: 0x0007F2E8
Partition Word Len:0x0007F2E8
Load Addr: 0x00000000
Exec Addr: 0x00000000
Partition Start: 0x000075D0
Partition Attr: 0x00000020
Partition Checksum Offset: 0x00000000
Section Count: 0x00000001
Checksum: 0xFFE7AF06
Bitstream
In FsblHookBeforeBitstreamDload function 
PCAP:StatusReg = 0x40000A30
PCAP:device ready
PCAP:Clear done
Level Shifter Value = 0xA 
Devcfg Status register = 0x40000A30 
PCAP:Fabric is Initialized done
PCAP register dump: 
PCAP CTRL 0xF8007000: 0x4C00E07F 
PCAP LOCK 0xF8007004: 0x0000001A
PCAP CONFIG 0xF8007008: 0x00000508
PCAP ISR 0xF800700C: 0x0802000B
PCAP IMR 0xF8007010: 0xFFFFFFFF
PCAP STATUS 0xF8007014: 0x50000F30
PCAP DMA SRC ADDR 0xF8007018: 0x00100001
PCAP DMA DEST ADDR 0xF800701C: 0xFFFFFFFF
PCAP DMA SRC LEN 0xF8007020: 0x0007F2E8
PCAP DMA DEST LEN 0xF8007024: 0x0007F2E8
PCAP ROM SHADOW CTRL 0xF8007028: 0xFFFFFFFF
PCAP MBOOT 0xF800702C: 0x0000C000
PCAP SW ID 0xF8007030: 0x00000000
PCAP UNLOCK 0xF8007034: 0x757BDF0D
PCAP MCTRL 0xF8007080: 0x30800100

DMA Done ! 

FPGA Done ! 
In FsblHookAfterBitstreamDload function 
Partition Number: 2
Header Dump
Image Word Len: 0x0001475C
Data Word Len: 0x0001475C
Partition Word Len:0x0001475C
Load Addr: 0x04000000
Exec Addr: 0x04000000
Partition Start: 0x000868C0
Partition Attr: 0x00000010NOR | Minicom 2.7 | VT102 | 切断 | ttyUSB
Partition Checksum Offset: 0x00000000
Section Count: 0x00000001
Checksum: 0xF7F3BEBA
Application
Handoff Address: 0x04000000
In FsblHookBeforeHandoff function 
Look Up I2C Configuration
I2C Initialization
Set I2C Clock
Set Memory Read Address
Get Mac Address
MAC Addr: 00 1E C0 AC 85 3F 
Look Up Emac Configuration
Emac Initialization
Set Emac MAC Address
Verify Emac MAC Address
MAC Addr: 00 1E C0 AC 85 3F 
SUCCESSFUL_HANDOFF
FSBL Status = 0x1


U-Boot 2014.01-00005-gc29bed9 (Dec 31 2014 - 18:29:40)

I2C:   ready
Memory: ECC disabled
DRAM:  512 MiB
MMC:   zynq_sdhci: 0
SF: Detected S25FL128S_64K with page size 256 Bytes, erase size 64 KiB, total 16 MiB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   Gem.e000b000
Hit any key to stop autoboot:  0 
Device: zynq_sdhci
Manufacturer ID: 2
OEM: 544d
Name: SA08G 
Tran Speed: 50000000
Rd Block Len: 512
SD version 3.0
High Capacity: Yes
Capacity: 7.4 GiB
Bus Width: 4-bit
reading uEnv.txt
116 bytes read in 8 ms (13.7 KiB/s)
Loaded environment from uEnv.txt
Importing environment from SD ...
Running uenvcmd ...
reading uImage
3540320 bytes read in 323 ms (10.5 MiB/s)
reading devicetree.dtb
7406 bytes read in 17 ms (424.8 KiB/s)
## Booting kernel from Legacy Image at 03000000 ...
   Image Name:   Linux-3.14.0-xilinx-13567-g906a2
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3540256 Bytes = 3.4 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 02a00000
   Booting using the fdt blob at 0x2a00000
   Loading Kernel Image ... OK
   Loading Device Tree to 1fb2a000, end 1fb2eced ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 3.14.0-xilinx-13567-g906a2c9 (ippei@T440s) (gcc version 4.8.3 20140320 (5
[    0.000000] CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5387d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Xilinx Zynq
[    0.000000] bootconsole [earlycon0] enabled
[    0.000000] cma: CMA: reserved 128 MiB at 17800000
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] PERCPU: Embedded 8 pages/cpu @dfb9e000 s10752 r8192 d13824 u32768
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 130048
[    0.000000] Kernel command line: console=ttyPS0,115200 root=/dev/mmcblk0p2 rw earlyprintk rootfsty1
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 376000K/524288K available (4765K kernel code, 308K rwdata, 1696K rodata, 198K )
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
[    0.000000]     vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc06578c4   (6463 kB)
[    0.000000]       .init : 0xc0658000 - 0xc0689a00   ( 199 kB)
[    0.000000]       .data : 0xc068a000 - 0xc06d71f8   ( 309 kB)
[    0.000000]        .bss : 0xc06d7204 - 0xc0c0b908   (5330 kB)
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000]  RCU lockdep checking is enabled.
[    0.000000]  Dump stacks of tasks blocking RCU-preempt GP.
[    0.000000]  RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000000] ps7-slcr mapped to e0802000
[    0.000000] zynq_clock_init: clkc starts at e0802100
[    0.000000] Zynq clock init
[    0.000017] sched_clock: 64 bits at 325MHz, resolution 3ns, wraps every 3383112499200ns
[    0.008509] ps7-ttc #0 at e0804000, irq=43
[    0.013560] Console: colour dummy device 80x30
[    0.017902] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar
[    0.025979] ... MAX_LOCKDEP_SUBCLASSES:  8
[    0.029996] ... MAX_LOCK_DEPTH:          48
[    0.034170] ... MAX_LOCKDEP_KEYS:        8191
[    0.038589] ... CLASSHASH_SIZE:          4096
[    0.042942] ... MAX_LOCKDEP_ENTRIES:     16384
[    0.047413] ... MAX_LOCKDEP_CHAINS:      32768
[    0.051916] ... CHAINHASH_SIZE:          16384
[    0.056359]  memory used by lock dependency info: 3695 kB
[    0.061805]  per task-struct memory footprint: 1152 bytes
[    0.067251] Calibrating delay loop... 1292.69 BogoMIPS (lpj=6463488)
[    0.110963] pid_max: default: 32768 minimum: 301
[    0.116258] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.122802] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.137276] CPU: Testing write buffer coherency: ok
[    0.143560] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.149204] Setting up static identity map for 0x485d00 - 0x485d58
[    0.155576] L310 cache controller enabled
[    0.159533] l2x0: 8 ways, CACHE_ID 0x410000c8, AUX_CTRL 0x72760000, Cache size: 512 kB
[    0.240357] CPU1: Booted secondary processor
[    0.328292] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
[    0.329313] Brought up 2 CPUs
[    0.342176] SMP: Total of 2 processors activated.
[    0.346877] CPU: All CPU(s) started in SVC mode.
[    0.354991] devtmpfs: initialized
[    0.365735] VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
[    0.380056] regulator-dummy: no parameters
[    0.393071] NET: Registered protocol family 16
[    0.401906] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.415545] cpuidle: using governor ladder
[    0.419532] cpuidle: using governor menu
[    0.446601] syscon f8000000.ps7-slcr: regmap [mem 0xf8000000-0xf8000fff] registered
[    0.458474] hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
[    0.466650] hw-breakpoint: maximum watchpoint size is 4 bytes.
[    0.472832] zynq-ocm f800c000.ps7-ocmc: ZYNQ OCM pool: 256 KiB @ 0xe0880000
[    0.536847] bio: create slab <bio-0> at 0
[    0.545446] SCSI subsystem initialized
[    0.551703] usbcore: registered new interface driver usbfs
[    0.557513] usbcore: registered new interface driver hub
[    0.564690] usbcore: registered new device driver usb
[    0.571221] media: Linux media interface: v0.10
[    0.576046] Linux video capture interface: v2.00
[    0.581273] pps_core: LinuxPPS API ver. 1 registered
[    0.586110] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.i>
[    0.595724] PTP clock support registered
[    0.600650] EDAC MC: Ver: 3.0.0
[    0.615887] DMA-API: preallocated 4096 debug entries
[    0.620830] DMA-API: debugging enabled by kernel config
[    0.626525] Switched to clocksource arm_global_timer
[    0.689909] NET: Registered protocol family 2
[    0.696979] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    0.704064] TCP bind hash table entries: 4096 (order: 5, 147456 bytes)
[    0.712000] TCP: Hash tables configured (established 4096 bind 4096)
[    0.718486] TCP: reno registered
[    0.721620] UDP hash table entries: 256 (order: 2, 20480 bytes)
[    0.727852] UDP-Lite hash table entries: 256 (order: 2, 20480 bytes)
[    0.735376] NET: Registered protocol family 1
[    0.741260] RPC: Registered named UNIX socket transport module.
[    0.747201] RPC: Registered udp transport module.
[    0.751782] RPC: Registered tcp transport module.
[    0.756586] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.764310] hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
[    0.778131] futex hash table entries: 512 (order: 3, 32768 bytes)
[    0.791980] jffs2: version 2.2. (NAND) (SUMMARY)  �© 2001-2006 Red Hat, Inc.
[    0.799519] msgmni has been set to 990
[    0.804753] io scheduler noop registered
[    0.808715] io scheduler deadline registered
[    0.812964] io scheduler cfq registered (default)
[    0.835484] dma-pl330 f8003000.ps7-dma: Loaded driver for PL330 DMAC-2364208
[    0.842529] dma-pl330 f8003000.ps7-dma:      DBUFF-128x8bytes Num_Chans-8 Num_Peri-4 Num_Events-16
[    0.853603] e0001000.serial: ttyPS0 at MMIO 0xe0001000 (irq = 82, base_baud = 3125000) is a xuartps
[    0.863020] console [ttyPS0] enabled
[    0.863020] console [ttyPS0] enabled
[    0.870138] bootconsole [earlycon0] disabled
[    0.870138] bootconsole [earlycon0] disabled
[    0.881251] xdevcfg f8007000.ps7-dev-cfg: ioremap 0xf8007000 to e0866000
[    0.922721] brd: module loaded
[    0.945617] loop: module loaded
[    0.961573] m25p80 spi0.0: found s25fl128s1, expected n25q128
[    0.967641] m25p80 spi0.0: s25fl128s1 (16384 Kbytes)
[    0.972666] 4 ofpart partitions found on MTD device spi0.0
[    0.978133] Creating 4 MTD partitions on "spi0.0":
[    0.982851] 0x000000000000-0x000000400000 : "qspi-fsbl-uboot"
[    0.996917] 0x000000400000-0x000000900000 : "qspi-linux"
[    1.006960] 0x000000900000-0x000000920000 : "qspi-device-tree"
[    1.017477] 0x000000920000-0x000001000000 : "qspi-user"
[    1.036702] e1000e: Intel(R) PRO/1000 Network Driver - 2.3.2-k
[    1.042454] e1000e: Copyright(c) 1999 - 2013 Intel Corporation.
[    1.054217] libphy: XEMACPS mii bus: probed
[    1.060617] xemacps e000b000.ps7-ethernet: pdev->id -1, baseaddr 0xe000b000, irq 54
[    1.071135] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.078209] ehci-pci: EHCI PCI platform driver
[    1.085837] zynq-dr e0002000.ps7-usb: Unable to init USB phy, missing?
[    1.093280] usbcore: registered new interface driver usb-storage
[    1.102213] mousedev: PS/2 mouse device common for all mice
[    1.109850] i2c /dev entries driver
[    1.122300] zynq-edac f8006000.ps7-ddrc: ecc not enabled
[    1.128575] cpufreq_cpu0: failed to get cpu0 regulator: -19
[    1.137064] Xilinx Zynq CpuIdle Driver started
[    1.143263] sdhci: Secure Digital Host Controller Interface driver
[    1.149590] sdhci: Copyright(c) Pierre Ossman
[    1.153870] sdhci-pltfm: SDHCI platform and OF driver helper
[    1.161091] mmc0: no vqmmc regulator found
[    1.165120] mmc0: no vmmc regulator found
[    1.206535] mmc0: SDHCI controller on e0100000.ps7-sdio [e0100000.ps7-sdio] using ADMA
[    1.222939] usbcore: registered new interface driver usbhid
[    1.228529] usbhid: USB HID core driver
[    1.233866] TCP: cubic registered
[    1.237222] NET: Registered protocol family 17
[    1.242012] Registering SWP/SWPB emulation handler
[    1.249672] regulator-dummy: disabling
[    1.254096] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[    1.257596] mmc0: new high speed SDHC card at address 1234
[    1.260170] mmcblk0: mmc0:1234 SA08G 7.42 GiB 
[    1.265861]  mmcblk0: p1 p2
[    1.328726] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    1.336930] VFS: Mounted root (ext4 filesystem) on device 179:2.
[    1.354208] devtmpfs: mounted
[    1.357486] Freeing unused kernel memory: 196K (c0658000 - c0689000)
�+HH��1.874740] init: ureadahead main process (550) terminated with status 5
Last login: Thu Jan  1 00:00:07 UTC 1970 on tty1
Welcome to Linaro 12.11 (GNU/Linux 3.14.0-xilinx-13567-g906a2c9 armv7l)

 * Documentation:  https://wiki.linaro.org/
root@linaro-nano:~# ^C


ippei-r/zybo_custom · GitHub