[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250203180623.GC1003@redhat.com>
Date: Mon, 3 Feb 2025 19:06:24 +0100
From: Oleg Nesterov <oleg@...hat.com>
To: Mateusz Guzik <mjguzik@...il.com>
Cc: ebiederm@...ssion.com, brauner@...nel.org, akpm@...ux-foundation.org,
linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 3/6] exit: postpone tty_kref_put() until after
tasklist_lock is dropped
On 02/01, Mateusz Guzik wrote:
>
> Instead of smuggling the tty pointer directly, use a struct so that more
> things can be added later.
I am not sure this particular change worth the effort, but I won't argue.
I'd like to know what Eric thinks.
OTOH, if we do this, then perhaps we can do more "call tty_kref_put()
lockless" changes later. And perhaps even add the new
void tty_kref_put_sync(struct tty_struct *tty)
{
if (tty)
kref_put(&tty->kref, release_one_tty);
}
helper. With this change release_task() doesn't need to abuse
schedule_work(), and this helper can have more users.
Nevermind, this is almost off-topic.
Oleg.
Powered by blists - more mailing lists