Jelajahi Sumber

Merge "msm: camera: csiphy: Continue in case of unavailibility of CSIPHY hw" into camera-kernel.lnx.5.0

Savita Patted 4 tahun lalu
induk
melakukan
017b2667e9
1 mengubah file dengan 6 tambahan dan 0 penghapusan
  1. 6 0
      drivers/cam_sensor_module/cam_csiphy/cam_csiphy_core.c

+ 6 - 0
drivers/cam_sensor_module/cam_csiphy/cam_csiphy_core.c

@@ -234,6 +234,12 @@ static void cam_csiphy_prgm_cmn_data(
 		csiphybase = g_phy_data[csiphy_idx].base_address;
 		is_3phase = g_phy_data[csiphy_idx].is_3phase;
 
+		if (!csiphybase) {
+			CAM_DBG(CAM_CSIPHY, "CSIPHY: %d is not available in platform",
+				csiphy_idx);
+			continue;
+		}
+
 		for (i = 0; i < size; i++) {
 			csiphy_common_reg =
 				&csiphy_dev->ctrl_reg->csiphy_common_reg[i];