aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/remoteproc/rpres.c
diff options
context:
space:
mode:
authorMiguel Vadillo <vadillo@ti.com>2011-07-05 20:58:02 -0500
committerIliyan Malchev <malchev@google.com>2011-07-20 17:34:32 -0700
commitfce1d8835485265fc4fefaa83d94d224aecbb89b (patch)
treeb6e2f167c18487b2620195753714406b5be02c7f /drivers/remoteproc/rpres.c
parent9208332f7b34f4761d47c8c5e0178becdf3783c7 (diff)
downloadkernel_samsung_tuna-fce1d8835485265fc4fefaa83d94d224aecbb89b.zip
kernel_samsung_tuna-fce1d8835485265fc4fefaa83d94d224aecbb89b.tar.gz
kernel_samsung_tuna-fce1d8835485265fc4fefaa83d94d224aecbb89b.tar.bz2
omap: rpres: skip the creation of already created devices
Some devices like: - iva - dsp - fdif are being created for pm purposes and create them again is not recommended. For these devices the pm framework is exporting api's to get them. If a resource is already created use the api to get the device and add the platform data and information needed for rpres to control such device. Change-Id: I6640883f911f4c21d204c20ded1ced104af5ed7c Signed-off-by: Miguel Vadillo <vadillo@ti.com>
Diffstat (limited to 'drivers/remoteproc/rpres.c')
-rw-r--r--drivers/remoteproc/rpres.c23
1 files changed, 19 insertions, 4 deletions
diff --git a/drivers/remoteproc/rpres.c b/drivers/remoteproc/rpres.c
index c52e6a1..e839f70 100644
--- a/drivers/remoteproc/rpres.c
+++ b/drivers/remoteproc/rpres.c
@@ -165,10 +165,25 @@ static int __devexit rpres_remove(struct platform_device *pdev)
return 0;
}
+static struct platform_device_id rpres_id_table[] = {
+ {
+ .name = "iva",
+ },
+ {
+ .name = "fdif",
+ },
+ {
+ .name = "rpres",
+ },
+ { },
+};
+MODULE_DEVICE_TABLE(platform, rpres_id_table);
+
static struct platform_driver omap_rpres_driver = {
- .probe = rpres_probe,
- .remove = __devexit_p(rpres_remove),
- .driver = {
+ .id_table = rpres_id_table,
+ .probe = rpres_probe,
+ .remove = __devexit_p(rpres_remove),
+ .driver = {
.name = "rpres",
.owner = THIS_MODULE,
},
@@ -178,7 +193,7 @@ static int __init rpres_init(void)
{
return platform_driver_register(&omap_rpres_driver);
}
-module_init(rpres_init);
+late_initcall(rpres_init);
static void __exit rpres_exit(void)
{