summaryrefslogtreecommitdiffstats
path: root/storage/devices.py
diff options
context:
space:
mode:
authorDavid Lehman <dlehman@redhat.com>2009-03-23 22:05:23 -0500
committerDavid Lehman <dlehman@redhat.com>2009-03-23 22:17:17 -0500
commit3b1206629309d766fc25d529ae3145c9532c8977 (patch)
treef80b64de5fe9f8d6adbea56da795934dbf65068e /storage/devices.py
parentbfa234b45d3563ea4661cfddd6b7171777c94bb0 (diff)
downloadanaconda-3b1206629309d766fc25d529ae3145c9532c8977.tar.gz
anaconda-3b1206629309d766fc25d529ae3145c9532c8977.tar.xz
anaconda-3b1206629309d766fc25d529ae3145c9532c8977.zip
Remove all implicit calls to self.format.destroy from Device classes.
We are scheduling the actions we need. This is just noise now.
Diffstat (limited to 'storage/devices.py')
-rw-r--r--storage/devices.py19
1 files changed, 0 insertions, 19 deletions
diff --git a/storage/devices.py b/storage/devices.py
index 35e9be62a..6494601a5 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -609,10 +609,6 @@ class StorageDevice(Device):
if not self.isleaf:
raise DeviceError("Cannot destroy non-leaf device")
- if self.status:
- # best effort
- self.format.destroy()
-
self.exists = False
# we already did this in DeviceTree._removeDevice
#for parent in self.parents:
@@ -805,9 +801,6 @@ class DiskDevice(StorageDevice):
if not self.mediaPresent:
raise DeviceError("cannot destroy disk %s which has no media" % self.name)
- if self.status:
- self.format.destroy()
-
self.partedDisk.deleteAllPartitions()
# this is perhaps a separate operation (wiping the disklabel)
self.partedDisk.clobber()
@@ -1184,9 +1177,6 @@ class PartitionDevice(StorageDevice):
raise DeviceError("Cannot destroy non-leaf device")
self.setupParents()
- if self.status:
- self.format.destroy()
-
self.disk.removePartition(self)
self.disk.commit()
@@ -1970,9 +1960,6 @@ class LVMLogicalVolumeDevice(DMDevice):
if not self.exists:
raise DeviceError("device has not been created")
- if self.status:
- self.format.destroy()
-
self.teardown()
lvm.lvremove(self.vg.name, self._name)
self.exists = False
@@ -2306,9 +2293,6 @@ class MDRaidArrayDevice(StorageDevice):
if not self.exists:
raise DeviceError("device has not been created")
- if self.status:
- self.format.destroy()
-
self.teardown()
# The destruction of the formatting on the member devices does the
@@ -2587,9 +2571,6 @@ class FileDevice(StorageDevice):
if not self.exists:
raise DeviceError("device has not been created")
- if self.status:
- self.format.destroy()
-
os.unlink(self.path)
self.exists = False