[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-id: <1274451009-29456-1-git-send-email-hannemann@nets.rwth-aachen.de>
Date: Fri, 21 May 2010 16:10:09 +0200
From: Arnd Hannemann <hannemann@...s.rwth-aachen.de>
To: shemminger@...l.org
Cc: netdev@...r.kernel.org,
Arnd Hannemann <hannemann@...s.rwth-aachen.de>
Subject: [PATCH] iproute2: Add dsfield as alias for tos for ip rules
From: Arnd Hannemann <arnd@...a.(none)>
Get ip rule parsing of "dsfield" in sync with ip route parsing and manual page.
Signed-off-by: Arnd Hannemann <hannemann@...s.rwth-aachen.de>
---
ip/iprule.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/ip/iprule.c b/ip/iprule.c
index 7140375..cbf8226 100644
--- a/ip/iprule.c
+++ b/ip/iprule.c
@@ -270,7 +270,8 @@ static int iprule_modify(int cmd, int argc, char **argv)
if (get_u32(&pref, *argv, 0))
invarg("preference value is invalid\n", *argv);
addattr32(&req.n, sizeof(req), FRA_PRIORITY, pref);
- } else if (strcmp(*argv, "tos") == 0) {
+ } else if (strcmp(*argv, "tos") == 0 ||
+ matches(*argv, "dsfield") == 0) {
__u32 tos;
NEXT_ARG();
if (rtnl_dsfield_a2n(&tos, *argv))
--
1.7.0.4
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists