mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-30 06:06:47 +07:00
drm/i915: Bad pixel formats can't reach the sprite code
The framebuffer pixel format is already checked by the common code. So there's no way an invalid format could reach the driver. So instead of falling back to a default format, call BUG(). Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
parent
2bd3c3cb35
commit
28d491df4c
@ -79,9 +79,7 @@ ivb_update_plane(struct drm_plane *plane, struct drm_framebuffer *fb,
|
|||||||
sprctl |= SPRITE_FORMAT_YUV422 | SPRITE_YUV_ORDER_VYUY;
|
sprctl |= SPRITE_FORMAT_YUV422 | SPRITE_YUV_ORDER_VYUY;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
DRM_DEBUG_DRIVER("bad pixel format, assuming RGBX888\n");
|
BUG();
|
||||||
sprctl |= SPRITE_FORMAT_RGBX888;
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (obj->tiling_mode != I915_TILING_NONE)
|
if (obj->tiling_mode != I915_TILING_NONE)
|
||||||
@ -263,9 +261,7 @@ ilk_update_plane(struct drm_plane *plane, struct drm_framebuffer *fb,
|
|||||||
dvscntr |= DVS_FORMAT_YUV422 | DVS_YUV_ORDER_VYUY;
|
dvscntr |= DVS_FORMAT_YUV422 | DVS_YUV_ORDER_VYUY;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
DRM_DEBUG_DRIVER("bad pixel format, assuming RGBX888\n");
|
BUG();
|
||||||
dvscntr |= DVS_FORMAT_RGBX888;
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (obj->tiling_mode != I915_TILING_NONE)
|
if (obj->tiling_mode != I915_TILING_NONE)
|
||||||
|
Loading…
Reference in New Issue
Block a user