[PATCH 6/8] Add dracutSetupData() method to DASDDevice (#526354).

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

 



Return kernel parameter information for the DASD.
---
 storage/devices.py |   20 ++++++++++++++++++++
 1 files changed, 20 insertions(+), 0 deletions(-)

diff --git a/storage/devices.py b/storage/devices.py
index a37834f..ad936ea 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -3159,6 +3159,26 @@ class DASDDevice(DiskDevice):
         self.failfast = kwargs.get('failfast')
         DiskDevice.__init__(self, *args, **kwargs)
 
+    def dracutSetupData(self):
+        arg = {'option': 'dasd', 'combine': True, 'delimiter': ','}
+        subargs = []
+
+        if self.readonly:
+            subargs.append("ro")
+        if self.diag:
+            subargs.append("diag")
+        if self.erplog:
+            subargs.append("erplog")
+        if self.failfast:
+            subargs.append("failfast")
+
+        if subargs == []:
+            arg['value'] = "%s" % (self.busid,)
+        else:
+            arg['value'] = "%s(%s)" % (self.busid, ":".join(subargs),)
+
+        return [arg]
+
 
 class NFSDevice(StorageDevice, NetworkStorageDevice):
     """ An NFS device """
-- 
1.6.2.5

_______________________________________________
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