From 2ba7f668dc4e201a327ec99cd07ecef4370f6407 Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Mon, 21 Oct 2019 14:13:47 +0200 Subject: [PATCH] make WifiLink depend on LinkImpl directly --- src/surf/network_wifi.cpp | 5 ++--- src/surf/network_wifi.hpp | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/surf/network_wifi.cpp b/src/surf/network_wifi.cpp index 50529b3ae4..10eb70b3ee 100644 --- a/src/surf/network_wifi.cpp +++ b/src/surf/network_wifi.cpp @@ -19,13 +19,12 @@ namespace resource { NetworkWifiLink::NetworkWifiLink(NetworkCm02Model* model, const std::string& name, std::vector bandwidths, lmm::System* system) - : NetworkCm02Link(model, name, 1 / sg_bandwidth_factor, 0, s4u::Link::SharingPolicy::WIFI, system) -// : LinkImpl(model, name, system->constraint_new(this, 1)) + : LinkImpl(model, name, system->constraint_new(this, 1)) { for (auto bandwidth : bandwidths) bandwidths_.push_back({bandwidth, 1.0, nullptr}); - // simgrid::s4u::Link::on_creation(this->piface_); + simgrid::s4u::Link::on_creation(this->piface_); } void NetworkWifiLink::set_host_rate(s4u::Host* host, int rate_level) diff --git a/src/surf/network_wifi.hpp b/src/surf/network_wifi.hpp index a1cd907f7d..c84527bfc3 100644 --- a/src/surf/network_wifi.hpp +++ b/src/surf/network_wifi.hpp @@ -19,7 +19,7 @@ namespace simgrid { namespace kernel { namespace resource { -class NetworkWifiLink : public NetworkCm02Link { +class NetworkWifiLink : public LinkImpl { /** @brief Hold every rates association between host and links (host name, rates id) */ std::map host_rates_; -- 2.20.1