Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753681AbdFVTqM (ORCPT ); Thu, 22 Jun 2017 15:46:12 -0400 Received: from mail-pg0-f54.google.com ([74.125.83.54]:36545 "EHLO mail-pg0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751147AbdFVTqK (ORCPT ); Thu, 22 Jun 2017 15:46:10 -0400 Date: Thu, 22 Jun 2017 12:46:05 -0700 From: Benson Leung To: Enric Balletbo i Serra Cc: olof@lixom.net, bleung@chromium.org, linux-kernel@vger.kernel.org, lee.jones@linaro.org, Archana Patni , Thierry Escande , bleung@google.com Subject: Re: [PATCH RESEND 08/13] platform/chrome: cros_ec_lpc: Add power management ops Message-ID: <20170622194605.GC85041@decatoncale.mtv.corp.google.com> References: <20170516161319.13257-1-enric.balletbo@collabora.com> <20170516161319.13257-9-enric.balletbo@collabora.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="bKyqfOwhbdpXa4YI" Content-Disposition: inline In-Reply-To: <20170516161319.13257-9-enric.balletbo@collabora.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2995 Lines: 99 --bKyqfOwhbdpXa4YI Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Enric and Thierry, On Tue, May 16, 2017 at 06:13:14PM +0200, Enric Balletbo i Serra wrote: > From: Archana Patni >=20 > This patch adds suspend and resume pm ops to the LPC ChromeOS EC driver. > These LPC handlers call the croc_ec generic handlers. >=20 > Signed-off-by: Archana Patni > Signed-off-by: Thierry Escande Signed-off-by: Benson Leung Applied. Thanks. > --- > drivers/platform/chrome/cros_ec_lpc.c | 21 +++++++++++++++++++++ > 1 file changed, 21 insertions(+) >=20 > diff --git a/drivers/platform/chrome/cros_ec_lpc.c b/drivers/platform/chr= ome/cros_ec_lpc.c > index 90703521..89afad7 100644 > --- a/drivers/platform/chrome/cros_ec_lpc.c > +++ b/drivers/platform/chrome/cros_ec_lpc.c > @@ -333,10 +333,31 @@ static struct dmi_system_id cros_ec_lpc_dmi_table[]= __initdata =3D { > }; > MODULE_DEVICE_TABLE(dmi, cros_ec_lpc_dmi_table); > =20 > +#ifdef CONFIG_PM_SLEEP > +static int cros_ec_lpc_suspend(struct device *dev) > +{ > + struct cros_ec_device *ec_dev =3D dev_get_drvdata(dev); > + > + return cros_ec_suspend(ec_dev); > +} > + > +static int cros_ec_lpc_resume(struct device *dev) > +{ > + struct cros_ec_device *ec_dev =3D dev_get_drvdata(dev); > + > + return cros_ec_resume(ec_dev); > +} > +#endif > + > +const struct dev_pm_ops cros_ec_lpc_pm_ops =3D { > + SET_LATE_SYSTEM_SLEEP_PM_OPS(cros_ec_lpc_suspend, cros_ec_lpc_resume) > +}; > + > static struct platform_driver cros_ec_lpc_driver =3D { > .driver =3D { > .name =3D DRV_NAME, > .acpi_match_table =3D cros_ec_lpc_acpi_device_ids, > + .pm =3D &cros_ec_lpc_pm_ops, > }, > .probe =3D cros_ec_lpc_probe, > .remove =3D cros_ec_lpc_remove, > --=20 > 2.9.3 >=20 --=20 Benson Leung Staff Software Engineer Chrome OS Kernel Google Inc. bleung@google.com Chromium OS Project bleung@chromium.org --bKyqfOwhbdpXa4YI Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJZTB59AAoJEB8J9XsKL+ZYGWYP+wbg0E9PcuBk8SjUeptcsN+0 PU94fyyDWEObDb8elnPFofKDR1NvH/D2e8Hx4x/K98Yl6ujMntqz1aWxHQeC+7Kv BeY5sGudQjzgbNZStbEVkn8fHx0dDpiqYyjKSmx3IpEwTKgDGv/gnehxfEmp5BNi eLa5YnXBHjCi3saiCSmuAYCjXanfHEzMM4to6zQSrhfNHHI4pN4n8r89SWh0vYUM S6rDh8bJ2x8TyTgxOb6ZdpC4E8CpQMJudsr3P7K4Q3v6fIlsE9LnnwzYdEoy9Okg 0AtRjHTfXhRAk1HCET0lZ3jKx6BqTYR1riDPUoHoqdRig3M3F7Z8jE+daC9bVGfx AnyHLulNw0PNdND5fkDkRz8aF+fj3wW4AFKhPXRWFchg0BMpUVj0R5kuhYJwMKP7 YENNSjwk9OOtM5UBIuDk758/+EpLjIhJBhqAWVixtiKDNEpbVwDbY8mtOVJ8mSoL UBiB673NTAuvcVbKbOUjBRsJbU8mv4AGt7VXtK/qIeW/QSG1kxgd0KgRIH2fafiy QmUShB+Z8+e7bs+FlpPd8vaVXJSfotTPlJFoqJa9Spm847LDuXXCmdmonwJDYY7x W1YhjC8t3sXCoRqAYhdIJa8T0ITCahbgQawQV3gedWVyfiUwqzGNXTuzXHNSu8v9 U62EQOhcd6JsqI9yIYDF =nkm/ -----END PGP SIGNATURE----- --bKyqfOwhbdpXa4YI--