[PATCH 4/5] Ignore loop and ram devices

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

 



Ignore loop and ram devices, we normally already skip these in
udev.py: enumerate_block_devices(), but we can still end up trying
to add them to the tree when they are slaves of other devices, this
happens for example with the livecd
---
 storage/devicetree.py |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/storage/devicetree.py b/storage/devicetree.py
index 765c857..fdcac7c 100644
--- a/storage/devicetree.py
+++ b/storage/devicetree.py
@@ -816,6 +816,13 @@ class DeviceTree(object):
                 if disk.name == os.path.basename(os.path.dirname(sysfs_path)):
                     return True
 
+        # Ignore loop and ram devices, we normally already skip these in
+        # udev.py: enumerate_block_devices(), but we can still end up trying
+        # to add them to the tree when they are slaves of other devices, this
+        # happens for example with the livecd
+        if name.startswith("loop") or name.startswith("ram"):
+            return True
+
         # FIXME: check for virtual devices whose slaves are on the ignore list
 
     def addUdevDevice(self, info):
-- 
1.6.1.3

_______________________________________________
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