Date: Thu, 26 Jul 2012 16:11:42 -0700 From: Xin Li <delphij@delphij.net> To: nvangogh <nvangoghs@gmail.com> Cc: freebsd-drivers@freebsd.org Subject: Re: Precisely what hardware information is required? Message-ID: <5011CEAE.1070608@delphij.net> In-Reply-To: <50018B36.4000207@gmail.com> References: <50018B36.4000207@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 07/14/12 08:07, nvangogh wrote: > Hello, I am a novice as far as FreeBSD is concerned. However, I am > interested in device driver development methodology and code. > > My question relates specifically to a particular wireless chipset > for wifi. There is currently no device driver available under > FreeBSD for the RTL 8191 SE chipset. Realtek have a web page > explaining the features of the chip in general terms. There is > source code available for certain linux distributions. Now I > understand that it would be impossible to build such source code on > FreeBSD. > > However, according to the documentation, the source code is divided > into two parts i.e : > > 1. Firmware for the chip. There is a folder that contains 7 small > files (on average 70kb) and they end with .bin.fw - I believe that > these are the files containing assembly code for the chipset. How > would one go about writing such code from scratch, with only > general information about the driver? Would it be necessary to have > technical information such as the number of registers in the > chipset and eg how they interact? Or Is there a generic codebase of > 'firmware' that will work with most wifi chipsets? What does the > firmware actually do? Normally you don't rewrite firmware (many of the times the source of firmware are not disclosed by the way). From the driver standpoint, firmwares are opaque and hides the detail of underlying hardware, generally speaking, they simplify or offload the work of the OS driver and sometimes can workaround bugs of hardware design, etc., and most firmware are loaded at the time we initialize the hardware. If you want to redistribute the driver with FreeBSD, vendor permission will be required. FreeBSD is flexible wrt firmware, as long as we can distribute the binary, it's fine. Of course, it would be nice if the vendor would agree to redistribute the firmware in source code form, however, they may have reasons to refuse it and it's not a requirement. > 2. Source code. This is written in c. At this stage I have no > questions about it. Cheers, - -- Xin LI <delphij@delphij.net> https://www.delphij.net/ FreeBSD - The Power to Serve! Live free or die -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJQEc6uAAoJEG80Jeu8UPuzJfsH+QF2HuvU4Os9tywbl1hdVJb9 vt2crOb1Yv5zX7of2yLpvA2mZsalaeGwj4v7AAsHozBBSy4q/eXy70F74W7O7IGp ta5+AEYN3lgVNxteIezCxmUu0klKLkoROrxGYKnFW+YK4hjJuwySwDwQv7xTBU4t cSbe+O3Biqu8sUCawBFHeF9DVUiOQ1AJwSrIIIBHEaCDsYRsg20sXV1PCN0ujR52 mGEa7mA/detiyoDBsBedlFZrDVVC/phkH8qrxfUDiS4/lgzYXXDdBdQ3WUyagdWV RQmVEowOvlkWqal60EYlFOJMBoNJ+h5GDoIX4YCXAM6O3+X1YLZDKPx2nPMQ9DM= =T3Z1 -----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5011CEAE.1070608>