[PATCH 2/2] Don't set GPT HFS+ partitions as bootable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Setting a GPT partition as bootable changes it to the EFI system partition
type, which is defined as FAT. Doing this for HFS+ confuses the firmware.
Skip setting it bootable in this scenario - the firmware is fine with that.
---
 pyanaconda/storage/__init__.py |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/pyanaconda/storage/__init__.py b/pyanaconda/storage/__init__.py
index 7cb90ed..5317c1b 100644
--- a/pyanaconda/storage/__init__.py
+++ b/pyanaconda/storage/__init__.py
@@ -375,7 +375,7 @@ class Storage(object):
         self.devicetree.processActions()
         self.doEncryptionPassphraseRetrofits()
 
-        # now set the boot partition's flag
+        # now set the boot partition's flag.
         if self.anaconda:
             if self.anaconda.bootloader.stage2_bootable:
                 boot = self.bootDevice
@@ -402,6 +402,13 @@ class Storage(object):
                          log.info("not setting boot flag on %s as there is"
                                   "another active partition" % dev.name)
                          continue
+                    # hfs+ partitions on gpt can't be marked bootable via
+                    # parted
+                    if dev.disk.format.partedDisk.type == "gpt" and \
+                            dev.format.type == "hfs+":
+                        log.info("not setting boot flag on hfs+ partition"
+                                 " %s" % dev.name)
+                        continue
                     log.info("setting boot flag on %s" % dev.name)
                     dev.bootable = True
 
-- 
1.7.7.6

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux