I think use variable 'min' instead of number '1024' is better.
Signed-off-by: Lin Zhang
---
net/netfilter/nf_nat_proto_common.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/netfilter/nf_nat_proto_common.c
b/net/netfilter/nf_nat_proto_co
Storing the left length of skb into 'len' actually has no effect
so we can remove it.
Signed-off-by: Lin Zhang
---
net/ipv6/exthdrs_core.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/net/ipv6/exthdrs_core.c b/net/ipv6/exthdrs_core.c
index 305e2ed..98096ea 100644
---
The phonet_protocol structs don't need to be written by anyone and
so can be marked as const.
Signed-off-by: Lin Zhang
---
changelog:
v1 -> v2:
* remove __read_mostly tag
v2 -> v3:
* revert __read_mostly tag
---
include/net/phonet/phonet.h | 6 --
net/phonet/
Signed-off-by: Lin Zhang
---
changelog:
v2 -> v3:
* fix phonet_header_ops type mismatch error
---
include/linux/if_phonet.h | 2 +-
net/phonet/af_phonet.c| 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/linux/if_phonet.h b/include/linux/if_phone
In function {ipv4,ipv6}_synproxy_hook we expect a normal tcp packet,
but the real server maybe reply an icmp error packet related to the
exist tcp conntrack, so we will access wrong tcp data.
For fix it, check for the protocol field and only process tcp traffic.
Signed-off-by: Lin Zhang
In function {ipv4,ipv6}_synproxy_hook we expect a normal tcp packet,
but the real server maybe reply an icmp error packet related to the
exist tcp conntrack, so we will access wrong tcp data.
For fix it, check for the protocol field and only process tcp traffic.
Signed-off-by: Lin Zhang
The phonet_protocol structs don't need to be written by anyone and
so can be marked as const.
Signed-off-by: Lin Zhang
---
changelog:
v1 -> v2:
* remove __read_mostly tag
---
include/net/phonet/phonet.h | 6 --
net/phonet/af_phonet.c | 15 ---
ne
Signed-off-by: Lin Zhang
---
net/phonet/af_phonet.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c
index f925753..b12142e 100644
--- a/net/phonet/af_phonet.c
+++ b/net/phonet/af_phonet.c
@@ -149,7 +149,7 @@ static int
The phonet_protocol structs don't need to be written by anyone and
so can be marked as const.
Signed-off-by: Lin Zhang
---
include/net/phonet/phonet.h | 6 --
net/phonet/af_phonet.c | 15 ---
net/phonet/datagram.c | 2 +-
net/phonet/pep.c| 2 +-
4
Signed-off-by: Lin Zhang
---
net/phonet/af_phonet.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/phonet/af_phonet.c b/net/phonet/af_phonet.c
index f925753..b12142e 100644
--- a/net/phonet/af_phonet.c
+++ b/net/phonet/af_phonet.c
@@ -149,7 +149,7 @@ static int
In function {ipv4,ipv6}_synproxy_hook we expect a normal tcp packet,
but the real server maybe reply an icmp error packet related to the
exist tcp conntrack, so we will access wrong tcp data.
For fix it, we simply pass IP_CT_RELATED_REPLY packets.
Signed-off-by: Lin Zhang
---
net/ipv4
In the pull_pages code block, if the first frag size > eat,
we can end the loop in advance to avoid extra copy.
Signed-off-by: Lin Zhang
---
v1 -> v2:
* no need to rewrite skb_shinfo(skb)->nr_frags, per Eric Dumazet.
---
net/core/skbuff.c | 3 +++
1 file changed, 3 insertions
2017-07-17 15:32 GMT+08:00 Eric Dumazet :
> On Mon, 2017-07-17 at 10:22 +0800, Lin Zhang wrote:
>> In the pull_pages code block, if the first frag size > eat,
>> we can end the loop in advance to avoid extra copy.
>>
>> Signed-off-by: Lin Zhang
>> ---
>&
In the pull_pages code block, if the first frag size > eat,
we can end the loop in advance to avoid extra copy.
Signed-off-by: Lin Zhang
---
net/core/skbuff.c | 4
1 file changed, 4 insertions(+)
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index f990eb8..c00a1df 100644
--- a/
2017-07-06 17:23 GMT+08:00 Eric Dumazet :
> On Thu, 2017-07-06 at 02:16 -0700, Eric Dumazet wrote:
>> On Thu, 2017-07-06 at 17:01 +0800, Lin Zhang wrote:
>> > In the pull_pages code block, if the first frags size > eat,
>> > we can end the loop in advance to avoid ex
In the pull_pages code block, if the first frags size > eat,
we can end the loop in advance to avoid extra copy.
Signed-off-by: Lin Zhang
---
net/core/skbuff.c | 4
1 file changed, 4 insertions(+)
diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index f990eb8..c00a1df 100644
--- a/
if kernel support NF_CT_EXT_EXPAND extension,
user could call nf_ct_expand_area_add() to register a new expansion
but not need to predefine an id in enum nf_ct_ext_id.
Signed-off-by: Lin Zhang
---
include/net/netfilter/nf_conntrack_expand.h | 26 ++
include/net/netfilter/nf_conntrack_extend.h
ui_connect.
Signed-off-by: Lin Zhang
---
net/llc/af_llc.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/net/llc/af_llc.c b/net/llc/af_llc.c
index 8364fe5..c38d16f 100644
--- a/net/llc/af_llc.c
+++ b/net/llc/af_llc.c
@@ -311,6 +311,8 @@ static int llc_ui_bind(struct socket *sock, struc
call dev_queue_xmit.
I think the latest kernel is have the same problem and that
dev_put should be behind of the dev_queue_xmit.
Signed-off-by: Lin Zhang
Acked-by: Stefan Schmidt
---
changelog:
v1 -> v2:
* split v1 into two patches, per Stefan Schmidt.
Hello, Stefan:
If you
Explicit set skb->sk is needless, sock_alloc_send_skb is already set it.
Signed-off-by: Lin Zhang
Acked-by: Stefan Schmidt
---
changelog:
v1 -> v2:
* split v1 into two patches, per Stefan Schmidt.
Thanks to Stefan Schmidt for reviewing !
---
net/ieee802154/socket.c | 2 --
20 matches
Mail list logo