Re: [ovs-dev] [PATCH 1/5] lib/ofp-actions: use mf_subvalue in struct ofpact_reg_load.

2012-09-12 Thread Simon Horman
On Tue, Sep 11, 2012 at 10:37:48PM -0700, Ben Pfaff wrote: > On Tue, Sep 11, 2012 at 01:30:04PM +0900, Simon Horman wrote: > > From: Isaku Yamahata > > > > Use a uninion mf_subvalue instead of a uint64_t for > > the value member of struct ofpact_reg_load. > > > > set_field action needs to hold v

[ovs-dev] [PATCH v5 0/5] set-field action preliminary support

2012-09-12 Thread Simon Horman
Hi, This series adds preliminary support for set-field actions. I have picked up this series from Yamahata-san on his request. It is based on the current master branch. Changes for each patch are noted inline. I believe this series addresses raised by Ben Pfaff in respect to v4 of this series. A

[ovs-dev] [PATCH 2/5] lib/ofp-actions: helper functions for of12 set-field action

2012-09-12 Thread Simon Horman
From: Isaku Yamahata Signed-off-by: Isaku Yamahata Signed-off-by: Simon Horman --- v5 [Simon Horman] * Do not add mf_check_dst_oxm(), just use mf_check_dst(). v4 [Simon Horman] * Remove utilities/ovs-ofctl.c hunk, introduced in v3, which belongs in a different patch * Make use of new oxm_w

[ovs-dev] [PATCH 1/5] lib/ofp-actions: use mf_subvalue in struct ofpact_reg_load.

2012-09-12 Thread Simon Horman
From: Isaku Yamahata Use a uninion mf_subvalue instead of a uint64_t for the value member of struct ofpact_reg_load. set_field action needs to hold values wider than 64 bits. This is preparation for set_field action. Signed-off-by: Isaku Yamahata Signed-off-by: Simon Horman --- v5 [Simon Ho

[ovs-dev] [PATCH 5/5] [RFC] ofp-actions: Check pre-requisists of set-field actions

2012-09-12 Thread Simon Horman
By passing a flow to the action parser the pre-requisites of set-feild actions will be checked. If the flow is NULL, for instance in test code such as ofctl_parse_ofp11_instructions(), then the check is skiped, as it always was before this change. Unfortunately I don't think that this check is cor

[ovs-dev] [PATCH 3/5] ofp-actions: plumb of12 actions support

2012-09-12 Thread Simon Horman
From: Isaku Yamahata Signed-off-by: Isaku Yamahata Signed-off-by: Simon Horman --- v5 [Simon Horman] * No change v4 [Simon Horman] * Update call to ofpacts_pull_openflow11_instructions() in ofctl_parse_ofp11_instructions() to include new ofp_version argument * Add a special case for OFPAT1

[ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Simon Horman
From: Isaku Yamahata Signed-off-by: Isaku Yamahata Signed-off-by: Simon Horman --- v5 [Simon Horman] * No change v4 [Simon Horman] * Manual Rebase * Add a limited number of tests v3 [Simon Horman] * Manual Rebase - Add ofpacts_put_openflow12_instructions() and ofpacts_put_openflow11_a

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Reid Price
One note inline On Sep 11, 2555 BE, at 23:17, Isaku Yamahata wrote: > Since Transaction._substitute doesn't substitute elements of list/tuple, > setting list references results in transaction error. Teach it such case. > > Example: > {"op": "update", > "row":{"bridges":["set",[["uuid", >

Re: [ovs-dev] [PATCH 3/5] python/ovs/db/idl: make SchemaHelper accept schema in json form

2012-09-12 Thread Reid Price
Contextless phone review here also. Perhaps raise a value error if location and schema are both provided? Isaku/Ben, are there any side effects of keeping this data in memory before it is used, and removing entirely it after the 'schema =' line? Before it loaded it on demand. Isn't necessarily

Re: [ovs-dev] NVGRE tunnel

2012-09-12 Thread Jesse Gross
On Tue, Sep 11, 2012 at 9:11 PM, Saleha Asad wrote: > > Yes the standard is not completely defined yet but Microsoft server 2012 > has this protocol implemented and they are using the following commands to > allot VSIDs to the packet: > > New-NetVirtualizationLookupRecord -VirtualSubnetID “5001″

Re: [ovs-dev] [PATCH 5/5] python/ovs/db/idl: getattr(Row) raises TypeError, not AttributeError.

2012-09-12 Thread Reid Price
Patches 1/5, 2/5, 5/5 look fine to me. On Sep 11, 2555 BE, at 23:17, Isaku Yamahata wrote: > In some cases getattr(Row instance, attrname) doesn't raise AttributeError, > but TypeError > >> File "python/ovs/db/idl.py", line 554, in __getattr__ >>datum = self._data[column_name] >> TypeError:

Re: [ovs-dev] [PATCH 1/5] lib/ofp-actions: use mf_subvalue in struct ofpact_reg_load.

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 05:44:28PM +0900, Simon Horman wrote: > From: Isaku Yamahata > > Use a uninion mf_subvalue instead of a uint64_t for > the value member of struct ofpact_reg_load. > > set_field action needs to hold values wider than 64 bits. > This is preparation for set_field action. >

Re: [ovs-dev] [PATCH 2/5] lib/ofp-actions: helper functions for of12 set-field action

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 05:44:29PM +0900, Simon Horman wrote: > +enum ofperr > +nxm_reg_load_from_openflow12_set_field( > +const struct ofp12_action_set_field * oasf, struct ofpbuf *ofpacts) > +{ > +uint16_t oasf_len = ntohs(oasf->len); > +ovs_be32 *p = (ovs_be32*)oasf->field; > +ui

[ovs-dev] [PATCH] ofp-actions: Right-justify the value in ofpact_reg_load 'subvalue' member.

2012-09-12 Thread Ben Pfaff
This is what I intended when I suggested using mf_subvalue, but I didn't notice the difference until after applying the patch. Signed-off-by: Ben Pfaff --- lib/learn.c |4 +++- lib/meta-flow.c |2 +- lib/nx-match.c| 25 + lib/ofp-actions.h |2 +-

Re: [ovs-dev] [PATCH 2/5] python/ovs/db/idl: counter part of ovsdb_idl_add_table() to SchemaHelper

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 03:17:22PM +0900, Isaku Yamahata wrote: > add register_table method to SchemaHelper as counter part of > ovsdb_idl_add_table(). > > Signed-off-by: Isaku Yamahata This seems like a good idea, but would you mind adding a doc comment and updating comments on other functions

Re: [ovs-dev] [PATCH 1/5] python/ovs: socket_util uses select.poll

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 03:17:21PM +0900, Isaku Yamahata wrote: > The changeset of ed815d9bd28422a490fe370d7804d24bcd676806 eliminated > the use of select.poll for eventlet/gevent. > It forgot to select.poll in socket_util. > > Signed-off-by: Isaku Yamahata Applied to master, thanks! ___

Re: [ovs-dev] [PATCH 3/5] python/ovs/db/idl: make SchemaHelper accept schema in json form

2012-09-12 Thread Ben Pfaff
I agree about raising an error if both are provided. There doesn't seem to be an issue with reading the file earlier. It won't bother any in-tree users anyhow. On Wed, Sep 12, 2012 at 08:41:55AM -0700, Reid Price wrote: > Contextless phone review here also. > > Perhaps raise a value error if lo

Re: [ovs-dev] [PATCH 5/5] python/ovs/db/idl: getattr(Row) raises TypeError, not AttributeError.

2012-09-12 Thread Ben Pfaff
Thanks as always for the reviews, Reid! On Wed, Sep 12, 2012 at 08:49:49AM -0700, Reid Price wrote: > Patches 1/5, 2/5, 5/5 look fine to me. > > On Sep 11, 2555 BE, at 23:17, Isaku Yamahata wrote: > > > In some cases getattr(Row instance, attrname) doesn't raise AttributeError, > > but TypeErro

Re: [ovs-dev] [PATCH 3/5] ofp-actions: plumb of12 actions support

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 05:44:30PM +0900, Simon Horman wrote: > From: Isaku Yamahata > > Signed-off-by: Isaku Yamahata > Signed-off-by: Simon Horman This seems reasonable once the issues in patch 2 are cleaned up. Thanks, Ben. ___ dev mailing list

Re: [ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 05:44:31PM +0900, Simon Horman wrote: > From: Isaku Yamahata > > Signed-off-by: Isaku Yamahata > Signed-off-by: Simon Horman I think that, if I'm reading this right, then attempting to convert many actions to OF1.2 will cause an assertion failure. We need to do somethi

Re: [ovs-dev] [PATCH 5/5] [RFC] ofp-actions: Check pre-requisists of set-field actions

2012-09-12 Thread Ben Pfaff
On Wed, Sep 12, 2012 at 05:44:32PM +0900, Simon Horman wrote: > By passing a flow to the action parser the pre-requisites > of set-feild actions will be checked. If the flow is NULL, > for instance in test code such as ofctl_parse_ofp11_instructions(), > then the check is skiped, as it always was b

[ovs-dev] Hotel 4* en Málaga + Museo Thyssen por 61¤ / Pinza depilatoria con luz por 5, 67¤ / Faja reductora al 63%

2012-09-12 Thread GlobalBono
Cabestan. Layout Simple Asegúrate de no perderte ninguna oferta, añade ofer...@globalbono.com a tu lista de contactos. Si no ves correctamente las imágenes, pulsa [ http://email.globalbono.com/E12092012134620.cfm?WL=1293&WS=208833_8707685&WA=610 ] aquí [ http://email.globalbono.com/Go/index.c

Re: [ovs-dev] [PATCH] ofp-actions: Right-justify the value in ofpact_reg_load 'subvalue' member.

2012-09-12 Thread Simon Horman
On Wed, Sep 12, 2012 at 11:37:53AM -0700, Ben Pfaff wrote: > This is what I intended when I suggested using mf_subvalue, but I didn't > notice the difference until after applying the patch. > > Signed-off-by: Ben Pfaff Acked-by: Simon Horman ___ dev

Re: [ovs-dev] [PATCH 2/5] lib/ofp-actions: helper functions for of12 set-field action

2012-09-12 Thread Simon Horman
On Wed, Sep 12, 2012 at 11:13:49AM -0700, Ben Pfaff wrote: > On Wed, Sep 12, 2012 at 05:44:29PM +0900, Simon Horman wrote: > > +enum ofperr > > +nxm_reg_load_from_openflow12_set_field( > > +const struct ofp12_action_set_field * oasf, struct ofpbuf *ofpacts) > > +{ > > +uint16_t oasf_len = n

Re: [ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Simon Horman
On Wed, Sep 12, 2012 at 12:06:50PM -0700, Ben Pfaff wrote: > On Wed, Sep 12, 2012 at 05:44:31PM +0900, Simon Horman wrote: > > From: Isaku Yamahata > > > > Signed-off-by: Isaku Yamahata > > Signed-off-by: Simon Horman > > I think that, if I'm reading this right, then attempting to convert > ma

Re: [ovs-dev] [PATCH 2/5] python/ovs/db/idl: counter part of ovsdb_idl_add_table() to SchemaHelper

2012-09-12 Thread Isaku Yamahata
On Wed, Sep 12, 2012 at 11:45:12AM -0700, Ben Pfaff wrote: > On Wed, Sep 12, 2012 at 03:17:22PM +0900, Isaku Yamahata wrote: > > add register_table method to SchemaHelper as counter part of > > ovsdb_idl_add_table(). > > > > Signed-off-by: Isaku Yamahata > > This seems like a good idea, but woul

Re: [ovs-dev] [PATCH 3/5] python/ovs/db/idl: make SchemaHelper accept schema in json form

2012-09-12 Thread Isaku Yamahata
On Wed, Sep 12, 2012 at 11:52:09AM -0700, Ben Pfaff wrote: > I agree about raising an error if both are provided. > > There doesn't seem to be an issue with reading the file earlier. It > won't bother any in-tree users anyhow. Schema file isn't such large in practice. for example, The size of vs

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Isaku Yamahata
On Wed, Sep 12, 2012 at 08:32:15AM -0700, Reid Price wrote: > One note inline > > On Sep 11, 2555 BE, at 23:17, Isaku Yamahata wrote: > > > Since Transaction._substitute doesn't substitute elements of list/tuple, > > setting list references results in transaction error. Teach it such case. > >

Re: [ovs-dev] [PATCH 5/5] [RFC] ofp-actions: Check pre-requisists of set-field actions

2012-09-12 Thread Simon Horman
On Wed, Sep 12, 2012 at 12:09:41PM -0700, Ben Pfaff wrote: > On Wed, Sep 12, 2012 at 05:44:32PM +0900, Simon Horman wrote: > > By passing a flow to the action parser the pre-requisites > > of set-feild actions will be checked. If the flow is NULL, > > for instance in test code such as ofctl_parse_o

Re: [ovs-dev] [PATCH 2/5] python/ovs/db/idl: counter part of ovsdb_idl_add_table() to SchemaHelper

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 11:22:53AM +0900, Isaku Yamahata wrote: > On Wed, Sep 12, 2012 at 11:45:12AM -0700, Ben Pfaff wrote: > > On Wed, Sep 12, 2012 at 03:17:22PM +0900, Isaku Yamahata wrote: > > > add register_table method to SchemaHelper as counter part of > > > ovsdb_idl_add_table(). > > > > >

Re: [ovs-dev] [PATCH 3/5] python/ovs/db/idl: make SchemaHelper accept schema in json form

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 11:27:30AM +0900, Isaku Yamahata wrote: > On Wed, Sep 12, 2012 at 11:52:09AM -0700, Ben Pfaff wrote: > > I agree about raising an error if both are provided. > > > > There doesn't seem to be an issue with reading the file earlier. It > > won't bother any in-tree users anyh

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 11:30:23AM +0900, Isaku Yamahata wrote: > From: Isaku Yamahata > Date: Mon, 10 Sep 2012 18:21:20 +0900 > Subject: [PATCH] python/ovs/db/idl.py: Transaction._substitute doesn't handle > list/tuple > > Since Transaction._substitute doesn't substitute elements of list/tuple,

Re: [ovs-dev] [PATCH 3/5] python/ovs/db/idl: make SchemaHelper accept schema in json form

2012-09-12 Thread Reid Price
If by chance you haven't pushed yet, s/preresentation// On Wed, Sep 12, 2012 at 8:48 PM, Ben Pfaff wrote: > On Thu, Sep 13, 2012 at 11:27:30AM +0900, Isaku Yamahata wrote: > > On Wed, Sep 12, 2012 at 11:52:09AM -0700, Ben Pfaff wrote: > > > I agree about raising an error if both are provided. >

Re: [ovs-dev] [PATCH] ofp-actions: Right-justify the value in ofpact_reg_load 'subvalue' member.

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 10:08:48AM +0900, Simon Horman wrote: > On Wed, Sep 12, 2012 at 11:37:53AM -0700, Ben Pfaff wrote: > > This is what I intended when I suggested using mf_subvalue, but I didn't > > notice the difference until after applying the patch. > > > > Signed-off-by: Ben Pfaff > > A

Re: [ovs-dev] [PATCH 2/5] lib/ofp-actions: helper functions for of12 set-field action

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 10:33:35AM +0900, Simon Horman wrote: > On Wed, Sep 12, 2012 at 11:13:49AM -0700, Ben Pfaff wrote: > > Hmm. This looks like it blindly puts an OFPAT12_SET_FIELD action into > > other versions of OpenFlow. I think we have a few options: > > True, but I'm not sure that I un

Re: [ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 10:44:00AM +0900, Simon Horman wrote: > On Wed, Sep 12, 2012 at 12:06:50PM -0700, Ben Pfaff wrote: > > On Wed, Sep 12, 2012 at 05:44:31PM +0900, Simon Horman wrote: > > > From: Isaku Yamahata > > > > > > Signed-off-by: Isaku Yamahata > > > Signed-off-by: Simon Horman > >

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Reid Price
+else: +if type(json) == list: +json = [self._substitute_uuids(elem) for elem in json] +else: +json = tuple(self._substitute_uuids(elem) for elem in json) tuple/list are treated identically, based upon the retur

Re: [ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Simon Horman
On Wed, Sep 12, 2012 at 09:09:49PM -0700, Ben Pfaff wrote: > On Thu, Sep 13, 2012 at 10:44:00AM +0900, Simon Horman wrote: > > On Wed, Sep 12, 2012 at 12:06:50PM -0700, Ben Pfaff wrote: > > > On Wed, Sep 12, 2012 at 05:44:31PM +0900, Simon Horman wrote: > > > > From: Isaku Yamahata > > > > > > >

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Isaku Yamahata
On Wed, Sep 12, 2012 at 08:56:41PM -0700, Ben Pfaff wrote: > On Thu, Sep 13, 2012 at 11:30:23AM +0900, Isaku Yamahata wrote: > > From: Isaku Yamahata > > Date: Mon, 10 Sep 2012 18:21:20 +0900 > > Subject: [PATCH] python/ovs/db/idl.py: Transaction._substitute doesn't > > handle list/tuple > > > >

Re: [ovs-dev] [PATCH 4/5] ofp-actions: encode OF12 output/set-field actions

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 01:37:08PM +0900, Simon Horman wrote: > On Wed, Sep 12, 2012 at 09:09:49PM -0700, Ben Pfaff wrote: > > On Thu, Sep 13, 2012 at 10:44:00AM +0900, Simon Horman wrote: > > > On Wed, Sep 12, 2012 at 12:06:50PM -0700, Ben Pfaff wrote: > > > > On Wed, Sep 12, 2012 at 05:44:31PM +0

Re: [ovs-dev] [PATCH 4/5] python/ovs/db/idl.py: Transaction._substitute doesn't handle list/tuple

2012-09-12 Thread Ben Pfaff
On Thu, Sep 13, 2012 at 01:41:04PM +0900, Isaku Yamahata wrote: > On Wed, Sep 12, 2012 at 08:56:41PM -0700, Ben Pfaff wrote: > > On Thu, Sep 13, 2012 at 11:30:23AM +0900, Isaku Yamahata wrote: > > > From: Isaku Yamahata > > > Date: Mon, 10 Sep 2012 18:21:20 +0900 > > > Subject: [PATCH] python/ovs/

Re: [ovs-dev] [PATCH 04/27] ofp-util: Allow decoding of Open Flow 1.1 & 1.2 Table Statistics Request Messages

2012-09-12 Thread Simon Horman
On Tue, Sep 11, 2012 at 09:55:17PM -0700, Ben Pfaff wrote: > On Mon, Sep 10, 2012 at 10:47:52AM -0700, Ben Pfaff wrote: > > On Mon, Sep 10, 2012 at 09:59:28AM +0900, Simon Horman wrote: > > > On Sat, Sep 08, 2012 at 12:15:53PM +0900, Simon Horman wrote: > > > > On Fri, Sep 07, 2012 at 10:33:00AM -0