* Adalbert Lazăr: >>> - the control plane accepts three ioctls >>> >>> PIDFD_MEM_MAP takes a struct like >>> >>> struct pidfd_mem_map { >>> uint64_t address; >>> off_t offset; >>> off_t size; >>> int flags; >>> int padding[7]; >>> } >>> >>> After this is done, the memory access fd can be mmap-ed at range >>> [offset, >>> offset+size), and it will read memory from range [address, >>> address+size) of the target descriptor. >>> >>> PIDFD_MEM_UNMAP takes a struct like >>> >>> struct pidfd_mem_unmap { >>> off_t offset; >>> off_t size; >>> } >>> >>> and unmaps the corresponding range of course. off_t depends on preprocessor macros (_FILE_OFFSET_BITS), so these types should be uint64_t, too. I'm not sure what the advantage is of returning separate file descriptors, and nit operating directly on the pidfd.