msm: camera: cpas: Add hw version checks for Yupik camera

This change add titan hw version checks in csid, vfe and icp
camera drivers for Yupik camera.

CRs-Fixed: 2825675
Change-Id: Ibb704efa5eae327fc7c376328ceafc45a8217f44
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
Bu işleme şunda yer alıyor:
Ayush Kumar
2020-11-26 11:48:18 +05:30
işlemeyi yapan: Gerrit - the friendly Code Review server
ebeveyn 315ec1178d
işleme 92dbea0ccb
7 değiştirilmiş dosya ile 14 ekleme ve 6 silme

Dosyayı Görüntüle

@@ -125,6 +125,7 @@ enum cam_cpas_version_map_id {
enum cam_cpas_hw_version {
CAM_CPAS_TITAN_NONE = 0,
CAM_CPAS_TITAN_150_V100 = 0x150100,
CAM_CPAS_TITAN_165_V100 = 0x165100,
CAM_CPAS_TITAN_170_V100 = 0x170100,
CAM_CPAS_TITAN_170_V110 = 0x170110,
CAM_CPAS_TITAN_170_V120 = 0x170120,
@@ -140,7 +141,6 @@ enum cam_cpas_hw_version {
CAM_CPAS_TITAN_545_V100 = 0x545100,
CAM_CPAS_TITAN_570_V200 = 0x570200,
CAM_CPAS_TITAN_680_V100 = 0x680100,
CAM_CPAS_TITAN_165_V100 = 0x165100,
CAM_CPAS_TITAN_MAX
};

Dosyayı Görüntüle

@@ -1479,6 +1479,7 @@ static int cam_convert_hw_idx_to_ife_hw_num(int hw_idx)
break;
case CAM_CPAS_TITAN_580_V100:
case CAM_CPAS_TITAN_570_V200:
case CAM_CPAS_TITAN_165_V100:
if (hw_idx == 0)
return CAM_ISP_IFE0_HW;
else if (hw_idx == 1)

Dosyayı Görüntüle

@@ -2559,7 +2559,8 @@ static int cam_ife_csid_init_config_rdi_path(
if (camera_hw_version == CAM_CPAS_TITAN_480_V100 ||
camera_hw_version == CAM_CPAS_TITAN_175_V130 ||
camera_hw_version == CAM_CPAS_TITAN_580_V100 ||
camera_hw_version == CAM_CPAS_TITAN_570_V200) {
camera_hw_version == CAM_CPAS_TITAN_570_V200 ||
camera_hw_version == CAM_CPAS_TITAN_165_V100) {
val |= (path_data->drop_enable <<
csid_reg->cmn_reg->drop_h_en_shift_val) |
(path_data->drop_enable <<

Dosyayı Görüntüle

@@ -1269,7 +1269,8 @@ static int cam_vfe_bus_start_wm(
} else if ((camera_hw_version == CAM_CPAS_TITAN_175_V100) ||
(camera_hw_version == CAM_CPAS_TITAN_175_V101) ||
(camera_hw_version == CAM_CPAS_TITAN_175_V120) ||
(camera_hw_version == CAM_CPAS_TITAN_175_V130)) {
(camera_hw_version == CAM_CPAS_TITAN_175_V130) ||
(camera_hw_version == CAM_CPAS_TITAN_165_V100)) {
struct cam_vfe_bus_ver2_reg_offset_ubwc_3_client
*ubwc_regs;
@@ -2620,6 +2621,7 @@ static void cam_vfe_bus_update_ubwc_meta_addr(
case CAM_CPAS_TITAN_175_V101:
case CAM_CPAS_TITAN_175_V120:
case CAM_CPAS_TITAN_175_V130:
case CAM_CPAS_TITAN_165_V100:
ubwc_3_regs =
(struct cam_vfe_bus_ver2_reg_offset_ubwc_3_client *)
regs;
@@ -2835,6 +2837,7 @@ static int cam_vfe_bus_update_ubwc_regs(
case CAM_CPAS_TITAN_175_V101:
case CAM_CPAS_TITAN_175_V120:
case CAM_CPAS_TITAN_175_V130:
case CAM_CPAS_TITAN_165_V100:
rc = cam_vfe_bus_update_ubwc_3_regs(
wm_data, reg_val_pair, i, j);
break;

Dosyayı Görüntüle

@@ -427,7 +427,8 @@ static int cam_vfe_camif_lite_cpas_fifo_levels_reg_dump(
uint32_t val;
if (soc_private->cpas_version == CAM_CPAS_TITAN_175_V120 ||
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130) {
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130 ||
soc_private->cpas_version == CAM_CPAS_TITAN_165_V100) {
rc = cam_cpas_reg_read(soc_private->cpas_handle,
CAM_CPAS_REG_CAMNOC, 0x3A20, true, &val);
if (rc) {

Dosyayı Görüntüle

@@ -557,7 +557,8 @@ static int cam_vfe_camif_reg_dump(
soc_private = camif_priv->soc_info->soc_private;
if (soc_private->cpas_version == CAM_CPAS_TITAN_175_V120 ||
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130) {
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130 ||
soc_private->cpas_version == CAM_CPAS_TITAN_165_V100) {
cam_cpas_reg_read(soc_private->cpas_handle,
CAM_CPAS_REG_CAMNOC, 0x3A20, true, &val);
CAM_INFO(CAM_ISP, "IFE0_nRDI_MAXWR_LOW offset 0x3A20 val 0x%x",

Dosyayı Görüntüle

@@ -94,7 +94,8 @@ struct cam_vfe_mux_rdi_data *rdi_priv)
uint32_t val;
if (soc_private->cpas_version == CAM_CPAS_TITAN_175_V120 ||
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130) {
soc_private->cpas_version == CAM_CPAS_TITAN_175_V130 ||
soc_private->cpas_version == CAM_CPAS_TITAN_165_V100) {
rc = cam_cpas_reg_read(soc_private->cpas_handle,
CAM_CPAS_REG_CAMNOC, 0x3A20, true, &val);
if (rc) {