From: Ville Syrjala <ville.syrjala@linux.intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: intel-xe@lists.freedesktop.org
Subject: [PATCH 2/4] drm/i915/fbdev: Select linear modifier explicitly
Date: Thu, 2 Oct 2025 14:54:32 +0300 [thread overview]
Message-ID: <20251002115434.6486-3-ville.syrjala@linux.intel.com> (raw)
In-Reply-To: <20251002115434.6486-1-ville.syrjala@linux.intel.com>
From: Ville Syrjälä <ville.syrjala@linux.intel.com>
Currently we use the implicit modifier fb creation path for fbdev,
but as we never call set_tiling on the bo it will always end up as
linear anyway. The rest of the code (eg. stride alignment) also
assumes that we'll use linear. Just select the linear modifier
explicitly.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
drivers/gpu/drm/i915/display/intel_fbdev.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/gpu/drm/i915/display/intel_fbdev.c b/drivers/gpu/drm/i915/display/intel_fbdev.c
index 3fbdf75415cc..51d3d87caf43 100644
--- a/drivers/gpu/drm/i915/display/intel_fbdev.c
+++ b/drivers/gpu/drm/i915/display/intel_fbdev.c
@@ -214,12 +214,14 @@ static void intel_fbdev_fill_mode_cmd(struct drm_fb_helper_surface_size *sizes,
if (sizes->surface_bpp == 24)
sizes->surface_bpp = 32;
+ mode_cmd->flags = DRM_MODE_FB_MODIFIERS;
mode_cmd->width = sizes->surface_width;
mode_cmd->height = sizes->surface_height;
mode_cmd->pitches[0] = ALIGN(mode_cmd->width * DIV_ROUND_UP(sizes->surface_bpp, 8), 64);
mode_cmd->pixel_format = drm_mode_legacy_fb_format(sizes->surface_bpp,
sizes->surface_depth);
+ mode_cmd->modifier[0] = DRM_FORMAT_MOD_LINEAR;
}
static struct intel_framebuffer *
--
2.49.1
next prev parent reply other threads:[~2025-10-02 11:54 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-02 11:54 [PATCH 0/4] drm/i915: fb fixes and claenups Ville Syrjala
2025-10-02 11:54 ` [PATCH 1/4] drm/i915/fb: Fix the set_tiling vs. addfb race, again Ville Syrjala
2025-10-02 13:59 ` Jani Nikula
2025-10-02 16:41 ` Ville Syrjälä
2025-10-02 16:44 ` [PATCH v2 " Ville Syrjala
2025-10-02 11:54 ` Ville Syrjala [this message]
2025-10-02 14:25 ` [PATCH 2/4] drm/i915/fbdev: Select linear modifier explicitly Jani Nikula
2025-10-02 11:54 ` [PATCH 3/4] drm/i915/fb: Drop the 'fb' argument from intel_fb_bo_framebuffer_init() Ville Syrjala
2025-10-02 14:27 ` Jani Nikula
2025-10-02 11:54 ` [PATCH 4/4] drm/i915/wm: Use fb->modfier to check for tiled vs. untiled Ville Syrjala
2025-10-02 15:05 ` Jani Nikula
2025-10-02 15:41 ` ✓ i915.CI.BAT: success for drm/i915: fb fixes and claenups Patchwork
2025-10-02 18:53 ` ✓ i915.CI.BAT: success for drm/i915: fb fixes and claenups (rev2) Patchwork
2025-10-03 10:49 ` ✓ i915.CI.Full: " 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=20251002115434.6486-3-ville.syrjala@linux.intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--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