From patchwork Wed May 29 17:48:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679330 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 5580EC41513 for ; Wed, 29 May 2024 17:48:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0DF6910E2E2; Wed, 29 May 2024 17:48:13 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="RDoK4TAZ"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8913310E2E2; Wed, 29 May 2024 17:48:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004888; x=1748540888; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Wh5bqMYOSQTd24YAhd01N78CGIlD6Jkz+TYmkw/wD/c=; b=RDoK4TAZfCdFM9p4p5NaG7tKrib2pAHkOSY+Vnex96LjpRQR1rJwIJOX f8KRgV/dQGV9GdsXt3owkKaynYeSdWJw9te45dOR7nYenZzLyFURWVS12 mNdWue67XYyWCix1VYPEY7cThEIw5geQZherqw8rxCB55slG0H4vuZrYW tzX735T5VspdLGjBZdv4erL4tg1KU1xHc0gGWDBOmJ4+akZxZi2LE90Jr RO09LlomejcI48c+9dz8EuENb2Ql3YBhSpxkbdNLw7NW0mJOqGX9nop2z XavRKCMi5gw4Muy9QZ0+Xx+YHLR8mLOJeyUHJEBPlz2OA4crWdKNdfetF w==; X-CSE-ConnectionGUID: 5GgNvNcwQHazM0kL6seW/w== X-CSE-MsgGUID: 9BwNMLDHTDujiQqH6cCIMA== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="24082644" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="24082644" Received: from fmviesa007.fm.intel.com ([10.60.135.147]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:08 -0700 X-CSE-ConnectionGUID: cDRzz0VlTHu1rVdnFERH7w== X-CSE-MsgGUID: /yZ2ZWlDQHWZ0Cee3Zwhag== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="35452773" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by fmviesa007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:06 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 01/10] drm/i915/display: include gem/i915_gem_stolen.h where needed Date: Wed, 29 May 2024 20:48:05 +0300 Message-Id: <6ac3480a8689fda5aaf4007cb604e06e939a03f7.1717004739.git.jani.nikula@intel.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. We need to move the compat i915_gem_stolen.h under gem subdir. With this, we can drop the include from xe compat i915_drv.h. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/i915/display/intel_fbc.c | 1 + .../gpu/drm/xe/compat-i915-headers/{ => gem}/i915_gem_stolen.h | 0 drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 1 - 3 files changed, 1 insertion(+), 1 deletion(-) rename drivers/gpu/drm/xe/compat-i915-headers/{ => gem}/i915_gem_stolen.h (100%) diff --git a/drivers/gpu/drm/i915/display/intel_fbc.c b/drivers/gpu/drm/i915/display/intel_fbc.c index e9189a864f69..6985abeb6102 100644 --- a/drivers/gpu/drm/i915/display/intel_fbc.c +++ b/drivers/gpu/drm/i915/display/intel_fbc.c @@ -43,6 +43,7 @@ #include #include +#include "gem/i915_gem_stolen.h" #include "i915_drv.h" #include "i915_reg.h" #include "i915_utils.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_gem_stolen.h b/drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_stolen.h similarity index 100% rename from drivers/gpu/drm/xe/compat-i915-headers/i915_gem_stolen.h rename to drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_stolen.h diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index cd4632276141..3be3d419530a 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -19,7 +19,6 @@ #include "xe_bo.h" #include "xe_pm.h" #include "xe_step.h" -#include "i915_gem_stolen.h" #include "i915_gpu_error.h" #include "i915_reg_defs.h" #include "i915_utils.h" From patchwork Wed May 29 17:48:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679331 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id CC586C41513 for ; Wed, 29 May 2024 17:48:20 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A569010E1EA; Wed, 29 May 2024 17:48:19 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Rr4+O1Mw"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id CC07710E350; Wed, 29 May 2024 17:48:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004894; x=1748540894; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=DDSD+ifMmZLOI86JIN9ZjQUgvxtvQOkyhhQmI2aCg98=; b=Rr4+O1Mww9iZ+IQUqTDmtxeDDdSgIhx8rrbfyKt5PFUd1d/vyV7ZSLYK PZNnnZ7SMdr0wB9JFhKtES/dAXOwiAupLXA9lfUHeKXngot1Kdytieu82 Z2mpzHJzbOH6X8NjZh8K9mpcPRoyy6cVwystoOL3ivYlDwI0rCP8NWzJ5 GFfEaP7sLvhAEzjb7li6Om9rh/WkQ3c5ah+ICPXl0sZtReDxle0zNivOZ TbZqpXp9ceVkQ6dT0/SgcdRzgAL9Wi6vshOshmpIVE0Zm6jT8LLf65Vgo yx47KTr9QuCvCejGpWwfA+CDS0cvKB5MaTkc9CNyLCPyB0jCPNrqRAuwn g==; X-CSE-ConnectionGUID: hbB+n3F6Q5uCdOk4af9J3w== X-CSE-MsgGUID: oyBFDZEzRQypJNd5Lkw68Q== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="24082648" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="24082648" Received: from fmviesa007.fm.intel.com ([10.60.135.147]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:13 -0700 X-CSE-ConnectionGUID: LxaA6alqSIeydpKxQBpJQg== X-CSE-MsgGUID: HEUta/LpQkexoJmS/wdKvA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="35452778" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by fmviesa007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:11 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 02/10] drm/i915/display: include gt/intel_gt_types.h where needed Date: Wed, 29 May 2024 20:48:06 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. We need to move the compat intel_gt_types.h under gt subdir. With this, we can drop the include from xe compat i915_drv.h. Signed-off-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_fbc.c | 1 + drivers/gpu/drm/xe/compat-i915-headers/{ => gt}/intel_gt_types.h | 0 drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 1 - 3 files changed, 1 insertion(+), 1 deletion(-) rename drivers/gpu/drm/xe/compat-i915-headers/{ => gt}/intel_gt_types.h (100%) diff --git a/drivers/gpu/drm/i915/display/intel_fbc.c b/drivers/gpu/drm/i915/display/intel_fbc.c index 6985abeb6102..8e956e7a1964 100644 --- a/drivers/gpu/drm/i915/display/intel_fbc.c +++ b/drivers/gpu/drm/i915/display/intel_fbc.c @@ -44,6 +44,7 @@ #include #include "gem/i915_gem_stolen.h" +#include "gt/intel_gt_types.h" #include "i915_drv.h" #include "i915_reg.h" #include "i915_utils.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h b/drivers/gpu/drm/xe/compat-i915-headers/gt/intel_gt_types.h similarity index 100% rename from drivers/gpu/drm/xe/compat-i915-headers/intel_gt_types.h rename to drivers/gpu/drm/xe/compat-i915-headers/gt/intel_gt_types.h diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index 3be3d419530a..fb784ab64cd4 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -22,7 +22,6 @@ #include "i915_gpu_error.h" #include "i915_reg_defs.h" #include "i915_utils.h" -#include "intel_gt_types.h" #include "intel_step.h" #include "intel_uncore.h" #include "intel_runtime_pm.h" From patchwork Wed May 29 17:48:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679332 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id B6004C25B75 for ; Wed, 29 May 2024 17:48:25 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B266B10E439; Wed, 29 May 2024 17:48:24 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="RqowZ9Ay"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 17DEE10E350; Wed, 29 May 2024 17:48:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004900; x=1748540900; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=cTci0aj+c1TimvNuGvGl2HiTFkg+fVEuvTXkhxrJX0c=; b=RqowZ9Ay80z97YLIxtP/OIKUJWSGbQB9lqY6quppgMkk5r1V7Apd7zR1 7uJUvWwLvYsbMzpSW0jCxWwYqUR9cAiVW90c/YRO+TRP83tyIci+igrTe td6yvPrb3ziuOe+0CT6g05Rt7MfsFsIDA014JobM7mOiBv8BB4S73k47A Qsy0dFl7VyTwDHuEG2ioKGiGmaN/7sLwquxm8CzNmihKwPG8lly+gpTWD t13TgeJQqSpfQdFBXQ2TEwi/VrIQnRH35BSpTWiKCzVd86LFuUcVZLJzC CkYEV1Y/kqPSiUHE8GyNUil+ilp3gFiyzmV1+MULkWNGYNU4AtxyX1vNa w==; X-CSE-ConnectionGUID: y1PIiWrQSK2XunmjYpVmUg== X-CSE-MsgGUID: khRIYZHOTHWUrAD6TT2/Ug== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="24082660" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="24082660" Received: from fmviesa007.fm.intel.com ([10.60.135.147]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:19 -0700 X-CSE-ConnectionGUID: g59i3B3mTUyBph2RF15aWQ== X-CSE-MsgGUID: uGU2EaMUTNeyaIjJkclMnw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="35452783" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by fmviesa007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:17 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 03/10] drm/i915/display: include i915_gpu_error.h where needed Date: Wed, 29 May 2024 20:48:07 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. With this, we can drop the include from xe compat i915_drv.h. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/i915/display/intel_dmc.c | 1 + drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c index 63fccdda56c0..b5ebb0f5b269 100644 --- a/drivers/gpu/drm/i915/display/intel_dmc.c +++ b/drivers/gpu/drm/i915/display/intel_dmc.c @@ -26,6 +26,7 @@ #include #include "i915_drv.h" +#include "i915_gpu_error.h" #include "i915_reg.h" #include "intel_de.h" #include "intel_dmc.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index fb784ab64cd4..9776cc3332fe 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -19,7 +19,6 @@ #include "xe_bo.h" #include "xe_pm.h" #include "xe_step.h" -#include "i915_gpu_error.h" #include "i915_reg_defs.h" #include "i915_utils.h" #include "intel_step.h" From patchwork Wed May 29 17:48:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679333 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 7A80EC27C44 for ; Wed, 29 May 2024 17:48:30 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 36DB910E343; Wed, 29 May 2024 17:48:29 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Zg8ZOvU6"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1B4E310E4F9; Wed, 29 May 2024 17:48:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004905; x=1748540905; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=iaDtTOiID8vxEuLa0wpfi5/HjnkVZQHaYB0rf3PwIg8=; b=Zg8ZOvU6P7wB+KnPCbDNS+OaWFUmGUdXhfaVL0SHtVbu17wiiCpxjgeZ q4US1g85MEL5X15WEWxU6LOTqeQIU/Tu0jjU5HsJLHuApUA/pGLTH8+G/ vjc1eufpvEx1ChukjPO9FNEaWhziIybA1vREWSCoIS7OL2S133AKjxBXj ByAGJ9x8hpYiezxu3So9aJf46iHzPorD72ywACuqAZBdTYPPoJHusWvve x5OcoZegYQfxOqXdlbWtXmwWmooglqHC2IoaDckvTAh4b7fAZXz2SSZKb ampjjczalaoxnVmJrWpeKmGA1att7g/cpNJ3jM32rny9IHcCpL/cuaT6o A==; X-CSE-ConnectionGUID: 3mdn4LSsRAOZAgcn6yLvCQ== X-CSE-MsgGUID: +Huf7R1sTm6Ww/L61ogBKQ== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="24082663" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="24082663" Received: from fmviesa007.fm.intel.com ([10.60.135.147]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:25 -0700 X-CSE-ConnectionGUID: xwnnuAYXRVSJ23GjdHBqFw== X-CSE-MsgGUID: whpgthR3TJm4ErKMoS0Z3g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="35452790" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by fmviesa007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:22 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 04/10] drm/i915/display: include intel_uncore.h where needed Date: Wed, 29 May 2024 20:48:08 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. With this, we can drop the include from xe compat i915_drv.h. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/i915/display/intel_bios.c | 1 + drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_bios.c b/drivers/gpu/drm/i915/display/intel_bios.c index b0a49b2f957f..e53a789e3170 100644 --- a/drivers/gpu/drm/i915/display/intel_bios.c +++ b/drivers/gpu/drm/i915/display/intel_bios.c @@ -36,6 +36,7 @@ #include "intel_display.h" #include "intel_display_types.h" #include "intel_gmbus.h" +#include "intel_uncore.h" #define _INTEL_BIOS_PRIVATE #include "intel_vbt_defs.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index 9776cc3332fe..e5966f07a924 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -22,7 +22,6 @@ #include "i915_reg_defs.h" #include "i915_utils.h" #include "intel_step.h" -#include "intel_uncore.h" #include "intel_runtime_pm.h" #include From patchwork Wed May 29 17:48:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679338 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id E28C8C27C44 for ; Wed, 29 May 2024 17:48:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E6FBC10E52D; Wed, 29 May 2024 17:48:56 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="TjahsMpt"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 50B8010E350; Wed, 29 May 2024 17:48:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004910; x=1748540910; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=XnsDVQY4LWcJFZGLTI6/D7A6A4roVSb7NCajoegtaqA=; b=TjahsMptOkXZk2hMBfwzbm+wPUwHBncM7v3b2sugTVqmOYjJ0/QwfG3J RlaZCvVlYzwB4FdC+4gcYCK7RVj9gaQk7G6v/oU0uTsxyTdbzHQm3KsAV jOKmwLhdKvKZ0L2beSyrVfCugORqFv4fggzYMGL52QTmwoORAMuv+2QTo hhzmSof9NUXR17YYQio4TC+Bh/5MXDsxhgS41HtpA5kxQFOzDpVv7L6fZ 5rgW73MsIv/RZaqM+J9obww4uosmkeUMgiK35i73nYY7Ncop4CsZ7fQBe evGQpOSzAhIEqKGb6pWfrBv5roDAfAa0iri6J2Zu68b/98UMv1wTNgmFM A==; X-CSE-ConnectionGUID: ul2Ixb9XTSC9aIO6m0AL3Q== X-CSE-MsgGUID: AZB6M949Qu+UDRyGz4ViBg== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="24082667" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="24082667" Received: from fmviesa007.fm.intel.com ([10.60.135.147]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:30 -0700 X-CSE-ConnectionGUID: x1XhajggQuKAM924XHsFgQ== X-CSE-MsgGUID: 6KuaI5hZSdSOqwVYMNpjdg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="35452796" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by fmviesa007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:28 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 05/10] drm/i915/display: include intel_step.h where needed Date: Wed, 29 May 2024 20:48:09 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. With this, we can drop the include along with xe_step.h from xe compat i915_drv.h. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/i915/display/intel_dmc.c | 1 + drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c index b5ebb0f5b269..852c11aa3205 100644 --- a/drivers/gpu/drm/i915/display/intel_dmc.c +++ b/drivers/gpu/drm/i915/display/intel_dmc.c @@ -31,6 +31,7 @@ #include "intel_de.h" #include "intel_dmc.h" #include "intel_dmc_regs.h" +#include "intel_step.h" /** * DOC: DMC Firmware Support diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index e5966f07a924..3e930ce25c90 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -18,10 +18,8 @@ #include "xe_device.h" #include "xe_bo.h" #include "xe_pm.h" -#include "xe_step.h" #include "i915_reg_defs.h" #include "i915_utils.h" -#include "intel_step.h" #include "intel_runtime_pm.h" #include From patchwork Wed May 29 17:48:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679334 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 34051C25B7C for ; Wed, 29 May 2024 17:48:50 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8D5B210E82E; Wed, 29 May 2024 17:48:47 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="TOCQ25YR"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id 896E010E52D; Wed, 29 May 2024 17:48:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004917; x=1748540917; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=FH7XHQl4ZANo7/L3rdIUmSTdLa95XHqcLFevEG0i8IY=; b=TOCQ25YRUvEdBAV6zeMBsboKnGrATU+2bk81DkdR/Z2dUwC6HARQPU5U 4Mn7C7HPFDSk2HvE+IL5wP+b6Y9o8xpuRHUAZrfzQ7oHvVgW2UpXlqOt4 7/OfNwl8vETrusZEp2EziPUQhehmkN/QgQG0ekawn4DySsO/5Cd6CGCGe 9d1jkeB4e2PaPWpN+tV8arwdZJyP77yQh+PtQPeyItDggaL5MuiylN0BI Ja5Rjh0Wv8pYf00YivwNcLLUF9ppQmvFOffGsy652IgIYptyEXa2dTh8S yFbZku/Jr2Omx9FiwiHZLgWgvd0ULTtI0hOvgm3b3IPywa2WEi81lDhDA g==; X-CSE-ConnectionGUID: NbasqaZNTEKn7n4k27zIDw== X-CSE-MsgGUID: Fpc3dTEYRkGDn+toDTVgkQ== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="16378353" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="16378353" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:36 -0700 X-CSE-ConnectionGUID: mb+ZyLLQTPmB31w2tMNlSg== X-CSE-MsgGUID: +idQV3etSaanq07Keb3hxw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="66393584" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:34 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 06/10] drm/i915/display: include xe_bo.h, gem_object_types etc. where needed Date: Wed, 29 May 2024 20:48:10 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Include what you use. The dependencies on the headers, and what they include, is a bit convoluted. Add xe compat gem/gem_object_types.h. Fix all the places needed. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/i915/display/intel_atomic_plane.c | 1 + drivers/gpu/drm/i915/display/intel_display_types.h | 1 + drivers/gpu/drm/i915/display/intel_fb.c | 1 + drivers/gpu/drm/i915/display/intel_fbdev.c | 1 + .../compat-i915-headers/gem/i915_gem_object_types.h | 11 +++++++++++ drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 4 ---- drivers/gpu/drm/xe/display/intel_fb_bo.c | 2 ++ drivers/gpu/drm/xe/display/intel_fbdev_fb.c | 9 ++++----- drivers/gpu/drm/xe/display/xe_fb_pin.c | 5 +++-- drivers/gpu/drm/xe/display/xe_plane_initial.c | 1 + 10 files changed, 25 insertions(+), 11 deletions(-) create mode 100644 drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_object_types.h diff --git a/drivers/gpu/drm/i915/display/intel_atomic_plane.c b/drivers/gpu/drm/i915/display/intel_atomic_plane.c index a2a827070c33..1143ba5b4f7c 100644 --- a/drivers/gpu/drm/i915/display/intel_atomic_plane.c +++ b/drivers/gpu/drm/i915/display/intel_atomic_plane.c @@ -32,6 +32,7 @@ */ #include +#include #include #include diff --git a/drivers/gpu/drm/i915/display/intel_display_types.h b/drivers/gpu/drm/i915/display/intel_display_types.h index 6fbfe8a18f45..4de86e299c91 100644 --- a/drivers/gpu/drm/i915/display/intel_display_types.h +++ b/drivers/gpu/drm/i915/display/intel_display_types.h @@ -47,6 +47,7 @@ #include #include +#include "gem/i915_gem_object_types.h" /* for to_intel_bo() */ #include "i915_vma.h" #include "i915_vma_types.h" #include "intel_bios.h" diff --git a/drivers/gpu/drm/i915/display/intel_fb.c b/drivers/gpu/drm/i915/display/intel_fb.c index b6638726949d..8069abf91c5e 100644 --- a/drivers/gpu/drm/i915/display/intel_fb.c +++ b/drivers/gpu/drm/i915/display/intel_fb.c @@ -9,6 +9,7 @@ #include #include +#include "gem/i915_gem_object.h" #include "i915_drv.h" #include "intel_display.h" #include "intel_display_types.h" diff --git a/drivers/gpu/drm/i915/display/intel_fbdev.c b/drivers/gpu/drm/i915/display/intel_fbdev.c index 5ad0b4c8a0fd..37ae176bfeb0 100644 --- a/drivers/gpu/drm/i915/display/intel_fbdev.c +++ b/drivers/gpu/drm/i915/display/intel_fbdev.c @@ -44,6 +44,7 @@ #include #include "gem/i915_gem_mman.h" +#include "gem/i915_gem_object.h" #include "i915_drv.h" #include "intel_display_types.h" diff --git a/drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_object_types.h b/drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_object_types.h new file mode 100644 index 000000000000..7d6bb1abab73 --- /dev/null +++ b/drivers/gpu/drm/xe/compat-i915-headers/gem/i915_gem_object_types.h @@ -0,0 +1,11 @@ +/* SPDX-License-Identifier: MIT */ +/* Copyright © 2024 Intel Corporation */ + +#ifndef __I915_GEM_OBJECT_TYPES_H__ +#define __I915_GEM_OBJECT_TYPES_H__ + +#include "xe_bo.h" + +#define to_intel_bo(x) gem_to_xe_bo((x)) + +#endif diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index 3e930ce25c90..7b3f53427b03 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -12,11 +12,8 @@ #include -#include "gem/i915_gem_object.h" - #include "soc/intel_pch.h" #include "xe_device.h" -#include "xe_bo.h" #include "xe_pm.h" #include "i915_reg_defs.h" #include "i915_utils.h" @@ -113,7 +110,6 @@ static inline struct drm_i915_private *kdev_to_i915(struct device *kdev) #define IS_RAPTORLAKE_U(xe) ((xe)->info.subplatform == XE_SUBPLATFORM_ALDERLAKE_P_RPLU) #define IS_ICL_WITH_PORT_F(xe) (xe && 0) #define HAS_FLAT_CCS(xe) (xe_device_has_flat_ccs(xe)) -#define to_intel_bo(x) gem_to_xe_bo((x)) #define HAS_128_BYTE_Y_TILING(xe) (xe || 1) diff --git a/drivers/gpu/drm/xe/display/intel_fb_bo.c b/drivers/gpu/drm/xe/display/intel_fb_bo.c index e18521acc516..b89cda053d2c 100644 --- a/drivers/gpu/drm/xe/display/intel_fb_bo.c +++ b/drivers/gpu/drm/xe/display/intel_fb_bo.c @@ -4,10 +4,12 @@ */ #include +#include #include "i915_drv.h" #include "intel_display_types.h" #include "intel_fb_bo.h" +#include "xe_bo.h" void intel_fb_bo_framebuffer_fini(struct xe_bo *bo) { diff --git a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c index f6bf5896ff1b..5ecc7d467934 100644 --- a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c +++ b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c @@ -3,15 +3,14 @@ * Copyright © 2023 Intel Corporation */ -#include "intel_fbdev_fb.h" - #include -#include "xe_gt.h" -#include "xe_ttm_stolen_mgr.h" - #include "i915_drv.h" #include "intel_display_types.h" +#include "intel_fbdev_fb.h" +#include "xe_bo.h" +#include "xe_gt.h" +#include "xe_ttm_stolen_mgr.h" struct intel_framebuffer *intel_fbdev_fb_alloc(struct drm_fb_helper *helper, struct drm_fb_helper_surface_size *sizes) diff --git a/drivers/gpu/drm/xe/display/xe_fb_pin.c b/drivers/gpu/drm/xe/display/xe_fb_pin.c index 36e15c4961c1..0449cdb892f3 100644 --- a/drivers/gpu/drm/xe/display/xe_fb_pin.c +++ b/drivers/gpu/drm/xe/display/xe_fb_pin.c @@ -3,17 +3,18 @@ * Copyright © 2021 Intel Corporation */ +#include + #include "i915_drv.h" #include "intel_display_types.h" #include "intel_dpt.h" #include "intel_fb.h" #include "intel_fb_pin.h" +#include "xe_bo.h" #include "xe_ggtt.h" #include "xe_gt.h" #include "xe_pm.h" -#include - static void write_dpt_rotated(struct xe_bo *bo, struct iosys_map *map, u32 *dpt_ofs, u32 bo_ofs, u32 width, u32 height, u32 src_stride, u32 dst_stride) diff --git a/drivers/gpu/drm/xe/display/xe_plane_initial.c b/drivers/gpu/drm/xe/display/xe_plane_initial.c index 9eaa29e733e1..7672a0cffbd8 100644 --- a/drivers/gpu/drm/xe/display/xe_plane_initial.c +++ b/drivers/gpu/drm/xe/display/xe_plane_initial.c @@ -18,6 +18,7 @@ #include "intel_fb_pin.h" #include "intel_frontbuffer.h" #include "intel_plane_initial.h" +#include "xe_bo.h" static bool intel_reuse_initial_plane_obj(struct intel_crtc *this, From patchwork Wed May 29 17:48:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679335 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id B679EC27C4F for ; Wed, 29 May 2024 17:48:51 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E823010E908; Wed, 29 May 2024 17:48:50 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ItHTPM7n"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id 82A5010EB1B; Wed, 29 May 2024 17:48:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004926; x=1748540926; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ewOoJnvJnkhDip+vSimxwIBShryZRRNAivMXn+UU0Xg=; b=ItHTPM7nSF8I5fIc6hnkkgX9zlquF+fBe3+mUTo1beopegaulr3teF+P atc1Y1z1/arnwERhV9ZStPRqFs9NFGN6Yd9ykHdkZhVTO742OO6qfdUgh fA/6/9NOEk5Y6oq9LdmA87cDaPq4t9l4zedwUx9elptDfVstbZIRJ6FHI rlEVmksQm/vQ7RJ6EkF8e/XwDQPt5zaj1kj/WmwfFtFu8tgE8ERuEoU/d Iz/Ee7l4VOffRg7AI4dZEP6bYkITSfJlDm5u5py/NyuPljjR7FpUjRetm F3FEGKhEoLpqEPtvBSNPJZK3IlDIc/A88zkg3CUZtXpMAg3YRmdltG4nF w==; X-CSE-ConnectionGUID: SEobJj7CRNiMi2ikzMpV1A== X-CSE-MsgGUID: ArdP8SPlTGGasMt9vcfvEg== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="16378385" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="16378385" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:42 -0700 X-CSE-ConnectionGUID: pCnna5s6RuiPDneipHemuA== X-CSE-MsgGUID: p2yOsjvPQpqI+fflFHloLw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="66393613" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:39 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 07/10] drm/xe/display: move compat uncore stubs to the correct file Date: Wed, 29 May 2024 20:48:11 +0300 Message-Id: <3f3903c7c5e34aefac0f6d06e433710bc782c97e.1717004739.git.jani.nikula@intel.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Move things that belong to intel_uncore.h to the correct place. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 5 ----- drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h | 5 +++++ 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index 7b3f53427b03..60544633ddf7 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -155,11 +155,6 @@ static inline void intel_runtime_pm_put(struct xe_runtime_pm *pm, intel_wakeref_ #define assert_rpm_wakelock_held(x) do { } while (0) #define assert_rpm_raw_wakeref_held(x) do { } while (0) -#define intel_uncore_forcewake_get(x, y) do { } while (0) -#define intel_uncore_forcewake_put(x, y) do { } while (0) - -#define intel_uncore_arm_unclaimed_mmio_detection(x) do { } while (0) - #define I915_PRIORITY_DISPLAY 0 struct i915_sched_attr { int priority; diff --git a/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h b/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h index ef79793caa72..083c4da2ea41 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/intel_uncore.h @@ -172,4 +172,9 @@ static inline void __iomem *intel_uncore_regs(struct intel_uncore *uncore) #define raw_reg_write(base, reg, value) \ writel(value, base + i915_mmio_reg_offset(reg)) +#define intel_uncore_forcewake_get(x, y) do { } while (0) +#define intel_uncore_forcewake_put(x, y) do { } while (0) + +#define intel_uncore_arm_unclaimed_mmio_detection(x) do { } while (0) + #endif /* __INTEL_UNCORE_H__ */ From patchwork Wed May 29 17:48:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679336 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 85626C25B7C for ; Wed, 29 May 2024 17:48:53 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 28D0110E4F9; Wed, 29 May 2024 17:48:52 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="PCtcEOcx"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id E69C410EAE7; Wed, 29 May 2024 17:48:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004928; x=1748540928; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=2RWnQtIcemRfep1+1UjiO92xyQtrrxFmzFEXOwX0XsQ=; b=PCtcEOcxxHoTCJC9MCspw6gepkdbu/87VupK3EW8WNvu7H1EcgSKVXxH CThlZK8n6q5VN1xZaxbd87wa9NaF68OiuE37LS230JaWnQ74HZw+v+gc4 f0lTttiPwW2rVhXWxQp8C5zD2nP5cYCr93CrGBgevojDMWaEtvvlDd1FQ t8597lfxLujFjUSf5POi03ANhzF9/JyrfTU1mrNqFV5xIDQNpFGKqyPdW +BPEViOzEdlvBNDNKaHuaP+o1Niwp9pADlZiEFyGBEOYDYiNjFv24cVgi u6MbJkl+GPFy5y32JoXGinr/SRkFhUZ9FU8OJfx2kWfMjo4noDJyst26v g==; X-CSE-ConnectionGUID: SqbHrIH1QcS2jOZmbDrqUA== X-CSE-MsgGUID: W0Qxo+iKRXS50nFmW6t8kQ== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="16378428" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="16378428" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:48 -0700 X-CSE-ConnectionGUID: FZ0dgEU7TwaP0dH4lQR2Kw== X-CSE-MsgGUID: CKDB2SGYSlWVfDXdz5eh6w== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="66393637" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:45 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 08/10] drm/xe/display: move compat runtime pm stubs to the correct file Date: Wed, 29 May 2024 20:48:12 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Move things that belong to intel_runtime_pm.h to the correct place. Add missing header guards while at it. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- .../gpu/drm/xe/compat-i915-headers/i915_drv.h | 48 ----------------- .../xe/compat-i915-headers/intel_runtime_pm.h | 51 +++++++++++++++++++ 2 files changed, 51 insertions(+), 48 deletions(-) diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index 60544633ddf7..fb37da4850c5 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -14,11 +14,9 @@ #include "soc/intel_pch.h" #include "xe_device.h" -#include "xe_pm.h" #include "i915_reg_defs.h" #include "i915_utils.h" #include "intel_runtime_pm.h" -#include static inline struct drm_i915_private *to_i915(const struct drm_device *dev) { @@ -113,58 +111,12 @@ static inline struct drm_i915_private *kdev_to_i915(struct device *kdev) #define HAS_128_BYTE_Y_TILING(xe) (xe || 1) -#include "intel_wakeref.h" - -static inline intel_wakeref_t intel_runtime_pm_get(struct xe_runtime_pm *pm) -{ - struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); - - return xe_pm_runtime_resume_and_get(xe); -} - -static inline intel_wakeref_t intel_runtime_pm_get_if_in_use(struct xe_runtime_pm *pm) -{ - struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); - - return xe_pm_runtime_get_if_in_use(xe); -} - -static inline intel_wakeref_t intel_runtime_pm_get_noresume(struct xe_runtime_pm *pm) -{ - struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); - - xe_pm_runtime_get_noresume(xe); - return true; -} - -static inline void intel_runtime_pm_put_unchecked(struct xe_runtime_pm *pm) -{ - struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); - - xe_pm_runtime_put(xe); -} - -static inline void intel_runtime_pm_put(struct xe_runtime_pm *pm, intel_wakeref_t wakeref) -{ - if (wakeref) - intel_runtime_pm_put_unchecked(pm); -} - -#define intel_runtime_pm_get_raw intel_runtime_pm_get -#define intel_runtime_pm_put_raw intel_runtime_pm_put -#define assert_rpm_wakelock_held(x) do { } while (0) -#define assert_rpm_raw_wakeref_held(x) do { } while (0) - #define I915_PRIORITY_DISPLAY 0 struct i915_sched_attr { int priority; }; #define i915_gem_fence_wait_priority(fence, attr) do { (void) attr; } while (0) -#define with_intel_runtime_pm(rpm, wf) \ - for ((wf) = intel_runtime_pm_get(rpm); (wf); \ - intel_runtime_pm_put((rpm), (wf)), (wf) = 0) - #define pdev_to_i915 pdev_to_xe_device #define RUNTIME_INFO(xe) (&(xe)->info.i915_runtime) diff --git a/drivers/gpu/drm/xe/compat-i915-headers/intel_runtime_pm.h b/drivers/gpu/drm/xe/compat-i915-headers/intel_runtime_pm.h index 89da3cc62f39..8c7b315aa8ac 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/intel_runtime_pm.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/intel_runtime_pm.h @@ -3,7 +3,12 @@ * Copyright © 2023 Intel Corporation */ +#ifndef __INTEL_RUNTIME_PM_H__ +#define __INTEL_RUNTIME_PM_H__ + #include "intel_wakeref.h" +#include "xe_device_types.h" +#include "xe_pm.h" #define intel_runtime_pm xe_runtime_pm @@ -14,3 +19,49 @@ static inline void disable_rpm_wakeref_asserts(void *rpm) static inline void enable_rpm_wakeref_asserts(void *rpm) { } + +static inline intel_wakeref_t intel_runtime_pm_get(struct xe_runtime_pm *pm) +{ + struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); + + return xe_pm_runtime_resume_and_get(xe); +} + +static inline intel_wakeref_t intel_runtime_pm_get_if_in_use(struct xe_runtime_pm *pm) +{ + struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); + + return xe_pm_runtime_get_if_in_use(xe); +} + +static inline intel_wakeref_t intel_runtime_pm_get_noresume(struct xe_runtime_pm *pm) +{ + struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); + + xe_pm_runtime_get_noresume(xe); + return true; +} + +static inline void intel_runtime_pm_put_unchecked(struct xe_runtime_pm *pm) +{ + struct xe_device *xe = container_of(pm, struct xe_device, runtime_pm); + + xe_pm_runtime_put(xe); +} + +static inline void intel_runtime_pm_put(struct xe_runtime_pm *pm, intel_wakeref_t wakeref) +{ + if (wakeref) + intel_runtime_pm_put_unchecked(pm); +} + +#define intel_runtime_pm_get_raw intel_runtime_pm_get +#define intel_runtime_pm_put_raw intel_runtime_pm_put +#define assert_rpm_wakelock_held(x) do { } while (0) +#define assert_rpm_raw_wakeref_held(x) do { } while (0) + +#define with_intel_runtime_pm(rpm, wf) \ + for ((wf) = intel_runtime_pm_get(rpm); (wf); \ + intel_runtime_pm_put((rpm), (wf)), (wf) = 0) + +#endif From patchwork Wed May 29 17:48:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679337 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 38535C27C4F for ; Wed, 29 May 2024 17:48:59 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 99EF710ED28; Wed, 29 May 2024 17:48:58 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="D3m5jzZS"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6711010E763; Wed, 29 May 2024 17:48:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004934; x=1748540934; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=U5VZsZxdx3Qoh3v1vmy9Tm997DzVL4NWHqNL2AAUVjg=; b=D3m5jzZS7IYf65P6YrlCDS869rI6Jx47FSCtias/iSuO+CoenXCQs489 PhbZOOSGZVlN7bJIyFRmYz/4BoqCQNpLbxyTr8vvN5NOx8EtE6u0AhRbM Itvfju4a2E6eWAmfgJtVYeNDGEJmt/UDCe6Dfx5svcvrl+YWu50ZZ3yUu eIWGU/66lgiIhUc/E8vHxmPGcQlK0LvfBZvy0b3D7iu8ugtdLD534KJ+K JQbVtXu3hp9murOXzjRMqoEpEcdEtYWaRyPZd+2b4cF5b59blfa1WkCg/ wNvjnuOnNs+1t3Qxku2tQdvBFwTF4zXrSpDozcO+PUP915YC7CuvnFQu3 w==; X-CSE-ConnectionGUID: Ngn7lCNFS2Koa5oIkcWz8w== X-CSE-MsgGUID: JA6VlUwBT5+y5Uv86i95GQ== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="16378465" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="16378465" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:53 -0700 X-CSE-ConnectionGUID: kWjmfy9MQwqDO51Gjy9o3Q== X-CSE-MsgGUID: df27qrnjT/m0i6q5xrnO8A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="66393667" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:51 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 09/10] drm/xe/display: reduce includes in compat i915_drv.h Date: Wed, 29 May 2024 20:48:13 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Remove some unnecessary includes, and replace xe_device.h with the sufficient xe_device_types.h. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h index fb37da4850c5..2feedddf1e40 100644 --- a/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h +++ b/drivers/gpu/drm/xe/compat-i915-headers/i915_drv.h @@ -12,11 +12,9 @@ #include -#include "soc/intel_pch.h" -#include "xe_device.h" -#include "i915_reg_defs.h" #include "i915_utils.h" #include "intel_runtime_pm.h" +#include "xe_device_types.h" static inline struct drm_i915_private *to_i915(const struct drm_device *dev) { From patchwork Wed May 29 17:48:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 13679339 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 3577DC25B75 for ; Wed, 29 May 2024 17:49:03 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 5332410EDA5; Wed, 29 May 2024 17:49:02 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="LV3fZ6KB"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id D4DE710ED5C; Wed, 29 May 2024 17:48:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717004939; x=1748540939; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=NHUJqpnXJzem8AmZTQFUnTECiCkL5bmKCGU7M7ceJQU=; b=LV3fZ6KB8k/RuU6U/Abajge2Z/SFI2gJi3TzcbED97cYOmFqXeSitcKd 64GIjQwEZN4HE+elAYQ52Zmbk45sbS8AILKmNPJxox5/HuAfuUMYEZcfQ SurKoFsWgMjhopbCcmFWEgh1Ck9c8ELq5/YhhWjrUAiYGEhnr1HGOMUlT 7xM4G6669r+qJybDcUpFkrk0F02m3tBWvU5ysAn/vQTlVDR65i48PZcU4 VIFvGaWZ3oO5dE+Cut9l80MaiZTv3h5mZ4e0IU2/0ZBAuEaCozGYEERZo fV/N9XyP61Z6n5vUh8YJK+rbrs5WHEnG/FBIk/8ytgcJvnbrwrIkm2+fp w==; X-CSE-ConnectionGUID: 4cWX05G3RAKpyHDMnu06BA== X-CSE-MsgGUID: XnPyWf/2R8iSlOz6roO7ow== X-IronPort-AV: E=McAfee;i="6600,9927,11087"; a="16378507" X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="16378507" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:59 -0700 X-CSE-ConnectionGUID: xH09zw3hRZ6vjXRRBwExgg== X-CSE-MsgGUID: 9T70vOJ1Q4uLYPZipO/slA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,199,1712646000"; d="scan'208";a="66393687" Received: from ncintean-mobl1.ger.corp.intel.com (HELO localhost) ([10.245.246.86]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 May 2024 10:48:57 -0700 From: Jani Nikula To: intel-gfx@lists.freedesktop.org, intel-xe@lists.freedesktop.org Cc: jani.nikula@intel.com, rodrigo.vivi@intel.com, lucas.demarchi@intel.com Subject: [PATCH 10/10] drm/xe/display: drop i915_drv.h include from xe code Date: Wed, 29 May 2024 20:48:14 +0300 Message-Id: X-Mailer: git-send-email 2.39.2 In-Reply-To: References: MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Drop i915_drv.h include from xe display code as much as possible, and switch to xe types where necessary. Signed-off-by: Jani Nikula Reviewed-by: Rodrigo Vivi --- drivers/gpu/drm/xe/display/ext/i915_irq.c | 1 - drivers/gpu/drm/xe/display/intel_fb_bo.c | 5 ++--- drivers/gpu/drm/xe/display/intel_fbdev_fb.c | 17 ++++++++--------- drivers/gpu/drm/xe/display/xe_dsb_buffer.c | 9 ++++----- drivers/gpu/drm/xe/display/xe_fb_pin.c | 1 - drivers/gpu/drm/xe/display/xe_plane_initial.c | 18 ++++++++---------- 6 files changed, 22 insertions(+), 29 deletions(-) diff --git a/drivers/gpu/drm/xe/display/ext/i915_irq.c b/drivers/gpu/drm/xe/display/ext/i915_irq.c index bee191a4a97d..eb40f1cb44f6 100644 --- a/drivers/gpu/drm/xe/display/ext/i915_irq.c +++ b/drivers/gpu/drm/xe/display/ext/i915_irq.c @@ -3,7 +3,6 @@ * Copyright © 2023 Intel Corporation */ -#include "i915_drv.h" #include "i915_irq.h" #include "i915_reg.h" #include "intel_uncore.h" diff --git a/drivers/gpu/drm/xe/display/intel_fb_bo.c b/drivers/gpu/drm/xe/display/intel_fb_bo.c index b89cda053d2c..f835492f73fb 100644 --- a/drivers/gpu/drm/xe/display/intel_fb_bo.c +++ b/drivers/gpu/drm/xe/display/intel_fb_bo.c @@ -6,7 +6,6 @@ #include #include -#include "i915_drv.h" #include "intel_display_types.h" #include "intel_fb_bo.h" #include "xe_bo.h" @@ -26,7 +25,7 @@ int intel_fb_bo_framebuffer_init(struct intel_framebuffer *intel_fb, struct xe_bo *bo, struct drm_mode_fb_cmd2 *mode_cmd) { - struct drm_i915_private *i915 = to_i915(bo->ttm.base.dev); + struct xe_device *xe = to_xe_device(bo->ttm.base.dev); int ret; xe_bo_get(bo); @@ -42,7 +41,7 @@ int intel_fb_bo_framebuffer_init(struct intel_framebuffer *intel_fb, * mode when the boect is VM_BINDed, so we can only set * coherency with display when unbound. */ - if (XE_IOCTL_DBG(i915, !list_empty(&bo->ttm.base.gpuva.list))) { + if (XE_IOCTL_DBG(xe, !list_empty(&bo->ttm.base.gpuva.list))) { ttm_bo_unreserve(&bo->ttm); ret = -EINVAL; goto err; diff --git a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c index 5ecc7d467934..3a2f3a5ac2f9 100644 --- a/drivers/gpu/drm/xe/display/intel_fbdev_fb.c +++ b/drivers/gpu/drm/xe/display/intel_fbdev_fb.c @@ -5,7 +5,6 @@ #include -#include "i915_drv.h" #include "intel_display_types.h" #include "intel_fbdev_fb.h" #include "xe_bo.h" @@ -17,7 +16,7 @@ struct intel_framebuffer *intel_fbdev_fb_alloc(struct drm_fb_helper *helper, { struct drm_framebuffer *fb; struct drm_device *dev = helper->dev; - struct drm_i915_private *dev_priv = to_i915(dev); + struct xe_device *xe = to_xe_device(dev); struct drm_mode_fb_cmd2 mode_cmd = {}; struct drm_i915_gem_object *obj; int size; @@ -38,26 +37,26 @@ struct intel_framebuffer *intel_fbdev_fb_alloc(struct drm_fb_helper *helper, size = PAGE_ALIGN(size); obj = ERR_PTR(-ENODEV); - if (!IS_DGFX(dev_priv)) { - obj = xe_bo_create_pin_map(dev_priv, xe_device_get_root_tile(dev_priv), + if (!IS_DGFX(xe)) { + obj = xe_bo_create_pin_map(xe, xe_device_get_root_tile(xe), NULL, size, ttm_bo_type_kernel, XE_BO_FLAG_SCANOUT | XE_BO_FLAG_STOLEN | XE_BO_FLAG_PINNED); if (!IS_ERR(obj)) - drm_info(&dev_priv->drm, "Allocated fbdev into stolen\n"); + drm_info(&xe->drm, "Allocated fbdev into stolen\n"); else - drm_info(&dev_priv->drm, "Allocated fbdev into stolen failed: %li\n", PTR_ERR(obj)); + drm_info(&xe->drm, "Allocated fbdev into stolen failed: %li\n", PTR_ERR(obj)); } if (IS_ERR(obj)) { - obj = xe_bo_create_pin_map(dev_priv, xe_device_get_root_tile(dev_priv), NULL, size, + obj = xe_bo_create_pin_map(xe, xe_device_get_root_tile(xe), NULL, size, ttm_bo_type_kernel, XE_BO_FLAG_SCANOUT | - XE_BO_FLAG_VRAM_IF_DGFX(xe_device_get_root_tile(dev_priv)) | + XE_BO_FLAG_VRAM_IF_DGFX(xe_device_get_root_tile(xe)) | XE_BO_FLAG_PINNED); } if (IS_ERR(obj)) { - drm_err(&dev_priv->drm, "failed to allocate framebuffer (%pe)\n", obj); + drm_err(&xe->drm, "failed to allocate framebuffer (%pe)\n", obj); fb = ERR_PTR(-ENOMEM); goto err; } diff --git a/drivers/gpu/drm/xe/display/xe_dsb_buffer.c b/drivers/gpu/drm/xe/display/xe_dsb_buffer.c index 44c9fd2143cc..9e860c61f4b3 100644 --- a/drivers/gpu/drm/xe/display/xe_dsb_buffer.c +++ b/drivers/gpu/drm/xe/display/xe_dsb_buffer.c @@ -3,7 +3,6 @@ * Copyright 2023, Intel Corporation. */ -#include "i915_drv.h" #include "i915_vma.h" #include "intel_display_types.h" #include "intel_dsb_buffer.h" @@ -34,18 +33,18 @@ void intel_dsb_buffer_memset(struct intel_dsb_buffer *dsb_buf, u32 idx, u32 val, bool intel_dsb_buffer_create(struct intel_crtc *crtc, struct intel_dsb_buffer *dsb_buf, size_t size) { - struct drm_i915_private *i915 = to_i915(crtc->base.dev); - struct drm_i915_gem_object *obj; + struct xe_device *xe = to_xe_device(crtc->base.dev); + struct xe_bo *obj; struct i915_vma *vma; vma = kzalloc(sizeof(*vma), GFP_KERNEL); if (!vma) return false; - obj = xe_bo_create_pin_map(i915, xe_device_get_root_tile(i915), + obj = xe_bo_create_pin_map(xe, xe_device_get_root_tile(xe), NULL, PAGE_ALIGN(size), ttm_bo_type_kernel, - XE_BO_FLAG_VRAM_IF_DGFX(xe_device_get_root_tile(i915)) | + XE_BO_FLAG_VRAM_IF_DGFX(xe_device_get_root_tile(xe)) | XE_BO_FLAG_GGTT); if (IS_ERR(obj)) { kfree(vma); diff --git a/drivers/gpu/drm/xe/display/xe_fb_pin.c b/drivers/gpu/drm/xe/display/xe_fb_pin.c index 0449cdb892f3..a2f417209124 100644 --- a/drivers/gpu/drm/xe/display/xe_fb_pin.c +++ b/drivers/gpu/drm/xe/display/xe_fb_pin.c @@ -5,7 +5,6 @@ #include -#include "i915_drv.h" #include "intel_display_types.h" #include "intel_dpt.h" #include "intel_fb.h" diff --git a/drivers/gpu/drm/xe/display/xe_plane_initial.c b/drivers/gpu/drm/xe/display/xe_plane_initial.c index 7672a0cffbd8..e135b20962d9 100644 --- a/drivers/gpu/drm/xe/display/xe_plane_initial.c +++ b/drivers/gpu/drm/xe/display/xe_plane_initial.c @@ -9,7 +9,6 @@ #include "regs/xe_gtt_defs.h" #include "xe_ggtt.h" -#include "i915_drv.h" #include "intel_atomic_plane.h" #include "intel_crtc.h" #include "intel_display.h" @@ -25,10 +24,10 @@ intel_reuse_initial_plane_obj(struct intel_crtc *this, const struct intel_initial_plane_config plane_configs[], struct drm_framebuffer **fb) { - struct drm_i915_private *i915 = to_i915(this->base.dev); + struct xe_device *xe = to_xe_device(this->base.dev); struct intel_crtc *crtc; - for_each_intel_crtc(&i915->drm, crtc) { + for_each_intel_crtc(&xe->drm, crtc) { struct intel_plane *plane = to_intel_plane(crtc->base.primary); const struct intel_plane_state *plane_state = @@ -135,8 +134,7 @@ static bool intel_alloc_initial_plane_obj(struct intel_crtc *crtc, struct intel_initial_plane_config *plane_config) { - struct drm_device *dev = crtc->base.dev; - struct drm_i915_private *dev_priv = to_i915(dev); + struct xe_device *xe = to_xe_device(crtc->base.dev); struct drm_mode_fb_cmd2 mode_cmd = { 0 }; struct drm_framebuffer *fb = &plane_config->fb->base; struct xe_bo *bo; @@ -148,9 +146,9 @@ intel_alloc_initial_plane_obj(struct intel_crtc *crtc, case I915_FORMAT_MOD_4_TILED: break; default: - drm_dbg(&dev_priv->drm, - "Unsupported modifier for initial FB: 0x%llx\n", - fb->modifier); + drm_dbg_kms(&xe->drm, + "Unsupported modifier for initial FB: 0x%llx\n", + fb->modifier); return false; } @@ -161,13 +159,13 @@ intel_alloc_initial_plane_obj(struct intel_crtc *crtc, mode_cmd.modifier[0] = fb->modifier; mode_cmd.flags = DRM_MODE_FB_MODIFIERS; - bo = initial_plane_bo(dev_priv, plane_config); + bo = initial_plane_bo(xe, plane_config); if (!bo) return false; if (intel_framebuffer_init(to_intel_framebuffer(fb), bo, &mode_cmd)) { - drm_dbg_kms(&dev_priv->drm, "intel fb init failed\n"); + drm_dbg_kms(&xe->drm, "intel fb init failed\n"); goto err_bo; } /* Reference handed over to fb */