> On Aug 8, 2016, at 3:10 PM, Jan Scheurich <jan.scheur...@ericsson.com> wrote: > > Hi Jarno, > > While trying to rebase my "dpcls per in_port" patch to your updated > pvector/cpvector implementation, I have stumbled over a threading issue in > your patch. > > I believe that dpcls_destroy_subtable(), which may be invoked from > revalidater threads at flow removal, should not simply call the new > non-concurrent pvector_remove() function as this may destroy the priority > order of the vector when it swaps in the last element. > > In this particular case the damage done to the concurrently iterating PMD > thread might not be fatal, but I believe using the non-concurrent API from > two different threads is not OK. Seizing the pmd->flow_mutex for flow removal > does not suffice as it does not prevent the PMD thread from iterating the > pvector at lookup. > > In my view we should revert dpcls to use the concurrent cpvector API. I would > also use that approach for v3 of my "dpcls per in_port with sorted subtables" > patch. >
Thanks for figuring this out. I think it is cleaner to just revert that patch that exposed the non-concurrent pvector, as it has no other users. I'll post a patch to that effect shortly. Regards, Jarno _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev