Merge ~rbalint/shim/+git/shim-signed:nvidia-rename-ok-bionic into ~ubuntu-core-dev/shim/+git/shim-signed:bionic

Proposed by Balint Reczey
Status: Merged
Merged at revision: d09724a3266495a582267ea0230752339ead12c6
Proposed branch: ~rbalint/shim/+git/shim-signed:nvidia-rename-ok-bionic
Merge into: ~ubuntu-core-dev/shim/+git/shim-signed:bionic
Diff against target: 53 lines (+26/-1)
2 files modified
debian/changelog (+7/-0)
update-secureboot-policy (+19/-1)
Reviewer Review Type Date Requested Status
Mathieu Trudel-Lapierre Approve
Ubuntu Core Development Team Pending
Review via email: mp+357843@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/debian/changelog b/debian/changelog
2index 113caab..47e38fe 100644
3--- a/debian/changelog
4+++ b/debian/changelog
5@@ -1,3 +1,10 @@
6+shim-signed (1.37~18.04.3) bionic; urgency=medium
7+
8+ * Don't fail non-interactive upgrade of nvidia module and module removals
9+ (LP: #1726803)
10+
11+ -- Balint Reczey <rbalint@ubuntu.com> Thu, 25 Oct 2018 20:55:38 +0200
12+
13 shim-signed (1.37~18.04.2) bionic; urgency=medium
14
15 * debian/control: add Breaks: grub-efi-amd64-signed (<< 1.93.7), as the new
16diff --git a/update-secureboot-policy b/update-secureboot-policy
17index e9aeb25..0c53443 100755
18--- a/update-secureboot-policy
19+++ b/update-secureboot-policy
20@@ -55,6 +55,23 @@ clear_new_dkms_list()
21 rm "$NEW_DKMS_LIST"
22 }
23
24+new_dkms_module()
25+{
26+ # handle nvidia module specially because it changed path
27+ if ! grep -q "/var/lib/dkms/nvidia" "$OLD_DKMS_LIST" && grep -q "/var/lib/dkms/nvidia" "$NEW_DKMS_LIST" ; then
28+ # nvidia module is newly added
29+ return 0
30+ fi
31+
32+ # return 0 if there is any other new module
33+ env LC_ALL=C comm -1 -3 $OLD_DKMS_LIST $NEW_DKMS_LIST | grep -q -v "/var/lib/dkms/nvidia"
34+}
35+
36+show_dkms_list_changes()
37+{
38+ diff -u $OLD_DKMS_LIST $NEW_DKMS_LIST >&2
39+}
40+
41 validate_password()
42 {
43 db_capb
44@@ -146,7 +163,8 @@ do_it()
45 if [ -z "$key$again" ] && echo "$seen_key" | grep -q ^30; then
46 echo "Running in non-interactive mode, doing nothing." >&2
47
48- if ! diff -u $OLD_DKMS_LIST $NEW_DKMS_LIST; then
49+ if new_dkms_module; then
50+ show_dkms_list_changes
51 clear_new_dkms_list
52 exit 1
53 else

Subscribers

People subscribed via source and target branches