ikwzm / ZynqMP-FPGA-Ubuntu20.04-Ultra96

Ubuntu 20.04 Desktop for Ultra96/Ultra96-V2
12 stars 3 forks source link

board start fail #2

Open PapaKache opened 3 years ago

PapaKache commented 3 years ago

Hi: My board is ultra-v2,I flash SD follow by readme. When board boot up,I see the led-D3 flash in board, but no screen display output. I can read bootloader log from uart1 port, but there is not kernel log .I think system is blocked, load kernal may failed. I try to use putty login in,but there is no response.

SD info: My SD card storage is 16GB. oo@oo:~$ sudo fdisk -l /dev/sdc Disk /dev/sdc: 14.9 GiB, 16022241280 bytes, 31293440 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: dos Disk identifier: 0x36453005

设备 启动 Start 末尾 扇区 Size Id 类型 /dev/sdc1 2048 206847 204800 100M b W95 FAT32 /dev/sdc2 206848 31293439 31086592 14.8G 83 Linux

uart log below

oo@oo:~$ sudo minicom -s

Welcome to minicom 2.7

OPTIONS: I18n Compiled on Nov 15 2018, 20:18:47. Port /dev/ttyUSB1, 18:17:05

Press CTRL-A Z for help on special keys

NOTICE: ATF running on XCZU3EG/silicon v4/RTL5.1 at 0xfffea000 NOTICE: BL31: Secure code at 0x0
NOTICE: BL31: Non secure code at 0x8000000 NOTICE: BL31: v2.0(release):xilinx-v2019.2-ultra96-1 NOTICE: BL31: Built : 12:52:00, Feb 2 2020 PMUFW: v1.1

U-Boot 2019.01 (Feb 02 2020 - 00:09:16 +0900)

Model: Avnet Ultra96 Rev1
Board: Xilinx ZynqMP DRAM: 2 GiB EL Level: EL2 Chip ID: zu3eg MMC: mmc@ff160000: 0, mmc@ff170000: 1 In: serial@ff010000 Out: serial@ff010000 Err: serial@ff010000 Bootmode: SD_MODE Reset reason: EXTERNAL Net: No ethernet found. 4370 bytes read in 18 ms (236.3 KiB/s) Loaded environment from uEnv.txt Importing environment from SD ... !!! !!! Booting cmd is deprecated (will be removed in 2020). !!! Please move to distro bootcmd. !!! switch to partitions #0, OK mmc0 is current device Device: mmc@ff160000 Manufacturer ID: 58 OEM: 4444 Name: DDINC Bus Speed: 15000000 Mode : SD High Speed (50MHz) Rd Block Len: 512 SD version 3.0 High Capacity: Yes Capacity: 14.9 GiB Bus Width: 4-bit Erase Group Size: 512 Bytes Running uenvcmd ... 16964096 bytes read in 1548 ms (10.5 MiB/s) 41517 bytes read in 21 ms (1.9 MiB/s) Flattened Device Tree blob at 04000000 Booting using the fdt blob at 0x4000000 Loading Device Tree to 000000000fff2000, end 000000000ffff22c ... OK

Starting kernel ...

ikwzm commented 3 years ago

Thank you for the issue.

Is the console set to ttyPS0? Please show me your uEnv.txt.

PapaKache commented 3 years ago

My env have no ttyPS0 `oo@oo:~$ ls /dev/tty*

/dev/tty /dev/tty17 /dev/tty26 /dev/tty35 /dev/tty44 /dev/tty53 /dev/tty62 /dev/ttyS12 /dev/ttyS21 /dev/ttyS30 /dev/tty0 /dev/tty18 /dev/tty27 /dev/tty36 /dev/tty45 /dev/tty54 /dev/tty63 /dev/ttyS13 /dev/ttyS22 /dev/ttyS31 /dev/tty1 /dev/tty19 /dev/tty28 /dev/tty37 /dev/tty46 /dev/tty55 /dev/tty7 /dev/ttyS14 /dev/ttyS23 /dev/ttyS4 /dev/tty10 /dev/tty2 /dev/tty29 /dev/tty38 /dev/tty47 /dev/tty56 /dev/tty8 /dev/ttyS15 /dev/ttyS24 /dev/ttyS5 /dev/tty11 /dev/tty20 /dev/tty3 /dev/tty39 /dev/tty48 /dev/tty57 /dev/tty9 /dev/ttyS16 /dev/ttyS25 /dev/ttyS6 /dev/tty12 /dev/tty21 /dev/tty30 /dev/tty4 /dev/tty49 /dev/tty58 /dev/ttyprintk /dev/ttyS17 /dev/ttyS26 /dev/ttyS7 /dev/tty13 /dev/tty22 /dev/tty31 /dev/tty40 /dev/tty5 /dev/tty59 /dev/ttyS0 /dev/ttyS18 /dev/ttyS27 /dev/ttyS8 /dev/tty14 /dev/tty23 /dev/tty32 /dev/tty41 /dev/tty50 /dev/tty6 /dev/ttyS1 /dev/ttyS19 /dev/ttyS28 /dev/ttyS9 /dev/tty15 /dev/tty24 /dev/tty33 /dev/tty42 /dev/tty51 /dev/tty60 /dev/ttyS10 /dev/ttyS2 /dev/ttyS29 /dev/ttyUSB0 /dev/tty16 /dev/tty25 /dev/tty34 /dev/tty43 /dev/tty52 /dev/tty61 /dev/ttyS11 /dev/ttyS20 /dev/ttyS3 /dev/ttyUSB1 oo@oo:~$ `

uEnv.txt modify below linux_boot_args_console console=ttyUSB1,115200 && boot

`

ikwzm commented 3 years ago

Please show me "all" contents of your uEnv.txt.

PapaKache commented 3 years ago

files in boot dir: `$ ls .

boot.bin image-5.4.0-xlnx-v2020.2-zynqmp-fpga devicetree-5.4.0-xlnx-v2020.2-zynqmp-fpga-ultra96v2.dtb uEnv-linux-5.4.0-xlnx-v2020.2-zynqmp-fpga.txt devicetree-5.4.0-xlnx-v2020.2-zynqmp-fpga-ultra96v2.dts uEnv.txt `

uEnv.txt contents: ######################################################################## //# Linux Kernel Files //# linux_kernel_image : Linux Kernel Image File Name //# linux_fdt_image : Linux Device Tree Blob File Name ######################################################################## linux_kernel_image=image-5.4.0-xlnx-v2020.2-zynqmp-fpga linux_fdt_image=devicetree-5.4.0-xlnx-v2020.2-zynqmp-fpga-ultra96v2.dtb

######################################################################## //# Linux Boot Argments //# linux_boot_args_console : ex) console=tty1 //# console=ttyPS0,115200 //# linux_boot_args_rootfs : ex) root=/dev/mmcblk0p2 rw rootwait //# linux_boot_args_systemd : ex) systemd.unit=graphical.target //# systemd.unit=multi-user.target //# linux_boot_args_cpuidle : ex) cpuidle.off=1 //# linux_boot_args_cma : ex) cma=256M //# linux_boot_args_uio : ex) uio=uio_pdrv_genirq.of_id=generic-uio //# * linux_boot_args_other : ######################################################################## linux_boot_args_console=console=tty1 linux_boot_args_rootfs=root=/dev/mmcblk0p2 rw rootwait linux_boot_args_systemd= linux_boot_args_cpuidle=cpuidle.off=1 linux_boot_args_cma= linux_boot_args_uio=uio_pdrv_genirq.of_id=generic-uio linux_boot_args_other=

######################################################################## //# uenvcmd : During sdboot, if uenvcmd is set, uenvcmd will be executed. ######################################################################## linux_img_load_cmd=fatload mmc ${sdbootdev}:${partid} ${kernel_addr} ${linux_kernel_image} linux_fdt_load_cmd=fatload mmc ${sdbootdev}:${partid} ${fdt_addr} ${linux_fdt_image} linux_load_cmd=env run linux_img_load_cmd && env run linux_fdt_load_cmd linux_boot_cmd=booti ${kernel_addr} - ${fdt_addr} linux_args_cmd=if env exists linux_boot_args; then; setenv bootargs ${linux_boot_args}; else; setenv bootargs ${linux_boot_args_console} ${linux_boot_args_rootfs} ${linux_boot_args_systemd} ${linux_boot_args_cpuidle} ${linux_boot_args_cma} ${linux_boot_args_uio} ${linux_boot_args_other}; fi uenvcmd=env run linux_args_cmd && env run linux_load_cmd && env run linux_boot_cmd

######################################################################## //# external_env_file : external environment file. //# external_env_boot : import external_env_file and boot. ######################################################################## external_env_existence_test=test -e mmc ${sdbootdev}:${partid} ${external_env_file} external_env_load=fatload mmc ${sdbootdev}:${partid} ${loadbootenv_addr} ${external_env_file} external_env_import=env import -t ${loadbootenv_addr} $filesize external_env_set=env run external_env_existence_test && env run external_env_load && env run external_env_import external_env_boot=if env run external_env_set; then; boot; else; echo "## Error Read fail " ${external_env_file}; fi

######################################################################## //# Select bootcmd_???? //# jtag : bootcmd_jtag = source $scriptaddr; echo SCRIPT FAILED: continuiing...; //# mmc0 : bootcmd_mmc0 = setenv devnum 0; run mmc_boot //# mmc1 : bootcmd_mmc1 = setenv devnum 1; run mmc_boot //# pxe : bootcmd_pxe = setenv run boot_net_usb_start; dhcp ; if pxe get; then pxe boot; fi //# usb0 : bootcmd_usb0 = setenv devnum 0; run usb_boot //# usb1 : bootcmd_usb1 = setenv devnum 1; run usb_boot //# * xilinx : bootcmd_xilinx = run $modeboot (modeboot=sdboot) ######################################################################## boot_targets=xilinx

######################################################################## //# Boot Menu Example - No Wait, console=tty1, systemd.unit=default ######################################################################## bootmenu_0=Boot Default=boot bootdelay=0

######################################################################## //# Boot Menu Example ######################################################################## //# bootmenu_0=Boot Default=boot //# bootmenu_1=Boot CUI on Display=env set linux_boot_args_systemd systemd.unit=multi-user.target && boot //# bootmenu_2=Boot CUI on ttyPS0=env set linux_boot_args_systemd systemd.unit=multi-user.target && env set linux_boot_args_console console=ttyUSB1,115200 && boot //# bootdelay=5

ikwzm commented 3 years ago

Set the environment variable "linux_boot_args_console" as follows Try changing it to "console = ttyPS0,115200".

linux_boot_args_console=console=ttyPS0,115200
########################################################################
# Linux Kernel Files
#  * linux_kernel_image : Linux Kernel Image File Name
#  * linux_fdt_image    : Linux Device Tree Blob File Name
########################################################################
linux_kernel_image=image-5.4.0-xlnx-v2020.2-zynqmp-fpga
linux_fdt_image=devicetree-5.4.0-xlnx-v2020.2-zynqmp-fpga-ultra96v2.dtb

########################################################################
# Linux Boot Argments
#  * linux_boot_args_console : ex) console=tty1
#                                  console=ttyPS0,115200
#  * linux_boot_args_rootfs  : ex) root=/dev/mmcblk0p2 rw rootwait
#  * linux_boot_args_systemd : ex) systemd.unit=graphical.target
#                                  systemd.unit=multi-user.target
#  * linux_boot_args_cpuidle : ex) cpuidle.off=1
#  * linux_boot_args_cma     : ex) cma=256M
#  * linux_boot_args_uio     : ex) uio=uio_pdrv_genirq.of_id=generic-uio
#  * linux_boot_args_other   :
########################################################################
linux_boot_args_console=console=ttyPS0,115200
linux_boot_args_rootfs=root=/dev/mmcblk0p2 rw rootwait
linux_boot_args_systemd=
linux_boot_args_cpuidle=cpuidle.off=1
linux_boot_args_cma=
linux_boot_args_uio=uio_pdrv_genirq.of_id=generic-uio
linux_boot_args_other=

########################################################################
# uenvcmd : During sdboot, if uenvcmd is set, uenvcmd will be executed.
########################################################################
linux_img_load_cmd=fatload mmc ${sdbootdev}:${partid} ${kernel_addr} ${linux_kernel_image}
linux_fdt_load_cmd=fatload mmc ${sdbootdev}:${partid} ${fdt_addr}    ${linux_fdt_image}
linux_load_cmd=env run linux_img_load_cmd && env run linux_fdt_load_cmd
linux_boot_cmd=booti ${kernel_addr} - ${fdt_addr}
linux_args_cmd=if env exists linux_boot_args; then; setenv bootargs ${linux_boot_args}; else; setenv bootargs ${linux_boot_args_console} ${linux_boot_args_rootfs} ${linux_boot_args_systemd} ${linux_boot_args_cpuidle} ${linux_boot_args_cma} ${linux_boot_args_uio} ${linux_boot_args_other}; fi
uenvcmd=env run linux_args_cmd && env run linux_load_cmd && env run linux_boot_cmd

########################################################################
# external_env_file : external environment file.
# external_env_boot : import external_env_file and boot.
########################################################################
external_env_existence_test=test -e mmc ${sdbootdev}:${partid} ${external_env_file}
external_env_load=fatload mmc ${sdbootdev}:${partid} ${loadbootenv_addr} ${external_env_file}
external_env_import=env import -t ${loadbootenv_addr} $filesize
external_env_set=env run external_env_existence_test && env run external_env_load && env run external_env_import
external_env_boot=if env run external_env_set; then; boot; else; echo "## Error Read fail " ${external_env_file}; fi

########################################################################
# Select bootcmd_????
#   * jtag   : bootcmd_jtag   = source $scriptaddr; echo SCRIPT FAILED: continuiing...;
#   * mmc0   : bootcmd_mmc0   = setenv devnum 0; run mmc_boot
#   * mmc1   : bootcmd_mmc1   = setenv devnum 1; run mmc_boot
#   * pxe    : bootcmd_pxe    = setenv run boot_net_usb_start; dhcp ; if pxe get; then pxe boot; fi
#   * usb0   : bootcmd_usb0   = setenv devnum 0; run usb_boot
#   * usb1   : bootcmd_usb1   = setenv devnum 1; run usb_boot
#   * xilinx : bootcmd_xilinx = run $modeboot (modeboot=sdboot)
########################################################################
boot_targets=xilinx

########################################################################
# Boot Menu Example - No Wait, console=tty1, systemd.unit=default
########################################################################
bootmenu_0=Boot Default=boot
bootdelay=0

########################################################################
# Boot Menu Example
########################################################################
# bootmenu_0=Boot Default=boot
# bootmenu_1=Boot CUI on Display=env set linux_boot_args_systemd systemd.unit=multi-user.target && boot
# bootmenu_2=Boot CUI on ttyPS0=env set linux_boot_args_systemd systemd.unit=multi-user.target && env set linux_boot_args_console console=ttyPS0,115200 && boot
# bootdelay=5