Historically, subsystems (drivers, etc.) were supposed to deliver on both SPARC and x86 platforms (and now amd64 as well) unless a really good argument was supplied. While I've long been a supporter of this philosophy, I think a time is coming to consider making a specific policy exception.
The problem I'm running into is with legacy PCI devices. Some of these legacy PCI devices can work SPARC. But devices that don't support 66 MHz frequently (but not always) have problems on SPARC workstations. The biggest problem is that many SPARC workstations have 32-bit 33 MHz slots that don't supply 3.3V. This affects quite a number of cards that require 3.3V power to operate. Some devices will operate with only 5V, but only marginally. I've seen a number of failures that I think can be traced to this problem, and now I don't recommend using PCI devices not specifically qualified for these platforms with SPARC systems. (Sun makes that same recommendation, btw.)
Furthermore, identifying suitable SPARC hardware can be a challenge. SPARC systems these days are slower than their x86 counterparts, yet for the most part remain more expensive, and there are few inexpensive options available for open source developers. And, SPARC desktop systems are effectively off the market -- Sun doesn't have any current SPARC desktop models for sale, and that's not likely to change anytime soon.
So what I'd like to propose is a policy change that recommends authors working on drivers for legacy PCI cards be given a blanket waiver for SPARC delivery. (Examples are recent NIC drivers such as "vr", "sfe", and "bfe", and audio hardware such as "audiopci", "audiocmi", and perhaps in the future drivers for Creative Audigy cards.)
I still believe that developers working with modern PCIe devices should deliver both SPARC and x86 binaries though. PCIe is available on last generation SPARC desktop (Ultra 25/45) hardware as well as current generation server products.
Saturday, June 6, 2009
driver private headers
Some may have noticed in a few of my changes lately that I'm moving some header files around. This post explains the change (and encourages others to do the same).
Header files that are only useful to one subsystem (a kernel module, or driver, for example) should, IMO, only be located in the subsystem for which they are used. For example, do we really need to ship a header file in /usr/include/sys/ that has all the register definitions for the DEC tulip ethernet (dnet.h)? Wouldn't it be sufficient to have those definitions just where they belong, alongside the source for the dnet driver itself?
Locating the files for such subsystems in their own directory instead of a common directory (e.g. common/io/dnet/dnet.h instead of common/sys/dnet.h) has several positive ramifications:
The upshot of all this is that a bunch of driver-private header files have been slowly moving out of uts/common/sys/ and into better locations. Hopefully other driver developers will consider doing the same.
Header files that are only useful to one subsystem (a kernel module, or driver, for example) should, IMO, only be located in the subsystem for which they are used. For example, do we really need to ship a header file in /usr/include/sys/ that has all the register definitions for the DEC tulip ethernet (dnet.h)? Wouldn't it be sufficient to have those definitions just where they belong, alongside the source for the dnet driver itself?
Locating the files for such subsystems in their own directory instead of a common directory (e.g. common/io/dnet/dnet.h instead of common/sys/dnet.h) has several positive ramifications:
- It makes it readily apparent that the header file has no content needed outside of the kernel or subsystem. So changes can be more freely made (no userland dependencies, for example.)
- The header file is not delivered to customers (except as part of the entire source code), shrinking the amount of disk space consumed on development workstations.
- No exceptions entry is required to suppress the file from delivery - so the file is referenced in fewer places. (Fewer places to change if the file needs to move, be removed, etc.)
- The header file is easier for humans to locate with the source.
- The header file is faster for the compiler to locate -- it will be in the first directory searched - slightly faster build times. (If enough subsystems do this, it might start to make a noticeable improvement.)
- The common include directory becomes slightly more manageable with each such change. (Big directories with hundreds of files are awkward.)
- The file can't be used/abused by other subsystems (at least not without making such abuse obvious), because it really is in a private directory.
The upshot of all this is that a bunch of driver-private header files have been slowly moving out of uts/common/sys/ and into better locations. Hopefully other driver developers will consider doing the same.
Friday, June 5, 2009
driver.conf files considered evil
Just a quick note on driver.conf files that some device drivers deliver.
I believe that driver.conf files, and the tunables that are usually put in them, are for the most part, a byproduct of inadequate architecture The average driver should use no tunables in driver.conf properties.
As a result, I've started going out of my way to remove driver.conf files from device drivers for which I'm responsible. I think that even the "advanced" tunables (such as the interrupt rate used for audio drivers) falls outside the scope of what users should normally tune, and that delivering a configuration file is actively harmful.
One of Solaris' great strengths historically has been the approach to "self-tuning", so that lots of configuration is not necessary. I'd like to see that continue. The next time you think about adding a driver.conf property, consider carefully if there might not be a better solution. (Either self tuning, providing a default that works for everyone or nearly everyone, or using another system like Brussels to provide configuration overrides.)
(PCI devices in particular are very painful to configure with driver.conf... see the pci man page to find out why!)
I believe that driver.conf files, and the tunables that are usually put in them, are for the most part, a byproduct of inadequate architecture The average driver should use no tunables in driver.conf properties.
As a result, I've started going out of my way to remove driver.conf files from device drivers for which I'm responsible. I think that even the "advanced" tunables (such as the interrupt rate used for audio drivers) falls outside the scope of what users should normally tune, and that delivering a configuration file is actively harmful.
One of Solaris' great strengths historically has been the approach to "self-tuning", so that lots of configuration is not necessary. I'd like to see that continue. The next time you think about adding a driver.conf property, consider carefully if there might not be a better solution. (Either self tuning, providing a default that works for everyone or nearly everyone, or using another system like Brussels to provide configuration overrides.)
(PCI devices in particular are very painful to configure with driver.conf... see the pci man page to find out why!)
Friday, May 29, 2009
audiocmi webrev posted
I've posted a webrev for the audiocmi driver. This driver supports CMI 8738 and similar parts. This is for Boomer, and I hope to get it integrated into build 117. If you want to test a binary, drop me an e-mail!
Thursday, May 28, 2009
spwr opensource and GLDv3?
If you'd like the spwr driver to be open sourced and GLDv3 compliant (with VLAN support, link notification, dladm and ndd support, and the rest of the goodies), and have a few spare cards that you can give me, please feel free to contact me. I'm willing to do the work as a side project.
I'm also interested in obtaining 100Base-X fiber cards, and fiber cables (VF45 format), especially if someone also has access to the 3M VOL-N100VF+TX card (which is theoretically supported by "afe", but which I'm not entirely convinced works properly because I've never actually had a card on hand that I could test!) I need cards and cable... at the moment I have neither.
Note that this is not Sun commissioned work, but an interesting side project that caught my interest. If nobody replies with hardware, then its unlikely that I'll do any of the work.
I'm also interested in obtaining 100Base-X fiber cards, and fiber cables (VF45 format), especially if someone also has access to the 3M VOL-N100VF+TX card (which is theoretically supported by "afe", but which I'm not entirely convinced works properly because I've never actually had a card on hand that I could test!) I need cards and cable... at the moment I have neither.
Note that this is not Sun commissioned work, but an interesting side project that caught my interest. If nobody replies with hardware, then its unlikely that I'll do any of the work.
Wednesday, May 27, 2009
Going to CommunityOne After All
Well, it appears that I'll be at CommunityOne (Monday only) after all! This is going to be a fairly big event -- the big event for OpenSolaris this year, I think. I'm looking forward to the chance to meet a bunch of folks that I didn't get the chance to meet previously. Hope to see you there!
Monday, May 11, 2009
hme for x86 RTI submitted
I've just submitted the RTI for hme. If the RTI advocate approves it in time, it will be in build 115, otherwise in build 116. This will allow you to use your old PCI qfe boards with OpenSolaris on x86 systems.
It also represents a significant simplifications of the code. Thanks to the folks who've helped with testing!
It also represents a significant simplifications of the code. Thanks to the folks who've helped with testing!
Subscribe to:
Posts (Atom)