Merge "msm: vidc: check for cvp support"
This commit is contained in:
commit
d2eb76acdc
@ -4607,6 +4607,12 @@ int msm_venc_set_cvp_skipratio(struct msm_vidc_inst *inst)
|
||||
d_vpr_e("%s: invalid params %pK\n", __func__, inst);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (!is_cvp_supported(inst)) {
|
||||
s_vpr_h(inst->sid, "%s cvp is not supported", __func__);
|
||||
return rc;
|
||||
}
|
||||
|
||||
if (!msm_vidc_cvp_usage)
|
||||
return 0;
|
||||
|
||||
|
@ -794,6 +794,11 @@ static bool msm_vidc_set_cvp_metadata(struct msm_vidc_inst *inst) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!is_cvp_supported(inst)) {
|
||||
s_vpr_h(inst->sid, "%s cvp is not supported", __func__);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (inst->prop.extradata_ctrls & EXTRADATA_ENC_INPUT_CVP)
|
||||
value = 0x1;
|
||||
|
||||
|
@ -59,6 +59,11 @@ static inline bool is_low_power_session(struct msm_vidc_inst *inst)
|
||||
return !!(inst->flags & VIDC_LOW_POWER);
|
||||
}
|
||||
|
||||
static inline bool is_cvp_supported(struct msm_vidc_inst *inst)
|
||||
{
|
||||
return inst->core && !inst->core->resources.no_cvp;
|
||||
}
|
||||
|
||||
static inline struct v4l2_ctrl *get_ctrl(struct msm_vidc_inst *inst,
|
||||
u32 id)
|
||||
{
|
||||
|
@ -1398,6 +1398,10 @@ static struct msm_vidc_common_data holi_common_data[] = {
|
||||
.key = "qcom,fw-vpp-cycles",
|
||||
.value = 225975,
|
||||
},
|
||||
{
|
||||
.key = "qcom,no-cvp",
|
||||
.value = 1,
|
||||
},
|
||||
};
|
||||
|
||||
static struct msm_vidc_efuse_data shima_efuse_data[] = {
|
||||
|
@ -813,6 +813,8 @@ int read_platform_resources_from_drv_data(
|
||||
"qcom,vpp_delay_supported");
|
||||
res->enc_auto_dynamic_fps = find_key_value(platform_data,
|
||||
"qcom,enc_auto_dynamic_fps");
|
||||
res->no_cvp = find_key_value(platform_data,
|
||||
"qcom,no-cvp");
|
||||
|
||||
res->csc_coeff_data = &platform_data->csc_data;
|
||||
|
||||
|
@ -206,6 +206,7 @@ struct msm_vidc_platform_resources {
|
||||
uint32_t ubwc_stats_in_fbd;
|
||||
uint32_t has_vpp_delay;
|
||||
bool enc_auto_dynamic_fps;
|
||||
bool no_cvp;
|
||||
};
|
||||
|
||||
static inline bool is_iommu_present(struct msm_vidc_platform_resources *res)
|
||||
|
Loading…
Reference in New Issue
Block a user