SPDX: Convert all of our single license tags to Linux Kernel style
When U-Boot started using SPDX tags we were among the early adopters and
there weren't a lot of other examples to borrow from. So we picked the
area of the file that usually had a full license text and replaced it
with an appropriate SPDX-License-Identifier: entry. Since then, the
Linux Kernel has adopted SPDX tags and they place it as the very first
line in a file (except where shebangs are used, then it's second line)
and with slightly different comment styles than us.
In part due to community overlap, in part due to better tag visibility
and in part for other minor reasons, switch over to that style.
This commit changes all instances where we have a single declared
license in the tag as both the before and after are identical in tag
contents. There's also a few places where I found we did not have a tag
and have introduced one.
Signed-off-by: Tom Rini <trini@konsulko.com>
diff --git a/include/dm/device-internal.h b/include/dm/device-internal.h
index eaeadd4..5a4d50c 100644
--- a/include/dm/device-internal.h
+++ b/include/dm/device-internal.h
@@ -1,11 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (C) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
* Marek Vasut <marex@denx.de>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_DEVICE_INTERNAL_H
diff --git a/include/dm/device.h b/include/dm/device.h
index 7786b1c..49078bc 100644
--- a/include/dm/device.h
+++ b/include/dm/device.h
@@ -1,11 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
* Marek Vasut <marex@denx.de>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_DEVICE_H
diff --git a/include/dm/fdtaddr.h b/include/dm/fdtaddr.h
index c46f0e9..db4c11e 100644
--- a/include/dm/fdtaddr.h
+++ b/include/dm/fdtaddr.h
@@ -1,11 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2017 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
* Marek Vasut <marex@denx.de>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_FDTADDR_H
diff --git a/include/dm/lists.h b/include/dm/lists.h
index d4d82d2..13d1516 100644
--- a/include/dm/lists.h
+++ b/include/dm/lists.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_LISTS_H_
diff --git a/include/dm/of.h b/include/dm/of.h
index d4d941e..461e25a 100644
--- a/include/dm/of.h
+++ b/include/dm/of.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2017 Google, Inc
* Written by Simon Glass <sjg@chromium.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_OF_H
diff --git a/include/dm/of_access.h b/include/dm/of_access.h
index c49d287..74f0606 100644
--- a/include/dm/of_access.h
+++ b/include/dm/of_access.h
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Originally from Linux v4.9
* Copyright (C) 1996-2005 Paul Mackerras.
@@ -11,8 +12,6 @@
*
* Modified for U-Boot
* Copyright (c) 2017 Google, Inc
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_OF_ACCESS_H
diff --git a/include/dm/of_addr.h b/include/dm/of_addr.h
index 25ca05b..12b1a99 100644
--- a/include/dm/of_addr.h
+++ b/include/dm/of_addr.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Taken from Linux v4.9 drivers/of/address.c
*
* Modified for U-Boot
* Copyright (c) 2017 Google, Inc
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_OF_ADDR_H
diff --git a/include/dm/of_extra.h b/include/dm/of_extra.h
index 01b6ebe..6f15296 100644
--- a/include/dm/of_extra.h
+++ b/include/dm/of_extra.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2017 Google, Inc
* Written by Simon Glass <sjg@chromium.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_OF_EXTRA_H
diff --git a/include/dm/ofnode.h b/include/dm/ofnode.h
index 0d00840..be3f25d 100644
--- a/include/dm/ofnode.h
+++ b/include/dm/ofnode.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2017 Google, Inc
* Written by Simon Glass <sjg@chromium.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_OFNODE_H
diff --git a/include/dm/pinctrl.h b/include/dm/pinctrl.h
index c6c8f61..80de3f3 100644
--- a/include/dm/pinctrl.h
+++ b/include/dm/pinctrl.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __PINCTRL_H
diff --git a/include/dm/platdata.h b/include/dm/platdata.h
index b73aa33..c972fa6 100644
--- a/include/dm/platdata.h
+++ b/include/dm/platdata.h
@@ -1,11 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
* Marek Vasut <marex@denx.de>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_PLATDATA_H
diff --git a/include/dm/platform_data/lpc32xx_hsuart.h b/include/dm/platform_data/lpc32xx_hsuart.h
index fd191b5..9bfd628 100644
--- a/include/dm/platform_data/lpc32xx_hsuart.h
+++ b/include/dm/platform_data/lpc32xx_hsuart.h
@@ -1,6 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2015 Vladimir Zapolskiy <vz@mleia.com>
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _LPC32XX_HSUART_PLAT_H
diff --git a/include/dm/platform_data/net_ethoc.h b/include/dm/platform_data/net_ethoc.h
index 3f94bde..855e999 100644
--- a/include/dm/platform_data/net_ethoc.h
+++ b/include/dm/platform_data/net_ethoc.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (C) 2016 Cadence Design Systems Inc.
- *
- * SPDX-License-Identifier: GPL-2.0
*/
#ifndef _ETHOC_H
diff --git a/include/dm/platform_data/pfe_dm_eth.h b/include/dm/platform_data/pfe_dm_eth.h
index 7943c67..100a981 100644
--- a/include/dm/platform_data/pfe_dm_eth.h
+++ b/include/dm/platform_data/pfe_dm_eth.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright 2015-2016 Freescale Semiconductor, Inc.
* Copyright 2017 NXP
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __PFE_DM_ETH_H__
diff --git a/include/dm/platform_data/serial_bcm283x_mu.h b/include/dm/platform_data/serial_bcm283x_mu.h
index 57ae6ad..37f5174 100644
--- a/include/dm/platform_data/serial_bcm283x_mu.h
+++ b/include/dm/platform_data/serial_bcm283x_mu.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* (C) Copyright 2016 Stephen Warren <swarren@wwwdotorg.org>
*
* Derived from pl01x code:
* Copyright (c) 2014 Google, Inc
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __serial_bcm283x_mu_h
diff --git a/include/dm/platform_data/serial_coldfire.h b/include/dm/platform_data/serial_coldfire.h
index 5d86456..ba916fe 100644
--- a/include/dm/platform_data/serial_coldfire.h
+++ b/include/dm/platform_data/serial_coldfire.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2015 Angelo Dureghello <angelo@sysam.it>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __serial_coldfire_h
diff --git a/include/dm/platform_data/serial_mxc.h b/include/dm/platform_data/serial_mxc.h
index 7bcd280..86cd3bc 100644
--- a/include/dm/platform_data/serial_mxc.h
+++ b/include/dm/platform_data/serial_mxc.h
@@ -1,6 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2014 Google, Inc
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __serial_mxc_h
diff --git a/include/dm/platform_data/serial_pl01x.h b/include/dm/platform_data/serial_pl01x.h
index ccfa808..77d96c4 100644
--- a/include/dm/platform_data/serial_pl01x.h
+++ b/include/dm/platform_data/serial_pl01x.h
@@ -1,6 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2014 Google, Inc
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __serial_pl01x_h
diff --git a/include/dm/platform_data/serial_pxa.h b/include/dm/platform_data/serial_pxa.h
index b19a4a6..408c008 100644
--- a/include/dm/platform_data/serial_pxa.h
+++ b/include/dm/platform_data/serial_pxa.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2016 Marcel Ziswiler <marcel.ziswiler@toradex.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __SERIAL_PXA_H
diff --git a/include/dm/platform_data/serial_sh.h b/include/dm/platform_data/serial_sh.h
index 0271ad6..711435d 100644
--- a/include/dm/platform_data/serial_sh.h
+++ b/include/dm/platform_data/serial_sh.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2014 Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
* Copyright (c) 2014 Renesas Electronics Corporation
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __serial_sh_h
diff --git a/include/dm/platform_data/serial_stm32.h b/include/dm/platform_data/serial_stm32.h
index d1cfcbe..85153df 100644
--- a/include/dm/platform_data/serial_stm32.h
+++ b/include/dm/platform_data/serial_stm32.h
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* (C) Copyright 2015
* Kamil Lulko, <kamil.lulko@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __SERIAL_STM32_H
diff --git a/include/dm/read.h b/include/dm/read.h
index f14c7a7..4a725bc 100644
--- a/include/dm/read.h
+++ b/include/dm/read.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Function to read values from the device tree node attached to a udevice.
*
* Copyright (c) 2017 Google, Inc
* Written by Simon Glass <sjg@chromium.org>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_READ_H
diff --git a/include/dm/root.h b/include/dm/root.h
index b075eef..2b9c6da 100644
--- a/include/dm/root.h
+++ b/include/dm/root.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_ROOT_H_
diff --git a/include/dm/test.h b/include/dm/test.h
index cecee26..83418eb 100644
--- a/include/dm/test.h
+++ b/include/dm/test.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc.
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __DM_TEST_H
diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h
index d28fb3e..d7f9df3 100644
--- a/include/dm/uclass-id.h
+++ b/include/dm/uclass-id.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_UCLASS_ID_H
diff --git a/include/dm/uclass-internal.h b/include/dm/uclass-internal.h
index c086004..7ba064b 100644
--- a/include/dm/uclass-internal.h
+++ b/include/dm/uclass-internal.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_UCLASS_INTERNAL_H
diff --git a/include/dm/uclass.h b/include/dm/uclass.h
index a5bf3eb..9fbaa7d 100644
--- a/include/dm/uclass.h
+++ b/include/dm/uclass.h
@@ -1,10 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
*
* (C) Copyright 2012
* Pavel Herrmann <morpheus.ibis@gmail.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef _DM_UCLASS_H
diff --git a/include/dm/util.h b/include/dm/util.h
index 0d4ce8f..898822e 100644
--- a/include/dm/util.h
+++ b/include/dm/util.h
@@ -1,7 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (c) 2013 Google, Inc
- *
- * SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __DM_UTIL_H