GPLv2 and Its Infringement by Xiaomi

GPLv2 and Its Infringement by Xiaomi

Xiaomi has announced their spectacularly spec’ed Mi Note Pro, which features the latest in Qualcomm’s Snapdragon processors alongside a big 2K display and 4GB of RAM for a killer price. That being said, there’s something that is not-so-good about Xiaomi’s offerings that is a concern to many developers, especially many found here on XDA: Xiaomi’s repeated violations of the GPLv2 license for the Linux kernel which Android (and thus Xiaomi’s devices), is built on.

Xiaomi is not the only company that has violated GPL though, and in the past many OEMs such as Rockchip and Micromax have done so too, with many continuing their outlaw behavior to this day. We talked a bit about this on XDA, and why wouldn’t we? XDA is primarily a developer community and we are known for providing thousands of power-users with modifications of software that falls under GPL, but our community follows our GPL Policy and thus we don’t see much shady appropriation here.

So what is Xiaomi doing wrong, exactly? And is it illegal, immoral or simply improper? Since there might be some readers, users or even developers who aren’t up to speed on these matters, let’s have a quick look at what GPL means. 

Not Free Beer 

gpl-logoThe GNU General Public License (GPL) is a free software license that guarantees developers, OEMs, users or any sort of organization that merges the three to have unlimited access to the foundations and functionality of the software that falls under it. They can use, study, share and copy or modify said software, as it is free software. GNU developers of the GNU Project define free software like this:

“Free software” means software that respects users’ freedom and community. Roughly, it means that the users have the freedom to run, copy, distribute, study, change and improve the software. Thus, “free software” is a matter of liberty, not price. To understand the concept, you should think of “free” as in “free speech,” not as in “free beer”.

So while free (free speech) software might ultimately end up free (free beer), it really is about fostering a developer environment that focuses on the progress of computer science and software engineering through the collective improvement, sharing and learning of any free software’s code.

The GNU Project has a very noble view on software, and they campaign because they believe every user and creator deserves this freedom. Not only does it allow for the public to control the program and what it does, but proprietary software does the opposite by controlling the user through the developer’s control of the program, which would result in an instrument of unjust power. With the essential freedoms of free software (which are running the program how you wish, studying how it works, redistributing it when you want, and distributing your own modifications), software engineering becomes more like a pure science that allows one to have papers rather than patents, allowing every programmer to take a peak at someone’s theory of code, their methodologies and their preferred programming style to further his own understanding of how it works, and gather insights for his personal development. Moreover, it allows him to grab that software and modify it.

Why should it be free?

The word “proprietary” used to describe non-free software does not just imply that the inner workings of the code are legally off-grounds to other parties; it also implies that the owner of the software you use (be it an app you download or an operating system you run) is the creator, and thus the owner decides whether you can copy it or share it. Such non-free obstructions lead to fewer people using the program and learning from it, and the inability for users to modify, adapt or fix the program. Leaving the more ethical grounds about social cohesion and its withholding ideologies aside, this material harm does have a noticeable impact in the future of computer science and consumers, especially given that computer science and its byproducts are intertwined with users’ lives – and their future – more than ever before today.

Where’s the free software’s catch?

There is no catch. But there are things that annoy OEMs. The people who attempt to modify free software licensed under GPL have to comply with some rules.

First of all, the terms must be available to anybody receiving a copy of GPL-licensed work, and anyone who adheres to the terms of GPL has permission to share, study and modify the work as well as its derivatives.Unlike other licenses, GPL does allow for free (free speech) software to not be free (free beer), unlike other licenses that explicitly prohibit commercial distribution.

A GPL licensee or distributor may not impose further restrictions on the rights granted by GPL – forbidding the distribution of GPL software without the explicit disclosure of its nature, or under nondisclosure contracts. All patents used in the GPL software are available for limitless use for those that comply with GPL terms.

GPL also requires that the programs that are distributed as pre-compiled binaries are accompanied by a copy of the source code and a disclaimer informing the user or developer that the software is GPL-licensed or free to be studied, shared or modified under GPL. And one of the most important parts, GPL requires distributors to provide all recipients a license along with the program, as well as making the source-code obtainable through some medium for those who request it, alongside clear directions as to how to obtain the source-code.

What does this have to do with Android?

Android is licensed under Apache 2.0 license, and not GPL. Apache is a more “permissive” license and doesn’t feature the same requirements as GPL. It doesn’t require you to distribute the source-code of a covered work, and the derived work doesn’t necessarily carry the Apache license, like the more viral GPL, as long as you include their license.

So while GPL promotes the growth of free software, Apache is more libertarian with their approach to how the terms of future derivations develop. And OEMs can, for example, take Apache licensed software, add their skins, bloat and what-have-you, and then close it down and keep the source closed. Which is what Xiaomi and many OEMs do. But the Linux kernel that Android bases its foundations on is not licensed under Apache, for Linux is GPLv2 software and due to this “viral” or “infectious” property of GPLv2, the Linux-based kernel of Android that uses Linux’s GPLv2 code has to remain GPLv2.

Xiaomi did nothing wrong then!

Xiaomi did not release its Android branch’s Kernel source codes. Since their Kernel is based on Android’s Kernel, which is based on Linux’s Kernel, which is GPLv2, the terms of GPLv2 are carried all the way to Xiaomi. If they would have used their own Kernel, then they’d have every right to not distribute their source, and they would have no obligation of doing so either. But by modifying and distributing GPL software, they have to comply with the GPL terms, in this case GPLv2.

Users and developers rightfully deserve access to the Kernel source codes, and for XDA the lack of such an important part of Xiaomi’s modified Android kernel source means that tweaking and tinkering on Xiaomi devices takes a hit. And for a community devoted to exploring the world of Android and turning it into the best it can be, being left out of modifying the software of phones from the fastest growing OEM in the world is an important matter.

There have been petitions to make Xiaomi comply with GPLv2 and release their sources in due time, but so far they have only managed to gain us promises. And these promises still haven’t been kept up. Hugo Barra, vice-president of Xiaomi, promised in October of 2014 that we’d see Kernel sources for the Mi3 in “in the next few weeks”, but that never happened. Moreover, in December of last year they said that their sources would be released not in 2014, but in 2015.

Why didn’t Xiaomi release the sources for their Mi3 device in due time? Hugo Barra said in December that they didn’t do so to prevent an information leak on their upcoming devices. He states:

“The kernel source code for these devices contains a significant amount of source code that will be used in two upcoming models. If we release the kernel source in its current state, we will be revealing more than we would like to about future devices. We will change this going forward, but right now it is a constraint we have to live with. We hope you can understand this position, and we’re very sorry for the frustration we may have caused!”

Does this justify their actions? Of course not. They are a billionaire manufacturer in a billionaire industry, and they knew very well that their code ran under GPLv2’s terms and that they had to comply with it. In 2013 an announcement was made proudly flaunting Xiaomi Kernel’s going open-source. They made a big deal about developers being able to customize ROMs for Xiaomi smartphones, and its apologists touted Xiaomi as being “all about open-source sharing of code”. Fast forward a year and their source codes are delayed over unjustifiable reasons, when their Kernel sources should have been distributed to consumers from the get-go, without waiting for consumers to chase them with pitchforks and without spitting in their faces with absurd delays. And that doesn’t even take into account the work of those who have gone before them, and the proverbial crap Xiaomi (and every other OEM who doesn’t follow GPLv2) takes on them every time they release a new device.

License vs Contract

I want to specify one last thing for those readers who are not familiar with the distinction: GPL is a license and not a contract. Some jurisdictions see key distinctions between these two, as contracts are enforceable by contract law and licenses fall under copyright. So breaking a license’s term is still judicable. The distributors who don’t accept GPL’s terms and conditions can’t copy and distribute GPL software under law. Since they chose to distribute the software, they are guilty of infringement in the eyes of the Law.

Right and Wrong

Whether anyone disagrees with GNU’s vision of democratic, open and inclusive free software, or not, doesn’t make Xiaomi’s decisions, and their reiterative violation of the terms they bought into, any less wrong. They are profiting off of Android at a speed no rival has seen and they do not follow the rules that made Android what it is today, the rules that allowed OEMs and individual developers alike able to foment growth and progress within the OS ecosystem. The rules that millions have respectfully abided by to create their own successful careers, their own successful companies, and our favorite hobby at XDA.

From a practical perspective, going about this in a court of law is not the easiest thing. The government of China is aware of the patent stealing, piracy, and copyright infringements of all sorts and kinds that go on in the country, but is unwilling to do anything about it. Many analysts and academics blame this on latent plagiarism that China has seen for years, some suggesting it could be an integral part of Confucian philosophy on which Chinese culture is largely based on. But whether or not academics, analysts, or frustrated businessmen are correct, the problem of Chinese copyright infringement sees the whole spectrum of products, and Android is no different.

Xiaomi is in the spotlight as one of the most important OEMs of today, with a brand recognition that grows by the day and a possible incursion into the American market soon. While their infringements do not necessarily mean much to the casual Android consumer, it has a severe impact on not just developers, but the ecosystem as a whole. Like the GNU Project suggests, this particular practice, specially in this particular case, hurts the progress of our beloved software.

And this is also a matter of respect, and humbleness. I leave you with a quote of a visionary revolutionary who acknowledged that his impact on the world was so thanks to the previous work of those before him. Let’s hope Xiaomi adopts this philosophy one day, complies with the terms, and helps Android prosper like only it can.


Discuss This Story

READ THIS NEXT