Hi,

I have recently contributed to update the VirtualBox port in the FreeBSD ports tree [1].

We have a bunch of patches there to make it work with recent FreeBSD versions. I'd like to have those integrated in the official sources at some point, but I know some cleanup and review process is required to achieve this.

So I'm starting with a simple patch that I'm attaching here and can also be found at [2].

While testing version 6.1.18 in FreeBSD, VBoxNetDHCP was observed hanging and becoming unkillable and causing panics at system shutdown.

I have noticed that since version 5.2.x the code related to that binary has been fundamentally rewritten, but looking at the changes I noticed the method pumping packets through it remained similar, but while in the past the system call to get packets was performed with a timeout now it is called without any. Changing this little detail like this patch does, and reinstating the same 2 seconds timeout fixed the problem for us.

I'd like this patch to be included in official virtualbox sources and I contribute it according to the MIT license.

As stated above more patches need to be merged but before proposing them I need to clean them up a little and also group some of them by subject and not by patched file like the ports tree does. Next thing I plan to propose is a patch with all the "#if __FreeBSD_version" changes bundled together.

Thanks in advance!


[1] https://svnweb.freebsd.org/changeset/ports/567950

[2] https://people.freebsd.org/~madpilot/VBoxNetDhcpd.diff

--
Guido Falsi <[email protected]>
Index: src/VBox/NetworkServices/Dhcpd/VBoxNetDhcpd.cpp
===================================================================
--- src/VBox/NetworkServices/Dhcpd/VBoxNetDhcpd.cpp	(revision 87670)
+++ src/VBox/NetworkServices/Dhcpd/VBoxNetDhcpd.cpp	(working copy)
@@ -394,7 +394,7 @@
         WaitReq.Hdr.cbReq = sizeof(WaitReq);
         WaitReq.pSession = m_pSession;
         WaitReq.hIf = m_hIf;
-        WaitReq.cMillies = RT_INDEFINITE_WAIT;
+        WaitReq.cMillies = 2000;
         int rc = CALL_VMMR0(VMMR0_DO_INTNET_IF_WAIT, WaitReq);
 
         /*
_______________________________________________
vbox-dev mailing list
[email protected]
https://www.virtualbox.org/mailman/listinfo/vbox-dev

Reply via email to