mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Benson Leung <bleung@google.com>
To: Thierry Escande <thierry.escande@collabora.com>
Cc: Benson Leung <bleung@chromium.org>,
	Lee Jones <lee.jones@linaro.org>,
	linux-kernel@vger.kernel.org, wnhuang@google.com,
	bleung@google.com
Subject: Re: [PATCH 6/8] mfd: cros_ec_i2c: add ACPI module device table
Date: Thu, 10 Aug 2017 21:11:03 -0700	[thread overview]
Message-ID: <20170811041103.GD13907@decatoncale.mtv.corp.google.com> (raw)
In-Reply-To: <1502403410-5233-7-git-send-email-thierry.escande@collabora.com>

[-- Attachment #1: Type: text/plain, Size: 2105 bytes --]

Hi Thierry,

On Fri, Aug 11, 2017 at 12:16:48AM +0200, Thierry Escande wrote:
> From: Wei-Ning Huang <wnhuang@google.com>
> 
> Add ACPI module device table for matching cros-ec devices to load the
> cros_ec_i2c driver automatically.
> 
> Signed-off-by: Wei-Ning Huang <wnhuang@google.com>
> Signed-off-by: Thierry Escande <thierry.escande@collabora.com>

Acked-by: Benson Leung <bleung@chromium.org>

> ---
>  drivers/mfd/cros_ec_i2c.c | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> diff --git a/drivers/mfd/cros_ec_i2c.c b/drivers/mfd/cros_ec_i2c.c
> index 576fcc4..56fc667 100644
> --- a/drivers/mfd/cros_ec_i2c.c
> +++ b/drivers/mfd/cros_ec_i2c.c
> @@ -13,6 +13,7 @@
>   * GNU General Public License for more details.
>   */
>  
> +#include <linux/acpi.h>
>  #include <linux/delay.h>
>  #include <linux/kernel.h>
>  #include <linux/module.h>
> @@ -345,11 +346,13 @@ const struct dev_pm_ops cros_ec_i2c_pm_ops = {
>  	SET_LATE_SYSTEM_SLEEP_PM_OPS(cros_ec_i2c_suspend, cros_ec_i2c_resume)
>  };
>  
> +#ifdef CONFIG_OF
>  static const struct of_device_id cros_ec_i2c_of_match[] = {
>  	{ .compatible = "google,cros-ec-i2c", },
>  	{ /* sentinel */ },
>  };
>  MODULE_DEVICE_TABLE(of, cros_ec_i2c_of_match);
> +#endif
>  
>  static const struct i2c_device_id cros_ec_i2c_id[] = {
>  	{ "cros-ec-i2c", 0 },
> @@ -357,9 +360,18 @@ static const struct i2c_device_id cros_ec_i2c_id[] = {
>  };
>  MODULE_DEVICE_TABLE(i2c, cros_ec_i2c_id);
>  
> +#ifdef CONFIG_ACPI
> +static const struct acpi_device_id cros_ec_i2c_acpi_id[] = {
> +	{ "GOOG0008", 0 },
> +	{ },
> +};
> +MODULE_DEVICE_TABLE(acpi, cros_ec_i2c_acpi_id);
> +#endif
> +
>  static struct i2c_driver cros_ec_driver = {
>  	.driver	= {
>  		.name	= "cros-ec-i2c",
> +		.acpi_match_table = ACPI_PTR(cros_ec_i2c_acpi_id),
>  		.of_match_table = of_match_ptr(cros_ec_i2c_of_match),
>  		.pm	= &cros_ec_i2c_pm_ops,
>  	},
> -- 
> 2.7.4
> 

-- 
Benson Leung
Staff Software Engineer
Chrome OS Kernel
Google Inc.
bleung@google.com
Chromium OS Project
bleung@chromium.org

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2017-08-11  4:11 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-10 22:16 [PATCH 0/8] platform/chrome: cros_ec: Fixes and improvements Thierry Escande
2017-08-10 22:16 ` [PATCH 1/8] iio: cros_ec: Relax sampling frequency before suspending Thierry Escande
2017-08-11  3:25   ` Benson Leung
2017-08-12 12:41     ` Jonathan Cameron
2017-08-10 22:16 ` [PATCH 2/8] mfd: cros_ec_i2c: move the system sleep pm ops to late Thierry Escande
2017-08-11  3:31   ` Benson Leung
2017-08-10 22:16 ` [PATCH 3/8] mfd: cros_ec: Stop the debugfs work when suspended Thierry Escande
2017-08-11  3:54   ` Benson Leung
2017-08-10 22:16 ` [PATCH 4/8] platform/chrome: cros_ec: register shutdown function for debugfs Thierry Escande
2017-08-11  4:01   ` Benson Leung
2017-08-10 22:16 ` [PATCH 5/8] mfd: cros_ec: fail early if we cannot identify the EC Thierry Escande
2017-08-11  4:06   ` Benson Leung
2017-08-10 22:16 ` [PATCH 6/8] mfd: cros_ec_i2c: add ACPI module device table Thierry Escande
2017-08-11  4:11   ` Benson Leung [this message]
2017-08-10 22:16 ` [PATCH 7/8] platform/chrome: cros_ec: Add sysfs entry to set keyboard wake lid angle Thierry Escande
2017-08-11  5:29   ` Benson Leung
2017-08-11 13:07     ` Thierry Escande
2017-08-10 22:16 ` [PATCH 8/8] platform/chrome: cros_ec: sysfs: Modify error handling Thierry Escande

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170811041103.GD13907@decatoncale.mtv.corp.google.com \
    --to=bleung@google.com \
    --cc=bleung@chromium.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=thierry.escande@collabora.com \
    --cc=wnhuang@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome