2018-06-05 17:58:10

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 0/8] cros_ec: Switch to SPDX identifier.

Dear all,

This patchset is just to adopt the SPDX license identifier for all
ChromeOS Embedded Controller related drivers. The patches touches
different subsystems but every patch can be picked from their respective
maintainer independently.

This second version fixes some copy paste errors in the copyright year
and takes care to no remove the paragraphs that have nothing to do with
license notice.

Thanks,
Enric

Changes in v2:
- Removed '[PATCH 5/9] rtc: cros-ec: Switch to SPDX identifier' from
series as it was applied.
- s/Chrome OS/ChromeOS/
- [1/9] Fixed wrong copyright year.
- [6/9] Do not remove last paragraph.
- [8/9] Fixed wrong copyright year.

Enric Balletbo i Serra (8):
platform/chrome: cros_ec: Switch to SPDX identifier.
platform/chrome: pstore: Switch to SPDX identifier.
mfd: cros_ec: Add or fix SPDX-License-Identifier in all files.
iio: cros_ec: Switch to SPDX identifier.
Input: cros_ec_keyb - Switch to SPDX identifier.
pwm: cros-ec: Switch to SPDX identifier.
extcon: usbc-cros-ec: Switch to SPDX identifier.
i2c: i2c-cros-ec-tunnel: Switch to SPDX identifier.

drivers/extcon/extcon-usbc-cros-ec.c | 20 +++--------
drivers/i2c/busses/i2c-cros-ec-tunnel.c | 14 +++-----
drivers/iio/accel/cros_ec_accel_legacy.c | 27 +++++----------
.../common/cros_ec_sensors/cros_ec_sensors.c | 24 ++++---------
.../cros_ec_sensors/cros_ec_sensors_core.c | 18 +++-------
.../cros_ec_sensors/cros_ec_sensors_core.h | 12 ++-----
drivers/iio/light/cros_ec_light_prox.c | 18 +++-------
drivers/iio/pressure/cros_ec_baro.c | 18 +++-------
drivers/input/keyboard/cros_ec_keyb.c | 34 +++++++------------
drivers/mfd/cros_ec.c | 26 +++++---------
drivers/mfd/cros_ec_dev.c | 23 +++----------
drivers/mfd/cros_ec_dev.h | 16 ++-------
drivers/mfd/cros_ec_i2c.c | 18 +++-------
drivers/mfd/cros_ec_spi.c | 20 +++--------
drivers/platform/chrome/chromeos_pstore.c | 13 +++----
drivers/platform/chrome/cros_ec_debugfs.c | 22 +++---------
drivers/platform/chrome/cros_ec_lightbar.c | 22 +++---------
drivers/platform/chrome/cros_ec_lpc.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_lpc_mec.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_lpc_reg.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_proto.c | 19 +++--------
drivers/platform/chrome/cros_ec_sysfs.c | 22 +++---------
drivers/platform/chrome/cros_ec_vbc.c | 24 +++----------
.../platform/chrome/cros_kbd_led_backlight.c | 19 +++--------
drivers/pwm/pwm-cros-ec.c | 13 +++----
include/linux/mfd/cros_ec.h | 10 +-----
include/linux/mfd/cros_ec_commands.h | 10 +-----
include/linux/mfd/cros_ec_lpc_mec.h | 14 ++------
include/linux/mfd/cros_ec_lpc_reg.h | 14 ++------
29 files changed, 152 insertions(+), 440 deletions(-)

--
2.17.1



2018-06-05 17:56:39

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 8/8] i2c: i2c-cros-ec-tunnel: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2: None

drivers/i2c/busses/i2c-cros-ec-tunnel.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)

diff --git a/drivers/i2c/busses/i2c-cros-ec-tunnel.c b/drivers/i2c/busses/i2c-cros-ec-tunnel.c
index eb76b76f4754..82bcd9a78759 100644
--- a/drivers/i2c/busses/i2c-cros-ec-tunnel.c
+++ b/drivers/i2c/busses/i2c-cros-ec-tunnel.c
@@ -1,13 +1,7 @@
-/*
- * Copyright (C) 2013 Google, 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.
- *
- * Expose an I2C passthrough to the ChromeOS EC.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Expose an I2C passthrough to the ChromeOS EC.
+//
+// Copyright (C) 2013 Google, Inc.

#include <linux/module.h>
#include <linux/i2c.h>
--
2.17.1


2018-06-05 17:56:51

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2:
- [6/9] Do not remove last paragraph.

drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
1 file changed, 12 insertions(+), 22 deletions(-)

diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
index 79eb29550c34..91b2839c12df 100644
--- a/drivers/input/keyboard/cros_ec_keyb.c
+++ b/drivers/input/keyboard/cros_ec_keyb.c
@@ -1,25 +1,15 @@
-/*
- * ChromeOS EC keyboard driver
- *
- * Copyright (C) 2012 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
- * communicating the keyboard state (which keys are pressed) from a keyboard EC
- * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
- * but everything else (including deghosting) is done here. The main
- * motivation for this is to keep the EC firmware as simple as possible, since
- * it cannot be easily upgraded and EC flash/IRAM space is relatively
- * expensive.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS EC keyboard driver
+//
+// Copyright (C) 2012 Google, Inc.
+//
+// This driver uses the ChromeOS EC byte-level message-based protocol for
+// communicating the keyboard state (which keys are pressed) from a keyboard EC
+// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
+// but everything else (including deghosting) is done here. The main
+// motivation for this is to keep the EC firmware as simple as possible, since
+// it cannot be easily upgraded and EC flash/IRAM space is relatively
+// expensive.

#include <linux/module.h>
#include <linux/bitops.h>
--
2.17.1


2018-06-05 17:57:07

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 6/8] pwm: cros-ec: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2: None

drivers/pwm/pwm-cros-ec.c | 13 ++++---------
1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/drivers/pwm/pwm-cros-ec.c b/drivers/pwm/pwm-cros-ec.c
index 9c13694eaa24..9bf4cde86765 100644
--- a/drivers/pwm/pwm-cros-ec.c
+++ b/drivers/pwm/pwm-cros-ec.c
@@ -1,12 +1,7 @@
-/*
- * Copyright (C) 2016 Google, Inc
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2, as published by
- * the Free Software Foundation.
- *
- * Expose a PWM controlled by the ChromeOS EC to the host processor.
- */
+// SPDX-License-Identifier: GPL-2.0
+// Expose a PWM controlled by the ChromeOS EC to the host processor.
+//
+// Copyright (C) 2016 Google, Inc.

#include <linux/module.h>
#include <linux/mfd/cros_ec.h>
--
2.17.1


2018-06-05 17:57:22

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 7/8] extcon: usbc-cros-ec: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2:
- [8/9] Fixed wrong copyright year.

drivers/extcon/extcon-usbc-cros-ec.c | 20 +++++---------------
1 file changed, 5 insertions(+), 15 deletions(-)

diff --git a/drivers/extcon/extcon-usbc-cros-ec.c b/drivers/extcon/extcon-usbc-cros-ec.c
index 6721ab01fe7d..ef5a23e46e71 100644
--- a/drivers/extcon/extcon-usbc-cros-ec.c
+++ b/drivers/extcon/extcon-usbc-cros-ec.c
@@ -1,18 +1,8 @@
-/**
- * drivers/extcon/extcon-usbc-cros-ec - ChromeOS Embedded Controller extcon
- *
- * Copyright (C) 2017 Google, Inc
- * Author: Benson Leung <[email protected]>
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS Embedded Controller extcon
+//
+// Copyright (C) 2017 Google, Inc.
+// Author: Benson Leung <[email protected]>

#include <linux/extcon-provider.h>
#include <linux/kernel.h>
--
2.17.1


2018-06-05 17:57:50

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 4/8] iio: cros_ec: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2: None

drivers/iio/accel/cros_ec_accel_legacy.c | 27 +++++++------------
.../common/cros_ec_sensors/cros_ec_sensors.c | 24 +++++------------
.../cros_ec_sensors/cros_ec_sensors_core.c | 18 +++----------
.../cros_ec_sensors/cros_ec_sensors_core.h | 12 ++-------
drivers/iio/light/cros_ec_light_prox.c | 18 +++----------
drivers/iio/pressure/cros_ec_baro.c | 18 +++----------
6 files changed, 30 insertions(+), 87 deletions(-)

diff --git a/drivers/iio/accel/cros_ec_accel_legacy.c b/drivers/iio/accel/cros_ec_accel_legacy.c
index 063e89eff791..525f7eb37e91 100644
--- a/drivers/iio/accel/cros_ec_accel_legacy.c
+++ b/drivers/iio/accel/cros_ec_accel_legacy.c
@@ -1,21 +1,12 @@
-/*
- * Driver for older Chrome OS EC accelerometer
- *
- * Copyright 2017 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the memory mapper cros-ec interface to communicate
- * with the Chrome OS EC about accelerometer data.
- * Accelerometer access is presented through iio sysfs.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Driver for older ChromeOS EC accelerometer
+//
+// Copyright (C) 2017 Google, Inc.
+// Author: Gwendal Grignou <[email protected]>
+//
+// This driver uses the memory mapper cros-ec interface to communicate
+// with the ChromeOS EC about accelerometer data.
+// Accelerometer access is presented through iio sysfs.

#include <linux/delay.h>
#include <linux/device.h>
diff --git a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c
index 705cb3e72663..39d4eecc97ea 100644
--- a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c
+++ b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c
@@ -1,20 +1,10 @@
-/*
- * cros_ec_sensors - Driver for Chrome OS Embedded Controller sensors.
- *
- * Copyright (C) 2016 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the cros-ec interface to communicate with the Chrome OS
- * EC about sensors data. Data access is presented through iio sysfs.
- */
+// SPDX-License-Identifier: GPL-2.0
+// Driver for ChromeOS Embedded Controller sensors.
+//
+// Copyright (C) 2016 Google, Inc.
+//
+// This driver uses the cros-ec interface to communicate with the ChromeOS
+// EC about sensors data. Data access is presented through iio sysfs.

#include <linux/delay.h>
#include <linux/device.h>
diff --git a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c
index a620eb5ce202..05221994197c 100644
--- a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c
+++ b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.c
@@ -1,17 +1,7 @@
-/*
- * cros_ec_sensors_core - Common function for Chrome OS EC sensor driver.
- *
- * Copyright (C) 2016 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0
+// Common functions for ChromeOS EC sensor driver.
+//
+// Copyright (C) 2016 Google, Inc.

#include <linux/delay.h>
#include <linux/device.h>
diff --git a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.h b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.h
index 2edf68dc7336..a9935489030e 100644
--- a/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.h
+++ b/drivers/iio/common/cros_ec_sensors/cros_ec_sensors_core.h
@@ -1,16 +1,8 @@
+/* SPDX-License-Identifier: GPL-2.0 */
/*
* ChromeOS EC sensor hub
*
- * Copyright (C) 2016 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
+ * Copyright (C) 2016 Google, Inc.
*/

#ifndef __CROS_EC_SENSORS_CORE_H
diff --git a/drivers/iio/light/cros_ec_light_prox.c b/drivers/iio/light/cros_ec_light_prox.c
index 8e8a0e7f78d1..8635e1c18cd5 100644
--- a/drivers/iio/light/cros_ec_light_prox.c
+++ b/drivers/iio/light/cros_ec_light_prox.c
@@ -1,17 +1,7 @@
-/*
- * cros_ec_light_prox - Driver for light and prox sensors behing CrosEC.
- *
- * Copyright (C) 2017 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0
+// Driver for light and prox sensors behind ChromeOS EC.
+//
+// Copyright (C) 2017 Google, Inc.

#include <linux/delay.h>
#include <linux/device.h>
diff --git a/drivers/iio/pressure/cros_ec_baro.c b/drivers/iio/pressure/cros_ec_baro.c
index 4599fde4dd25..8e134d65d18d 100644
--- a/drivers/iio/pressure/cros_ec_baro.c
+++ b/drivers/iio/pressure/cros_ec_baro.c
@@ -1,17 +1,7 @@
-/*
- * cros_ec_baro - Driver for barometer sensor behind CrosEC.
- *
- * Copyright (C) 2017 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0
+// Driver for barometer sensor behind ChromeOS EC.
+//
+// Copyright (C) 2017 Google, Inc.

#include <linux/delay.h>
#include <linux/device.h>
--
2.17.1


2018-06-05 17:58:02

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 2/8] platform/chrome: pstore: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2: None

drivers/platform/chrome/chromeos_pstore.c | 13 ++++---------
1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/drivers/platform/chrome/chromeos_pstore.c b/drivers/platform/chrome/chromeos_pstore.c
index b0693fdec8c6..4d3d3459e2f9 100644
--- a/drivers/platform/chrome/chromeos_pstore.c
+++ b/drivers/platform/chrome/chromeos_pstore.c
@@ -1,12 +1,7 @@
-/*
- * chromeos_pstore.c - Driver to instantiate Chromebook ramoops device
- *
- * Copyright (C) 2013 Google, 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, version 2 of the License.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Driver to instantiate Chromebook ramoops device.
+//
+// Copyright (C) 2013 Google, Inc.

#include <linux/acpi.h>
#include <linux/dmi.h>
--
2.17.1


2018-06-05 17:58:28

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 1/8] platform/chrome: cros_ec: Switch to SPDX identifier.

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2:
- s/Chrome OS/ChromeOS/
- [1/9] Fixed wrong copyright year.

drivers/platform/chrome/cros_ec_debugfs.c | 22 +++---------
drivers/platform/chrome/cros_ec_lightbar.c | 22 +++---------
drivers/platform/chrome/cros_ec_lpc.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_lpc_mec.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_lpc_reg.c | 34 +++++++------------
drivers/platform/chrome/cros_ec_proto.c | 19 +++--------
drivers/platform/chrome/cros_ec_sysfs.c | 22 +++---------
drivers/platform/chrome/cros_ec_vbc.c | 24 +++----------
.../platform/chrome/cros_kbd_led_backlight.c | 19 +++--------
9 files changed, 61 insertions(+), 169 deletions(-)

diff --git a/drivers/platform/chrome/cros_ec_debugfs.c b/drivers/platform/chrome/cros_ec_debugfs.c
index c62ee8e610a0..450dac3996ff 100644
--- a/drivers/platform/chrome/cros_ec_debugfs.c
+++ b/drivers/platform/chrome/cros_ec_debugfs.c
@@ -1,21 +1,7 @@
-/*
- * cros_ec_debugfs - debug logs for Chrome OS EC
- *
- * Copyright 2015 Google, 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, see <http://www.gnu.org/licenses/>.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Debug logs for ChromeOS EC.
+//
+// Copyright (C) 2015 Google, Inc.

#include <linux/circ_buf.h>
#include <linux/debugfs.h>
diff --git a/drivers/platform/chrome/cros_ec_lightbar.c b/drivers/platform/chrome/cros_ec_lightbar.c
index 68193bb53383..c5a6dd4ffa01 100644
--- a/drivers/platform/chrome/cros_ec_lightbar.c
+++ b/drivers/platform/chrome/cros_ec_lightbar.c
@@ -1,21 +1,7 @@
-/*
- * cros_ec_lightbar - expose the Chromebook Pixel lightbar to userspace
- *
- * Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Expose the Chromebook Pixel lightbar to userspace.
+//
+// Copyright (C) 2014 Google, Inc.

#define pr_fmt(fmt) "cros_ec_lightbar: " fmt

diff --git a/drivers/platform/chrome/cros_ec_lpc.c b/drivers/platform/chrome/cros_ec_lpc.c
index 3682e1539251..f196aa4fa84c 100644
--- a/drivers/platform/chrome/cros_ec_lpc.c
+++ b/drivers/platform/chrome/cros_ec_lpc.c
@@ -1,25 +1,15 @@
-/*
- * cros_ec_lpc - LPC access to the Chrome OS Embedded Controller
- *
- * Copyright (C) 2012-2015 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
- * communicating the keyboard state (which keys are pressed) from a keyboard EC
- * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
- * but everything else (including deghosting) is done here. The main
- * motivation for this is to keep the EC firmware as simple as possible, since
- * it cannot be easily upgraded and EC flash/IRAM space is relatively
- * expensive.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// LPC access to the ChromeOS Embedded Controller.
+//
+// Copyright (C) 2012-2015 Google, Inc.
+//
+// This driver uses the ChromeOS EC byte-level message-based protocol for
+// communicating the keyboard state (which keys are pressed) from a keyboard EC
+// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
+// but everything else (including deghosting) is done here. The main
+// motivation for this is to keep the EC firmware as simple as possible, since
+// it cannot be easily upgraded and EC flash/IRAM space is relatively
+// expensive.

#include <linux/acpi.h>
#include <linux/dmi.h>
diff --git a/drivers/platform/chrome/cros_ec_lpc_mec.c b/drivers/platform/chrome/cros_ec_lpc_mec.c
index 2eda2c2fc210..7c69883cea5d 100644
--- a/drivers/platform/chrome/cros_ec_lpc_mec.c
+++ b/drivers/platform/chrome/cros_ec_lpc_mec.c
@@ -1,25 +1,15 @@
-/*
- * cros_ec_lpc_mec - LPC variant I/O for Microchip EC
- *
- * Copyright (C) 2016 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
- * communicating the keyboard state (which keys are pressed) from a keyboard EC
- * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
- * but everything else (including deghosting) is done here. The main
- * motivation for this is to keep the EC firmware as simple as possible, since
- * it cannot be easily upgraded and EC flash/IRAM space is relatively
- * expensive.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// LPC variant I/O for Microchip EC.
+//
+// Copyright (C) 2016 Google, Inc.
+//
+// This driver uses the ChromeOS EC byte-level message-based protocol for
+// communicating the keyboard state (which keys are pressed) from a keyboard EC
+// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
+// but everything else (including deghosting) is done here. The main
+// motivation for this is to keep the EC firmware as simple as possible, since
+// it cannot be easily upgraded and EC flash/IRAM space is relatively
+// expensive

#include <linux/delay.h>
#include <linux/io.h>
diff --git a/drivers/platform/chrome/cros_ec_lpc_reg.c b/drivers/platform/chrome/cros_ec_lpc_reg.c
index dcc7a3e30604..4a1013964841 100644
--- a/drivers/platform/chrome/cros_ec_lpc_reg.c
+++ b/drivers/platform/chrome/cros_ec_lpc_reg.c
@@ -1,25 +1,15 @@
-/*
- * cros_ec_lpc_reg - LPC access to the Chrome OS Embedded Controller
- *
- * Copyright (C) 2016 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
- * communicating the keyboard state (which keys are pressed) from a keyboard EC
- * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
- * but everything else (including deghosting) is done here. The main
- * motivation for this is to keep the EC firmware as simple as possible, since
- * it cannot be easily upgraded and EC flash/IRAM space is relatively
- * expensive.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// LPC access to the ChromeOS Embedded Controller.
+//
+// Copyright (C) 2016 Google, Inc.
+//
+// This driver uses the ChromeOS EC byte-level message-based protocol for
+// communicating the keyboard state (which keys are pressed) from a keyboard EC
+// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
+// but everything else (including deghosting) is done here. The main
+// motivation for this is to keep the EC firmware as simple as possible, since
+// it cannot be easily upgraded and EC flash/IRAM space is relatively
+// expensive.

#include <linux/io.h>
#include <linux/mfd/cros_ec.h>
diff --git a/drivers/platform/chrome/cros_ec_proto.c b/drivers/platform/chrome/cros_ec_proto.c
index 8350ca2311c7..13b925aba61d 100644
--- a/drivers/platform/chrome/cros_ec_proto.c
+++ b/drivers/platform/chrome/cros_ec_proto.c
@@ -1,18 +1,7 @@
-/*
- * ChromeOS EC communication protocol helper functions
- *
- * Copyright (C) 2015 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS EC communication protocol helper functions.
+//
+// Copyright (C) 2015 Google, Inc.

#include <linux/mfd/cros_ec.h>
#include <linux/delay.h>
diff --git a/drivers/platform/chrome/cros_ec_sysfs.c b/drivers/platform/chrome/cros_ec_sysfs.c
index f34a50121064..68979cebb2c8 100644
--- a/drivers/platform/chrome/cros_ec_sysfs.c
+++ b/drivers/platform/chrome/cros_ec_sysfs.c
@@ -1,21 +1,7 @@
-/*
- * cros_ec_sysfs - expose the Chrome OS EC through sysfs
- *
- * Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Expose the ChromeOS EC through sysfs.
+//
+// Copyright (C) 2014 Google, Inc.

#define pr_fmt(fmt) "cros_ec_sysfs: " fmt

diff --git a/drivers/platform/chrome/cros_ec_vbc.c b/drivers/platform/chrome/cros_ec_vbc.c
index 5356f26bc022..a4934f41f462 100644
--- a/drivers/platform/chrome/cros_ec_vbc.c
+++ b/drivers/platform/chrome/cros_ec_vbc.c
@@ -1,22 +1,8 @@
-/*
- * cros_ec_vbc - Expose the vboot context nvram to userspace
- *
- * Copyright (C) 2015 Collabora Ltd.
- *
- * based on vendor driver,
- *
- * Copyright (C) 2012 The Chromium OS Authors
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Expose the vboot context nvram to userspace.
+//
+// Copyright (C) 2012 Google, Inc.
+// Copyright (C) 2015 Collabora Ltd.

#include <linux/of.h>
#include <linux/platform_device.h>
diff --git a/drivers/platform/chrome/cros_kbd_led_backlight.c b/drivers/platform/chrome/cros_kbd_led_backlight.c
index ca3e4da852b4..bd4aa9331806 100644
--- a/drivers/platform/chrome/cros_kbd_led_backlight.c
+++ b/drivers/platform/chrome/cros_kbd_led_backlight.c
@@ -1,18 +1,7 @@
-/*
- * Keyboard backlight LED driver for Chrome OS.
- *
- * Copyright (C) 2012 Google, 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.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Keyboard backlight LED driver for ChromeOS.
+//
+// Copyright (C) 2012 Google, Inc.

#include <linux/acpi.h>
#include <linux/leds.h>
--
2.17.1


2018-06-05 17:58:35

by Enric Balletbo i Serra

[permalink] [raw]
Subject: [PATCH v2 3/8] mfd: cros_ec: Add or fix SPDX-License-Identifier in all files.

And get rid of the license text that is no longer necessary. Also fix
the license as sometimes doesn't match what the header with the value in
the MODULE_LICENSE macro. Assuming that the desired license is GPL-2.0+,
all the files are updated to this license version.

Signed-off-by: Enric Balletbo i Serra <[email protected]>
---

Changes in v2: None

drivers/mfd/cros_ec.c | 26 ++++++++------------------
drivers/mfd/cros_ec_dev.c | 23 +++++------------------
drivers/mfd/cros_ec_dev.h | 16 ++--------------
drivers/mfd/cros_ec_i2c.c | 18 ++++--------------
drivers/mfd/cros_ec_spi.c | 20 +++++---------------
include/linux/mfd/cros_ec.h | 10 +---------
include/linux/mfd/cros_ec_commands.h | 10 +---------
include/linux/mfd/cros_ec_lpc_mec.h | 14 +++-----------
include/linux/mfd/cros_ec_lpc_reg.h | 14 +++-----------
9 files changed, 32 insertions(+), 119 deletions(-)

diff --git a/drivers/mfd/cros_ec.c b/drivers/mfd/cros_ec.c
index 58e05069163e..5b6a1c541543 100644
--- a/drivers/mfd/cros_ec.c
+++ b/drivers/mfd/cros_ec.c
@@ -1,21 +1,11 @@
-/*
- * ChromeOS EC multi-function device
- *
- * Copyright (C) 2012 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * The ChromeOS EC multi function device is used to mux all the requests
- * to the EC device for its multiple features: keyboard controller,
- * battery charging and regulator control, firmware update.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS EC multi-function device.
+//
+// Copyright (C) 2012 Google, Inc
+//
+// The ChromeOS EC multi function device is used to mux all the requests
+// to the EC device for its multiple features: keyboard controller,
+// battery charging and regulator control, firmware update.

#include <linux/of_platform.h>
#include <linux/interrupt.h>
diff --git a/drivers/mfd/cros_ec_dev.c b/drivers/mfd/cros_ec_dev.c
index d37c79426c87..0ce7be132a09 100644
--- a/drivers/mfd/cros_ec_dev.c
+++ b/drivers/mfd/cros_ec_dev.c
@@ -1,21 +1,8 @@
-/*
- * cros_ec_dev - expose the Chrome OS Embedded Controller to user-space
- *
- * Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// Expose the ChromeOS Embedded Controller to user-space.
+//
+// Copyright (C) 2014 Google, Inc.
+// Author: Bill Richardson <[email protected]>

#include <linux/fs.h>
#include <linux/mfd/core.h>
diff --git a/drivers/mfd/cros_ec_dev.h b/drivers/mfd/cros_ec_dev.h
index 45e9453608c5..a63cf80234c7 100644
--- a/drivers/mfd/cros_ec_dev.h
+++ b/drivers/mfd/cros_ec_dev.h
@@ -1,20 +1,8 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
- * cros_ec_dev - expose the Chrome OS Embedded Controller to userspace
+ * Expose the ChromeOS Embedded Controller to userspace
*
* Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
*/

#ifndef _CROS_EC_DEV_H_
diff --git a/drivers/mfd/cros_ec_i2c.c b/drivers/mfd/cros_ec_i2c.c
index ef9b4763356f..5f3a356467df 100644
--- a/drivers/mfd/cros_ec_i2c.c
+++ b/drivers/mfd/cros_ec_i2c.c
@@ -1,17 +1,7 @@
-/*
- * ChromeOS EC multi-function device (I2C)
- *
- * Copyright (C) 2012 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS EC multi-function device (I2C).
+//
+// Copyright (C) 2012 Google, Inc

#include <linux/acpi.h>
#include <linux/delay.h>
diff --git a/drivers/mfd/cros_ec_spi.c b/drivers/mfd/cros_ec_spi.c
index 2060d1483043..861ea6dcb816 100644
--- a/drivers/mfd/cros_ec_spi.c
+++ b/drivers/mfd/cros_ec_spi.c
@@ -1,17 +1,7 @@
-/*
- * ChromeOS EC multi-function device (SPI)
- *
- * Copyright (C) 2012 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- */
+// SPDX-License-Identifier: GPL-2.0+
+// ChromeOS EC multi-function device (SPI).
+//
+// Copyright (C) 2012 Google, Inc

#include <linux/delay.h>
#include <linux/kernel.h>
@@ -739,5 +729,5 @@ static struct spi_driver cros_ec_driver_spi = {

module_spi_driver(cros_ec_driver_spi);

-MODULE_LICENSE("GPL v2");
+MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("ChromeOS EC multi function device (SPI)");
diff --git a/include/linux/mfd/cros_ec.h b/include/linux/mfd/cros_ec.h
index 32421dfeb996..f6ed58166111 100644
--- a/include/linux/mfd/cros_ec.h
+++ b/include/linux/mfd/cros_ec.h
@@ -1,16 +1,8 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* ChromeOS EC multi-function device
*
* Copyright (C) 2012 Google, Inc
- *
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
*/

#ifndef __LINUX_MFD_CROS_EC_H
diff --git a/include/linux/mfd/cros_ec_commands.h b/include/linux/mfd/cros_ec_commands.h
index f2edd9969b40..bf762ae46378 100644
--- a/include/linux/mfd/cros_ec_commands.h
+++ b/include/linux/mfd/cros_ec_commands.h
@@ -1,17 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Host communication command constants for ChromeOS EC
*
* Copyright (C) 2012 Google, Inc
*
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
* The ChromeOS EC multi function device is used to mux all the requests
* to the EC device for its multiple features: keyboard controller,
* battery charging and regulator control, firmware update.
diff --git a/include/linux/mfd/cros_ec_lpc_mec.h b/include/linux/mfd/cros_ec_lpc_mec.h
index 176496ddc66c..ba4204f05172 100644
--- a/include/linux/mfd/cros_ec_lpc_mec.h
+++ b/include/linux/mfd/cros_ec_lpc_mec.h
@@ -1,18 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
- * cros_ec_lpc_mec - LPC variant I/O for Microchip EC
+ * LPC variant I/O for Microchip EC
*
* Copyright (C) 2016 Google, Inc
*
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
+ * This driver uses the ChromeOS EC byte-level message-based protocol for
* communicating the keyboard state (which keys are pressed) from a keyboard EC
* to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
* but everything else (including deghosting) is done here. The main
diff --git a/include/linux/mfd/cros_ec_lpc_reg.h b/include/linux/mfd/cros_ec_lpc_reg.h
index 5560bef63c2b..b5a6277cb465 100644
--- a/include/linux/mfd/cros_ec_lpc_reg.h
+++ b/include/linux/mfd/cros_ec_lpc_reg.h
@@ -1,18 +1,10 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
- * cros_ec_lpc_reg - LPC access to the Chrome OS Embedded Controller
+ * LPC register access to the ChromeOS Embedded Controller
*
* Copyright (C) 2016 Google, Inc
*
- * This software is licensed under the terms of the GNU General Public
- * License version 2, as published by the Free Software Foundation, and
- * may be copied, distributed, and modified under those terms.
- *
- * 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.
- *
- * This driver uses the Chrome OS EC byte-level message-based protocol for
+ * This driver uses the ChromeOS EC byte-level message-based protocol for
* communicating the keyboard state (which keys are pressed) from a keyboard EC
* to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
* but everything else (including deghosting) is done here. The main
--
2.17.1


2018-06-05 18:05:37

by Fabio Estevam

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Hi Enric,

On Tue, Jun 5, 2018 at 2:54 PM, Enric Balletbo i Serra
<[email protected]> wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2:
> - [6/9] Do not remove last paragraph.
>
> drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
> 1 file changed, 12 insertions(+), 22 deletions(-)
>
> diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
> index 79eb29550c34..91b2839c12df 100644
> --- a/drivers/input/keyboard/cros_ec_keyb.c
> +++ b/drivers/input/keyboard/cros_ec_keyb.c
> @@ -1,25 +1,15 @@
> -/*
> - * ChromeOS EC keyboard driver
> - *
> - * Copyright (C) 2012 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and

Original text says GPL-2.0...

> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> - * but everything else (including deghosting) is done here. The main
> - * motivation for this is to keep the EC firmware as simple as possible, since
> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> - * expensive.
> - */
> +// SPDX-License-Identifier: GPL-2.0+

but here you add a GPL-2.0+ type.

2018-06-05 18:15:07

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Hi Fabio,

On 05/06/18 20:04, Fabio Estevam wrote:
> Hi Enric,
>
> On Tue, Jun 5, 2018 at 2:54 PM, Enric Balletbo i Serra
> <[email protected]> wrote:
>> Adopt the SPDX license identifier headers to ease license compliance
>> management.
>>
>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
>> ---
>>
>> Changes in v2:
>> - [6/9] Do not remove last paragraph.
>>
>> drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
>> 1 file changed, 12 insertions(+), 22 deletions(-)
>>
>> diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
>> index 79eb29550c34..91b2839c12df 100644
>> --- a/drivers/input/keyboard/cros_ec_keyb.c
>> +++ b/drivers/input/keyboard/cros_ec_keyb.c
>> @@ -1,25 +1,15 @@
>> -/*
>> - * ChromeOS EC keyboard driver
>> - *
>> - * Copyright (C) 2012 Google, Inc
>> - *
>> - * This software is licensed under the terms of the GNU General Public
>> - * License version 2, as published by the Free Software Foundation, and
>
> Original text says GPL-2.0...
>
>> - * may be copied, distributed, and modified under those terms.
>> - *
>> - * 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.
>> - *
>> - * This driver uses the Chrome OS EC byte-level message-based protocol for
>> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
>> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
>> - * but everything else (including deghosting) is done here. The main
>> - * motivation for this is to keep the EC firmware as simple as possible, since
>> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
>> - * expensive.
>> - */
>> +// SPDX-License-Identifier: GPL-2.0+
>
> but here you add a GPL-2.0+ type.
>

Right, but the module license is set to GPL which means GNU Public License v2 or
later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
default. These mismatches are common so I think that should be fine for the
authors, if someone is disagree just let me know and I will change.

Best regards,
Enric

[1]
https://elixir.bootlin.com/linux/v4.17/source/drivers/input/keyboard/cros_ec_keyb.c#L677

2018-06-05 18:16:21

by Benson Leung

[permalink] [raw]
Subject: Re: [PATCH v2 7/8] extcon: usbc-cros-ec: Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 07:54:28PM +0200, Enric Balletbo i Serra wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>

Reviewed-by: Benson Leung <[email protected]>

> ---
>
> Changes in v2:
> - [8/9] Fixed wrong copyright year.
>
> drivers/extcon/extcon-usbc-cros-ec.c | 20 +++++---------------
> 1 file changed, 5 insertions(+), 15 deletions(-)
>
> diff --git a/drivers/extcon/extcon-usbc-cros-ec.c b/drivers/extcon/extcon-usbc-cros-ec.c
> index 6721ab01fe7d..ef5a23e46e71 100644
> --- a/drivers/extcon/extcon-usbc-cros-ec.c
> +++ b/drivers/extcon/extcon-usbc-cros-ec.c
> @@ -1,18 +1,8 @@
> -/**
> - * drivers/extcon/extcon-usbc-cros-ec - ChromeOS Embedded Controller extcon
> - *
> - * Copyright (C) 2017 Google, Inc
> - * Author: Benson Leung <[email protected]>
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// ChromeOS Embedded Controller extcon
> +//
> +// Copyright (C) 2017 Google, Inc.
> +// Author: Benson Leung <[email protected]>
>
> #include <linux/extcon-provider.h>
> #include <linux/kernel.h>
> --
> 2.17.1
>

--
Benson Leung
Staff Software Engineer
Chrome OS Kernel
Google Inc.
[email protected]
Chromium OS Project
[email protected]


Attachments:
(No filename) (1.79 kB)
signature.asc (849.00 B)
Download all attachments

2018-06-05 18:17:36

by Fabio Estevam

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Hi Enric,

On Tue, Jun 5, 2018 at 3:14 PM, Enric Balletbo i Serra
<[email protected]> wrote:

> Right, but the module license is set to GPL which means GNU Public License v2 or
> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
> default. These mismatches are common so I think that should be fine for the
> authors, if someone is disagree just let me know and I will change.

Ok, but I think you should add this explanation in the commit log to
make it clearer.

2018-06-05 18:30:17

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 03:16:40PM -0300, Fabio Estevam wrote:
> Hi Enric,
>
> On Tue, Jun 5, 2018 at 3:14 PM, Enric Balletbo i Serra
> <[email protected]> wrote:
>
> > Right, but the module license is set to GPL which means GNU Public License v2 or
> > later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
> > default. These mismatches are common so I think that should be fine for the
> > authors, if someone is disagree just let me know and I will change.
>
> Ok, but I think you should add this explanation in the commit log to
> make it clearer.

If there is a conflict between the license notice and MODULE_LICENSE()
we should go by the license notice. The license note is usually approved
by companies, whereas MIODULE_LICENSE()s get moved, adjusted, etc.

For ChromeOS kernel changes license notice is GPL v2 as documented at:

https://www.chromium.org/chromium-os/how-tos-and-troubleshooting/kernel-faq

section "Which copyright header should I use?"

Thanks.

--
Dmitry

2018-06-05 18:44:40

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH v2 7/8] extcon: usbc-cros-ec: Switch to SPDX identifier.

On Tue, Jun 5, 2018 at 11:15 AM, Benson Leung <[email protected]> wrote:
> On Tue, Jun 05, 2018 at 07:54:28PM +0200, Enric Balletbo i Serra wrote:
>> Adopt the SPDX license identifier headers to ease license compliance
>> management.
>>
>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
>
> Reviewed-by: Benson Leung <[email protected]>

It has wrong license tag, I think all ChromeOS drivers as GPL v2 only.

>
>> ---
>>
>> Changes in v2:
>> - [8/9] Fixed wrong copyright year.
>>
>> drivers/extcon/extcon-usbc-cros-ec.c | 20 +++++---------------
>> 1 file changed, 5 insertions(+), 15 deletions(-)
>>
>> diff --git a/drivers/extcon/extcon-usbc-cros-ec.c b/drivers/extcon/extcon-usbc-cros-ec.c
>> index 6721ab01fe7d..ef5a23e46e71 100644
>> --- a/drivers/extcon/extcon-usbc-cros-ec.c
>> +++ b/drivers/extcon/extcon-usbc-cros-ec.c
>> @@ -1,18 +1,8 @@
>> -/**
>> - * drivers/extcon/extcon-usbc-cros-ec - ChromeOS Embedded Controller extcon
>> - *
>> - * Copyright (C) 2017 Google, Inc
>> - * Author: Benson Leung <[email protected]>
>> - *
>> - * This software is licensed under the terms of the GNU General Public
>> - * License version 2, as published by the Free Software Foundation, and
>> - * may be copied, distributed, and modified under those terms.
>> - *
>> - * 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.
>> - */
>> +// SPDX-License-Identifier: GPL-2.0+
>> +// ChromeOS Embedded Controller extcon
>> +//
>> +// Copyright (C) 2017 Google, Inc.
>> +// Author: Benson Leung <[email protected]>
>>
>> #include <linux/extcon-provider.h>
>> #include <linux/kernel.h>
>> --
>> 2.17.1
>>
>
> --
> Benson Leung
> Staff Software Engineer
> Chrome OS Kernel
> Google Inc.
> [email protected]
> Chromium OS Project
> [email protected]



--
Dmitry

2018-06-05 18:48:11

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Hi Dmitry,

On 05/06/18 20:29, Dmitry Torokhov wrote:
> On Tue, Jun 05, 2018 at 03:16:40PM -0300, Fabio Estevam wrote:
>> Hi Enric,
>>
>> On Tue, Jun 5, 2018 at 3:14 PM, Enric Balletbo i Serra
>> <[email protected]> wrote:
>>
>>> Right, but the module license is set to GPL which means GNU Public License v2 or
>>> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
>>> default. These mismatches are common so I think that should be fine for the
>>> authors, if someone is disagree just let me know and I will change.
>>
>> Ok, but I think you should add this explanation in the commit log to
>> make it clearer.
>
> If there is a conflict between the license notice and MODULE_LICENSE()
> we should go by the license notice. The license note is usually approved
> by companies, whereas MIODULE_LICENSE()s get moved, adjusted, etc.
>
> For ChromeOS kernel changes license notice is GPL v2 as documented at:
>
> https://www.chromium.org/chromium-os/how-tos-and-troubleshooting/kernel-faq
>
> section "Which copyright header should I use?"
>

Many thanks to share and clarify this.

There is lots of mismatches so I'll send another version fixing this and
changing all to GPL v2. I assume I should also modify the MODULE_LICENSE when
it's wrong.

Thanks.
Enric

> Thanks.
>

2018-06-05 18:53:26

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 08:45:44PM +0200, Enric Balletbo i Serra wrote:
> Hi Dmitry,
>
> On 05/06/18 20:29, Dmitry Torokhov wrote:
> > On Tue, Jun 05, 2018 at 03:16:40PM -0300, Fabio Estevam wrote:
> >> Hi Enric,
> >>
> >> On Tue, Jun 5, 2018 at 3:14 PM, Enric Balletbo i Serra
> >> <[email protected]> wrote:
> >>
> >>> Right, but the module license is set to GPL which means GNU Public License v2 or
> >>> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
> >>> default. These mismatches are common so I think that should be fine for the
> >>> authors, if someone is disagree just let me know and I will change.
> >>
> >> Ok, but I think you should add this explanation in the commit log to
> >> make it clearer.
> >
> > If there is a conflict between the license notice and MODULE_LICENSE()
> > we should go by the license notice. The license note is usually approved
> > by companies, whereas MIODULE_LICENSE()s get moved, adjusted, etc.
> >
> > For ChromeOS kernel changes license notice is GPL v2 as documented at:
> >
> > https://www.chromium.org/chromium-os/how-tos-and-troubleshooting/kernel-faq
> >
> > section "Which copyright header should I use?"
> >
>
> Many thanks to share and clarify this.
>
> There is lots of mismatches so I'll send another version fixing this and
> changing all to GPL v2. I assume I should also modify the MODULE_LICENSE when
> it's wrong.

I'd have a round of changes having MODULE_LICENSE() match the license
notice, and then separate patches for changing over to SPDX tags.

Thanks.

--
Dmitry

2018-06-05 20:52:57

by Benson Leung

[permalink] [raw]
Subject: Re: [PATCH v2 1/8] platform/chrome: cros_ec: Switch to SPDX identifier.

Hi Enric,

On Tue, Jun 05, 2018 at 07:54:22PM +0200, Enric Balletbo i Serra wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2:
> - s/Chrome OS/ChromeOS/
> - [1/9] Fixed wrong copyright year.
>
> drivers/platform/chrome/cros_ec_debugfs.c | 22 +++---------
> drivers/platform/chrome/cros_ec_lightbar.c | 22 +++---------
> drivers/platform/chrome/cros_ec_lpc.c | 34 +++++++------------
> drivers/platform/chrome/cros_ec_lpc_mec.c | 34 +++++++------------
> drivers/platform/chrome/cros_ec_lpc_reg.c | 34 +++++++------------
> drivers/platform/chrome/cros_ec_proto.c | 19 +++--------
> drivers/platform/chrome/cros_ec_sysfs.c | 22 +++---------
> drivers/platform/chrome/cros_ec_vbc.c | 24 +++----------
> .../platform/chrome/cros_kbd_led_backlight.c | 19 +++--------
> 9 files changed, 61 insertions(+), 169 deletions(-)
>
Several of these change V2 only to V2+. We should match the old license
notice.

My bad. I made the same error on the tbmc driver. I will fix that myself.


> diff --git a/drivers/platform/chrome/cros_ec_debugfs.c b/drivers/platform/chrome/cros_ec_debugfs.c
> index c62ee8e610a0..450dac3996ff 100644
> --- a/drivers/platform/chrome/cros_ec_debugfs.c
> +++ b/drivers/platform/chrome/cros_ec_debugfs.c
> @@ -1,21 +1,7 @@
> -/*
> - * cros_ec_debugfs - debug logs for Chrome OS EC
> - *
> - * Copyright 2015 Google, 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, see <http://www.gnu.org/licenses/>.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// Debug logs for ChromeOS EC.
> +//
> +// Copyright (C) 2015 Google, Inc.
>
> #include <linux/circ_buf.h>
> #include <linux/debugfs.h>
> diff --git a/drivers/platform/chrome/cros_ec_lightbar.c b/drivers/platform/chrome/cros_ec_lightbar.c
> index 68193bb53383..c5a6dd4ffa01 100644
> --- a/drivers/platform/chrome/cros_ec_lightbar.c
> +++ b/drivers/platform/chrome/cros_ec_lightbar.c
> @@ -1,21 +1,7 @@
> -/*
> - * cros_ec_lightbar - expose the Chromebook Pixel lightbar to userspace
> - *
> - * Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// Expose the Chromebook Pixel lightbar to userspace.
> +//
> +// Copyright (C) 2014 Google, Inc.
>
> #define pr_fmt(fmt) "cros_ec_lightbar: " fmt
>
> diff --git a/drivers/platform/chrome/cros_ec_lpc.c b/drivers/platform/chrome/cros_ec_lpc.c
> index 3682e1539251..f196aa4fa84c 100644
> --- a/drivers/platform/chrome/cros_ec_lpc.c
> +++ b/drivers/platform/chrome/cros_ec_lpc.c
> @@ -1,25 +1,15 @@
> -/*
> - * cros_ec_lpc - LPC access to the Chrome OS Embedded Controller
> - *
> - * Copyright (C) 2012-2015 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> - * but everything else (including deghosting) is done here. The main
> - * motivation for this is to keep the EC firmware as simple as possible, since
> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> - * expensive.
> - */
> +// SPDX-License-Identifier: GPL-2.0+

This one was submitted previously as GPL-2.0 only, so let's keep it that way.
GPL-2.0


> +// LPC access to the ChromeOS Embedded Controller.
> +//
> +// Copyright (C) 2012-2015 Google, Inc.
> +//
> +// This driver uses the ChromeOS EC byte-level message-based protocol for
> +// communicating the keyboard state (which keys are pressed) from a keyboard EC
> +// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> +// but everything else (including deghosting) is done here. The main
> +// motivation for this is to keep the EC firmware as simple as possible, since
> +// it cannot be easily upgraded and EC flash/IRAM space is relatively
> +// expensive.
>
> #include <linux/acpi.h>
> #include <linux/dmi.h>
> diff --git a/drivers/platform/chrome/cros_ec_lpc_mec.c b/drivers/platform/chrome/cros_ec_lpc_mec.c
> index 2eda2c2fc210..7c69883cea5d 100644
> --- a/drivers/platform/chrome/cros_ec_lpc_mec.c
> +++ b/drivers/platform/chrome/cros_ec_lpc_mec.c
> @@ -1,25 +1,15 @@
> -/*
> - * cros_ec_lpc_mec - LPC variant I/O for Microchip EC
> - *
> - * Copyright (C) 2016 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> - * but everything else (including deghosting) is done here. The main
> - * motivation for this is to keep the EC firmware as simple as possible, since
> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> - * expensive.
> - */
> +// SPDX-License-Identifier: GPL-2.0+

This one was submitted previously as GPL-2.0 only, so let's keep it that way.
GPL-2.0


> +// LPC variant I/O for Microchip EC.
> +//
> +// Copyright (C) 2016 Google, Inc.
> +//
> +// This driver uses the ChromeOS EC byte-level message-based protocol for
> +// communicating the keyboard state (which keys are pressed) from a keyboard EC
> +// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> +// but everything else (including deghosting) is done here. The main
> +// motivation for this is to keep the EC firmware as simple as possible, since
> +// it cannot be easily upgraded and EC flash/IRAM space is relatively
> +// expensive
>
> #include <linux/delay.h>
> #include <linux/io.h>
> diff --git a/drivers/platform/chrome/cros_ec_lpc_reg.c b/drivers/platform/chrome/cros_ec_lpc_reg.c
> index dcc7a3e30604..4a1013964841 100644
> --- a/drivers/platform/chrome/cros_ec_lpc_reg.c
> +++ b/drivers/platform/chrome/cros_ec_lpc_reg.c
> @@ -1,25 +1,15 @@
> -/*
> - * cros_ec_lpc_reg - LPC access to the Chrome OS Embedded Controller
> - *
> - * Copyright (C) 2016 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> - * but everything else (including deghosting) is done here. The main
> - * motivation for this is to keep the EC firmware as simple as possible, since
> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> - * expensive.
> - */
> +// SPDX-License-Identifier: GPL-2.0+

Same here.
GPL-2.0


> +// LPC access to the ChromeOS Embedded Controller.
> +//
> +// Copyright (C) 2016 Google, Inc.
> +//
> +// This driver uses the ChromeOS EC byte-level message-based protocol for
> +// communicating the keyboard state (which keys are pressed) from a keyboard EC
> +// to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> +// but everything else (including deghosting) is done here. The main
> +// motivation for this is to keep the EC firmware as simple as possible, since
> +// it cannot be easily upgraded and EC flash/IRAM space is relatively
> +// expensive.
>
> #include <linux/io.h>
> #include <linux/mfd/cros_ec.h>
> diff --git a/drivers/platform/chrome/cros_ec_proto.c b/drivers/platform/chrome/cros_ec_proto.c
> index 8350ca2311c7..13b925aba61d 100644
> --- a/drivers/platform/chrome/cros_ec_proto.c
> +++ b/drivers/platform/chrome/cros_ec_proto.c
> @@ -1,18 +1,7 @@
> -/*
> - * ChromeOS EC communication protocol helper functions
> - *
> - * Copyright (C) 2015 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - */
> +// SPDX-License-Identifier: GPL-2.0+

GPL-2.0

> +// ChromeOS EC communication protocol helper functions.
> +//
> +// Copyright (C) 2015 Google, Inc.
>
> #include <linux/mfd/cros_ec.h>
> #include <linux/delay.h>
> diff --git a/drivers/platform/chrome/cros_ec_sysfs.c b/drivers/platform/chrome/cros_ec_sysfs.c
> index f34a50121064..68979cebb2c8 100644
> --- a/drivers/platform/chrome/cros_ec_sysfs.c
> +++ b/drivers/platform/chrome/cros_ec_sysfs.c
> @@ -1,21 +1,7 @@
> -/*
> - * cros_ec_sysfs - expose the Chrome OS EC through sysfs
> - *
> - * Copyright (C) 2014 Google, 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, see <http://www.gnu.org/licenses/>.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// Expose the ChromeOS EC through sysfs.
> +//
> +// Copyright (C) 2014 Google, Inc.
>
> #define pr_fmt(fmt) "cros_ec_sysfs: " fmt
>
> diff --git a/drivers/platform/chrome/cros_ec_vbc.c b/drivers/platform/chrome/cros_ec_vbc.c
> index 5356f26bc022..a4934f41f462 100644
> --- a/drivers/platform/chrome/cros_ec_vbc.c
> +++ b/drivers/platform/chrome/cros_ec_vbc.c
> @@ -1,22 +1,8 @@
> -/*
> - * cros_ec_vbc - Expose the vboot context nvram to userspace
> - *
> - * Copyright (C) 2015 Collabora Ltd.
> - *
> - * based on vendor driver,
> - *
> - * Copyright (C) 2012 The Chromium OS Authors
> - *
> - * 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.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// Expose the vboot context nvram to userspace.
> +//
> +// Copyright (C) 2012 Google, Inc.
> +// Copyright (C) 2015 Collabora Ltd.
>
> #include <linux/of.h>
> #include <linux/platform_device.h>
> diff --git a/drivers/platform/chrome/cros_kbd_led_backlight.c b/drivers/platform/chrome/cros_kbd_led_backlight.c
> index ca3e4da852b4..bd4aa9331806 100644
> --- a/drivers/platform/chrome/cros_kbd_led_backlight.c
> +++ b/drivers/platform/chrome/cros_kbd_led_backlight.c
> @@ -1,18 +1,7 @@
> -/*
> - * Keyboard backlight LED driver for Chrome OS.
> - *
> - * Copyright (C) 2012 Google, 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.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// Keyboard backlight LED driver for ChromeOS.
> +//
> +// Copyright (C) 2012 Google, Inc.
>
> #include <linux/acpi.h>
> #include <linux/leds.h>
> --
> 2.17.1
>

Thanks!
--
Benson Leung
Staff Software Engineer
Chrome OS Kernel
Google Inc.
[email protected]
Chromium OS Project
[email protected]


Attachments:
(No filename) (14.87 kB)
signature.asc (849.00 B)
Download all attachments

2018-06-05 20:55:59

by Benson Leung

[permalink] [raw]
Subject: Re: [PATCH v2 2/8] platform/chrome: pstore: Switch to SPDX identifier.

Hi Enric,

On Tue, Jun 05, 2018 at 07:54:23PM +0200, Enric Balletbo i Serra wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2: None
>
> drivers/platform/chrome/chromeos_pstore.c | 13 ++++---------
> 1 file changed, 4 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/platform/chrome/chromeos_pstore.c b/drivers/platform/chrome/chromeos_pstore.c
> index b0693fdec8c6..4d3d3459e2f9 100644
> --- a/drivers/platform/chrome/chromeos_pstore.c
> +++ b/drivers/platform/chrome/chromeos_pstore.c
> @@ -1,12 +1,7 @@
> -/*
> - * chromeos_pstore.c - Driver to instantiate Chromebook ramoops device
> - *
> - * Copyright (C) 2013 Google, 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, version 2 of the License.
> - */
> +// SPDX-License-Identifier: GPL-2.0+

GPL-2.0

> +// Driver to instantiate Chromebook ramoops device.
> +//
> +// Copyright (C) 2013 Google, Inc.
>
> #include <linux/acpi.h>
> #include <linux/dmi.h>
> --
> 2.17.1
>

Thanks!
--
Benson Leung
Staff Software Engineer
Chrome OS Kernel
Google Inc.
[email protected]
Chromium OS Project
[email protected]


Attachments:
(No filename) (1.39 kB)
signature.asc (849.00 B)
Download all attachments

2018-06-06 09:09:43

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH v2 6/8] pwm: cros-ec: Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 07:54:27PM +0200, Enric Balletbo i Serra wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2: None
>
> drivers/pwm/pwm-cros-ec.c | 13 ++++---------
> 1 file changed, 4 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/pwm/pwm-cros-ec.c b/drivers/pwm/pwm-cros-ec.c
> index 9c13694eaa24..9bf4cde86765 100644
> --- a/drivers/pwm/pwm-cros-ec.c
> +++ b/drivers/pwm/pwm-cros-ec.c
> @@ -1,12 +1,7 @@
> -/*
> - * Copyright (C) 2016 Google, Inc
> - *
> - * This program is free software; you can redistribute it and/or modify it
> - * under the terms of the GNU General Public License version 2, as published by
> - * the Free Software Foundation.
> - *
> - * Expose a PWM controlled by the ChromeOS EC to the host processor.
> - */
> +// SPDX-License-Identifier: GPL-2.0
> +// Expose a PWM controlled by the ChromeOS EC to the host processor.
> +//
> +// Copyright (C) 2016 Google, Inc.

This is odd. I understand that for some reason there is an exception for
SPDX license identifies to use C++ style comments, but why would you
make the whole comment C++ style? Why not just something like the below:

+// SPDX-License-Identifier: GPL-2.0
/*
* Copyright (C) 2016 Google, Inc
*
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2, as published by
- * the Free Software Foundation.
- *
* Expose a PWM controlled by the ChromeOS EC to the host processor.
*/

Thierry


Attachments:
(No filename) (1.63 kB)
signature.asc (849.00 B)
Download all attachments

2018-06-06 09:22:52

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [PATCH v2 6/8] pwm: cros-ec: Switch to SPDX identifier.

Hi Thierry,

On 06/06/18 11:08, Thierry Reding wrote:
> On Tue, Jun 05, 2018 at 07:54:27PM +0200, Enric Balletbo i Serra wrote:
>> Adopt the SPDX license identifier headers to ease license compliance
>> management.
>>
>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
>> ---
>>
>> Changes in v2: None
>>
>> drivers/pwm/pwm-cros-ec.c | 13 ++++---------
>> 1 file changed, 4 insertions(+), 9 deletions(-)
>>
>> diff --git a/drivers/pwm/pwm-cros-ec.c b/drivers/pwm/pwm-cros-ec.c
>> index 9c13694eaa24..9bf4cde86765 100644
>> --- a/drivers/pwm/pwm-cros-ec.c
>> +++ b/drivers/pwm/pwm-cros-ec.c
>> @@ -1,12 +1,7 @@
>> -/*
>> - * Copyright (C) 2016 Google, Inc
>> - *
>> - * This program is free software; you can redistribute it and/or modify it
>> - * under the terms of the GNU General Public License version 2, as published by
>> - * the Free Software Foundation.
>> - *
>> - * Expose a PWM controlled by the ChromeOS EC to the host processor.
>> - */
>> +// SPDX-License-Identifier: GPL-2.0
>> +// Expose a PWM controlled by the ChromeOS EC to the host processor.
>> +//
>> +// Copyright (C) 2016 Google, Inc.
>
> This is odd. I understand that for some reason there is an exception for
> SPDX license identifies to use C++ style comments, but why would you
> make the whole comment C++ style? Why not just something like the below:
>

Seems that there is some kind of controversy between different maintainers. I
did in that way because I was complained to use the c-style on other patches,
and seems, that putting everything as // is Linus Torvalds' preferred style:

https://lkml.org/lkml/2017/11/25/133

I don't mind to change if the c-style is preferred by the maintainer (others
prefer the c++ style) but I think that would be good get an agreement between
subsystems maintainers and document properly.

Best regards,
Enric

> +// SPDX-License-Identifier: GPL-2.0
> /*
> * Copyright (C) 2016 Google, Inc
> *
> - * This program is free software; you can redistribute it and/or modify it
> - * under the terms of the GNU General Public License version 2, as published by
> - * the Free Software Foundation.
> - *
> * Expose a PWM controlled by the ChromeOS EC to the host processor.
> */
>
> Thierry
>

2018-06-06 09:45:46

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH v2 6/8] pwm: cros-ec: Switch to SPDX identifier.

On Wed, Jun 06, 2018 at 11:21:01AM +0200, Enric Balletbo i Serra wrote:
> Hi Thierry,
>
> On 06/06/18 11:08, Thierry Reding wrote:
> > On Tue, Jun 05, 2018 at 07:54:27PM +0200, Enric Balletbo i Serra wrote:
> >> Adopt the SPDX license identifier headers to ease license compliance
> >> management.
> >>
> >> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> >> ---
> >>
> >> Changes in v2: None
> >>
> >> drivers/pwm/pwm-cros-ec.c | 13 ++++---------
> >> 1 file changed, 4 insertions(+), 9 deletions(-)
> >>
> >> diff --git a/drivers/pwm/pwm-cros-ec.c b/drivers/pwm/pwm-cros-ec.c
> >> index 9c13694eaa24..9bf4cde86765 100644
> >> --- a/drivers/pwm/pwm-cros-ec.c
> >> +++ b/drivers/pwm/pwm-cros-ec.c
> >> @@ -1,12 +1,7 @@
> >> -/*
> >> - * Copyright (C) 2016 Google, Inc
> >> - *
> >> - * This program is free software; you can redistribute it and/or modify it
> >> - * under the terms of the GNU General Public License version 2, as published by
> >> - * the Free Software Foundation.
> >> - *
> >> - * Expose a PWM controlled by the ChromeOS EC to the host processor.
> >> - */
> >> +// SPDX-License-Identifier: GPL-2.0
> >> +// Expose a PWM controlled by the ChromeOS EC to the host processor.
> >> +//
> >> +// Copyright (C) 2016 Google, Inc.
> >
> > This is odd. I understand that for some reason there is an exception for
> > SPDX license identifies to use C++ style comments, but why would you
> > make the whole comment C++ style? Why not just something like the below:
> >
>
> Seems that there is some kind of controversy between different maintainers. I
> did in that way because I was complained to use the c-style on other patches,
> and seems, that putting everything as // is Linus Torvalds' preferred style:
>
> https://lkml.org/lkml/2017/11/25/133
>
> I don't mind to change if the c-style is preferred by the maintainer (others
> prefer the c++ style) but I think that would be good get an agreement between
> subsystems maintainers and document properly.

I've read elsewhere that using // for SPDX was supposed to make it stand
out, which is kind of contradicted by the above. However, I interpret
Linus' reply to Mauro as "people tend to do less crazy things with //
than with /* */", so to me it seems that as long you use /* */ sensibly,
there's no reason to avoid it.

No need to resend, though, I can adjust the patch to my own preference
if I decide to do so.

Thierry


Attachments:
(No filename) (2.42 kB)
signature.asc (849.00 B)
Download all attachments

2018-06-18 06:38:59

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH v2 3/8] mfd: cros_ec: Add or fix SPDX-License-Identifier in all files.

On Tue, 05 Jun 2018, Enric Balletbo i Serra wrote:

> And get rid of the license text that is no longer necessary. Also fix
> the license as sometimes doesn't match what the header with the value in
> the MODULE_LICENSE macro. Assuming that the desired license is GPL-2.0+,
> all the files are updated to this license version.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2: None
>
> drivers/mfd/cros_ec.c | 26 ++++++++------------------
> drivers/mfd/cros_ec_dev.c | 23 +++++------------------
> drivers/mfd/cros_ec_dev.h | 16 ++--------------
> drivers/mfd/cros_ec_i2c.c | 18 ++++--------------
> drivers/mfd/cros_ec_spi.c | 20 +++++---------------
> include/linux/mfd/cros_ec.h | 10 +---------
> include/linux/mfd/cros_ec_commands.h | 10 +---------
> include/linux/mfd/cros_ec_lpc_mec.h | 14 +++-----------
> include/linux/mfd/cros_ec_lpc_reg.h | 14 +++-----------
> 9 files changed, 32 insertions(+), 119 deletions(-)
>
> diff --git a/drivers/mfd/cros_ec.c b/drivers/mfd/cros_ec.c
> index 58e05069163e..5b6a1c541543 100644
> --- a/drivers/mfd/cros_ec.c
> +++ b/drivers/mfd/cros_ec.c
> @@ -1,21 +1,11 @@
> -/*
> - * ChromeOS EC multi-function device
> - *
> - * Copyright (C) 2012 Google, Inc
> - *
> - * This software is licensed under the terms of the GNU General Public
> - * License version 2, as published by the Free Software Foundation, and
> - * may be copied, distributed, and modified under those terms.
> - *
> - * 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.
> - *
> - * The ChromeOS EC multi function device is used to mux all the requests
> - * to the EC device for its multiple features: keyboard controller,
> - * battery charging and regulator control, firmware update.
> - */
> +// SPDX-License-Identifier: GPL-2.0+
> +// ChromeOS EC multi-function device.
> +//
> +// Copyright (C) 2012 Google, Inc
> +//
> +// The ChromeOS EC multi function device is used to mux all the requests
> +// to the EC device for its multiple features: keyboard controller,
> +// battery charging and regulator control, firmware update.

I must admit I haven't seen a great many patches like this. Is C++
comments for the SPDX header *and* the Copyright text the done thing
now then?

--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2018-06-19 09:06:12

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [PATCH v2 3/8] mfd: cros_ec: Add or fix SPDX-License-Identifier in all files.

Hi Lee,

On 18/06/18 08:37, Lee Jones wrote:
> On Tue, 05 Jun 2018, Enric Balletbo i Serra wrote:
>
>> And get rid of the license text that is no longer necessary. Also fix
>> the license as sometimes doesn't match what the header with the value in
>> the MODULE_LICENSE macro. Assuming that the desired license is GPL-2.0+,
>> all the files are updated to this license version.
>>
>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
>> ---
>>
>> Changes in v2: None
>>
>> drivers/mfd/cros_ec.c | 26 ++++++++------------------
>> drivers/mfd/cros_ec_dev.c | 23 +++++------------------
>> drivers/mfd/cros_ec_dev.h | 16 ++--------------
>> drivers/mfd/cros_ec_i2c.c | 18 ++++--------------
>> drivers/mfd/cros_ec_spi.c | 20 +++++---------------
>> include/linux/mfd/cros_ec.h | 10 +---------
>> include/linux/mfd/cros_ec_commands.h | 10 +---------
>> include/linux/mfd/cros_ec_lpc_mec.h | 14 +++-----------
>> include/linux/mfd/cros_ec_lpc_reg.h | 14 +++-----------
>> 9 files changed, 32 insertions(+), 119 deletions(-)
>>
>> diff --git a/drivers/mfd/cros_ec.c b/drivers/mfd/cros_ec.c
>> index 58e05069163e..5b6a1c541543 100644
>> --- a/drivers/mfd/cros_ec.c
>> +++ b/drivers/mfd/cros_ec.c
>> @@ -1,21 +1,11 @@
>> -/*
>> - * ChromeOS EC multi-function device
>> - *
>> - * Copyright (C) 2012 Google, Inc
>> - *
>> - * This software is licensed under the terms of the GNU General Public
>> - * License version 2, as published by the Free Software Foundation, and
>> - * may be copied, distributed, and modified under those terms.
>> - *
>> - * 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.
>> - *
>> - * The ChromeOS EC multi function device is used to mux all the requests
>> - * to the EC device for its multiple features: keyboard controller,
>> - * battery charging and regulator control, firmware update.
>> - */
>> +// SPDX-License-Identifier: GPL-2.0+
>> +// ChromeOS EC multi-function device.
>> +//
>> +// Copyright (C) 2012 Google, Inc
>> +//
>> +// The ChromeOS EC multi function device is used to mux all the requests
>> +// to the EC device for its multiple features: keyboard controller,
>> +// battery charging and regulator control, firmware update.
>
> I must admit I haven't seen a great many patches like this. Is C++
> comments for the SPDX header *and* the Copyright text the done thing
> now then?
>

There is a bit of mess here, as per documentation, it is clear that the SPDX tag
for .c files should go in C++ style, but for the copyright notice is not clear
and there are differences between subsystems.

Seems that putting everything as // is Linus Torvalds' preferred style [1] but
other maintainers want the copyright in c-style. If you see current status in
the kernel both styles are present.

[1] https://lkml.org/lkml/2017/11/25/133

Best regards,
Enric









2018-06-25 02:03:06

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 08:14:24PM +0200, Enric Balletbo i Serra wrote:
> Hi Fabio,
>
> On 05/06/18 20:04, Fabio Estevam wrote:
> > Hi Enric,
> >
> > On Tue, Jun 5, 2018 at 2:54 PM, Enric Balletbo i Serra
> > <[email protected]> wrote:
> >> Adopt the SPDX license identifier headers to ease license compliance
> >> management.
> >>
> >> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> >> ---
> >>
> >> Changes in v2:
> >> - [6/9] Do not remove last paragraph.
> >>
> >> drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
> >> 1 file changed, 12 insertions(+), 22 deletions(-)
> >>
> >> diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
> >> index 79eb29550c34..91b2839c12df 100644
> >> --- a/drivers/input/keyboard/cros_ec_keyb.c
> >> +++ b/drivers/input/keyboard/cros_ec_keyb.c
> >> @@ -1,25 +1,15 @@
> >> -/*
> >> - * ChromeOS EC keyboard driver
> >> - *
> >> - * Copyright (C) 2012 Google, Inc
> >> - *
> >> - * This software is licensed under the terms of the GNU General Public
> >> - * License version 2, as published by the Free Software Foundation, and
> >
> > Original text says GPL-2.0...
> >
> >> - * may be copied, distributed, and modified under those terms.
> >> - *
> >> - * 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.
> >> - *
> >> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> >> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> >> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> >> - * but everything else (including deghosting) is done here. The main
> >> - * motivation for this is to keep the EC firmware as simple as possible, since
> >> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> >> - * expensive.
> >> - */
> >> +// SPDX-License-Identifier: GPL-2.0+
> >
> > but here you add a GPL-2.0+ type.
> >
>
> Right, but the module license is set to GPL which means GNU Public License v2 or
> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
> default. These mismatches are common so I think that should be fine for the
> authors, if someone is disagree just let me know and I will change.

NO!

The license text is what you need to follow as almost everyone gets the
MODULE_LICENSE() stuff wrong. You can not follow the MODULE_LICENSE
marking for determining GPLv2 vs. GPLv2+ at this point in time. After
we get the SPDX stuff all cleaned up then we can go and fix up the
MODULE_LICENSE mismatch.

So again, always defer to the license text in the file, NOT the
MODULE_LICENSE() marking.

thanks,

greg k-h

2018-06-25 06:25:24

by Enric Balletbo i Serra

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

Hi Grek,

On 25/06/18 03:57, Greg KH wrote:
> On Tue, Jun 05, 2018 at 08:14:24PM +0200, Enric Balletbo i Serra wrote:
>> Hi Fabio,
>>
>> On 05/06/18 20:04, Fabio Estevam wrote:
>>> Hi Enric,
>>>
>>> On Tue, Jun 5, 2018 at 2:54 PM, Enric Balletbo i Serra
>>> <[email protected]> wrote:
>>>> Adopt the SPDX license identifier headers to ease license compliance
>>>> management.
>>>>
>>>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
>>>> ---
>>>>
>>>> Changes in v2:
>>>> - [6/9] Do not remove last paragraph.
>>>>
>>>> drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
>>>> 1 file changed, 12 insertions(+), 22 deletions(-)
>>>>
>>>> diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
>>>> index 79eb29550c34..91b2839c12df 100644
>>>> --- a/drivers/input/keyboard/cros_ec_keyb.c
>>>> +++ b/drivers/input/keyboard/cros_ec_keyb.c
>>>> @@ -1,25 +1,15 @@
>>>> -/*
>>>> - * ChromeOS EC keyboard driver
>>>> - *
>>>> - * Copyright (C) 2012 Google, Inc
>>>> - *
>>>> - * This software is licensed under the terms of the GNU General Public
>>>> - * License version 2, as published by the Free Software Foundation, and
>>>
>>> Original text says GPL-2.0...
>>>
>>>> - * may be copied, distributed, and modified under those terms.
>>>> - *
>>>> - * 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.
>>>> - *
>>>> - * This driver uses the Chrome OS EC byte-level message-based protocol for
>>>> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
>>>> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
>>>> - * but everything else (including deghosting) is done here. The main
>>>> - * motivation for this is to keep the EC firmware as simple as possible, since
>>>> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
>>>> - * expensive.
>>>> - */
>>>> +// SPDX-License-Identifier: GPL-2.0+
>>>
>>> but here you add a GPL-2.0+ type.
>>>
>>
>> Right, but the module license is set to GPL which means GNU Public License v2 or
>> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
>> default. These mismatches are common so I think that should be fine for the
>> authors, if someone is disagree just let me know and I will change.
>
> NO!
>
> The license text is what you need to follow as almost everyone gets the
> MODULE_LICENSE() stuff wrong. You can not follow the MODULE_LICENSE
> marking for determining GPLv2 vs. GPLv2+ at this point in time. After
> we get the SPDX stuff all cleaned up then we can go and fix up the
> MODULE_LICENSE mismatch.
>
> So again, always defer to the license text in the file, NOT the
> MODULE_LICENSE() marking.
>

Many thanks for your feedback, Dmitry already told me that I was doing wrong
this and I sent another version following the license text, so this patchset was
superseded for v3 [1].

[1] https://patchwork.ozlabs.org/cover/925906/

Thanks,
Enric

> thanks,
>
> greg k-h
>

2018-06-25 06:43:40

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH v2 5/8] Input: cros_ec_keyb - Switch to SPDX identifier.

On Mon, Jun 25, 2018 at 08:23:38AM +0200, Enric Balletbo i Serra wrote:
> Hi Grek,
>
> On 25/06/18 03:57, Greg KH wrote:
> > On Tue, Jun 05, 2018 at 08:14:24PM +0200, Enric Balletbo i Serra wrote:
> >> Hi Fabio,
> >>
> >> On 05/06/18 20:04, Fabio Estevam wrote:
> >>> Hi Enric,
> >>>
> >>> On Tue, Jun 5, 2018 at 2:54 PM, Enric Balletbo i Serra
> >>> <[email protected]> wrote:
> >>>> Adopt the SPDX license identifier headers to ease license compliance
> >>>> management.
> >>>>
> >>>> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> >>>> ---
> >>>>
> >>>> Changes in v2:
> >>>> - [6/9] Do not remove last paragraph.
> >>>>
> >>>> drivers/input/keyboard/cros_ec_keyb.c | 34 ++++++++++-----------------
> >>>> 1 file changed, 12 insertions(+), 22 deletions(-)
> >>>>
> >>>> diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
> >>>> index 79eb29550c34..91b2839c12df 100644
> >>>> --- a/drivers/input/keyboard/cros_ec_keyb.c
> >>>> +++ b/drivers/input/keyboard/cros_ec_keyb.c
> >>>> @@ -1,25 +1,15 @@
> >>>> -/*
> >>>> - * ChromeOS EC keyboard driver
> >>>> - *
> >>>> - * Copyright (C) 2012 Google, Inc
> >>>> - *
> >>>> - * This software is licensed under the terms of the GNU General Public
> >>>> - * License version 2, as published by the Free Software Foundation, and
> >>>
> >>> Original text says GPL-2.0...
> >>>
> >>>> - * may be copied, distributed, and modified under those terms.
> >>>> - *
> >>>> - * 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.
> >>>> - *
> >>>> - * This driver uses the Chrome OS EC byte-level message-based protocol for
> >>>> - * communicating the keyboard state (which keys are pressed) from a keyboard EC
> >>>> - * to the AP over some bus (such as i2c, lpc, spi). The EC does debouncing,
> >>>> - * but everything else (including deghosting) is done here. The main
> >>>> - * motivation for this is to keep the EC firmware as simple as possible, since
> >>>> - * it cannot be easily upgraded and EC flash/IRAM space is relatively
> >>>> - * expensive.
> >>>> - */
> >>>> +// SPDX-License-Identifier: GPL-2.0+
> >>>
> >>> but here you add a GPL-2.0+ type.
> >>>
> >>
> >> Right, but the module license is set to GPL which means GNU Public License v2 or
> >> later, see [1]. So, there is a mismatch. In such cases I assumed GPL-2.0+ as the
> >> default. These mismatches are common so I think that should be fine for the
> >> authors, if someone is disagree just let me know and I will change.
> >
> > NO!
> >
> > The license text is what you need to follow as almost everyone gets the
> > MODULE_LICENSE() stuff wrong. You can not follow the MODULE_LICENSE
> > marking for determining GPLv2 vs. GPLv2+ at this point in time. After
> > we get the SPDX stuff all cleaned up then we can go and fix up the
> > MODULE_LICENSE mismatch.
> >
> > So again, always defer to the license text in the file, NOT the
> > MODULE_LICENSE() marking.
> >
>
> Many thanks for your feedback, Dmitry already told me that I was doing wrong
> this and I sent another version following the license text, so this patchset was
> superseded for v3 [1].
>
> [1] https://patchwork.ozlabs.org/cover/925906/

Ah, good, sorry for the noise then, I didn't see that series.

greg k-h

2018-07-09 17:04:27

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH v2 6/8] pwm: cros-ec: Switch to SPDX identifier.

On Tue, Jun 05, 2018 at 07:54:27PM +0200, Enric Balletbo i Serra wrote:
> Adopt the SPDX license identifier headers to ease license compliance
> management.
>
> Signed-off-by: Enric Balletbo i Serra <[email protected]>
> ---
>
> Changes in v2: None
>
> drivers/pwm/pwm-cros-ec.c | 13 ++++---------
> 1 file changed, 4 insertions(+), 9 deletions(-)

Applied, thanks.

Thierry


Attachments:
(No filename) (406.00 B)
signature.asc (849.00 B)
Download all attachments