Patchwork [3.5.y.z,extended,stable] Patch "bridging: fix rx_handlers return code" has been added to staging queue

login
register
mail settings
Submitter Luis Henriques
Date March 20, 2013, 10:44 a.m.
Message ID <1363776250-5533-1-git-send-email-luis.henriques@canonical.com>
Download mbox | patch
Permalink /patch/229338/
State New
Headers show

Comments

Luis Henriques - March 20, 2013, 10:44 a.m.
This is a note to let you know that I have just added a patch titled

    bridging: fix rx_handlers return code

to the linux-3.5.y-queue branch of the 3.5.y.z extended stable tree 
which can be found at:

 http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/heads/linux-3.5.y-queue

If you, or anyone else, feels it should not be added to this tree, please 
reply to this email.

For more information about the 3.5.y.z tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable

Thanks.
-Luis

------

From a13bd602aaca7f4316eca41733200e651af91743 Mon Sep 17 00:00:00 2001
From: Cristian Bercaru <B43982@freescale.com>
Date: Fri, 8 Mar 2013 07:03:38 +0000
Subject: [PATCH] bridging: fix rx_handlers return code

commit 3bc1b1add7a8484cc4a261c3e128dbe1528ce01f upstream.

The frames for which rx_handlers return RX_HANDLER_CONSUMED are no longer
counted as dropped. They are counted as successfully received by
'netif_receive_skb'.

This allows network interface drivers to correctly update their RX-OK and
RX-DRP counters based on the result of 'netif_receive_skb'.

Signed-off-by: Cristian Bercaru <B43982@freescale.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
[ luis: adjust context ]
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
---
 net/core/dev.c | 1 +
 1 file changed, 1 insertion(+)

--
1.8.1.2

Patch

diff --git a/net/core/dev.c b/net/core/dev.c
index 3ad746b..097dd07 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3227,6 +3227,7 @@  ncls:
 		}
 		switch (rx_handler(&skb)) {
 		case RX_HANDLER_CONSUMED:
+			ret = NET_RX_SUCCESS;
 			goto out;
 		case RX_HANDLER_ANOTHER:
 			goto another_round;