diff options
author | Franck LENORMAND <franck.lenormand@nxp.com> | 2018-01-18 16:35:45 +0100 |
---|---|---|
committer | Jason Liu <jason.hui.liu@nxp.com> | 2019-02-12 10:30:17 +0800 |
commit | 7babbd891c459e334125187c2cd63ccc37032767 (patch) | |
tree | 5de50472e816399b54a90178712de8ec5e50eb80 /drivers/crypto/caam/secvio.c | |
parent | 259942aa1ed7e35982d3ff29458a8372bf3e6d83 (diff) |
MLK-17412-01: Fix secvio driver to have same driver name as DTS
The name of the driver was "snvs-secvio" which doesn't corresponds
to its use in the differents dts files.
This patch change the driver name to "caam-snvs" to corresponds
to the dts files.
Signed-off-by: Franck LENORMAND <franck.lenormand@nxp.com>
Diffstat (limited to 'drivers/crypto/caam/secvio.c')
-rw-r--r-- | drivers/crypto/caam/secvio.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/drivers/crypto/caam/secvio.c b/drivers/crypto/caam/secvio.c index 305782147ded..dac2fef7039b 100644 --- a/drivers/crypto/caam/secvio.c +++ b/drivers/crypto/caam/secvio.c @@ -11,6 +11,13 @@ #include <linux/of.h> #include <linux/of_irq.h> #include <linux/of_address.h> + +/* The driver is matched with node caam_snvs to get regmap + * It will then retrieve interruption and tamper alarm configuration from + * node caam-secvio searching for the compat string "fsl,imx6q-caam-secvio" + */ +#define DRIVER_NAME "caam-snvs" + /* * These names are associated with each violation handler. * The source names were taken from MX6, and are based on recommendations @@ -219,12 +226,13 @@ static int snvs_secvio_probe(struct platform_device *pdev) npirq = of_find_compatible_node(NULL, NULL, "fsl,imx6q-caam-secvio"); if (!npirq) { - dev_err(svdev, "can't identify secvio interrupt\n"); + dev_err(svdev, "can't find secvio node\n"); kfree(svpriv); return -EINVAL; } svpriv->irq = irq_of_parse_and_map(npirq, 0); if (svpriv->irq <= 0) { + dev_err(svdev, "can't identify secvio interrupt\n"); kfree(svpriv); return -EINVAL; } @@ -234,7 +242,7 @@ static int snvs_secvio_probe(struct platform_device *pdev) itd = of_get_property(npirq, "internal-boot-tamper", NULL); etd = of_get_property(npirq, "external-pin-tamper", NULL); if (!jtd | !wtd | !itd | !etd ) { - dev_err(svdev, "can't identify tamper alarm configuration\n"); + dev_err(svdev, "can't identify all tamper alarm configuration\n"); kfree(svpriv); return -EINVAL; } @@ -285,7 +293,7 @@ static int snvs_secvio_probe(struct platform_device *pdev) (unsigned long)svdev); error = request_irq(svpriv->irq, snvs_secvio_interrupt, - IRQF_SHARED, "snvs-secvio", svdev); + IRQF_SHARED, DRIVER_NAME, svdev); if (error) { dev_err(svdev, "can't connect secvio interrupt\n"); irq_dispose_mapping(svpriv->irq); @@ -317,7 +325,7 @@ MODULE_DEVICE_TABLE(of, snvs_secvio_match); static struct platform_driver snvs_secvio_driver = { .driver = { - .name = "snvs-secvio", + .name = DRIVER_NAME, .owner = THIS_MODULE, .of_match_table = snvs_secvio_match, }, |