From: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
To: intel-xe@lists.freedesktop.org
Cc: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Subject: [PATCH 2/2] drm/xe/display: limit dpt creation to device where it's used
Date: Tue, 7 May 2024 20:35:40 +0300 [thread overview]
Message-ID: <20240507173540.402185-2-juhapekka.heikkila@gmail.com> (raw)
In-Reply-To: <20240507173540.402185-1-juhapekka.heikkila@gmail.com>
If running on discrete graphics dpt cannot be used from system memory
Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
---
drivers/gpu/drm/xe/display/xe_fb_pin.c | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/xe/display/xe_fb_pin.c b/drivers/gpu/drm/xe/display/xe_fb_pin.c
index bdb0dac5600e..b52eb15c150e 100644
--- a/drivers/gpu/drm/xe/display/xe_fb_pin.c
+++ b/drivers/gpu/drm/xe/display/xe_fb_pin.c
@@ -89,24 +89,26 @@ static int __xe_pin_fb_vma_dpt(struct intel_framebuffer *fb,
plane_count = ARRAY_SIZE(view->rotated.plane);
}
- if (IS_DGFX(xe))
+ if (IS_DGFX(xe)) {
dpt = xe_bo_create_pin_map(xe, tile0, NULL, dpt_size,
ttm_bo_type_kernel,
XE_BO_FLAG_VRAM0 |
XE_BO_FLAG_GGTT |
XE_BO_FLAG_PAGETABLE);
- else
+ } else {
dpt = xe_bo_create_pin_map(xe, tile0, NULL, dpt_size,
ttm_bo_type_kernel,
XE_BO_FLAG_STOLEN |
XE_BO_FLAG_GGTT |
XE_BO_FLAG_PAGETABLE);
- if (IS_ERR(dpt))
- dpt = xe_bo_create_pin_map(xe, tile0, NULL, dpt_size,
- ttm_bo_type_kernel,
- XE_BO_FLAG_SYSTEM |
- XE_BO_FLAG_GGTT |
- XE_BO_FLAG_PAGETABLE);
+ if (IS_ERR(dpt))
+ dpt = xe_bo_create_pin_map(xe, tile0, NULL, dpt_size,
+ ttm_bo_type_kernel,
+ XE_BO_FLAG_SYSTEM |
+ XE_BO_FLAG_GGTT |
+ XE_BO_FLAG_PAGETABLE);
+ }
+
if (IS_ERR(dpt))
return PTR_ERR(dpt);
--
2.43.2
next prev parent reply other threads:[~2024-05-07 17:35 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-07 17:35 [PATCH 1/2] drm/xe/display: Unify DPT mapping Juha-Pekka Heikkila
2024-05-07 17:35 ` Juha-Pekka Heikkila [this message]
2024-05-07 22:46 ` ✓ CI.Patch_applied: success for series starting with [1/2] " Patchwork
2024-05-07 22:46 ` ✓ CI.checkpatch: " Patchwork
2024-05-07 22:47 ` ✓ CI.KUnit: " Patchwork
2024-05-07 23:01 ` ✓ CI.Build: " Patchwork
2024-05-07 23:04 ` ✓ CI.Hooks: " Patchwork
2024-05-07 23:09 ` ✓ CI.checksparse: " Patchwork
2024-05-07 23:32 ` ✗ CI.BAT: failure " Patchwork
2024-05-08 10:06 ` ✗ CI.FULL: " Patchwork
2024-05-10 15:07 ` [PATCH 1/2] " Maarten Lankhorst
2024-05-10 16:01 ` Ville Syrjälä
-- strict thread matches above, loose matches on Subject: below --
2024-04-16 18:14 Juha-Pekka Heikkila
2024-04-16 18:14 ` [PATCH 2/2] drm/xe/display: limit dpt creation to device where it's used Juha-Pekka Heikkila
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=20240507173540.402185-2-juhapekka.heikkila@gmail.com \
--to=juhapekka.heikkila@gmail.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