diff options
Diffstat (limited to 'drivers/gpu/drm/lima/lima_drv.c')
-rw-r--r-- | drivers/gpu/drm/lima/lima_drv.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/drivers/gpu/drm/lima/lima_drv.c b/drivers/gpu/drm/lima/lima_drv.c index 97ed70c36340..bbbdc8455e2f 100644 --- a/drivers/gpu/drm/lima/lima_drv.c +++ b/drivers/gpu/drm/lima/lima_drv.c @@ -10,6 +10,7 @@ #include <drm/drm_prime.h> #include <drm/lima_drm.h> +#include "lima_device.h" #include "lima_drv.h" #include "lima_gem.h" #include "lima_vm.h" @@ -397,13 +398,19 @@ static int lima_pdev_probe(struct platform_device *pdev) if (err) goto err_out1; + err = lima_devfreq_init(ldev); + if (err) { + dev_err(&pdev->dev, "Fatal error during devfreq init\n"); + goto err_out2; + } + /* * Register the DRM device with the core and the connectors with * sysfs. */ err = drm_dev_register(ddev, 0); if (err < 0) - goto err_out2; + goto err_out3; platform_set_drvdata(pdev, ldev); @@ -412,8 +419,10 @@ static int lima_pdev_probe(struct platform_device *pdev) return 0; -err_out2: +err_out3: lima_device_fini(ldev); +err_out2: + lima_devfreq_fini(ldev); err_out1: drm_dev_put(ddev); err_out0: @@ -429,6 +438,7 @@ static int lima_pdev_remove(struct platform_device *pdev) sysfs_remove_bin_file(&ldev->dev->kobj, &lima_error_state_attr); platform_set_drvdata(pdev, NULL); drm_dev_unregister(ddev); + lima_devfreq_fini(ldev); lima_device_fini(ldev); drm_dev_put(ddev); lima_sched_slab_fini(); |