瀏覽代碼

drm/i915: Set framebuffer alignment based upon the fence constraints.

Set the request alignment to 0, and leave it up to i915_gem_object_pin()
to set the appropriate alignment to match the fence covering the object.

Eric Anholt mentioned that the pinning code is meant to choose the
maximum of the request alignment and that of the fence covering the
object... However currently, the pinning code will only apply the fence
constraints if the supplied alignment is 0.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Chris Wilson 16 年之前
父節點
當前提交
2ebed176a7
共有 1 個文件被更改,包括 2 次插入4 次删除
  1. 2 4
      drivers/gpu/drm/i915/intel_display.c

+ 2 - 4
drivers/gpu/drm/i915/intel_display.c

@@ -377,10 +377,8 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
 		alignment = 64 * 1024;
 		alignment = 64 * 1024;
 		break;
 		break;
 	case I915_TILING_X:
 	case I915_TILING_X:
-		if (IS_I9XX(dev))
-			alignment = 1024 * 1024;
-		else
-			alignment = 512 * 1024;
+		/* pin() will align the object as required by fence */
+		alignment = 0;
 		break;
 		break;
 	case I915_TILING_Y:
 	case I915_TILING_Y:
 		/* FIXME: Is this true? */
 		/* FIXME: Is this true? */