95-configured revision 48d5a1d50750ffa5d14b64841fc7e81dadafd1a4
1# This script runs last, after all network configuration
2# has completed. It sets a property to let the framework
3# know that setting up the interface is complete.
4
5# For debugging:
6
7if [[ $interface == p2p* ]]
8    then
9    intf=p2p
10    else
11    intf=$interface
12fi
13setprop dhcp.${intf}.reason "${reason}"
14
15case "${reason}" in
16BOUND|INFORM|REBIND|REBOOT|RENEW|TIMEOUT)
17    setprop dhcp.${intf}.ipaddress  "${new_ip_address}"
18    setprop dhcp.${intf}.gateway    "${new_routers%% *}"
19    setprop dhcp.${intf}.mask       "${new_subnet_mask}"
20    setprop dhcp.${intf}.leasetime  "${new_dhcp_lease_time}"
21    setprop dhcp.${intf}.server     "${new_dhcp_server_identifier}"
22    setprop dhcp.${intf}.vendorInfo "${new_vendor_encapsulated_options}"
23
24    setprop dhcp.${intf}.result "ok"
25    ;;
26
27EXPIRE|FAIL|IPV4LL|STOP)
28    setprop dhcp.${intf}.result "failed"
29    ;;
30
31RELEASE)
32    setprop dhcp.${intf}.result "released"
33    ;;
34esac
35