]> git.baikalelectronics.ru Git - kernel.git/commit
net: Allow user to get table id from route lookup
authorDavid Ahern <dsa@cumulusnetworks.com>
Wed, 2 Sep 2015 20:58:36 +0000 (13:58 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 15 Sep 2015 19:01:41 +0000 (12:01 -0700)
commit75194bf005f31848b5f6ed535f2ece45d52295f3
tree4ce0ed1e81dcc34125b19cdb7d4c6e431b1bf4bd
parentba7483f3bd10e2d87378969104216bd045ccb7a9
net: Allow user to get table id from route lookup

rt_fill_info which is called for 'route get' requests hardcodes the
table id as RT_TABLE_MAIN which is not correct when multiple tables
are used. Use the newly added table id in the rtable to send back
the correct table similar to what is done for IPv6.

To maintain current ABI a new request flag, RTM_F_LOOKUP_TABLE, is
added to indicate the actual table is wanted versus the hardcoded
response.

Signed-off-by: David Ahern <dsa@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/uapi/linux/rtnetlink.h
net/ipv4/route.c