It is better to explicitly initialize the dp->destroy than to rely
on xzalloc().
Signed-off-by: Andy Zhou <azhou@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
*CONST_CAST(const struct dpif_class **, &dp->class) = class;
*CONST_CAST(const char **, &dp->name) = xstrdup(name);
ovs_refcount_init(&dp->ref_cnt);
*CONST_CAST(const struct dpif_class **, &dp->class) = class;
*CONST_CAST(const char **, &dp->name) = xstrdup(name);
ovs_refcount_init(&dp->ref_cnt);
+ atomic_flag_clear(&dp->destroyed);
ovs_mutex_init(&dp->flow_mutex);
classifier_init(&dp->cls, NULL);
ovs_mutex_init(&dp->flow_mutex);
classifier_init(&dp->cls, NULL);