From 50bd755871fefa59857510a620ae66c1400577df Mon Sep 17 00:00:00 2001 From: Martin Willi Date: Fri, 9 Nov 2012 15:46:58 +0100 Subject: Add an optional kernel-interface parameter to install IPs with a custom prefix --- src/libhydra/kernel/kernel_net.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/libhydra/kernel/kernel_net.h') diff --git a/src/libhydra/kernel/kernel_net.h b/src/libhydra/kernel/kernel_net.h index 0f2e31cc9..50881ab4d 100644 --- a/src/libhydra/kernel/kernel_net.h +++ b/src/libhydra/kernel/kernel_net.h @@ -115,10 +115,11 @@ struct kernel_net_t { * The virtual IP is attached to the interface where the iface_ip is found. * * @param virtual_ip virtual ip address to assign + * @param prefix prefix length to install with IP address, -1 for auto * @param iface_ip IP of an interface to attach virtual IP * @return SUCCESS if operation completed */ - status_t (*add_ip) (kernel_net_t *this, host_t *virtual_ip, + status_t (*add_ip) (kernel_net_t *this, host_t *virtual_ip, int prefix, host_t *iface_ip); /** @@ -127,9 +128,10 @@ struct kernel_net_t { * The kernel interface uses refcounting, see add_ip(). * * @param virtual_ip virtual ip address to assign + * @param prefix prefix length of the IP to uninstall, -1 for auto * @return SUCCESS if operation completed */ - status_t (*del_ip) (kernel_net_t *this, host_t *virtual_ip); + status_t (*del_ip) (kernel_net_t *this, host_t *virtual_ip, int prefix); /** * Add a route. -- cgit v1.2.3