[Intel-gfx] [PATCH] drm/i915: Allow legacy interface for legacy Y tiled display
Tvrtko Ursulin
tvrtko.ursulin at linux.intel.com
Wed Apr 1 02:53:45 PDT 2015
From: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
Makes it easier for userspace to start supporting Y tiled display,
for at least the legacy format.
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
Cc: Chris Wilson <chris at chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter at ffwll.ch>
---
drivers/gpu/drm/i915/intel_display.c | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 1813190..de50631 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -13347,10 +13347,19 @@ static int intel_framebuffer_init(struct drm_device *dev,
return -EINVAL;
}
} else {
- if (obj->tiling_mode == I915_TILING_X)
+ switch (obj->tiling_mode) {
+ case I915_TILING_NONE:
+ mode_cmd->modifier[0] = DRM_FORMAT_MOD_NONE;
+ break;
+ case I915_TILING_X:
mode_cmd->modifier[0] = I915_FORMAT_MOD_X_TILED;
- else if (obj->tiling_mode == I915_TILING_Y) {
- DRM_DEBUG("No Y tiling for legacy addfb\n");
+ break;
+ case I915_TILING_Y:
+ mode_cmd->modifier[0] = I915_FORMAT_MOD_Y_TILED;
+ break;
+ default:
+ DRM_DEBUG("Unsupported fb obj tiling %u!\n",
+ obj->tiling_mode);
return -EINVAL;
}
}
--
2.3.2
More information about the Intel-gfx
mailing list