From patchwork Mon Nov 23 11:41:54 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Harrison X-Patchwork-Id: 7680451 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9255D9F6E4 for ; Mon, 23 Nov 2015 11:42:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5F7DB206E8 for ; Mon, 23 Nov 2015 11:42:40 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id A1E24206D6 for ; Mon, 23 Nov 2015 11:42:39 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AECF36E553; Mon, 23 Nov 2015 03:42:38 -0800 (PST) X-Original-To: Intel-GFX@lists.freedesktop.org Delivered-To: Intel-GFX@lists.freedesktop.org Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by gabe.freedesktop.org (Postfix) with ESMTP id 38A056E54D for ; Mon, 23 Nov 2015 03:42:37 -0800 (PST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga103.jf.intel.com with ESMTP; 23 Nov 2015 03:42:37 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,336,1444719600"; d="scan'208";a="692487849" Received: from johnharr-linux.isw.intel.com ([10.102.226.93]) by orsmga003.jf.intel.com with ESMTP; 23 Nov 2015 03:42:37 -0800 From: John.C.Harrison@Intel.com To: Intel-GFX@Lists.FreeDesktop.Org Date: Mon, 23 Nov 2015 11:41:54 +0000 Message-Id: <1448278932-31551-20-git-send-email-John.C.Harrison@Intel.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1448278932-31551-1-git-send-email-John.C.Harrison@Intel.com> References: <1448278932-31551-1-git-send-email-John.C.Harrison@Intel.com> Organization: Intel Corporation (UK) Ltd. - Co. Reg. #1134945 - Pipers Way, Swindon SN3 1RJ Subject: [Intel-gfx] [RFC 19/37] drm/i915/error: capture errored context based on request context-id X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, 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: Dave Gordon Context capture hasn't worked for a while now, probably since the introduction of execlists; this patch makes it work again by using a different way of identifying the context of interest. For: VIZ-2021 Signed-off-by: Dave Gordon --- drivers/gpu/drm/i915/i915_gpu_error.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c index 0697fc3..a40c947 100644 --- a/drivers/gpu/drm/i915/i915_gpu_error.c +++ b/drivers/gpu/drm/i915/i915_gpu_error.c @@ -1084,13 +1084,12 @@ static void i915_gem_record_active_context(struct intel_engine_cs *ring, continue; } - if (!error->ccid) - continue; - if (i915.enable_execlists) base += LRC_PPHWSP_PN * PAGE_SIZE; - if (base == (error->ccid & PAGE_MASK)) + if (error->ccid && base == (error->ccid & PAGE_MASK)) + ering->ctx = i915_error_ggtt_object_create(dev_priv, obj); + else if (((base ^ ering->ctx_desc) & 0x00000000FFFFF000ULL) == 0) ering->ctx = i915_error_ggtt_object_create(dev_priv, obj); } }