@@ -13447,7 +13447,7 @@ intel_primary_plane_create(struct drm_i915_private *dev_priv, enum pipe pipe)
unsigned int supported_rotations;
unsigned int num_formats;
const uint64_t *modifiers;
- int ret;
+ int ret, zpos;
primary = kzalloc(sizeof(*primary), GFP_KERNEL);
if (!primary) {
@@ -13591,6 +13591,9 @@ intel_primary_plane_create(struct drm_i915_private *dev_priv, enum pipe pipe)
DRM_COLOR_YCBCR_BT709,
DRM_COLOR_YCBCR_LIMITED_RANGE);
+ zpos = 0;
+ drm_plane_create_zpos_immutable_property(&primary->base, zpos);
+
drm_plane_helper_add(&primary->base, &intel_plane_helper_funcs);
return primary;
@@ -13608,7 +13611,7 @@ intel_cursor_plane_create(struct drm_i915_private *dev_priv,
{
struct intel_plane *cursor = NULL;
struct intel_plane_state *state = NULL;
- int ret;
+ int ret, zpos;
cursor = kzalloc(sizeof(*cursor), GFP_KERNEL);
if (!cursor) {
@@ -13665,6 +13668,9 @@ intel_cursor_plane_create(struct drm_i915_private *dev_priv,
DRM_MODE_ROTATE_0 |
DRM_MODE_ROTATE_180);
+ zpos = INTEL_INFO(dev_priv)->num_sprites[pipe] + 1;
+ drm_plane_create_zpos_immutable_property(&cursor->base, zpos);
+
if (INTEL_GEN(dev_priv) >= 9)
state->scaler_id = -1;
@@ -1421,7 +1421,7 @@ intel_sprite_plane_create(struct drm_i915_private *dev_priv,
const uint64_t *modifiers;
unsigned int supported_rotations;
int num_plane_formats;
- int ret;
+ int ret, zpos;
intel_plane = kzalloc(sizeof(*intel_plane), GFP_KERNEL);
if (!intel_plane) {
@@ -1552,6 +1552,9 @@ intel_sprite_plane_create(struct drm_i915_private *dev_priv,
DRM_COLOR_YCBCR_BT709,
DRM_COLOR_YCBCR_LIMITED_RANGE);
+ zpos = plane + 1;
+ drm_plane_create_zpos_immutable_property(&intel_plane->base, zpos);
+
drm_plane_helper_add(&intel_plane->base, &intel_plane_helper_funcs);
return intel_plane;