Track link status in Ethernet and register service
Add link status tracking (and setting IFF_UP) to ethernet devices.
When the interface is running, register a service with the manager.
BUG=chromium-os:12933
TEST=Manual -- unit tests and plug/unplug ethernet USB and RJ45 sides.
Change-Id: I1233ce5a63efddb7606183dc4daad4d2624d864a
Reviewed-on: http://gerrit.chromium.org/gerrit/1196
Tested-by: Paul Stewart <pstew@chromium.org>
Reviewed-by: Paul Stewart <pstew@chromium.org>
diff --git a/wifi.h b/wifi.h
index 844d653..e61e2b2 100644
--- a/wifi.h
+++ b/wifi.h
@@ -16,10 +16,11 @@
// this class.
class WiFi : public Device {
public:
- explicit WiFi(ControlInterface *control_interface,
- EventDispatcher *dispatcher,
- const std::string &link_name,
- int interface_index);
+ WiFi(ControlInterface *control_interface,
+ EventDispatcher *dispatcher,
+ Manager *manager,
+ const std::string& link_name,
+ int interface_index);
~WiFi();
bool TechnologyIs(Device::Technology type);
private: