shill: Connect Ethernet Device to DHCPConfig.
Most of the implementation is in the base Device class.
BUG=chromium-os:16794
TEST=unit test
Change-Id: I583761f7e54c88b043ce4343cb43f8298aaedf8b
Reviewed-on: http://gerrit.chromium.org/gerrit/2949
Reviewed-by: Darin Petkov <petkov@chromium.org>
Tested-by: Darin Petkov <petkov@chromium.org>
diff --git a/ethernet_service.cc b/ethernet_service.cc
index 44a7080..b3e31f7 100644
--- a/ethernet_service.cc
+++ b/ethernet_service.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "shill/ethernet_service.h"
+
#include <time.h>
#include <stdio.h>
#include <netinet/ether.h>
@@ -14,21 +16,21 @@
#include "shill/control_interface.h"
#include "shill/device.h"
#include "shill/device_info.h"
+#include "shill/ethernet.h"
#include "shill/manager.h"
#include "shill/shill_event.h"
-#include "shill/ethernet.h"
-#include "shill/ethernet_service.h"
-
using std::string;
namespace shill {
+
EthernetService::EthernetService(ControlInterface *control_interface,
EventDispatcher *dispatcher,
Ethernet *device,
- const std::string& name)
+ const string &name)
: Service(control_interface, dispatcher, device, name),
ethernet_(device) {
+ set_auto_connect(true);
}
EthernetService::~EthernetService() { }