maas/images/maas-region-controller-bionic/2.8_bios_grub_partition.patch
Anselme, Schubbert (sa246v) 129d958a51
Upgrading MAAS to v3
Signed-off-by: Anselme, Schubert (sa246v) <sa246v@att.com>
Change-Id: I4b5a5f6a7e21d790cce13a5ccff9819f517cad64
2022-11-23 12:55:52 -05:00

18 lines
854 B
Diff

diff --git a/src/maasserver/models/partition.py b/src/maasserver/models/partition.py
index 814660ac2..1ba4142bf 100644
--- a/src/maasserver/models/partition.py
+++ b/src/maasserver/models/partition.py
@@ -238,7 +238,11 @@ class Partition(CleanSave, TimestampedModel):
return idx + 1
elif arch == "ppc64el" and block_device.id == boot_disk.id:
return idx + 2
- elif arch == "amd64" and bios_boot_method != "uefi":
+ elif (
+ arch == "amd64"
+ and bios_boot_method != "uefi"
+ and block_device.id == boot_disk.id
+ ):
if block_device.type == "physical":
# Delay the `type` check because it can cause a query. Only
# physical block devices get the bios_grub partition.