netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255
@ 2019-02-21  0:23 Kalash Nainwal
  2019-02-22 23:22 ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Kalash Nainwal @ 2019-02-21  0:23 UTC (permalink / raw)
  To: netdev; +Cc: davem, linux-kernel, kalash

Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255 to
keep legacy software happy. This is similar to what was done for
ipv4 in commit 709772e6e065 ("net: Fix routing tables with
id > 255 for legacy software").

Signed-off-by: Kalash Nainwal <kalash@arista.com>
---
 net/ipv6/route.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 964491cf3672..77c07b2943f5 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -4649,7 +4649,7 @@ static int rt6_fill_node(struct net *net, struct sk_buff *skb,
 		table = rt->fib6_table->tb6_id;
 	else
 		table = RT6_TABLE_UNSPEC;
-	rtm->rtm_table = table;
+	rtm->rtm_table = table < 256 ? table : RT_TABLE_COMPAT;
 	if (nla_put_u32(skb, RTA_TABLE, table))
 		goto nla_put_failure;
 
-- 
2.19.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255
  2019-02-21  0:23 [PATCH] Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255 Kalash Nainwal
@ 2019-02-22 23:22 ` David Miller
  2019-02-22 23:28   ` Kalash Nainwal
  0 siblings, 1 reply; 3+ messages in thread
From: David Miller @ 2019-02-22 23:22 UTC (permalink / raw)
  To: kalash; +Cc: netdev, linux-kernel

From: Kalash Nainwal <kalash@arista.com>
Date: Wed, 20 Feb 2019 16:23:04 -0800

> Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255 to
> keep legacy software happy. This is similar to what was done for
> ipv4 in commit 709772e6e065 ("net: Fix routing tables with
> id > 255 for legacy software").
> 
> Signed-off-by: Kalash Nainwal <kalash@arista.com>

Applied and queued up for -stable.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255
  2019-02-22 23:22 ` David Miller
@ 2019-02-22 23:28   ` Kalash Nainwal
  0 siblings, 0 replies; 3+ messages in thread
From: Kalash Nainwal @ 2019-02-22 23:28 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, linux-kernel

On Fri, Feb 22, 2019 at 3:22 PM David Miller <davem@davemloft.net> wrote:
>
> From: Kalash Nainwal <kalash@arista.com>
> Date: Wed, 20 Feb 2019 16:23:04 -0800
>
> > Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255 to
> > keep legacy software happy. This is similar to what was done for
> > ipv4 in commit 709772e6e065 ("net: Fix routing tables with
> > id > 255 for legacy software").
> >
> > Signed-off-by: Kalash Nainwal <kalash@arista.com>
>
> Applied and queued up for -stable.

Thanks Dave.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-02-22 23:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-21  0:23 [PATCH] Set rtm_table to RT_TABLE_COMPAT for ipv6 for tables > 255 Kalash Nainwal
2019-02-22 23:22 ` David Miller
2019-02-22 23:28   ` Kalash Nainwal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).