libbpf: relicense bpf_helpers.h and bpf_endian.h
Subsystems (5)
PATCH 1/1 libbpf: relicense bpf_helpers.h and bpf_endian.h
bpf_helpers.h and bpf_endian.h contain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.
--- tools/testing/selftests/bpf/bpf_endian.h | 2 +- tools/testing/selftests/bpf/bpf_helpers.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
tools/testing/selftests/bpf/bpf_endian.h +1 -1
@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_ENDIAN__#define __BPF_ENDIAN__
tools/testing/selftests/bpf/bpf_helpers.h +1 -1
@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_HELPERS_H#define __BPF_HELPERS_H
Signature · 1 line
2.17.1
Quoted 5 lines · On Thu, 15 Aug 2019 22:45:43 -0700 Andrii Nakryiko <[email protected]> wrote:
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.
I've already ACKed this, and is fine with (LGPL-2.1 OR BSD-2-Clause).
I just want to understand, why "BSD-2-Clause" and not "Apache-2.0" ?
The original argument was that this needed to be compatible with "Apache-2.0", then why not simply add this in the "OR" ?
Quoted 6 lines
Acked-by Hechao Li <[email protected]>Acked-by Martin KaFai Lau <[email protected]>Acked-by Andrey Ignatov <[email protected]>Acked-by Yonghong Song <[email protected]>Acked-by Lawrence Brakmo <[email protected]>
Quoted 8 lines
Acked-by Adam Barth <[email protected]>Acked-by Roman Gushchin <[email protected]>Acked-by Josef Bacik <[email protected]>Acked-by Joe Stringer <[email protected]>Acked-by Daniel Borkmann <[email protected]>Acked-by David Ahern <[email protected]>
Confirming I acked this.
Quoted 39 lines
Acked-by Ilya Leoshkevich <[email protected]>Acked-by Lorenz Bauer <[email protected]>Acked-by Adrian Ratiu <[email protected]>Acked-by Willem de Bruijn <[email protected]>Acked-by Petar Penkov <[email protected]>Acked-by Teng Qin <[email protected]>Cc Michael Holzheu <[email protected]>Cc Naveen N. Rao <[email protected]>Cc David S. Miller <[email protected]>Cc Michal Rostecki <[email protected]>Cc John Fastabend <[email protected]>Cc Sargun Dhillon <[email protected]>Signed-off-by Andrii Nakryiko <[email protected]>--- tools/testing/selftests/bpf/bpf_endian.h | 2 +- tools/testing/selftests/bpf/bpf_helpers.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)tools/testing/selftests/bpf/bpf_endian.h +1
-1@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_ENDIAN__#define __BPF_ENDIAN__tools/testing/selftests/bpf/bpf_helpers.h +1
-1@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_HELPERS_H#define __BPF_HELPERS_H
Signature · 4 lines
Best regards, Jesper Dangaard Brouer MSc.CS, Principal Kernel Engineer at Red Hat LinkedIn: http://www.linkedin.com/in/brouer
Daniel Borkmann
maintainerQuoted 9 lines · Jesper Dangaard Brouer
Quoted 5 lines · On Thu, 15 Aug 2019 22:45:43 -0700 Andrii Nakryiko <[email protected]> wrote:
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.
Quoted 6 lines
I've already ACKed this, and is fine with (LGPL-2.1 OR BSD-2-Clause).
I just want to understand, why "BSD-2-Clause" and not "Apache-2.0" ?
The original argument was that this needed to be compatible with "Apache-2.0", then why not simply add this in the "OR" ?
It's use is discouraged in the kernel tree, see also LICENSES/dual/Apache-2.0 (below) and statement wrt compatibility from https://www.apache.org/licenses/GPL-compatibility.html:
Valid-License-Identifier: Apache-2.0
SPDX-URL: https://spdx.org/licenses/Apache-2.0.html
Usage-Guide:
Do NOT use. The Apache-2.0 is not GPL2 compatible. [...]
Quoted 59 lines
Quoted 6 lines
Acked-by Hechao Li <[email protected]>Acked-by Martin KaFai Lau <[email protected]>Acked-by Andrey Ignatov <[email protected]>Acked-by Yonghong Song <[email protected]>Acked-by Lawrence Brakmo <[email protected]>Quoted 8 lines
Acked-by Adam Barth <[email protected]>Acked-by Roman Gushchin <[email protected]>Acked-by Josef Bacik <[email protected]>Acked-by Joe Stringer <[email protected]>Acked-by Daniel Borkmann <[email protected]>Acked-by David Ahern <[email protected]>Confirming I acked this.
Quoted 39 lines
Acked-by Ilya Leoshkevich <[email protected]>Acked-by Lorenz Bauer <[email protected]>Acked-by Adrian Ratiu <[email protected]>Acked-by Willem de Bruijn <[email protected]>Acked-by Petar Penkov <[email protected]>Acked-by Teng Qin <[email protected]>Cc Michael Holzheu <[email protected]>Cc Naveen N. Rao <[email protected]>Cc David S. Miller <[email protected]>Cc Michal Rostecki <[email protected]>Cc John Fastabend <[email protected]>Cc Sargun Dhillon <[email protected]>Signed-off-by Andrii Nakryiko <[email protected]>--- tools/testing/selftests/bpf/bpf_endian.h | 2 +- tools/testing/selftests/bpf/bpf_helpers.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)tools/testing/selftests/bpf/bpf_endian.h +1
-1@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_ENDIAN__#define __BPF_ENDIAN__tools/testing/selftests/bpf/bpf_helpers.h +1
-1@@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */ #ifndef __BPF_HELPERS_H#define __BPF_HELPERS_H
Quoted 17 lines · Daniel Borkmann
Quoted 9 lines · Jesper Dangaard Brouer
Quoted 5 lines · On Thu, 15 Aug 2019 22:45:43 -0700 Andrii Nakryiko <[email protected]> wrote:
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.Quoted 6 lines
I've already ACKed this, and is fine with (LGPL-2.1 OR BSD-2-Clause).
I just want to understand, why "BSD-2-Clause" and not "Apache-2.0" ?
The original argument was that this needed to be compatible with "Apache-2.0", then why not simply add this in the "OR" ?
Quoted 7 lines
It's use is discouraged in the kernel tree, see also
LICENSES/dual/Apache-2.0(below) and statement wrt compatibility from https://www.apache.org/licenses/GPL-compatibility.html:Valid-License-Identifier: Apache-2.0
SPDX-URL: https://spdx.org/licenses/Apache-2.0.html
Usage-Guide:
Do NOT use. The Apache-2.0 is not GPL2 compatible. [...]
That is correct, don't use Apache-2 code in the kernel please. Even as a dual-license, it's a total mess.
Having this be BSD-2 is actually better, as it should be fine to use with Apache 2 code, right?
Jesper, do you know of any license that BSD-2 is not compatible with that is needed?
thanks,
greg k-h
Quoted 18 lines · On Fri, 16 Aug 2019 19:15:29 +0200 Greg KH <[email protected]> wrote:
Quoted 17 lines · Daniel Borkmann
Quoted 15 lines · Jesper Dangaard Brouer
Quoted 5 lines · On Thu, 15 Aug 2019 22:45:43 -0700 Andrii Nakryiko <[email protected]> wrote:
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.I've already ACKed this, and is fine with (LGPL-2.1 OR BSD-2-Clause).
I just want to understand, why "BSD-2-Clause" and not "Apache-2.0" ?
The original argument was that this needed to be compatible with "Apache-2.0", then why not simply add this in the "OR" ?
Quoted 7 lines
Quoted 7 lines
It's use is discouraged in the kernel tree, see also
LICENSES/dual/Apache-2.0(below) and statement wrt compatibility from https://www.apache.org/licenses/GPL-compatibility.html:Valid-License-Identifier: Apache-2.0
SPDX-URL: https://spdx.org/licenses/Apache-2.0.html
Usage-Guide:
Do NOT use. The Apache-2.0 is not GPL2 compatible. [...]
You didn't quote the continuation from LICENSES/dual/Apache-2.0
Usage-Guide:
Do NOT use. The Apache-2.0 is not GPL2 compatible. It may only be used for dual-licensed files where the other license is GPL2 compatible. If you end up using this it MUST be used together with a GPL2 compatible license using "OR".
The way I read it, is that you can use it with "OR", like:
SPDX-License-Identifier: GPL-2.0 OR Apache-2.0
Quoted 2 lines
That is correct, don't use Apache-2 code in the kernel please. Even as a dual-license, it's a total mess.
Good, I just wanted to understand why.
Quoted 2 lines
Having this be BSD-2 is actually better, as it should be fine to use with Apache 2 code, right?
Yes, that is also my understanding. And it better be as this is needed, as we want libbpf to be used by https://github.com/iovisor/bcc/ which is Apache-2.0.
Quoted 2 lines
Jesper, do you know of any license that BSD-2 is not compatible with that is needed?
No.
Signature · 4 lines
Best regards, Jesper Dangaard Brouer MSc.CS, Principal Kernel Engineer at Red Hat LinkedIn: http://www.linkedin.com/in/brouer
Quoted 26 lines · Andrii Nakryiko
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.Acked-by Hechao Li <[email protected]>Acked-by Martin KaFai Lau <[email protected]>Acked-by Andrey Ignatov <[email protected]>Acked-by Yonghong Song <[email protected]>Acked-by Lawrence Brakmo <[email protected]>Acked-by Adam Barth <[email protected]>Acked-by Roman Gushchin <[email protected]>Acked-by Josef Bacik <[email protected]>Acked-by Joe Stringer <[email protected]>Acked-by Daniel Borkmann <[email protected]>Acked-by David Ahern <[email protected]>Acked-by Ilya Leoshkevich <[email protected]>Acked-by Lorenz Bauer <[email protected]>Acked-by Adrian Ratiu <[email protected]>Acked-by Willem de Bruijn <[email protected]>Acked-by Petar Penkov <[email protected]>
Quoted 8 lines
Acked-by Teng Qin <[email protected]>Cc Michael Holzheu <[email protected]>Cc Naveen N. Rao <[email protected]>Cc David S. Miller <[email protected]>Cc Michal Rostecki <[email protected]>Cc John Fastabend <[email protected]>Cc Sargun Dhillon <[email protected]>Signed-off-by Andrii Nakryiko <[email protected]>
Applied, thanks!
Quoted 5 lines · Andrii Nakryiko
bpf_helpers.handbpf_endian.hcontain useful macros and BPF helper definitions essential to almost every BPF program. Which makes them useful not just for selftests. To be able to expose them as part of libbpf, though, we need them to be dual-licensed as LGPL-2.1 OR BSD-2-Clause. This patch updates licensing of those two files.
Quite late, but FWIW:
- Naveen