]> git.baikalelectronics.ru Git - kernel.git/commit
lib/vsprintf: Remove static_branch_likely() from __ptr_to_hashval().
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>
Tue, 27 Sep 2022 10:49:11 +0000 (12:49 +0200)
committerPetr Mladek <pmladek@suse.com>
Thu, 29 Sep 2022 11:44:27 +0000 (13:44 +0200)
commit73b74bb98e5a19e1cf9ee3d71f780ab6102d3058
tree396869d44ae7fc76f858f862f57eefd8a3daabd2
parentb4c8b2932148f9e9979ea67b4770eda4727e78fc
lib/vsprintf: Remove static_branch_likely() from __ptr_to_hashval().

Using static_branch_likely() to signal that ptr_key has been filled is a
bit much given that it is not a fast path.

Replace static_branch_likely() with bool for condition and a memory
barrier for ptr_key.

Suggested-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20220927104912.622645-2-bigeasy@linutronix.de
lib/vsprintf.c