From: "Jouni Högander" <jouni.hogander@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: "Jouni Högander" <jouni.hogander@intel.com>
Subject: [Intel-xe] [PATCH v2 05/11] drm/xe: Add frontbuffer setter/getter for xe_bo
Date: Fri, 8 Sep 2023 15:24:09 +0300 [thread overview]
Message-ID: <20230908122415.1886366-6-jouni.hogander@intel.com> (raw)
In-Reply-To: <20230908122415.1886366-1-jouni.hogander@intel.com>
Xe is not carrying frontbuffer pointer in xe_bo. Define it's getter as
NULL. Setter simply returns pointer which was provided as a
parameter and taking/releasing reference to xe_bo.
v2: Handle xe_bo_put as well
Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
---
drivers/gpu/drm/xe/xe_bo.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/drivers/gpu/drm/xe/xe_bo.h b/drivers/gpu/drm/xe/xe_bo.h
index 0823dda0f31b..148b097dd2f8 100644
--- a/drivers/gpu/drm/xe/xe_bo.h
+++ b/drivers/gpu/drm/xe/xe_bo.h
@@ -325,6 +325,16 @@ static inline unsigned int xe_sg_segment_size(struct device *dev)
return round_down(max / 2, PAGE_SIZE);
}
+#define i915_gem_object_get_frontbuffer(obj) NULL
+
+static inline struct intel_frontbuffer *
+i915_gem_object_set_frontbuffer(struct xe_bo *bo,
+ struct intel_frontbuffer *front)
+{
+ front ? xe_bo_get(bo) : xe_bo_put(bo);
+ return front;
+}
+
#if IS_ENABLED(CONFIG_DRM_XE_KUNIT_TEST)
/**
* xe_bo_is_mem_type - Whether the bo currently resides in the given
--
2.34.1
next prev parent reply other threads:[~2023-09-08 12:24 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-08 12:24 [Intel-xe] [PATCH v2 00/11] Frontbuffer tracking refactoring Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 01/11] drm/i915/display: Move releasing gem object away from fb tacking Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 02/11] fixup! drm/i915/display: Remaining changes to make xe compile Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 03/11] drm/xe: Add macro to get i915 device from xe_bo Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 04/11] fixup! drm/i915/display: Remaining changes to make xe compile Jouni Högander
2023-09-08 12:24 ` Jouni Högander [this message]
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 06/11] " Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 07/11] drm/xe: Add i915_active.h compatibility header Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 08/11] drm/xe/display: Include i916_active header Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 09/11] drm/xe: Add struct i915_active for Xe Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 10/11] fixup! drm/i915/display: Remaining changes to make xe compile Jouni Högander
2023-09-08 12:24 ` [Intel-xe] [PATCH v2 11/11] drm/xe: Add empty define for i915_ggtt_clear_scanout Jouni Högander
2023-09-08 12:27 ` [Intel-xe] ✓ CI.Patch_applied: success for Frontbuffer tracking refactoring (rev7) Patchwork
2023-09-08 12:27 ` [Intel-xe] ✗ CI.checkpatch: warning " Patchwork
2023-09-08 12:28 ` [Intel-xe] ✓ CI.KUnit: success " Patchwork
2023-09-08 12:35 ` [Intel-xe] ✓ CI.Build: " Patchwork
2023-09-08 12:36 ` [Intel-xe] ✓ CI.Hooks: " Patchwork
2023-09-08 12:37 ` [Intel-xe] ✗ CI.checksparse: warning " Patchwork
2023-09-08 13:26 ` [Intel-xe] ✓ CI.BAT: success " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230908122415.1886366-6-jouni.hogander@intel.com \
--to=jouni.hogander@intel.com \
--cc=intel-xe@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox