[PATCH] FcoeDiskDevice.dracutSetupString: handle DCB on / off option

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

 



---
 storage/devices.py |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/storage/devices.py b/storage/devices.py
index 69aa8bf..741e255 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -3355,7 +3355,19 @@ class FcoeDiskDevice(DiskDevice, NetworkStorageDevice):
         log.debug("created new fcoe disk %s @ %s" % (device, self.nic))
 
     def dracutSetupString(self):
-        return "netroot=fcoe:%s:nodcb" % self.nic
+        dcb = True
+
+        from .fcoe import fcoe
+        for nic, dcb in fcoe().nics:
+            if nic == self.nic:
+                break
+
+        if dcb:
+            dcbOpt = "dcb"
+        else:
+            dcbOpt = "nodcb"
+
+        return "netroot=fcoe:%s:%s" % (self.nic, dcbOpt)
 
 
 class OpticalDevice(StorageDevice):
-- 
1.7.0

_______________________________________________
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