History log of /openbsd/usr.sbin/vmd/loadfile.h (Results 1 – 17 of 17)
Revision Date Author Comments
# 73a98491 25-Apr-2023 dv <dv@openbsd.org>

vmm(4)/vmd(8): pull struct members out of vmm ioctl create struct.

The object sent to vmm(4) contained file paths and details the
kernel does not need for cpu virtualization as device emulation is
i

vmm(4)/vmd(8): pull struct members out of vmm ioctl create struct.

The object sent to vmm(4) contained file paths and details the
kernel does not need for cpu virtualization as device emulation is
in userland. Effectively, "pull up" the struct members from the
vm_create_params struct to the parent vmop_create_params struct.

This allows us to clean up some of vmd(8) and simplify things for
switching to having vmctl(8) open the "kernel" file (SeaBIOS, bsd.rd,
etc.) to allow users to boot recovery ramdisk kernels.

ok mlarkin@

show more ...


# 3227aa04 30-Dec-2021 claudio <claudio@openbsd.org>

Add back support for -B net -b bsd.rd which emulates a PXE install and
results in an autoinstall. This can be used to quickly create new OpenBSD
installs.
OK dv@


# 6eb4c859 16-Jun-2021 dv <dv@openbsd.org>

cleanup vmd(8) includes and header files

Lots of organic growth other the years lead to unnecessary includes
(proc.h everywhere) and odd dependencies between header files. This
cleans things up a bi

cleanup vmd(8) includes and header files

Lots of organic growth other the years lead to unnecessary includes
(proc.h everywhere) and odd dependencies between header files. This
cleans things up a bit to help with upcoming cleanup around dhcp
code.

No functional change.

"go for it" mlarkin@

show more ...


# 45bdc46f 05-Apr-2021 dv <dv@openbsd.org>

Support booting from compressed kernel images.

The bsd.rd ramdisk now ships gzip'd on amd64. Use libz in base to
transparently handle decompression of any compressed kernel images.

Patch from Josh

Support booting from compressed kernel images.

The bsd.rd ramdisk now ships gzip'd on amd64. Use libz in base to
transparently handle decompression of any compressed kernel images.

Patch from Josh Rickmar.

ok kn@

show more ...


# a13de4d1 19-Mar-2021 kn <kn@openbsd.org>

Remove booting from kernels in raw/qcow2 images

Diff and (slightly tweaked) text below from
Dave Voutila < dave at sisu dot io >, thanks!

--
Since 6.7 switched to FFS2 as the default filesystem for

Remove booting from kernels in raw/qcow2 images

Diff and (slightly tweaked) text below from
Dave Voutila < dave at sisu dot io >, thanks!

--
Since 6.7 switched to FFS2 as the default filesystem for new installs,
the ability for vmd(8) to load a kernel and boot.conf from a disk image
directly (without SeaBIOS) has been broken.

A diff from tb to add FFS2 support never mdae it into the tree.

On 5th Jan 2021, new ramdisks for amd64 have started shipping gzipped,
breaking the ability to load the bsd.rd directly as a kernel image for a vmd
guest without first uncompressing the image.

Using BIOS works, the FFS2 change happend ten months ago and few if any have
complained about the breakage. vmctl(8) is still vague about supporting it
per its man page and one still has to pass the disk image twice as a "-b"
and "-d" argument to boot an OpenBSD guest *without* BIOS.

Josh Rickmar reported the gzip issue on bugs@ and provided patches to add
support for compressed ramdisks and kernel images. The easiest way to do so
is to drop support for FFS images since they require a call to fmemopen(3)
while all the other logic uses fopen(3)/fdopen(3) calls and a file
descriptor. It is much easier to get thsoe patches merged if they don't
have to account for extracting files from disk images.
--

No objections anyone
"Removing it makes sense" reyk (who wrote the FFS module)
OK mlarkin

show more ...


# 65d68140 16-May-2019 claudio <claudio@openbsd.org>

Unbreak vmctl start foo -b /bsd -d disk.img -cL
Define a local definition of LOADADDR() instead of pulling in
machine/loadfile_machdep.h. vmd -b requires the addresses to be masked
and the new bootlo

Unbreak vmctl start foo -b /bsd -d disk.img -cL
Define a local definition of LOADADDR() instead of pulling in
machine/loadfile_machdep.h. vmd -b requires the addresses to be masked
and the new bootloader no longer does that.
OK pd@ kettenis@

show more ...


# cc104512 06-Dec-2018 claudio <claudio@openbsd.org>

Make it possible to define the bootdevice in vmd. This information is used
currently only when booting a OpenBSD kernel. If VMBOOTDEV_NET is used the
internal dhcp server will pass "auto_install" as

Make it possible to define the bootdevice in vmd. This information is used
currently only when booting a OpenBSD kernel. If VMBOOTDEV_NET is used the
internal dhcp server will pass "auto_install" as boot file to the client and
the boot loader passes the MAC of the first interface to the kernel to indicate
PXE booting. Adding boot order support to SeaBIOS is not yet implemented.
Ok ccardenas@

show more ...


# c96d1163 29-Nov-2017 mlarkin <mlarkin@openbsd.org>

make vmm(4) less responsible for initial register state, preferring to let
usermode daemons handle that.

ok pd@


# 8461863e 07-Jun-2017 mlarkin <mlarkin@openbsd.org>

vmd: properly advertise 640k base memory, not 636k. That was a holdover
from before we had seabios support (to fake a hole where the EBDA would
be), and seabios always assumes 640k low memory is avai

vmd: properly advertise 640k base memory, not 636k. That was a holdover
from before we had seabios support (to fake a hole where the EBDA would
be), and seabios always assumes 640k low memory is available. Fixes a
problem where FreeDOS guests whose seabios placed the virtio ring too
close to 640k would crash vmd. tested on a variety of guest OS, with
and without seabios. no regressions seen.

show more ...


# 38d0e0c3 25-Mar-2017 reyk <reyk@openbsd.org>

Boot using BIOS from /etc/firmware/vmm-bios by default.

Instead of using the internal "vmboot", VMs will now be booted using
the external BIOS firmware in /etc/firmware/vmm-bios (which is subject
to

Boot using BIOS from /etc/firmware/vmm-bios by default.

Instead of using the internal "vmboot", VMs will now be booted using
the external BIOS firmware in /etc/firmware/vmm-bios (which is subject
to a LGPLv3 license). Direct booting of OpenBSD kernels or
non-default BIOS images is still supported for now using the -b/boot
option that is replacing the -k/kernel option.

As requested by Theo, vmd(8) fails if neither the default BIOS is
found nor a kernel has been specified in the VM configuration. The
"vmm" BIOS has to be installed using fw_update(1), which will be done
automatically in most cases where the OpenBSD can fetch it after
install/upgrade.

OK mlarkin@

show more ...


# 07052635 26-Nov-2016 reyk <reyk@openbsd.org>

Implement basic support for boot.conf(8) on the disk image.

Like the real boot loader, load and parse hd0a:/etc/boot.conf from the
first disk and fall back to /bsd. Not all boot loader options are

Implement basic support for boot.conf(8) on the disk image.

Like the real boot loader, load and parse hd0a:/etc/boot.conf from the
first disk and fall back to /bsd. Not all boot loader options are
supported, but it at least does set device, set image, and boot -acds
(eg. for booting single-user).

For example, it can now boot install60.fs that includes a boot.conf
with "set image /6.0/amd64/bsd.rd":
vmctl start install -c -d install60.fs -d OpenBSD.img

This pseudo-bootloader is only needed without BIOS and could
potentially be replaced in the future.

OK mlarkin@

show more ...


# 82fb2f0a 24-Nov-2016 reyk <reyk@openbsd.org>

Add support for booting the kernel from the disk image.

This make the kernel/-k argument optional and, if not specified, tries
to find the /bsd kernel in the primary hd0a partition of the first
disk

Add support for booting the kernel from the disk image.

This make the kernel/-k argument optional and, if not specified, tries
to find the /bsd kernel in the primary hd0a partition of the first
disk image itself. It doesn't support hd0a:/etc/boot.conf yet, and it
is no BIOS or full boot loader, but it makes booting and handling of
VMs a bit easier - booting an external kernel is still supported.

The UFS file system code ufs.c is directly from libsa which is also
used by the real boot loader. The code compiles with a few signedness
warning which will be fixed separately.

OK mlarkin@

show more ...


# 11fac253 01-Sep-2016 stefan <stefan@openbsd.org>

Make vcpu_reset_regs use new writeregs code

Makes reset code a little simpler. ok mlarkin@


# fc059887 05-Apr-2016 mlarkin <mlarkin@openbsd.org>

Support processors without unrestricted guest capability.

ok stefan


# 40a3b6a0 13-Mar-2016 stefan <stefan@openbsd.org>

Introduce memory ranges to support VMs with >= 4G RAM

Kernel bits:
- When creating a VM, a list of memory ranges has to be specified,
similar to the BIOS memory map. This is necessary for VMs with

Introduce memory ranges to support VMs with >= 4G RAM

Kernel bits:
- When creating a VM, a list of memory ranges has to be specified,
similar to the BIOS memory map. This is necessary for VMs with
RAM sizes approaching 4G because we'll need PCI MMIO space in
the higher parts of the 32 bit address space.

vmctl and vmd bits:
- Construct appropriate memory ranges to create a VM with a given
RAM size
- Construct a corresponding BIOS memory map from the memory ranges
and update the boot params page accordingly.
- Make sure that all variables that represent guest physical addresses
match the address width of the target CPU instead of using uint32_t.
- Fix some integer promotion glitches that actually restricted VM
RAM size to 2G.

This changes the VM create ioctl interface, so update your kernel,
vmd, and vmctl.

ok mlarkin@

show more ...


# 3475ba91 17-Dec-2015 mlarkin <mlarkin@openbsd.org>

Move vcpu register state init to vmd. Allows vmd bootloader to make the
decision as to how the vcpu should be set up for initial start and
reset. Also removes some hardcoded register constants from v

Move vcpu register state init to vmd. Allows vmd bootloader to make the
decision as to how the vcpu should be set up for initial start and
reset. Also removes some hardcoded register constants from vmm(4).

ok jsing@, mpi@

show more ...


# f3c0184a 22-Nov-2015 mlarkin <mlarkin@openbsd.org>

vmd(8) - virtual machine daemon.

There is still a lot to be done, and fixed, in these userland components
but I have received enough "it works, commit it" emails that it's time
to finish those thing

vmd(8) - virtual machine daemon.

There is still a lot to be done, and fixed, in these userland components
but I have received enough "it works, commit it" emails that it's time
to finish those things in tree.

discussed with many, tested by many.

show more ...