Solved BSD hypervisor

Whether there's an SVM setting in the BIOS or not is immaterial. All the setting does is enable a bit in the MSR, which can be enabled by FreeBSD in svm_modinit(), by calling svm_enable(), anyway.

But this is not the only feature bhyve requires. It requires the popcnt instruction. Older Intel and AMD processors don't support it. AMD started supporting the popcnt instruction in Phenom II. You can tell if your processor supports bhyve by checking dmesg | egrep 'VT-x|SVM|POPCNT'. For Intel you should see VT-x and POPCNT. For AMD you should see SVM and POPCNT.

dmesg | egrep 'VT-x|SVM|POPCNT'
Features2=0x7ed8320b<SSE3,PCLMULQDQ,MON,SSSE3,FMA,CX16,SSE4.1,SSE4.2,MOVBE.POPCNT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND>
AMD Features2=0x35c233ff<LAHF,CMP,SVM,ExtAPIC,CR8,ABM,SSE4A,MAS,Prefetch,OSVW,SKINIT,WDT,TCE,Topology,PCXC,PNXC,DBE,PL2I,MWAITX>
SVM: (disabled in BIOS) NP,NRIP,VClean,AFlush,DAssist,NAsids=32768
SVM: disabled by BIOS.

The processor's features2 include SVM and POPCNT, says SVM is disabled in BIOS, there is no information about the status of POPCNT, though it shows POPCNT. Please tell me the exact command to enable SVM and (POPCNT ?) by svm_modinit() and how to call svm_enable() and where I should say that.

Thank you cy@
 
  • Like
Reactions: cy@
dmesg | egrep 'VT-x|SVM|POPCNT'


The processor's features2 include SVM and POPCNT, says SVM is disabled in BIOS, there is no information about the status of POPCNT, though it shows POPCNT. Please tell me the exact command to enable SVM and (POPCNT ?) by svm_modinit() and how to call svm_enable() and where I should say that.

Thank you cy@
FreeBSD will enable it when you use bhyve. svm_modinit() and svm_enable() are how FreeBSD does it.

Personally, I enable it in my server machines' BIOSen downstairs. Just a clean and healthy living kind-of thing. My laptop has no such setting.

If it still doesn't work, there may be something else it may not like. Open up a PR and one of the bhyve developers may be able to figure it out. If it's a bug they'll be able to fix it. Check this out first.
 
FreeBSD will enable it when you use bhyve. svm_modinit() and svm_enable() are how FreeBSD does it.

If it still doesn't work, there may be something else it may not like. Open up a PR and one of the bhyve developers may be able to figure it out. If it's a bug they'll be able to fix it. Check this out first.

cy@ Thank you. Where do I have to specify bhyve. svm_modinit() and svm_enable() ? And what is the exact syntax please?

Also found this document while searching for sv_modinit and svm_enable. Appears to be full set of instructions. Need to understand what to uncomment and what file to edit.

If I have to, how do I "Open up a PR" ? Would be helpful if you could share with me the URL. (Thank you for the link to bhyve wiki, there is a wealth of information)
 
cy@ Thank you. Where do I have to specify bhyve. svm_modinit() and svm_enable() ? And what is the exact syntax please?

Also found this document while searching for sv_modinit and svm_enable. Appears to be full set of instructions. Need to understand what to uncomment and what file to edit.

If I have to, how do I "Open up a PR" ? Would be helpful if you could share with me the URL. (Thank you for the link to bhyve wiki, there is a wealth of information)
You don't need to specify anything svm_modinit() and svm_enable() are kernel functions (subroutines). They figure this out for you.

To open a PR (problem report), go to FreeBSD Bugzilla. Click on the appropriate hyperlink, port bug, base system bug, or documentation bug, and fill in the fields. Be as specific as you can regarding the bug or your question. Open endedness leaves people wondering and may result in the bug not picked up by anyone.

Also, remember this is a volunteer project. It's not like you're opening a bug as a paid customer for software in which maintenance fees are paid. We're all working on this together. Most of us have full time jobs outside of our FreeBSD time. (Though some lucky people have employers who support their work on FreeBSD. Not all of us do.)
 
You don't need to specify anything svm_modinit() and svm_enable() are kernel functions (subroutines). They figure this out for you.

To open a PR (problem report), go to FreeBSD Bugzilla. Click on the appropriate hyperlink, port bug, base system bug, or documentation bug, and fill in the fields. Be as specific as you can regarding the bug or your question. Open endedness leaves people wondering and may result in the bug not picked up by anyone.

Also, remember this is a volunteer project. It's not like you're opening a bug as a paid customer for software in which maintenance fees are paid. We're all working on this together. Most of us have full time jobs outside of our FreeBSD time. (Though some lucky people have employers who support their work on FreeBSD. Not all of us do.)

A while later I enabled svm in bios, installed bhyve and three is a debian vm and a ubuntu vm working. Resolved. Thank you.
 
Back
Top