Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Control: tags 839595 pending Pushed a commit to git: https://anonscm.debian.org/git/d-i/flash-kernel.git/commit/?id=175f11c79927fbc9527f5cce1bdfd2ad60d3ed50 Should be included in the next upload. live well, vagrant signature.asc Description: PGP signature
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi Vagrant, thanks for the reply. On Sun, 23 Jul 2017 12:56:35 -0400 Vagrant Cascadian wrote: > On a related note, nobody has requested the clearfog target be enabled > in the u-boot packages in Debian: > > https://wiki.debian.org/U-boot/ > > If someone can offer to regularly test that, I'd be happy to enable it > in u-boot. I'd be happy to do that, what is the process? > > > I don't think that should be a blocker for including it into > flash-kernel, though. > > > live well, > vagrant
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
On 2017-07-23, Josua Mayer wrote: > Can anyone state the status here? If there is somethign missing, I'd be > perfectly willing to conduct some tests on my board if necessary. It looks like clearfog supports distro_bootcmd in mainline u-boot 2017.07 shipped in buster, including CONFIG_SUPPORT_RAW_INITRD, which is required to boot an initrd without u-boot headers. On a related note, nobody has requested the clearfog target be enabled in the u-boot packages in Debian: https://wiki.debian.org/U-boot/ If someone can offer to regularly test that, I'd be happy to enable it in u-boot. I don't think that should be a blocker for including it into flash-kernel, though. live well, vagrant signature.asc Description: PGP signature
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
* Christoph Egger [2016-12-27 17:55]: > Christoph Egger writes: > > I haven't updated u-boot yet, though it's still on my todo > > Seems to have worked. I have now u-boot 2016-11 SPL and "normal" > u-boot and everything works so far \o/ Karsten, I think this one is waiting for you. Can you take a look? -- Martin Michlmayr http://www.cyrius.com/
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Christoph Egger writes: > I haven't updated u-boot yet, though it's still on my todo Seems to have worked. I have now u-boot 2016-11 SPL and "normal" u-boot and everything works so far \o/ Christoph signature.asc Description: PGP signature
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi all! Christoph Egger writes: > I'll try to get the results today/tomorrow night .. if I don't reply > it'll be mid-january unfortunately I added the snippet to /etc/flash-kernel/db now. I had to do the following further steps (but I guess that's expected): - put the adapted dtb at the kernel location (where flash-kernel copies it from) - fw_setenv distro_bootpart 2 - actually configure flash-kernel to include root=/dev/mmcblk0p1 in the kernel comandline Indeed it seems to boot with the initrd now just fine! I haven't updated u-boot yet, though it's still on my todo .. only have my kfreebsd notebook with me so I might only get one try unless kwboot uart recovery is made to work on this platform. Christoph signature.asc Description: PGP signature
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Martin Michlmayr writes: > I was just looking at this bug report and it seems Karsten was never > copied on Christoph's last email (see below). Sorry for that. And I just didn't want to nag if people are busy. Karsten Merker writes: > that looks good. With this environment, using the "generic" > boot script should work. > > Christoph, could you perform a test with a current u-boot by > applying my environment patch on top of u-boot v2016.11 and > putting the follwing stanza into /etc/flash-kernel/db ? > > Machine: SolidRun Clearfog A1 > Kernel-Flavors: armmp armmp-lpae > Boot-Script-Path: /boot/boot.scr > DTB-Id: armada-388-clearfog.dtb > U-Boot-Script-Name: bootscr.uboot-generic > Required-Packages: u-boot-tools > > (This stanza is based on the assumption that booting plain > initrds works when bootz is passed the corresponding filesize. I > still don't understand why you got a "Wrong Ramdisk Image Format" > when manually booting a plain initrd with u-boot v2016.09.) > > With the aforementioned stanza, running flash-kernel on the > commandline should generate a proper boot script in > /boot/boot.scr that should be automatically loaded by u-boot on > reboot. I'll try to get the results today/tomorrow night .. if I don't reply it'll be mid-january unfortunately Christoph signature.asc Description: PGP signature
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
I was just looking at this bug report and it seems Karsten was never copied on Christoph's last email (see below). * Christoph Egger [2016-10-24 15:22]: > Hi! > > This seems to be the "new" default environment: > > => printenv > arch=arm > baudrate=115200 > board=clearfog > board_name=clearfog > boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} > ${prefix}${script}; source ${scriptaddr} > boot_efi_binary=load ${devtype} ${devnum}:${distro_bootpart} ${kernel_addr_r} > efi/boot/bootarm.efi; if fdt addr ${fdt_addr_r}; then bootefi > ${kernel_addr_r} ${fdt_addr_r};else bootefi ${kernel_addr_r} > ${fdtcontroladdr};fi > boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any > ${scriptaddr} ${prefix}extlinux/extlinux.conf > boot_net_usb_start=usb start > boot_prefixes=/ /boot/ > boot_script_dhcp=boot.scr.uimg > boot_scripts=boot.scr.uimg boot.scr > boot_targets=mmc0 usb0 pxe dhcp > bootcmd=run distro_bootcmd > bootcmd_dhcp=run boot_net_usb_start; if dhcp ${scriptaddr} > ${boot_script_dhcp}; then source ${scriptaddr}; fi;setenv efi_fdtfile > ${fdtfile}; if test -z "${fdtfile}" -a -n "${soc}"; then setenv efi_fdtfile > ${soc}-${board}${boardver}.dtb; fi; setenv efi_old_vci ${bootp_vci};setenv > efi_old_arch ${bootp_arch};setenv bootp_vci > PXEClient:Arch:00010:UNDI:003000;setenv bootp_arch 0xa;if dhcp > ${kernel_addr_r}; then tftpboot ${fdt_addr_r} dtb/${efi_fdtfile};if fdt addr > ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r}; else bootefi > ${kernel_addr_r} ${fdtcontroladdr};fi;fi;setenv bootp_vci > ${efi_old_vci};setenv bootp_arch ${efi_old_arch};setenv efi_fdtfile;setenv > efi_old_arch;setenv efi_old_vci; > bootcmd_mmc0=setenv devnum 0; run mmc_boot > bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi > bootcmd_usb0=setenv devnum 0; run usb_boot > bootdelay=3 > console=ttyS0,115200 > cpu=armv7 > devnum=0 > devplist=1 > devtype=mmc > distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done > efi_dtb_prefixes=/ /dtb/ /dtb/current/ > fdt_addr_r=0x10 > fdt_high=0x1000 > fdtcontroladdr=3fb4ce58 > fdtfile=armada-388-clearfog.dtb > initrd_high=0x1000 > kernel_addr_r=0x80 > load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} > ${prefix}${efi_fdtfile} > mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run > scan_dev_for_boot_part; fi > pxefile_addr_r=0x30 > ramdisk_addr_r=0x180 > scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; > for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run > scan_dev_for_scripts; done;run scan_dev_for_efi; > scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env > exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do > if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run > scan_dev_for_boot; fi; done > scan_dev_for_efi=setenv efi_fdtfile ${fdtfile}; if test -z "${fdtfile}" -a -n > "${soc}"; then setenv efi_fdtfile ${soc}-${board}${boardver}.dtb; fi; for > prefix in ${efi_dtb_prefixes}; do if test -e ${devtype} > ${devnum}:${distro_bootpart} ${prefix}${efi_fdtfile}; then run load_efi_dtb; > fi;done;if test -e ${devtype} ${devnum}:${distro_bootpart} > efi/boot/bootarm.efi; then echo Found EFI removable media binary > efi/boot/bootarm.efi; run boot_efi_binary; echo EFI LOAD FAILED: > continuing...; fi; setenv efi_fdtfile > scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} > ${prefix}extlinux/extlinux.conf; then echo Found > ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: > continuing...; fi > scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} > ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot > script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: > continuing...; fi; done > scriptaddr=0x20 > soc=mvebu > stderr=serial@12000 > stdin=serial@12000 > stdout=serial@12000 > usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run > scan_dev_for_boot_part; fi > vendor=solidrun > > Environment size: 3819/65532 bytes > > > -- > 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 > Debian Developer | Lisp Hacker | CaCert Assurer -- Martin Michlmayr http://www.cyrius.com/
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! This seems to be the "new" default environment: => printenv arch=arm baudrate=115200 board=clearfog board_name=clearfog boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr} boot_efi_binary=load ${devtype} ${devnum}:${distro_bootpart} ${kernel_addr_r} efi/boot/bootarm.efi; if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r};else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf boot_net_usb_start=usb start boot_prefixes=/ /boot/ boot_script_dhcp=boot.scr.uimg boot_scripts=boot.scr.uimg boot.scr boot_targets=mmc0 usb0 pxe dhcp bootcmd=run distro_bootcmd bootcmd_dhcp=run boot_net_usb_start; if dhcp ${scriptaddr} ${boot_script_dhcp}; then source ${scriptaddr}; fi;setenv efi_fdtfile ${fdtfile}; if test -z "${fdtfile}" -a -n "${soc}"; then setenv efi_fdtfile ${soc}-${board}${boardver}.dtb; fi; setenv efi_old_vci ${bootp_vci};setenv efi_old_arch ${bootp_arch};setenv bootp_vci PXEClient:Arch:00010:UNDI:003000;setenv bootp_arch 0xa;if dhcp ${kernel_addr_r}; then tftpboot ${fdt_addr_r} dtb/${efi_fdtfile};if fdt addr ${fdt_addr_r}; then bootefi ${kernel_addr_r} ${fdt_addr_r}; else bootefi ${kernel_addr_r} ${fdtcontroladdr};fi;fi;setenv bootp_vci ${efi_old_vci};setenv bootp_arch ${efi_old_arch};setenv efi_fdtfile;setenv efi_old_arch;setenv efi_old_vci; bootcmd_mmc0=setenv devnum 0; run mmc_boot bootcmd_pxe=run boot_net_usb_start; dhcp; if pxe get; then pxe boot; fi bootcmd_usb0=setenv devnum 0; run usb_boot bootdelay=3 console=ttyS0,115200 cpu=armv7 devnum=0 devplist=1 devtype=mmc distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done efi_dtb_prefixes=/ /dtb/ /dtb/current/ fdt_addr_r=0x10 fdt_high=0x1000 fdtcontroladdr=3fb4ce58 fdtfile=armada-388-clearfog.dtb initrd_high=0x1000 kernel_addr_r=0x80 load_efi_dtb=load ${devtype} ${devnum}:${distro_bootpart} ${fdt_addr_r} ${prefix}${efi_fdtfile} mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi pxefile_addr_r=0x30 ramdisk_addr_r=0x180 scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;run scan_dev_for_efi; scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done scan_dev_for_efi=setenv efi_fdtfile ${fdtfile}; if test -z "${fdtfile}" -a -n "${soc}"; then setenv efi_fdtfile ${soc}-${board}${boardver}.dtb; fi; for prefix in ${efi_dtb_prefixes}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${efi_fdtfile}; then run load_efi_dtb; fi;done;if test -e ${devtype} ${devnum}:${distro_bootpart} efi/boot/bootarm.efi; then echo Found EFI removable media binary efi/boot/bootarm.efi; run boot_efi_binary; echo EFI LOAD FAILED: continuing...; fi; setenv efi_fdtfile scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done scriptaddr=0x20 soc=mvebu stderr=serial@12000 stdin=serial@12000 stdout=serial@12000 usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi vendor=solidrun Environment size: 3819/65532 bytes -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Karsten Merker writes: > The attached patch enables CONFIG_DISTRO_DEFAULTS and includes > the necessary headers to define the common environment (only > build-tested due to lack of appropriate hardware). One thing > that is still missing in the patch is the definition of various > default load addresses (fdt_addr_r, ramdisk_addr_r, > kernel_addr_r, pxefile_addr_r, scriptaddr). Is there an > "official" list of the standard load addresses for this platform > so that I could add them to the patch? I don't know any > Could you please build u-boot with the attached patch and > send the output of "env default -f -a; printenv"? => env default -f -a ## Resetting to default environment => printenv arch=arm baudrate=115200 board=clearfog board_name=clearfog bootcmd=run distro_bootcmd bootdelay=3 cpu=armv7 fdt_high=0x1000 initrd_high=0x1000 soc=mvebu vendor=solidrun Environment size: 201/65532 bytes -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Karsten Merker writes: > ext4load mmc 0:2 0x10 armada-388-clearfog.dtb ; ext4load mmc 0:2 > 0x80 vmlinuz-4.7.0-1-armmp ; ext4load mmc 0:2 0x180 > initrd.img-4.7.0-1-armmp ; bootz 0x80 0x180:${filesize} > 0x10 => ext4load mmc 0:2 0x10 armada-388-clearfog.dtb ; ext4load mmc 0:2 0x80 vmlinuz-4.7.0-1-armmp ; ext4load mmc 0:2 0x180 initrd.img-4.7.0-1-armmp ; bootz 0x80 0x180:${filesize} 0x10 18060 bytes read in 79 ms (222.7 KiB/s) 3699848 bytes read in 237 ms (14.9 MiB/s) 15981995 bytes read in 796 ms (19.1 MiB/s) Wrong Ramdisk Image Format Ramdisk image is corrupt or invalid -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Karsten Merker writes: > Well, that is a _very_ minimalistic default environment ;-). > So there isn't any boot command handling at all in the default > environment of mainline u-boot for this system, which poses a > problem for supporting this setup in flash-kernel. I supposed this is CONFIG_DISTRO_DEFAULTS? I'll rebuild u-boot and see (also for the plain initrd) Christoph -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Hi! Karsten Merker writes: > is this the environment from mainline u-boot or the environment > from the original Marvell u-boot? I ask because there are a few > things that look a bit uncommon to me: This is a mainline 2016.9 u-boot (clearfog_defconfig) > - The bootcmd loads the kernel as a zImage but the initrd as a > uImage, which is a very unusual combination and I am unsure > whether that could even work properly. The normal case is > either loading the kernel as a zImage and the initrd as a plain > initrd image and booting them with bootz, or loading both the > kernel and the initrd as uImages and booting them with bootm. Works fine: | => ext4load mmc 0:2 0x10 armada-388-clearfog.dtb ; ext4load mmc 0:2 0x80 vmlinuz-4.7.0-1-armmp ; ext4load mmc 0:2 0x180 initrd.img-4.7.0-1-armmp.uimage ; bootz 0x80 0x180 0x10 | 18060 bytes read in 79 ms (222.7 KiB/s) | 3699848 bytes read in 237 ms (14.9 MiB/s) | 15982059 bytes read in 787 ms (19.4 MiB/s) | ## Loading init Ramdisk from Legacy Image at 0180 ... |Image Name: initrd.img-4.7.0-1-armmp |Image Type: ARM Linux RAMDisk Image (uncompressed) |Data Size:15981995 Bytes = 15.2 MiB |Load Address: |Entry Point: |Verifying Checksum ... OK | ## Flattened Device Tree blob at 0010 |Booting using the fdt blob at 0x10 |Loading Ramdisk to 0f0c2000, end 0dab ... OK |Loading Device Tree to 0f0ba000, end 0f0c168b ... OK | | Starting kernel ... With plain initrd: | => ext4load mmc 0:2 0x10 armada-388-clearfog.dtb ; ext4load mmc 0:2 0x80 vmlinuz-4.7.0-1-armmp ; ext4load mmc 0:2 0x180 initrd.img-4.7.0-1-armmp ; bootz 0x80 0x180 0x10 | 18060 bytes read in 79 ms (222.7 KiB/s) | 3699848 bytes read in 237 ms (14.9 MiB/s) | 15981995 bytes read in 796 ms (19.1 MiB/s) | Wrong Ramdisk Image Format | Ramdisk image is corrupt or invalid > Is mmc0 an SD card or an EMMC chip? Have you upgraded the system > from a marvell u-boot to a mainline u-boot or has it been set up > from scratch with a mainline u-boot? I ask because mainline > u-boot by default keeps the existing environment on upgrade, so > if you have upgraded the system from a marvell u-boot to a > mainline u-boot, you might still have an old non-mainline > environment. eMMC chip. as far as I know there was no u-boot shipped on the eMMC (booting via UART works quite well) > You could try running "env default -f -a" at the u-boot prompt, > which would reset your active environment to the default > environment of the u-boot version you are currently running. | => env default -f -a | ## Resetting to default environment | => printenv | baudrate=115200 | bootdelay=3 | fdt_high=0x1000 | initrd_high=0x1000 | | Environment size: 80/65532 bytes Christoph -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer
Bug#839595: flash-kernel: Please add support for SolidRun Clearfog
Package: flash-kernel Version: 3.69 Severity: wishlist Hi! Please consider adding clearfog support. The system works fine with mainline u-boot + kernel. Hopefully I have added all necessary information below: | Machine: SolidRun Clearfog A1 | Kernel-Flavors: armmp armmp-lpae | DTB-Id: armada-388-clearfog.dtb | Required-Packages: u-boot-tools | # fw_printenv | baudrate=115200 | bootargs=console=ttyS0,115200n8 rootdelay=10 bootwait=10 rootwait=10 root=/dev/mmcblk0p1 | bootcmd=ext4load mmc 0:2 0x10 dtb ; ext4load mmc 0:2 0x80 vmlinuz-4.7.0-1-armmp ; ext4load mmc 0:2 0x180 initrd.img-4.7.0-1-armmp.uimage ; bootz 0x80 0x180 0x10 | dnsip=10.100.3.2 | eth1addr=48:5b:39:c9:ec:74 | eth2addr=48:5b:39:c9:ec:75 | eth3addr=48:5b:39:c9:ec:76 | ethact=ethernet@3 | ethprime=egiga1 | fdt_high=0x1000 | fdtcontroladdr=3fb51e58 | fileaddr=10 | filesize=4961 | gatewayip=10.100.3.1 | initrd_high=0x1000 | ipaddr=10.100.3.3 | netmask=255.255.255.224 | serverip=10.100.3.2 | stderr=serial@12000 | stdin=serial@12000 | stdout=serial@12000 | bootdelay=5 | # cat /etc/fw_env.config | /dev/mmcblk0 0xf 0x1 0x1000 Regards Christoph -- System Information: Debian Release: stretch/sid APT prefers testing APT policy: (500, 'testing') Architecture: armhf (armv7l) Kernel: Linux 4.7.0-1-armmp (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages flash-kernel depends on: ii debconf [debconf-2.0] 1.5.59 ii devio 1.2-1.2 ii initramfs-tools0.125 ii linux-base 4.5 ii mtd-utils 1:1.5.2-1 ii ucf3.0036 Versions of packages flash-kernel recommends: ii u-boot-tools 2016.03+dfsg1-6 flash-kernel suggests no packages. -- debconf information excluded -- 9FED 5C6C E206 B70A 5857 70CA 9655 22B9 D49A E731 Debian Developer | Lisp Hacker | CaCert Assurer