In the push_ukey_ops__(), when flow_del operation returns error, the 'struct
stats' passed to the operation function will be set to all zero. And we
should not use it to calculate the delta (i.e. minus the zero stats by the
cached stats causes overflow).
Even though this should rarely happen, it is still good to make
push_ukey_ops__() just ignore the operation when it fails.
Signed-off-by: Alex Wang <ee07b291@gmail.com>
Acked-by: Daniele Di Proietto <diproiettod@vmware.com>
continue;
}
+ if (op->dop.error) {
+ /* flow_del error, 'stats' is unusable. */
+ continue;
+ }
+
if (op->ukey) {
ovs_mutex_lock(&op->ukey->mutex);
push->used = MAX(stats->used, op->ukey->stats.used);