* Patch "net: ipv4: fix table id in getroute response" has been added to the 4.9-stable tree
@ 2017-02-01 8:11 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2017-02-01 8:11 UTC (permalink / raw)
To: dsa, davem, gregkh; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
net: ipv4: fix table id in getroute response
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
net-ipv4-fix-table-id-in-getroute-response.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From foo@baz Wed Feb 1 08:50:24 CET 2017
From: David Ahern <dsa@cumulusnetworks.com>
Date: Wed, 11 Jan 2017 15:42:17 -0800
Subject: net: ipv4: fix table id in getroute response
From: David Ahern <dsa@cumulusnetworks.com>
[ Upstream commit 8a430ed50bb1b19ca14a46661f3b1b35f2fb5c39 ]
rtm_table is an 8-bit field while table ids are allowed up to u32. Commit
709772e6e065 ("net: Fix routing tables with id > 255 for legacy software")
added the preference to set rtm_table in dumps to RT_TABLE_COMPAT if the
table id is > 255. The table id returned on get route requests should do
the same.
Fixes: c36ba6603a11 ("net: Allow user to get table id from route lookup")
Signed-off-by: David Ahern <dsa@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
net/ipv4/route.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/net/ipv4/route.c
+++ b/net/ipv4/route.c
@@ -2440,7 +2440,7 @@ static int rt_fill_info(struct net *net,
r->rtm_dst_len = 32;
r->rtm_src_len = 0;
r->rtm_tos = fl4->flowi4_tos;
- r->rtm_table = table_id;
+ r->rtm_table = table_id < 256 ? table_id : RT_TABLE_COMPAT;
if (nla_put_u32(skb, RTA_TABLE, table_id))
goto nla_put_failure;
r->rtm_type = rt->rt_type;
Patches currently in stable-queue which might be from dsa@cumulusnetworks.com are
queue-4.9/net-lwtunnel-handle-lwtunnel_fill_encap-failure.patch
queue-4.9/lwtunnel-fix-autoload-of-lwt-modules.patch
queue-4.9/net-ipv4-fix-table-id-in-getroute-response.patch
queue-4.9/net-mpls-fix-multipath-selection-for-lsr-use-case.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-02-01 8:12 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-01 8:11 Patch "net: ipv4: fix table id in getroute response" has been added to the 4.9-stable tree gregkh
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.