> On Aug 1, 2019, at 3:07 PM, Yi-Hung Wei <[email protected]> wrote:
>
> diff --git a/lib/dpif-provider.h b/lib/dpif-provider.h
> index 79a2314500cf..57b32ccb610f 100644
> --- a/lib/dpif-provider.h
> +++ b/lib/dpif-provider.h
> @@ -536,6 +536,11 @@ struct dpif_class {
> struct ct_dpif_timeout_policy *tp);
> int (*ct_timeout_policy_dump_done)(struct dpif *, void *state);
>
> + /* Get timeout policy name (OVS_CT_ATTR_TIMEOUT) from datapath. */
> + int (*ct_format_timeout_policy_name)(struct dpif *, uint32_t tp_id,
> + uint16_t dl_type, uint8_t nw_proto,
> + struct ds *ds);
To Darrell's point about wanting the ability to implement timeout policies in
the userspace implementation without unwildcarding the dl_type and nw_proto,
I'd suggest adding a "bool *unwildcard" argument that the provider can indicate
whether those bits should be unwildcarded or not.
> diff --git a/ofproto/ofproto-provider.h b/ofproto/ofproto-provider.h
> index 41e07f0ee23e..1a2fc4a6a084 100644
> --- a/ofproto/ofproto-provider.h
> +++ b/ofproto/ofproto-provider.h
> @@ -1880,6 +1880,11 @@ struct ofproto_class {
> const struct ovsrec_datapath *dp_cfg, unsigned int idl_seqno);
> /* Cleans up the to be deleted timeout policy in the pending kill list. */
> void (*ct_zone_timeout_policy_sweep)(const struct ofproto *ofproto_);
> +
> + /* Returns true if timeout policy for 'zone' is configured and stores the
> + * timeout policy id in '*tp_id'. */
> + bool (*ct_zone_timeout_policy_get)(const struct ofproto *ofproto_,
> + uint16_t zone, uint32_t *tp_id);
> };
As we discuss off-line, by pulling the OVSDB information out of the dpif layer,
I think we'll want a more tradition get/set ofproto interface. I believe that
will be done in v3.
Thanks,
--Justin
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev