bhyve: change suspend exit code
Currently, after suspending, bhyve(8) exits with 0. This code is also used to indicate that a VM was rebooted. To differentiate reboot and suspend, use the next available exit code, 5, for suspend. Approved by: markj Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D54087
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd October 28, 2025
|
||||
.Dd December 4, 2025
|
||||
.Dt BHYVE 8
|
||||
.Os
|
||||
.Sh NAME
|
||||
@@ -1158,6 +1158,8 @@ halted
|
||||
triple fault (amd64 only)
|
||||
.It 4
|
||||
exited due to an error
|
||||
.It 5
|
||||
suspended
|
||||
.El
|
||||
.Sh EXAMPLES
|
||||
If not using a boot ROM, the guest operating system must have been loaded with
|
||||
|
||||
@@ -1308,7 +1308,7 @@ vm_checkpoint(struct vmctx *ctx, int fddir, const char *checkpoint_file,
|
||||
|
||||
if (stop_vm) {
|
||||
vm_destroy(ctx);
|
||||
exit(0);
|
||||
exit(5);
|
||||
}
|
||||
|
||||
done:
|
||||
|
||||
Reference in New Issue
Block a user