mirror of
https://github.com/lkl/linux.git
synced 2025-12-19 16:13:19 +09:00
Merge tag 'core_guards_for_6.5_rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue
Pull scope-based resource management infrastructure from Peter Zijlstra: "These are the first few patches in the Scope-based Resource Management series that introduce the infrastructure but not any conversions as of yet. Adding the infrastructure now allows multiple people to start using them. Of note is that Sparse will need some work since it doesn't yet understand this attribute and might have decl-after-stmt issues" * tag 'core_guards_for_6.5_rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue: kbuild: Drop -Wdeclaration-after-statement locking: Introduce __cleanup() based infrastructure apparmor: Free up __cleanup() name dmaengine: ioat: Free up __cleanup() name
This commit is contained in:
@@ -343,4 +343,9 @@ static inline void smp_mb__after_srcu_read_unlock(void)
|
||||
/* __srcu_read_unlock has smp_mb() internally so nothing to do here. */
|
||||
}
|
||||
|
||||
DEFINE_LOCK_GUARD_1(srcu, struct srcu_struct,
|
||||
_T->idx = srcu_read_lock(_T->lock),
|
||||
srcu_read_unlock(_T->lock, _T->idx),
|
||||
int idx)
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user