> -----Original Message----- > From: Vitaly Chikunov <[email protected]> > Tim, > > On Wed, Feb 18, 2026 at 05:09:38PM -0700, Tim Bird wrote: > > Add SDPX-License-Identifier ID lines to assorted C files in the > > crypto directory, that are missing them. Remove licensing text, > > except in cases where the text itself says that the notice must > > be retained. > > You are saying "except" but in at least two cases in this patch you > removing the following text: "retain the above copyright notice, this > list of conditions and the following disclaimer." Aren't it should be > retained?
The kernel source tree 'retains' the BSD-3-Clause and BSD-2-Clause license text under the LICENSES directory. In cases where I removed them, the text is a match for what's in LICENSES. In the cases where I left the license text in the file (e.g. jitterentropy.c), there was wording that was slightly different, and required to retain "the entire permission notice in its entirety". Ironically, that's the only phrase that's different, but if I removed the notice from the file , it wouldn't be retained anywhere in the kernel source unless I added another license file (which I hesitate to do). I'll explain in subsequent version of the patch why I'm removing the license text, but in general it updates the code to the new licensing standard (which is to just have the SPDX-License-Identifier, without license boilerplate text). Having the 'application' text (for GPL) or the license text itself (for BSD and others) leads to lots of minor variations that are a pain to deal with and cause more legal ambiguity than they are worth. > > Also, in one case below you skip dual-licensing in SPDX record. > > Cam you also state in the commit message the reason why you are removing > existing license texts at all and not just adding SPDX? I will do this in the subsequent versions of the patch. Thanks for the suggestion. > > > > > Signed-off-by: Tim Bird <[email protected]> > > > > --- > > Note that this does not finish adding SPDX id lines to all the > > files, as there are a few special cases with weird license texts. > > --- > > crypto/algif_rng.c | 1 + > > crypto/anubis.c | 7 +------ > > crypto/drbg.c | 1 + > > crypto/ecc.c | 22 +--------------------- > > crypto/fcrypt.c | 33 +-------------------------------- > > crypto/jitterentropy-kcapi.c | 1 + > > crypto/jitterentropy.c | 1 + > > crypto/khazad.c | 7 +------ > > crypto/md4.c | 7 +------ > > crypto/wp512.c | 7 +------ > > 10 files changed, 10 insertions(+), 77 deletions(-) > > > > diff --git a/crypto/algif_rng.c b/crypto/algif_rng.c > > index 1a86e40c8372..a9dffe53e85a 100644 > > --- a/crypto/algif_rng.c > > +++ b/crypto/algif_rng.c > > @@ -1,3 +1,4 @@ > > +// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause > > /* > > * algif_rng: User-space interface for random number generators > > * > > diff --git a/crypto/anubis.c b/crypto/anubis.c > > index 4b01b6ec961a..18b359883d99 100644 > > --- a/crypto/anubis.c > > +++ b/crypto/anubis.c > > @@ -1,3 +1,4 @@ > > +// SPDX-License-Identifier: GPL-2.0-or-later > > /* > > * Cryptographic API. > > * > > @@ -21,12 +22,6 @@ > > * have put this under the GNU General Public License. > > * > > * By Aaron Grothe [email protected], October 28, 2004 > > - * > > - * This program is free software; you can redistribute it and/or modify > > - * it under the terms of the GNU General Public License as published by > > - * the Free Software Foundation; either version 2 of the License, or > > - * (at your option) any later version. > > - * > > */ > > > > #include <crypto/algapi.h> > > diff --git a/crypto/drbg.c b/crypto/drbg.c > > index 5e7ed5f5c192..410cecc45ab9 100644 > > --- a/crypto/drbg.c > > +++ b/crypto/drbg.c > > @@ -1,3 +1,4 @@ > > +// SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause > > /* > > * DRBG: Deterministic Random Bits Generator > > * Based on NIST Recommended DRBG from NIST SP800-90A with the > > following > > diff --git a/crypto/ecc.c b/crypto/ecc.c > > index 2808b3d5f483..c38e4bc0d613 100644 > > --- a/crypto/ecc.c > > +++ b/crypto/ecc.c > > @@ -1,27 +1,7 @@ > > +// SPDX-License-Identifier: BSD-2-Clause > > The file also have the line: > > MODULE_LICENSE("Dual BSD/GPL"); This line is not legally dispositive, but may indicate intent. I'll do some research and see if this means I should adopt an OR clause in the license. Since the entire kernel is GPL-2.0-only, then all instances of BSD IDs alone actually have the meaning of 'GPL-2.0-only OR BSD-whatever'. But it's probably better to be explicit. Thanks for catching that! I need to review MODULE_LICENSE lines in the future and I'll add this to my tooling for this project. The review is much appreciated! -- Tim
