diff options
author | Peter Jones <pjones@redhat.com> | 2008-03-14 16:04:34 -0400 |
---|---|---|
committer | Peter Jones <pjones@pjones2.localdomain> | 2008-03-14 16:04:34 -0400 |
commit | 66c8fcf008c0d80edf9c67fce34f17d27202ed2c (patch) | |
tree | 2d37588405c597c7ac23407d0f08d623647ff796 /bootloader.py | |
parent | 8b663e83048e5b44627f121ea4c08e3cb23198c2 (diff) | |
download | anaconda-66c8fcf008c0d80edf9c67fce34f17d27202ed2c.tar.gz anaconda-66c8fcf008c0d80edf9c67fce34f17d27202ed2c.tar.xz anaconda-66c8fcf008c0d80edf9c67fce34f17d27202ed2c.zip |
Add EFI handling to the bootloader setup choices.
Diffstat (limited to 'bootloader.py')
-rw-r--r-- | bootloader.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/bootloader.py b/bootloader.py index f3e3baf68..5d603fccd 100644 --- a/bootloader.py +++ b/bootloader.py @@ -63,6 +63,26 @@ def bootloaderSetupChoices(anaconda): pref = anaconda.id.bootloader.drivelist[:1] anaconda.id.bootloader.updateDriveList(pref) + if iutil.isEfi() and not anaconda.id.bootloader.device: + drives = anaconda.id.diskset.disks.keys() + drives.sort() + bootPart = None + for drive in drives: + disk = anaconda.id.diskset.disks[drive] + part = disk.next_partition() + while part: + if part.is_active() and partedUtils.isEfiSystemPartition(part): + bootPart = partedUtils.get_partition_name(part) + break + part = disk.next_partition(part) + if bootPart: + break + if bootPart: + anaconda.id.bootloader.setDevice(bootPart) + dev = Device() + dev.device = bootPart + anaconda.id.fsset.add(FileSystemSetEntry(dev, None, fileSystemTypeGet("efi"))) + # iSeries bootloader on upgrades if iutil.getPPCMachine() == "iSeries" and not anaconda.id.bootloader.device: drives = anaconda.id.diskset.disks.keys() |