Re: [PATCH v2 1/5] rust: sync: move lockdep types to rust/kernel/sync/lockdep.rs

From: Boqun Feng

Date: Fri Jul 17 2026 - 09:00:07 EST


On Thu, Jul 16, 2026 at 12:34:25PM +0000, Alice Ryhl wrote:
> The lockdep types are currently stored directly in rust/kernel/sync.rs,
> but there are starting to be too many of them to keep them in that file.
> Thus, move them to a submodule.
>
> For commonly used lockdep logic it's useful to keep re-exports in
> kernel::sync, and this also avoids the need to update any users.
>
> Reviewed-by: Gary Guo <gary@xxxxxxxxxxx>
> Reviewed-by: Boqun Feng <boqun@xxxxxxxxxx>
> Reviewed-by: Carlos Llamas <cmllamas@xxxxxxxxxx>
> Signed-off-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>
> ---
> rust/kernel/sync.rs | 135 +-----------------------------------------
> rust/kernel/sync/lockdep.rs | 139 ++++++++++++++++++++++++++++++++++++++++++++

Alice brought it up offlist (thanks!): we should add this file under
LOCKING PRIMITIVES entry. This can be done in a separate patch if that
works easier.

Regards,
Boqun

> 2 files changed, 141 insertions(+), 133 deletions(-)
>
[...]