[15/65] ah: Dont return NET_XMIT_DROP on input.

From: Greg KH
Date: Wed Feb 01 2012 - 16:08:50 EST


3.0-stable review patch. If anyone has any objections, please let me know.

------------------

From: Nick Bowler <nbowler@xxxxxxxxxxxxxxxx>

commit 4b90a603a1b21d63cf743cc833680cb195a729f6 upstream.

When the ahash driver returns -EBUSY, AH4/6 input functions return
NET_XMIT_DROP, presumably copied from the output code path. But
returning transmit codes on input doesn't make a lot of sense.
Since NET_XMIT_DROP is a positive int, this gets interpreted as
the next header type (i.e., success). As that can only end badly,
remove the check.

Signed-off-by: Nick Bowler <nbowler@xxxxxxxxxxxxxxxx>
Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
net/ipv4/ah4.c | 2 --
net/ipv6/ah6.c | 2 --
2 files changed, 4 deletions(-)

--- a/net/ipv4/ah4.c
+++ b/net/ipv4/ah4.c
@@ -369,8 +369,6 @@ static int ah_input(struct xfrm_state *x
if (err == -EINPROGRESS)
goto out;

- if (err == -EBUSY)
- err = NET_XMIT_DROP;
goto out_free;
}

--- a/net/ipv6/ah6.c
+++ b/net/ipv6/ah6.c
@@ -581,8 +581,6 @@ static int ah6_input(struct xfrm_state *
if (err == -EINPROGRESS)
goto out;

- if (err == -EBUSY)
- err = NET_XMIT_DROP;
goto out_free;
}



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/