Commit d133a36
committed
pinctrl: Convert the put_ARP/ND/FDB actions to be lockless.
The put_ARP/ND/FDB were bound to pinctrl lock to prevent data races
as they have used shared hmap to store the data that were later on
added into SB. This is problematic in situations when main thread
holds the lock and we have to process any put_ARP/ND/FDB packet. That
contention would block the pinctrl thread from processing the
incoming packets. The same can happen from the opposite side, pinctrl
could be holding a lock, delaying main thread from processing other
updates.
To prevent that use the hmap only by main thread, this will ensure
that we wait properly for the multicast timeout to expire and at the
same time to do the deduplication. Once the entry arrives it will
be shared by thread-safe ring buffer and consumed by main thread.
Reported-at: https://redhat.atlassian.net/browse/FDP-3924
Acked-by: Dumitru Ceara <dceara@redhat.com>
Signed-off-by: Ales Musil <amusil@redhat.com>
(cherry picked from commit 9fbc6d6)1 parent b8cb977 commit d133a36
1 file changed
Lines changed: 112 additions & 78 deletions
0 commit comments