[SRU] Copy OpenSBI 1.3 to Jammy and Lunar

Bug #2026588 reported by Heinrich Schuchardt
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
opensbi (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
Undecided
Unassigned
Lunar
Fix Released
Undecided
Unassigned
u-boot (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
Undecided
Unassigned
Lunar
Fix Released
Undecided
Unassigned
u-boot-nezha (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
Undecided
Unassigned
Lunar
Fix Released
Undecided
Unassigned

Bug Description

[ Impact ]

We provide an image for the StarFive VisionFive 2 board. Upstream U-Boot now provides support for the board but it requires OpenSBI 1.3. We should strive to put a current U-Boot onto our preinstalled image.

[ Test plan ]

* Rebuild current u-boot package in ppa against new OpenSBI and test running Ubuntu 22.04/23.04 on QEMU, SiFive HiFive Unmatched, and PolarFire Icicle Kit with this U-Boot.
* Use a rebuilt u-boot-nezha package to boot the Nezha D1.
* Run apt-get update, apt-get install, and execute an application.
* Run snap install and execute an application.

[ Where problems could occur ]

OpenSBI is only used directly when running a RISC-V emulation in QEMU with the bios parameter.

For all real hardware OpenSBI is built into U-Boot SPL. So getting OpenSBI onto boards will require a rebuild of U-Boot.

Theoretically upgrading OpenSBI could

* stop RISC-V boards from booting
* cause failures when the operating system calls into OpenSBI
* cause failures when OpenSBI emulates missing instructions.

[ Other Info ]

Upgrading to the same OpenSBI 1.3 that we use in Mantic instead of applying selected patches to 22.04/23.04 is easier to maintain in the long run.

description: updated
Changed in opensbi (Ubuntu):
assignee: nobody → Heinrich Schuchardt (xypron)
Revision history for this message
Heinrich Schuchardt (xypron) wrote (last edit ):

opensbi - 1.3-1ubuntu0.23.04.1 is available in ppa:xypron/opensbi

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

opensbi - 1.3-1ubuntu0.22.04.1 is available in ppa:xypron/merge-from-debian

Changed in opensbi (Ubuntu):
assignee: Heinrich Schuchardt (xypron) → nobody
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Sponsored both the lunar and jammy versions, should now be in the unapproved queue. All that's needed is for someone from the SRU team to review and accept the packages.
Removing ubuntu-sponsors.

Changed in opensbi (Ubuntu):
status: New → Invalid
Changed in opensbi (Ubuntu Jammy):
status: New → In Progress
Changed in opensbi (Ubuntu Lunar):
status: New → In Progress
Revision history for this message
Robie Basak (racb) wrote :

> Rebuild current u-boot package in ppa against new OpenSBI and test running Ubuntu 22.04/23.04 on QEMU, SiFive HiFive Unmatched, and PolarFire Icicle Kit with this U-Boot.

If a rebuilt u-boot is required to solve the problem being addressed by this SRU, then shouldn't a u-boot SRU be included as part of this SRU, and they all be tested from -proposed together? Otherwise, if you're planning to build an image with this support with software sources that are not in the archive, then can't you include opensbi in that external source instead?

Changed in opensbi (Ubuntu Jammy):
status: In Progress → Incomplete
Changed in opensbi (Ubuntu Lunar):
status: In Progress → Incomplete
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

I think having a rebuilt u-boot is one part of the required fix, so there will be a follow-up u-boot SRU to rebuild against the new opensbi. The description mentions that the raw opensbi is used for qemu, so the test case for the qemu bits is already something.

I will accept the package into -proposed as-is so that it's ready for the u-boot rebuilds, but Heinrich please provide already all the u-boot debdiffs in the meantime. We can get those uploaded right after opensbi is built and require all of those released/tested at once.

Changed in opensbi (Ubuntu Jammy):
status: Incomplete → Confirmed
Changed in opensbi (Ubuntu Lunar):
status: Incomplete → Confirmed
Revision history for this message
Heinrich Schuchardt (xypron) wrote :
Revision history for this message
Heinrich Schuchardt (xypron) wrote :
Revision history for this message
Heinrich Schuchardt (xypron) wrote :
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Will we need to rebuild u-boot-nezha and/or nezha-boot0 as well?

Changed in opensbi (Ubuntu Lunar):
status: Confirmed → Fix Committed
tags: added: verification-needed verification-needed-lunar
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Heinrich, or anyone else affected,

Accepted opensbi into lunar-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/opensbi/1.3-1ubuntu0.23.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-lunar to verification-done-lunar. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-lunar. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in opensbi (Ubuntu Jammy):
status: Confirmed → Fix Committed
tags: added: verification-needed-jammy
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Heinrich, or anyone else affected,

Accepted opensbi into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/opensbi/1.3-1ubuntu0.22.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Heinrich Schuchardt (xypron) wrote :
description: updated
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Heinrich, or anyone else affected,

Accepted u-boot into lunar-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/u-boot/2022.10+dfsg-1ubuntu1.23.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-lunar to verification-done-lunar. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-lunar. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in u-boot (Ubuntu Lunar):
status: New → Fix Committed
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Heinrich, or anyone else affected,

Accepted u-boot into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/u-boot/2022.01+dfsg-2ubuntu2.4 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in u-boot (Ubuntu Jammy):
status: New → Fix Committed
Revision history for this message
Heinrich Schuchardt (xypron) wrote (last edit ):

Testing u-boot-sifive_2022.10+dfsg-1ubuntu1.23.04.1_riscv64.deb on SiFive HiFive Unmatched:
The build information "U-Boot 2022.10+dfsg-1ubuntu1.23.04.1 (Jul 20 2023 - 09:21:39 +0000)" is displayed.
The sbi command shows: OpenSBI 1.3.
Reboot from U-Boot works.
Reboot from Linux works.
Poweroff from Linux works.

Testing u-boot-sifive_2022.01+dfsg-2ubuntu2.4_riscv64.deb:
The build information "U-Boot 2022.01+dfsg-2ubuntu2.4 (Jul 20 2023 - 09:42:59 +0000)" is displayed.
The sbi command shows: OpenSBI 1.3.
Reboot from U-Boot works.
Reboot from Linux works.
Poweroff from Linux works.

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

Testing u-boot-microchip_2022.10+dfsg-1ubuntu1.23.04.1_riscv64.deb on Microchip PolarFire Icicle Kit:
The build information "U-Boot 2022.10+dfsg-1ubuntu1.23.04.1 (Jul 20 2023 - 09:21:39 +0000)" is displayed.
The sbi command shows: OpenSBI 1.0 (OpenSBI is not supplied by the Ubuntu package but by the HSS firmware).
Reboot from U-Boot works.
Reboot from Linux works.

Testing u-boot-microchip_2022.01+dfsg-2ubuntu2.4_riscv64.deb:
The build information "U-Boot 2022.01+dfsg-2ubuntu2.4 (Jul 20 2023 - 09:42:59 +0000)" is displayed.
The sbi command shows: OpenSBI 1.0 (OpenSBI is not supplied by the Ubuntu package but by the HSS firmware).
Reboot from U-Boot works.
Reboot from Linux works.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Heinrich, or anyone else affected,

Accepted u-boot-nezha into lunar-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/u-boot-nezha/2022.10-1089-g528ae9bc6c-0ubuntu1.23.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-lunar to verification-done-lunar. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-lunar. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in u-boot-nezha (Ubuntu):
status: New → Invalid
Changed in u-boot (Ubuntu):
status: New → Invalid
Changed in u-boot-nezha (Ubuntu Lunar):
status: New → Fix Committed
Changed in u-boot-nezha (Ubuntu Jammy):
status: New → Fix Committed
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello Heinrich, or anyone else affected,

Accepted u-boot-nezha into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/u-boot-nezha/2022.04+git20220405.7446a472-0ubuntu0.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

The updated u-boot-nezha packages work fine:

On the Sipeed Lichee RV u-boot-nezha_2022.10-1089-g528ae9bc6c-0ubuntu1.23.04.1_all.deb displays
U-Boot 2022.10 (Jul 20 2023 - 09:48:42 +0000) Allwinner Technology
The sbi commands shows "OpenSBI v1.3".
Reset in U-Boot is functional.
Reset from Linux is funcitonal.

On the Sipeed Lichee RV u-boot-nezha_2022.04+git20220405.7446a472-0ubuntu0.3_all.deb displays
U-Boot 2022.04 (Jul 20 2023 - 09:56:44 +0000)
The sbi commands shows "OpenSBI v1.3".
Reset in U-Boot is functional.
Reset from Linux is functional.

On the Allwinner Nezha D1 u-boot-nezha_2022.10-1089-g528ae9bc6c-0ubuntu1.23.04.1_all.deb displays
U-Boot 2022.10 (Jul 20 2023 - 09:48:42 +0000) Allwinner Technology
The sbi commands shows "OpenSBI v1.3".
Reset in U-Boot is functional.
Reset from Linux is funcitonal.

On the Allwinner Nezha D1 u-boot-nezha_2022.04+git20220405.7446a472-0ubuntu0.3_all.deb displays
U-Boot 2022.04 (Jul 20 2023 - 09:56:44 +0000)
The sbi commands shows "OpenSBI v1.3".
Reset in U-Boot is functional.
Reset from Linux is functional.

tags: added: verification-done verification-done-jammy verification-done-lunar
removed: verification-needed verification-needed-jammy verification-needed-lunar
Revision history for this message
Robie Basak (racb) wrote :

The agreed test plan also included these steps:

> * Run apt-get update, apt-get install, and execute an application.
> * Run snap install and execute an application.

But I don't see any mention of this in your verification reports. Was this done?

Additionally bug 1995860 is not verified yet, and presumably we want to release these three packages together?

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

On Nezha D1, LicheeRV Dock, SiFive Unmatched, Microchip PolarFire Icicle Kit using the updated U-Boot for Jammy or Lunar respectively the following worked successfully:

* sudo apt-get update && sudo apt-get install hello && hello
* sudo snap install hello && /snap/bin/hello

Revision history for this message
Heinrich Schuchardt (xypron) wrote :

Also on QEMU testing runs fine.

Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for opensbi has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opensbi - 1.3-1ubuntu0.23.04.1

---------------
opensbi (1.3-1ubuntu0.23.04.1) lunar; urgency=medium

  * New upstream release (LP: #2026588)

opensbi (1.1-2) unstable; urgency=medium

  [ Lintian Brush ]
  * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
    Repository-Browse.

  [ Heinrich Schuchardt ]
  * Fix emulation of fence.tso hanging in endless loop on Allwinner D1
    d/p/lib-sbi_illegal_insn-Fix-FENCE.TSO-emulation-infinit.patch (LP:
    #1995860) (Closes: #1023616)

 -- Heinrich Schuchardt <email address hidden> Wed, 12 Jul 2023 14:43:34 +0200

Changed in opensbi (Ubuntu Lunar):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package u-boot - 2022.10+dfsg-1ubuntu1.23.04.1

---------------
u-boot (2022.10+dfsg-1ubuntu1.23.04.1) lunar; urgency=medium

  * Rebuild against updated OpenSBI (LP: #2026588)
  * Enable sbi command on riscv64 to check OpenSBI version

 -- Heinrich Schuchardt <email address hidden> Thu, 20 Jul 2023 11:21:39 +0200

Changed in u-boot (Ubuntu Lunar):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package u-boot-nezha - 2022.10-1089-g528ae9bc6c-0ubuntu1.23.04.1

---------------
u-boot-nezha (2022.10-1089-g528ae9bc6c-0ubuntu1.23.04.1) lunar; urgency=medium

  * Rebuild against updated OpenSBI (LP: #2026588)
  * Enable sbi command on riscv64 to check OpenSBI version

 -- Heinrich Schuchardt <email address hidden> Thu, 20 Jul 2023 11:48:42 +0200

Changed in u-boot-nezha (Ubuntu Lunar):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opensbi - 1.3-1ubuntu0.22.04.1

---------------
opensbi (1.3-1ubuntu0.22.04.1) jammy; urgency=medium

  * SRU OpenSBI 1.3 to Jammy (LP: #2026588)

opensbi (1.3-1) unstable; urgency=medium

  * New upstream release.
  * debian/copyright: Update for v1.3.

opensbi (1.2-1) unstable; urgency=medium

  * debian/watch: Update for new upstream source location.
  * Update upstream URLs.
  * debian/copyright: Update for v1.2.
  * debian/patches: Drop all patches, applied upstream.
  * debian/control: Add Build-Depends on python3.
  * debian/control: Update to Standards-Version 4.6.2.

opensbi (1.1-2) unstable; urgency=medium

  [ Lintian Brush ]
  * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
    Repository-Browse.

  [ Heinrich Schuchardt ]
  * Fix emulation of fence.tso hanging in endless loop on Allwinner D1
    d/p/lib-sbi_illegal_insn-Fix-FENCE.TSO-emulation-infinit.patch (LP:
    #1995860) (Closes: #1023616)

 -- Heinrich Schuchardt <email address hidden> Mon, 10 Jul 2023 09:26:57 +0200

Changed in opensbi (Ubuntu Jammy):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package u-boot - 2022.01+dfsg-2ubuntu2.4

---------------
u-boot (2022.01+dfsg-2ubuntu2.4) jammy; urgency=medium

  * Rebuild against updated OpenSBI (LP: #2026588)
  * Enable sbi command on riscv64 to check OpenSBI version

 -- Heinrich Schuchardt <email address hidden> Thu, 20 Jul 2023 11:42:59 +0200

Changed in u-boot (Ubuntu Jammy):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package u-boot-nezha - 2022.04+git20220405.7446a472-0ubuntu0.3

---------------
u-boot-nezha (2022.04+git20220405.7446a472-0ubuntu0.3) jammy; urgency=medium

  * Rebuild against updated OpenSBI (LP: #2026588)
  * Enable sbi command on riscv64 to check OpenSBI version

 -- Heinrich Schuchardt <email address hidden> Thu, 20 Jul 2023 11:56:44 +0200

Changed in u-boot-nezha (Ubuntu Jammy):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.