diff -ruNpb iproute2-2.6.9/ip/iplink.c iproute2-2.6.9-new/ip/iplink.c --- iproute2-2.6.9/ip/iplink.c 2004-08-31 13:32:14.000000000 -0500 +++ iproute2-2.6.9-new/ip/iplink.c 2009-09-04 03:43:18.000000000 -0500 @@ -31,6 +31,7 @@ #include "utils.h" #include "ip_common.h" +#include static void usage(void) __attribute__((noreturn)); @@ -358,6 +359,7 @@ static int do_set(int argc, char **argv) usage(); if (dev) duparg2("dev", *argv); + netdev_pathname_to_name(*argv); dev = *argv; } argc--; argv++; diff -ruNpb iproute2-2.6.9/ip/ipmaddr.c iproute2-2.6.9-new/ip/ipmaddr.c --- iproute2-2.6.9/ip/ipmaddr.c 2004-08-31 13:32:14.000000000 -0500 +++ iproute2-2.6.9-new/ip/ipmaddr.c 2009-09-04 04:11:34.000000000 -0500 @@ -21,6 +21,7 @@ #include #include +#include #include #include #include @@ -257,6 +258,7 @@ static int multiaddr_list(int argc, char usage(); if (filter.dev) duparg2("dev", *argv); + netdev_pathname_to_name(*argv); filter.dev = *argv; } argv++; argc--; @@ -290,6 +292,7 @@ int multiaddr_modify(int cmd, int argc, if (ifr.ifr_name[0]) duparg("dev", *argv); strncpy(ifr.ifr_name, *argv, IFNAMSIZ); + netdev_pathname_to_name(ifr.ifr_name); } else { if (matches(*argv, "address") == 0) { NEXT_ARG(); diff -ruNpb iproute2-2.6.9/lib/ll_map.c iproute2-2.6.9-new/lib/ll_map.c --- iproute2-2.6.9/lib/ll_map.c 2004-08-31 13:32:14.000000000 -0500 +++ iproute2-2.6.9-new/lib/ll_map.c 2009-09-04 04:08:20.000000000 -0500 @@ -18,6 +18,7 @@ #include #include #include +#include #include "libnetlink.h" #include "ll_map.h" @@ -140,6 +141,7 @@ int ll_name_to_index(const char *name) if (name == NULL) return 0; + netdev_pathname_to_name(name); if (icache && strcmp(name, ncache) == 0) return icache; for (i=0; i<16; i++) { diff -ruNpb iproute2-2.6.9/Makefile iproute2-2.6.9-new/Makefile --- iproute2-2.6.9/Makefile 2009-08-20 00:39:04.000000000 -0500 +++ iproute2-2.6.9-new/Makefile 2009-08-14 08:58:29.000000000 -0500 @@ -24,7 +24,7 @@ CC = gcc CCOPTS = -D_GNU_SOURCE -O2 -Wstrict-prototypes -Wall -g CFLAGS = $(CCOPTS) -I../include $(DEFINES) -LDLIBS += -L../lib -lnetlink -lutil +LDLIBS += -L../lib -lnetlink -lutil -lnetdevname SUBDIRS=lib ip tc misc diff -ruNpb iproute2-2.6.9/tc/f_fw.c iproute2-2.6.9-new/tc/f_fw.c --- iproute2-2.6.9/tc/f_fw.c 2009-08-20 00:39:04.000000000 -0500 +++ iproute2-2.6.9-new/tc/f_fw.c 2009-09-04 03:46:26.000000000 -0500 @@ -18,6 +18,7 @@ #include #include #include +#include #include #include /* IFNAMSIZ */ #include "utils.h" @@ -86,6 +87,7 @@ static int fw_parse_opt(struct filter_ut fprintf(stderr, "Illegal indev\n"); return -1; } + netdev_pathname_to_name(*argv); strncpy(d, *argv, sizeof (d) - 1); addattr_l(n, MAX_MSG, TCA_FW_INDEV, d, strlen(d) + 1); } else if (strcmp(*argv, "help") == 0) {