提交图

103 次代码提交

作者 SHA1 备注 提交日期
Megha Byahatti
9df60c1fa4 video: driver: Add pipes scalability for multi slice count
- Add pipes check to support different Tile sizes based on
number of VPP Pipes for HFI_IRIS3_ENC_TILE_SIZE_INFO,
HFI_IRIS3_ENC_MB_BASED_MULTI_SLICE_COUNT.

HFI review done with ccb id 3284017.

Change-Id: I2e403ac712143635fd9ff5167260e23d6b48c482
Signed-off-by: Megha Byahatti <quic_mbyahatt@quicinc.com>
2023-12-20 19:41:25 +05:30
qctecmdr
9b62925502 Merge "video: driver: fix roi metadata size calculation" 2023-08-14 14:03:35 -07:00
qctecmdr
d361bf3acb Merge "video: driver: remove dead code of uneccessary setting VPP delay" 2023-08-10 14:02:16 -07:00
Jiajia Cong
d9fe02d49a video: driver: fix roi metadata size calculation
lcu_size shouldn't be changed by shift op, it is still
needed in alignment calculation.

Change-Id: I3c0ebfaee84389926ba3e191d901006065598182
Signed-off-by: Jiajia Cong <quic_jcong@quicinc.com>
2023-08-07 22:01:06 -07:00
qctecmdr
c43d43d95e Merge "video: driver: fix length of line exceeding max length warning" 2023-08-03 15:08:37 -07:00
Ankush Mitra
99c2355e85 video: driver: remove dead code of uneccessary setting VPP delay
In driver num_comv value is coming more than expected
due to assumtion of default VPP delay as 2, which
is not needed now.

Change-Id: Ie24b5b30034cbc465aaa5952d80b6c0811cfe1a2
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-08-01 11:32:01 +05:30
Megha Byahatti
13cfd900b7 video: driver: fix length of line exceeding max length warning
Fix 'length of line exceeding 100 char' warning.

Change-Id: Ic40bb53a85273eee79a37ead1937702b96f4e979
Signed-off-by: Megha Byahatti <quic_mbyahatt@quicinc.com>
2023-07-31 20:05:09 +05:30
Ankush Mitra
a101cca5a9 video: driver: fix space requirement warning
Fix space and blank line required warning.

Change-Id: I2f754e52cdb36332a53b65ca248ae5d974a00ff4
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-07-25 17:50:44 +05:30
Ankush Mitra
30b8ff5ce2 video: driver: fix few checker warning
Fix braces are not necessary warning and suspect code
indentation warning.

Change-Id: I6e599d94766cc34013a0ddd758cf5c6609798ea2
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-07-19 18:38:09 +05:30
qctecmdr
b941cfd415 Merge "video-driver: kept blank line after declarations" 2023-07-18 17:22:50 -07:00
Manikanta Kanamarlapudi
4d2903e0d0 video-driver: kept blank line after declarations
Fix warning of 'Missing blank line after declarations'
in the checker.

Change-Id: I3db5717890db68096e5a035c536f0b6bcae7e28e
2023-07-17 15:18:27 +05:30
Anshul Agarwal
2576adf412 video: driver: fix some checker err
Fix some checker err

Change-Id: I3526a509f4cbb3d91284b21dad851b57bb43f57a
Signed-off-by: Anshul Agarwal <quic_anshagar@quicinc.com>
2023-07-14 15:03:37 +05:30
Ankush Mitra
50a257d310 video: driver: fix No space is necessary after a cast err
Fix this warning in checker.

Change-Id: I2f90b2f8b3fddb55a3b1dd9b0e4ca227e46ed42f
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-07-12 18:15:31 +05:30
Dikshita Agarwal
2ae30091f4 video: driver: fix copyright markings
fix copyright markings and have all markings in one
multiline comment.

Change-Id: I481c6213bb25e8c278956ad6a51df3fc5c1aabf2
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2023-07-08 01:40:35 +05:30
qctecmdr
75351f36a5 Merge "video: driver: use helper functions wherever applicable" 2023-06-30 10:08:21 -07:00
Dikshita Agarwal
5d2eff1150 video: driver: use helper functions wherever applicable
There are many places in code where available helper
functions are not being used, fix it.

Change-Id: Id5b309837fd5847e280f7fab02820af1b08242a6
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2023-06-28 13:59:57 +05:30
Vedang Nagar
e05b1f39c9 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>
2023-06-22 20:53:42 +05:30
Govindaraj Rajagopal
29d10ac07b video: driver: cleanup driver remove sequence
Remove deinit sequence calls and register devm
managed callbacks, so that kernel can invoke
then, when dev scope ends and cleansup all
associated resources.

Change-Id: I729fd21fe32d9f39240d0b743f910409d93a00c5
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2023-06-13 13:17:23 +05:30
Akshata Sahukar
b6fba340c3 video: driver: fix hfi_buffer_iris3.h premerge failures
remove macro brackets in hfi_buffer_iris3.h to
fix premerge failures

Change-Id: I30f2cb656376cefc632cc3fd64dc979a903bfdc0
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2023-06-09 19:19:26 -07:00
Anshul Agarwal
950306d1aa video: driver: fix some checker err
Fix some checker err

Change-Id: I357059999dd43b58d6c414868a8b4060b6b691da
Signed-off-by: Anshul Agarwal <quic_anshagar@quicinc.com>
2023-06-09 15:31:01 +05:30
Anshul Agarwal
65d28b3cab video: driver: fix some checker err
Fix some checker err.

Change-Id: I6704727abf49c8c55ac9c213dec180c93928961f
Signed-off-by: Anshul Agarwal <quic_anshagar@quicinc.com>
2023-06-08 12:00:19 +05:30
Ankush Mitra
e1cb32c5de video: driver: resolve some checker err
Resolve some static checker err.

Change-Id: I0aa1d8c905ac7fd1defa16dd28d4386465f09ff3
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-06-06 11:57:20 +05:30
Ankush Mitra
400a782851 video: driver: add space and move "{" to previous line
This change will fix some checker err.

Change-Id: I93da24e9b54bb1d5f6145b438858a977b06ca09c
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-06-04 21:08:33 +05:30
Ankush Mitra
542b9f9736 video: driver: enclosed macros with complex values within bracket
This is resolve some of this kind of checker err.

Change-Id: Ief665e17045c3b6a6ff636ab6404c6e0c93e9460
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-06-01 12:32:01 +05:30
Ankush Mitra
a04f985cda video: driver: move "{" to the previous line
This will fix some static code checker err.

Change-Id: I664e96dd2d65f694c3f2523e1f4aeb08a40f660a
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-05-30 22:21:18 +05:30
Ankush Mitra
e3415ddbef video: driver: changing "foo* bar" to "foo *bar"
This change will resolve some of the static code
checker err.

Change-Id: I62edcbc8740dd932f5662b0bad1548374a0c9188
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-05-30 22:14:30 +05:30
Vedang Nagar
e2663ce820 video: driver: Remove inst check in video driver
Remove inst check from all the functions in video driver.
Inst check is present in most of the functions in video
driver which is not required.
Keep check only at root level functions and remove
from rest all of the functions.

Change-Id: Ib310cd3df5e8612a9fc3a5aa654dff4203a12906
Signed-off-by: Vedang Nagar <quic_vnagar@quicinc.com>
2023-05-25 21:04:49 +05:30
Ankush Mitra
6bdbae50f2 video: driver: remove core capability pointer
Remove core capability pointer.

Change-Id: I42f4c5cb7f8a0791b8c5f84d5f0d953be3bf80d6
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-04-06 10:56:57 +05:30
Ankush Mitra
e450d8eaa3 video: driver: remove capability pointer
Remove capability pointer and allocate
memory with max cap size.

Change-Id: I7f53e3b35439f91b72f057695b6e63f71bfecc0a
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2023-04-05 11:58:48 +05:30
Govindaraj Rajagopal
c3c85e9653 video: driver: remove config dependencies
remove all conditional compilation in video driver.
With this change, all files willbe always compiled
and will be available in final kernel object file.

Change-Id: I9843c246e23bd1ee4fb8918e5cfa840e2defd432
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2023-02-21 14:33:41 +05:30
Chinmay Sawarkar
6e414ca7a7 video: driver: kalama power calculations
New bandwidth and frequency calculation functions
for kalama.

Change-Id: Iaca0be832c42e00bb7404f7cfbac5bbf03427144
Signed-off-by: Ashish Patil <quic_ashpat@quicinc.com>
2023-02-16 20:08:14 -08:00
Vedang Nagar
8765409333 video: driver: Fix unbalanced irq warning in interrupt handling
In case of watchdog interrupt, power off sequence will
get called which will make intr_status to 0 due to which
enable_irq gets called from isr_handler irrespective of
watchdog interrupt. Now during power up sequence again
when the enable_irq gets called, it will through
"Unbalanced enable for irq" error.
Added a fix for the same.

Call trace ->
enable_irq+0x9c/0xf8
__power_on_ar50lt+0x2d4/0x320 [msm_video]
__load_fw+0x92c/0x1368 [msm_video]
venus_hfi_core_init+0x64/0x468 [msm_video]
msm_vidc_core_init+0x158/0x4bc [msm_video]
msm_vidc_open+0x90/0x804 [msm_video]

Change-Id: Ic675d7540ef029e530a8cd5b87fb97f72e72057f
Signed-off-by: Vedang Nagar <quic_vnagar@quicinc.com>
2023-02-14 12:38:20 +05:30
Manikanta Kanamarlapudi
06d84f081f msm: vidc: update dpb buffer size only for film grain content
update buffer size only for film grain content.

Change-Id: Ia9230d36ef0c917723fdb1eea82adfb8df3b3413
Signed-off-by: Manikanta Kanamarlapudi <quic_kmanikan@quicinc.com>
2023-02-09 06:42:34 -08:00
Govindaraj Rajagopal
ab9b1a112b video: driver: add power domain and opp table support for video
Added changes to support generic power domain and opp table.
This is an alternative for downstream regulator framework.

power domain can be enabled using below dtsi entries.

power-domains =
    <&videocc MVS0C_GDSC>,
	<&videocc MVS0_GDSC>,
	<&rpmhpd SM8450_MXC>,
	<&rpmhpd SM8450_MMCX>
power-domain-names =
    "iris-ctl", "vcodec", "mx", "mmcx";

Power domain handles willbe parsed at driver side using below api's.
   - dev_pm_domain_attach_by_name()
   - devm_pm_opp_attach_genpd()

devm_pm_opp_attach_genpd() provides consumer virtual device handles
and i.e linked to core->dev using device_link_add().

MXC, MMCX rails wilbe powered up by scaling desired rate using
dev_pm_opp_set_rate().

Change-Id: I3d73434cb772078f031aec7cadc2d42ab930edd0
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2023-01-18 16:44:23 +05:30
Darshana Patil
ea34534af0 video: driver: update copyright markings to 2023
update copyright markings to 2023 in all files.

Change-Id: I6842d56c4a8fff6a7a93d0c1d4bc049041297b02
Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
2023-01-13 14:58:17 -08:00
Govindaraj Rajagopal
c4982fbf1a video: driver: refine core state machine
introduced core error state and added changes
to refine core state machine.

Change-Id: Ib3b94fd3798e902b7a6cfc5de45820558c89806e
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-12-15 07:59:45 +05:30
qctecmdr
fdb319f335 Merge "video: driver: Move adjust/set control functions to common/platform.c" 2022-12-07 14:54:07 -08:00
Govindaraj Rajagopal
9b0140cf03 video: driver: add core sub_state support
Introduce core->sub_state similar to inst->sub_state.

[1] pm_suspended - moved to this substate in case of PM suspend
[2] handoff - moved to this state after successful
    handoff_regulator call.
[3] fw_power_control - moved to this state in case of IFPC.
[4] power_enable - will track core power_on/power_off status.
[5] page_fault - used to rate_limit fault logs.
[6] cpu_wd - indicates hw fired wd interrupt.
[7] video_unresponsive - moved to this state if sync cmd fails.

Change-Id: Iceb65cf404fd93aff7846860b0276307e4eab570
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-11-23 10:53:11 +05:30
Ankush Mitra
1df215f203 video: driver: Move adjust/set control functions to common/platform.c
Move adjust/set control functions to common/platform.c as part of
upstream effort.
This is part 1 of the change.

Change-Id: I8c440740fe785b5b052c4d44963ea34c21419fa4
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2022-11-22 23:01:17 +05:30
Ankush Mitra
b35fde25c4 Video Driver: fix frame freeze for HEVC 10bit all intra decoding
1. Allow turbo for HEVC 10bit all intra decoding;
2. Add 25 percent extra to VSP cycle for HEVC
   10bit all intra decoding;

Change-Id: I794b2a896f7e9444c8979abdb15b8e673a5270ee
Signed-off-by: Zhongbo Shi <quic_zhongbos@quicinc.com>
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2022-11-07 09:01:17 -08:00
Ankush Mitra
dc39a04e6e video: driver: follow vcodec power collapse seq for PC failure case
if PC fails for 10 times then video driver is treating that situation
as fatal and doing force core_deinit(), in this case firmware will not
follow vcodec power_collapse sequence and if there any pending
transaction from any session it will cause smmu_fault during next
firmware_boot sequence. Added change to perform vcodec power_collapse
from power_off_iris3_hardware() incase of core_deinit due to PC failure.

Change-Id: I45e32985d87b5cc882c4f96f77d1cabc796e6ba0
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
Signed-off-by: Ankush Mitra <quic_ankumitr@quicinc.com>
2022-11-07 07:59:33 -08:00
Govindaraj Rajagopal
3560442234 video: driver: add resource ops macro support
Added call_res_op() macro and used at all possible
places to avoid invalid pointer dereference issue.

Also added changes to cleanup unused functions.

Change-Id: Id77711ad9eaf7b407208567b0fde1f2693588641
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-10-20 12:18:25 +05:30
Govindaraj Rajagopal
21eb38981e video: driver: reduce device_tree dependency for video
Only keep minimal entries in dtsi, which is essential for
other drivers usage. Move remaining all data into platform
resource file.

Remove device_tree dependency and maintain platform_data
to initialize resources like regulators, interconnects,
clocks, reset_clocks, subcaches and context_banks.

Read static data like freq_table, firmware_name, pas_id
also from platform_data instead of from dtsi.

Change-Id: I73a1df10b92c55e55b23e538aea62598a7250ab4
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-10-18 00:10:19 +05:30
Stanimir Varbanov
21974f4a60 video-driver: Move register manipulation functions
Move register manipulation functions in a common variant
file (msm_vidc_variant).

Change-Id: Ic92a264b47b4d90efcfb4389e30d2749a23f792b
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-26 09:42:41 -07:00
Stanimir Varbanov
8b003fb153 video-driver: Abstract platform resources
Move clocks, gdsc, bandwidth resources out of venus_hfi and
use the ops in variant and venus_hfi code.

Change-Id: I1be77c9d384f4eef2cb8085b75c39dc3fd3eeb86
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-25 19:26:32 -07:00
Stanimir Varbanov
a558b04808 video-driver: Delete not used clock_config_on_enable op
The operation is not used anywhere, delete it.

Change-Id: I4fe7cd41d63ea1b1e0792de6b3e98757860629d8
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-25 14:06:52 -07:00
Stanimir Varbanov
b52b9fd3c1 video-driver: Drop init_interrupt op
The init_interrupt op is not used out of variant, lets
remove the op and used the functions directly.

Change-Id: I8f97cf503503b7f30e824843a5bd9d93c702241a
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-25 14:06:31 -07:00
Stanimir Varbanov
cca051abf4 video-driver: Setup ucregion from boot_firmware op
On all places ucregion setup is done just before calling
boot_firmware, move setup in boot_firmware op and remove
ucregion_setup op.

Change-Id: I91a9a72d3b88eef91e82e19b9d8629e9731211f5
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-25 14:06:03 -07:00
Mahesh Kumar Sharma
7d00efc5dc video: driver: fix encoder output buffer size requirement
For some resolutions memory requirement was coming as 4 * yuv_size
and for CQ/RC_OFF it was 8 * yuv_size. With this fix it will be 
max 2 * yuv_size (+ 25% for 10 bit). Fix typo in 720P resolution check.

Change-Id: Ib5908f1eef8dca92dac46c5c195cd47ba28a4df4
Signed-off-by: Mahesh Kumar Sharma <quic_smahesh@quicinc.com>
2022-08-22 16:00:50 -07:00
qctecmdr
1ee1d9c8e5 Merge "video: driver: define slice delivery as boolean control." 2022-08-03 10:39:31 -07:00