Re: [PATCH v5 22/36] um: Fix incorrect __acquires/__releases annotations

From: Bart Van Assche

Date: Fri Dec 19 2025 - 16:06:18 EST


On 12/19/25 7:40 AM, Marco Elver wrote:
-void enter_turnstile(struct mm_id *mm_id) __acquires(turnstile)
+struct mutex *__get_turnstile(struct mm_id *mm_id)
{
struct mm_context *ctx = container_of(mm_id, struct mm_context, id);
- mutex_lock(&ctx->turnstile);
+ return &ctx->turnstile;
}

Many "container_of()" wrappers have "to" in their name. Please follow
that convention and rename this function into e.g. mm_id_to_turnstile().

Thanks,

Bart.