ovn-controller: Clean up bindings handling.
authorRussell Bryant <russell@ovn.org>
Tue, 12 Jul 2016 17:33:08 +0000 (13:33 -0400)
committerRussell Bryant <russell@ovn.org>
Mon, 18 Jul 2016 19:36:27 +0000 (15:36 -0400)
commit6f783c0616ec4c8c72003c14a83adc570663a58f
tree649e471f43610aea8dac5310340cfae912a71063
parentbf44c2cd9536be18e1b34a22c925e1bd75f81c63
ovn-controller: Clean up bindings handling.

Remove the global set of logical port IDs called 'all_lports'.  This is
no longer used for anything after conntrack ID assignment was moved out
of binding.c.

Remove the global smap of logical port IDs to ovsrec_interface records.
We can't persist references to these records, as we may be holding
references to freed memory.  Instead, replace it with a new global sset
of logical port IDs called 'local_ids'.  This is used to track when
interfaces have been added or removed.  We also build a temporary
shash of logical port IDs to ovs interfaces used for fast lookup
of the right interface as needed.

Found by inspection.

Fixes: a478c4efef4d ("ovn-controller: Refactor conntrack zone allocation.")
Fixes: 263064aeaa31 ("Convert binding_run to incremental processing.")
Signed-off-by: Russell Bryant <russell@ovn.org>
Acked-by: Ryan Moats <rmoats@us.ibm.com>
ovn/controller/binding.c