diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2010-03-25 02:00:09 -0400 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2010-04-08 20:12:30 -0400 |
commit | 78bb35129e9400fb50580e971d964563fc8e0218 (patch) | |
tree | 9a91f9486033b290859269a14dd79750d6f26356 /drivers | |
parent | 494ab824f179ddeb2022cbb1d25aee41ab46ee9b (diff) |
drm/nouveau: fixup the init failure paths some more
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_state.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_state.c b/drivers/gpu/drm/nouveau/nouveau_state.c index 1ee2b65d72e9..a9e9cf35429c 100644 --- a/drivers/gpu/drm/nouveau/nouveau_state.c +++ b/drivers/gpu/drm/nouveau/nouveau_state.c | |||
@@ -505,7 +505,7 @@ nouveau_card_init(struct drm_device *dev) | |||
505 | else | 505 | else |
506 | ret = nv04_display_create(dev); | 506 | ret = nv04_display_create(dev); |
507 | if (ret) | 507 | if (ret) |
508 | goto out_irq; | 508 | goto out_channel; |
509 | } | 509 | } |
510 | 510 | ||
511 | ret = nouveau_backlight_init(dev); | 511 | ret = nouveau_backlight_init(dev); |
@@ -519,6 +519,11 @@ nouveau_card_init(struct drm_device *dev) | |||
519 | 519 | ||
520 | return 0; | 520 | return 0; |
521 | 521 | ||
522 | out_channel: | ||
523 | if (dev_priv->channel) { | ||
524 | nouveau_channel_free(dev_priv->channel); | ||
525 | dev_priv->channel = NULL; | ||
526 | } | ||
522 | out_irq: | 527 | out_irq: |
523 | drm_irq_uninstall(dev); | 528 | drm_irq_uninstall(dev); |
524 | out_fifo: | 529 | out_fifo: |
@@ -536,6 +541,7 @@ out_mc: | |||
536 | out_gpuobj: | 541 | out_gpuobj: |
537 | nouveau_gpuobj_takedown(dev); | 542 | nouveau_gpuobj_takedown(dev); |
538 | out_mem: | 543 | out_mem: |
544 | nouveau_sgdma_takedown(dev); | ||
539 | nouveau_mem_close(dev); | 545 | nouveau_mem_close(dev); |
540 | out_instmem: | 546 | out_instmem: |
541 | engine->instmem.takedown(dev); | 547 | engine->instmem.takedown(dev); |