]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
dccp: Remove obsolete parts of the old CCID interface
authorGerrit Renker <gerrit@erg.abdn.ac.uk>
Mon, 8 Dec 2008 09:18:05 +0000 (01:18 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 8 Dec 2008 09:18:05 +0000 (01:18 -0800)
The TX/RX CCIDs of the minisock are now redundant: similar to the Ack Vector
case, their value equals initially that of the sysctl, but at the end of
feature negotiation may be something different.

The old interface removed by this patch thus has been replaced by the newer
interface to dynamically query the currently loaded CCIDs.

Also removed are the constructors for the TX CCID and the RX CCID, since the
switch "rx <-> non-rx" is done by the handler in minisocks.c (and the handler
is the only place in the code where CCIDs are loaded).

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Acked-by: Ian McDonald <ian.mcdonald@jandi.co.nz>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/networking/dccp.txt
include/linux/dccp.h
net/dccp/ccid.c
net/dccp/ccid.h
net/dccp/feat.c
net/dccp/minisocks.c

index 610083ff73f6ae28c8f1e66d500b4396ddac0347..a203d132dbef473b841d13ccd86c10578606dadf 100644 (file)
@@ -140,10 +140,11 @@ send_ackvec = 1
        Whether or not to send Ack Vector options (sec. 11.5).
 
 tx_ccid = 2
-       Default CCID for the sender-receiver half-connection.
+       Default CCID for the sender-receiver half-connection. Depending on the
+       choice of CCID, the Send Ack Vector feature is enabled automatically.
 
 rx_ccid = 2
-       Default CCID for the receiver-sender half-connection.
+       Default CCID for the receiver-sender half-connection; see tx_ccid.
 
 seq_window = 100
        The initial sequence window (sec. 7.5.2).
index 6a72ff52a8a4fc83c8b3a9d975d3184f764d1570..46daea312d92544ca5946998794da0acad6080cd 100644 (file)
@@ -370,7 +370,6 @@ static inline unsigned int dccp_hdr_len(const struct sk_buff *skb)
   * Will be used to pass the state from dccp_request_sock to dccp_sock.
   *
   * @dccpms_sequence_window - Sequence Window Feature (section 7.5.2)
-  * @dccpms_ccid - Congestion Control Id (CCID) (section 10)
   * @dccpms_send_ack_vector - Send Ack Vector Feature (section 11.5)
   * @dccpms_send_ndp_count - Send NDP Count Feature (7.7.2)
   * @dccpms_pending - List of features being negotiated
@@ -378,8 +377,6 @@ static inline unsigned int dccp_hdr_len(const struct sk_buff *skb)
   */
 struct dccp_minisock {
        __u64                   dccpms_sequence_window;
-       __u8                    dccpms_rx_ccid;
-       __u8                    dccpms_tx_ccid;
        __u8                    dccpms_send_ack_vector;
        __u8                    dccpms_send_ndp_count;
        struct list_head        dccpms_pending;
index 647cb0614f843752ec64106bb179ecc3a44c9db6..bcc643f992aeb6c70ed218ebb7248e9a072ea758 100644 (file)
@@ -253,20 +253,6 @@ out_module_put:
 
 EXPORT_SYMBOL_GPL(ccid_new);
 
-struct ccid *ccid_hc_rx_new(unsigned char id, struct sock *sk, gfp_t gfp)
-{
-       return ccid_new(id, sk, 1, gfp);
-}
-
-EXPORT_SYMBOL_GPL(ccid_hc_rx_new);
-
-struct ccid *ccid_hc_tx_new(unsigned char id,struct sock *sk,  gfp_t gfp)
-{
-       return ccid_new(id, sk, 0, gfp);
-}
-
-EXPORT_SYMBOL_GPL(ccid_hc_tx_new);
-
 static void ccid_delete(struct ccid *ccid, struct sock *sk, int rx)
 {
        struct ccid_operations *ccid_ops;
index 803343aed00447abdbcb0e6816531dfd5609283e..18f69423a7084fc929c359a5168d4250c5beb208 100644 (file)
@@ -111,11 +111,6 @@ extern int  ccid_getsockopt_builtin_ccids(struct sock *sk, int len,
 extern struct ccid *ccid_new(unsigned char id, struct sock *sk, int rx,
                             gfp_t gfp);
 
-extern struct ccid *ccid_hc_rx_new(unsigned char id, struct sock *sk,
-                                  gfp_t gfp);
-extern struct ccid *ccid_hc_tx_new(unsigned char id, struct sock *sk,
-                                  gfp_t gfp);
-
 static inline int ccid_get_current_rx_ccid(struct dccp_sock *dp)
 {
        struct ccid *ccid = dp->dccps_hc_rx_ccid;
index 077f78d579c47323eae0780582f2221cf3940737..a0d5891a37bf9cf17b39ab3e3303b76b08e28318 100644 (file)
@@ -1124,22 +1124,9 @@ int dccp_feat_init(struct sock *sk)
        INIT_LIST_HEAD(&dmsk->dccpms_pending);  /* XXX no longer used */
        INIT_LIST_HEAD(&dmsk->dccpms_conf);     /* XXX no longer used */
 
-       /* CCID L */
-       rc = __feat_register_sp(&dp->dccps_featneg, DCCPF_CCID, 1, 0,
-                               &dmsk->dccpms_tx_ccid, 1);
-       if (rc)
-               goto out;
-
-       /* CCID R */
-       rc = __feat_register_sp(&dp->dccps_featneg, DCCPF_CCID, 0, 0,
-                               &dmsk->dccpms_rx_ccid, 1);
-       if (rc)
-               goto out;
-
        /* Ack ratio */
        rc = __feat_register_nn(&dp->dccps_featneg, DCCPF_ACK_RATIO, 0,
                                dp->dccps_l_ack_ratio);
-out:
        return rc;
 }
 
index 308b6b928c3d86bc80ff5794f9e7317c3bdf6dc9..210c346899baf59fcb7792db537658580f160544 100644 (file)
@@ -45,8 +45,6 @@ EXPORT_SYMBOL_GPL(dccp_death_row);
 void dccp_minisock_init(struct dccp_minisock *dmsk)
 {
        dmsk->dccpms_sequence_window = sysctl_dccp_feat_sequence_window;
-       dmsk->dccpms_rx_ccid         = sysctl_dccp_feat_rx_ccid;
-       dmsk->dccpms_tx_ccid         = sysctl_dccp_feat_tx_ccid;
        dmsk->dccpms_send_ack_vector = sysctl_dccp_feat_send_ack_vector;
        dmsk->dccpms_send_ndp_count  = sysctl_dccp_feat_send_ndp_count;
 }