Skip to content

Adapt the OpenBSD hvt tender to the new vmm(4)#600

Merged
dinosaure merged 3 commits intoSolo5:masterfrom
omegametabroccolo:obsd-curr-fix
Sep 23, 2025
Merged

Adapt the OpenBSD hvt tender to the new vmm(4)#600
dinosaure merged 3 commits intoSolo5:masterfrom
omegametabroccolo:obsd-curr-fix

Conversation

@omegametabroccolo
Copy link
Contributor

@omegametabroccolo omegametabroccolo commented Jul 27, 2025

For now, this PR only works on -current and breaks released versions of OpenBSD. AFAICT there is no way to know at compile time if we're on -current or not, but we can check the latest released version with the OpenBSD macro from <sys/param.h>. We could wait until OpenBSD 7.8 is released to add some #if OpenBSD >= [7.8 version number] and support both 7.8 and earlier releases, as suggested in #598.

- VM memory allocation is now handled by vmm(4)
- VMM_IOC_MPROTECT_EPT has been dropped some time ago, vmm(4) handles this now

This commit breaks releases of OpenBSD (7.7 and before)
@hannesm
Copy link
Contributor

hannesm commented Sep 23, 2025

I wonder if there's anything we can have the conditional on, e.g. if we're <= 7.7 retain the current code, otherwise use this new code?

@dinosaure
Copy link
Collaborator

I wonder if there's anything we can have the conditional on, e.g. if we're <= 7.7 retain the current code, otherwise use this new code?

I will agree with that.

@hannesm
Copy link
Contributor

hannesm commented Sep 23, 2025

See omegametabroccolo#1 (which should work since openbsd/src@ca6cf18)

EDIT: please note I didn't compile that commit, please check if it works :)

@dinosaure
Copy link
Collaborator

Thanks, if @omegametabroccolo is happy, I can cherry-pick the commit and merge it.

@omegametabroccolo
Copy link
Contributor Author

Yes that works, thanks!

@dinosaure
Copy link
Collaborator

Thanks both!

@dinosaure dinosaure merged commit a4df083 into Solo5:master Sep 23, 2025
dinosaure added a commit to dinosaure/opam-repository that referenced this pull request Sep 23, 2025
- Fix `test_ssp` on OpenBSD (@omegametabroccolo, Solo5/solo5#599)
- Fix build of hvt on aarch64 (Solo5/solo5#601, @cmainas)
- Adapt OpenBSD hvt tender with the new `vmm(4)` (@omegametabroccolo, @hannesm, Solo5/solo5#600)
dinosaure added a commit to dinosaure/opam-repository that referenced this pull request Sep 23, 2025
- Fix `test_ssp` on OpenBSD (@omegametabroccolo, Solo5/solo5#599)
- Fix build of hvt on aarch64 (Solo5/solo5#601, @cmainas)
- Adapt OpenBSD hvt tender with the new `vmm(4)` (@omegametabroccolo, @hannesm, Solo5/solo5#600)
dinosaure added a commit to dinosaure/opam-repository that referenced this pull request Oct 27, 2025
- Fix compilation on OpenBSD about `#ifdef` (@omegametabroccolo, @hannesm, @reynir, Solo5/solo5#614, related with Solo5/solo5#600)
- Add GitHub actions to test Solo5 on different platforms (@hannesm, Solo5/solo5#616, Solo5/solo5#617 & Solo5/solo5#540)
- Do not use `-Wstringopt-overflow` when we use `clang` for `test_ssp` (@hannesm, Solo5/solo5#607)
- Show errors and exit instead of `assert false` (@shym, @edwintorok, @hannesm, @reynir, Solo5/solo5#613 & Solo5/solo5#612)
- Define `.note.GNU-stack` when it's needed (@shym, @Kensan, @hannesm, @palainp, @dinosaure, Solo5/solo5#619, Solo5/solo5#570 & Solo5/solo5#562)
- Detect MTU on TAP interface for hvt, spt and virtio (@reynir, @hannesm, @dinosaure, Solo5/solo5#605 & Solo5/solo5#606)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants