diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2011-06-09 23:36:08 -0400 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2011-06-23 02:03:46 -0400 |
commit | 24f246ac10ae6a6ae873045387d4501498869f74 (patch) | |
tree | eb0c2dde2080898958e317c37ed87bb883653678 /drivers/gpu/drm/nouveau/nouveau_drv.h | |
parent | 15ba79ad44fed84a9dabf6996144789424abae5b (diff) |
drm/nouveau: rework vram init/fini ordering a little
Commit "drm/nouveau: add some debug output if nouveau_mm busy at destroy time"
revealed an issue where vram mm takedown would actually fail due to there
still being nodes present, causing nouveau to leak a small amount of memory
on module unload.
This splits TTM/nouveau_mm a bit more cleanly and ensures nouveau_mm fini
isn't done until all gpuobjs are also destroyed.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nouveau_drv.h')
-rw-r--r-- | drivers/gpu/drm/nouveau/nouveau_drv.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h b/drivers/gpu/drm/nouveau/nouveau_drv.h index bbea0452dca7..d610edb044c4 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drv.h +++ b/drivers/gpu/drm/nouveau/nouveau_drv.h | |||
@@ -504,7 +504,10 @@ struct nouveau_pm_engine { | |||
504 | }; | 504 | }; |
505 | 505 | ||
506 | struct nouveau_vram_engine { | 506 | struct nouveau_vram_engine { |
507 | struct nouveau_mm *mm; | ||
508 | |||
507 | int (*init)(struct drm_device *); | 509 | int (*init)(struct drm_device *); |
510 | void (*takedown)(struct drm_device *dev); | ||
508 | int (*get)(struct drm_device *, u64, u32 align, u32 size_nc, | 511 | int (*get)(struct drm_device *, u64, u32 align, u32 size_nc, |
509 | u32 type, struct nouveau_mem **); | 512 | u32 type, struct nouveau_mem **); |
510 | void (*put)(struct drm_device *, struct nouveau_mem **); | 513 | void (*put)(struct drm_device *, struct nouveau_mem **); |
@@ -717,7 +720,6 @@ struct drm_nouveau_private { | |||
717 | /* VRAM/fb configuration */ | 720 | /* VRAM/fb configuration */ |
718 | uint64_t vram_size; | 721 | uint64_t vram_size; |
719 | uint64_t vram_sys_base; | 722 | uint64_t vram_sys_base; |
720 | u32 vram_rblock_size; | ||
721 | 723 | ||
722 | uint64_t fb_phys; | 724 | uint64_t fb_phys; |
723 | uint64_t fb_available_size; | 725 | uint64_t fb_available_size; |