* [dts] [PATCH] nics: allow tester init fm10k netdev object
@ 2016-07-11 5:11 Marvin Liu
0 siblings, 0 replies; only message in thread
From: Marvin Liu @ 2016-07-11 5:11 UTC (permalink / raw)
To: dts; +Cc: Marvin Liu
Allow tester initialize fm10k netdev object. When host and tester on the
same platform, host fm10k netdev objects will inherit from tester.
Fm10k require domain id in port configuration, keep pace with normal pci
device.
Signed-off-by: Marvin Liu <yong.liu@intel.com>
diff --git a/nics/atwood.py b/nics/atwood.py
index e2fe458..76a94bd 100644
--- a/nics/atwood.py
+++ b/nics/atwood.py
@@ -90,7 +90,7 @@ class Atwood(NetDevice):
# load port config
portconf = PortConf(PORTCONF)
portconf.load_ports_config(host.crb['IP'])
- pci_addr = ':'.join((bus_id, devfun_id))
+ pci_addr = ':'.join((domain_id, bus_id, devfun_id))
if not portconf.check_port_available(pci_addr):
raise PortConfigParseException("Atwood must configured")
diff --git a/nics/br.py b/nics/br.py
index 86c4d95..5b6e778 100644
--- a/nics/br.py
+++ b/nics/br.py
@@ -101,9 +101,6 @@ class BoulderRapid(NetDevice):
def __init__(self, host, domain_id, bus_id, devfun_id):
super(BoulderRapid, self).__init__(host, domain_id, bus_id, devfun_id)
- if host.NAME == "tester":
- return
-
self.tp_path = "~"
self.sec_port = False
self.host = host
@@ -111,7 +108,7 @@ class BoulderRapid(NetDevice):
# load port config
portconf = PortConf(PORTCONF)
portconf.load_ports_config(host.crb['IP'])
- pci_addr = ':'.join((bus_id, devfun_id))
+ pci_addr = ':'.join((domain_id, bus_id, devfun_id))
if not portconf.check_port_available(pci_addr):
raise PortConfigParseException("BoulderRapid must configured")
diff --git a/nics/rrc.py b/nics/rrc.py
index a498b7a..02fe6c5 100644
--- a/nics/rrc.py
+++ b/nics/rrc.py
@@ -102,9 +102,6 @@ class RedRockCanyou(NetDevice):
def __init__(self, host, domain_id, bus_id, devfun_id):
super(RedRockCanyou, self).__init__(host, domain_id, bus_id, devfun_id)
- if host.NAME == "tester":
- return
-
self.tp_path = "~"
self.sec_port = False
self.host = host
@@ -112,7 +109,7 @@ class RedRockCanyou(NetDevice):
# load port config
portconf = PortConf(PORTCONF)
portconf.load_ports_config(host.crb['IP'])
- pci_addr = ':'.join((bus_id, devfun_id))
+ pci_addr = ':'.join((domain_id, bus_id, devfun_id))
if not portconf.check_port_available(pci_addr):
raise PortConfigParseException("RRC must configured")
--
1.9.3
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-07-11 5:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-11 5:11 [dts] [PATCH] nics: allow tester init fm10k netdev object Marvin Liu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).