Skip to content

Commit

Permalink
Revert "KVM: doc: Document the life cycle of a VM and its resources"
Browse files Browse the repository at this point in the history
This reverts commit 919f6cd.

The patch was applied twice.
The first commit is eca6be5.

Reported-by: Cornelia Huck <cohuck@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
rkrcmar authored and bonzini committed Apr 30, 2019
1 parent da8f0d9 commit 3a1e5e4
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions Documentation/virtual/kvm/api.txt
Expand Up @@ -69,23 +69,6 @@ by and on behalf of the VM's process may not be freed/unaccounted when
the VM is shut down.


It is important to note that althought VM ioctls may only be issued from
the process that created the VM, a VM's lifecycle is associated with its
file descriptor, not its creator (process). In other words, the VM and
its resources, *including the associated address space*, are not freed
until the last reference to the VM's file descriptor has been released.
For example, if fork() is issued after ioctl(KVM_CREATE_VM), the VM will
not be freed until both the parent (original) process and its child have
put their references to the VM's file descriptor.

Because a VM's resources are not freed until the last reference to its
file descriptor is released, creating additional references to a VM via
via fork(), dup(), etc... without careful consideration is strongly
discouraged and may have unwanted side effects, e.g. memory allocated
by and on behalf of the VM's process may not be freed/unaccounted when
the VM is shut down.


3. Extensions
-------------

Expand Down

0 comments on commit 3a1e5e4

Please sign in to comment.