lkml.org 
[lkml]   [2026]   [May]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v1 2/3] liveupdate: block outgoing session mutations during serialization
On 05-06 10:47, Pratyush Yadav wrote:
> On Wed, May 06 2026, Pasha Tatashin wrote:
>
> > Introduce a 'rebooting' flag in the session header to ensure that once
> > serialization has started, no new outgoing session mutations (creations
> > or file preservations) can occur.
>
> Would it be a better idea to hold the session header lock and locks of
> each session? This would prevent anyone else from getting access to any
> of the sessions, and we don't have to worry about all the weird cases
> when one might add a file to a serialized session or something similar.
>
> Once liveupdate_reboot() returns success, there is no going back anyway
> so I don't think it matters much that some tasks will be left waiting.

Overall, we can do that. The only possible issue I can think of is that
we might get some stupid warnings if the shutdown takes too long:

INFO: task ... blocked for more than ... seconds
followed by a call trace.

But that is unlikely, and it also means that userspace has been trying
to mutate sessions when it should not have, so I think your approach is
workable. Let me update the implementation.

Pasha

\
 
 \ /
  Last update: 2026-05-06 17:34    [W:0.104 / U:2.169 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog