Re: [PATCH] x86/sgx: Fix SRCU list traversal
"Huang, Kai" <[email protected]> Wed, 11 Feb 2026 10:38:53 +0000
| Newsgroups | org.kernel.vger.linux-sgx,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On Wed, 2026-02-04 at 20:53 -0500, lirongqing wrote: > From: Li RongQing <[email protected]> > > Replace list_for_each_entry_rcu() with list_for_each_entry_srcu() > when traversing the encl->mm_list protected by SRCU. This ensures > proper synchronization annotation and avoids potential lockdep > warnings about incorrect RCU usage. > > The list is protected by encl->srcu, not RCU, so the SRCU-specific > iterator with srcu_read_lock_held() annotation is required. > > Signed-off-by: Li RongQing <[email protected]> Acked-by: Kai Huang <[email protected]>