Loading drivers/media/platform/msm/vidc/msm_vidc_platform.c +12 −0 Original line number Diff line number Diff line Loading @@ -154,6 +154,10 @@ static struct msm_vidc_common_data sdm845_common_data[] = { .key = "qcom,debug-timeout", .value = 0, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_common_data sdm670_common_data_v0[] = { Loading Loading @@ -205,6 +209,10 @@ static struct msm_vidc_common_data sdm670_common_data_v0[] = { .key = "qcom,hw-resp-timeout", .value = 1000, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_common_data sdm670_common_data_v1[] = { Loading Loading @@ -256,6 +264,10 @@ static struct msm_vidc_common_data sdm670_common_data_v1[] = { .key = "qcom,hw-resp-timeout", .value = 1000, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_efuse_data sdm670_efuse_data[] = { Loading drivers/media/platform/msm/vidc/venus_hfi.c +14 −6 Original line number Diff line number Diff line Loading @@ -2747,7 +2747,7 @@ static void venus_hfi_pm_handler(struct work_struct *work) { int rc = 0; u32 wfi_status = 0, idle_status = 0, pc_ready = 0; int count = 0; int pc_count = 0, idle_count = 0; const int max_tries = 10; struct venus_hfi_device *device = list_first_entry( &hal_ctxt.dev_head, struct venus_hfi_device, list); Loading Loading @@ -2796,8 +2796,16 @@ static void venus_hfi_pm_handler(struct work_struct *work) wfi_status); goto skip_power_off; } if (device->res->sys_idle_indicator && !(idle_status & BIT(30))) { while (device->res->sys_idle_indicator && idle_count < max_tries) { if (idle_status & BIT(30)) break; usleep_range(50, 100); idle_status = __read_register(device, VIDC_CPU_CS_SCIACMDARG0); idle_count++; } if (idle_count == max_tries) { dprintk(VIDC_WARN, "Skipping PC as idle_status (%#x) bit not set\n", idle_status); Loading @@ -2810,7 +2818,7 @@ static void venus_hfi_pm_handler(struct work_struct *work) goto skip_power_off; } while (count < max_tries) { while (pc_count < max_tries) { wfi_status = __read_register(device, VIDC_WRAPPER_CPU_STATUS); pc_ready = __read_register(device, Loading @@ -2819,10 +2827,10 @@ static void venus_hfi_pm_handler(struct work_struct *work) VIDC_CPU_CS_SCIACMDARG0_HFI_CTRL_PC_READY)) break; usleep_range(150, 250); count++; pc_count++; } if (count == max_tries) { if (pc_count == max_tries) { dprintk(VIDC_ERR, "Skip PC. Core is not in right state (%#x, %#x)\n", wfi_status, pc_ready); Loading Loading
drivers/media/platform/msm/vidc/msm_vidc_platform.c +12 −0 Original line number Diff line number Diff line Loading @@ -154,6 +154,10 @@ static struct msm_vidc_common_data sdm845_common_data[] = { .key = "qcom,debug-timeout", .value = 0, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_common_data sdm670_common_data_v0[] = { Loading Loading @@ -205,6 +209,10 @@ static struct msm_vidc_common_data sdm670_common_data_v0[] = { .key = "qcom,hw-resp-timeout", .value = 1000, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_common_data sdm670_common_data_v1[] = { Loading Loading @@ -256,6 +264,10 @@ static struct msm_vidc_common_data sdm670_common_data_v1[] = { .key = "qcom,hw-resp-timeout", .value = 1000, }, { .key = "qcom,enable-idle-indicator", .value = 1, }, }; static struct msm_vidc_efuse_data sdm670_efuse_data[] = { Loading
drivers/media/platform/msm/vidc/venus_hfi.c +14 −6 Original line number Diff line number Diff line Loading @@ -2747,7 +2747,7 @@ static void venus_hfi_pm_handler(struct work_struct *work) { int rc = 0; u32 wfi_status = 0, idle_status = 0, pc_ready = 0; int count = 0; int pc_count = 0, idle_count = 0; const int max_tries = 10; struct venus_hfi_device *device = list_first_entry( &hal_ctxt.dev_head, struct venus_hfi_device, list); Loading Loading @@ -2796,8 +2796,16 @@ static void venus_hfi_pm_handler(struct work_struct *work) wfi_status); goto skip_power_off; } if (device->res->sys_idle_indicator && !(idle_status & BIT(30))) { while (device->res->sys_idle_indicator && idle_count < max_tries) { if (idle_status & BIT(30)) break; usleep_range(50, 100); idle_status = __read_register(device, VIDC_CPU_CS_SCIACMDARG0); idle_count++; } if (idle_count == max_tries) { dprintk(VIDC_WARN, "Skipping PC as idle_status (%#x) bit not set\n", idle_status); Loading @@ -2810,7 +2818,7 @@ static void venus_hfi_pm_handler(struct work_struct *work) goto skip_power_off; } while (count < max_tries) { while (pc_count < max_tries) { wfi_status = __read_register(device, VIDC_WRAPPER_CPU_STATUS); pc_ready = __read_register(device, Loading @@ -2819,10 +2827,10 @@ static void venus_hfi_pm_handler(struct work_struct *work) VIDC_CPU_CS_SCIACMDARG0_HFI_CTRL_PC_READY)) break; usleep_range(150, 250); count++; pc_count++; } if (count == max_tries) { if (pc_count == max_tries) { dprintk(VIDC_ERR, "Skip PC. Core is not in right state (%#x, %#x)\n", wfi_status, pc_ready); Loading