summaryrefslogtreecommitdiffstats
path: root/storage/formats
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2009-10-27 19:45:15 +0100
committerHans de Goede <hdegoede@redhat.com>2009-10-28 10:27:53 +0100
commit0d974cb8a7cee879de6695b8b09c9f61c2c99a12 (patch)
treec42b1a3328bf33e5cefba6d624e9d8cc205e8852 /storage/formats
parent81b7b447818db245359dea1a4eb23a07b916f720 (diff)
downloadanaconda-0d974cb8a7cee879de6695b8b09c9f61c2c99a12.tar.gz
anaconda-0d974cb8a7cee879de6695b8b09c9f61c2c99a12.tar.xz
anaconda-0d974cb8a7cee879de6695b8b09c9f61c2c99a12.zip
When doing initlabel on a dasd disk create a dasd disklabel (#531209)
As discussed on IRC this changes the platform.diskType property into a platform.diskLabelType method that takes a disk/device type argument and uses this argument to check for dasd disks and in that cases returns dasd as diskLabelType.
Diffstat (limited to 'storage/formats')
-rw-r--r--storage/formats/disklabel.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/storage/formats/disklabel.py b/storage/formats/disklabel.py
index a6e3352ee..8f003fc17 100644
--- a/storage/formats/disklabel.py
+++ b/storage/formats/disklabel.py
@@ -92,7 +92,8 @@ class DiskLabel(DeviceFormat):
def freshPartedDisk(self):
""" Return a new, empty parted.Disk instance for this device. """
log_method_call(self, device=self.device)
- labelType = platform.getPlatform(None).diskLabelType
+ platf = platform.getPlatform(None)
+ labelType = platf.diskLabelType(self.partedDevice.type)
return parted.freshDisk(device=self.partedDevice, ty=labelType)
@property