iio: ltr501: Add ACPI enumeration support
Added ACPI enumeration support for LTR501 chip. Signed-off-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
This commit is contained in:
parent
eea53b4a25
commit
772154d0dd
|
@ -17,6 +17,7 @@
|
||||||
#include <linux/err.h>
|
#include <linux/err.h>
|
||||||
#include <linux/delay.h>
|
#include <linux/delay.h>
|
||||||
#include <linux/regmap.h>
|
#include <linux/regmap.h>
|
||||||
|
#include <linux/acpi.h>
|
||||||
|
|
||||||
#include <linux/iio/iio.h>
|
#include <linux/iio/iio.h>
|
||||||
#include <linux/iio/events.h>
|
#include <linux/iio/events.h>
|
||||||
|
@ -1264,6 +1265,12 @@ static int ltr501_resume(struct device *dev)
|
||||||
|
|
||||||
static SIMPLE_DEV_PM_OPS(ltr501_pm_ops, ltr501_suspend, ltr501_resume);
|
static SIMPLE_DEV_PM_OPS(ltr501_pm_ops, ltr501_suspend, ltr501_resume);
|
||||||
|
|
||||||
|
static const struct acpi_device_id ltr_acpi_match[] = {
|
||||||
|
{"LTER0501", 0},
|
||||||
|
{ },
|
||||||
|
};
|
||||||
|
MODULE_DEVICE_TABLE(acpi, ltr_acpi_match);
|
||||||
|
|
||||||
static const struct i2c_device_id ltr501_id[] = {
|
static const struct i2c_device_id ltr501_id[] = {
|
||||||
{ "ltr501", 0 },
|
{ "ltr501", 0 },
|
||||||
{ }
|
{ }
|
||||||
|
@ -1274,6 +1281,7 @@ static struct i2c_driver ltr501_driver = {
|
||||||
.driver = {
|
.driver = {
|
||||||
.name = LTR501_DRV_NAME,
|
.name = LTR501_DRV_NAME,
|
||||||
.pm = <r501_pm_ops,
|
.pm = <r501_pm_ops,
|
||||||
|
.acpi_match_table = ACPI_PTR(ltr_acpi_match),
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
},
|
},
|
||||||
.probe = ltr501_probe,
|
.probe = ltr501_probe,
|
||||||
|
|
Loading…
Reference in New Issue