[ovs-dev] effective user isolation

2013-05-29 Thread Vasiliy Tolstov
Hello. I have some nodes with virtual machines and want that each owner can view traffic from only owning virtual machines. For example: user1 have vm1_1 vm1_2 vm1_3 user2 have vm2_1 vm2_2 vm2_3 I want that user1 from vm1_1 and vm2_1 can view only traffic from this three servers and can't see vm2_

Re: [ovs-dev] [PATCH net-next v5 1/2] net: Use 16bits for *_headers fields of struct skbuff

2013-05-29 Thread Simon Horman
On Wed, May 29, 2013 at 04:02:12PM -0700, Olof Johansson wrote: > Hi, > > On Wed, May 29, 2013 at 3:54 PM, Simon Horman wrote: > > On Wed, May 29, 2013 at 02:46:05PM -0700, Olof Johansson wrote: > >> Sorry, that was not a great bug report. > >> > >> So, looks like it's the removal of NET_SKBUFF_D

Re: [ovs-dev] [PATCH v2 1/3] ovs-vswitchd: An option to wait for userspace > flow restore to complete. (Gurucharan Shetty)

2013-05-29 Thread Jing Ai
Date: Wed, 29 May 2013 13:46:05 -0700 Subject: Re: [ovs-dev] [PATCH v2 1/3] ovs-vswitchd: An option to wait for userspace > flow restore to complete. (Gurucharan Shetty) From: shet...@nicira.com To: ai_jing2...@hotmail.com CC: dev@openvswitch.org On Wed, May 29, 2013 at 1:23 PM, Jing Ai wrote:

[ovs-dev] [PATCH V2] ofproto-dpif.c: Modify vsp_realdev_to_vlandev() function

2013-05-29 Thread Alex Wang
This patch modifies the vsp_realdev_to_vlandev() function. Instead of taking and returning datapath port number, the new implementation takes and returns OpenFlow port number. Signed-off-by: Alex Wang --- ofproto/ofproto-dpif.c | 38 +- 1 file changed, 21 in

[ovs-dev] Bug#710125: Bug#710125: openvswitch: unable to compile kernel module with linux-3.8

2013-05-29 Thread Jesse Gross
On Tue, May 28, 2013 at 10:56 PM, Maciej Galkiewicz wrote: > Package: openvswitch > Version: 1.4.2+git20120612-9 > Severity: important > > # dkms install -m openvswitch -v 1.4.2+git20120612 -k 3.8-2-amd64 Open vSwitch 1.4 was released almost a year before Linux 3.8 so it is not surprising that th

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Modify vsp_realdev_to_vlandev() function

2013-05-29 Thread Alex Wang
Thanks Ben for the suggestion, I'll adjust accordingly. On Wed, May 29, 2013 at 4:58 PM, Ben Pfaff wrote: > On Wed, May 29, 2013 at 04:57:11PM -0700, Alex Wang wrote: > > This patch modifies the vsp_realdev_to_vlandev() function. Instead of > taking > > and returning datapath port number, the

Re: [ovs-dev] [xlate 1.11 9/9] ofproto-dpif: Revamp xlate_actions() interface.

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 02:24:41PM -0700, Ethan Jackson wrote: > This patch implements a new interface to xlate_actions which, aside > from being simpler and more intuitive, achieves several goals. It > pulls all of xlate_actions() results into a single structure which > will be easier to cache an

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Modify vsp_realdev_to_vlandev() function

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 04:57:11PM -0700, Alex Wang wrote: > This patch modifies the vsp_realdev_to_vlandev() function. Instead of taking > and returning datapath port number, the new implementation takes and returns > OpenFlow port number. > > Signed-off-by: Alex Wang This needs a re-spin again

Re: [ovs-dev] [PATCH v2 1/3] ovs-vswitchd: An option to wait for userspace flow restore to complete.

2013-05-29 Thread Ben Pfaff
On Tue, May 28, 2013 at 02:02:17PM +, Gurucharan Shetty wrote: > While upgrading openvswitch, it helps to restore openflow flows before > starting packet processing. Typically we want to restart openvswitch, > add the openflow flows and then start packet processing. > > To do this, we look fo

[ovs-dev] [PATCH] ofproto-dpif.c: Modify vsp_realdev_to_vlandev() function

2013-05-29 Thread Alex Wang
This patch modifies the vsp_realdev_to_vlandev() function. Instead of taking and returning datapath port number, the new implementation takes and returns OpenFlow port number. Signed-off-by: Alex Wang --- ofproto/ofproto-dpif.c | 34 +- 1 file changed, 17 insert

[ovs-dev] [PATCH] ofproto-dpif: Fix facet_lookup_valid().

2013-05-29 Thread Ethan Jackson
facet_lookup_valid() attempted to re-revalidate its facet after it had been removed. Found by inspection (by Justin). Reported-by: Justin Pettit Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c |5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ofproto/ofproto-dp

Re: [ovs-dev] [PATCH] ofproto-dpif: Don't count misses in OpenFlow table stats.

2013-05-29 Thread Jesse Gross
On Wed, May 29, 2013 at 6:20 AM, Ben Pfaff wrote: > On Fri, May 24, 2013 at 05:01:34PM -0700, Jesse Gross wrote: >> Originally no rule existed for packets that did not match an >> OpenFlow flow and therefore every packet with a rule could be >> counted as a hit. However, newer versions of OVS have

[ovs-dev] [PATCH] ofproto-dpif: Remove useless odp_in_port from subfacet.

2013-05-29 Thread Ethan Jackson
Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index 40be3c8..580044e 100644 --- a/ofproto/ofproto-dpif.c +++ b/ofproto/ofproto-dpif.c @@ -397,13 +397,6 @@ struct subfacet {

Re: [ovs-dev] [PATCH net-next v5 1/2] net: Use 16bits for *_headers fields of struct skbuff

2013-05-29 Thread Olof Johansson
Hi, On Wed, May 29, 2013 at 3:54 PM, Simon Horman wrote: > On Wed, May 29, 2013 at 02:46:05PM -0700, Olof Johansson wrote: >> Sorry, that was not a great bug report. >> >> So, looks like it's the removal of NET_SKBUFF_DATA_USES_OFFSET that >> does it for me. >> >> The devices I've seen it with ar

Re: [ovs-dev] [PATCH net-next v5 1/2] net: Use 16bits for *_headers fields of struct skbuff

2013-05-29 Thread Simon Horman
On Wed, May 29, 2013 at 02:46:05PM -0700, Olof Johansson wrote: > Sorry, that was not a great bug report. > > So, looks like it's the removal of NET_SKBUFF_DATA_USES_OFFSET that > does it for me. > > The devices I've seen it with are with asix usb-ethernet adapters (on > Tegra seaboard) and with

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Ethan Jackson
> I'm not sure how likely the function "vsp_realdev_to_vlandev()" will be > called with odp_port as argument in the future. I'll go with the "two > functions" implementation first. FWIW I suspect this is unlikely, and even if it wasn't. We can always change it in future when we have more informat

Re: [ovs-dev] [PATCH] ofproto-dpif: Consolidate facet stat logic.

2013-05-29 Thread Ethan Jackson
Btw, this version is based on master, and is ready for review. Thanks, Ethan On Wed, May 29, 2013 at 5:43 PM, Ethan Jackson wrote: > The logic for updating statistics at the facet level had been > spread through ofproto-dpif in a rather confusing manner. This > patch consolidates as much of thi

[ovs-dev] [PATCH] ofproto-dpif: Consolidate facet stat logic.

2013-05-29 Thread Ethan Jackson
The logic for updating statistics at the facet level had been spread through ofproto-dpif in a rather confusing manner. This patch consolidates as much of this logic as is reasonable into facet_push_stats(). On a side note, I'd expect this patch to have a marginal positive performance impact when

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Alex Wang
I saw you comment after sending the previous email. I'll have some time and consider both. And I'll resubmit the patch later. Thanks On Wed, May 29, 2013 at 3:37 PM, Alex Wang wrote: > Thanks Ben and Ethan, > > I'm okay with both ways. > > I'm not sure how likely the function "vsp_realdev_to_v

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Ben Pfaff
That would avoid an ofp->odp translation since compose_output_action__() already has the ofp_port. It's probably a good idea. Alex, do you want to do it that way? On Wed, May 29, 2013 at 05:25:09PM -0500, Ethan Jackson wrote: > I haven't looked at this patch carefully, so my next comment may or

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Alex Wang
Thanks Ben and Ethan, I'm okay with both ways. I'm not sure how likely the function "vsp_realdev_to_vlandev()" will be called with odp_port as argument in the future. I'll go with the "two functions" implementation first. Hope to hear more comments from you. Thanks On Wed, May 29, 2013 at 3:

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Ethan Jackson
I haven't looked at this patch carefully, so my next comment may or may not be worthwhile, but I'm wondering if it would be cleaner if we kept a single vsp_realdev_to_vlandev, which took an ofp_port as an argument, and then had compose_output_action__ pass in the openflow port number instead of the

Re: [ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 03:01:43PM -0700, Alex Wang wrote: > In ofproto-dpif.c, function vsp_realdev_to_vlandev() is called with both > OpenFlow port and datapath port number as argument. This patch replaces > the function vsp_realdev_to_vlandev() with vsp_ofp_realdev_to_vlandev() and > vsp_odp_rea

Re: [ovs-dev] [PATCH] ofproto/pktbuf.c: Fix a typo in the comment

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 01:57:22PM -0700, Alex Wang wrote: > This patch fixes a typo in the comment of the pktbuf_retrieve() function. > > Signed-off-by: Alex Wang Looks good, thanks. ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mail

Re: [ovs-dev] [PATCH net-next v5 1/2] net: Use 16bits for *_headers fields of struct skbuff

2013-05-29 Thread Olof Johansson
Sorry, that was not a great bug report. So, looks like it's the removal of NET_SKBUFF_DATA_USES_OFFSET that does it for me. The devices I've seen it with are with asix usb-ethernet adapters (on Tegra seaboard) and with mv643xx_eth on cubox (dove). I'll try to get a better stacktrace out of it. S

[ovs-dev] [PATCH] ofproto-dpif.c: Replace vsp_realdev_to_vlandev() with two new functions

2013-05-29 Thread Alex Wang
In ofproto-dpif.c, function vsp_realdev_to_vlandev() is called with both OpenFlow port and datapath port number as argument. This patch replaces the function vsp_realdev_to_vlandev() with vsp_ofp_realdev_to_vlandev() and vsp_odp_realdev_to_vlandev(), which take OpenFlow port number and datapth port

[ovs-dev] [xlate 1.11 4/9] ofproto-dpif: Ditch SLOW_MATCH slow path reason.

2013-05-29 Thread Ethan Jackson
Before this patch, datapath keys with ODP_FIT_TO_LITTLE, would be assigned subfacets and installed in the kernel with a SLOW_MATCH slow path reason. This is problematic, because these flow keys can't be reliable converted into a 'struct flow' thus breaking a fundamental assumption of ofproto-dpif.

[ovs-dev] [xlate 1.11 5/9] ofproto: Ditch SLOW_IN_BAND slow path reason.

2013-05-29 Thread Ethan Jackson
Before this patch, when in band control was enabled, every DHCP packet had to be sent to userspace to calculate it's actions. Those DHCP packets intended for the local port would have a special action added to ensure they actually make it there. This unnecessarily complicates the code, so this pat

[ovs-dev] [xlate 1.11 8/9] ofproto-dpif: Rename action_xlate_ctx.

2013-05-29 Thread Ethan Jackson
This patch changes the name of action_xlate_ctx to xlate_ctx. Aside from being a bit snappier, it fits more cleanly with structures added in future patches. Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c | 183 1 file changed, 90 inserti

[ovs-dev] [xlate 1.11 3/9] ofpbuf: New helper ofpbuf_equal().

2013-05-29 Thread Ethan Jackson
Used in future commits. Signed-off-by: Ethan Jackson --- lib/ofpbuf.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/lib/ofpbuf.h b/lib/ofpbuf.h index 8b03c7e..0c12162 100644 --- a/lib/ofpbuf.h +++ b/lib/ofpbuf.h @@ -107,6 +107,12 @@ static inline struct ofpbuf *ofpbuf_from_list(co

[ovs-dev] [xlate 1.11 2/9] ofproto-dpif: Avoid redundant facet_find() in facet_lookup_valid().

2013-05-29 Thread Ethan Jackson
Suggested-by: Ben Pfaff Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index e0c88a8..3a1484e 100644 --- a/ofproto/ofproto-dpif.c +++ b/ofproto/ofpro

[ovs-dev] [xlate 1.11 7/9] ofproto-dpif: Move odp_actions from subfacet to facet.

2013-05-29 Thread Ethan Jackson
Upon close inspection, it appears that it's not possible for actions to differ between subfacets belonging to a given facet. Given this fact, it makes sense to move datapath actions from subfacets to their parent facets. It's both conceptually more straightforward, and necessary for future threadi

[ovs-dev] [xlate 1.11 6/9] odp-util: Make slow_path_reasons mutually exclusive.

2013-05-29 Thread Ethan Jackson
It's no longer possible for a single datapath flow to be slow pathed for two different reasons. This patch updates the code to reflect this fact (marginally simplifying it). Signed-off-by: Ethan Jackson --- lib/odp-util.c | 53 +++- lib/odp-

[ovs-dev] [xlate 1.11 1/9] ofproto-dpif: handle_flow_miss_common() without facets.

2013-05-29 Thread Ethan Jackson
handle_flow_miss_common() is intended to be called whether or not a miss needs a facet. Found by inspection. Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index f74cfcb..e0c88a8 10

[ovs-dev] [xlate 1.11 0/9] xlate series to branch-1.11

2013-05-29 Thread Ethan Jackson
This is the backport of the recently merged xlate series to branch-1.11. I'm sending it out to the list as a backport of this size is slightly unusual, and therefore deserves some explanation. Because of a potentially large performance benefit, we're planning to backport userspace megaflows to 1.

Re: [ovs-dev] [PATCH net-next v5 1/2] net: Use 16bits for *_headers fields of struct skbuff

2013-05-29 Thread Olof Johansson
Simon, On Thu, May 23, 2013 at 11:51 PM, Simon Horman wrote: > In order to mitigate ongoing incresase in the size of struct skbuff > use 16 bit integer offsets rather than pointers for inner_*_headers. > > This appears to reduce the size of struct skbuff from 0xd0 to 0xc0 > bytes on x86_64 with t

Re: [ovs-dev] [PATCH] debian: Don't fail ovs-controller restart if daemon not running.

2013-05-29 Thread Gurucharan Shetty
On Wed, May 29, 2013 at 12:00 PM, Ben Pfaff wrote: > On Tue, May 28, 2013 at 05:24:16PM -0700, Gurucharan Shetty wrote: > > Reported-by: Maxime Brun > > Signed-off-by: Gurucharan Shetty > > Looks good, thanks. > > Thank you. I pushed this to master, 1.11, 1.10 and 1.9. I thought we had convert

Re: [ovs-dev] [PATCH v2 1/3] ovs-vswitchd: An option to wait for userspace > flow restore to complete. (Gurucharan Shetty)

2013-05-29 Thread Gurucharan Shetty
On Wed, May 29, 2013 at 1:23 PM, Jing Ai wrote: > > While upgrading openvswitch, it helps to restore openflow flows before > > starting packet processing. Typically we want to restart openvswitch, > > add the openflow flows and then start packet processing. > > > > To do this, we look for the oth

[ovs-dev] [PATCH] ofproto/pktbuf.c: Fix a typo in the comment

2013-05-29 Thread Alex Wang
This patch fixes a typo in the comment of the pktbuf_retrieve() function. Signed-off-by: Alex Wang --- ofproto/pktbuf.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ofproto/pktbuf.c b/ofproto/pktbuf.c index 902b19d..2ec1f0d 100644 --- a/ofproto/pktbuf.c +++ b/ofproto/pk

Re: [ovs-dev] [xlate v3 8/8] ofproto-dpif: Revamp xlate_actions() interface.

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 01:22:00PM -0700, Ethan Jackson wrote: > This incremental (applied on v3) should address your comments on the > v2 version of the patch. I consider this series reviewed at this > point, unless there's something you'd like to make additional comments > on. No, I'm happy, th

Re: [ovs-dev] [PATCH v11 2/6] Add set skb_mark, set_priority and tunnel support to execute_set_action

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 03:06:39PM +0900, Simon Horman wrote: > Add set skb_mark support to execute_set_action. Now renamed odp_execute_actions(). > This also adds support for the user-space datapath > to honour such actions if they occur before recirculation, > which will be added by a subsequen

Re: [ovs-dev] [PATCH v2 1/3] ovs-vswitchd: An option to wait for userspace > flow restore to complete. (Gurucharan Shetty)

2013-05-29 Thread Jing Ai
> While upgrading openvswitch, it helps to restore openflow flows before > starting packet processing. Typically we want to restart openvswitch, > add the openflow flows and then start packet processing. > > To do this, we look for the other_config:flow-restore-wait column > in the Open_vSwitch t

Re: [ovs-dev] [xlate v3 8/8] ofproto-dpif: Revamp xlate_actions() interface.

2013-05-29 Thread Ethan Jackson
This incremental (applied on v3) should address your comments on the v2 version of the patch. I consider this series reviewed at this point, unless there's something you'd like to make additional comments on. Ethan --- ofproto/ofproto-dpif.c | 43 +++ 1

Re: [ovs-dev] [PATCH] ofproto-dpif: handle_flow_miss_common() without > facets. (Ethan Jackson)

2013-05-29 Thread Jing Ai
> Message: 3 > Date: Wed, 29 May 2013 10:21:28 -0700 > From: Ethan Jackson > Subject: [ovs-dev] [PATCH] ofproto-dpif: handle_flow_miss_common() > without facets. > To: dev@openvswitch.org > Message-ID: <1369848088-47098-1-git-send-email-et...@nicira.com> > > handle_flow_miss_common() is in

Re: [ovs-dev] [PATCH v11 1/6] Add execute_actions

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 03:06:38PM +0900, Simon Horman wrote: > This moves generic action execution code out of lib/dpif-netedev.c > and into a new file, lib/execute-actions.c. > > This is in preparation for using execute_set_action() > in lib/odp-util.c to handle recirculation/ > > Signed-off-by

Re: [ovs-dev] [PATCH] ofproto-dpif: handle_flow_miss_common() without facets.

2013-05-29 Thread Ethan Jackson
Probably. I need to backport the xlate series as well. I'll do it all in one go when I merge that. On Wed, May 29, 2013 at 2:02 PM, Ben Pfaff wrote: > On Wed, May 29, 2013 at 10:21:28AM -0700, Ethan Jackson wrote: >> handle_flow_miss_common() is intended to be called whether or not a >> miss ne

Re: [ovs-dev] [PATCH] ofproto-dpif: Consolidate facet stat logic.

2013-05-29 Thread Ben Pfaff
OK, thanks. On Wed, May 29, 2013 at 02:41:55PM -0500, Ethan Jackson wrote: > Oops, this patch ends up deleteing, xlate_actions_for_side_effects(), > but then I need it again in the xlate series. I think instead of > basing this on master, I'll base it on the xlate series once it's > merged. May

Re: [ovs-dev] [PATCH] ofproto-dpif: Consolidate facet stat logic.

2013-05-29 Thread Ethan Jackson
Oops, this patch ends up deleteing, xlate_actions_for_side_effects(), but then I need it again in the xlate series. I think instead of basing this on master, I'll base it on the xlate series once it's merged. May as well hold off reviewing it until then. Ethan On Wed, May 29, 2013 at 2:38 PM, E

[ovs-dev] [PATCH] ofproto-dpif: Consolidate facet stat logic.

2013-05-29 Thread Ethan Jackson
The logic for updating statistics at the facet level had been spread through ofproto-dpif in a rather confusing manner. This patch consolidates as much of this logic as is reasonable into facet_push_stats(). On a side note, I'd expect this patch to have a marginal positive performance impact when

Re: [ovs-dev] [PATCH] ofproto-dpif: handle_flow_miss_common() without facets.

2013-05-29 Thread Ben Pfaff
On Wed, May 29, 2013 at 10:21:28AM -0700, Ethan Jackson wrote: > handle_flow_miss_common() is intended to be called whether or not a > miss needs a facet. Found by inspection. > > Signed-off-by: Ethan Jackson Looks good, thanks. Is it worth a backport? _

Re: [ovs-dev] [PATCH] debian: Don't fail ovs-controller restart if daemon not running.

2013-05-29 Thread Ben Pfaff
On Tue, May 28, 2013 at 05:24:16PM -0700, Gurucharan Shetty wrote: > Reported-by: Maxime Brun > Signed-off-by: Gurucharan Shetty Looks good, thanks. I thought we had converted all this stuff to use ovs-lib.sh, but I guess not. ___ dev mailing list dev

Re: [ovs-dev] [PATCH] openvswitch: use -EEXIST as return error to be more precise

2013-05-29 Thread Jesse Gross
On Tue, May 28, 2013 at 3:31 PM, Fan Du wrote: > ovs_vport_cmd_new create a new vport with port num specified by user. > when this port num is already occupied, it's more clear to return > -EEXIST as the reason than -EBUSY. > > Signed-off-by: Fan Du This error code is part of the userspace ABI s

[ovs-dev] [PATCH] ofproto-dpif: handle_flow_miss_common() without facets.

2013-05-29 Thread Ethan Jackson
handle_flow_miss_common() is intended to be called whether or not a miss needs a facet. Found by inspection. Signed-off-by: Ethan Jackson --- ofproto/ofproto-dpif.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index b547298..ae59eda 10

[ovs-dev] OpenvSwitch version for Ubuntu Saucy + Kernel 3.9/3.10

2013-05-29 Thread James Page
Hi OpenvSwitch Devs Ubuntu Saucy development has been open for a while and the Ubuntu kernel team are currently targeting either Linux 3.9 or 3.10 for this release. Currently the 1.9.0 DKMS source is unhappy with 3.9 - I've hacked on it for a bit and although it definitely possible to backpor