From patchwork Tue Apr 6 13:40:43 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Joonas Lahtinen X-Patchwork-Id: 12185323 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,INCLUDES_PULL_REQUEST, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B86EBC433ED for ; Tue, 6 Apr 2021 13:40:52 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 72C2D613C7 for ; Tue, 6 Apr 2021 13:40:52 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 72C2D613C7 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C3CAE6E0BA; Tue, 6 Apr 2021 13:40:51 +0000 (UTC) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTPS id 99B746E05A; Tue, 6 Apr 2021 13:40:50 +0000 (UTC) IronPort-SDR: 4akxnD/QR3y8TCvGYgaV7QbFdxxp17cjnTNZwDH+DWTrplDQGpokxBNoFchVZ+plX7cvXeZadF K9f6m8juhykw== X-IronPort-AV: E=McAfee;i="6000,8403,9946"; a="180195238" X-IronPort-AV: E=Sophos;i="5.81,309,1610438400"; d="scan'208";a="180195238" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Apr 2021 06:40:49 -0700 IronPort-SDR: hwd9aEb/9KTjYZ+VEr8H1CYP/KEXiNIB/3WoN8iUUnO5NfevhdRuhnKCWbvjYEgTOGBwqL67mY wK8BTlqtpGTg== X-IronPort-AV: E=Sophos;i="5.81,309,1610438400"; d="scan'208";a="612538533" Received: from jkeenan-mobl.ger.corp.intel.com (HELO localhost) ([10.252.4.27]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Apr 2021 06:40:45 -0700 Date: Tue, 6 Apr 2021 16:40:43 +0300 From: Joonas Lahtinen To: Dave Airlie , Daniel Vetter Subject: [PULL] drm-intel-gt-next Message-ID: MIME-Version: 1.0 Content-Disposition: inline X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: dim-tools@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Rodrigo Vivi , Sean Paul , intel-gfx@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Hi Dave & Daniel, Bit late PR due to Easter break. Prep work for local memory support as requested. Hard hang fix for Sandybridge. Sanitize dma-buf size on import and avoid GPU reset if heartbeat callback runs before timeout. The rest is mostly small fixes and code/checkpatch cleanups. Regards, Joonas *** drm-intel-gt-next-2021-04-06: Driver Changes: - Prepare for local/device memory support on DG1 by starting to use it for kernel internal allocations: context, ring and engine scratch (Matt A, CQ, Abdiel, Imre) - Sandybridge fix to avoid hard hang on ring resume (Chris) - Limit imported dma-buf size to int32 (Matt A) - Double check heartbeat timeout before resetting (Chris) - Use new tasklet API for execution list (Emil) - Fix SPDX checkpats warnings (Chris) - Fixes for various checkpatch warnings (Chris) - Selftest improvements (Chris) - Move the defer_request waiter active assertion to correct spot (Chris) - Make local-memory probing a GT operation (Matt, Tvrtko) - Protect against request freeing during cancellation on wedging (Chris) - Retire unexpected starting state error dumping (Chris) - Distinction of memory regions in debugging (Zbigniew) - Always flush the submission queue on checking for idle (Chris) - Consolidate 2big error check to helper (Matt) - Decrease number of subplatform bits (Tvrtko) - Remove unused internal request priority levels (Chris) - Document the unused internal header bits in buddy allocator (Matt) - Cleanup the region class/instance encoding (Matt) The following changes since commit 06debd6e1b28029e6e77c41e59a162868f377897: Merge tag 'drm-intel-next-2021-03-16' of git://anongit.freedesktop.org/drm/drm-intel into drm-next (2021-03-18 08:06:34 +1000) are available in the Git repository at: git://anongit.freedesktop.org/drm/drm-intel tags/drm-intel-gt-next-2021-04-06 for you to fetch changes up to 2da21daa7d93817fa82f703c29adfcb5eed7f77d: drm/i915/gt: Always flush the submission queue on checking for idle (2021-03-24 19:31:59 +0100) ---------------------------------------------------------------- Driver Changes: - Prepare for local/device memory support on DG1 by starting to use it for kernel internal allocations: context, ring and engine scratch (Matt A, CQ, Abdiel, Imre) - Sandybridge fix to avoid hard hang on ring resume (Chris) - Limit imported dma-buf size to int32 (Matt A) - Double check heartbeat timeout before resetting (Chris) - Use new tasklet API for execution list (Emil) - Fix SPDX checkpats warnings (Chris) - Fixes for various checkpatch warnings (Chris) - Selftest improvements (Chris) - Move the defer_request waiter active assertion to correct spot (Chris) - Make local-memory probing a GT operation (Matt, Tvrtko) - Protect against request freeing during cancellation on wedging (Chris) - Retire unexpected starting state error dumping (Chris) - Distinction of memory regions in debugging (Zbigniew) - Always flush the submission queue on checking for idle (Chris) - Consolidate 2big error check to helper (Matt) - Decrease number of subplatform bits (Tvrtko) - Remove unused internal request priority levels (Chris) - Document the unused internal header bits in buddy allocator (Matt) - Cleanup the region class/instance encoding (Matt) ---------------------------------------------------------------- Abdiel Janulgue (1): drm/i915: introduce mem->reserved CQ Tang (1): drm/i915: reserve stolen for LMEM region Chris Wilson (22): drm/i915: Strip out internal priorities drm/i915: Remove I915_USER_PRIORITY_SHIFT drm/i915/gt: Call stop_ring() from ring resume, again drm/i915/gt: SPDX cleanup drm/i915/gt: Add some missing blank lines after declaration drm/i915/gt: Remove repeated words from comments drm/i915/gt: Fixup misaligned function parameters drm/i915/gt: Remove a bonus newline drm/i915/gt: Wrap macro arg in () drm/i915/gt: Insert spaces into GEN3_L3LOG_SIZE/4 drm/i915/gt: Replace unnecessary ',' with '; ' drm/i915/gt: Add a space before '(' drm/i915/gt: Replace 'return' with a fall-through drm/i915/selftests: Check for engine-reset errors in the middle of workarounds drm/i915/gt: Move the defer_request waiter active assertion drm/i915: Protect against request freeing during cancellation on wedging drm/i915/selftests: Use a single copy of the mocs table drm/i915/gt: Retire unexpected starting state error dumping drm/i915/selftests: Restore previous heartbeat interval drm/i915/gt: Double check heartbeat timeout before resetting drm/i915/selftest: Synchronise with the GPU timestamp drm/i915/gt: Always flush the submission queue on checking for idle Emil Renner Berthing (1): drm/i915/gt: use new tasklet API for execution list Imre Deak (1): drm/i915/dg1: Reserve first 1MB of local memory Matthew Auld (11): drm/i915/gem: don't trust the dma_buf->size drm/i915/gem: consolidate 2big error checking for object sizes drm/i915/buddy: document the unused header bits drm/i915: make local-memory probing a GT operation drm/i915: setup the LMEM region drm/i915: allocate context from LMEM drm/i915: move engine scratch to LMEM drm/i915/gtt/dg1: add PTE_LM plumbing for ppGTT drm/i915/gtt/dg1: add PTE_LM plumbing for GGTT drm/i915: cleanup the region class/instance encoding drm/i915: give stolen system memory its own class Michel Thierry (1): drm/i915: allocate cmd ring in lmem Tvrtko Ursulin (1): drm/i915: Decrease number of subplatform bits Zbigniew KempczyƄski (1): drm/i915: Distinction of memory regions drivers/gpu/drm/i915/display/intel_display.c | 4 +- drivers/gpu/drm/i915/gem/i915_gem_context.c | 6 +- drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c | 3 + drivers/gpu/drm/i915/gem/i915_gem_object.h | 26 ++++ drivers/gpu/drm/i915/gem/i915_gem_region.c | 12 +- drivers/gpu/drm/i915/gem/i915_gem_stolen.c | 4 +- drivers/gpu/drm/i915/gem/i915_gem_userptr.c | 16 +-- .../drm/i915/gem/selftests/i915_gem_object_blt.c | 4 +- drivers/gpu/drm/i915/gt/debugfs_gt.c | 2 +- drivers/gpu/drm/i915/gt/gen6_ppgtt.h | 4 +- drivers/gpu/drm/i915/gt/gen6_renderstate.c | 20 +-- drivers/gpu/drm/i915/gt/gen7_renderstate.c | 20 +-- drivers/gpu/drm/i915/gt/gen8_ppgtt.c | 13 +- drivers/gpu/drm/i915/gt/gen8_renderstate.c | 20 +-- drivers/gpu/drm/i915/gt/gen9_renderstate.c | 20 +-- drivers/gpu/drm/i915/gt/intel_breadcrumbs.c | 23 +--- drivers/gpu/drm/i915/gt/intel_context.c | 3 +- drivers/gpu/drm/i915/gt/intel_context.h | 3 +- drivers/gpu/drm/i915/gt/intel_context_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_engine_cs.c | 35 +---- drivers/gpu/drm/i915/gt/intel_engine_heartbeat.c | 26 ++-- drivers/gpu/drm/i915/gt/intel_engine_heartbeat.h | 3 +- drivers/gpu/drm/i915/gt/intel_engine_pm.c | 3 +- drivers/gpu/drm/i915/gt/intel_engine_pm.h | 3 +- drivers/gpu/drm/i915/gt/intel_engine_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_engine_user.c | 3 +- drivers/gpu/drm/i915/gt/intel_engine_user.h | 3 +- .../gpu/drm/i915/gt/intel_execlists_submission.c | 97 +++++--------- drivers/gpu/drm/i915/gt/intel_ggtt.c | 26 +++- drivers/gpu/drm/i915/gt/intel_ggtt_fencing.c | 23 +--- drivers/gpu/drm/i915/gt/intel_ggtt_fencing.h | 21 +-- drivers/gpu/drm/i915/gt/intel_gpu_commands.h | 3 +- drivers/gpu/drm/i915/gt/intel_gt.c | 44 ++++++- drivers/gpu/drm/i915/gt/intel_gt.h | 1 + .../gpu/drm/i915/gt/intel_gt_buffer_pool_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_gt_clock_utils.c | 1 - drivers/gpu/drm/i915/gt/intel_gt_irq.c | 3 +- drivers/gpu/drm/i915/gt/intel_gt_irq.h | 3 +- drivers/gpu/drm/i915/gt/intel_gt_pm.c | 3 +- drivers/gpu/drm/i915/gt/intel_gt_pm.h | 3 +- drivers/gpu/drm/i915/gt/intel_gt_pm_irq.c | 3 +- drivers/gpu/drm/i915/gt/intel_gt_pm_irq.h | 3 +- drivers/gpu/drm/i915/gt/intel_gt_requests.c | 3 +- drivers/gpu/drm/i915/gt/intel_gt_requests.h | 3 +- drivers/gpu/drm/i915/gt/intel_gtt.h | 5 + drivers/gpu/drm/i915/gt/intel_llc.c | 3 +- drivers/gpu/drm/i915/gt/intel_llc.h | 3 +- drivers/gpu/drm/i915/gt/intel_llc_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_lrc.c | 6 +- drivers/gpu/drm/i915/gt/intel_lrc_reg.h | 5 +- drivers/gpu/drm/i915/gt/intel_mocs.c | 21 +-- drivers/gpu/drm/i915/gt/intel_mocs.h | 22 +--- drivers/gpu/drm/i915/gt/intel_ppgtt.c | 4 + drivers/gpu/drm/i915/gt/intel_rc6.c | 4 +- drivers/gpu/drm/i915/gt/intel_rc6.h | 3 +- drivers/gpu/drm/i915/gt/intel_rc6_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_region_lmem.c | 97 +++++++++++++- drivers/gpu/drm/i915/gt/intel_region_lmem.h | 6 +- drivers/gpu/drm/i915/gt/intel_renderstate.c | 27 +--- drivers/gpu/drm/i915/gt/intel_renderstate.h | 20 +-- drivers/gpu/drm/i915/gt/intel_reset.c | 18 +-- drivers/gpu/drm/i915/gt/intel_reset.h | 3 +- drivers/gpu/drm/i915/gt/intel_reset_types.h | 2 +- drivers/gpu/drm/i915/gt/intel_ring.c | 8 +- drivers/gpu/drm/i915/gt/intel_ring.h | 4 +- drivers/gpu/drm/i915/gt/intel_ring_submission.c | 146 +++++++++------------ drivers/gpu/drm/i915/gt/intel_ring_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_rps.c | 3 +- drivers/gpu/drm/i915/gt/intel_rps.h | 3 +- drivers/gpu/drm/i915/gt/intel_rps_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_sseu.c | 3 +- drivers/gpu/drm/i915/gt/intel_sseu.h | 3 +- drivers/gpu/drm/i915/gt/intel_timeline.c | 3 +- drivers/gpu/drm/i915/gt/intel_timeline.h | 21 +-- drivers/gpu/drm/i915/gt/intel_timeline_types.h | 3 +- drivers/gpu/drm/i915/gt/intel_workarounds.c | 14 +- drivers/gpu/drm/i915/gt/intel_workarounds.h | 3 +- drivers/gpu/drm/i915/gt/intel_workarounds_types.h | 3 +- drivers/gpu/drm/i915/gt/mock_engine.c | 29 +--- drivers/gpu/drm/i915/gt/mock_engine.h | 21 +-- drivers/gpu/drm/i915/gt/selftest_context.c | 3 +- drivers/gpu/drm/i915/gt/selftest_engine.c | 3 +- drivers/gpu/drm/i915/gt/selftest_engine.h | 3 +- drivers/gpu/drm/i915/gt/selftest_engine_cs.c | 3 +- .../gpu/drm/i915/gt/selftest_engine_heartbeat.c | 17 ++- drivers/gpu/drm/i915/gt/selftest_engine_pm.c | 11 +- drivers/gpu/drm/i915/gt/selftest_execlists.c | 54 +++----- drivers/gpu/drm/i915/gt/selftest_gt_pm.c | 4 +- drivers/gpu/drm/i915/gt/selftest_hangcheck.c | 21 +-- drivers/gpu/drm/i915/gt/selftest_llc.c | 3 +- drivers/gpu/drm/i915/gt/selftest_llc.h | 3 +- drivers/gpu/drm/i915/gt/selftest_lrc.c | 1 - drivers/gpu/drm/i915/gt/selftest_mocs.c | 35 +++-- drivers/gpu/drm/i915/gt/selftest_rc6.c | 3 +- drivers/gpu/drm/i915/gt/selftest_rc6.h | 3 +- drivers/gpu/drm/i915/gt/selftest_timeline.c | 3 +- drivers/gpu/drm/i915/gt/selftest_workarounds.c | 19 ++- drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c | 16 +-- drivers/gpu/drm/i915/i915_buddy.c | 3 + drivers/gpu/drm/i915/i915_buddy.h | 7 +- drivers/gpu/drm/i915/i915_drv.c | 6 +- drivers/gpu/drm/i915/i915_drv.h | 2 +- drivers/gpu/drm/i915/i915_pci.c | 2 +- drivers/gpu/drm/i915/i915_priolist_types.h | 11 +- drivers/gpu/drm/i915/i915_reg.h | 2 + drivers/gpu/drm/i915/i915_request.c | 9 +- drivers/gpu/drm/i915/i915_request.h | 2 +- drivers/gpu/drm/i915/i915_scheduler.c | 52 +------- drivers/gpu/drm/i915/i915_scheduler.h | 16 +-- drivers/gpu/drm/i915/intel_device_info.c | 2 +- drivers/gpu/drm/i915/intel_device_info.h | 3 +- drivers/gpu/drm/i915/intel_memory_region.c | 54 +++++--- drivers/gpu/drm/i915/intel_memory_region.h | 22 ++-- drivers/gpu/drm/i915/selftests/i915_buddy.c | 48 +++++++ .../gpu/drm/i915/selftests/intel_memory_region.c | 77 +++++++++++ 115 files changed, 735 insertions(+), 844 deletions(-)