From: Ben Skeggs Subject: [PATCH 1/2] drm/ttm: ensure ttm_mem_io_free is called on bo destruction Date: Thu, 4 Nov 2010 10:03:46 +1000 Message-ID: <1288829027-23239-1-git-send-email-skeggsb@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-qw0-f49.google.com (mail-qw0-f49.google.com [209.85.216.49]) by gabe.freedesktop.org (Postfix) with ESMTP id 5DCBB9E7B4 for ; Wed, 3 Nov 2010 17:04:16 -0700 (PDT) Received: by qwh6 with SMTP id 6so692612qwh.36 for ; Wed, 03 Nov 2010 17:04:15 -0700 (PDT) List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: dri-devel@lists.freedesktop.org Cc: Ben Skeggs List-Id: dri-devel@lists.freedesktop.org From: Ben Skeggs Nouveau will start to use ttm_mem_io_reserve to allocate BAR VM space for VRAM mappings, and without this call GPU address space gets leaked. Signed-off-by: Ben Skeggs --- drivers/gpu/drm/ttm/ttm_bo.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index dfa163b..c373cf9 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c @@ -472,6 +472,7 @@ static void ttm_bo_cleanup_memtype_use(struct ttm_buffer_object *bo) wake_up_all(&bo->event_queue); spin_unlock(&glob->lru_lock); + ttm_mem_io_free(bo->bdev, &tmp_mem); ttm_bo_mem_put(bo, &tmp_mem); } -- 1.7.3.1