msm: camera: isp: Add support for IFE epoch config

Add support to configure IFE epoch for SFE QCFA HDR
or binning use-cases.

CRs-Fixed: 2841729
Change-Id: I958656ddbe4e28d3247e317b021da5e963b03679
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
This commit is contained in:
Karthik Anantha Ram
2021-01-04 14:44:09 -08:00
parent 0499b96da4
commit 933cf650a1
4 changed files with 9 additions and 1 deletions

View File

@@ -4280,6 +4280,8 @@ static int cam_ife_mgr_acquire_get_unified_structure_v2(
CAM_ISP_DYNAMIC_SENOR_SWITCH_EN); CAM_ISP_DYNAMIC_SENOR_SWITCH_EN);
in_port->can_use_lite = in->feature_flag & in_port->can_use_lite = in->feature_flag &
CAM_ISP_CAN_USE_LITE_MODE; CAM_ISP_CAN_USE_LITE_MODE;
in_port->sfe_binned_epoch_cfg = (in->feature_flag &
CAM_ISP_SFE_BINNED_EPOCH_CFG_ENABLE);
in_port->data = kcalloc(in->num_out_res, in_port->data = kcalloc(in->num_out_res,
sizeof(struct cam_isp_out_port_generic_info), sizeof(struct cam_isp_out_port_generic_info),

View File

@@ -135,6 +135,7 @@ struct cam_isp_in_port_generic_info {
uint32_t secure_mode; uint32_t secure_mode;
uint32_t dynamic_sensor_switch_en; uint32_t dynamic_sensor_switch_en;
uint32_t can_use_lite; uint32_t can_use_lite;
uint32_t sfe_binned_epoch_cfg;
struct cam_isp_out_port_generic_info *data; struct cam_isp_out_port_generic_info *data;
}; };

View File

@@ -64,6 +64,7 @@ struct cam_vfe_mux_ver4_data {
bool is_offline; bool is_offline;
bool is_pixel_path; bool is_pixel_path;
bool sfe_binned_epoch_cfg;
struct timespec64 sof_ts; struct timespec64 sof_ts;
struct timespec64 epoch_ts; struct timespec64 epoch_ts;
@@ -373,6 +374,8 @@ int cam_vfe_top_acquire_resource(
acquire_data->vfe_in.in_port->horizontal_bin; acquire_data->vfe_in.in_port->horizontal_bin;
res_data->vbi_value = 0; res_data->vbi_value = 0;
res_data->hbi_value = 0; res_data->hbi_value = 0;
res_data->sfe_binned_epoch_cfg = (bool)
acquire_data->vfe_in.in_port->sfe_binned_epoch_cfg;
if (res_data->is_dual) if (res_data->is_dual)
res_data->dual_hw_idx = acquire_data->vfe_in.dual_hw_idx; res_data->dual_hw_idx = acquire_data->vfe_in.dual_hw_idx;
@@ -1023,7 +1026,8 @@ static int cam_vfe_resource_start(
/* Epoch line cfg will still be configured at midpoint of the frame width. /* Epoch line cfg will still be configured at midpoint of the frame width.
* We use '/4' instead of '/2' because it is multipixel path. * We use '/4' instead of '/2' because it is multipixel path.
*/ */
if (rsrc_data->horizontal_bin || rsrc_data->qcfa_bin) if (rsrc_data->horizontal_bin || rsrc_data->qcfa_bin ||
rsrc_data->sfe_binned_epoch_cfg)
val >>= 1; val >>= 1;
cam_io_w_mb(val, rsrc_data->mem_base + cam_io_w_mb(val, rsrc_data->mem_base +

View File

@@ -169,6 +169,7 @@
#define CAM_ISP_PARAM_FETCH_SECURITY_MODE BIT(0) #define CAM_ISP_PARAM_FETCH_SECURITY_MODE BIT(0)
#define CAM_ISP_CAN_USE_LITE_MODE BIT(1) #define CAM_ISP_CAN_USE_LITE_MODE BIT(1)
#define CAM_ISP_DYNAMIC_SENOR_SWITCH_EN BIT(2) #define CAM_ISP_DYNAMIC_SENOR_SWITCH_EN BIT(2)
#define CAM_ISP_SFE_BINNED_EPOCH_CFG_ENABLE BIT(3)
/* ISP core cfg flag params */ /* ISP core cfg flag params */
#define CAM_ISP_PARAM_CORE_CFG_HDR_MUX_SEL BIT(0) #define CAM_ISP_PARAM_CORE_CFG_HDR_MUX_SEL BIT(0)