From 60aa12984a948a8ad9c1d17da55ce9b20c2977bc Mon Sep 17 00:00:00 2001
From: =?utf8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
Date: Wed, 4 Aug 2021 13:06:24 +0200
Subject: [PATCH] firmware-utils: replace GPL 2.0+ boilerplate/reference with
 SPDX
MIME-Version: 1.0
Content-Type: text/plain; charset=utf8
Content-Transfer-Encoding: 8bit

This uses "GPL-2.0-or-later" header for files identified using scancode
license scanner with 100% score as GPL 2.0 or later.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
 tools/firmware-utils/src/addpattern.c      | 15 +--------------
 tools/firmware-utils/src/asustrx.c         |  6 +-----
 tools/firmware-utils/src/csysimg.h         | 16 +---------------
 tools/firmware-utils/src/dgn3500sum.c      | 15 +--------------
 tools/firmware-utils/src/encode_crc.c      | 15 +--------------
 tools/firmware-utils/src/fw.h              | 17 ++---------------
 tools/firmware-utils/src/jcgimage.c        | 16 +---------------
 tools/firmware-utils/src/lzma2eva.c        | 15 +--------------
 tools/firmware-utils/src/makeamitbin.c     | 16 +---------------
 tools/firmware-utils/src/mkchkimg.c        | 15 +--------------
 tools/firmware-utils/src/mkcsysimg.c       | 16 +---------------
 tools/firmware-utils/src/mkdlinkfw-lib.c   |  6 +-----
 tools/firmware-utils/src/mkdlinkfw-lib.h   |  6 +-----
 tools/firmware-utils/src/mkdlinkfw.c       |  6 +-----
 tools/firmware-utils/src/mkedimaximg.c     |  7 +------
 tools/firmware-utils/src/mkfwimage.c       | 15 +--------------
 tools/firmware-utils/src/mkfwimage2.c      | 15 +--------------
 tools/firmware-utils/src/mkheader_gemtek.c | 15 +--------------
 tools/firmware-utils/src/motorola-bin.c    | 17 +----------------
 tools/firmware-utils/src/myloader.h        |  7 +------
 tools/firmware-utils/src/oseama.c          |  6 +-----
 tools/firmware-utils/src/otrx.c            |  6 +-----
 tools/firmware-utils/src/ptgen.c           | 15 +--------------
 tools/firmware-utils/src/sign_dlink_ru.c   | 14 +-------------
 tools/firmware-utils/src/spw303v.c         | 15 +--------------
 tools/firmware-utils/src/xorimage.c        | 15 +--------------
 tools/firmware-utils/src/zyxbcm.c          | 15 +--------------
 27 files changed, 28 insertions(+), 314 deletions(-)

diff --git a/tools/firmware-utils/src/addpattern.c b/tools/firmware-utils/src/addpattern.c
index 9791527878..74286fd563 100644
--- a/tools/firmware-utils/src/addpattern.c
+++ b/tools/firmware-utils/src/addpattern.c
@@ -1,19 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2004  Manuel Novoa III  <mjn3@codepoet.org>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 /* July 29, 2004
diff --git a/tools/firmware-utils/src/asustrx.c b/tools/firmware-utils/src/asustrx.c
index 04af9a184a..ce721687d8 100644
--- a/tools/firmware-utils/src/asustrx.c
+++ b/tools/firmware-utils/src/asustrx.c
@@ -1,12 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * asustrx
  *
  * Copyright (C) 2015 Rafał Miłecki <zajec5@gmail.com>
- *
- * 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 <byteswap.h>
diff --git a/tools/firmware-utils/src/csysimg.h b/tools/firmware-utils/src/csysimg.h
index 65ab062f31..1214c7dee4 100644
--- a/tools/firmware-utils/src/csysimg.h
+++ b/tools/firmware-utils/src/csysimg.h
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  *
  *  Copyright (C) 2007,2009 Gabor Juhos <juhosg@openwrt.org>
@@ -5,21 +6,6 @@
  *  This program was based on the code found in various Linux
  *  source tarballs released by Edimax for it's devices.
  *  Original author: David Hsu <davidhsu@realtek.com.tw>
- *
- *  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.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the
- *  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- *  Boston, MA  02110-1301, USA.
  */
 
 #define SIG_LEN		4
diff --git a/tools/firmware-utils/src/dgn3500sum.c b/tools/firmware-utils/src/dgn3500sum.c
index e86621bc1f..6c2937ed51 100644
--- a/tools/firmware-utils/src/dgn3500sum.c
+++ b/tools/firmware-utils/src/dgn3500sum.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /* **************************************************************************
 
    This program creates a modified 16bit checksum used for the Netgear
@@ -9,20 +10,6 @@
 
    Based on previous unattributed work.
 
-   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.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-   General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
  ************************************************************************* */
 
 
diff --git a/tools/firmware-utils/src/encode_crc.c b/tools/firmware-utils/src/encode_crc.c
index 647fb92e89..80f44f133e 100644
--- a/tools/firmware-utils/src/encode_crc.c
+++ b/tools/firmware-utils/src/encode_crc.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /* **************************************************************************
 
    This program creates a CRC checksum and encodes the file that is named
@@ -9,20 +10,6 @@
    Copyright:  Freecom Technology GmbH, Berlin, 2004
                www.freecom.com
 
-  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.
-
-  This program is distributed in the hope that it will be useful,
-  but WITHOUT ANY WARRANTY; without even the implied warranty of
-  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  General Public License for more details.
-
-  You should have received a copy of the GNU General Public License
-  along with this program; if not, write to the Free Software
-  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
  ************************************************************************* */
 
 
diff --git a/tools/firmware-utils/src/fw.h b/tools/firmware-utils/src/fw.h
index c8fb99b467..d2be71e983 100644
--- a/tools/firmware-utils/src/fw.h
+++ b/tools/firmware-utils/src/fw.h
@@ -1,20 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  *  * Copyright (C) 2007 Ubiquiti Networks, Inc.
- *   *
- *    * 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.
- *        *
- *         * This program is distributed in the hope that it will be useful, but
- *          * WITHOUT ANY WARRANTY; without even the implied warranty of
- *           * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- *            * General Public License for more details.
- *             *
- *              * You should have received a copy of the GNU General Public License
- *               * along with this program; if not, write to the Free Software
- *                * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *                 */
+ */
 
 #ifndef FW_INCLUDED
 #define FW_INCLUDED
diff --git a/tools/firmware-utils/src/jcgimage.c b/tools/firmware-utils/src/jcgimage.c
index 81d9f79f52..59a6ac4de5 100644
--- a/tools/firmware-utils/src/jcgimage.c
+++ b/tools/firmware-utils/src/jcgimage.c
@@ -1,23 +1,9 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * jcgimage - Create a JCG firmware image
  *
  * Copyright (C) 2015 Reinhard Max <reinhard@m4x.de>
  * Copyright (C) 2019 Davide Fioravanti <pantanastyle@gmail.com>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
- *
  */
 
 /*
diff --git a/tools/firmware-utils/src/lzma2eva.c b/tools/firmware-utils/src/lzma2eva.c
index 1d7e364889..f72ec74c19 100644
--- a/tools/firmware-utils/src/lzma2eva.c
+++ b/tools/firmware-utils/src/lzma2eva.c
@@ -1,20 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
     lzma2eva - convert lzma-compressed file to AVM EVA bootloader format
     Copyright (C) 2007  Enrik Berkhan <Enrik.Berkhan@inka.de>
-
-    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.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
 */
 
 #include <stdint.h>
diff --git a/tools/firmware-utils/src/makeamitbin.c b/tools/firmware-utils/src/makeamitbin.c
index 5c334424e6..c626d5ce6a 100644
--- a/tools/firmware-utils/src/makeamitbin.c
+++ b/tools/firmware-utils/src/makeamitbin.c
@@ -1,23 +1,9 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  *  makeamitbin - create firmware binaries for MGB100
  *
  *  Copyright (C) 2007 Volker Weiss     <dev@tintuc.de>
  *                     Christian Welzel <dev@welzel-online.ch>
- *
- *  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.
- * 
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- * 
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
  */
 
 
diff --git a/tools/firmware-utils/src/mkchkimg.c b/tools/firmware-utils/src/mkchkimg.c
index dff5169a25..b51eca9369 100644
--- a/tools/firmware-utils/src/mkchkimg.c
+++ b/tools/firmware-utils/src/mkchkimg.c
@@ -1,23 +1,10 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * 	Make CHK Image
  *
  * 	This utility creates Netgear .chk files.
  *
  * 	Copyright (C) 2008 Dave C. Reeve <Dave.Reeve@dreeve.org>
- *
- *	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.
- *
- *	This program is distributed in the hope that it will be useful,
- *	but WITHOUT ANY WARRANTY; without even the implied warranty of
- *	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *	GNU General Public License for more details.
- *	
- *	You should have received a copy of the GNU General Public License along
- *	with this program; if not, write to the Free Software Foundation, Inc.,
- *	51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  */
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/tools/firmware-utils/src/mkcsysimg.c b/tools/firmware-utils/src/mkcsysimg.c
index 0ddb54c4ec..2347e63da1 100644
--- a/tools/firmware-utils/src/mkcsysimg.c
+++ b/tools/firmware-utils/src/mkcsysimg.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  *
  *  Copyright (C) 2007-2009 Gabor Juhos <juhosg@openwrt.org>
@@ -5,21 +6,6 @@
  *  This program was based on the code found in various Linux
  *  source tarballs released by Edimax for it's devices.
  *  Original author: David Hsu <davidhsu@realtek.com.tw>
- *
- *  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.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the
- *  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- *  Boston, MA  02110-1301, USA.
  */
 
 #include <stdio.h>
diff --git a/tools/firmware-utils/src/mkdlinkfw-lib.c b/tools/firmware-utils/src/mkdlinkfw-lib.c
index b3f3f41348..dbe178c6dd 100644
--- a/tools/firmware-utils/src/mkdlinkfw-lib.c
+++ b/tools/firmware-utils/src/mkdlinkfw-lib.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * mkdlinkfw
  *
@@ -6,11 +7,6 @@
  * This tool is based on mktplinkfw.
  * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
  * Copyright (C) 2008,2009 Wang Jian <lark@linux.net.cn>
- *
- * 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 <stdio.h>
diff --git a/tools/firmware-utils/src/mkdlinkfw-lib.h b/tools/firmware-utils/src/mkdlinkfw-lib.h
index da4ecf010c..a459599665 100644
--- a/tools/firmware-utils/src/mkdlinkfw-lib.h
+++ b/tools/firmware-utils/src/mkdlinkfw-lib.h
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * mkdlinkfw
  *
@@ -6,11 +7,6 @@
  * This tool is based on mktplinkfw.
  * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
  * Copyright (C) 2008,2009 Wang Jian <lark@linux.net.cn>
- *
- * 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.
  */
 
 #ifndef mkdlinkfw_lib_h
diff --git a/tools/firmware-utils/src/mkdlinkfw.c b/tools/firmware-utils/src/mkdlinkfw.c
index 3b59a5d2df..6dbaf4ae27 100644
--- a/tools/firmware-utils/src/mkdlinkfw.c
+++ b/tools/firmware-utils/src/mkdlinkfw.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * mkdlinkfw
  *
@@ -6,11 +7,6 @@
  * This tool is based on mktplinkfw.
  * Copyright (C) 2009 Gabor Juhos <juhosg@openwrt.org>
  * Copyright (C) 2008,2009 Wang Jian <lark@linux.net.cn>
- *
- * 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 <stdio.h>
diff --git a/tools/firmware-utils/src/mkedimaximg.c b/tools/firmware-utils/src/mkedimaximg.c
index 541eaaaa3f..899f9f6146 100644
--- a/tools/firmware-utils/src/mkedimaximg.c
+++ b/tools/firmware-utils/src/mkedimaximg.c
@@ -1,11 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2011 Vasilis Tsiligiannis <b_tsiligiannis@silverton.gr>
- *
- * 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 <stdio.h>
diff --git a/tools/firmware-utils/src/mkfwimage.c b/tools/firmware-utils/src/mkfwimage.c
index 5b749a3f66..7f15d1f196 100644
--- a/tools/firmware-utils/src/mkfwimage.c
+++ b/tools/firmware-utils/src/mkfwimage.c
@@ -1,20 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2007 Ubiquiti Networks, Inc.
  * Copyright (C) 2008 Lukas Kuna <ValXdater@seznam.cz>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
 #include <sys/types.h>
diff --git a/tools/firmware-utils/src/mkfwimage2.c b/tools/firmware-utils/src/mkfwimage2.c
index 9d8b2f6f8b..a0db930df2 100644
--- a/tools/firmware-utils/src/mkfwimage2.c
+++ b/tools/firmware-utils/src/mkfwimage2.c
@@ -1,21 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2007 Ubiquiti Networks, Inc.
  * Copyright (C) 2008 Lukas Kuna <ValXdater@seznam.cz>
  * Copyright (C) 2008 Gabor Juhos <juhosg@openwrt.org>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  */
 
 #include <sys/types.h>
diff --git a/tools/firmware-utils/src/mkheader_gemtek.c b/tools/firmware-utils/src/mkheader_gemtek.c
index 9e618efbad..ab72a644ef 100644
--- a/tools/firmware-utils/src/mkheader_gemtek.c
+++ b/tools/firmware-utils/src/mkheader_gemtek.c
@@ -1,19 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2014  Claudio Leite <leitec@staticky.com>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 /*
diff --git a/tools/firmware-utils/src/motorola-bin.c b/tools/firmware-utils/src/motorola-bin.c
index fecb4ce95b..6fda2a9e31 100644
--- a/tools/firmware-utils/src/motorola-bin.c
+++ b/tools/firmware-utils/src/motorola-bin.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * motorola-bin.c
  *
@@ -5,22 +6,6 @@
  *                         Imre Kaloz <kaloz@openwrt.org>
  *                         D. Hugh Redelmeier
  *                         OpenWrt.org
- *
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
- *
  */
 
 /*
diff --git a/tools/firmware-utils/src/myloader.h b/tools/firmware-utils/src/myloader.h
index 7be1d49369..039f2df6d2 100644
--- a/tools/firmware-utils/src/myloader.h
+++ b/tools/firmware-utils/src/myloader.h
@@ -1,11 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  *  Copyright (C) 2006-2008 Gabor Juhos <juhosg@openwrt.org>
- *
- *  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.
- *
  */
 
 #ifndef _MYLOADER_H_
diff --git a/tools/firmware-utils/src/oseama.c b/tools/firmware-utils/src/oseama.c
index 4434b11162..75580e6cf5 100644
--- a/tools/firmware-utils/src/oseama.c
+++ b/tools/firmware-utils/src/oseama.c
@@ -1,12 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * oseama
  *
  * Copyright (C) 2016 Rafał Miłecki <zajec5@gmail.com>
- *
- * 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 <byteswap.h>
diff --git a/tools/firmware-utils/src/otrx.c b/tools/firmware-utils/src/otrx.c
index 3bbbac39e3..b5cd70d6c8 100644
--- a/tools/firmware-utils/src/otrx.c
+++ b/tools/firmware-utils/src/otrx.c
@@ -1,12 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * otrx
  *
  * Copyright (C) 2015-2017 Rafał Miłecki <zajec5@gmail.com>
- *
- * 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 <byteswap.h>
diff --git a/tools/firmware-utils/src/ptgen.c b/tools/firmware-utils/src/ptgen.c
index d911b9d1f0..665c5f7a04 100644
--- a/tools/firmware-utils/src/ptgen.c
+++ b/tools/firmware-utils/src/ptgen.c
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * ptgen - partition table generator
  * Copyright (C) 2006 by Felix Fietkau <nbd@nbd.name>
@@ -7,20 +8,6 @@
  *
  * UUID/GUID definition stolen from kernel/include/uapi/linux/uuid.h
  * Copyright (C) 2010, Intel Corp. Huang Ying <ying.huang@intel.com>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
 #include <sys/types.h>
diff --git a/tools/firmware-utils/src/sign_dlink_ru.c b/tools/firmware-utils/src/sign_dlink_ru.c
index 9c02ed50af..50f2e67bf4 100644
--- a/tools/firmware-utils/src/sign_dlink_ru.c
+++ b/tools/firmware-utils/src/sign_dlink_ru.c
@@ -1,21 +1,9 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * This program is designed to sign firmware images so they are accepted
  * by D-Link DIR-882 R1 WebUIs.
  *
  * Copyright (C) 2020 Andrew Pikler
- * 
- * 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.
- * 
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- * 
- * You should have received a copy of the GNU General Public License
- * along with this program; If not, see <http://www.gnu.org/licenses/>.
  */
 
 #include <stdlib.h>
diff --git a/tools/firmware-utils/src/spw303v.c b/tools/firmware-utils/src/spw303v.c
index 980f41ded6..3244a73a2f 100644
--- a/tools/firmware-utils/src/spw303v.c
+++ b/tools/firmware-utils/src/spw303v.c
@@ -1,21 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * spw303v.c - partially based on OpenWrt's imagetag.c and addpattern.c
  *
  * Copyright (C) 2011  Jonas Gorski <jonas.gorski@gmail.com>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 #include <arpa/inet.h>
diff --git a/tools/firmware-utils/src/xorimage.c b/tools/firmware-utils/src/xorimage.c
index e13531ab4a..94190fd181 100644
--- a/tools/firmware-utils/src/xorimage.c
+++ b/tools/firmware-utils/src/xorimage.c
@@ -1,19 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * xorimage.c - partially based on OpenWrt's addpattern.c
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 
diff --git a/tools/firmware-utils/src/zyxbcm.c b/tools/firmware-utils/src/zyxbcm.c
index 1a2926bfd3..0266c82caf 100644
--- a/tools/firmware-utils/src/zyxbcm.c
+++ b/tools/firmware-utils/src/zyxbcm.c
@@ -1,21 +1,8 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * zyxbcm.c - based on Jonas Gorski's spw303v.c
  *
  * Copyright (C) 2014 Álvaro Fernández Rojas <noltari@gmail.com>
- *
- * 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.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  */
 
 #include <arpa/inet.h>
-- 
2.30.2