From patchwork Mon Jul 21 11:27:27 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Christian_K=C3=B6nig?= X-Patchwork-Id: 4594401 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 4F1AB9F2B8 for ; Mon, 21 Jul 2014 11:27:53 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 58B2020107 for ; Mon, 21 Jul 2014 11:27:52 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 10C74200EC for ; Mon, 21 Jul 2014 11:27:49 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 14A756E338; Mon, 21 Jul 2014 04:27:48 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from pegasos-out.vodafone.de (pegasos-out.vodafone.de [80.84.1.38]) by gabe.freedesktop.org (Postfix) with ESMTP id 84B416E338 for ; Mon, 21 Jul 2014 04:27:46 -0700 (PDT) Received: from localhost (localhost.localdomain [127.0.0.1]) by pegasos-out.vodafone.de (Rohrpostix1 Daemon) with ESMTP id C48A5261427 for ; Mon, 21 Jul 2014 13:27:43 +0200 (CEST) X-Virus-Scanned: amavisd-new at vodafone.de X-Spam-Score: 0.2 X-Spam-Level: X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Authentication-Results: rohrpostix1.prod.vfnet.de (amavisd-new); dkim=pass header.i=@vodafone.de Received: from pegasos-out.vodafone.de ([127.0.0.1]) by localhost (rohrpostix1.prod.vfnet.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hTfMvX+VUGVz for ; Mon, 21 Jul 2014 13:27:38 +0200 (CEST) Received: from smtp-03.vodafone.de (xsmail-dmz9.prod.vfnet.de [10.215.254.40]) by pegasos-out.vodafone.de (Rohrpostix1 Daemon) with ESMTP id 119FB26143E for ; Mon, 21 Jul 2014 13:27:36 +0200 (CEST) X-DKIM: OpenDKIM Filter v2.6.8 pegasos-out.vodafone.de 119FB26143E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vodafone.de; s=mail; t=1405942056; bh=oX9kMlmV1deUBGTSMeE9emj2lNvq3wWtJ3Z8v1R0hb4=; h=From:To:Subject:Date; b=NFHP1VDllR+2fts5j8/x2Y9yfT1zaZwIbdX4F5ln75ERCGQSvEO+vzCk/FkLW71w4 dB9fwgguw0tZ3KZDsYU8fcl3GoaLlg/IurN00X7oqvWWuT1w1dqDXWMODBOmNL/4Z9 W4LY+Fdp9LK0pMNDQkwllpxf7bZKY3BvqSKvMfV0= X-DKIM: OpenDKIM Filter v2.0.2 smtp-03.vodafone.de 56E21ED38B X-Virus-Scanned: amavisd-new at vodafone.de Received: from smtp-03.vodafone.de ([127.0.0.1]) by localhost (xsmail-dmz9.prod.vfnet.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AEcJcsjKDYcQ for ; Mon, 21 Jul 2014 13:27:29 +0200 (CEST) From: =?UTF-8?q?Christian=20K=C3=B6nig?= To: dri-devel@lists.freedesktop.org Subject: [PATCH] drm/radeon: remove discardable flag from radeon_gem_object_create Date: Mon, 21 Jul 2014 13:27:27 +0200 Message-Id: <1405942047-26711-1-git-send-email-deathsimple@vodafone.de> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Christian König Unused and unimplemented. Also fix specifying the kernel flag incorrectly at one occasion. Signed-off-by: Christian König --- drivers/gpu/drm/radeon/radeon.h | 2 +- drivers/gpu/drm/radeon/radeon_fb.c | 3 +-- drivers/gpu/drm/radeon/radeon_gem.c | 7 +++---- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h index 6ce80ae..9b6fbda 100644 --- a/drivers/gpu/drm/radeon/radeon.h +++ b/drivers/gpu/drm/radeon/radeon.h @@ -548,7 +548,7 @@ int radeon_gem_init(struct radeon_device *rdev); void radeon_gem_fini(struct radeon_device *rdev); int radeon_gem_object_create(struct radeon_device *rdev, unsigned long size, int alignment, int initial_domain, - u32 flags, bool discardable, bool kernel, + u32 flags, bool kernel, struct drm_gem_object **obj); int radeon_mode_dumb_create(struct drm_file *file_priv, diff --git a/drivers/gpu/drm/radeon/radeon_fb.c b/drivers/gpu/drm/radeon/radeon_fb.c index 477ea0d..94b0f2a 100644 --- a/drivers/gpu/drm/radeon/radeon_fb.c +++ b/drivers/gpu/drm/radeon/radeon_fb.c @@ -127,8 +127,7 @@ static int radeonfb_create_pinned_object(struct radeon_fbdev *rfbdev, aligned_size = ALIGN(size, PAGE_SIZE); ret = radeon_gem_object_create(rdev, aligned_size, 0, RADEON_GEM_DOMAIN_VRAM, - 0, false, true, - &gobj); + 0, true, &gobj); if (ret) { printk(KERN_ERR "failed to allocate framebuffer (%d)\n", aligned_size); diff --git a/drivers/gpu/drm/radeon/radeon_gem.c b/drivers/gpu/drm/radeon/radeon_gem.c index eafe316..9fb1c06 100644 --- a/drivers/gpu/drm/radeon/radeon_gem.c +++ b/drivers/gpu/drm/radeon/radeon_gem.c @@ -42,7 +42,7 @@ void radeon_gem_object_free(struct drm_gem_object *gobj) int radeon_gem_object_create(struct radeon_device *rdev, unsigned long size, int alignment, int initial_domain, - u32 flags, bool discardable, bool kernel, + u32 flags, bool kernel, struct drm_gem_object **obj) { struct radeon_bo *robj; @@ -255,7 +255,7 @@ int radeon_gem_create_ioctl(struct drm_device *dev, void *data, args->size = roundup(args->size, PAGE_SIZE); r = radeon_gem_object_create(rdev, args->size, args->alignment, args->initial_domain, args->flags, - false, false, &gobj); + false, &gobj); if (r) { up_read(&rdev->exclusive_lock); r = radeon_gem_handle_lockup(rdev, r); @@ -570,8 +570,7 @@ int radeon_mode_dumb_create(struct drm_file *file_priv, r = radeon_gem_object_create(rdev, args->size, 0, RADEON_GEM_DOMAIN_VRAM, 0, - false, ttm_bo_type_device, - &gobj); + false, &gobj); if (r) return -ENOMEM;