sdm: Add missing default initializations

Add missing default initializations. Remove reset().

Change-Id: Ib629db78b7b47afbf66193533870a6433ab9eec6
CRs-fixed: 2194609
diff --git a/sdm/include/private/hw_info_types.h b/sdm/include/private/hw_info_types.h
index 5304133..c9b5782 100644
--- a/sdm/include/private/hw_info_types.h
+++ b/sdm/include/private/hw_info_types.h
@@ -168,8 +168,6 @@
   std::string device_path = "";
   float min_downscale = 2.0f;
   bool downscale_compression = false;
-
-  void Reset() { *this = HWRotatorInfo(); }
 };
 
 enum HWQseedStepVersion {
@@ -259,8 +257,6 @@
   HWQseedStepVersion pipe_qseed3_version = kQseed3v2;  // only valid when has_qseed3=true
   uint32_t min_prefill_lines = 0;
   InlineRotationVersion inrot_version = kInlineRotationNone;
-
-  void Reset() { *this = HWResourceInfo(); }
 };
 
 struct HWSplitInfo {
@@ -356,8 +352,8 @@
 };
 
 struct HWSessionConfig {
-  LayerRect src_rect;
-  LayerRect dst_rect;
+  LayerRect src_rect {};
+  LayerRect dst_rect {};
   uint32_t buffer_count = 0;
   bool secure = false;
   uint32_t frame_rate = 0;
@@ -388,21 +384,19 @@
 struct HWRotateInfo {
   int pipe_id = -1;  // Not actual pipe id, but the relative DMA id
   int writeback_id = -1;  // Writeback block id, but this is the same as DMA id
-  LayerRect src_roi;  // Source crop of each split
-  LayerRect dst_roi;  // Destination crop of each split
+  LayerRect src_roi {};  // Source crop of each split
+  LayerRect dst_roi {};  // Destination crop of each split
   bool valid = false;
   int rotate_id = -1;  // Actual rotator session id with driver
-
-  void Reset() { *this = HWRotateInfo(); }
 };
 
 struct HWRotatorSession {
-  HWRotateInfo hw_rotate_info[kMaxRotatePerLayer];
+  HWRotateInfo hw_rotate_info[kMaxRotatePerLayer] {};
   uint32_t hw_block_count = 0;  // number of rotator hw blocks used by rotator session
   int session_id = -1;  // A handle with Session Manager
-  HWSessionConfig hw_session_config;
-  LayerBuffer input_buffer;  // Input to rotator
-  LayerBuffer output_buffer;  // Output of rotator, crop width and stride are same
+  HWSessionConfig hw_session_config {};
+  LayerBuffer input_buffer {};  // Input to rotator
+  LayerBuffer output_buffer {};  // Output of rotator, crop width and stride are same
   float input_compression = 1.0f;
   float output_compression = 1.0f;
   bool is_buffer_cached = false;
@@ -442,10 +436,10 @@
   int32_t phase_step_x = 0;
   int32_t init_phase_y = 0;
   int32_t phase_step_y = 0;
-  HWPixelExtension left;
-  HWPixelExtension top;
-  HWPixelExtension right;
-  HWPixelExtension bottom;
+  HWPixelExtension left {};
+  HWPixelExtension top {};
+  HWPixelExtension right {};
+  HWPixelExtension bottom {};
   uint32_t roi_width = 0;
   int32_t preload_x = 0;
   int32_t preload_y = 0;
@@ -461,7 +455,7 @@
   } enable;
   uint32_t dst_width = 0;
   uint32_t dst_height = 0;
-  HWPlane plane[MAX_PLANES];
+  HWPlane plane[MAX_PLANES] {};
   // scale_v2_data fields
   ScalingFilterConfig y_rgb_filter_cfg = kFilterEdgeDirected;
   ScalingFilterConfig uv_filter_cfg = kFilterEdgeDirected;
@@ -483,8 +477,7 @@
   uint32_t uv_cir_lut_idx = 0;
   uint32_t y_rgb_sep_lut_idx = 0;
   uint32_t uv_sep_lut_idx = 0;
-
-  HWDetailEnhanceData detail_enhance;
+  HWDetailEnhanceData detail_enhance {};
 };
 
 struct HWDestScaleInfo {
@@ -507,18 +500,16 @@
   uint8_t rect = 255;
   uint32_t pipe_id = 0;
   HWSubBlockType sub_block_type = kHWSubBlockMax;
-  LayerRect src_roi;
-  LayerRect dst_roi;
-  LayerRect excl_rect;  // exclusion rectangle per pipe rectangle
+  LayerRect src_roi {};
+  LayerRect dst_roi {};
+  LayerRect excl_rect {};  // exclusion rectangle per pipe rectangle
   uint8_t horizontal_decimation = 0;
   uint8_t vertical_decimation = 0;
-  HWScaleData scale_data;
+  HWScaleData scale_data {};
   uint32_t z_order = 0;
   uint8_t flags = 0;
   bool valid = false;
   bool is_virtual = 0;
-
-  void Reset() { *this = HWPipeInfo(); }
 };
 
 struct HWSolidfillStage {
@@ -530,15 +521,12 @@
 };
 
 struct HWLayerConfig {
-  HWPipeInfo left_pipe;           // pipe for left side of output
-  HWPipeInfo right_pipe;          // pipe for right side of output
-  HWRotatorSession hw_rotator_session;
-  HWSolidfillStage hw_solidfill_stage;
-
+  HWPipeInfo left_pipe {};           // pipe for left side of output
+  HWPipeInfo right_pipe {};          // pipe for right side of output
+  HWRotatorSession hw_rotator_session {};
+  HWSolidfillStage hw_solidfill_stage {};
   float compression = 1.0f;
   bool use_solidfill_stage = false;
-
-  void Reset() { *this = HWLayerConfig(); }
 };
 
 struct HWHDRLayerInfo {
@@ -560,19 +548,15 @@
   LayerStack *stack = NULL;        // Input layer stack. Set by the caller.
   uint32_t app_layer_count = 0;    // Total number of app layers. Must not be 0.
   uint32_t gpu_target_index = 0;   // GPU target layer index. 0 if not present.
-
   std::vector<Layer> hw_layers = {};  // Layers which need to be programmed on the HW
   std::vector<LayerExt> layer_exts = {};  // Extention layer having list of
                                           // exclusion rectangles for each layer
-
-  std::vector<uint32_t> index;   // Indexes of the layers from the layer stack which need to
+  std::vector<uint32_t> index {};   // Indexes of the layers from the layer stack which need to
                                  // be programmed on hardware.
-  std::vector<uint32_t> roi_index;  // Stores the ROI index where the layers are visible.
-
+  std::vector<uint32_t> roi_index {};  // Stores the ROI index where the layers are visible.
   int sync_handle = -1;         // Release fence id for current draw cycle.
   int set_idle_time_ms = -1;    // Set idle time to the new specified value.
                                 //    -1 indicates no change in idle time since last set value.
-
   std::vector<LayerRect> left_frame_roi = {};   // Left ROI.
   std::vector<LayerRect> right_frame_roi = {};  // Right ROI.
   LayerRect partial_fb_roi = {};   // Damaged area in framebuffer.
@@ -596,8 +580,8 @@
 };
 
 struct HWLayers {
-  HWLayersInfo info;
-  HWLayerConfig config[kMaxSDELayers];
+  HWLayersInfo info {};
+  HWLayerConfig config[kMaxSDELayers] {};
   float output_compression = 1.0f;
   HWQosData qos_data = {};
   HWAVRInfo hw_avr_info = {};
@@ -610,12 +594,10 @@
   uint32_t v_pulse_width = 0;  //!< Vertical pulse width of panel
   uint32_t h_total = 0;        //!< Total width of panel (hActive + hFP + hBP + hPulseWidth)
   uint32_t v_total = 0;        //!< Total height of panel (vActive + vFP + vBP + vPulseWidth)
-  std::bitset<32> s3d_config;  //!< Stores the bit mask of S3D modes
+  std::bitset<32> s3d_config {};  //!< Stores the bit mask of S3D modes
   uint32_t clock_khz = 0;      //!< Stores the pixel clock of panel in khz
   HWTopology topology = kUnknown;  //!< Stores the topology information.
 
-  void Reset() { *this = HWDisplayAttributes(); }
-
   bool operator !=(const HWDisplayAttributes &display_attributes) {
     return ((is_device_split != display_attributes.is_device_split) ||
             (x_pixels != display_attributes.x_pixels) ||
diff --git a/sdm/libs/core/resource_default.cpp b/sdm/libs/core/resource_default.cpp
index cce2cec..73a28a8 100644
--- a/sdm/libs/core/resource_default.cpp
+++ b/sdm/libs/core/resource_default.cpp
@@ -483,7 +483,7 @@
     left_pipe->src_roi = src_rect;
     left_pipe->dst_roi = dst_rect;
     left_pipe->valid = true;
-    right_pipe->Reset();
+    *right_pipe = {};
   }
 
   return kErrorNone;
@@ -520,8 +520,8 @@
   }
 
   // Reset left_pipe and right_pipe to invalid by default
-  left_pipe->Reset();
-  right_pipe->Reset();
+  *left_pipe = {};
+  *right_pipe = {};
 
   if (crop_left_valid) {
     // assign left pipe