Commit Graph

2043 Commits

Author SHA1 Message Date
Ayush Kumar
8554f46816 msm: camera: core: Add delay detection support
This changes is to detect workqueue and tasklet
scheduling and execution delay.

CRs-Fixed: 2977775
Change-Id: Ia4b4845a067c22bd1f24bd63a971d103fcfc049c
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
2021-08-11 22:18:10 +05:30
Ayush Kumar
688f87e5e7 msm: camera: req_mgr: Increase one more request to apply in initial sync
For SW sync to work, CRM needs to apply the first 6 requests in
initial sync mode. This change is to increase the count of requests
to be applied in the initial sync mode.

CRs-Fixed: 3000684
Change-Id: Ic35d37ac727fc10ec113dd9f05074cec7a52e39a
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
2021-08-11 19:16:22 +05:30
Gaurav Jindal
d3e1aae5f2 msm: camera: isp: Prevent unclocked access to CSID registers
In some race conditions, CSID registers can be accessed after disabling
the clock. This can result in NOC errors due to unclocked access.
This commit prevents the register access with spin locks.
This commit also moves the halt call of CSID path before unsubcribing
the IRQ.

CRs-Fixed: 3005024
Change-Id: I45bc3410f9562ce328ebe02b39dc63061130faeb
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
2021-08-10 20:37:25 -07:00
Haritha Chintalapati
46d07dd8d8 Merge "msm: camera: isp: Add constraint violation check in vfe bus" into camera-kernel.lnx.5.0 2021-08-10 20:34:31 -07:00
Haritha Chintalapati
ad21805336 Merge "msm: camera: isp: Add support to print illegal programming IRQ errors" into camera-kernel.lnx.5.0 2021-08-10 20:34:17 -07:00
Haritha Chintalapati
8c22a0ca43 Merge "msm: camera: isp: Add decode format1 support for v780" into camera-kernel.lnx.5.0 2021-08-10 20:34:01 -07:00
Karthik Anantha Ram
502a4e954e msm: camera: isp: Add support to update packer format
Add support to update packer format per request.

CRs-Fixed: 2841729
Change-Id: I5d01ea0d8176d8a022bb079a53b6fb218f94b437
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-10 18:47:19 -07:00
Karthik Anantha Ram
488962cfb1 msm: camera: uapi: Add support to update packer format
Add support to re-configure packer format per request.

CRs-Fixed: 2841729
Change-Id: I2df1b523117aa3bafea047aff5e640b94169ad16
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-10 18:35:11 -07:00
Jigar Agrawal
b8951526bf msm: camera: jpeg: Add UAPI support for JPEG retry mechanism
Add uapi structure to add support for enforcing the size
restriction on JPEG thumbnail images.

CRs-Fixed: 2999106
Change-Id: Icee615eb5674b3f0869631a57eed0d46aa6c2799
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-08-10 10:56:10 -07:00
Anand Ravi
b811f12335 msm: camera: isp: Protect recovery callback from stop ioctl using mutex
Since recovery callback happens in workqueue context, it can run in
parallel with stop dev ioctl. This leads to many possible race
conditions. Instead, protect the recovery callback with the same context
mutex as ioctls to prevent parallel execution.

CRs-Fixed: 3003703
Change-Id: I92a635cfaeee4cf09047672a5cb925cf262cd816
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-08-09 11:49:02 -07:00
Anand Ravi
7804729921 msm: camera: isp: Print SFE PP violation info on overflow
SFE should print violation information along with overflow information
when triggered by IFE HW manager to print overflow information.
Otherwise, there are instances where CSID reports overflow due to SFE
violation but SFE is stopped before IRQ can be fired.

This commit also fixes null pointer dereference in SFE irq handlers
caused by 'commit 1c1d221ff7 ("msm: camera: isp: Add support of SFE
HW for v780")'.

CRs-Fixed: 2977145
Change-Id: I974a1afca84740a72916141db6e5fd0aced2d745
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-08-09 11:20:48 -07:00
Anand Ravi
41404d0eef msm: camera: isp: Always disable RX in top half on error
RX disable should be triggered on error in top half even if bottom half
payload is not available.

CRs-Fixed: 2846451
Change-Id: I723e6cac97ab8df4cdda3fd3edb722c581878b5d
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-08-09 11:12:40 -07:00
Chandan Kumar Jha
a09f4b3b38 msm: camera: isp: Add support to print illegal programming IRQ errors
Add support to print illegal programming IRQ errors for 780 CSID.

Illegal programming Could be due to following reasons within a path.

1. User has to program either RAW formats or PAYLOAD on both
for multi VCDT with the second decode format. It can neither be a
mix of these.
2. Say in a multi VCDT situation for an active VC, the programmed value
of DECODE_FORMAT is PAYLOAD_ONLY (0xF), the value of DECODE_FORMAT1
should also be programmed as PAYLOAD_ONLY. Failing this check would
trigger the IRQ.
3. In a similar case, if both VCs and DTs are programmed to be same
values, the DECODE_FORMATs should also match.
4. User has to perform sensor switching with a new RUP. For
this, we need the MUP bit to be programmed along with RUP.
5. Early EOF enabled without VCROP registers programmed could also
trigger this IRQ.

CRs-Fixed: 2948116
Change-Id: Ib8cede8607d52586ef178c14a9a4bfd8d0b0b80e
Signed-off-by: Chandan Kumar Jha <cjha@codeaurora.org>
2021-08-09 00:20:51 -07:00
Chandan Kumar Jha
cf99d6942b msm: camera: isp: Add decode format1 support for v780
Decode format1 is required for payload decoding in
multi VCDT usecase.Format type is packed in 8 bits.

We will get 8 bits value as format type from UMD to
get decode format1.

CRs-Fixed: 2948116
Change-Id: I81bc816c1fc53ff8949d8920d076461ff1895e45
Signed-off-by: Chandan Kumar Jha <cjha@codeaurora.org>
2021-08-09 12:48:16 +05:30
Vikram Sharma
56164d50f1 msm: camera: tfe: rdi packer format fix for mimas 2.0
For Mimas 2.0 TFE RDI port has a width of 128 bit compared
to 64 bit on Mimas 1.0. This change takes care of correct
packer format w.r.t rdi width.

CRs-Fixed: 2982472
Change-Id: I89b16dc517e68e5417ec4683a394b092ff0850f5
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
2021-08-08 22:28:55 -07:00
Savita Patted
8b5f97b80f Merge "msm: camera: isp: Path register structures refactoring" into camera-kernel.lnx.5.0 2021-08-05 18:49:01 -07:00
Savita Patted
90a8a20e2a Merge "msm: camera: cpas: Invoke llcc putd on deinit soc resources" into camera-kernel.lnx.5.0 2021-08-05 18:48:44 -07:00
Savita Patted
67885d1c54 Merge "msm: camera: isp: Configure frame based WM config for PLAIN16" into camera-kernel.lnx.5.0 2021-08-05 18:48:25 -07:00
Savita Patted
4b39865386 Merge "msm: camera: isp: Handle init discard frame config for dynamic switch" into camera-kernel.lnx.5.0 2021-08-05 18:48:08 -07:00
Mukund Madhusudan Atre
24da174459 msm: camera: isp: Add constraint violation check in vfe bus
Earlier, constraint violation was received as part of image size
violation status. Add constraint violation check in vfe bus error
bottom half handler to accommodate changes to the bus irq status
register.

CRs-Fixed: 3005893
Change-Id: I62327b0900ecb3c05cb38a5079d6d9ffb8c5408e
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
2021-08-05 10:36:40 -07:00
Depeng Shao
75a0aff96f msm: camera: reqmgr: Fix trigger count out of bound issue
Since the CAM_TRIGGER_MAX_POINTS equal to CAM_TRIGGER_POINT_EOF,
so we need to use CAM_TRIGGER_MAX_POINTS + 1 to define the
trigger count.

CRs-Fixed: 3007296
Change-Id: Ia0cefd8381417a4b7ecd8636796bf25df705101d
Signed-off-by: Depeng Shao <depengs@codeaurora.org>
2021-08-05 15:27:01 +08:00
Savita Patted
9631f05e75 Merge "msm: camera: common: presil change for soc util" into camera-kernel.lnx.5.0 2021-08-04 22:51:37 -07:00
Savita Patted
bfa1600ccc Merge "msm: camera: cci: Fix CCI Timeout during burst_read concurrency" into camera-kernel.lnx.5.0 2021-08-04 22:51:15 -07:00
Savita Patted
39dea3bf5f Merge "msm: camera: isp: Expanded address support for v780" into camera-kernel.lnx.5.0 2021-08-04 22:50:52 -07:00
Karthik Anantha Ram
2dfbe62d1f msm: camera: isp: Handle init discard frame config for dynamic switch
In case of dynamic switch shdr use-case ensure discard config is only
applied on number of starting exposures. The change also avoids
programming fetch enable/disable via AHB if already programmed
via CDM at stream on.

CRs-Fixed: 2841729
Change-Id: I36719ca447eeb890f0059489709ab11dcc37dd38
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-04 10:32:42 -07:00
Karthik Anantha Ram
708d55f188 msm: camera: cpas: Invoke llcc putd on deinit soc resources
Invoke llcc_slice_putd during soc deinit.

CRs-Fixed: 2841729
Change-Id: If9479a60cbf917c0701f10bf36e6856978e8100b
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-02 16:59:17 -07:00
Karthik Anantha Ram
7d98cf34e9 msm: camera: isp: Configure frame based WM config for PLAIN16
Configure WM config to frame based mode for PLAIN16 formats in
case of SFE RDI WMs.

CRs-Fixed: 2841729
Change-Id: I8d21e593d13d46486fe3a1c03b51282efad015f0
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-08-02 16:56:15 -07:00
Gaurav Jindal
87adb08d09 msm: camera: isp: Path register structures refactoring
Merge RDI and IPP path register structures into
common path register structure.

CRs-Fixed: 2948116
Change-Id: I55c9c10e7b5d3d0b975c9168ef3165f604e523e1
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
Signed-off-by: Chandan Kumar Jha <cjha@codeaurora.org>
2021-08-02 18:17:20 +05:30
Camera Software Integration
e3c9d6d1e6 Merge "msm: camera: csiphy: Fix presil crash due to readl in tpg" into camera-kernel.lnx.5.0 2021-07-30 17:36:31 -07:00
Camera Software Integration
8d98c4afaf Merge "msm: camera: isp: Check for CAMIF SOF as secondary event" into camera-kernel.lnx.5.0 2021-07-30 17:36:21 -07:00
Camera Software Integration
7d06d880aa Merge "msm: camera: isp: Handle processing RUP_DONE prior to SOF" into camera-kernel.lnx.5.0 2021-07-30 17:36:10 -07:00
Camera Software Integration
bbf79daec2 Merge "msm: camera: isp: Improvements to logging in VFE and CSID" into camera-kernel.lnx.5.0 2021-07-30 17:35:12 -07:00
Camera Software Integration
522aa191d5 Merge "msm: camera: common: Add condition in Kbuild to compile presil code" into camera-kernel.lnx.5.0 2021-07-30 17:35:00 -07:00
Camera Software Integration
60fe99a6d3 Merge "msm: camera: common: Change judgement condition" into camera-kernel.lnx.5.0 2021-07-30 17:34:48 -07:00
Camera Software Integration
d53c3ae878 Merge "msm: camera: cci: Enhance burst read timing" into camera-kernel.lnx.5.0 2021-07-30 17:34:32 -07:00
Mukund Madhusudan Atre
9133c767b4 msm: camera: csiphy: Fix presil crash due to readl in tpg
Register read writes are expected to go through wrapper
functions in presil so that they can be overridden by presil
code. Change register read during tpg start to use this wrapper.

CRs-Fixed: 2932495
Change-Id: Ib72f2de381e096bde146e4fb1ff8f5187eaa5717
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
2021-07-29 16:11:18 -07:00
Karthik Anantha Ram
451df98c68 msm: camera: isp: Check for CAMIF SOF as secondary event
CAMIF SOF is subscribed as secondary event, change INPUT SOF
check to CAMIF SOF.

CRs-Fixed: 2986303
Change-Id: I0416c35c437edf75e86c3e6b0852ee1943415d2b
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-07-29 11:25:50 -07:00
Camera Software Integration
32701c91b2 Merge "msm: camera: sync: Append sync obj's name in log" into camera-kernel.lnx.5.0 2021-07-28 20:37:52 -07:00
Camera Software Integration
4a203b01d7 Merge "msm: camera: isp: Logging improvements to ISP context" into camera-kernel.lnx.5.0 2021-07-28 20:37:43 -07:00
Camera Software Integration
5872617883 Merge "msm: camera: isp: Improve isp context debug capability" into camera-kernel.lnx.5.0 2021-07-28 20:37:34 -07:00
Camera Software Integration
a85269e2e9 Merge "msm: camera: icp: allow icp debug clock for debug purpose" into camera-kernel.lnx.5.0 2021-07-28 20:37:13 -07:00
Suraj Dongre
f037f5b9fe msm: camera: common: Add condition in Kbuild to compile presil code
Based on arch, config flag can be set for presil and when enabled,
presil code will be compiled.

CRs-Fixed: 2932495
Change-Id: Iabf1a74be3582d0b84b70777e406b4ce02218220
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
Signed-off-by: Suraj Dongre <sdongre@codeaurora.org>
2021-07-28 11:15:40 -07:00
Suraj Dongre
d6e8c46024 msm: camera: common: presil change for soc util
Add code to call presil apis related to IRQ and
reg base remap.

CRs-Fixed: 2932495
Change-Id: Ibe3c4da806bfe84c306bc71bfe2150e2caac55b1
Signed-off-by: Suraj Dongre <sdongre@codeaurora.org>
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
2021-07-28 11:07:31 -07:00
Haritha Chintalapati
854ef5bbec Merge "msm: camera: common: Append workq name in log" into camera-kernel.lnx.5.0 2021-07-27 22:12:54 -07:00
Haritha Chintalapati
2c70bb0fa0 Merge "msm: camera: reqmgr: Notify devices on link stall" into camera-kernel.lnx.5.0 2021-07-27 22:10:12 -07:00
Haritha Chintalapati
ecb3d1cd6c Merge "msm: camera: icp: Add WD clear logic for lx7" into camera-kernel.lnx.5.0 2021-07-27 22:09:56 -07:00
Haritha Chintalapati
5971e01fa7 Merge "msm: camera: reqmgr: check link state before taking mutex" into camera-kernel.lnx.5.0 2021-07-27 22:09:31 -07:00
Haritha Chintalapati
24a017483d Merge "msm: camera: isp: Enable IFE Bus violation IRQ" into camera-kernel.lnx.5.0 2021-07-27 22:09:02 -07:00
Haritha Chintalapati
e15669839b Merge "msm: camera: csiphy: Enhance the csiphy reg dump" into camera-kernel.lnx.5.0 2021-07-27 22:08:51 -07:00
Haritha Chintalapati
ed9a69cf4b Merge "msm: camera: csiphy: Rearrange csiphy debugfs" into camera-kernel.lnx.5.0 2021-07-27 22:08:33 -07:00