# \[PATCH 1/4\] crypto: caam - platform\_bus\_type migration

- Subsystems: CRYPTO API, FREESCALE CAAM (Cryptographic Acceleration and Assurance Module) DRIVER, THE REST
- Maintainers: Herbert Xu, "David S. Miller", Horia Geantă, Pankaj Gupta, Sahil Malhotra, Linus Torvalds
- List: linux-crypto
- 2 messages, 2 authors
- Page: https://ratatoskr.run/linux-crypto/2011/05/8470921/t

## \[PATCH 1/4\] crypto: caam - platform\_bus\_type migration

- From: Kim Phillips \<hidden\>
- Date: 2011-05-15 03:08:06 
- Message: https://ratatoskr.run/linux-crypto/2011/05/8470921.md

```text
this fixes a build error since cryptodev-2.6 got rebased
to include commit d714d1979d7b4df7e2c127407f4014ce71f73cd0
"dt: eliminate of_platform_driver shim code".

Signed-off-by: Kim Phillips <redacted>
---
 drivers/crypto/caam/ctrl.c |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/crypto/caam/ctrl.c b/drivers/crypto/caam/ctrl.c
index 59aae4e..9009713 100644
--- a/drivers/crypto/caam/ctrl.c
+++ b/drivers/crypto/caam/ctrl.c
@@ -44,8 +44,7 @@ static int caam_remove(struct platform_device *pdev)
 }
 
 /* Probe routine for CAAM top (controller) level */
-static int caam_probe(struct platform_device *pdev,
-		      const struct of_device_id *devmatch)
+static int caam_probe(struct platform_device *pdev)
 {
 	int d, ring, rspec;
 	struct device *dev;
@@ -242,7 +241,7 @@ static struct of_device_id caam_match[] = {
 };
 MODULE_DEVICE_TABLE(of, caam_match);
 
-static struct of_platform_driver caam_driver = {
+static struct platform_driver caam_driver = {
 	.driver = {
 		.name = "caam",
 		.owner = THIS_MODULE,
@@ -254,12 +253,12 @@ static struct of_platform_driver caam_driver = {
 
 static int __init caam_base_init(void)
 {
-	return of_register_platform_driver(&caam_driver);
+	return platform_driver_register(&caam_driver);
 }
 
 static void __exit caam_base_exit(void)
 {
-	return of_unregister_platform_driver(&caam_driver);
+	return platform_driver_unregister(&caam_driver);
 }
 
 module_init(caam_base_init);
-- 
1.7.5.1
```

## Re: \[PATCH 1/4\] crypto: caam - platform\_bus\_type migration

- From: Herbert Xu \<herbert@gondor.apana.org.au\>
- Date: 2011-05-19 04:39:07 
- Message: https://ratatoskr.run/linux-crypto/2011/05/8470926.md

```text
On Sat, May 14, 2011 at 10:07:55PM -0500, Kim Phillips wrote:
> this fixes a build error since cryptodev-2.6 got rebased
> to include commit d714d1979d7b4df7e2c127407f4014ce71f73cd0
> "dt: eliminate of_platform_driver shim code".
> 
> Signed-off-by: Kim Phillips <redacted>

All four patches applied.  Thanks Kim!
-- 
Email: Herbert Xu [ref]
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
```
