From: Pasha Tatashin <pasha.tatashin@soleen.com>
To: David Matlack <dmatlack@google.com>
Cc: rppt@kernel.org, pratyush@kernel.org,
linux-kernel@vger.kernel.org, akpm@linux-foundation.org,
linux-mm@kvack.org
Subject: Re: [PATCH 3/6] liveupdate: Defer file handler module refcounting to active sessions
Date: Tue, 17 Mar 2026 14:32:34 -0400 [thread overview]
Message-ID: <CA+CK2bCtYMoXfXdaOhvpQ5YUL-407qeCWqry92UZ0qKdEBv+4w@mail.gmail.com> (raw)
In-Reply-To: <CALzav=cY4G-1MrEv1zNbqjdu3eXYnFLUK4xgo0r=DrbSdsXPLQ@mail.gmail.com>
On Tue, Mar 17, 2026 at 12:39 PM David Matlack <dmatlack@google.com> wrote:
>
> On Mon, Mar 16, 2026 at 7:50 PM Pasha Tatashin
> <pasha.tatashin@soleen.com> wrote:
>
> > @@ -281,7 +282,10 @@ int luo_preserve_file(struct luo_file_set *file_set, u64 token, int fd)
> > scoped_guard(rwsem_read, &luo_file_handler_lock) {
> > list_private_for_each_entry(fh, &luo_file_handler_list, list) {
> > if (fh->ops->can_preserve(fh, file)) {
> > - err = 0;
> > + if (try_module_get(fh->ops->owner))
> > + err = 0;
> > + else
> > + err = -ENODEV;
> > break;
> > }
> > }
>
> Does LUO even need to take a reference to the file handler owner?
>
> LUO already takes a reference to the file, and the file should already
> be holding a reference to the file's owner, which should (must?) be
> the same as the file handler's owner.
Hi David,
Thanks for review. This is a very good point. I will remove taking
file handler reference entirely.
>
> For FLB it makes more sense since the FLB's owner is likely not the
> same as the file's owner.
+1.
Pasha
next prev parent reply other threads:[~2026-03-17 18:33 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-17 2:50 [PATCH 0/6] liveupdate: Fix module unloading and unregister API Pasha Tatashin
2026-03-17 2:50 ` [PATCH 1/6] liveupdate: Protect file handler list with rwsem Pasha Tatashin
2026-03-17 2:50 ` [PATCH 2/6] liveupdate: Protect FLB lists " Pasha Tatashin
2026-03-17 2:50 ` [PATCH 3/6] liveupdate: Defer file handler module refcounting to active sessions Pasha Tatashin
2026-03-17 16:38 ` David Matlack
2026-03-17 18:32 ` Pasha Tatashin [this message]
2026-03-17 2:50 ` [PATCH 4/6] liveupdate: Defer FLB " Pasha Tatashin
2026-03-17 2:50 ` [PATCH 5/6] liveupdate: Make unregister functions return void Pasha Tatashin
2026-03-17 8:58 ` kernel test robot
2026-03-17 10:10 ` kernel test robot
2026-03-17 13:03 ` Pasha Tatashin
2026-03-17 2:50 ` [PATCH 6/6] liveupdate: Remove luo_session_quiesce() Pasha Tatashin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CA+CK2bCtYMoXfXdaOhvpQ5YUL-407qeCWqry92UZ0qKdEBv+4w@mail.gmail.com \
--to=pasha.tatashin@soleen.com \
--cc=akpm@linux-foundation.org \
--cc=dmatlack@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=pratyush@kernel.org \
--cc=rppt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox