cca384e4 | 20-Jul-2021 |
Aaron LI <aly@aaronly.me> |
nvmm: Fix comm page unmapping issue by doing it on userland side
Previously, we're mapping and unmapping the comm page for userland process both on the kernel side. The unmapping was called at the
nvmm: Fix comm page unmapping issue by doing it on userland side
Previously, we're mapping and unmapping the comm page for userland process both on the kernel side. The unmapping was called at the point of closing the fd.
However, the kernel may destroy process' vmspace before or after closing the fd, so there is no guarantee that kernel can get the correct address space to unmap the comm page for the userland process. Therefore, do the comm page unmapping on the userland side in libnvmm to fix the above issue.
In addition, add the 'comm_size' member to 'struct nvmm_capability' to expose the comm page size to userland, which is required for the unmapping operation. This breaks ABI, so bump NVMM_KERN_VERSION. Update nvmmctl(8) accordingly to print the comm page size.
This commit partially reverts: "nvmm: Add missing comm page unmapping"
show more ...
|