diff mbox series

[v2,2/6] platform/chrome: cros_ec: remove unused variable `was_wake_device`

Message ID 20220209045035.380615-3-tzungbi@google.com (mailing list archive)
State Superseded
Headers show
Series platform/chrome: cros_ec: miscellaneous cleanups | expand

Commit Message

Tzung-Bi Shih Feb. 9, 2022, 4:50 a.m. UTC
`was_wake_device` is unused.  Remove it.

Signed-off-by: Tzung-Bi Shih <tzungbi@google.com>
---
 drivers/platform/chrome/cros_ec.c           | 1 -
 include/linux/platform_data/cros_ec_proto.h | 3 ---
 2 files changed, 4 deletions(-)

Comments

Prashant Malani Feb. 9, 2022, 5:58 a.m. UTC | #1
Hi,

On Tue, Feb 8, 2022 at 8:50 PM Tzung-Bi Shih <tzungbi@google.com> wrote:
>
> `was_wake_device` is unused.  Remove it.
nit: This commit message doesn't add anything to the patch (it is
repeating the subject), so it
should be fine to drop it.

>
> Signed-off-by: Tzung-Bi Shih <tzungbi@google.com>
Reviewed-by: Prashant Malani <pmalani@chromium.org>
> ---
In the future, please add a change log for versions here. Quoting the
patch submission guide [1]

"One good use for the additional comments after the --- marker
is...Other comments relevant
only to the moment or the maintainer, not suitable for the permanent
changelog, should also
go here. A good example of such comments might be patch changelogs
which describe what
has changed between the v1 and v2 version of the patch."

[1] https://www.kernel.org/doc/html/latest/process/submitting-patches.html#the-canonical-patch-format
Tzung-Bi Shih Feb. 9, 2022, 9:36 a.m. UTC | #2
On Tue, Feb 08, 2022 at 09:58:41PM -0800, Prashant Malani wrote:
> On Tue, Feb 8, 2022 at 8:50 PM Tzung-Bi Shih <tzungbi@google.com> wrote:
> >
> > `was_wake_device` is unused.  Remove it.
> nit: This commit message doesn't add anything to the patch (it is
> repeating the subject), so it
> should be fine to drop it.

Ack.

> > ---
> In the future, please add a change log for versions here. Quoting the
> patch submission guide [1]
> 
> "One good use for the additional comments after the --- marker
> is...Other comments relevant
> only to the moment or the maintainer, not suitable for the permanent
> changelog, should also
> go here. A good example of such comments might be patch changelogs
> which describe what
> has changed between the v1 and v2 version of the patch."
> 
> [1] https://www.kernel.org/doc/html/latest/process/submitting-patches.html#the-canonical-patch-format

They are in the cover letter.  Will copy them to each patch.
diff mbox series

Patch

diff --git a/drivers/platform/chrome/cros_ec.c b/drivers/platform/chrome/cros_ec.c
index 7ce667ff08e0..303af630c03e 100644
--- a/drivers/platform/chrome/cros_ec.c
+++ b/drivers/platform/chrome/cros_ec.c
@@ -344,7 +344,6 @@  int cros_ec_suspend(struct cros_ec_device *ec_dev)
 		ec_dev->wake_enabled = !enable_irq_wake(ec_dev->irq);
 
 	disable_irq(ec_dev->irq);
-	ec_dev->was_wake_device = ec_dev->wake_enabled;
 	ec_dev->suspended = true;
 
 	return 0;
diff --git a/include/linux/platform_data/cros_ec_proto.h b/include/linux/platform_data/cros_ec_proto.h
index df3c78c92ca2..c65971ec90ea 100644
--- a/include/linux/platform_data/cros_ec_proto.h
+++ b/include/linux/platform_data/cros_ec_proto.h
@@ -76,8 +76,6 @@  struct cros_ec_command {
  * struct cros_ec_device - Information about a ChromeOS EC device.
  * @phys_name: Name of physical comms layer (e.g. 'i2c-4').
  * @dev: Device pointer for physical comms device
- * @was_wake_device: True if this device was set to wake the system from
- *                   sleep at the last suspend.
  * @cros_class: The class structure for this device.
  * @cmd_readmem: Direct read of the EC memory-mapped region, if supported.
  *     @offset: Is within EC_LPC_ADDR_MEMMAP region.
@@ -137,7 +135,6 @@  struct cros_ec_device {
 	/* These are used by other drivers that want to talk to the EC */
 	const char *phys_name;
 	struct device *dev;
-	bool was_wake_device;
 	struct class *cros_class;
 	int (*cmd_readmem)(struct cros_ec_device *ec, unsigned int offset,
 			   unsigned int bytes, void *dest);