linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <michael.hennerich@analog.com>
To: <linux-iio@vger.kernel.org>, <jic23@kernel.org>
Cc: Michael Hennerich <michael.hennerich@analog.com>
Subject: [PATCH 2/2] iio: dac: ad5593r: Add ACPI support
Date: Mon, 19 Dec 2016 13:10:39 +0100	[thread overview]
Message-ID: <1482149439-16327-2-git-send-email-michael.hennerich@analog.com> (raw)
In-Reply-To: <1482149439-16327-1-git-send-email-michael.hennerich@analog.com>

From: Michael Hennerich <michael.hennerich@analog.com>

This patch adds the ACPI/PNP ID. The AD5592/3 driver core is already
designed around the unified device property API.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
---
 drivers/iio/dac/ad5593r.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/iio/dac/ad5593r.c b/drivers/iio/dac/ad5593r.c
index dca158a..fc11ea0 100644
--- a/drivers/iio/dac/ad5593r.c
+++ b/drivers/iio/dac/ad5593r.c
@@ -13,6 +13,7 @@
 #include <linux/i2c.h>
 #include <linux/module.h>
 #include <linux/of.h>
+#include <linux/acpi.h>
 
 #define AD5593R_MODE_CONF		(0 << 4)
 #define AD5593R_MODE_DAC_WRITE		(1 << 4)
@@ -115,10 +116,17 @@ static const struct of_device_id ad5593r_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, ad5593r_of_match);
 
+static const struct acpi_device_id ad5593r_acpi_match[] = {
+	{"ADS5593", },
+	{ },
+};
+MODULE_DEVICE_TABLE(acpi, ad5593r_acpi_match);
+
 static struct i2c_driver ad5593r_driver = {
 	.driver = {
 		.name = "ad5593r",
 		.of_match_table = of_match_ptr(ad5593r_of_match),
+		.acpi_match_table = ACPI_PTR(ad5593r_acpi_match),
 	},
 	.probe = ad5593r_i2c_probe,
 	.remove = ad5593r_i2c_remove,
-- 
2.7.4


  reply	other threads:[~2016-12-19 12:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-19 12:10 [PATCH 1/2] iio: dac: ad5592r: Add ACPI support michael.hennerich
2016-12-19 12:10 ` michael.hennerich [this message]
2016-12-30 17:19 ` Jonathan Cameron

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=1482149439-16327-2-git-send-email-michael.hennerich@analog.com \
    --to=michael.hennerich@analog.com \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).