Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 217902
b: refs/heads/master
c: 57cd650
h: refs/heads/master
v: v3
  • Loading branch information
Chris Wilson committed Sep 8, 2010
1 parent a9133de commit afc06ec
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 763a4a019105dccdcd44883f1712571ae8ea8f1f
refs/heads/master: 57cd6508da65adabcb14be6ba3b9370d750b647d
17 changes: 17 additions & 0 deletions trunk/drivers/gpu/drm/i915/intel_display.c
Original file line number Diff line number Diff line change
Expand Up @@ -5371,8 +5371,25 @@ int intel_framebuffer_init(struct drm_device *dev,
struct drm_mode_fb_cmd *mode_cmd,
struct drm_gem_object *obj)
{
struct drm_i915_gem_object *obj_priv = to_intel_bo(obj);
int ret;

if (obj_priv->tiling_mode == I915_TILING_Y)
return -EINVAL;

if (mode_cmd->pitch & 63)
return -EINVAL;

switch (mode_cmd->bpp) {
case 8:
case 16:
case 24:
case 32:
break;
default:
return -EINVAL;
}

ret = drm_framebuffer_init(dev, &intel_fb->base, &intel_fb_funcs);
if (ret) {
DRM_ERROR("framebuffer init failed %d\n", ret);
Expand Down

0 comments on commit afc06ec

Please sign in to comment.