I won't apply this version, please send v6 with the changes below.
On Tue, 10 Nov 2026 18:26:47 +0100, Vladimir Riabchun
<[email protected]> wrote:
> Vladimir Riabchun (5):
> ve: Remove STOPPED state
> ve: Introduce override_ve/revert_ve helpers
> ve: Defer ve creds drop until ve is completely destroyed
> ovl: Keep creator VE in overlayfs superblock
> ve/overlayfs: Override VE together with creds
The approach works: the criu oops is gone, the "CT stopped while the
overlay is still in use" case is closed by patches 3 and 4, and a CT
using a host overlay (GPU passthrough) behaves as before. What is left
is small.
What to change for v6:
1. Patches 2 and 5, code: a CT task asking override_ve() for VE0 gets
its current override back (no change) instead of ERR_PTR(-EPERM).
Cross-CT returns ERR_PTR(-EPERM) instead of -EINVAL.
ovl_override_creds() and ovl_revert_creds() then test only
IS_ERR(). Change the comment "Cross-CT mounts are forbidden" to say
that using an overlayfs from another CT is refused.
2. Patch 2, code: do not print ve_name(new_ve) in the "Invalid VE
override" message.
3. Patch 2, code: WARN_ON_ONCE instead of WARN_ON in
dup_task_struct().
4. Patch 3, code: the two "ve isn't running" comments in
kernel/capability.c now mean "ve was never started", fix them.
5. Patch 1, message: restore Pavel's Reviewed-by from v2 (the diff has
not changed since), "stated" -> "state".
6. Patch 2, message: rewrite the garbled fork sentence, and say that
ve_capable() now uses overrided_ve and which VE switches are
allowed, refused, or silently skipped.
7. Patch 4, message: drop the blank line before Signed-off-by.
8. Patch 5, message: add a Fixes tag for ec01a90d0ef9 ("ovl: replace
capable by ve_capable for indexing feature"), fix "swich" and
"Stroing", say why cross-CT use must fail, and limit the "compile
error for new users" claim to ovl_override_creds().
9. All patches: add a Feature line. Patches 1-3: "ve: ve generic
structures" (as ed9325c6f4ce6), patches 4-5: "ve: CRIU support"
(as ec01a90d0ef9).
10. Cover letter: the "v2:" link points to the 20 Sep two-patch series,
and "reworked completely after v2" is wrong (override_ve() came
with the 22 Oct v1). Mention that cross-CT use now fails, and name
the Jira task for the backing_file gap (item 1 below).
11. All patches: add the Reviewed-by of Vasileios Almpanis, which he
gave on the v5 cover letter; the v6 changes above are small enough
to keep it.
Separate patches, not needed for v6:
1. backing_file_ctx.cred = ovl_creds() (read_iter, write_iter, splice,
mmap) still switches creds without the VE. Nothing there reaches
ve_capable() today, so no crash, but it is the same class of bug.
You said on v2 it would be a separate task; please file it.
2. Optional hardening: a WARN_ON_ONCE(!fh) returning -EIO in
ovl_create_index() would turn any future creds/VE mismatch into an
error instead of an oops.
--
Konstantin Khorenko,
Virtuozzo Linux Kernel Team
_______________________________________________
Devel mailing list
[email protected]
https://lists.openvz.org/mailman/listinfo/devel