v1
2026-10-05
文件处理器依赖级别机制 · v1
RFC 为 Liveupdate FD 保留引入批量 ioctl 和文件处理器层级,按依赖顺序由内核保序保留 FDs。
原始补丁链接
子 Patch(6)
1/6
liveupdate: Introduce file handler dependency level
Dependency level is an optional level in the file handler that can be used to indicate the order in which FDs are preserved. The level define the type of state an FD preserved and how it relates to ot
2/6
mm/memfd_luo: Set Liveupdate level of a memfd file handler
Set level of the memfd file handler to LIVEUPDATE_LEVEL_MEM as it is a memory provider. Signed-off-by: Samiullah Khawaja skhawaja@google.com — mm/memfd_luo.c | 1 + 1 file changed , 1 insertion(
3/6
iommufd: Set liveupdate file handler level
Set level of iommufd preservation file handler to LIVEUPDATE_LEVEL_MAPPER. Signed-off-by: Samiullah Khawaja skhawaja@google.com — drivers/iommu/iommufd/liveupdate.c | 1 + 1 file changed , 1 ins
4/6
vfio/pci: Set live update file handler level
Set live update file handler to LIVEUPDATE_LEVEL_DEVICE. Signed-off-by: Samiullah Khawaja skhawaja@google.com — drivers/vfio/pci/vfio_pci_liveupdate.c | 1 + 1 file changed , 1 insertion(+) diff
5/6
selftests/liveupdate: Add API to preserve a batch of FDs
Add luo_session_preserve_fds() that can be used to preserve a batch of FDs using the LIVEUPDATE_SESSION_PRESERVE_FDS ioctl. Signed-off-by: Samiullah Khawaja skhawaja@google.com — …/liveupdate/
6/6
iommufd/selftests: Preserve all the FDs in a batch
Use the luo_session_preserve_fds() to preserve vfio cdev, iommufd and memfd together in a batch. Signed-off-by: Samiullah Khawaja skhawaja@google.com — …/iommu/iommufd_liveupdate_kexec_test.c