]> www.infradead.org Git - users/jedix/linux-maple.git/commit
net: dst_cache: Use nested-BH locking for dst_cache::cache
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>
Mon, 12 May 2025 09:27:23 +0000 (11:27 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 15 May 2025 13:23:30 +0000 (15:23 +0200)
commitc99dac52ffad5df88c9c52ab2008b182743bdcc1
tree390890ca773061c527e43ac1aaa80c7fc8010d71
parent32471b2f481dea8624f27669d36ffd131d24b732
net: dst_cache: Use nested-BH locking for dst_cache::cache

dst_cache::cache is a per-CPU variable and relies on disabled BH for its
locking. Without per-CPU locking in local_bh_disable() on PREEMPT_RT
this data structure requires explicit locking.

Add a local_lock_t to the data structure and use
local_lock_nested_bh() for locking. This change adds only lockdep
coverage and does not alter the functional behaviour for !PREEMPT_RT.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Link: https://patch.msgid.link/20250512092736.229935-3-bigeasy@linutronix.de
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
net/core/dst_cache.c