ipv6: correct return on ipv6_rcv() packet drop
Subsystems (3)
PATCH 1/1 ipv6: correct return on ipv6_rcv() packet drop
The routine ipv6_rcv() uses magic number 0 for a return when it drops a packet. This corresponds to NET_RX_SUCCESS, which is obviously incorrect. Correct this by using NET_RX_DROP instead.
ps. It isn't exactly clear who the IPv6 maintainers are, apologies if I've missed any.
net/ipv6/ip6_input.c +3 -3
@@ -63,7 +63,7 @@ int ipv6_rcv(struct sk_buff *skb, struct net_device *dev, struct packet_type *ptif (skb->pkt_type ==PACKET_OTHERHOST ) {kfree_skb (skb); -return 0 ; +return NET_RX_DROP ; }rcu_read_lock ();
@@ -133,7 +133,7 @@ int ipv6_rcv(struct sk_buff *skb, struct net_device *dev, struct packet_type *ptif (ipv6_parse_hopopts (skb) <0 ) {IP6_INC_STATS_BH (net, idev,IPSTATS_MIB_INHDRERRORS );rcu_read_unlock (); -return 0 ; +return NET_RX_DROP ; } }
@@ -146,7 +146,7 @@ err: drop:rcu_read_unlock ();kfree_skb (skb); -return 0 ; +return NET_RX_DROP ; }/*
From: Mark Smith <[email protected]>
Date: Tue, 7 Jul 2009 06:56:24 +0930
Quoted 8 lines
The routine
ipv6_rcv()uses magic number 0 for a return when it drops a packet. This corresponds toNET_RX_SUCCESS, which is obviously incorrect. Correct this by usingNET_RX_DROPinstead.ps. It isn't exactly clear who the IPv6 maintainers are, apologies if I've missed any.
Signed-off-by Mark Smith <[email protected]>
Applied.
Hi Dave,
Quoted 7 lines · On Mon, 06 Jul 2009 18:09:45 -0700 (PDT) David Miller <[email protected]>…
From: Mark Smith <[email protected]>
Date: Tue, 7 Jul 2009 06:56:24 +0930Quoted 4 lines
The routine
ipv6_rcv()uses magic number 0 for a return when it drops a packet. This corresponds toNET_RX_SUCCESS, which is obviously incorrect. Correct this by usingNET_RX_DROPinstead.
Quoted 6 lines
Quoted 4 lines
ps. It isn't exactly clear who the IPv6 maintainers are, apologies if I've missed any.
Signed-off-by Mark Smith <[email protected]>Applied.
Today I came across this earlier partial version of what I independently identified and submitted, so I shouldn't get full credit for it:
http://lkml.indiana.edu/hypermail/linux/kernel/0804.1/2393.html
Regards,
Mark.
David Miller
maintainerFrom: Mark Smith <[email protected]>
Date: Tue, 7 Jul 2009 18:50:15 +0930
Quoted 5 lines
Today I came across this earlier partial version of what I independently identified and submitted, so I shouldn't get full credit for it:
http://lkml.indiana.edu/hypermail/linux/kernel/0804.1/2393.html
I already pushed your change out to my public tree so we're past the point of being able to modify the commit message.
We'll just try to be more careful next time.
Quoted 7 lines · On Tue, 07 Jul 2009 08:52:19 -0700 (PDT) David Miller <[email protected]>…
From: Mark Smith <[email protected]>
Date: Tue, 7 Jul 2009 18:50:15 +0930Quoted 4 lines
Today I came across this earlier partial version of what I independently identified and submitted, so I shouldn't get full credit for it:
Quoted 6 lines
I already pushed your change out to my public tree so we're past the point of being able to modify the commit message.
We'll just try to be more careful next time.
Is there an easier way to avoid this, other than a google search? I happened to discover it by doing a google search when I was at work, to see how my patch was going. I suppose possibly not.
David Miller
maintainerFrom: Mark Smith <[email protected]>
Date: Wed, 8 Jul 2009 06:34:13 +0930
Quoted 12 lines
Quoted 9 lines · On Tue, 07 Jul 2009 08:52:19 -0700 (PDT) David Miller <[email protected]>…
From: Mark Smith <[email protected]>
Date: Tue, 7 Jul 2009 18:50:15 +0930Quoted 5 lines
Today I came across this earlier partial version of what I independently identified and submitted, so I shouldn't get full credit for it:
http://lkml.indiana.edu/hypermail/linux/kernel/0804.1/2393.html
Quoted 8 lines
Quoted 4 lines
I already pushed your change out to my public tree so we're past the point of being able to modify the commit message.
We'll just try to be more careful next time.
Is there an easier way to avoid this, other than a google search? I happened to discover it by doing a google search when I was at work, to see how my patch was going. I suppose possibly not.
Perhaps some day we can have more powerful searching mechanisms on patchwork, who knows.
Feel free to discuss such ideas on the patchwork mailing list: