Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
e11d9d30
Commit
e11d9d30
authored
Nov 13, 2006
by
Gerrit Renker
Committed by
David S. Miller
Dec 02, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[DCCP]: Increment sequence numbers on retransmitted Response packets
Problem:
parent
08a29e41
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
7 deletions
+13
-7
net/dccp/minisocks.c
net/dccp/minisocks.c
+9
-7
net/dccp/output.c
net/dccp/output.c
+4
-0
No files found.
net/dccp/minisocks.c
View file @
e11d9d30
...
@@ -196,15 +196,17 @@ struct sock *dccp_check_req(struct sock *sk, struct sk_buff *skb,
...
@@ -196,15 +196,17 @@ struct sock *dccp_check_req(struct sock *sk, struct sk_buff *skb,
/* Check for retransmitted REQUEST */
/* Check for retransmitted REQUEST */
if
(
dccp_hdr
(
skb
)
->
dccph_type
==
DCCP_PKT_REQUEST
)
{
if
(
dccp_hdr
(
skb
)
->
dccph_type
==
DCCP_PKT_REQUEST
)
{
if
(
after48
(
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
,
dccp_rsk
(
req
)
->
dreq_isr
))
{
struct
dccp_request_sock
*
dreq
=
dccp_rsk
(
req
);
struct
dccp_request_sock
*
dreq
=
dccp_rsk
(
req
);
if
(
after48
(
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
,
dreq
->
dreq_isr
))
{
dccp_pr_debug
(
"Retransmitted REQUEST
\n
"
);
dccp_pr_debug
(
"Retransmitted REQUEST
\n
"
);
/* Send another RESPONSE packet */
dreq
->
dreq_isr
=
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
;
dccp_set_seqno
(
&
dreq
->
dreq_iss
,
dreq
->
dreq_iss
+
1
);
/*
dccp_set_seqno
(
&
dreq
->
dreq_isr
,
* Send another RESPONSE packet
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
);
* To protect against Request floods, increment retrans
* counter (backoff, monitored by dccp_response_timer).
*/
req
->
retrans
++
;
req
->
rsk_ops
->
rtx_syn_ack
(
sk
,
req
,
NULL
);
req
->
rsk_ops
->
rtx_syn_ack
(
sk
,
req
,
NULL
);
}
}
/* Network Duplicate, discard packet */
/* Network Duplicate, discard packet */
...
...
net/dccp/output.c
View file @
e11d9d30
...
@@ -332,6 +332,8 @@ struct sk_buff *dccp_make_response(struct sock *sk, struct dst_entry *dst,
...
@@ -332,6 +332,8 @@ struct sk_buff *dccp_make_response(struct sock *sk, struct dst_entry *dst,
skb
->
dst
=
dst_clone
(
dst
);
skb
->
dst
=
dst_clone
(
dst
);
dreq
=
dccp_rsk
(
req
);
dreq
=
dccp_rsk
(
req
);
if
(
inet_rsk
(
req
)
->
acked
)
/* increase ISS upon retransmission */
dccp_inc_seqno
(
&
dreq
->
dreq_iss
);
DCCP_SKB_CB
(
skb
)
->
dccpd_type
=
DCCP_PKT_RESPONSE
;
DCCP_SKB_CB
(
skb
)
->
dccpd_type
=
DCCP_PKT_RESPONSE
;
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
=
dreq
->
dreq_iss
;
DCCP_SKB_CB
(
skb
)
->
dccpd_seq
=
dreq
->
dreq_iss
;
...
@@ -354,6 +356,8 @@ struct sk_buff *dccp_make_response(struct sock *sk, struct dst_entry *dst,
...
@@ -354,6 +356,8 @@ struct sk_buff *dccp_make_response(struct sock *sk, struct dst_entry *dst,
dccp_csum_outgoing
(
skb
);
dccp_csum_outgoing
(
skb
);
/* We use `acked' to remember that a Response was already sent. */
inet_rsk
(
req
)
->
acked
=
1
;
DCCP_INC_STATS
(
DCCP_MIB_OUTSEGS
);
DCCP_INC_STATS
(
DCCP_MIB_OUTSEGS
);
return
skb
;
return
skb
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment