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
Kirill Smelkov
linux
Commits
31457e34
Commit
31457e34
authored
Nov 01, 2002
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[NET]: Some missed cases of dst_pmtu conversion.
parent
32c3b723
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
+9
-9
net/ipv4/ip_gre.c
net/ipv4/ip_gre.c
+2
-2
net/ipv4/ipip.c
net/ipv4/ipip.c
+2
-2
net/ipv4/ipmr.c
net/ipv4/ipmr.c
+2
-2
net/ipv4/netfilter/ipt_TCPMSS.c
net/ipv4/netfilter/ipt_TCPMSS.c
+3
-3
No files found.
net/ipv4/ip_gre.c
View file @
31457e34
...
@@ -523,11 +523,11 @@ void ipgre_err(struct sk_buff *skb, u32 info)
...
@@ -523,11 +523,11 @@ void ipgre_err(struct sk_buff *skb, u32 info)
/* change mtu on this route */
/* change mtu on this route */
if
(
type
==
ICMP_DEST_UNREACH
&&
code
==
ICMP_FRAG_NEEDED
)
{
if
(
type
==
ICMP_DEST_UNREACH
&&
code
==
ICMP_FRAG_NEEDED
)
{
if
(
rel_info
>
skb2
->
dst
->
pmtu
)
{
if
(
rel_info
>
dst_pmtu
(
skb2
->
dst
)
)
{
kfree_skb
(
skb2
);
kfree_skb
(
skb2
);
return
;
return
;
}
}
skb2
->
dst
->
pmtu
=
rel_info
;
skb2
->
dst
->
ops
->
update_pmtu
(
skb2
->
dst
,
rel_info
)
;
rel_info
=
htonl
(
rel_info
);
rel_info
=
htonl
(
rel_info
);
}
else
if
(
type
==
ICMP_TIME_EXCEEDED
)
{
}
else
if
(
type
==
ICMP_TIME_EXCEEDED
)
{
struct
ip_tunnel
*
t
=
(
struct
ip_tunnel
*
)
skb2
->
dev
->
priv
;
struct
ip_tunnel
*
t
=
(
struct
ip_tunnel
*
)
skb2
->
dev
->
priv
;
...
...
net/ipv4/ipip.c
View file @
31457e34
...
@@ -452,11 +452,11 @@ void ipip_err(struct sk_buff *skb, u32 info)
...
@@ -452,11 +452,11 @@ void ipip_err(struct sk_buff *skb, u32 info)
/* change mtu on this route */
/* change mtu on this route */
if
(
type
==
ICMP_DEST_UNREACH
&&
code
==
ICMP_FRAG_NEEDED
)
{
if
(
type
==
ICMP_DEST_UNREACH
&&
code
==
ICMP_FRAG_NEEDED
)
{
if
(
rel_info
>
skb2
->
dst
->
pmtu
)
{
if
(
rel_info
>
dst_pmtu
(
skb2
->
dst
)
)
{
kfree_skb
(
skb2
);
kfree_skb
(
skb2
);
return
;
return
;
}
}
skb2
->
dst
->
pmtu
=
rel_info
;
skb2
->
dst
->
ops
->
update_pmtu
(
skb2
->
dst
,
rel_info
)
;
rel_info
=
htonl
(
rel_info
);
rel_info
=
htonl
(
rel_info
);
}
else
if
(
type
==
ICMP_TIME_EXCEEDED
)
{
}
else
if
(
type
==
ICMP_TIME_EXCEEDED
)
{
struct
ip_tunnel
*
t
=
(
struct
ip_tunnel
*
)
skb2
->
dev
->
priv
;
struct
ip_tunnel
*
t
=
(
struct
ip_tunnel
*
)
skb2
->
dev
->
priv
;
...
...
net/ipv4/ipmr.c
View file @
31457e34
...
@@ -1111,7 +1111,7 @@ static inline int ipmr_forward_finish(struct sk_buff *skb)
...
@@ -1111,7 +1111,7 @@ static inline int ipmr_forward_finish(struct sk_buff *skb)
{
{
struct
dst_entry
*
dst
=
skb
->
dst
;
struct
dst_entry
*
dst
=
skb
->
dst
;
if
(
skb
->
len
<=
dst
->
pmtu
)
if
(
skb
->
len
<=
dst
_pmtu
(
dst
)
)
return
dst
->
output
(
skb
);
return
dst
->
output
(
skb
);
else
else
return
ip_fragment
(
skb
,
dst
->
output
);
return
ip_fragment
(
skb
,
dst
->
output
);
...
@@ -1167,7 +1167,7 @@ static void ipmr_queue_xmit(struct sk_buff *skb, struct mfc_cache *c,
...
@@ -1167,7 +1167,7 @@ static void ipmr_queue_xmit(struct sk_buff *skb, struct mfc_cache *c,
dev
=
rt
->
u
.
dst
.
dev
;
dev
=
rt
->
u
.
dst
.
dev
;
if
(
skb
->
len
+
encap
>
rt
->
u
.
dst
.
pmtu
&&
(
ntohs
(
iph
->
frag_off
)
&
IP_DF
))
{
if
(
skb
->
len
+
encap
>
dst_pmtu
(
&
rt
->
u
.
dst
)
&&
(
ntohs
(
iph
->
frag_off
)
&
IP_DF
))
{
/* Do not fragment multicasts. Alas, IPv4 does not
/* Do not fragment multicasts. Alas, IPv4 does not
allow to send ICMP, so that packets will disappear
allow to send ICMP, so that packets will disappear
to blackhole.
to blackhole.
...
...
net/ipv4/netfilter/ipt_TCPMSS.c
View file @
31457e34
...
@@ -85,14 +85,14 @@ ipt_tcpmss_target(struct sk_buff **pskb,
...
@@ -85,14 +85,14 @@ ipt_tcpmss_target(struct sk_buff **pskb,
return
NF_DROP
;
/* or IPT_CONTINUE ?? */
return
NF_DROP
;
/* or IPT_CONTINUE ?? */
}
}
if
(
(
*
pskb
)
->
dst
->
pmtu
<=
(
sizeof
(
struct
iphdr
)
+
sizeof
(
struct
tcphdr
)))
{
if
(
dst_pmtu
((
*
pskb
)
->
dst
)
<=
(
sizeof
(
struct
iphdr
)
+
sizeof
(
struct
tcphdr
)))
{
if
(
net_ratelimit
())
if
(
net_ratelimit
())
printk
(
KERN_ERR
printk
(
KERN_ERR
"ipt_tcpmss_target: unknown or invalid path-MTU (%d)
\n
"
,
(
*
pskb
)
->
dst
->
pmtu
);
"ipt_tcpmss_target: unknown or invalid path-MTU (%d)
\n
"
,
dst_pmtu
((
*
pskb
)
->
dst
)
);
return
NF_DROP
;
/* or IPT_CONTINUE ?? */
return
NF_DROP
;
/* or IPT_CONTINUE ?? */
}
}
newmss
=
(
*
pskb
)
->
dst
->
pmtu
-
sizeof
(
struct
iphdr
)
-
sizeof
(
struct
tcphdr
);
newmss
=
dst_pmtu
((
*
pskb
)
->
dst
->
pmtu
)
-
sizeof
(
struct
iphdr
)
-
sizeof
(
struct
tcphdr
);
}
else
}
else
newmss
=
tcpmssinfo
->
mss
;
newmss
=
tcpmssinfo
->
mss
;
...
...
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