Haiku Getting a FreeBSD Network Driver Compatibility Layer
Here is a quote from Hugo himself: "My original goal was to enable the use of FreeBSD drivers by just having them compiled 'as is' by the build system. This is possible with some drivers, but not all; but even for those that may require some changes in the code, the modification requirements will be minimal (most likely related to interrupt handling). The idea was to make it easy to upgrade the drivers with fixes from FreeBSD and/or upgrade to newer versions. Developing drivers can be a hard job, and developing bug free drivers even more so. The ability to use FreeBSD drivers with little to no changes in the code expands Haiku's hardware support with little burden to our pool of developers, which is a good thing. By the way, this idea was inspired by Marcus Overhagen's ipro1000 driver, which is Intel's FreeBSD driver ported to Haiku using a very specific compatibility layer."
To achieve his goal, Hugo started by copying the functions necessary for drivers from FreeBSD and creating a compatibility library. As he tried more drivers, he added more functions to the library. The Intel Pro Express 100 driver (fxp) was used as a base for requirements; Hugo then wrote Haiku-specific versions of some of these functions and changed others as required. Some original FreeBSD code is also used, as well as some of Marcus' code.
This is still work in progress and, by Hugo's own words, there is a lot more to be done and tested. Nevertheless, this is a great addition to Haiku and we are all grateful for Hugo's significant contributions.