devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] dt-bindings: fsl-imx-sahara: Add i.MX51 as a supported SoC
@ 2018-06-22 16:21 Fabio Estevam
  2018-06-22 16:21 ` [PATCH 2/2] crypto: sahara - Add i.MX51 entry Fabio Estevam
  0 siblings, 1 reply; 2+ messages in thread
From: Fabio Estevam @ 2018-06-22 16:21 UTC (permalink / raw)
  To: herbert; +Cc: robh+dt, linux-crypto, devicetree, horia.geanta, Fabio Estevam

From: Fabio Estevam <fabio.estevam@nxp.com>

i.MX51 and i.MX51 share the same sahara IP block version, so add
i.MX51 in the list of supported SoCs.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
---
 Documentation/devicetree/bindings/crypto/fsl-imx-sahara.txt | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/crypto/fsl-imx-sahara.txt b/Documentation/devicetree/bindings/crypto/fsl-imx-sahara.txt
index e8a35c7..5343a48 100644
--- a/Documentation/devicetree/bindings/crypto/fsl-imx-sahara.txt
+++ b/Documentation/devicetree/bindings/crypto/fsl-imx-sahara.txt
@@ -1,8 +1,9 @@
 Freescale SAHARA Cryptographic Accelerator included in some i.MX chips.
-Currently only i.MX27 and i.MX53 are supported.
+Currently i.MX27, i.MX51 and i.MX53 are supported.
 
 Required properties:
-- compatible : Should be "fsl,<soc>-sahara"
+- compatible : Should be "fsl,imx27-sahara", "fsl,imx51-sahara"
+or "fsl,imx53-sahara"
 - reg : Should contain SAHARA registers location and length
 - interrupts : Should contain SAHARA interrupt number
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH 2/2] crypto: sahara - Add i.MX51 entry
  2018-06-22 16:21 [PATCH 1/2] dt-bindings: fsl-imx-sahara: Add i.MX51 as a supported SoC Fabio Estevam
@ 2018-06-22 16:21 ` Fabio Estevam
  0 siblings, 0 replies; 2+ messages in thread
From: Fabio Estevam @ 2018-06-22 16:21 UTC (permalink / raw)
  To: herbert; +Cc: robh+dt, linux-crypto, devicetree, horia.geanta, Fabio Estevam

From: Fabio Estevam <fabio.estevam@nxp.com>

i.MX51 and i.MX51 share the same sahara IP block version, so add
i.MX51 in the compatible list.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
---
 drivers/crypto/sahara.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/crypto/sahara.c b/drivers/crypto/sahara.c
index 0f2245e..ce1a42c 100644
--- a/drivers/crypto/sahara.c
+++ b/drivers/crypto/sahara.c
@@ -1382,6 +1382,7 @@ static const struct platform_device_id sahara_platform_ids[] = {
 MODULE_DEVICE_TABLE(platform, sahara_platform_ids);
 
 static const struct of_device_id sahara_dt_ids[] = {
+	{ .compatible = "fsl,imx51-sahara" },
 	{ .compatible = "fsl,imx53-sahara" },
 	{ .compatible = "fsl,imx27-sahara" },
 	{ /* sentinel */ }
@@ -1507,7 +1508,9 @@ static int sahara_probe(struct platform_device *pdev)
 		if (version != SAHARA_VERSION_3)
 			err = -ENODEV;
 	} else if (of_device_is_compatible(pdev->dev.of_node,
-			"fsl,imx53-sahara")) {
+		   "fsl,imx53-sahara") ||
+		   of_device_is_compatible(pdev->dev.of_node,
+		   "fsl,imx51-sahara")) {
 		if (((version >> 8) & 0xff) != SAHARA_VERSION_4)
 			err = -ENODEV;
 		version = (version >> 8) & 0xff;
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-06-22 16:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-22 16:21 [PATCH 1/2] dt-bindings: fsl-imx-sahara: Add i.MX51 as a supported SoC Fabio Estevam
2018-06-22 16:21 ` [PATCH 2/2] crypto: sahara - Add i.MX51 entry Fabio Estevam

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).