From patchwork Tue Jun 14 06:34:53 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sven Eckelmann X-Patchwork-Id: 16382 X-Patchwork-Delegate: mareklindner@neomailbox.ch Return-Path: X-Original-To: patchwork@open-mesh.org Delivered-To: patchwork@open-mesh.org Received: from open-mesh.org (localhost [IPv6:::1]) by open-mesh.org (Postfix) with ESMTP id A208F81466; Tue, 14 Jun 2016 08:35:11 +0200 (CEST) Authentication-Results: open-mesh.org; dmarc=none header.from=narfation.org Authentication-Results: open-mesh.org; dkim=fail reason="verification failed; unprotected key" header.d=narfation.org header.i=@narfation.org header.b=OwiTfc1g; dkim-adsp=fail (unprotected policy); dkim-atps=neutral Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2001:4d88:2000:7::2; helo=v3-1039.vlinux.de; envelope-from=sven@narfation.org; receiver=b.a.t.m.a.n@lists.open-mesh.org Authentication-Results: open-mesh.org; dmarc=pass header.from=narfation.org Received: from v3-1039.vlinux.de (narfation.org [IPv6:2001:4d88:2000:7::2]) by open-mesh.org (Postfix) with ESMTPS id AF15D80F94 for ; Tue, 14 Jun 2016 08:35:09 +0200 (CEST) Received: from sven-desktop.home.narfation.org (p200300C593C0D4F90000000000002E16.dip0.t-ipconnect.de [IPv6:2003:c5:93c0:d4f9::2e16]) by v3-1039.vlinux.de (Postfix) with ESMTPSA id B3FC311000C for ; Tue, 14 Jun 2016 08:35:08 +0200 (CEST) Authentication-Results: v3-1039.vlinux.de; dmarc=none header.from=narfation.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=narfation.org; s=20121; t=1465886108; bh=wKgHqbUVxTDFk1AyATztnSK2jdQi33Be1D8u/fOrsYs=; h=From:To:Subject:Date:From; b=OwiTfc1g20bB3sLYqHrFkB3AU8Kuh4xlG8yTSDe7frOowfBgPXtJ4cGh3oMkTnJwc VwragrW1xnju41ZVHKRxHkvkwnbr06HZD8psEWQe4HkYYNn8vUGA1IFm1oBN2EdT/W luWbhWOwkAAcXKg3TCiL+8NJN8GUEbLXO4q+CEJo= From: Sven Eckelmann To: b.a.t.m.a.n@lists.open-mesh.org Date: Tue, 14 Jun 2016 08:34:53 +0200 Message-Id: <1465886093-9609-1-git-send-email-sven@narfation.org> X-Mailer: git-send-email 2.8.1 Subject: [B.A.T.M.A.N.] [PATCH next] batman-adv: remove NET_XMIT_POLICED X-BeenThere: b.a.t.m.a.n@lists.open-mesh.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: The list for a Better Approach To Mobile Ad-hoc Networking List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: The list for a Better Approach To Mobile Ad-hoc Networking Errors-To: b.a.t.m.a.n-bounces@lists.open-mesh.org Sender: "B.A.T.M.A.N" From: Florian Westphal BATMAN uses it as an intermediate return value to signal forwarding vs. buffering, but it did not return POLICED to callers outside of BATMAN. Signed-off-by: Florian Westphal Signed-off-by: David S. Miller [sven@narfation.org: rebased on top of TX path rewrite] Signed-off-by: Sven Eckelmann --- Taken from upstream commit 99860208bc62 ("sched: remove NET_XMIT_POLICED"). Please make sure you first apply * https://patchwork.open-mesh.org/patch/16362/ * https://patchwork.open-mesh.org/patch/16363/ * https://patchwork.open-mesh.org/patch/16364/ --- net/batman-adv/send.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c index 49836da..729deec 100644 --- a/net/batman-adv/send.c +++ b/net/batman-adv/send.c @@ -20,6 +20,7 @@ #include #include +#include #include #include #include @@ -156,7 +157,7 @@ int batadv_send_unicast_skb(struct sk_buff *skb, * host, NULL can be passed as recv_if and no interface alternating is * attempted. * - * Return: -1 on failure (and the skb is not consumed), NET_XMIT_POLICED if the + * Return: -1 on failure (and the skb is not consumed), -EINPROGRESS if the * skb is buffered for later transmit or the NET_XMIT status returned by the * lower routine if the packet has been passed down. * @@ -191,7 +192,7 @@ int batadv_send_skb_to_orig(struct sk_buff *skb, * network coding fails, then send the packet as usual. */ if (recv_if && batadv_nc_skb_forward(skb, neigh_node)) - ret = NET_XMIT_POLICED; + ret = -EINPROGRESS; else ret = batadv_send_unicast_skb(skb, neigh_node);