diff mbox

[ovs-dev,06/30] ofp-actions: Correct member name for write_actions.

Message ID 1470642309-18995-7-git-send-email-blp@ovn.org
State Accepted
Headers show

Commit Message

Ben Pfaff Aug. 8, 2016, 7:44 a.m. UTC
For a variable-length action like write_actions, the member name is
supposed to be the name of the variable-length array at the end of the
action structure.  It only makes a real difference if the beginning of the
array is not 64-bit aligned, so it did not matter in this case, but it's
better to get it right.

Signed-off-by: Ben Pfaff <blp@ovn.org>
---
 include/openvswitch/ofp-actions.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Ryan Moats Aug. 8, 2016, 3:38 p.m. UTC | #1
"dev" <dev-bounces@openvswitch.org> wrote on 08/08/2016 02:44:45 AM:

> From: Ben Pfaff <blp@ovn.org>
> To: dev@openvswitch.org
> Cc: Ben Pfaff <blp@ovn.org>
> Date: 08/08/2016 02:46 AM
> Subject: [ovs-dev] [PATCH 06/30] ofp-actions: Correct member name
> for write_actions.
> Sent by: "dev" <dev-bounces@openvswitch.org>
>
> For a variable-length action like write_actions, the member name is
> supposed to be the name of the variable-length array at the end of the
> action structure.  It only makes a real difference if the beginning of
the
> array is not 64-bit aligned, so it did not matter in this case, but it's
> better to get it right.
>
> Signed-off-by: Ben Pfaff <blp@ovn.org>
> ---
>  include/openvswitch/ofp-actions.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/include/openvswitch/ofp-actions.h b/include/
> openvswitch/ofp-actions.h
> index 42764b1..a0cefe3 100644
> --- a/include/openvswitch/ofp-actions.h
> +++ b/include/openvswitch/ofp-actions.h
> @@ -119,7 +119,7 @@
>      /* Instructions. */
\
>      OFPACT(METER,           ofpact_meter,       ofpact, "meter")
\
>      OFPACT(CLEAR_ACTIONS,   ofpact_null,        ofpact, "clear_actions")
\
> -    OFPACT(WRITE_ACTIONS,   ofpact_nest,        ofpact, "write_actions")
\
> +    OFPACT(WRITE_ACTIONS,   ofpact_nest,        actions,
"write_actions") \
>      OFPACT(WRITE_METADATA,  ofpact_metadata,    ofpact,
"write_metadata") \
>      OFPACT(GOTO_TABLE,      ofpact_goto_table,  ofpact, "goto_table")
>
> --

Since I don't have PS 5 in my mailbox, this Ack counts for both
this patch set and PS 5...

Acked-by: Ryan Moats <rmoats@us.ibm.com>
diff mbox

Patch

diff --git a/include/openvswitch/ofp-actions.h b/include/openvswitch/ofp-actions.h
index 42764b1..a0cefe3 100644
--- a/include/openvswitch/ofp-actions.h
+++ b/include/openvswitch/ofp-actions.h
@@ -119,7 +119,7 @@ 
     /* Instructions. */                                                 \
     OFPACT(METER,           ofpact_meter,       ofpact, "meter")        \
     OFPACT(CLEAR_ACTIONS,   ofpact_null,        ofpact, "clear_actions") \
-    OFPACT(WRITE_ACTIONS,   ofpact_nest,        ofpact, "write_actions") \
+    OFPACT(WRITE_ACTIONS,   ofpact_nest,        actions, "write_actions") \
     OFPACT(WRITE_METADATA,  ofpact_metadata,    ofpact, "write_metadata") \
     OFPACT(GOTO_TABLE,      ofpact_goto_table,  ofpact, "goto_table")