aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorAlexandre Courbot <acourbot@nvidia.com>2015-03-20 06:41:05 -0400
committerBen Skeggs <bskeggs@redhat.com>2015-04-14 03:00:51 -0400
commitbbf2e92f914019324bb4351fcf0db9f41329a7c3 (patch)
treeadb06d561022b9ac0f1026c02649f02f46c13b66 /drivers/gpu
parent25eb3a924f8589b5ad80e5d50d743befca8a46de (diff)
drm/nouveau/platform: fix probe error path
A "return 0" found its way in the middle of the error path of nouveau_platform_probe(), remove it as it will make the kernel crash if we try to unload the module afterwards. While we are at it, also remove the IOMMU domain if it has been created, as we should. Signed-off-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_platform.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_platform.c b/drivers/gpu/drm/nouveau/nouveau_platform.c
index f83aa12ee5c6..775277f1edb0 100644
--- a/drivers/gpu/drm/nouveau/nouveau_platform.c
+++ b/drivers/gpu/drm/nouveau/nouveau_platform.c
@@ -209,10 +209,9 @@ static int nouveau_platform_probe(struct platform_device *pdev)
209err_unref: 209err_unref:
210 drm_dev_unref(drm); 210 drm_dev_unref(drm);
211 211
212 return 0;
213
214power_down: 212power_down:
215 nouveau_platform_power_down(gpu); 213 nouveau_platform_power_down(gpu);
214 nouveau_platform_remove_iommu(&pdev->dev, gpu);
216 215
217 return err; 216 return err;
218} 217}