gpu: pvr: move device registration into board file
authorCarsten Valdemar Munk <carsten.munk@gmail.com>
Wed, 15 Dec 2010 14:24:25 +0000 (09:24 -0500)
committerGrazvydas Ignotas <notasas@gmail.com>
Sun, 20 May 2012 18:09:40 +0000 (21:09 +0300)
Needed by an upcoming patch adding board specific device parameters.

Signed-off-by: Imre Deak <imre.deak@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
Adapt for Nokia N900 MeeGo kernel

Signed-off-by: Carsten Munk <carsten@maemo.org>
pvr/module.c

index a38dcf3..565e420 100644 (file)
@@ -148,19 +148,6 @@ static int pvr_resume(struct platform_device *pdev)
        return 0;
 }
 
-static void pvr_dev_release(struct device *pdev)
-{
-       PVR_DPF(PVR_DBG_WARNING, "pvr_dev_release(pdev=%p)", pdev);
-}
-
-static struct platform_device pvr_device = {
-       .name = DRVNAME,
-       .id = -1,
-       .dev = {
-               .release = pvr_dev_release
-       }
-};
-
 static struct miscdevice pvr_miscdevice = {
        .minor = MISC_DYNAMIC_MINOR,
        .name = DRVNAME,
@@ -254,14 +241,8 @@ static int __init pvr_init(void)
        if (error < 0)
                goto err4;
 
-       error = platform_device_register(&pvr_device);
-       if (error)
-               goto err5;
-
        return 0;
 
-err5:
-       platform_driver_unregister(&pvr_driver);
 err4:
        PVRMMapCleanup();
        LinuxBridgeDeInit();
@@ -283,7 +264,6 @@ static void __exit pvr_cleanup(void)
 
        SysAcquireData(&sysdata);
 
-       platform_device_unregister(&pvr_device);
        platform_driver_unregister(&pvr_driver);
 
        PVRMMapCleanup();