aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/ip_vs.h
diff options
context:
space:
mode:
authorJulius Volz <juliusv@google.com>2008-09-02 09:55:36 -0400
committerSimon Horman <horms@verge.net.au>2008-09-04 21:17:04 -0400
commitc860c6b1479992440e4962e9c95d258bfdce4fca (patch)
tree25172dc157cf23f02f1639af5ae6bbd39521f627 /include/net/ip_vs.h
parentc842a3ada9ba8f0cca38a70de3fe0effcfab254c (diff)
IPVS: Add internal versions of sockopt interface structs
Add extended internal versions of struct ip_vs_service_user and struct ip_vs_dest_user (the originals can't be modified as they are part of the old sockopt interface). Adjust ip_vs_ctl.c to work with the new data structures and add some minor AF-awareness. Signed-off-by: Julius Volz <juliusv@google.com> Signed-off-by: Simon Horman <horms@verge.net.au>
Diffstat (limited to 'include/net/ip_vs.h')
-rw-r--r--include/net/ip_vs.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h
index 0400e590b6a2..1adf8a026e46 100644
--- a/include/net/ip_vs.h
+++ b/include/net/ip_vs.h
@@ -400,6 +400,45 @@ struct ip_vs_conn {
400 400
401 401
402/* 402/*
403 * Extended internal versions of struct ip_vs_service_user and
404 * ip_vs_dest_user for IPv6 support.
405 *
406 * We need these to conveniently pass around service and destination
407 * options, but unfortunately, we also need to keep the old definitions to
408 * maintain userspace backwards compatibility for the setsockopt interface.
409 */
410struct ip_vs_service_user_kern {
411 /* virtual service addresses */
412 u16 af;
413 u16 protocol;
414 union nf_inet_addr addr; /* virtual ip address */
415 u16 port;
416 u32 fwmark; /* firwall mark of service */
417
418 /* virtual service options */
419 char *sched_name;
420 unsigned flags; /* virtual service flags */
421 unsigned timeout; /* persistent timeout in sec */
422 u32 netmask; /* persistent netmask */
423};
424
425
426struct ip_vs_dest_user_kern {
427 /* destination server address */
428 union nf_inet_addr addr;
429 u16 port;
430
431 /* real server options */
432 unsigned conn_flags; /* connection flags */
433 int weight; /* destination weight */
434
435 /* thresholds for active connections */
436 u32 u_threshold; /* upper threshold */
437 u32 l_threshold; /* lower threshold */
438};
439
440
441/*
403 * The information about the virtual service offered to the net 442 * The information about the virtual service offered to the net
404 * and the forwarding entries 443 * and the forwarding entries
405 */ 444 */