diff mbox

net: ipv6: make "ip -6 route get mark xyz" work.

Message ID 1400197121-16033-1-git-send-email-lorenzo@google.com
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

Lorenzo Colitti May 15, 2014, 11:38 p.m. UTC
Currently, "ip -6 route get mark xyz" ignores the mark passed in
by userspace. Make it honour the mark, just like IPv4 does.

Signed-off-by: Lorenzo Colitti <lorenzo@google.com>
---
 net/ipv6/route.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

David Miller May 16, 2014, 8:50 p.m. UTC | #1
From: Lorenzo Colitti <lorenzo@google.com>
Date: Thu, 15 May 2014 16:38:41 -0700

> Currently, "ip -6 route get mark xyz" ignores the mark passed in
> by userspace. Make it honour the mark, just like IPv4 does.
> 
> Signed-off-by: Lorenzo Colitti <lorenzo@google.com>

Applied, thanks for fixing this.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index f0a8ff9..8784d3a 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -2709,6 +2709,9 @@  static int inet6_rtm_getroute(struct sk_buff *in_skb, struct nlmsghdr* nlh)
 	if (tb[RTA_OIF])
 		oif = nla_get_u32(tb[RTA_OIF]);
 
+	if (tb[RTA_MARK])
+		fl6.flowi6_mark = nla_get_u32(tb[RTA_MARK]);
+
 	if (iif) {
 		struct net_device *dev;
 		int flags = 0;