From patchwork Sat Oct 13 21:58:26 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Max Filippov X-Patchwork-Id: 1589311 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork2.kernel.org (Postfix) with ESMTP id 4CAA7DF24C for ; Sat, 13 Oct 2012 21:58:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1FDB59EC15 for ; Sat, 13 Oct 2012 14:58:54 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lb0-f177.google.com (mail-lb0-f177.google.com [209.85.217.177]) by gabe.freedesktop.org (Postfix) with ESMTP id 631619EC16 for ; Sat, 13 Oct 2012 14:58:40 -0700 (PDT) Received: by mail-lb0-f177.google.com with SMTP id gi11so2656572lbb.36 for ; Sat, 13 Oct 2012 14:58:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer; bh=3gTa6OPsXPBw9oViaKDkB35YMRD7oY/X/1nhhttN8sA=; b=Gw6/RDOxuBU75YQIX7goZ1awIrVXOq15j1gYLj8/PBtFSn+m6e8bF3bH6OKroIdzxj LkXNf4KmoTu7IOSVlcEdPECMs2olWuRMt/NE6VjfBEfacwfqo6m19oreMitZWNmKzhxR zfXKTWJ9v6hwqExmHzDhVYJuSDM7nUFsRR6+9u0WxEr2WuIKVe4T6OqQ+vXxUa83x3gn /u3jTH4yNZLJX8bsdLnLI8IMjtuOApWG2Own/1EdKuKtg4lr2rBWO2RGkg0LKR2roKvb XuDexou9Axv1uf4MooUrVBNxESsm8DQKEaLZmspa6YJDyVtf3y7vPM4JfblXSoIpCW2D XJbg== Received: by 10.152.106.212 with SMTP id gw20mr6758979lab.8.1350165519020; Sat, 13 Oct 2012 14:58:39 -0700 (PDT) Received: from grizzly.metropolis ([188.134.19.124]) by mx.google.com with ESMTPS id ti4sm3217543lab.1.2012.10.13.14.58.37 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 13 Oct 2012 14:58:37 -0700 (PDT) From: Max Filippov To: dri-devel@lists.freedesktop.org Subject: [PATCH v2] drm/nouveau: only call ttm_agp_tt_create when __OS_HAS_AGP Date: Sun, 14 Oct 2012 01:58:26 +0400 Message-Id: <1350165506-27415-1-git-send-email-jcmvbkbc@gmail.com> X-Mailer: git-send-email 1.7.7.6 Cc: Ben Skeggs X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org ttm_agp_tt_create is itself defined under CONFIG_AGP, so there's no point calling it otherwise. Signed-off-by: Max Filippov --- This fixes allmodconfig build failure for xtensa: http://kisskb.ellerman.id.au/kisskb/buildresult/7346547/ drivers/gpu/drm/nouveau/nouveau_bo.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_bo.c b/drivers/gpu/drm/nouveau/nouveau_bo.c index 259e5f1..35ac57f 100644 --- a/drivers/gpu/drm/nouveau/nouveau_bo.c +++ b/drivers/gpu/drm/nouveau/nouveau_bo.c @@ -456,6 +456,7 @@ static struct ttm_tt * nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size, uint32_t page_flags, struct page *dummy_read) { +#if __OS_HAS_AGP struct nouveau_drm *drm = nouveau_bdev(bdev); struct drm_device *dev = drm->dev; @@ -463,6 +464,7 @@ nouveau_ttm_tt_create(struct ttm_bo_device *bdev, unsigned long size, return ttm_agp_tt_create(bdev, dev->agp->bridge, size, page_flags, dummy_read); } +#endif return nouveau_sgdma_create_ttm(bdev, size, page_flags, dummy_read); }