From patchwork Fri Jul 31 22:22:37 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Deucher X-Patchwork-Id: 6921001 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id DB704C05AC for ; Fri, 31 Jul 2015 22:23:50 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0AC5C20653 for ; Fri, 31 Jul 2015 22:23:50 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 3512A20631 for ; Fri, 31 Jul 2015 22:23:49 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4190E7A228; Fri, 31 Jul 2015 15:23:48 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-yk0-f178.google.com (mail-yk0-f178.google.com [209.85.160.178]) by gabe.freedesktop.org (Postfix) with ESMTPS id 981946EDF7 for ; Fri, 31 Jul 2015 15:23:08 -0700 (PDT) Received: by ykay190 with SMTP id y190so70354221yka.3 for ; Fri, 31 Jul 2015 15:23:08 -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:in-reply-to:references; bh=VxixvZ9Ny2i/fs9PCdL3biN+iCrmH7UHPkYihEs0tGA=; b=Tmj3oorLNh1kRJtZj4z/yjFth3+YpkoCT9kxj6m+yxNrj7eNvahOf6Z9j6fHSmoyaQ P310APp/KNb6OvF9heNAkvkXds7wohTqSLI6lkkVZtWgfIwSJGQ4EbSGcEz4sMi/iqbd qH5G7aM36pHvQ8rBoUiyI05cqCURvcPkDkflbXjpW2o8Zcktqvo6sl7hUQPWgxapDbdH EGwbmsxZpZQGFcqu4fKTKV65el1lQiF2GObE4DqJ2zv9adoJK48p5IJYXLCUqjNSBzXP +fzeObR9xj85FT5EZsS1OobcPLkW4JvDMQP6t62uAWdUBEoLvUFQt092ZrdJ4f+YQ+hm 87Yw== X-Received: by 10.170.185.134 with SMTP id b128mr6280193yke.85.1438381387954; Fri, 31 Jul 2015 15:23:07 -0700 (PDT) Received: from localhost.localdomain (static-74-96-105-49.washdc.fios.verizon.net. [74.96.105.49]) by smtp.gmail.com with ESMTPSA id u78sm5438990ywu.13.2015.07.31.15.23.07 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 31 Jul 2015 15:23:07 -0700 (PDT) From: Alex Deucher X-Google-Original-From: Alex Deucher To: dri-devel@lists.freedesktop.org Subject: [PATCH 21/31] drm/amdgpu: wait forever for wait emit Date: Fri, 31 Jul 2015 18:22:37 -0400 Message-Id: <1438381367-24980-22-git-send-email-alexander.deucher@amd.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1438381367-24980-1-git-send-email-alexander.deucher@amd.com> References: <1438381367-24980-1-git-send-email-alexander.deucher@amd.com> X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Chunming Zhou the job must be emitted by scheduler, otherwise scheduler is abnormal. Signed-off-by: Chunming Zhou Reviewed-by: Christian K?nig --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c index 58ce265..95807b6 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c @@ -302,8 +302,8 @@ struct fence *amdgpu_ctx_get_fence(struct amdgpu_ctx *ctx, if (amdgpu_enable_scheduler) { r = amd_sched_wait_emit(&cring->c_entity, seq, - true, - AMDGPU_WAIT_IDLE_TIMEOUT_IN_MS); + false, + -1); if (r) return NULL; } diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c index 34938d2..26c55a7 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c @@ -386,7 +386,7 @@ static int amdgpu_vm_clear_bo(struct amdgpu_device *adev, sched_job); r = amd_sched_wait_emit(&adev->kernel_ctx->rings[ring->idx].c_entity, v_seq, - true, + false, -1); if (r) DRM_ERROR("emit timeout\n"); @@ -537,7 +537,7 @@ int amdgpu_vm_update_page_directory(struct amdgpu_device *adev, sched_job); r = amd_sched_wait_emit(&adev->kernel_ctx->rings[ring->idx].c_entity, v_seq, - true, + false, -1); if (r) DRM_ERROR("emit timeout\n"); @@ -890,7 +890,7 @@ static int amdgpu_vm_bo_update_mapping(struct amdgpu_device *adev, sched_job); r = amd_sched_wait_emit(&adev->kernel_ctx->rings[ring->idx].c_entity, v_seq, - true, + false, -1); if (r) DRM_ERROR("emit timeout\n");