From 7c3d1c291ab5f9efb2efcfd5def1baeea1255917 Mon Sep 17 00:00:00 2001 From: Alex Yakavenka Date: Tue, 8 Nov 2011 20:25:23 +0900 Subject: Export flags needed for ifc_reset_connections API in netutils Code using ifc_reset_connections api needs to have access to predefined masks for reset_mask parameter Change-Id: I90bc5e1b62ae4a88501c8ad4e353c0d93d319579 --- include/netutils/ifc.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/netutils') diff --git a/include/netutils/ifc.h b/include/netutils/ifc.h index 67a4a456..3574f7f2 100644 --- a/include/netutils/ifc.h +++ b/include/netutils/ifc.h @@ -34,6 +34,9 @@ extern int ifc_down(const char *name); extern int ifc_enable(const char *ifname); extern int ifc_disable(const char *ifname); +#define RESET_IPV4_ADDRESSES 0x01 +#define RESET_IPV6_ADDRESSES 0x02 +#define RESET_ALL_ADDRESSES (RESET_IPV4_ADDRESSES | RESET_IPV6_ADDRESSES) extern int ifc_reset_connections(const char *ifname, const int reset_mask); extern int ifc_get_addr(const char *name, in_addr_t *addr); -- cgit v1.2.3 From 22bb8fc5fe7c10fb9c7b8c4cfeb244c837e3e0c7 Mon Sep 17 00:00:00 2001 From: Dmitry Shmidt Date: Mon, 23 Jul 2012 15:40:15 -0700 Subject: netutils: Make visible prefixLengthToIpv4Netmask() function Change-Id: I316b192ce753daa838ea44001f899ea508adf75c Signed-off-by: Dmitry Shmidt --- include/netutils/ifc.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/netutils') diff --git a/include/netutils/ifc.h b/include/netutils/ifc.h index 67a4a456..9079ab45 100644 --- a/include/netutils/ifc.h +++ b/include/netutils/ifc.h @@ -66,6 +66,8 @@ extern int ifc_configure(const char *ifname, in_addr_t address, uint32_t prefixLength, in_addr_t gateway, in_addr_t dns1, in_addr_t dns2); +extern in_addr_t prefixLengthToIpv4Netmask(int prefix_length); + __END_DECLS #endif /* _NETUTILS_IFC_H_ */ -- cgit v1.2.3