[Bug 2052693] Re: u-boot-starfive does not contain a postinst script to update the board after package installation
scottfk
2052693 at bugs.launchpad.net
Thu Feb 8 12:42:21 UTC 2024
Still there.
$ uname -a
Linux venus3 6.5.0-14-generic #14.1-Ubuntu SMP Fri Nov 24 06:09:26 UTC 2023 riscv64 riscv64 riscv64 GNU/Linux
/dev/mtd/by-name$ ls -l
total 0
lrwxrwxrwx 1 root root 10 Jan 24 20:53 reserved-data -> ../../mtd3
lrwxrwxrwx 1 root root 10 Jan 24 20:53 spl -> ../../mtd0
lrwxrwxrwx 1 root root 10 Jan 24 20:53 uboot -> ../../mtd2
lrwxrwxrwx 1 root root 10 Jan 24 20:53 uboot-env -> ../../mtd1
(time/date are always wrong until systemd-timesyncd starts and puts
things right:
$ last -1 reboot
reboot system boot 6.5.0-14-generic Wed Jan 24 20:53 still running
wtmp begins Tue Sep 19 17:54:34 2023
$ timedatectl
Local time: Thu 2024-02-08 13:41:50 CET
Universal time: Thu 2024-02-08 12:41:50 UTC
RTC time: n/a
Time zone: Europe/Zurich (CET, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
)
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to u-boot in Ubuntu.
https://bugs.launchpad.net/bugs/2052693
Title:
u-boot-starfive does not contain a postinst script to update the board
after package installation
Status in u-boot package in Ubuntu:
New
Bug description:
u-boot-starfive distributes updates to SPL and U-Boot, but it does
not flash them to the board. I think it would be useful if it
followed the pattern of u-boot-sifive and included a postinst script
to update the board.
The script could look something like this. NB: I only have access to
a StarFive VisionFive 2 v1.3B board. Not sure if the other revisions
are compatible with the SPL and U-Boot images in the u-boot-starfive
package:
#!/bin/sh
##
set -e
case "$1" in
configure)
target=""
if grep -q '^StarFive VisionFive 2 v1.3B$' /sys/firmware/devicetree/base/model; then
target="starfive_visionfive2"
fi
if [ -n "$target" ] && [ -e /dev/mtd/by-name/spl ] && [ -e /dev/mtd/by-name/uboot ]; then
flashcp -v /usr/lib/u-boot/$target/u-boot-spl.bin.normal.out /dev/mtd/by-name/spl
flashcp -v /usr/lib/u-boot/$target/u-boot.itb /dev/mtd/by-name/uboot
fi
;;
esac
exit 0
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/u-boot/+bug/2052693/+subscriptions
More information about the foundations-bugs
mailing list