grub exit on arm64-efi crashes

Bug #1731241 reported by Ike Panhc on 2017-11-09
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Undecided
Unassigned
Xenial
Undecided
Ike Panhc

Bug Description

[Impact]

 * grub exit on arm64-efi causes EFI exception, requiring reboot to recover.

[Test Case]

 * Using grub cmdline and exit shall return to UEFI

[Regression Potential]

 * Low regression risk due to
   - Only codes on exit with efi platform modified
   - patch cherry-picked from upstream and already in grub2 since zesty

[Other Info]

 * Patch on upstream

commit c945ca75c3b2b900040b905323b1226cb60a1166
Author: Mark Salter <email address hidden>
Date: Fri Aug 15 12:22:43 2014 -0400

    Fix exit to EFI firmware

    The current code for EFI grub_exit() calls grub_efi_fini() before
    returning to firmware. In the case of ARM, this leaves a timer
    event running which could lead to a firmware crash. This patch
    changes this so that grub_machine_fini() is called with a NORETURN
    flag. This allows machine-specific shutdown to happen as well
    as the shutdown done by grub_efi_fini().

    Signed-off-by: Mark Salter <email address hidden>

Ike Panhc (ikepanhc) on 2017-11-09
Changed in grub2 (Ubuntu):
assignee: nobody → Ike Panhc (ikepanhc)
status: New → In Progress
dann frazier (dannf) on 2017-11-09
Changed in grub2 (Ubuntu Xenial):
assignee: nobody → Ike Panhc (ikepanhc)
status: New → In Progress
Changed in grub2 (Ubuntu):
status: In Progress → Fix Released
assignee: Ike Panhc (ikepanhc) → nobody
description: updated

Hello Ike, or anyone else affected,

Accepted grub2 into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2/2.02~beta2-36ubuntu3.15 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 and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. 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!

Changed in grub2 (Ubuntu Xenial):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-xenial
Brian Murray (brian-murray) wrote :

Hello Ike, or anyone else affected,

Accepted grub2-signed into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/grub2-signed/1.66.15 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 and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. 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!

Ike Panhc (ikepanhc) wrote :

grub2-signed in -proposed is in dependency wait.

Install debs manually and confirm that grub2 binaries in -proposed solve this problem.

                   GNU GRUB version 2.02~beta2-36ubuntu3.15

   Minimal BASH-like line editing is supported. For the first word, TAB
   lists possible command completions. Anywhere else TAB lists possible
   device or file completions. ESC at any time exits.

grub> exit
Unloading driver at 0x00030F5F000
CoreLoadedImageInfo: Not an ImageHandle 3C1D0F18

  Failed to boot both default and fallback entries.

Press any key to continue...

tags: added: verification-done verification-done-xenial
removed: verification-needed verification-needed-xenial
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 2.02~beta2-36ubuntu3.15

---------------
grub2 (2.02~beta2-36ubuntu3.15) xenial; urgency=medium

  [ Ike Panhc ]
  * Fix grub crash when exit on arm64-platform. (LP: #1731241)

  [ Mathieu Trudel-Lapierre ]
  * Cherry-pick upstream patch to change the default TSC calibration method
    to pmtimer on EFI systems (LP: #1734278)

 -- Mathieu Trudel-Lapierre <email address hidden> Mon, 11 Dec 2017 10:25:22 -0500

Changed in grub2 (Ubuntu Xenial):
status: Fix Committed → Fix Released

The verification of the Stable Release Update for grub2 has completed successfully and the package has now been 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.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers