提交線圖

1063 次程式碼提交

作者 SHA1 備註 日期
Deepa Guthyappa Madivalara
3d9c6f17f9 video: driver: Add support for lanai/iris3.3 platform
Add the required config and platform files to enable
lanai platform with iris3.3 VPU.

Change-Id: I441d631b9876705342e34097feff3e5d355d6b71
Signed-off-by: Deepa Guthyappa Madivalara <quic_dmadival@quicinc.com>
2022-09-28 14:36:08 -07:00
qctecmdr
908892519f Merge "video: driver: remove restricted keyword" 2022-09-27 21:46:45 -07:00
Dikshita Agarwal
d861f5047c video: driver: remove restricted keyword
Remove restricted keyword from comments.

Change-Id: Idf7cc0925730f05ba0db371e0fe3dda312a85b79
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-09-27 15:47:20 +05:30
Darshana Patil
1ef323df29 video: driver: buffer flow changes
When client queued a buffer, v4l2 framework
compares the client Dmabuf with the existing
dmabuf in the bufs array at the same index.
If the dmabuf is different then v4l2 framework
would call unmap_dmabuf, detach_dmabuf callbacks
for the old buffer and then calls attach_dmabuf,
map_dmabuf callbacks for the new buffer before
qbuf callback is made to driver. If the dmabuf
is same then qbuf callback will be made directly.

V4l2 framework expects that clients recycles the
same buffers in the same indices so that when
v4l2 framework compares dmabuf it won't unmap
or map buffers.

If client recycle the buffers in different indices
still usecase works but there will be unnecessary
unmap, map overhead will be incurred.

If client does not recycle the buffers at all,
meaning every time client queues new buffers
then special handling is required for decoder
output buffers which are used for reference by
video hardware.If any buffers are used by video
hardware as reference buffers then firmware returns
those buffers with READ_ONLY flag and they are kept
in read_only list and when read_only grows beyond
some limit then driver would ask firmware to release
those READ_ONLY buffers and when firmware responds
driver would delete these READ_ONLY buffers.

Change-Id: I8a0b11c986dd0b9464895498efd8c1831a754198
Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
2022-09-26 17:24:30 -07:00
qctecmdr
08b36416ce Merge "video: driver: modify slice delivery control as boolean control" 2022-09-22 17:43:50 -07:00
qctecmdr
8244c81132 Merge "video: driver: remove input meta via request support" 2022-09-22 17:43:50 -07:00
qctecmdr
786981d774 Merge "video: driver: fix AV1D fence timing failures during flush sequence" 2022-09-21 09:54:45 -07:00
Akshata Sahukar
85d79a7a23 video: driver: remove input meta via request support
remove input meta via request support

Change-Id: If2a504455e1899c4cefb2a9142f7a92db02a45f2
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-09-20 11:07:39 -07:00
Deepa Guthyappa Madivalara
a6337c1460 video: driver: update platform_get_resource to platform_get_irq
Use platform_get_irq api instead of platform_get_resource for Lanai

Change-Id: Ia06e7d5c890f6c7344b53a9f15c0b68b26bcc53e
Signed-off-by: Deepa Guthyappa Madivalara <quic_dmadival@quicinc.com>
2022-09-19 18:24:32 -07:00
Akshata Sahukar
7818456489 video: driver: fix AV1D fence timing failures during flush sequence
Flushed out buffers by driver retain filled length field same
as it was while queued to driver. This is incorrect as it
gives an impression to the client that some data has been
written by driver/firmware. Hence, reset this to 0 while
dequeuing to fix the issue.

Change-Id: Ia2bb86a3462255991d45a1f77cab39a4a0eafd23
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-09-16 12:59:36 -07:00
qctecmdr
b48e799508 Merge "video: driver: Introduce SUPPORTS_REQUESTS cap" 2022-09-16 10:47:04 -07:00
Akshata Sahukar
b1dfbad4a4 video: driver: Introduce SUPPORTS_REQUESTS cap
Introduce SUPPORTS_REQUESTS cap to have different caps support
for upstream and downstream driver.

Change-Id: Ib8bae21ba3fa6d65236954e0728fa30e20d7b375
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-09-13 14:29:18 -07:00
Dikshita Agarwal
9b32ff0498 video: driver: modify slice delivery control as boolean control
Update definition of slice delivery control in v4l2_vidc_extensions.h
to make it a boolean control instead of menu control and use it
accordingly.

Change-Id: I8ad5f5b7088bc01b78560cb40eae7c7d677ce7ce
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-09-12 14:11:16 +05:30
Ashish Patil
03606a7c77 video-driver: dma_buf_vmap() usage changes
Earlier Kernel Version were using struct dma_buf_map 
and latest Kernel using struct iosys_map and 
MODULE_IMPORT_NS(DMA_BUF) to import dma buf namespace

Change-Id: Ida6535fb2e3426b10264efe01e3a343fd3a1e127
Signed-off-by: Ashish Patil <quic_ashpat@quicinc.com>
2022-09-09 15:52:12 -07:00
qctecmdr
e072a88b28 Merge "video: driver: Introduce CAP_FLAG_META flag for metadata caps" 2022-09-08 18:36:14 -07:00
qctecmdr
1bb9c5f525 Merge "video: driver: add support for standard compressed formats" 2022-09-08 18:36:13 -07:00
Akshata Sahukar
6b5c62db0c video: driver: Introduce DEVICE_CAPS cap in core database
Introduce DEVICE_CAPS capability to have different caps support
for upstream and downstream driver.

Change-Id: Ife73ab8c3b6ef9b47ef844883d9fa18e469d9188
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-09-08 16:02:13 -07:00
Dikshita Agarwal
1aedac8e6e video: driver: add support for standard compressed formats
Add support for standard compressed formats in upstream.
remove usage of not supported codecs HEIC and AV1 from
upstream database file.

Change-Id: I11b29990f439dc2b43d5dcdb70a4e7d47bbf3970
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-09-08 16:08:02 +05:30
Akshata Sahukar
f37cc5fe6c video: driver: Introduce CAP_FLAG_META flag for metadata caps
Introduce CAP_FLAG_META flag to differentiate metadata caps
from non metadata caps.

Change-Id: I7a3d2c5fb952e5d829002a04d11fa7b05b2c9297
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-09-06 13:42:20 -07:00
Stanimir Varbanov
2b1146d5cd video-driver: Move three functions to msm_vidc_power.c
Move __lut, __compression_ratio and __dump functions
form venus_hfi.c to msm_vidc_power.c where they belongs.

Change-Id: Iafabf1c61a9602ea9b2c067663e46e12b88266b8
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-26 09:44:02 -07:00
Stanimir Varbanov
07f4bf666c video-driver: The file msm_vidc_bus.h is not used
The file msm_vidc_bus.h is not used, delete it.

Change-Id: I21503a1cfb35bf6e93fe92a5c6a9286d29135e12
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-26 09:42:51 -07:00
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
cf7b4f85c9 video-driver: Move firmware code out of venus hfi
All firmware related code is moved into a firmware file.
This is part of cleanup of venus_hfi.

Change-Id: Ie915e47644dbbbe73c941488fff6db6e40160b90
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-26 09:42:29 -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
Stanimir Varbanov
1020319ca4 video-driver: Move HFI queue functions out of venus_hfi
Split HFI queue functions in separate file. This will
unload venus_hfi and also will make possible to reuse/shared
with other drivers.

Change-Id: I16155e649f216afc6f26db76b565aad28b114cc7
Signed-off-by: Stanimir Varbanov <quic_c_svarba@quicinc.com>
2022-08-25 14:04:51 -07:00
qctecmdr
e77d578972 Merge "video: driver: fix encoder output buffer size requirement" 2022-08-23 21:07:43 -07:00
qctecmdr
ac24ed5217 Merge "video: driver: reset interface queue header for sys error case" 2022-08-23 21:07:43 -07:00
qctecmdr
f7b923fb87 Merge "video: driver: sessions without input data are skipped for power votes" 2022-08-23 21:07:43 -07:00
qctecmdr
bffb7c6070 Merge "msm: vidc: Fix for slice mode configuration" 2022-08-23 21:07:43 -07:00
qctecmdr
9a95bcd6b5 Merge "video-driver: Disabling VSP subcache for Halliday" 2022-08-23 21:07:43 -07:00
qctecmdr
91e54040b8 Merge "video: driver: fixes for upstream/downstream driver compilation" 2022-08-23 14:26:58 -07:00
Sachu George
963e12e58f video-driver: Disabling VSP subcache for Halliday
VSP subcache support is not available in 5.10 kernel.
Hence needs to be disabled for Halliday.

Change-Id: I8e0905d537d8df3c72063b2e8dc5011d8e0ff785
Signed-off-by: Sachu George <quic_sachgeor@quicinc.com>
2022-08-23 13:54:12 -07:00
qctecmdr
d0affa6c7c Merge "video: driver: add dynamic_allowed flag in database" 2022-08-23 11:17:23 -07:00
qctecmdr
7fda1ff3b8 Merge "video: driver: add video vsp subcache id support" 2022-08-23 11:17:23 -07:00
Darshana Patil
c4beadb5d2 video: driver: fixes for upstream/downstream driver compilation
- do not use vidc_v4l2_extensions.h for upstream driver compilation.
- resolve compilation issues in upstream and downstream driver due
  to above change.
- add volatile flag in the database.

Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
Change-Id: I1985cae29a459af2250f7044d85c5cd22cdd68f7
2022-08-22 16:51:31 -07:00
Dikshita Agarwal
90fabfb02b video: driver: remove support for V4L2_EVENT_VIDC_METADATA
remove support for V4L2_EVENT_VIDC_METADATA as it is not
being used.

Change-Id: Ia375d0410d144d2e3b9cd78bc0fde16cfa0d0884
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-08-22 16:50:50 -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
Akshata Sahukar
ec161663ce video: driver: fix hevc codec layer count support
Support only 4 total layers for hevc non vbr rc type session
as per PRD.

Change-Id: Ifc425de75804552717919e6be71788dd59fb086b
Signed-off-by: Akshata Sahukar <quic_asahukar@quicinc.com>
2022-08-22 15:53:08 -07:00
Govindaraj Rajagopal
3c75f5da07 video: driver: reset interface queue header for sys error case
interface queues were allocated only once and reused for entire
lifetime, but un-consumed packets in the queue during sys_error
is leading to undefined behaviour for the next session.

For e.x, after queueing cmd_init, received sys_error, so core
will be deinited and sys_init willbe sent again as part of next
session_open, but FW is consuming 1st cmd_init pkt and sending
init_done but driver is expecting done for 2nd cmd_init, So
i.e treated as fatal and driver is closing the session and
doing core_deinit.

To avoid above mentioned issue, made changes to reset queue hdr
incase of sys_error.

Change-Id: I3ebba24ed4975fbf2b16f914c28b9ae72878fb03
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-08-22 14:53:50 -07:00
Vikash Garodia
8ff4bad25b video: driver: sessions without input data are skipped for power votes
Video driver has a logic to vote for maximum power resources for
initial few frames. If any video session remains within those
initial few frames, the votes calculated would reflect as maximum.
To handle such video sessions, there is another logic to check
if the video session has any input buffer to process. If there
are no input buffers to process for that session, there is no
need to consider that session for power resource voting. Hence
skip the votes aggregation for such sessions during concurrency.

Change-Id: Ib5d678b92a81a48100f404421e9356a7226658b0
Signed-off-by: Vikash Garodia <quic_vgarodia@quicinc.com>
2022-08-22 14:11:08 -07:00
Manikanta Kanamarlapudi
5a0859f15d msm: vidc: Fix for slice mode configuration
When layers are enabled, bitrates are set layerwise.
Need to add the cumulative layer bitrates and calculate
bytes per slice accordingly.

Change-Id: I17616a3b4f73d33c32badbbf8b9aacb60123f54a
Signed-off-by: Manikanta Kanamarlapudi <quic_kmanikan@quicinc.com>
2022-08-22 14:00:42 -07:00
Mahesh Kumar Sharma
e0da5a7e44 video: driver: add video vsp subcache id support
In order to improve video hardware performance, a new BLE is added
in system cache to get additional bandwidth.
To enable new system cache, video sw driver reads device tree entry
and enables it in Video FW.

Change-Id: I20025a8095c9981f8533062bdee9a6952df231a3
Signed-off-by: Mark Bao <quic_mbao@quicinc.com>
Signed-off-by: Mahesh Kumar Sharma <quic_smahesh@quicinc.com>
2022-08-22 12:38:21 -07:00
Darshana Patil
0b49e4ea40 video: driver: use standard EOS event
use standard EOS event instead of private
last flag event.

Change-Id: Iaeb2c57ceb80769de8cf94a63077eddf3710f871
Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
2022-08-16 10:07:52 -07:00
Darshana Patil
87557615b9 video: driver: add dynamic_allowed flag in database
add the missing dynamic_allowed flag for dynamic controls
in the database.

Change-Id: Icbdac824d668f2c0fdd86af8a1e5a4a4dd25a160
Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
2022-08-11 12:19:30 -07:00
Dikshita Agarwal
203f09ac3f video: driver: add mapping for missing colorspace vidc macros
Add mapping for missing vidc macros MSM_VIDC_TRANSFER_UNSPECIFIED
and MSM_VIDC_PRIMARIES_UNSPECIFIED.

Change-Id: I39fc60d98fe9f7c73d91768f5a0eb36e2c72a94c
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-08-10 13:19:26 +05:30
qctecmdr
1ee1d9c8e5 Merge "video: driver: define slice delivery as boolean control." 2022-08-03 10:39:31 -07:00
Dikshita Agarwal
f1a32f5a86 video: driver: define slice delivery as boolean control.
Make slice delivery a boolean control instead of menu.

Change-Id: Iedf8e0df882d61e82661c7f557473d3f7b49215a
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
2022-08-02 12:28:44 +05:30