Merge branch 'master' into net-next
This commit is contained in:
commit
e9155685b7
|
|
@ -19,6 +19,11 @@ ifeq ($(IP_CONFIG_SETNS),y)
|
||||||
CFLAGS += -DHAVE_SETNS
|
CFLAGS += -DHAVE_SETNS
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(HAVE_MNL),y)
|
||||||
|
CFLAGS += -DHAVE_LIBMNL $(shell $(PKG_CONFIG) libmnl --cflags)
|
||||||
|
LDLIBS += $(shell $(PKG_CONFIG) libmnl --libs)
|
||||||
|
endif
|
||||||
|
|
||||||
ALLOBJ=$(IPOBJ) $(RTMONOBJ)
|
ALLOBJ=$(IPOBJ) $(RTMONOBJ)
|
||||||
SCRIPTS=ifcfg rtpr routel routef
|
SCRIPTS=ifcfg rtpr routel routef
|
||||||
TARGETS=ip rtmon
|
TARGETS=ip rtmon
|
||||||
|
|
|
||||||
|
|
@ -59,8 +59,8 @@ static int vti6_parse_opt(struct link_util *lu, int argc, char **argv,
|
||||||
struct rtattr *tb[IFLA_MAX + 1];
|
struct rtattr *tb[IFLA_MAX + 1];
|
||||||
struct rtattr *linkinfo[IFLA_INFO_MAX+1];
|
struct rtattr *linkinfo[IFLA_INFO_MAX+1];
|
||||||
struct rtattr *vtiinfo[IFLA_VTI_MAX + 1];
|
struct rtattr *vtiinfo[IFLA_VTI_MAX + 1];
|
||||||
struct in6_addr saddr;
|
struct in6_addr saddr = IN6ADDR_ANY_INIT;
|
||||||
struct in6_addr daddr;
|
struct in6_addr daddr = IN6ADDR_ANY_INIT;
|
||||||
unsigned int ikey = 0;
|
unsigned int ikey = 0;
|
||||||
unsigned int okey = 0;
|
unsigned int okey = 0;
|
||||||
unsigned int link = 0;
|
unsigned int link = 0;
|
||||||
|
|
@ -195,8 +195,11 @@ get_failed:
|
||||||
|
|
||||||
addattr32(n, 1024, IFLA_VTI_IKEY, ikey);
|
addattr32(n, 1024, IFLA_VTI_IKEY, ikey);
|
||||||
addattr32(n, 1024, IFLA_VTI_OKEY, okey);
|
addattr32(n, 1024, IFLA_VTI_OKEY, okey);
|
||||||
addattr_l(n, 1024, IFLA_VTI_LOCAL, &saddr, sizeof(saddr));
|
|
||||||
addattr_l(n, 1024, IFLA_VTI_REMOTE, &daddr, sizeof(daddr));
|
if (memcmp(&saddr, &in6addr_any, sizeof(in6addr_any)))
|
||||||
|
addattr_l(n, 1024, IFLA_VTI_LOCAL, &saddr, sizeof(saddr));
|
||||||
|
if (memcmp(&daddr, &in6addr_any, sizeof(in6addr_any)))
|
||||||
|
addattr_l(n, 1024, IFLA_VTI_REMOTE, &daddr, sizeof(daddr));
|
||||||
addattr32(n, 1024, IFLA_VTI_FWMARK, fwmark);
|
addattr32(n, 1024, IFLA_VTI_FWMARK, fwmark);
|
||||||
if (link)
|
if (link)
|
||||||
addattr32(n, 1024, IFLA_VTI_LINK, link);
|
addattr32(n, 1024, IFLA_VTI_LINK, link);
|
||||||
|
|
|
||||||
|
|
@ -102,6 +102,11 @@ endif
|
||||||
TCOBJ += $(TCMODULES)
|
TCOBJ += $(TCMODULES)
|
||||||
LDLIBS += -L. -lm
|
LDLIBS += -L. -lm
|
||||||
|
|
||||||
|
ifeq ($(HAVE_MNL),y)
|
||||||
|
CFLAGS += -DHAVE_LIBMNL $(shell $(PKG_CONFIG) libmnl --cflags)
|
||||||
|
LDLIBS += $(shell $(PKG_CONFIG) libmnl --libs)
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(SHARED_LIBS),y)
|
ifeq ($(SHARED_LIBS),y)
|
||||||
LDLIBS += -ldl
|
LDLIBS += -ldl
|
||||||
LDFLAGS += -Wl,-export-dynamic
|
LDFLAGS += -Wl,-export-dynamic
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue