summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@mandriva.com>2005-09-18 07:18:52 (GMT)
committerDavid S. Miller <davem@davemloft.net>2005-09-18 07:18:52 (GMT)
commit561713cf475de1f671cc89c437927ec008a20209 (patch)
treef0485a84b71e2e14f02c9c87e792b187e28b6fdd
parent65299d6c3cfb49cc3eee4fc483e7edd23ea7b2ed (diff)
downloadlinux-3.10-561713cf475de1f671cc89c437927ec008a20209.zip
linux-3.10-561713cf475de1f671cc89c437927ec008a20209.tar.gz
linux-3.10-561713cf475de1f671cc89c437927ec008a20209.tar.bz2
[DCCP]: Don't use necessarily the same CCID for tx and rx
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--include/linux/dccp.h3
-rw-r--r--net/dccp/ipv4.c4
-rw-r--r--net/dccp/options.c3
3 files changed, 6 insertions, 4 deletions
diff --git a/include/linux/dccp.h b/include/linux/dccp.h
index 8c8e029..13f9b78 100644
--- a/include/linux/dccp.h
+++ b/include/linux/dccp.h
@@ -330,7 +330,8 @@ static inline unsigned int dccp_hdr_len(const struct sk_buff *skb)
*/
struct dccp_options {
__u64 dccpo_sequence_window;
- __u8 dccpo_ccid;
+ __u8 dccpo_rx_ccid;
+ __u8 dccpo_tx_ccid;
__u8 dccpo_send_ack_vector;
__u8 dccpo_send_ndp_count;
};
diff --git a/net/dccp/ipv4.c b/net/dccp/ipv4.c
index 82434e4..40fe6af 100644
--- a/net/dccp/ipv4.c
+++ b/net/dccp/ipv4.c
@@ -1241,9 +1241,9 @@ static int dccp_v4_init_sock(struct sock *sk)
* setsockopt(CCIDs-I-want/accept). -acme
*/
if (likely(!dccp_ctl_socket_init)) {
- dp->dccps_hc_rx_ccid = ccid_init(dp->dccps_options.dccpo_ccid,
+ dp->dccps_hc_rx_ccid = ccid_init(dp->dccps_options.dccpo_rx_ccid,
sk);
- dp->dccps_hc_tx_ccid = ccid_init(dp->dccps_options.dccpo_ccid,
+ dp->dccps_hc_tx_ccid = ccid_init(dp->dccps_options.dccpo_tx_ccid,
sk);
if (dp->dccps_hc_rx_ccid == NULL ||
dp->dccps_hc_tx_ccid == NULL) {
diff --git a/net/dccp/options.c b/net/dccp/options.c
index c480c506..0a76426 100644
--- a/net/dccp/options.c
+++ b/net/dccp/options.c
@@ -25,7 +25,8 @@
/* stores the default values for new connection. may be changed with sysctl */
static const struct dccp_options dccpo_default_values = {
.dccpo_sequence_window = DCCPF_INITIAL_SEQUENCE_WINDOW,
- .dccpo_ccid = DCCPF_INITIAL_CCID,
+ .dccpo_rx_ccid = DCCPF_INITIAL_CCID,
+ .dccpo_tx_ccid = DCCPF_INITIAL_CCID,
.dccpo_send_ack_vector = DCCPF_INITIAL_SEND_ACK_VECTOR,
.dccpo_send_ndp_count = DCCPF_INITIAL_SEND_NDP_COUNT,
};