Commit Graph

2109 Commits

Author SHA1 Message Date
Camera Software Integration
3bc1aac82e Merge "msm: camera: sync: Prevent OOB access of sync name" into camera-kernel.lnx.5.0 2021-09-03 14:29:59 -07:00
Camera Software Integration
6f1081755e Merge "msm: camera: reqmgr: Prevent session deadlock" into camera-kernel.lnx.5.0 2021-09-03 14:29:48 -07:00
Camera Software Integration
f132db758a Merge "msm: camera: csiphy: Add more datarate setting ranges" into camera-kernel.lnx.5.0 2021-09-03 14:29:36 -07:00
Camera Software Integration
b859cf3ee5 Merge "msm: camera: csiphy: update the csiphy driver for v2 device" into camera-kernel.lnx.5.0 2021-09-03 14:29:26 -07:00
Camera Software Integration
60a7a5cb46 Merge "msm: camera: common: Send 0 rate to MMRM for src clocks" into camera-kernel.lnx.5.0 2021-09-03 14:28:35 -07:00
Jigar Agrawal
0225f24ddd msm: camera: csiphy: Update the datarate settings for csiphy
Update the csiphy datarate setting for 2.6gsps slab.

CRs-Fixed: 3022770
Change-Id: I10357104d9c0342a942568753ca12bc2b6ff0d60
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-09-03 08:43:20 -07:00
Vikram Sharma
59830712cd msm: camera: cre: Fix typo error for copying blob args
This change fixes the typo error which was there while copying the blob
args. Also fix typo in cam_cre_validate_acquire_res_info for plain128.

CRs-Fixed: 3027075
Change-Id: Ibd163e0719e93a3159ae5cbbd84ce835e85bb8cc
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
Signed-off-by: Wyes Karny <wkarny@codeaurora.org>
2021-09-03 17:58:55 +05:30
Karthik Anantha Ram
5c9aac95eb msm: camera: isp: Update latency buffer allocation in header
Based on the chipset update the latency buffer alloc config for
SFE RD. This value can obtained from CAMNOC HPG for a given target.

CRs-Fixed: 2841729
Change-Id: I86acf62e62edc473231f6fe75d9d4780a7f099ae
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-09-02 16:19:38 -07:00
Camera Software Integration
c828b82890 Merge "msm: camera: isp: Update virtual frame for IFE/SFE clients" into camera-kernel.lnx.5.0 2021-09-02 14:22:58 -07:00
Camera Software Integration
6f4e582d55 Merge "msm: camera: ope: Fix uninitialized variable access" into camera-kernel.lnx.5.0 2021-09-02 14:22:41 -07:00
Camera Software Integration
a24033c339 Merge "msm: camera: isp: Correct HBI VBI print and format measure" into camera-kernel.lnx.5.0 2021-09-02 14:18:44 -07:00
Camera Software Integration
49fc897f56 Merge "msm: camera: isp: Add check for bus ports before sending bw vote to hw" into camera-kernel.lnx.5.0 2021-09-02 14:18:34 -07:00
Karthik Anantha Ram
5c3b688397 msm: camera: isp: Program rup/aup for scratch only at run time
Avoid programming aup/rup at stream on after scratch buffer
programming on occasions where there is no ePCR. At stream on,
INIT packet adds rup/aup.

CRs-Fixed: 2841729
Change-Id: Ic045c4917c7a1cebacb0a331a7c3ade16726e267
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-09-02 10:43:12 -07:00
Karthik Anantha Ram
c87ae52bc1 msm: camera: isp: Skip exposure config for resources with no read
As opposed to failing the cache config call for resources that
do not have a RM, skip the config and continue. Also make the
scratch config flag per resource as opposed to one for all 3 RDIs.

CRs-Fixed: 3007750
Change-Id: I64efd5af0dd292a8687ad22cea7672e1d423339b
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-09-02 10:41:57 -07:00
Jigar Agrawal
6c439c1a5a msm: camera: csiphy: Add more datarate setting ranges
Add more datarate specific setting ranges to cover the
finer gsps ranges. Dump all the common status registers
on the error rather than just the irq status registers.

CRs-Fixed: 3022770
Change-Id: I6dc5e8d695a40c1633c054e5420084f1ec771485
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-09-01 21:38:37 -07:00
Jigar Agrawal
7eff3cb4b6 msm: camera: csiphy: update the csiphy driver for v2 device
Move the flag which decides whether to program the common
registers for csiphy for all the phy devices to dtsi file.
Common registers sequence should not be programmed for all
the Csiphys during stream on for SM8450 v2 device.

CRs-Fixed: 3020245
Change-Id: I91e6bb786868c1aae165c97751663593e46b8c5b
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-09-01 21:29:36 -07:00
Mulugeta Engdaw
5bfdde5fb3 msm: camera: common: Add QMAA compliance to camera dlkms
Disable camera module during BU that is not ready for
compiling on new targets for QMAA.

CRs-Fixed: 3027651
Change-Id: I26fb7f51caddb342fc9a50f2c482362e36dae015
Signed-off-by: Mulugeta Engdaw <mengdaw@codeaurora.org>
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
2021-09-01 11:14:23 -07:00
Anand Ravi
22097757a8 msm: camera: reqmgr: Fix pagefault in workqueue get task
Protect taskpool memory free operation with workqueue lock to prevent
use after free issues.

CRs-Fixed: 3019429
Change-Id: I0282e01e093f80578c5058a41823036370f5a88a
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-09-01 10:45:34 -07:00
Karthik Anantha Ram
5a09c81180 msm: camera: isp: Change format specifier for hbi-vbi print
Print HBI-VBI in hex for better readability.

CRs-Fixed: 2841729
Change-Id: Ic3d232cca5a2547cc6a361b67ab3cbd8bed000cc
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-09-01 10:24:53 -07:00
Ayush Kumar
7b9703b0db msm: camera: req_mgr: Apply lower pd request in sync
This change help to aply request for lower pd device in sync mode
even if next open request is not avaiable at CRM.

CRs-Fixed: 3017979
Change-Id: Idfae0438d53e61f49c30f205357d5826dd943daa
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
2021-09-01 09:06:52 -07:00
Camera Software Integration
bb15434c6d Merge "msm: camera: isp: Ignore CSID errors after stop command is issued" into camera-kernel.lnx.5.0 2021-08-31 19:09:17 -07:00
sokchetra eung
b5bec7886f msm: camera: reqmgr: Prevent session deadlock
Releasing session lock before unlink and acquiring
it immediately after to allow workq to be done. Check
link state after acquiring session lock in process_
req to return if link is IDLE.

CRs-Fixed: 3003287
Change-Id: Ie7a8ffc4edcb123db290d6da047d748b3e99d68b
Signed-off-by: sokchetra eung <eung@codeaurora.org>
2021-08-31 13:52:27 -07:00
Karthik Anantha Ram
1b34b6460d msm: camera: common: Send 0 rate to MMRM for src clocks
Send clock rate as 0 for src clocks to MMRM, when disabling
the clock. This will help MMRM in peak overshoot computation.

CRs-Fixed: 2841729
Change-Id: I048b530fb620f0e47e1596f31e2ca12ff43bb471
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-31 12:10:24 -07:00
Alok Chauhan
35c1f46e6b msm: camera: ope: Fix uninitialized variable access
Update ope pf dump function for uninitialized variables
access.

CRs-Fixed: 3020020
Change-Id: I7a996b15c8fe48297bcd160be3dbf4c7b65dc41d
Signed-off-by: Alok Chauhan <alokc@codeaurora.org>
2021-08-31 10:24:12 -07:00
Trishansh Bhardwaj
0d847c06fe msm: camera: sync: Prevent OOB access of sync name
Issue:
strlcpy calls strlen on src ptr. If src is not NULL terminated then OOB
access will occur in below stack.
  strlen
  strlcpy
  cam_sync_init_row
  cam_sync_handle_create
  cam_sync_dev_ioctl

Fix:
Pad user-space supplied name with NULL.

CRs-Fixed: 3010262
Change-Id: Ib5c2fbfe395025ec05e0bb2980f86111e95ff54c
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
2021-08-31 10:24:05 -07:00
Karthik Anantha Ram
e1bbaf8a9d msm: camera: isp: Update virtual frame for IFE/SFE clients
Enable virtual frame based on WM per request config.

CRs-Fixed: 2841729
Change-Id: Ic4abca2a95c4a0007ce4365accf19b09aef43e38
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-31 08:15:24 -07:00
Gaurav Jindal
b4a6a49012 msm: camera: isp: Correct HBI VBI print and format measure
This commit fixes mismatch between number of format specifier
and number of arguments while printing the HBI and VBI values.
Also, it swaps the actual and expected frames while printing
format measure values.

CRs-Fixed: 3026328
Change-Id: Idf8b5ec75c1fb2058d046a193282bd3c66057b72
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-31 17:09:21 +05:30
Camera Software Integration
110420ce29 Merge "msm: camera: isp: Correct the condition for violation print loop" into camera-kernel.lnx.5.0 2021-08-30 17:45:55 -07:00
Camera Software Integration
0f02a1e925 Merge "msm: camera: isp: Associate IFE CDM user data with context" into camera-kernel.lnx.5.0 2021-08-30 17:45:37 -07:00
Mukund Madhusudan Atre
4ba6673aae msm: camera: isp: Add check for bus ports before sending bw vote to hw
Currently, bw vote is sent directly to top layer for each base index.
In cases where no bus reador write port is acquired, the bw vote will
be all zeros for that core, and can be interpreted as error. check
acquire of bus ports before sending bw vote to hw.

CRs-Fixed: 3020236
Change-Id: I1e9c1ae1fde0435f4defbd2f065a53190fd2c32a
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
2021-08-30 14:10:35 -07:00
Camera Software Integration
918ec12e6f Merge "msm: camera: req_mgr: Table info dump removed" into camera-kernel.lnx.5.0 2021-08-27 17:59:39 -07:00
Camera Software Integration
bc9f7aac07 Merge "msm: camera: isp: Distinguish between write and read secure mode cmds" into camera-kernel.lnx.5.0 2021-08-27 17:59:11 -07:00
Anand Ravi
5ed072bb22 msm: camera: isp: Ignore CSID errors after stop command is issued
When CSID stop commmand is issued before sensor is streamed off,
hardware might raise spurious errors that should be ignored.

CRs-Fixed: 2846451
Change-Id: Icece55fcba606697851a335d5a7a29256236017a
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-08-27 10:50:31 -07:00
Savita Patted
70753459bd Merge "msm: camera: cci: CCI logging improvement" into camera-kernel.lnx.5.0 2021-08-26 19:51:27 -07:00
Gaurav Jindal
bf02458248 msm: camera: isp: Correct the condition for violation print loop
This commit changes the termination condition while printing the
violation in IFE. Current condition results in infinite loop.

Change-Id: Id1d1d0dbffa3e3a8065745aebe7aa35f5d2ce52e
CRs-Fixed: 3020683
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-26 17:27:25 +05:30
Gaurav Jindal
6efe919f4c msm: camera: isp: Associate IFE CDM user data with context
In scheduling delays or race conditions, it has been observed that
cookie value and the request id in userdata returned from CDM
do not match. This can happen due to CDM worker threads getting
delayed. Userdata attached with the CDM is the pointer in the
request. By the time, the cdm callback is received there is a
possibility that the request data has been reset and that request
node being re-used for another request. This can cause issues
particularly in race conditions.
To handle the condition, this commit associates the userdata and
with the context. Also, while submitting the request, the request
id is saved with context, which can be compared during the cdm
callback.

Change-Id: If09bc823602621e7a5e48e8eeb843c4abbeca016
CRs-Fixed: 3015161
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-26 17:22:56 +05:30
Savita Patted
946cfd80fe Merge "msm: camera: common: Add Minidump changes for NRT devices" into camera-kernel.lnx.5.0 2021-08-24 20:02:04 -07:00
Savita Patted
09f1d471b3 Merge "msm: camera: common: Add camera minidump changes" into camera-kernel.lnx.5.0 2021-08-24 20:01:45 -07:00
Wang Kan
e935575398 msm: camera: cci: CCI logging improvement
CCI logging improvement to print the runnning
master and queue.

CRs-Fixed: 3014893
Change-Id: I65a0e2797956a66fe50660290a4f2ccb74c60cbe
Signed-off-by: Wang Kan <wkan@codeaurora.org>
2021-08-24 13:25:15 +08:00
Gaurav Jindal
2f5933b075 msm: camera: common: Add Minidump changes for NRT devices
Based on targets, in case of device crash, in place
of complete memory dump, mini dump can be extracted.
This commit adds changes in context utils for NRT devices
and in ICP, JPEG drivers.

CRs-Fixed: 2993116
Change-Id: I7c4af2cdf44713f741d3d772316080124e8a9a7f
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-22 21:19:33 -07:00
Gaurav Jindal
d266ac8813 msm: camera: common: Add camera minidump changes
Based on targets, in case of device crash, in place
of complete memory dump, mini dump can be extracted.
This commit adds changes for basic framework
to interact with base kernel for mini dump.
This commit also adds changes for ISP, CRM, SMMU and
Memory Manager.

CRs-Fixed: 2993116
Change-Id: I02620bd79ee2f84847381509a5eb030ffb1ca9d4
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-22 12:00:40 -07:00
Ayush Kumar
f428aed04a msm: camera: req_mgr: Handle apply failure
Handle apply failure in workqueue. Add recovery mechanism
to recovery in req_mgr to handle frame out of sync issue.

CRs-Fixed: 2997164
Change-Id: I0e04571b3a31d7a879a7aa579c1f0be51c233277
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
2021-08-19 07:54:50 -07:00
Savita Patted
4baa6ec428 Merge "msm: camera: jpeg: Release the failed request for jpeg" into camera-kernel.lnx.5.0 2021-08-18 21:49:51 -07:00
Savita Patted
4250340b1a Merge "msm: camera: csiphy: Rearrange the CSIPHY bring up sequence" into camera-kernel.lnx.5.0 2021-08-18 21:49:36 -07:00
Savita Patted
fa9c1dd507 Merge "msm: camera: flash: Make warning non fatal for early PCR" into camera-kernel.lnx.5.0 2021-08-18 21:49:19 -07:00
Savita Patted
b07d7da652 Merge "msm: camera: reqmgr: Fix trigger count out of bound issue" into camera-kernel.lnx.5.0 2021-08-18 00:18:51 -07:00
Savita Patted
05d72291f7 Merge "msm: camera: core: Add delay detection support" into camera-kernel.lnx.5.0 2021-08-18 00:18:33 -07:00
sokchetra eung
64ff6b3ffc msm: camera: req_mgr: Table info dump removed
Remove dump_tbl_info function and all of its
invocations in CRM to prevent dumping all the
handle info when holding the spin lock.

CRs-Fixed: 3014074, 3014073
Change-Id: Ie98bafb489fc0d1f2d75cf0f3f08efb48d9b4062
Signed-off-by: sokchetra eung <eung@codeaurora.org>
2021-08-17 20:58:29 -07:00
Jigar Agrawal
7aaba7949c msm: camera: jpeg: Release the failed request for jpeg
Fix the incorrect implementation which keeps the failed
thumbnail requests in the active request list and do not
free up.

CRs-Fixed: 2999106
Change-Id: I8f34d8b24aa1e0e3afb1452cffbf5a4113e0dc0e
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-08-17 14:32:51 -07:00
Camera Software Integration
2c94f5fd9a Merge "msm: camera: isp: Add infra to select CC testbus for 780 sfe" into camera-kernel.lnx.5.0 2021-08-16 21:03:25 -07:00