summaryrefslogtreecommitdiffstats
path: root/libnetutils
diff options
context:
space:
mode:
Diffstat (limited to 'libnetutils')
-rw-r--r--libnetutils/dhcp_utils.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/libnetutils/dhcp_utils.c b/libnetutils/dhcp_utils.c
index 3ab5d1b..d18931b 100644
--- a/libnetutils/dhcp_utils.c
+++ b/libnetutils/dhcp_utils.c
@@ -145,6 +145,11 @@ void get_daemon_suffix(const char *interface, char *daemon_suffix) {
/*
* Start the dhcp client daemon, and wait for it to finish
* configuring the interface.
+ *
+ * The device init.rc file needs a corresponding entry for this work.
+ *
+ * Example:
+ * service dhcpcd_<interface> /system/bin/dhcpcd -ABKL
*/
int dhcp_do_request(const char *interface,
char *ipaddr,
@@ -287,13 +292,16 @@ char *dhcp_get_errmsg() {
}
/**
- * Run WiMAX dhcp renew service.
- * "wimax_renew" service shoud be included in init.rc.
+ * The device init.rc file needs a corresponding entry.
+ *
+ * Example:
+ * service iprenew_<interface> /system/bin/dhcpcd -n
+ *
*/
int dhcp_do_request_renew(const char *interface,
in_addr_t *ipaddr,
in_addr_t *gateway,
- in_addr_t *mask,
+ uint32_t *prefixLength,
in_addr_t *dns1,
in_addr_t *dns2,
in_addr_t *server,
@@ -333,7 +341,7 @@ int dhcp_do_request_renew(const char *interface,
return -1;
}
if (strcmp(prop_value, "ok") == 0) {
- fill_ip_info(interface, ipaddr, gateway, mask, dns1, dns2, server, lease);
+ fill_ip_info(interface, ipaddr, gateway, prefixLength, dns1, dns2, server, lease);
return 0;
} else {
snprintf(errmsg, sizeof(errmsg), "DHCP Renew result was %s", prop_value);