Re: U-boot menu support in Debian
On Tue, Jan 17, 2017 at 03:59:33PM +, Riku Voipio wrote: > I guess I'll push it to it's own package, since not all u-boot-tools > may want a menu. Done now: https://tracker.debian.org/pkg/u-boot-menu
Re: U-boot menu support in Debian
On Sun, Jan 15, 2017 at 12:03:05PM -0800, Vagrant Cascadian wrote: > On 2017-01-05, Riku Voipio wrote: > > I only recently noticed that Debian doesn't seem use U-boot > > support for extlinux style boot menus. This makes jumping > > between kernel versions frustrating. > > > > I've taken the old syslinux support for menu generation and > > re-purposed it for u-boot: > > > > https://github.com/suihkulokki/u-boot-update > > Thanks for working on this! > > This would also be good to do for debian-installer images (one concern > was how widespread support for the "chosen" console was, as there was no > way to pass the console via extlinux.conf in a platform agnostic way). I see the console from dtb worksforme, and adding it to missing DTB's should be easy. > > Note location is temporary, I don't know if this is > > preferrable as independent package, part of flash-kernel > > or even u-boot package itself. > Indeed. On the one hand, it'd be nice to keep it outside of > flash-kernel, so as not to require flash-kernel and it's dependencies. Rethinking, the only link I get for flash-kernel, is the dtb name / device model name map which could be used to set the FDT setting. > I could include it in the u-boot-tools package, but I'd want it to > default to doing nothing out of the box, if someone is relying on a boot > script this could break their boot configuration. It could also be > implemented as a separate package and enabled by default; probably too > late for stretch, though. I guess I'll push it to it's own package, since not all u-boot-tools may want a menu. > I've submitted a pull request that fixes an issue with falling back to > using "fdtdir" and make the "fdtdir" configurable via a variable to > improve compatibility with flash-kernel or when /boot is on a separate > partition: > > https://github.com/suihkulokki/u-boot-update/pull/1 Thanks, applied. > My workaround was to use flash-kernel to copy the dtb into /boot (which > I had to do anyways, since /boot was on a separate partition), and > configure /boot/dtbs/$VERSION in my patches above. Yeah, separate /boot doesn't work with DTBs out of box. Riku
Re: U-boot menu support in Debian
On 2017-01-05, Riku Voipio wrote: > I only recently noticed that Debian doesn't seem use U-boot > support for extlinux style boot menus. This makes jumping > between kernel versions frustrating. > > I've taken the old syslinux support for menu generation and > re-purposed it for u-boot: > > https://github.com/suihkulokki/u-boot-update Thanks for working on this! Karsten Merker, Ian Campbell and I had a bit of a discussion during Debconf15 about doing exactly this, and then I discovered it was removed From the syslinux/extlinux packages and put it on the back burner... This would also be good to do for debian-installer images (one concern was how widespread support for the "chosen" console was, as there was no way to pass the console via extlinux.conf in a platform agnostic way). > Note location is temporary, I don't know if this is > preferrable as independent package, part of flash-kernel > or even u-boot package itself. Indeed. On the one hand, it'd be nice to keep it outside of flash-kernel, so as not to require flash-kernel and it's dependencies. I could include it in the u-boot-tools package, but I'd want it to default to doing nothing out of the box, if someone is relying on a boot script this could break their boot configuration. It could also be implemented as a separate package and enabled by default; probably too late for stretch, though. > Setting this up for Dragonboard 410c is matter of: > > # echo U_BOOT_FDT=\"qcom/apq8016-sbc.dtb\" > /etc/default/u-boot > > This could be truly platform agnostic by using the > the "fdtdir" keyword in the menu. However, on u-boot the > fdtfile is "apq8016-sbc.dtb", missing the qcom/ directory > prefix. We need to submit a patch for u-boot to search device > tree from vendor sub-dirs too. Yes, that would be nice. I made a couple fixes for my use-case and tested with pine64. I've submitted a pull request that fixes an issue with falling back to using "fdtdir" and make the "fdtdir" configurable via a variable to improve compatibility with flash-kernel or when /boot is on a separate partition: https://github.com/suihkulokki/u-boot-update/pull/1 My workaround was to use flash-kernel to copy the dtb into /boot (which I had to do anyways, since /boot was on a separate partition), and configure /boot/dtbs/$VERSION in my patches above. live well, vagrant signature.asc Description: PGP signature
U-boot menu support in Debian
Hi, I only recently noticed that Debian doesn't seem use U-boot support for extlinux style boot menus. This makes jumping between kernel versions frustrating. I've taken the old syslinux support for menu generation and re-purposed it for u-boot: https://github.com/suihkulokki/u-boot-update Note location is temporary, I don't know if this is preferrable as independent package, part of flash-kernel or even u-boot package itself. Setting this up for Dragonboard 410c is matter of: # echo U_BOOT_FDT=\"qcom/apq8016-sbc.dtb\" > /etc/default/u-boot This could be truly platform agnostic by using the the "fdtdir" keyword in the menu. However, on u-boot the fdtfile is "apq8016-sbc.dtb", missing the qcom/ directory prefix. We need to submit a patch for u-boot to search device tree from vendor sub-dirs too. Now that the device tree is set, the only thing to make it work on any new u-boot with distro_bootcmd set is generating and using the menu: # u-boot-update P: Checking for EXTLINUX directory... found. P: Writing config for /boot/vmlinuz-4.9.0-rc8-arm64... P: Writing config for /boot/vmlinuz-4.8.0-rc8-arm64... P: Writing config for /boot/vmlinuz-4.4.23-linaro-lt-qcom... P: Updating /boot/extlinux/extlinux.conf... # reboot ... U-Boot 2016.09+dfsg1-1 (Sep 12 2016 - 19:43:29 +) ... Scanning mmc 0:a... Found /boot/extlinux/extlinux.conf Retrieving file: /boot/extlinux/extlinux.conf 1965 bytes read in 99 ms (18.6 KiB/s) U-Boot menu 1: Debian GNU/Linux kernel 4.9.0-rc8-arm64 2: Debian GNU/Linux kernel 4.9.0-rc8-arm64 (rescue target) 3: Debian GNU/Linux kernel 4.8.0-rc8-arm64 4: Debian GNU/Linux kernel 4.8.0-rc8-arm64 (rescue target) 5: Debian GNU/Linux kernel 4.4.23-linaro-lt-qcom 6: Debian GNU/Linux kernel 4.4.23-linaro-lt-qcom (rescue target) Enter choice: 5 5: Debian GNU/Linux kernel 4.4.23-linaro-lt-qcom Retrieving file: /boot/initrd.img-4.4.23-linaro-lt-qcom 4658722 bytes read in 596 ms (7.5 MiB/s) Retrieving file: /boot/vmlinuz-4.4.23-linaro-lt-qcom 13888000 bytes read in 1552 ms (8.5 MiB/s) append: root=/dev/disk/by-partlabel/rootfs rw rootwait Retrieving file: /usr/lib/linux-image-4.4.23-linaro-lt-qcom/qcom/apq8016-sbc.dtb 70369 bytes read in 440 ms (155.3 KiB/s) ## Flattened Device Tree blob at 8300 Booting using the fdt blob at 0x8300 Using Device Tree in place at 8300, end 830142e0 Starting kernel ... [0.00] Booting Linux on physical CPU 0x0