]> git.baikalelectronics.ru Git - kernel.git/commit
mac80211: Use rhashtable_lookup_get_insert_fast instead of racy code
authorHerbert Xu <herbert@gondor.apana.org.au>
Thu, 14 Feb 2019 14:03:26 +0000 (22:03 +0800)
committerJohannes Berg <johannes.berg@intel.com>
Fri, 22 Feb 2019 12:48:48 +0000 (13:48 +0100)
commitaa9ae1164f914e436df72bf474b5d0ef9da01fb1
tree24576379a6d0cb8f6c63d7e58f186587569bec37
parent6007da6675fd2ad5f9fc7c5ad82cbff942a7d81a
mac80211: Use rhashtable_lookup_get_insert_fast instead of racy code

The code in mesh_path_add tries to handle the case where a duplicate
entry is added to the rhashtable by doing a lookup after a failed
insertion.  It also tries to handle races by repeating the insertion
should the lookup fail.

This is now unnecessary as we have rhashtable API functions that can
directly return the mathcing object.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/mesh_pathtbl.c