diff options
author | Nivedita Singhvi <niv@us.ibm.com> | 2009-05-28 07:00:46 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-06-02 00:45:24 -0700 |
commit | f771bef98004d9d141b085d987a77d06669d4f4f (patch) | |
tree | df9b7a353a8c28e71a8237d3ad65ba7f41ffab30 /include | |
parent | 4d52cfbef6266092d535237ba5a4b981458ab171 (diff) | |
download | linux-3.10-f771bef98004d9d141b085d987a77d06669d4f4f.tar.gz linux-3.10-f771bef98004d9d141b085d987a77d06669d4f4f.tar.bz2 linux-3.10-f771bef98004d9d141b085d987a77d06669d4f4f.zip |
ipv4: New multicast-all socket option
After some discussion offline with Christoph Lameter and David Stevens
regarding multicast behaviour in Linux, I'm submitting a slightly
modified patch from the one Christoph submitted earlier.
This patch provides a new socket option IP_MULTICAST_ALL.
In this case, default behaviour is _unchanged_ from the current
Linux standard. The socket option is set by default to provide
original behaviour. Sockets wishing to receive data only from
multicast groups they join explicitly will need to clear this
socket option.
Signed-off-by: Nivedita Singhvi <niv@us.ibm.com>
Signed-off-by: Christoph Lameter<cl@linux.com>
Acked-by: David Stevens <dlstevens@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/in.h | 1 | ||||
-rw-r--r-- | include/net/inet_sock.h | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/include/linux/in.h b/include/linux/in.h index d60122a3a08..cf196da04ec 100644 --- a/include/linux/in.h +++ b/include/linux/in.h @@ -107,6 +107,7 @@ struct in_addr { #define MCAST_JOIN_SOURCE_GROUP 46 #define MCAST_LEAVE_SOURCE_GROUP 47 #define MCAST_MSFILTER 48 +#define IP_MULTICAST_ALL 49 #define MCAST_EXCLUDE 0 #define MCAST_INCLUDE 1 diff --git a/include/net/inet_sock.h b/include/net/inet_sock.h index de0ecc71cf0..20a6957af87 100644 --- a/include/net/inet_sock.h +++ b/include/net/inet_sock.h @@ -130,7 +130,8 @@ struct inet_sock { freebind:1, hdrincl:1, mc_loop:1, - transparent:1; + transparent:1, + mc_all:1; int mc_index; __be32 mc_addr; struct ip_mc_socklist *mc_list; |