video: driver: Remove core check from video driver

Remove core check from all the functions in video driver.
ore check is present in most of the functions in video
driver which is not required.
Keep check only at root level functions and remove
the check from rest all of the functions.

Change-Id: I5f6374b68dd739b7ab563f32f64bb90e368c4085
Signed-off-by: Vedang Nagar <quic_vnagar@quicinc.com>
This commit is contained in:
Vedang Nagar
2023-06-13 19:20:43 +05:30
parent 34ca50e260
commit e05b1f39c9
28 changed files with 63 additions and 764 deletions

View File

@@ -21,11 +21,6 @@ int __write_register(struct msm_vidc_core *core, u32 reg, u32 value)
u8 *base_addr;
int rc = 0;
if (!core || !core->resource) {
d_vpr_e("%s: invalid params\n", __func__);
return -EINVAL;
}
rc = __strict_check(core, __func__);
if (rc)
return rc;
@@ -58,11 +53,6 @@ int __write_register_masked(struct msm_vidc_core *core, u32 reg, u32 value,
u8 *base_addr;
int rc = 0;
if (!core || !core->resource) {
d_vpr_e("%s: invalid params\n", __func__);
return -EINVAL;
}
rc = __strict_check(core, __func__);
if (rc)
return rc;
@@ -100,11 +90,6 @@ int __read_register(struct msm_vidc_core *core, u32 reg, u32 *value)
int rc = 0;
u8 *base_addr;
if (!core || !core->resource || !value) {
d_vpr_e("%s: invalid params\n", __func__);
return -EINVAL;
}
if (!is_core_sub_state(core, CORE_SUBSTATE_POWER_ENABLE)) {
d_vpr_e("HFI Read register failed : Power is OFF\n");
return -EINVAL;
@@ -131,11 +116,6 @@ int __read_register_with_poll_timeout(struct msm_vidc_core *core, u32 reg,
u32 val = 0;
u8 *addr;
if (!core || !core->resource) {
d_vpr_e("%s: invalid params\n", __func__);
return -EINVAL;
}
if (!is_core_sub_state(core, CORE_SUBSTATE_POWER_ENABLE)) {
d_vpr_e("%s failed: Power is OFF\n", __func__);
return -EINVAL;
@@ -163,11 +143,6 @@ int __set_registers(struct msm_vidc_core *core)
unsigned int prst_count;
int cnt, rc = 0;
if (!core || !core->platform) {
d_vpr_e("core resources null, cannot set registers\n");
return -EINVAL;
}
reg_prst = core->platform->data.reg_prst_tbl;
prst_count = core->platform->data.reg_prst_tbl_size;