On Fri, Sep 4, 2020 at 4:41 AM Adalbert Lazăr <alazar@xxxxxxxxxxxxxxx> wrote: > > This patchset adds support for the remote mapping feature. > Remote mapping, as its name suggests, is a means for transparent and > zero-copy access of a remote process' address space. > access of a remote process' address space. > I think this is very clever, but I find myself wondering what happens if people start trying to abuse this by, for example, setting up a remote mapping pointing to fun regions like userfaultfd or another remote mapping. I'm a little concerned that it's actually too clever and that maybe a more straightforward solution should be investigated. I personally rather dislike the KVM model in which the guest address space mirrors the host (QEMU) address space rather than being its own thing. In particular, the current model means that extra-special-strange mappings like SEV-encrypted memory are required to be present in the QEMU page tables in order for the guest to see them. (If I had noticed that last bit before it went upstream, I would have NAKked it. I would still like to see it deprecated and ideally eventually removed from the kernel. We have absolutely no business creating incoherent mappings like this.) --Andy