# BSD 2-Clause license. What is allowed?



## Phishfry (Nov 6, 2022)

I would like to get some clarification on FreeBSD driver licensing and what is permissible.
Lets say I want to contribute a driver for INA3221 under the most permissive license. BSD-2 clause.

What is the critera for looking at other licensed code. Is it allowed at all? No copying obviously.
Where does taint begin?

We have GPL-2.0 license source from TI:








						linux/ina3221.c at master · torvalds/linux
					

Linux kernel source tree. Contribute to torvalds/linux development by creating an account on GitHub.




					github.com
				




And BSD licensed source here:




__





						driver/ina3221.c - chromiumos/platform/ec - Git at Google
					





					chromium.googlesource.com
				




Am I now legally tainted by looking at the GPL licensed code?


----------



## Phishfry (Nov 6, 2022)

I only offer this as a hypothetical question.
I am not a programmer and could not make a driver without help.
Don't take the legal aspect seriously.


----------



## cmoerz (Nov 6, 2022)

Was this kind of question ever answered definitively in legal terms? Would that even apply to all countries of the world equally?
Kind of reminds me of "Halt and Catch Fire Season 1" and its depiction of the clean room reimplementation of the IBM bios.
If you follow recent Oracle vs Google developments, you might get scrutinized for even duplicating an API. And with the looming question whether software patents can actually be enforced, it gets dicier and dicier.

Obviously, if you implement particular syscalls to provide network functionality, you might expect some structural similarity to the GPL code, whether you like it or not. Then again, I haven't looked at that source code either, so maybe there's ways around it.

How would you even prove that you never looked at the code (unless you admit it)? Last I remember is, you can't prove a negative?


----------



## mer (Nov 6, 2022)

Thinking about device drivers, my experience is the people making the hardware demand all kinds of NDAs to even look at documentation.
So if you need an NDA to look at the docs, can you legally release a driver under any open source license?

As for the specific question of "if I looked at GPL code can I create BSD licensed code?"  I'm not sure, part of me says "I think you should be able to" but not being a lawyer, I don't know.


----------



## Alain De Vos (Nov 6, 2022)

Can I say, it's not wrong to the same thing.
But it's wrong to do the same thing in exactly the same way (ie copy).


----------



## cmoerz (Nov 6, 2022)

Does a painter, who looks at another painter's painting break copyright law, if he paints a new painting that resembles the original? There's fair use and all, but there's also very murky waters as recent lawsuits show:








						Microsoft sued for open-source piracy through GitHub Copilot
					

Programmer and lawyer Matthew Butterick has sued Microsoft, GitHub, and OpenAI, alleging that GitHub's Copilot violates the terms of open-source licenses and infringes the rights of code authors.




					www.bleepingcomputer.com
				




And there's not even a human involved... that litigation probably is going to open a big can of worms.

I don't think there's sufficient precedent (yet?) to succinctly interpret legal leeway for "being inspired" by original art (source) work.

Do you break a license if there is no obvious alternative way to build something? You'd still end up with a duplicate and, as Alain De Vox points out, that would likely not be permissible?


----------



## mer (Nov 6, 2022)

Fair use.  Often misused by both sides of the lawsuit.  Overzealous prosecution by companies/copyright holders, Overly Liberal interpretation in using the material.

If you poke around you find lots of youtube channels that talk about "what makes this song great" or "the top 20 rock guitar riffs in history".  Some of the bands threaten and get things taken down if you have 3 or more connected notes (Sweet Child O' Mine, Hotel California are a couple that get whacked hard), when a reasonable person would say "15 secs of a song, while talking about the technical aspects of it, not claiming ownership in fact giving credit to the original artist and doing it for no financial gain" is the very definition of Fair Use.

Device Drivers:
Different OS have different structures when writing a device driver, but if you need to read/modify/write an eight bit register, configure interrupts, configure DMA rings, well, every single device driver for that specific device is going to look the same.  The NDA the hardware folks want to enforce relate to the specific meaning of a specific register and the bits within.  If that information is available by looking at the source of a GPL driver, "reusing" that information in a BSD licensed driver should be fair use or irrelevant.

But I'm not a lawyer, I don't even pretend to play one on the Internet, so the above is just my opinion and should not be considered as legal advice.


----------

