Commit b5626747 authored by Jesse Barnes's avatar Jesse Barnes Committed by Keith Packard

drm/i915: check for supported depth at fb init time

This will catch bad fb configs earlier.
Signed-off-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: default avatarKeith Packard <keithp@keithp.com>
parent 46e48456
...@@ -7061,6 +7061,11 @@ int intel_framebuffer_init(struct drm_device *dev, ...@@ -7061,6 +7061,11 @@ int intel_framebuffer_init(struct drm_device *dev,
switch (mode_cmd->bpp) { switch (mode_cmd->bpp) {
case 8: case 8:
case 16: case 16:
/* Only pre-ILK can handle 5:5:5 */
if (mode_cmd->depth == 15 && !HAS_PCH_SPLIT(dev))
return -EINVAL;
break;
case 24: case 24:
case 32: case 32:
break; break;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment