[PATCH 1/6] src/tools: add SPDX tags to all files

Jason A. Donenfeld Jason at zx2c4.com
Fri Dec 1 00:49:09 CET 2017


On Thu, Nov 30, 2017 at 6:57 PM, Jason A. Donenfeld <Jason at zx2c4.com> wrote:
> On Thu, Nov 30, 2017 at 4:23 PM, Greg Kroah-Hartman
> <gregkh at linuxfoundation.org> wrote:
>> It's good to have SPDX identifiers in all files as the Linux kernel
>> diff --git a/src/tools/config.c b/src/tools/config.c
>> index 6ff03767f9e6..312cbcdd7a85 100644
>> --- a/src/tools/config.c
>> +++ b/src/tools/config.c
>> @@ -1,3 +1,4 @@
>> +// SPDX-License-Identifier: GPL-2.0
>>  /* Copyright (C) 2015-2017 Jason A. Donenfeld <Jason at zx2c4.com>. All Rights Reserved. */
>>
>>  #include <arpa/inet.h>
>> diff --git a/src/tools/config.h b/src/tools/config.h
>> index 63a272cc1285..e3ad9f87404b 100644
>> --- a/src/tools/config.h
>> +++ b/src/tools/config.h
>> @@ -1,3 +1,4 @@
>> +/* SPDX-License-Identifier: GPL-2.0 */
>>  /* Copyright (C) 2015-2017 Jason A. Donenfeld <Jason at zx2c4.com>. All Rights Reserved. */
>
> It looks like you're giving .h a /* style comment and .c a // style
> comment. Is there a reason for this, or did you just have two
> different sed commands by accident?

zx2c4 at thinkpad ~/Projects/linux $ grep -rl '/* SPDX-' | sed
's/.*\/\([^/]\+\)$/\1/;s/.*\.\(.\+\)$/\1/' | sort | uniq -c | sort -nr
| head -n 5
  7621 h
  3671 c
  1193 Makefile
   486 S
   221 dts
zx2c4 at thinkpad ~/Projects/linux $ grep -rl '// SPDX-' | sed
's/.*\/\([^/]\+\)$/\1/;s/.*\.\(.\+\)$/\1/' | sort | uniq -c | sort -nr
| head -n 5
  3655 c
   326 h
   187 dts
   147 dtsi
     8 cocci

Doesn't seem like there's much rhyme or reason to it.


More information about the WireGuard mailing list