


Moving from Binary Drivers to Open Source? 186
GerryGilmore asks: "We are a division, specializing in telecommunications equipment, of a very large hardware manufacturer. Our equipment, DSP and PSTN boards, has been supported under Linux through a set of binary driver modules and binary libraries implementing our API set. We are in the process of migrating to a completely open source-based software infrastructure to be more in sync with the rest of the Linux industry. However, not having any real experience with moving from proprietary to an open source model, we wanted to see if the Slashdot crowd has any similar experiences to share: The Good; The Bad; The Ugly; and how best to avoid the most common pitfalls."
going.. through... withdrawals... *twitch* (Score:2, Insightful)
HELP!
I have never made a migration on a scale like this, so I have no horror stories.. but I would like to commend you and all peoples making the move to open source where possible.
Re:going.. through... withdrawals... *twitch* (Score:1, Funny)
Re:going.. through... withdrawals... *twitch* (Score:1)
Know your code (Score:5, Informative)
1) Check it is all really your code - you didn't buy any in 5 years ago? If you have a source code control system then actually being able to trace your code is great.
2) Read the comments - ok, so lots of closed source contains rather dodgy comments that you might not want to be public.
3) Check that releasing it wouldn't be revealing any information you got under NDA from any of your suppliers/partners.
Re:Know your code (Score:4, Funny)
Hehe.. very true. My favorite one:
"Sane people do things like this?"
Re:Know your code (Score:3, Funny)
What do you mean, "if"?
Re:Know your code (Score:3, Funny)
You missed the implied rest:
Sadly many companies do not use source control. CVS is free, and as been around for years not. (Not to mention all the newer systems that fix some of CVS's flaws) Doesn't mean anyone uses them.
Re:Know your code (Score:3, Funny)
Legal Issues Promote Open Source Ready Code (Score:3, Insightful)
Re:Know your code (Score:3, Insightful)
Re:Know your code (Score:3, Informative)
1) Other employees
2) Your boss
3) Your customers
I've seen some classic example of these.
Re:Know your code (Score:5, Funny)
//WARNING! We do not know what the following code does!
//But do NOT remove that extra semi-colon whatever you do
or...
//TODO: Change from inefficient inept implementation to sane one
Re:Know your code (Score:2)
Actually fixing the problems may be more work than its worth, let the community do their job...
Re:Know your code (Score:3, Funny)
/* Get the OVERFLOW attribute. (Fuck yuo, W3C. Fuck you.) */
/* Words cannot express how much HPUX SUCKS!
** This whole hacky pile of poop was done by Michael Toy.
Different sorts of dodgy (Score:2)
That doesn't mean that you wouldn't want to scrutinize the comments carefully. Profanity might not be a big issue, but sexism, racism, or homophobia would look very bad for your company, for example. Also, you might want to remove trenchant criticism of your own (or even other c
Re:Know your Comments (Score:5, Insightful)
I can think of two things to look at with respect to comments.:
First of all, you would like your comments to be meaningful, understandable and accurate. (I'm sure I could find you some juicy counter-examples in my own code).
The second thing (which, I think the grandfather post referred to) is: You might want to edit out comments like
Murphy's law says that you won't necessarily catch everything that might be embarrassing, but if only one or two nasty examples make it past the review, you can always blame it on too much coffee. If there's lots of stuff that you find on a quick audit, then you might want to delay the public release for a couple more months while you go over the code with a fine toothed comb.
If you can find some code monkeys with OpenBSD style auditing experience, then you could possibly add in cleaning up the actual code to the benefits of such an audit. This code is going to represent your company (unless you release it anonymously), so it'd be good to release the best code your resources allow you to generate.
Re:Know your Comments (Score:2)
I've found that most PR groups are a bunch of idiots who can't give up control. "You cannot use the 'official' university font or logo in any of your webpages or documents" kind of crap.
It's funny to think of handing them a million lines of source-code and asking them to check it before you release it a week later.
Re:Know your Comments (Score:2)
Re:Know your Comments (Score:3, Insightful)
As a blatant example, it's a disgrace to the school to have sports and music schedules that are 3 years old attached to "upcoming events" on the main page. Equally lame was that PR would not allow departments to post lists of classes being offered.
But I think the most absurd was that PR would not even allow the School of Business, which has profe
Re:Know your Comments (Score:2)
Obviously, you worked at a space where the PR peoplke had a serious power fixation and had implemented their plans of local domination. I'd say that the Borrd of Governors needs to jerk their chain something fierce.
codingstyle (Score:5, Interesting)
The biggest mistake is some idiot using unusual function names, spreading his driver over atleast ten files and using 2 character indents or no indentation at all.
Especially if your source is ported from windows (or the programmer has only windows experience) make sure you do this right.
Jeroen
Re:codingstyle (Score:3, Informative)
Indentation? I think not. (Score:1)
Re:Indentation? I think not. (Score:2)
Existence isn't enough: they've got to actually use indent in order for it to be useful.
2 space tab indents? (Score:3, Interesting)
Let's look at the following chunks of code;
Many would write a simple for-loop like this (using standard 8-space unexpanded tabs);
f
Re:2 space tab indents? (Score:3, Interesting)
Re:2 space tab indents? (Score:3, Informative)
What about 4 space tabs? That's IMHO the best compromise between readability & vertical space use, and what I have been using for the last 12 years.
From "Code Complete":
Nesting (Score:2)
Eek.
The only code I have to work with that's like that is a jungle of pseudo-OO spaghetti, full of 500-line-long case statements and loops. It's horrifying.
I've never yet been happy with my own code when control structures end up nested more than about 4 levels deep, except sometimes in _extremely_ localised blocks.
Re:2 space tab indents? (Score:2)
Re:2 space tab indents? (Score:3, Interesting)
Using hard coded spaces consumes more bytes and requires reformatting to change the indent. Use of Tabs is a no-brainer, but judging from the comments here and elsewhere people still don't understand the issue.
Re:2 space tab indents? (Score:5, Interesting)
Consider the following simple example, coded with spaces and 2 character indent. Now suppose, I had used tabs instead. With 2 character tabs, it would look the same.
But, someone else who prefers 4 character tabs, opens the source in their editor, and gets: If you're going to standardise on using tabs for indentation, you need to distinguish between indentation and alignment and use tabs for indentation and spaces for alignment
So in my exmaple, you would need to write: It's hard enough sometimes to get programmers to follow coding standards where the difference is visible to them, but trying to enforce a mixture of tabs and spaces like this when the editor does not make it easy to differentiate between them is almost impossible.
It's much easier to just standardise on spaces everywhere.
Re:2 space tab indents? (Score:2)
Deep nesting (Score:2)
Of course, that's the viewpoint of someone who doesn't use two-space indenting
I'll use whatever the code I'm working on uses reasonably comfortably though. I currently regularly work on code with:
<ul>
<li>4-spaces-indenting with a tabstop of 8</li>
<li>4-spaces-indenting with a ta
Re: (Score:3, Informative)
Re:codingstyle (Score:3, Insightful)
The same with your second point. While just dumping crap on the doorstep might make you a few friends you won't get the same kind of welcome as when you release nice clean code and play along with the other kids.
Jeroen
Open source is more than Linux (Score:5, Interesting)
This may be really useful for sales, but it may also lead to a serious amount of bug finding!
Are you really sure you want your device drivers debugged?
Re: (Score:3, Insightful)
Re:Open source is more than Linux (Score:3, Interesting)
It makes me wonder why more hardware manufacturers aren't asking this very question, and why anybody making new devices wouldn't open their driver code from the beginning. I mean if you make hardware, and you write software to run it on at least one platform, what is the point in making it hard for people to port the software to another platform? Isn't your profit margin in the sales of the hardwa
Re:Open source is more than Linux (Score:1)
Re:Open source is more than Linux (Score:3, Informative)
Re:Open source is more than Linux (Score:2)
Well, that certainly wasn't true for winmodems. Often very cheap hardware is just a proxy for the software that runs it... Now, as the hardwaare gets more complex and capable, then what you say becomes more true.
Place to Ask (Score:2, Informative)
Many vendors have been moving from proprietary to open source. You can join LKML at http://www.kernel.org/.
Avoid closed source coding conventions (Score:3, Funny)
for (i=0;i10;i++) {
switch(i) {
case 1:
case 2:
case 3:
}
}
Re:Avoid closed source coding conventions (Score:2)
but, any section of a program that would use that without any breaks in there would probably be just about impossible to understand anyways.
Re:Avoid closed source coding conventions (Score:1)
If you find that interesting you'll love seeing Duff's Device [lysator.liu.se] - a useful form of the switch statement with no breaks.
(Used for loop unrolling).
Re:In answer to your sig... (Score:2)
that would work in linux too, but you can have
Aside from that, you are correct, though.
Re:In answer to your sig... (Score:1)
You assume I care about my users. I am BOFH, hear me roar
Re:Avoid closed source coding conventions (Score:2)
Re:Avoid closed source coding conventions (Score:2)
Re:Avoid closed source coding conventions (Score:2)
Re:Avoid closed source coding conventions (Score:2)
Make it completely open... (Score:5, Insightful)
Make sure that you release all documentation and tools (preferably with source) for the hardware and the drivers. The last thing a "free" developer wants to do is re-invent all of the wheels that your company created.
Provide Good Documentation
If you provide well organized and complete documentation to a quality product, developers will most likely flock to it.
Support the Developers
You will want to have staff on hand to answer questions about the technical details of the product. Create a forum that is monitored by the engineers who designed and create code for the product. Make sure that questions are answered thoroughly and quickly.
Code (Score:4, Funny)
Re:Code (Score:1)
Re:Code (Score:2)
No, it goes like this:
Don't jump into this. (Score:5, Insightful)
Sweep through the code to make it/make sure it is readable. This will attract more developers to your project.
Open a project. Still release the binary drivers, just let people get into the code and start making the fixes for the bugs they find. Once it's sufficiently linux-ized by members of the linux community, switch them to your main drivers instead of your binary drivers.
Your binary drivers work right now (I assume), so leave them as your defaults, until the open source community can go in, change, break, fix and test out your open source drivers with you.
And thanks for your future contributions to the comunity. Please post a follow up when they do go open source. This will generate more interest in your products, and I, and many other admins who are part the decision making process of picking hardware for their companies, will definately give your products another look if they have open source, stable drivers (Like 3Ware....they rock. Because of thier long time commitment to linux, they are the only hardware raid cards I buy for my linux servers).
Re:Don't jump into this. (Score:1)
Why aren't more hardware concerns doing this? (Score:5, Insightful)
While it's true that windows and linux are the biggest games in town, offering potential customers who run other OSes a way to use your hardware seems like a no-brainer: larger potential customer base -> more customers -> more profits.
It often seems like pulling teeth; take a look at the recent (and ongoing) attempt OpenBSD is making to get more documentation and relaxed licenses for hardware. Being able to point to $1 million of hardware already running under an OS and getting little or no response from a vendor for better support -> larger customer base -> greater profits? WTF is wrong with the PHBs?
And now, back to the topic:
Document, document, document. Although I don't have any directly relevant experience, I've occasionally taken over 5000+ lines of code with abysmal documentation; on one occasion, it became so painful I rewrote major portions because it ended up taking less time than having to figure out what was going on.
Re:Why aren't more hardware concerns doing this? (Score:3, Insightful)
If you require software to accompany the kernel modules such as the way PCMCIA drivers are integrated with the PCMCIA man
Re:Why aren't more hardware concerns doing this? (Score:5, Insightful)
In a lot of cases the hardware is pretty simple and the functionality that differentiates their product is all located in the driver. Think "WinModem". Releasing the driver as open source can take a way a competetive advantage in that case.
Re:Why aren't more hardware concerns doing this? (Score:2)
Re:Why aren't more hardware concerns doing this? (Score:2)
My point was that it's currently possible for different vendors to use the same hardware as each other and try to create better software to capture market share. If all drivers were open source then this wouldn't be possible as your competition would download your patches minutes after you uploaded them and then they wo
Re:Why aren't more hardware concerns doing this? (Score:2)
releasing open-source drivers is a great way to kill VAR interest in your product, since the only place a VAR can add value is in the software or in support, and most people won't pay extra for support.
Speaking as a developer working for a company that does some work as a VAR, why the heck would we care whether we're building our value added components on top of open source or proprietary drivers? Perhaps if the drivers were completely GPL'ed we'd have to be a little car
Re:Why aren't more hardware concerns doing this? (Score:2)
Of course it is. You can include both proprietary drivers and proprietary applications on a delivered Linux box. The only restriction is that you can't use GPL'd software as the basis for the proprietary code.
My point about VARs is that the profit margin when selling generic hardware with open-source drivers will be very low compared to the profit margin when selling advanced h
Re:Why aren't more hardware concerns doing this? (Score:2)
Opening up their drivers would enable other software to be written for their device, but it would also open up their designs to competitors, not something they like to do.
I don't want to name names, but for this story, the company will be known as... Widecom.
I have spent some time working with some products from Widecom in past and have learned much about their seeming paranoia. We have a couple of proprietary datasheets on a couple of part
Re:Why aren't more hardware concerns doing this? (Score:2, Insightful)
The whole "if we release the specs, it can be reverse engineered" is so shallow as to be laughable; if a competitor truly wanted to reverse engineer your product, they'd do so with or without your published specs, by disassembling a) the hardware, or b) the driver you provide (this all reminds me of the "hackers only know how to break windows because we release security advisories" bs that comes out of redmond from time to time). M
Re:Why aren't more hardware concerns doing this? (Score:1, Redundant)
Simpler example: I lock all of my doors and windows when I am away, heck, I even have a security camera running in my livingroom... but that of course is not going to stop someone who wants to break into my house, which has happened. (http://www.brendangrant.com/breakin/index.html) Just because it has happened and it can happen doesn't mean I should just thr
One problem with your analogy. (Score:2)
I really fail to see how anyone can expect to continue to own any part of something they've sold. It's just plain silly and it's going to become very damaging to society at large before long.
Patience (Score:4, Informative)
Include reasonable amount of documentation, like a README and an INSTALL file. Keep both short.
Try to use autoconf scripts, since that may help in the long run when people tries to build it on all kinds of strange platforms. Be clear of which platforms that are supported, and which are not. Be also clear of platforms known not to work.
Set up a bug report tool. Bugzilla is a well-known tool. Bugs will be reported, and you may also get fix feedbacks that way.
A clear versioning strategy is also necessary. Avoid a multitude of branches if possible. The preferred way is to have a public read-only CVS archive. (you can use cvsup to create a mirror of the real archive in case you have a security breach on the public server.)
Have a reasonable licensing for your software, it will pay off in the end. You may want to take a look at MySQL. Try to be flexible and not too complicated.
This seems to be what I could come up with on a short notice.
And GOOD LUCK!
popular kids are jumping off bridges? (Score:2)
The autoconf scripts are a mess. They run slow. They take up 200 to 300 kB compressed. They test for various basic POSIX features that exist already on every OS you'd ever care to support. They add several extra layers of complexity.
Better way: good old #ifdef and such. It works.
Bugzilla is an isolation tool. (see the recent trouble with GNOME developers ignoring bug reports) At the very least, you must enable voting. You also face
OT - mozilla is NOT based on old netscape code (Score:2)
Actually, it took a short amount of time for the mozilla project developers to abandon the netscape codebase and start over on developing mozilla from scratch(though I'm not sure if no netscape code made it into the new mozilla code or not).
It then took a fair amount of time for the project to then reimplement most of netscape and create the firefox which I'm typing into right now.
Re:popular kids are jumping off bridges? (Score:2)
Uh, this is a driver! (Score:2)
I hate to bring this back on topic, but the subject is device drivers for linux. There is no need for any configure script because they only need to run on the current kernel. You know in advance exactly what is there. The most you might need is a depends line in the makefile to be sure your not getting compiled when someone you need isn't. (that is don't compile your SCSI card driver if the SCSI subsystem isn't installed) Should be trivial to do this.
Re:Uh, this is a driver! (Score:3, Informative)
It even has nice structures for building one version of a kernel module that's not the one you're running at the moment, or building RPM or
Re:popular kids are jumping off bridges? (Score:2)
autoconf checks for whatever you tell it to check for. If you don't want to check for sys/socket.h, don't tell it to.
*cough* (Score:5, Informative)
http://undeadly.org/cgi?action=article&sid=200503
Get marketing involved (Score:4, Insightful)
From the bleachers (Score:4, Insightful)
- Expect a rough transition.
Releasing your app to the community is like hiring a bunch of new developers but not giving them any management. If they like what you have, they will work with it; if they don't, they might re-implement things or openly disagree with your existing design. Get as much relevant information online as possible so others can make informed design decisions.
- Provide direction, but be flexible.
One benefit of OSS is that others can suggest fixes that may directly contradict your current view of the problem. By carefully accepting some of these changes, your software will become better.
- Don't expect the OSS community to do all the work.
Several major bloopers have come from companies saying, "fine; we're open-sourcing it; let them do the work". This is the road to stagnation. The community will support things that are useful to them; don't assume that your alpha-OSS release will generate immediate support. A small OSS community is excellent for porting existing software to new systems; they are generally slow for actual development work.
- Keep providing support.
During the initial transition, you will probably have more work than normal as people flock to your project asking questions. Then only those who like what they see will stay. At a minimum, your company should host an email list and an anonymous CVS or Subversion server.
- Advertise the transition to your users.
Make sure your customers understand that they can now customize things in-house. Make OSS a "value-added" feature. Encourage them to return their improvements back to the community.
- Make a good testing framework available.
Most of your end-users will only have access to the hardware they actually use. Your current Q/A process probably tests against a range of hardware. As such, you own a range of test machines. Network these to a test framework that can validate community changes as they are submitted. Maintain a "stable", in-house tested branch and an "unstable", bleeding-edge branch.
Look for in-house advice too (Score:5, Insightful)
http://www.intel.com/software/products/opensource/ [intel.com]
http://www.intel.com/cd/ids/developer/asmo-na/eng/ 52779.htm [intel.com]
Work with the community (Score:5, Informative)
So the people who know the hardware best are paid to work on a driver that few people use. Meanwhile, the driver in mainline keeps up with the frequent changes of in-kernel APIs but lacks the resources to make use of all the features the hardware offers.
A few companies (e.g. Intel with their eepro) seem to get it right: Have someone work with the community to write and maintain a driver in mainline. You are still largely in control as long as you are competent, and you are pushing the code people actually use.
Thigs to do (Score:5, Insightful)
2) Clean up your code. If the comments are incomplete, complete them, if there's something that's obfuscated for no good reason, unobfuscate it, etc. Remember that for it to be useful someone who's never seen it, and doesn't know how your stuff works. While doing that clean up any bad language in the comments and code.
3) Make sure your code builds completely to a final useful state on standard compilers (GCC on Linux, VisualStudio on Windows). If there's any special options that need to be set, document them. Don't release something that won't compile without tweaking, it should be ready to go.
4) Don't neglect binary versions. Keep them at least as current as the source versions, if not more so. Many (most?) people don't like fucking around with compiling their own stuff. It takes time, and the compiler is scary to non-programmers. Have an easy to install binary version as you did before. Goes double for Windows.
5) Do it for the right reasons, that being to get feedback from the world at large and to help out. Don't do it expecting the OSS community to pick up your slack and develop your drivers for you. You might get lucky and find that some extremely talented individuals do just that, but more than likely if you open them up and ignore them, they'll become crap.
6) If you take community contributed drivers that you have nothing to do with (like ports to an unsupported OS), make sure you make it clear on your site that they are different. Have a clear demarcation between drivers you created and supported (with or without community help) and drivers someone else did, but you didn't make and can't support.
In general I think it can work to your advantage, but only if you treat the OSS community as an additonal asset, not as your core development. Maintain the same team you have now, same standards for testing and quality (I'm assuming they are good here) and so on. Take any useful contributions the OSS community provides, but don't rely on them to start doing your job for you.
Language police? (Score:2)
However, it's just my advice, I'm certianly not trying to force it on him. If you do
Support Zaptel (Score:1, Redundant)
It was originally developed by Jim Dixon for his Tormenta T1 card (open source GPLed hardware BTW) but has since been used with open source telephony projects such as Asterisk.
Asterisk is an interesting example to study in respect of open versus closed telephony drivers.
Some vendors have closed driver support for Asterisk, eg. Intel/Dialogic which means their drivers can only be sold through a non-GPL Asterisk
Re:Support Zaptel (Score:4, Insightful)
I wouldn't be surprised if this is one of Gerry's motivations for switching to open-source. Do a bit of Google searching, examples are:
http://lists.digium.com/pipermail/asterisk-
Gerry works for Intel/Dialogic.
As another poster who figured out who you work for said, you might want to get in touch with people in your parent company familiar with open source, such as the eepro maintainer. They'll probably give you better answers than Slashdot. Although they won't give you as much free publicity as Slashdot.
Release tokens (Score:2, Informative)
Dear Dialogic (Score:1, Interesting)
I would like to suggest the following:
- Communicate with your application developers openly. You rob yourself of invaluable feedback when the forums you sponsor are not as free as the source.
- Particiapte. While it's not neccessary to feed the trolls, your guidance and expertise are critical to the success of the project.
- Take a resolute approach. An insistance on silly extra clauses added to otherwise good licenses only c
Other telecom vendors do a better job.... (Score:1, Interesting)
We switched from this company to a smaller vendor that shipped PSTN and VoIP boards with stable drivers. We've never had a problem since, and will never go back to the previous vendor.
As for open source, if I am
Re:Other telecom vendors do a better job.... (Score:2, Interesting)
Some Linux kernel tips (Score:5, Interesting)
Know the politics. Most Linux kernel developers aren't accountable to anyone and don't negotiate. You will have to put up with whatever requirements they give you if you want your code to be part of the kernel.
Know the effort. You will probably be asked to rewrite your drivers, possibly more than once. This will take months. If you don't do it, then open-sourcing the drivers was mostly wasted effort.
As others mentioned, coding style is important. Also, wrappers are not allowed in the kernel, so call kernel APIs directly instead of wrapping them. The result is a totally Linux-specific driver, but the rules are the rules (see above).
Re:not for this kind of driver though (Score:2)
Two-way delivery (Score:3, Interesting)
This is both a good thing and a bad thing. It's good because you'll get fixes from people testing your code on all sorts of weird platforms you've never heard of. It's bad because you can wake up one morning and discover the kernel API for your type of driver has changed overnight, and your code won't even compile until you re-write half of it (there go your plans for the weekend). A certain amount of lag is acceptable, and you can restrict support to the stable kernel series only if you want, but expect to hear a lot of whining from users who will demand that you keep up with the cutting-edge development code.
Corporate reasons for BSD over GPL (Score:2)
- Hubert
Re:No experience (Score:1)
Re:If it is not broken... (Score:4, Informative)
By making the drivers open source & letting the OS supplier recompile them for new releases they lessen the future load on their support desk from people complaining that their Linux 2.8 binary drivers won't work in Linux 4.2
Re:If it is not broken... (Score:1)
At some companies, the support desk just has a button on the phone to transfer the complaining customer to sales. *ring* "Yes, you want to buy one of the newer, supported fribbitzes?"
Not saying it's good, or bad.
Re:If it is not broken... (Score:1)
... do you know for sure it won't break in the future? Binary-only drivers are notorious for breaking in every kernel release (just look at nvidia's proprietary display driver).
In addition, to that, there are various other reasons for open sourcing drivers, (probably) the most important benefit being community-based maintenance and porting of the drivers.
Re:If it is not broken... (Score:2)
Offtopic (Re:If it is not broken...) (Score:2)
And preferably a PCI Express board too...
Re:And more importantly... (Score:1)
You, sir, are an idiot. (see
Re: (Score:2)