提交 90f9a336 编写于 作者: V Ville Syrjälä 提交者: Daniel Vetter

drm/i915: Check the framebuffer offset

The current code can't deal with framebuffers with an offset. Return an
error when trying to create such a framebuffer until the rest of the
code is fixed to handle them.
Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
上级 5d7bd705
...@@ -8393,6 +8393,10 @@ int intel_framebuffer_init(struct drm_device *dev, ...@@ -8393,6 +8393,10 @@ int intel_framebuffer_init(struct drm_device *dev,
return -EINVAL; return -EINVAL;
} }
/* FIXME need to adjust LINOFF/TILEOFF accordingly. */
if (mode_cmd->offsets[0] != 0)
return -EINVAL;
ret = drm_framebuffer_init(dev, &intel_fb->base, &intel_fb_funcs); ret = drm_framebuffer_init(dev, &intel_fb->base, &intel_fb_funcs);
if (ret) { if (ret) {
DRM_ERROR("framebuffer init failed %d\n", ret); DRM_ERROR("framebuffer init failed %d\n", ret);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册