* [PATCH] ip xfrm state: Allow different selector family
@ 2013-03-17 10:56 Thomas Egerer
2013-03-20 9:18 ` Thomas Egerer
0 siblings, 1 reply; 2+ messages in thread
From: Thomas Egerer @ 2013-03-17 10:56 UTC (permalink / raw)
To: netdev; +Cc: stephen.hemminger
[-- Attachment #1: Type: text/plain, Size: 272 bytes --]
Do not enforce the selector of a state to have the same address family
as the id. This makes it possible to configure inter family states.
Signed-off-by: Thomas Egerer <hakke_007@gmx.de>
---
ip/xfrm_state.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
[-- Attachment #2: 0001-ip-xfrm-state-Allow-different-selector-family.patch --]
[-- Type: text/x-patch, Size: 588 bytes --]
diff --git a/ip/xfrm_state.c b/ip/xfrm_state.c
index 8ac3437..aec49d6 100644
--- a/ip/xfrm_state.c
+++ b/ip/xfrm_state.c
@@ -300,7 +300,9 @@ static int xfrm_state_modify(int cmd, unsigned flags, int argc, char **argv)
xfrm_state_flag_parse(&req.xsinfo.flags, &argc, &argv);
} else if (strcmp(*argv, "sel") == 0) {
NEXT_ARG();
+ preferred_family = AF_UNSPEC;
xfrm_selector_parse(&req.xsinfo.sel, &argc, &argv);
+ preferred_family = req.xsinfo.sel;
} else if (strcmp(*argv, "limit") == 0) {
NEXT_ARG();
xfrm_lifetime_cfg_parse(&req.xsinfo.lft, &argc, &argv);
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ip xfrm state: Allow different selector family
2013-03-17 10:56 [PATCH] ip xfrm state: Allow different selector family Thomas Egerer
@ 2013-03-20 9:18 ` Thomas Egerer
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Egerer @ 2013-03-20 9:18 UTC (permalink / raw)
To: netdev; +Cc: stephen.hemminger
My previous commit introduced a patch to allow for states with different
ip address families for selector and id. The must have somehow been a
mixup of the patch I tested and the one I send, so the patch sent breaks
the iproute2 build. This patch fixes this. My apologies.
Signed-off-by: Thomas Egerer <hakke_007@gmx.de>
---
Hi Stephen, *,
my sincere apologies for breaking the build. But I somehow build and tested
one commit and sent the wrong one to the list. The assignment was wrong.
This commit fixes this bug. My bad,
Thomas
ip/xfrm_state.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
0001-ip-xfrm-state-Fix-assignment-of-preferred_family.patch
diff --git a/ip/xfrm_state.c b/ip/xfrm_state.c
index 6ff5b51..c0cf88c 100644
--- a/ip/xfrm_state.c
+++ b/ip/xfrm_state.c
@@ -296,7 +296,7 @@ static int xfrm_state_modify(int cmd, unsigned flags, int argc, char **argv)
NEXT_ARG();
preferred_family = AF_UNSPEC;
xfrm_selector_parse(&req.xsinfo.sel, &argc, &argv);
- preferred_family = req.xsinfo.sel;
+ preferred_family = req.xsinfo.sel.family;
} else if (strcmp(*argv, "limit") == 0) {
NEXT_ARG();
xfrm_lifetime_cfg_parse(&req.xsinfo.lft, &argc, &argv);
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-03-20 9:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-17 10:56 [PATCH] ip xfrm state: Allow different selector family Thomas Egerer
2013-03-20 9:18 ` Thomas Egerer
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.