Fix IPv4 DHCP address origin

This commit popluates DHCPv4 address origin.

Tested By:
Check origin of LinkLocal IPv4 and IPv6 addresses.
Enable DHCPv4 and check origin of DHCP IP
Assign static address and check origin of static address
Enable DHCv6 and check origin of DHCP addresses
Enable DHCPv6 stateless addresses and check origin

Change-Id: I1d35829cf5b0c981621b5d476ac349567d8d9bdd
Signed-off-by: Ravi Teja <raviteja28031990@gmail.com>
diff --git a/src/ethernet_interface.cpp b/src/ethernet_interface.cpp
index 7a17208..b3b9bb7 100644
--- a/src/ethernet_interface.cpp
+++ b/src/ethernet_interface.cpp
@@ -174,6 +174,11 @@
 void EthernetInterface::addAddr(const AddressInfo& info)
 {
     IP::AddressOrigin origin = IP::AddressOrigin::Static;
+    if (dhcpIsEnabled(info.ifaddr.getAddr()))
+    {
+        origin = IP::AddressOrigin::DHCP;
+    }
+
 #ifdef LINK_LOCAL_AUTOCONFIGURATION
     if (info.scope == RT_SCOPE_LINK)
     {