Эх сурвалжийг харах

msm: camera: cpas: Add version map entry for 680 titan version

This change add cpas hw version map entry for 680 titan
version. And remove cpas version check for ubwc support.

CRs-Fixed: 2825675
Change-Id: I858838a5a774c964a1a09d96114442f69058670a
Signed-off-by: Ayush Kumar <[email protected]>
Ayush Kumar 4 жил өмнө
parent
commit
bf3e83fc7f

+ 21 - 26
drivers/cam_isp/isp_hw_mgr/isp_hw/vfe_hw/cam_vfe_soc.c

@@ -58,34 +58,29 @@ static int cam_vfe_get_dt_properties(struct cam_hw_soc_info *soc_info)
 		goto pid;
 	}
 
-	switch (soc_info->hw_version) {
-	case CAM_CPAS_TITAN_480_V100:
-	case CAM_CPAS_TITAN_580_V100:
-	case CAM_CPAS_TITAN_570_V200:
-	case CAM_CPAS_TITAN_165_V100:
-		num_ubwc_cfg = of_property_count_u32_elems(of_node,
-			"ubwc-static-cfg");
-
-		if (num_ubwc_cfg < 0 || num_ubwc_cfg > UBWC_STATIC_CONFIG_MAX) {
-			CAM_ERR(CAM_ISP, "wrong num_ubwc_cfg: %d",
-				num_ubwc_cfg);
-			rc = num_ubwc_cfg;
-			goto pid;
-		}
+	if (!of_property_read_bool(of_node, "ubwc-static-cfg")) {
+		CAM_DBG(CAM_ISP, "ubwc-static-cfg not supported");
+		goto pid;
+	}
 
-		for (i = 0; i < num_ubwc_cfg; i++) {
-			rc = of_property_read_u32_index(of_node,
-				"ubwc-static-cfg", i,
-				&vfe_soc_private->ubwc_static_ctrl[i]);
-			if (rc < 0) {
-				CAM_ERR(CAM_ISP,
-					"unable to read ubwc static config");
-				break;
-			}
+	num_ubwc_cfg = of_property_count_u32_elems(of_node,
+		"ubwc-static-cfg");
+
+	if (num_ubwc_cfg < 0 || num_ubwc_cfg > UBWC_STATIC_CONFIG_MAX) {
+		CAM_ERR(CAM_ISP, "wrong num_ubwc_cfg: %d",
+			num_ubwc_cfg);
+		rc = num_ubwc_cfg;
+		goto pid;
+	}
+
+	for (i = 0; i < num_ubwc_cfg; i++) {
+		rc = of_property_read_u32_index(of_node,
+			"ubwc-static-cfg", i,
+			&vfe_soc_private->ubwc_static_ctrl[i]);
+		if (rc < 0) {
+			CAM_ERR(CAM_ISP,
+				"unable to read ubwc static config");
 		}
-		break;
-	default:
-		break;
 	}
 pid:
 	/* set some default values */