Merge "sdm: Fix vector initialization."
diff --git a/sdm/libs/core/drm/hw_device_drm.cpp b/sdm/libs/core/drm/hw_device_drm.cpp
index 3ffc9c0..7708c83 100644
--- a/sdm/libs/core/drm/hw_device_drm.cpp
+++ b/sdm/libs/core/drm/hw_device_drm.cpp
@@ -375,11 +375,6 @@
HWRotatorSession *hw_rotator_session = &hw_layers->config[i].hw_rotator_session;
bool needs_rotation = false;
- // TODO(user): Add support for solid fill
- if (layer.flags.solid_fill) {
- continue;
- }
-
for (uint32_t count = 0; count < 2; count++) {
HWPipeInfo *pipe_info = (count == 0) ? left_pipe : right_pipe;
HWRotateInfo *hw_rotate_info = &hw_rotator_session->hw_rotate_info[count];
@@ -389,16 +384,8 @@
needs_rotation = true;
}
- if (pipe_info->valid) {
+ if (pipe_info->valid && input_buffer->fb_id) {
uint32_t pipe_id = pipe_info->pipe_id;
- if (input_buffer->fb_id == 0) {
- // We set these to 0 to clear any previous cycle's state from another buffer.
- // Unfortunately this layer will be skipped from validation because it's dimensions are
- // tied to fb_id which is not available yet.
- drm_atomic_intf_->Perform(DRMOps::PLANE_SET_FB_ID, pipe_id, 0);
- drm_atomic_intf_->Perform(DRMOps::PLANE_SET_CRTC, pipe_id, 0);
- continue;
- }
drm_atomic_intf_->Perform(DRMOps::PLANE_SET_ALPHA, pipe_id, layer.plane_alpha);
drm_atomic_intf_->Perform(DRMOps::PLANE_SET_ZORDER, pipe_id, pipe_info->z_order);
DRMBlendType blending = {};
diff --git a/sdm/libs/hwc/hwc_display.cpp b/sdm/libs/hwc/hwc_display.cpp
index 17b4b99..bb062cd 100644
--- a/sdm/libs/hwc/hwc_display.cpp
+++ b/sdm/libs/hwc/hwc_display.cpp
@@ -449,6 +449,7 @@
layer_buffer.height = UINT32(aligned_height);
layer_buffer.unaligned_width = UINT32(unaligned_width);
layer_buffer.unaligned_height = UINT32(unaligned_height);
+ layer_buffer.fb_id = pvt_handle->fb_id;
if (SetMetaData(pvt_handle, layer) != kErrorNone) {
return -EINVAL;