Wrap it before you tap it? No, say Linux developers: 'GPL condom' for Nvidia driver is laughed out of the kernel
- Reference: 1596555913
- News link: https://www.theregister.co.uk/2020/08/04/gpl_condom_nvidia_linux_kernel/
- Source link:
The Linux Kernel [1]licensing rules make provision for proprietary third-party modules but state that such modules must be tagged as proprietary.
This "cannot be used for modules with source code in the kernel tree. Modules tagged that way are tainting the kernel with the 'P' flag when loaded and the kernel module loader refuses to link such modules against symbols which are exported with EXPORT_SYMBOL_GPL() ."
Facebook developer Jonathan Lemon put forward an RFC (Request for Comments) on a proposal to implement DMA (Direct Memory Access) zero-copy between a network card and a GPU to enhance network performance, while keeping the protocol processing on the CPU. The use case is for "GPUs used for machine learning, which are located near the NICs, and have a high bandwidth PCI connection between the GPU/NIC," states [2]the RFC .
The code relies on Nvidia's proprietary driver for Linux, noticed by kernel maintainer Greg Kroah-Hartman, who observed: "OK, now you are just trolling us. Nice job, I shouldn't have read the previous patches. Please, go get a lawyer to sign-off on this patch, with their corporate email address on it. That's the only way we could possibly consider something like this."
Long-term Linux and free software developer Christoph Hellwig agreed, accusing Lemon of working around the requirement for EXPORT_SYMBOL_GPL . "If you only even considered this is something reasonable to do you should not be anywhere near Linux kernel development," he said.
Lemon said: "While the current GPU utilized is Nvidia, there's nothing in the rest of the patches specific to Nvidia – an Intel or AMD GPU interface could be equally workable," but others were unconvinced, arguing that the proposed code was written specifically for the Nvidia API.
"We we can't do a good job if our hands are tied by being unable to change something. This is really a textbook example of why this is the correct philosophy," said Jason Gunthorpe, who works at Nvidia following the [3]acquisition of his former company Mellanox. "Posting patches so tightly coupled to the Nvidia GPU implementation just makes people angry," he said.
The spat prompted Hellwig to [4]propose a patch to "Inherit TAINT_PROPRIETARY_MODULE ". Hellwig said: "We've had a bug in our resolution of _GPL modules since day one, that is a module can claim to be GPL licensed and use _GPL exports, while it also depends on symbols from non-GPL modules. This is used as a circumvention of the _GPL exports by using a small shim module using the _GPL exports and the other functionality."
The proposed patch is to ensure that "if a TAINT_PROPRIETARY_MODULE exports symbol, inherit the taint flag for all modules importing these symbols, and don't allow loading symbols from TAINT_PROPRIETARY_MODULE modules if the module previously imported gplonly symbols. Add anti-circumvention devices so people don't accidentally get themselves into trouble this way."
"Ah," said Kroah-Hartman, "the proven-to-be-illegal 'GPL Condom' defense."
Hat tip to Michael Larabel, who [5]reported the incident on his Phoronix site. ®
Get our [6]Tech Resources
[1] https://www.kernel.org/doc/html/latest/process/license-rules.html
[2] https://lore.kernel.org/netdev/6376CA34-BC6F-45DE-9FFD-7E32664C7569@fb.com/T/#md514322fdfa212afe9f1d3eb4e5f7eaefece36eb
[3] https://nvidianews.nvidia.com/news/nvidia-to-acquire-mellanox-for-6-9-billion
[4] https://lkml.org/lkml/2020/7/30/58
[5] https://www.phoronix.com/scan.php?page=news_item&px=Linux-Kernel-Blocking-NV-NetGPU
[6] https://whitepapers.theregister.com/
( Leaving aside the details of this particular issue )
There is a reason for a HW maker to keep a driver closed source.
You make 2 models of a card, model A is $ while B can do more and costs $$
You could make 2 different chip sets but this would cost more, leaving you with A costing $$ and B $$$$
By using the same parts, but limiting one in software,,you can make both cards cheaper.
It's like banning first class on planes/trains - that would make economy much more expensive.
That is fairly common. Usually done in firmware rather than the driver however.
think of the driver purely as "getting it to run". All the (slightly seedy) monetisation is done via hardware or firmware.
For example, have a think how AMD and Intel get round this. Both have decent quality open-source drivers for a while now. It isn't like they have lost business or trade secrets. Nvidia doesn't really provide much more above a "premium" brand name.
Yes but that is dishonest. If the card is identical between the different models, the vendor should pick a price and sell the product. That kind of differential pricing demonstrates why proprietary software is wrong.
It's not llike first class on a train or a plane - if you pay for a first class seat you get more legroom, better food etc. It's more like selling first class tickets and then putting first class and economy into the same seats.
As others have said, if they really want to differentiate, then put the proprietary stuff into onboard firmware, and publish open source drivers. Other manufacturers seem to be able to do this.
"It's more like selling first class tickets and then putting first class and economy into the same seats."
There is a smallish selection of Britains rail services for which that is true.
Lemon
"If you only even considered this is something reasonable to do you should not be anywhere near Linux kernel development," he said.
Hmm ...
Clear enough, methiks.
Good for you, Christoph Hellwig.
Have one or two on me ----->
O.
NVidia has the money and manpower
to write and maintain their own proprietary kernel. I strongly encourage them to do just that and stop trying to hijack the Linux kernel.
Re: NVidia has the money and manpower
They wouldn't just have to write their own kernel - no mean feat in itself - they would also have do so in a way that has an identical interface for the rest of the system... or write an entire OS and application level. I don't see that happening any time soon
NVidia keep on trying
so hats off to them but... they can take a hike.
They know the rules. They played by them for a while but then... they were gone, gone gone.
I have to smile when Nvidia is having issues with FOSS as well as the Apple Walled Garden. For once, Apple and Linus are on the same side. Kinda ironic.
This is good. It will ensure proprietary stuff will slowly become more and more behind compared to open technology.
Yes, pretty lame in the short term but if it can "bully" the companies like NVidia into opening up their source code for correct integration with systems, it is better for humanity in the long run.
Nvidia sells hardware, not their driver. There is no reason for it to remain closed source in 2020.