On Tue, May 17, 2016 at 7:44 AM, Ben Pfaff <b...@ovn.org> wrote:

> The ofport member should be an ofp_port_t, since it represents an OpenFlow
> port number.
>
> Fixes: 9baaabfff3c7 ("ovn: Fix localnet ports deletion and recreation
> sometimes after restart.")
>

Is this rather related to "ovn: send garp on localnet." ?



> Signed-off-by: Ben Pfaff <b...@ovn.org>
> ---
>  ovn/controller/pinctrl.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/ovn/controller/pinctrl.c b/ovn/controller/pinctrl.c
> index 1611bcd..bc57c40 100644
> --- a/ovn/controller/pinctrl.c
> +++ b/ovn/controller/pinctrl.c
> @@ -514,7 +514,7 @@ struct garp_data {
>      ovs_be32 ipv4;               /* Ipv4 address of port. */
>      long long int announce_time; /* Next announcement in ms. */
>      int backoff;                 /* Backoff for the next announcement. */
> -    int ofport;                  /* ofport used to output this GARP. */
> +    ofp_port_t ofport;           /* ofport used to output this GARP. */
>  };
>
>  /* Contains GARPs to be sent. */
> @@ -548,7 +548,8 @@ send_garp_update(const struct sbrec_port_binding
> *binding_rec,
>      if (!ld || !ld->localnet_port) {
>          return;
>      }
> -    int ofport = simap_get(localnet_ofports,
> ld->localnet_port->logical_port);
> +    ofp_port_t ofport = u16_to_ofp(simap_get(localnet_ofports,
> +
>  ld->localnet_port->logical_port));
>
>      /* Update GARP if it exists. */
>      struct garp_data *garp = shash_find_data(&send_garp_data,
> --
> 2.1.3
>
> _______________________________________________
> dev mailing list
> dev@openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev
>
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to