summaryrefslogtreecommitdiff
path: root/net/dccp/ccids/ccid3.h
diff options
context:
space:
mode:
authorGerrit Renker <gerrit@erg.abdn.ac.uk>2008-09-04 09:30:19 +0400
committerGerrit Renker <gerrit@erg.abdn.ac.uk>2008-09-04 09:45:41 +0400
commit2f3e3bbad917c426d3aba03a535809e5699de156 (patch)
treee00bd5c8ccfad4444e8cc6ee8eb0d90223292390 /net/dccp/ccids/ccid3.h
parent34a081be8e14b7ada70e069b65b05d54db4af497 (diff)
downloadlinux-2f3e3bbad917c426d3aba03a535809e5699de156.tar.xz
dccp ccid-3: Remove duplicate RX states
The only state information that the CCID-3 receiver keeps is whether initial feedback has been sent or not. Further, this overlaps with use of feedback: * state == TFRC_RSTATE_NO_DATA as long as no feedback has been sent; * state == TFRC_RSTATE_DATA as soon as the first feedback has been sent. This patch reduces the duplication, by memorising the type of the last feedback. Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
Diffstat (limited to 'net/dccp/ccids/ccid3.h')
-rw-r--r--net/dccp/ccids/ccid3.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/net/dccp/ccids/ccid3.h b/net/dccp/ccids/ccid3.h
index 0c4fadd85f94..72e110a1100f 100644
--- a/net/dccp/ccids/ccid3.h
+++ b/net/dccp/ccids/ccid3.h
@@ -114,16 +114,18 @@ static inline struct ccid3_hc_tx_sock *ccid3_hc_tx_sk(const struct sock *sk)
return hctx;
}
-/* TFRC receiver states */
-enum ccid3_hc_rx_states {
- TFRC_RSTATE_NO_DATA = 1,
- TFRC_RSTATE_DATA,
+
+enum ccid3_fback_type {
+ CCID3_FBACK_NONE = 0,
+ CCID3_FBACK_INITIAL,
+ CCID3_FBACK_PERIODIC,
+ CCID3_FBACK_PARAM_CHANGE
};
/** struct ccid3_hc_rx_sock - CCID3 receiver half-connection socket
*
* @last_counter - Tracks window counter (RFC 4342, 8.1)
- * @state - Receiver state, one of %ccid3_hc_rx_states
+ * @feedback - The type of the feedback last sent
* @x_recv - Receiver estimate of send rate (RFC 3448, sec. 4.3)
* @rtt - Receiver estimate of RTT
* @tstamp_last_feedback - Time at which last feedback was sent
@@ -133,7 +135,7 @@ enum ccid3_hc_rx_states {
*/
struct ccid3_hc_rx_sock {
u8 last_counter:4;
- enum ccid3_hc_rx_states state:8;
+ enum ccid3_fback_type feedback:4;
u32 x_recv;
u32 rtt;
ktime_t tstamp_last_feedback;