2013-08-16 02:20:23

by Richard Yao

[permalink] [raw]
Subject: Why are BSD-licensed LZ4 symbols GPL exported?

Why are the LZ4 symbols being GPL-exported when the LZ4 code is
BSD-licensed and no substantial changes appear to have been made when it
was merged?

Also, why is the module license GPL when the code itself is clearly
under a BSD license?


Attachments:
signature.asc (901.00 B)
OpenPGP digital signature

2013-08-16 22:25:09

by Richard Laager

[permalink] [raw]
Subject: [PATCH] Correct the LZ4 license

The LZ4 code is listed as using the "BSD 2-Clause License".

Signed-off-by: Richard Laager <[email protected]>
---
lib/lz4/lz4_compress.c | 4 ++--
lib/lz4/lz4_decompress.c | 6 +++---
lib/lz4/lz4hc_compress.c | 4 ++--
3 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/lib/lz4/lz4_compress.c b/lib/lz4/lz4_compress.c
index fd94058..28321d8 100644
--- a/lib/lz4/lz4_compress.c
+++ b/lib/lz4/lz4_compress.c
@@ -437,7 +437,7 @@ int lz4_compress(const unsigned char *src, size_t src_len,
exit:
return ret;
}
-EXPORT_SYMBOL_GPL(lz4_compress);
+EXPORT_SYMBOL(lz4_compress);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4 compressor");
diff --git a/lib/lz4/lz4_decompress.c b/lib/lz4/lz4_decompress.c
index d3414ea..411be80 100644
--- a/lib/lz4/lz4_decompress.c
+++ b/lib/lz4/lz4_decompress.c
@@ -299,7 +299,7 @@ exit_0:
return ret;
}
#ifndef STATIC
-EXPORT_SYMBOL_GPL(lz4_decompress);
+EXPORT_SYMBOL(lz4_decompress);
#endif

int lz4_decompress_unknownoutputsize(const char *src, size_t src_len,
@@ -319,8 +319,8 @@ exit_0:
return ret;
}
#ifndef STATIC
-EXPORT_SYMBOL_GPL(lz4_decompress_unknownoutputsize);
+EXPORT_SYMBOL(lz4_decompress_unknownoutputsize);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4 Decompressor");
#endif
diff --git a/lib/lz4/lz4hc_compress.c b/lib/lz4/lz4hc_compress.c
index eb1a74f..f344f76 100644
--- a/lib/lz4/lz4hc_compress.c
+++ b/lib/lz4/lz4hc_compress.c
@@ -533,7 +533,7 @@ int lz4hc_compress(const unsigned char *src, size_t src_len,
exit:
return ret;
}
-EXPORT_SYMBOL_GPL(lz4hc_compress);
+EXPORT_SYMBOL(lz4hc_compress);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4HC compressor");
--
1.7.9.5

2013-08-17 01:24:03

by Kyungsik Lee

[permalink] [raw]
Subject: Re: [PATCH] Correct the LZ4 license

On Fri, Aug 16, 2013 at 04:45:29PM -0500, Richard Laager wrote:
> The LZ4 code is listed as using the "BSD 2-Clause License".
>
> Signed-off-by: Richard Laager <[email protected]>
> ---
> lib/lz4/lz4_compress.c | 4 ++--
> lib/lz4/lz4_decompress.c | 6 +++---
> lib/lz4/lz4hc_compress.c | 4 ++--
> 3 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/lib/lz4/lz4_compress.c b/lib/lz4/lz4_compress.c
> index fd94058..28321d8 100644
> --- a/lib/lz4/lz4_compress.c
> +++ b/lib/lz4/lz4_compress.c
> @@ -437,7 +437,7 @@ int lz4_compress(const unsigned char *src, size_t src_len,
> exit:
> return ret;
> }
> -EXPORT_SYMBOL_GPL(lz4_compress);
> +EXPORT_SYMBOL(lz4_compress);
>
> -MODULE_LICENSE("GPL");
> +MODULE_LICENSE("Dual BSD/GPL");
> MODULE_DESCRIPTION("LZ4 compressor");
> diff --git a/lib/lz4/lz4_decompress.c b/lib/lz4/lz4_decompress.c
> index d3414ea..411be80 100644
> --- a/lib/lz4/lz4_decompress.c
> +++ b/lib/lz4/lz4_decompress.c
> @@ -299,7 +299,7 @@ exit_0:
> return ret;
> }
> #ifndef STATIC
> -EXPORT_SYMBOL_GPL(lz4_decompress);
> +EXPORT_SYMBOL(lz4_decompress);
> #endif
>
> int lz4_decompress_unknownoutputsize(const char *src, size_t src_len,
> @@ -319,8 +319,8 @@ exit_0:
> return ret;
> }
> #ifndef STATIC
> -EXPORT_SYMBOL_GPL(lz4_decompress_unknownoutputsize);
> +EXPORT_SYMBOL(lz4_decompress_unknownoutputsize);
>
> -MODULE_LICENSE("GPL");
> +MODULE_LICENSE("Dual BSD/GPL");
> MODULE_DESCRIPTION("LZ4 Decompressor");
> #endif
> diff --git a/lib/lz4/lz4hc_compress.c b/lib/lz4/lz4hc_compress.c
> index eb1a74f..f344f76 100644
> --- a/lib/lz4/lz4hc_compress.c
> +++ b/lib/lz4/lz4hc_compress.c
> @@ -533,7 +533,7 @@ int lz4hc_compress(const unsigned char *src, size_t src_len,
> exit:
> return ret;
> }
> -EXPORT_SYMBOL_GPL(lz4hc_compress);
> +EXPORT_SYMBOL(lz4hc_compress);
>
> -MODULE_LICENSE("GPL");
> +MODULE_LICENSE("Dual BSD/GPL");
> MODULE_DESCRIPTION("LZ4HC compressor");

Acked-by: Kyungsik Lee <[email protected]>

Thanks,
Kyungsik

2013-08-20 17:11:59

by Matthew Garrett

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On Thu, Aug 15, 2013 at 10:19:56PM -0400, Richard Yao wrote:
> Why are the LZ4 symbols being GPL-exported when the LZ4 code is
> BSD-licensed and no substantial changes appear to have been made when it
> was merged?

EXPORT_SYMBOL_GPL is intended an indication that using a symbol is
likely to result in you producing a derived work of the kernel, and the
kernel as a whole is under the GPL. It has nothing to do with additional
licenses that individual pieces of code may be available under.

--
Matthew Garrett | [email protected]

2013-08-20 17:38:18

by Joe Perches

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On Tue, 2013-08-20 at 18:11 +0100, Matthew Garrett wrote:
> On Thu, Aug 15, 2013 at 10:19:56PM -0400, Richard Yao wrote:
> > Why are the LZ4 symbols being GPL-exported when the LZ4 code is
> > BSD-licensed and no substantial changes appear to have been made when it
> > was merged?
>
> EXPORT_SYMBOL_GPL is intended an indication that using a symbol is
> likely to result in you producing a derived work of the kernel, and the
> kernel as a whole is under the GPL. It has nothing to do with additional
> licenses that individual pieces of code may be available under.

Maybe not.

http://www.ifross.org/en/artikel/ongoing-dispute-over-value-exportsymbolgpl-function

2013-08-20 21:37:53

by Rob Landley

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On 08/20/2013 12:38:14 PM, Joe Perches wrote:
> On Tue, 2013-08-20 at 18:11 +0100, Matthew Garrett wrote:
> > On Thu, Aug 15, 2013 at 10:19:56PM -0400, Richard Yao wrote:
> > > Why are the LZ4 symbols being GPL-exported when the LZ4 code is
> > > BSD-licensed and no substantial changes appear to have been made
> when it
> > > was merged?
> >
> > EXPORT_SYMBOL_GPL is intended an indication that using a symbol is
> > likely to result in you producing a derived work of the kernel, and
> the
> > kernel as a whole is under the GPL. It has nothing to do with
> additional
> > licenses that individual pieces of code may be available under.
>
> Maybe not.
>
> http://www.ifross.org/en/artikel/ongoing-dispute-over-value-exportsymbolgpl-function

Kernel developers: "We're making symbols that we, as the creators of
this project, don't think you can use without the result being a
derived work".

Lawyers: "we're prepared to argue over the definitions of 'that', 'as',
'of', 'this', 'use', and 'the', as long as we're paid by the hour."

This random speculation outside of a courtroom actually capable of
setting precedent strikes you as relevant for what reason?

Rob-

2013-08-20 21:46:36

by Joe Perches

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On Tue, 2013-08-20 at 16:37 -0500, Rob Landley wrote:
> On 08/20/2013 12:38:14 PM, Joe Perches wrote:
> > On Tue, 2013-08-20 at 18:11 +0100, Matthew Garrett wrote:
> > > On Thu, Aug 15, 2013 at 10:19:56PM -0400, Richard Yao wrote:
> > > > Why are the LZ4 symbols being GPL-exported when the LZ4 code is
> > > > BSD-licensed and no substantial changes appear to have been made
> > when it
> > > > was merged?
> > >
> > > EXPORT_SYMBOL_GPL is intended an indication that using a symbol is
> > > likely to result in you producing a derived work of the kernel, and
> > the
> > > kernel as a whole is under the GPL. It has nothing to do with
> > additional
> > > licenses that individual pieces of code may be available under.
> >
> > Maybe not.
> > http://www.ifross.org/en/artikel/ongoing-dispute-over-value-exportsymbolgpl-function
>
> Kernel developers: "We're making symbols that we, as the creators of
> this project, don't think you can use without the result being a
> derived work".
>
> Lawyers: "we're prepared to argue over the definitions of 'that', 'as',
> 'of', 'this', 'use', and 'the', as long as we're paid by the hour."

Law is certainly a, umm, useful occupation.

> This random speculation outside of a courtroom actually capable of
> setting precedent strikes you as relevant for what reason?

Because your declarative statement that EXPORT_SYMBOL_GPL is
"intended [as] an indication that using [the] symbol is likely
to result..." is incomplete.

There are competing histories as to what EXPORT_SYMBOL_GPL
was intended to do.

2013-08-20 22:07:10

by Joe Perches

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On Tue, 2013-08-20 at 14:46 -0700, Joe Perches wrote:
> Because your

Sorry, not your's but Matthew's.

I do think the MODULE_LICENSE should be "Dual BSD/GPL"
instead of merely "GPL" if for no other reason than
politeness to the original developer and the
license at the top of the files.

* LZ4 - Fast LZ compression algorithm
* Copyright (C) 2011-2012, Yann Collet.
* BSD 2-Clause License (http://www.opensource.org/licenses/bsd-license.php)

---
lib/lz4/lz4_compress.c | 2 +-
lib/lz4/lz4_decompress.c | 2 +-
lib/lz4/lz4hc_compress.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/lz4/lz4_compress.c b/lib/lz4/lz4_compress.c
index fd94058..a4001ee 100644
--- a/lib/lz4/lz4_compress.c
+++ b/lib/lz4/lz4_compress.c
@@ -439,5 +439,5 @@ exit:
}
EXPORT_SYMBOL_GPL(lz4_compress);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4 compressor");
diff --git a/lib/lz4/lz4_decompress.c b/lib/lz4/lz4_decompress.c
index d3414ea..c45e685 100644
--- a/lib/lz4/lz4_decompress.c
+++ b/lib/lz4/lz4_decompress.c
@@ -321,6 +321,6 @@ exit_0:
#ifndef STATIC
EXPORT_SYMBOL_GPL(lz4_decompress_unknownoutputsize);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4 Decompressor");
#endif
diff --git a/lib/lz4/lz4hc_compress.c b/lib/lz4/lz4hc_compress.c
index eb1a74f..59f26e6 100644
--- a/lib/lz4/lz4hc_compress.c
+++ b/lib/lz4/lz4hc_compress.c
@@ -535,5 +535,5 @@ exit:
}
EXPORT_SYMBOL_GPL(lz4hc_compress);

-MODULE_LICENSE("GPL");
+MODULE_LICENSE("Dual BSD/GPL");
MODULE_DESCRIPTION("LZ4HC compressor");

2013-08-20 22:33:11

by Matthew Garrett

[permalink] [raw]
Subject: Re: Why are BSD-licensed LZ4 symbols GPL exported?

On Tue, Aug 20, 2013 at 02:46:33PM -0700, Joe Perches wrote:

> There are competing histories as to what EXPORT_SYMBOL_GPL
> was intended to do.

Not really. The original discussion is hardly difficult to find.

--
Matthew Garrett | [email protected]