ofproto-dpif-xlate: Fix mac learning deadlock.
authorEthan Jackson <ethan@nicira.com>
Wed, 4 Sep 2013 00:34:00 +0000 (17:34 -0700)
committerEthan Jackson <ethan@nicira.com>
Wed, 4 Sep 2013 00:53:57 +0000 (17:53 -0700)
commitd6d5bbc9e43f5b6ce28d1d8c0df06b7cc3cb6db9
tree57ebe8b7ea09040c209370132ddbfbc6dfd03ef0
parent7395c05254df87ce52b37b04478e802befd799d9
ofproto-dpif-xlate: Fix mac learning deadlock.

xlate_normal() held the mac_learning lock while calling
output_normal().  When running with patch ports, this could cause
xlate_actions() to be called again, possibly attempting to take a
write lock on the same learning table causing a deadlock.  This patch
solves the problem by holding the lock for a very brief period of
time.

Bug #19423.
Signed-off-by: Ethan Jackson <ethan@nicira.com>
Acked-by: Justin Pettit <jpettit@nicira.com>
ofproto/ofproto-dpif-xlate.c