diff options
author | Gerrit Renker <gerrit@erg.abdn.ac.uk> | 2011-07-03 09:53:12 -0600 |
---|---|---|
committer | Gerrit Renker <gerrit@erg.abdn.ac.uk> | 2011-07-04 12:37:40 -0600 |
commit | 58fdea0f3170c13a3b875ef904d5b67cf73814be (patch) | |
tree | 9cdaa4c22734531b21479dc594dadf6ffbcd36d4 /net/dccp/ccids/ccid2.h | |
parent | b4d5f4b2884625d13c7ef5b9fd085ec93bbf545c (diff) |
dccp ccid-2: Use existing function to test for data packets
This replaces a switch statement with a test, using the equivalent
function dccp_data_packet(skb). It also doubles the range of the field
`rx_num_data_pkts' by changing the type from `int' to `u32', avoiding
signed/unsigned comparison with the u16 field `dccps_r_ack_ratio'.
Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Diffstat (limited to 'net/dccp/ccids/ccid2.h')
-rw-r--r-- | net/dccp/ccids/ccid2.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/dccp/ccids/ccid2.h b/net/dccp/ccids/ccid2.h index f17460a8fe7..da021ebce9a 100644 --- a/net/dccp/ccids/ccid2.h +++ b/net/dccp/ccids/ccid2.h @@ -97,8 +97,12 @@ static inline u32 rfc3390_bytes_to_packets(const u32 smss) return smss <= 1095 ? 4 : (smss > 2190 ? 2 : 3); } +/** + * struct ccid2_hc_rx_sock - Receiving end of CCID-2 half-connection + * @rx_num_data_pkts: number of data packets received since last feedback + */ struct ccid2_hc_rx_sock { - int rx_data; + u32 rx_num_data_pkts; }; static inline struct ccid2_hc_tx_sock *ccid2_hc_tx_sk(const struct sock *sk) |