linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: lee.jones@linaro.org (Lee Jones)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 6/6] crypto: ux500/hash - Enable DT probing of the driver
Date: Thu, 16 May 2013 12:27:26 +0100	[thread overview]
Message-ID: <1368703646-26418-7-git-send-email-lee.jones@linaro.org> (raw)
In-Reply-To: <1368703646-26418-1-git-send-email-lee.jones@linaro.org>

By providing an OF match table with a suitable compatible string, we
can ensure the ux500-hasht driver is probed by supplying an associated
DT node in a given platform's Device Tree.

Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: linux-crypto at vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/crypto/ux500/hash/hash_core.c |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/crypto/ux500/hash/hash_core.c b/drivers/crypto/ux500/hash/hash_core.c
index 9ca6fbb..f89fe8a 100644
--- a/drivers/crypto/ux500/hash/hash_core.c
+++ b/drivers/crypto/ux500/hash/hash_core.c
@@ -1981,6 +1981,11 @@ static int ux500_hash_resume(struct device *dev)
 
 static SIMPLE_DEV_PM_OPS(ux500_hash_pm, ux500_hash_suspend, ux500_hash_resume);
 
+static const struct of_device_id ux500_hash_match[] = {
+        { .compatible = "stericsson,ux500-hash" },
+        { },
+};
+
 static struct platform_driver hash_driver = {
 	.probe  = ux500_hash_probe,
 	.remove = ux500_hash_remove,
@@ -1988,6 +1993,7 @@ static struct platform_driver hash_driver = {
 	.driver = {
 		.owner = THIS_MODULE,
 		.name  = "hash1",
+		.of_match_table = ux500_hash_match,
 		.pm    = &ux500_hash_pm,
 	}
 };
-- 
1.7.10.4

  parent reply	other threads:[~2013-05-16 11:27 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-16 11:27 [PATCH 0/6] crypto: ux500/[cryp|hash] - Enable Device Tree Lee Jones
2013-05-16 11:27 ` [PATCH 1/6] ARM: ux500: Add Device Tree nodes for the ux500 Crypt device Lee Jones
2013-05-16 11:27 ` [PATCH 2/6] ARM: ux500: Add Device Tree nodes for the ux500 Hash device Lee Jones
2013-05-16 11:27 ` [PATCH 3/6] ARM: ux500: Provide an AUXDATA entry for ux500-cyrpt Lee Jones
2013-05-16 11:27 ` [PATCH 4/6] ARM: ux500: Provide an AUXDATA entry for ux500-hash Lee Jones
2013-05-16 11:27 ` [PATCH 5/6] crypto: ux500/cryp - Enable DT probing of the driver Lee Jones
2013-05-24  6:20   ` Linus Walleij
2013-05-24  6:21     ` Herbert Xu
2013-05-24  8:32     ` Lee Jones
2013-05-24 11:16       ` Linus Walleij
2013-05-24  6:26   ` Linus Walleij
2013-05-16 11:27 ` Lee Jones [this message]
2013-05-24  6:27 ` [PATCH 0/6] crypto: ux500/[cryp|hash] - Enable Device Tree Linus Walleij

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=1368703646-26418-7-git-send-email-lee.jones@linaro.org \
    --to=lee.jones@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.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).