Slashdot Mirror


NDIS Wrapper For Wireless LAN Cards Under GPL

An anonymous reader writes " Shortly after Linuxant has released their commercial DriverLoader, Pontus Fuchs has made an NDIS wrapper available under the GPL. Since some vendors refuse to release specifications or even a binary Linux-driver for their Wireless LAN cards he has decided to solve it himself by making a kernel module that can load Microsoft-Windows NDIS drivers. ndiswrapper has been tested with some BroadCom miniPCI cards and it seems to work on some laptops . With some more work it should be possible to support more cards. Hopefully this will be the case for the many owners of Linux laptops based on Intel's Centrino technology. Please contact Pontus if you are interested in helping out!"

44 of 222 comments (clear)

  1. What, no screen shots?? by rvaniwaa · · Score: 5, Funny

    How does he expect people to try out his code without any screen shots????

    --
    main(i){(10-putchar(((25208>>3*(i+=3))&7)+(i ?i-4?100:65:10)))?main(i-4):i;}
  2. Sweet! by zx-6e · · Score: 2, Interesting

    As long as the NDIS wrappers support all the capabilities of the cards, this is great news!

    1. Re:Sweet! by Anonymous Coward · · Score: 3, Informative

      An NDIS driver provides functionality to make the card work. Its a standard way to operate with the card from a program if you dont know a particular card's interface. So no, NDIS does NOT support all the capacilities of the card as far as alternate forms of authentication and the little extra goodies the manufactorer puts in. But, it will get the card working with its basic functions which is better then not working at all.

  3. Not the best solution by mocm · · Score: 3, Insightful

    compared to a native driver, but certainly helpful in reverse engineering the windows drivers.

    --
    ***Quis custodiet ipsos custodes***
  4. Support supported cards by Neil+Watson · · Score: 3, Interesting

    Would someone care to point out which cards have native Linux drivers available? Once we have this list I think we should go out of our way to buy from vendors with Linux drivers.

    1. Re:Support supported cards by pyros · · Score: 3, Informative

      cards besed on the prism chipset and the orinnoco/hermes chipset(s) work very well. Cisco aironet cards have worked pretty well for me, too. I think the big stinkers are the broadcom based ones.

    2. Re:Support supported cards by Kamel+Jockey · · Score: 3, Informative

      Likewise, I've also been able to use the Linux-WLAN-NG drivers to make various wireless adapters work under Redhat Linux versions 7.2 and 9. The devices that I have actually used successfully are:

      • Proxim RangeLan-DS PC Card (oddly enough I can't get this card to work under Windows 98 or XP)
      • Linksys WPC-11 v.3 PC Card
      • Microsoft(!) MN-510 USB wireless adapter (works pretty well with Kismet)

      I noticed that the README file included in the download mentioned a "BroadCom" wireless card. I'm curious as to whether or not this is the newer Linksys PCI wireless card (WMP11) which used to work with Linux-WLAN-NG before they changed the friggin' chipset from Prism2 to Broadcom.

      --
      In case of fire, do not use elevator. Use water!
    3. Re:Support supported cards by pyros · · Score: 2, Interesting

      yeah, I have a WPC-11, and I've been very happy with it. I finally got encryption (albeit 64bit) working with the orinoco_cs driver, which means I don't have to wait for this guy to catch up with new kernel releases. I'm pretty sure that Linksys switched to Broadcom. That's actually part of the big stink over the source code for the WRT54G router they sell. It runs linux, and uses a Broadcom chipset. So we know a driver exists.

  5. Double edged sword by Mr+Bill · · Score: 4, Insightful

    This is kind of a double edged sword. Now that you can use NDIS drivers under Linux, it will be that much harder to convince these companies that providing a native Linux driver would be good for their business...

    If you are in the market for one of these cards, buy from a company that supports your OS of choice...

    1. Re:Double edged sword by nbvb · · Score: 4, Insightful

      Heh, this sounds like the OS/2 problem:

      We make a better DOS than DOS, and a better Windows than Windows!

      So who'd bother writing for OS/2 when I can just write for Win or DOS?

    2. Re:Double edged sword by Lussarn · · Score: 2, Insightful

      Except that very few companies write for Linux anyway. Of course, very few wrote for OS/2 too but linux have a much stronger community than OS/2 ever had.

      We don't even want closed source binary drivers. We want the specs for the hardware.

      I don't think there ever was a OS/2 problem as it is described. Noone wrote for BeOS either and BeOS didn't have ANY apps. Surely it's better to run windows apps than nothing.

    3. Re:Double edged sword by Minna+Kirai · · Score: 4, Insightful

      This is kind of a double edged sword.

      That's the same argument that comes up around Wine, or other projects that allow non-native applications to run on a platform- backward compatibility might discourage creation of true native apps.

      It's a valid concern. But for the position Linux is in today, it looks like a degree of Windows compatibility will help more than it hurts.

      If two systems can share binary applications and drivers, then a barrier for users to switch between those systems has been reduced. Compatibility might encourage switching in either direction- but the rule of thumb is that lowered switching costs helps minority solutions increase their popularity.

      Virtually everyone uses Windows(r)... if switching to other things were easier, then more people will switch, and the number of Linux installs will increase.

      If you are in the market for one of these cards, buy from a company that supports your OS of choice...

      One way a company might "support" linux is by including this wrapper module with the hardware, and pointing Linux customers to instructions on how to use it. This way, hardware vendors can take a gentle slope towards native Linux support: their initial investment in software programming is minimized, but they can get accustomed to the idea that some of their customers are buying for Linux, and that the platform deserves support in the future.

    4. Re:Double edged sword by Minna+Kirai · · Score: 2, Insightful

      That's often mentioned as an argument against a competitor's legacy systems, it's more complex than that. Linux and OS/2 are substantially different.

      Back when IBM attempted to push OS/2 to the buying public, it was a $100+ product, while DOS/Windows was "free" (it seemed free from the end-user perspective, in that it came with every computer and customers couldn't reduce PC cost by declining DOS)

      Today, however, Linux is a $0 product, and some buyers now have the option of bare-bones systems where Windows(r) would look like a $299 add-on.

      So OS/2 was more expensive than Windows. Using it to run Windows apps was wasteful. But Linux is less expensive than Windows, so if it turns out it can run Windows stuff adequately, people will turn to Linux as the cheaper choice.

      (And then, when/if Linux gets major marketshare, more new commercial programs will tend to be aimed at Linux first)

    5. Re:Double edged sword by PCM2 · · Score: 3, Insightful

      Well, a counter-example might be Mac OS X. You could write apps for OS 9 and they would run in Classic mode. Or, you could code to the Carbon libraries and your apps should work on both OS 9 and OS X. Or, you could write your apps to the Cocoa frameworks, and they'll only work on OS X, yet they'll be "better."

      Seems to me that, while the initial reaction was to code to Carbon, most brand-new applications being written (or rewritten) for OS X these days are Cocoa applications.

      It's not the same thing as the OS/2 example, exactly, because Apple controls both the Carbon and Cocoa libraries and has pretty much announced the death of OS 9, so backward compatibility is not an issue. But if you consider that even established Mac OS developers have begun coding to Cocoa in spite of their past investments in Carbon/Mac OS 7-9.x development, it seems that some vendors, at least, are capable of seeing the value in doing something the "better" way, rather than just sticking to what they know.

      Where hardware vendors and Linux drivers are concerned, we'll just have to wait and see. This seems like a case where everybody really should hope Linux gets "ready for the desktop" -- because a couple million laptops out there running Linux as a primary OS are going to convince the hardware manufacturers a lot more quickly than a bunch of servers will.

      --
      Breakfast served all day!
  6. Wrapper should send e-mail to hardware vendor by Anonymous Coward · · Score: 5, Interesting

    The wrapper should send an e-mail to the hardware vendor every time it loads. As more people use the wrapper, they get more and more e-mail. Perhaps they would rather write proper Linux drivers than get more e-mail. ;-)

    1. Re:Wrapper should send e-mail to hardware vendor by FauxPasIII · · Score: 3, Funny

      You don't REALLY want to usher in a time when network device drivers surreptitiously send email, hit websites, etc. Do you ?

      --
      25% Funny, 25% Insightful, 25% Informative, 25% Troll
  7. That's Easy by OctaneZ · · Score: 5, Informative

    Here's a nice list at HP of cards that work.

  8. Re:How by OctaneZ · · Score: 4, Informative
    At the bottom of the SF page:
    Contact

    You can contact me at pof (at) users.sourceforge.net.
  9. Cross Platform Drivers by AKAImBatman · · Score: 3, Interesting

    For quite a while now, I've considered what sorts of problems would be inherent in cross platform drivers. Usually, the problem seems to come back to a difference in the way kernels manage their drivers and differences in the way that I/O is done between OSes. Perhaps a "Driver Adapter" could be built that would allow drivers written for it to run on any OS? The basic concept is that the adapter itself would be a driver for the OS, then the "Cross Platform Drivers" would deal directly with the adapter.

    Anyone have any thoughts on why this would or wouldn't work?

    1. Re:Cross Platform Drivers by Ann+Elk · · Score: 2, Informative

      NDIS is a cross-platform network driver model, or at least it was when I worked with it ~10 years ago. An NDIS driver never calls the OS directly; everything goes through the NDIS wrapper, thus providing an abstraction layer over the actual OS.

      Now, if someone will just write a similar layer for Linux that can load Windows NT filesystem drivers, then I can get read/write access to my NTFS partitions... Hmm...

    2. Re:Cross Platform Drivers by parnasus · · Score: 2, Insightful
      ... every judge in the US is going to throw the book at them.

      If history is any judge, that book is probably going to be made of tissue. Nothing the judges have thown at Microsoft so far has done anything to deter them.

      --
      --If you code for the exceptions, the rules fall into place
    3. Re:Cross Platform Drivers by Ann+Elk · · Score: 2, Informative

      The original NDIS specification predates Windows NT, 95, et al. It was, in fact, targeted at DOS and OS/2. A little Googling [see this, this, and this] shows that it has a long (if not glorious) history. IIRC, NDIS binaries would load unmodified in Win NT and Win 95. This is pretty cool given these two OS's vastly different I/O models.

    4. Re:Cross Platform Drivers by ComputerSlicer23 · · Score: 2, Informative
      There is such a beast, or at least pretty close. It's I2O. According to what I've read, it's a drivers where the OS writes the high-level driver, for their specific OS, and the device maker writes the low level driver that provides functionality to the high level driver. The low level driver can be plugged into any OS. There is a specification for each major type of hardware.

      Here is a link to a page about it.

      It's a neat idea, but I'm not sure how popular it is with hardware makers, and it somewhat constrains the implementation in hardware. The basic underlying princepals of the hardware would have to support the way the high level model is written, as opposed to having the software conform to the software.

      It has to be a split driver model, as OS's organize themselves differently, so what would be highly efficient in one would be dog slow in another. This is also why various people recommend not porting a Windows driver to Linux, but to instead write a native Linux driver. Somebody presented a paper on the 10 things not to do while writing a Linux driver.

      Notice, that I2C is also how lots of Linux drivers are written for block devices, because lots of block devices have a high layer, a mid layer, and a low level. Normally the high level, and mid layer are similar between lots of drivers, and generally get squeezed into a single driver.

      Kirby

  10. This is not necessarily good news by Rosco+P.+Coltrane · · Score: 5, Interesting

    Good news : I can get that %^*@$# network card going now.

    Bad news : Nobody will bother to write Linux drivers soon enough, they'll all say "why bother, we'll just make a Windows driver and tell people to use the wrapper.

    Net results :

    - This makes card vendors inclined to think only the Windows platform is truly important

    - This allows Microsoft to have the option of one day changing, subtly messing up or adding undocumented calls to their API, slowly leaving Linux people in the cold as all card vendors transition.

    - I would think native drivers are faster / more efficient / more full featured than drivers running under emulation. That might not be the case though, but more often than not, running alien binaries in any OS isn't known to be as fast as the real McCoy.

    --
    "A door is what a dog is perpetually on the wrong side of" - Ogden Nash
    1. Re:This is not necessarily good news by arth1 · · Score: 5, Interesting

      Bad news : Nobody will bother to write Linux drivers soon enough, they'll all say "why bother, we'll just make a Windows driver and tell people to use the wrapper.


      This is already happening. The excellent 3COM 990 series (the network cards with a RISC CPU and memory on the card), for example, have their own firmware and API that hugely simplified writing a wrapper for Linux, to the point that there isn't a real driver. While the wrapper-drivers work, you don't get the benefits of CPU offloading and profiling that you get under Windows 2000.

      Regards,
      --
      *Art
  11. Platform independent drivers by cant_get_a_good_nick · · Score: 3, Informative

    This wrapper sounds a bit like the UDI Project creates a universally consistent driver DDI across all platforms. All drivers are source code compatible for all platforms with an environment. Drivers are binary compatible between platforms with a common C ABI.

    Unfortunately Caldera was the main weight behind this, back when they actually did something silly like write code to make money instead of sue. They fell on hard times and essentially pulled support, and it's been dead in the water since.

  12. Licensing issues by sgf · · Score: 3, Interesting

    How does the licensing work with this? If it's GPL, isn't it being linked (albeit in a kind of weird runtime way) with proprietary code? It seems a nice idea to write code in order to export the features of proprietary code into open software, but how do you distinguish it from programs that do the opposite?

    1. Re:Licensing issues by mrroach · · Score: 2, Insightful

      Because the GPL is only a distribution license. The user can link against whatever they want. That's why proprietary kernel modules are ok.

      -Mark

    2. Re:Licensing issues by PugMajere · · Score: 2, Insightful

      No, Linus added that *well* after he began receiving contributions from others.

      There is no reason to think that Linus has total control over the licensing restrictions that the kernel is distributed under.

      Anyone who tells you otherwise is wrong.

  13. Kernel space? by 42forty-two42 · · Score: 2, Insightful

    Is this implemented in kernel space still? Is it possible to implement a driver wrapper like this in Ring 3, or at least in Ring 1 or 2, thus reducing the effects of a driver crash, instead of Ring 0?

    1. Re:Kernel space? by 42forty-two42 · · Score: 2, Insightful

      I don't see why it can't go through e.g. mapping memory and using real-time signals or reading from a device file to receive interrupts...

  14. Next step: integrate with Windows Update by mentin · · Score: 3, Insightful
    I can see that soon this will go to Windows Update to find new or updated NDIS drivers.

    Looks like more and more Linux is simply emulating Windows. But if you run Windows drivers and Windows programs via appropriate emulation layers, why not simply run Windows?

    --
    MSDOS: 20+ years without remote hole in the default install
  15. one bad thing by termos · · Score: 3, Interesting

    The only bad thing I experienced when testing this NdisWrapper was that I needed Linux 2.6.0-test8 or higher.

    I don't want to run a beta version of Linux, so is there any good reason for this?

    --
    Note to self: get smarter troll to guard door.
    1. Re:one bad thing by Anonymous Coward · · Score: 4, Informative

      Read more carefully: There is a way to build it in 2.4.x since about yesterday.

  16. The reason that this is required: Interference by Karora · · Score: 4, Insightful

    There are people here claiming that we'll never see Linux drivers because of this.

    The main reason this is required, however, is because the latest chipsets for wireless give too much control to the software. That means the user can theoretically control transmit levels and frequencies, and make their transmission interfere with other people's communication.

    Since the transmit power levels and frequencies are all set differently in different parts of the world, the closed-source software is needed to restrict people's control over the hardware.

    And that is a real bummer. It is hard to support closed-source Linux drivers - people don't particularly like them, there are thousands of different kernels out there (each distribution has about fifty or so current at any one time, not to mention all the patches you can download from kernel.org).

    As a result, this doesn't surprise me at all. I think it's probably the only way modern WiFi will be supported under Linux. That doesn't translate to the end of the world, however, since the regulatory situation is quite different for almost everything else in the computer.

    --

    ...heellpppp! I've been captured by little green penguins!
  17. We also need... by jmv · · Score: 2

    A stable Linux driver API/ABI. This is getting ridiculous. Windows drivers compiled for a 5 year-old version still work on the current version (maybe a slight exageration), while a driver compiled for 2.4.21 won't work with 2.4.22. Not only that, but even with the same version, driver compatibility depends on SMP option, highmem, ...

    1. Re:We also need... by jmv · · Score: 2, Insightful

      I'm not saying the ABI should be frozen for 5 years, but I think every it shouldn't with micro version numbers. The same driver should work for all of 2.4.x. Now, I know most drivers have source code with them, but sometimes a binary is just much simpler. I mean I can also have the source for XFree86 and OpenOffice, yet I'd rather just get the binaries.

  18. Re:The reason that this is required: Interference by fishbowl · · Score: 4, Interesting

    "Since the transmit power levels and frequencies are all set differently in different parts of the world, the closed-source software is needed to restrict people's control over the hardware. "

    It's a matter of opinion that "restricting people's control over the hardware" is necessary or appropriate. If there is some compelling state interest, then it should be considered a defective and/or dangerous product, which ought to be dispensable only to licensed purchasers.

    Treating it as a problem that the consumer owns does not solve the problem. Just because the manufacturer hasn't enabled the consumer to alter the card's programming, doesn't change the fact that the dangerous device has been distributed into the wild.

    As soon as some independent party (not subject to the US law-by-agency-order), creates software to unlock these cards, the disabled-by-obscurity features will be open. If that's a problem for the state, then they should have considered it before allowing the product to be sold.

    If some product can be converted to a weapon, the fact is, the weapon is in the consumer's hands whether you've told him how to convert it or not. You hold some of the responsibility for this product getting into the consumer's hands.

    --
    -fb Everything not expressly forbidden is now mandatory.
  19. Re:The reason that this is required: Interference by kwerle · · Score: 4, Insightful

    Following your argument, why don't the wireless card makers release specs then? If they're off the hook regarding using these wireless chipsets for illicit purposes, why don't they just release the specs?

    Because every hardware company that releases a product believes that they either
    Have a competitive advantage and need to keep it a secret.
    or
    Have a crap design and need to keep it a secret.
    or
    Have the same design as everyone else and need to keep it a secret.

  20. Re:Pontus Fuchs by Anonymous Coward · · Score: 2, Funny

    I know a girl whose name is "Ashley Fuchs". Her email sig simply reads "It's pronounced fox."

  21. Why was this modded a Troll ? i need help by zymano · · Score: 2

    Can someone tell me why this was modded down ? There is nothing trollish about that . I mention that you need to fight the hardwared makers or they wont assist at all.

  22. PowerPC by O · · Score: 3, Insightful

    If this works, then no one will bother developing an open source driver, which means there is still no hope for using Airport Extreme, which uses the Broadcom chipset, under Linux on a PowerBook. =(

    --

    1, 1, 2, 3, 5, 8, 13, 21 -- Mathematics is the Language of Nature.
  23. Re:The reason that this is required: Interference by Asmodeus · · Score: 3, Interesting

    Its actually quite hard to reverse engineer modern hardware. Gone are the days of a few bits to twiddle on an IO port. Now we are talking entire protocol stacks for complex protocols with varying amounts of the stack and/or compression implemented in hardware. Go read the USB or 802.11 specs sometime. This is not your grandfathers' serial port. Yes, I am experienced at writing device drivers. I reverse engineered a major USB webcam chipset for Linux, and I've written many older drivers.

  24. Ask Intel by jwr · · Score: 2, Informative

    Or better, contact Intel and ask them, why in spite of all the hype and marketing announcements about them supporting Linux, they have silently failed to deliver either Centrino drivers or Centrino documentation.

    Frankly, I'm rather surprised that no Linux company has sued them yet, for unfair competition. Disclosing drivers and documentation to one OS maker and hiding it from the others IS unfair competition.