summaryrefslogtreecommitdiff
path: root/drivers/nfc/trf7970a.c
diff options
context:
space:
mode:
authorJavier Martinez Canillas <javier@osg.samsung.com>2015-09-16 11:08:42 +0200
committerSamuel Ortiz <sameo@linux.intel.com>2015-10-19 19:54:04 +0200
commit3c39c1a54a26c5495d48df796bc1f3fba78667f2 (patch)
tree3752247a453c2471ea804c8531f7e24104644bb2 /drivers/nfc/trf7970a.c
parentd7e7f02f71bee425d651ced7ba3b316df61ab945 (diff)
NFC: trf7970a: Add OF match table
The Documentation/devicetree/bindings/net/nfc/trf7970a.txt DT binding doc lists "ti,trf7970a" as a compatible string but the corresponding driver does not have an OF match table. Add the table to the driver so the SPI core can do an OF style match. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/nfc/trf7970a.c')
-rw-r--r--drivers/nfc/trf7970a.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/nfc/trf7970a.c b/drivers/nfc/trf7970a.c
index 70b0707fd9a9..123aa981c9d8 100644
--- a/drivers/nfc/trf7970a.c
+++ b/drivers/nfc/trf7970a.c
@@ -2211,6 +2211,12 @@ static const struct dev_pm_ops trf7970a_pm_ops = {
trf7970a_pm_runtime_resume, NULL)
};
+static const struct of_device_id trf7970a_of_match[] = {
+ { .compatible = "ti,trf7970a", },
+ { /* sentinel */ },
+};
+MODULE_DEVICE_TABLE(of, trf7970a_of_match);
+
static const struct spi_device_id trf7970a_id_table[] = {
{ "trf7970a", 0 },
{ }
@@ -2223,6 +2229,7 @@ static struct spi_driver trf7970a_spi_driver = {
.id_table = trf7970a_id_table,
.driver = {
.name = "trf7970a",
+ .of_match_table = of_match_ptr(trf7970a_of_match),
.owner = THIS_MODULE,
.pm = &trf7970a_pm_ops,
},