Graf commitů

2422 Commity

Autor SHA1 Zpráva Datum
Camera Software Integration
01d287416d Merge "msm: camera: utils: Use mmrm api to check if mmrm is supported" into camera-kernel.lnx.5.0 2021-11-24 19:55:27 -08:00
Vikram Sharma
afac5c5a18 msm: camera: isp: Fix PPI index based on the phy selection
1) There is one to one mapping for ppi index with phy index
but phy select is not always equal to phy number,for some
targets "phy_sel = phy_idx + 1", and for some targets it is
"phy_sel = phy_idx", ppi_index should be updated accordingly.
2) Updated to configure ppi cfg register as.
 for cphy, disable dphy in config register.
 for dphy, do nothing (both cphy and dphy will be selected).
 then enable all lanes.

CRs-Fixed: 3057665
Change-Id: I1d5d66034a5563b5adcb8163acf9a668d10d4a19
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
2021-11-23 16:00:57 +05:30
Karthik Anantha Ram
ec9c3c2d48 msm: camera: isp: Enable error recovery block for PPP
In CSID enable error recovery block for PPP. Configure error
recovery to freeze mode.

CRs-Fixed: 3077774
Change-Id: I8c107396521a7a6475c648362157acdba44bf1d4
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
2021-11-18 13:37:11 -08:00
Sridhar Gujje
137172a663 Merge tag 'camera-kernel.lnx.5.0-211112' into camera-kernel.lnx.6.0
FF: Upto PC675: Merge tag 'camera-kernel.lnx.5.0-211112' into 6.0

* tag 'camera-kernel.lnx.5.0-211112':
  msm: camera: isp: Report frame timing events in correct sequence
  msm: camera: icp: Remove extra IPE/BPS core reset reg read
  msm: camera: cpas: camnoc_reg_offset_fix
  msm: camera: icp: Fix HFI init sequence
  msm: camera: isp: Reset rdi only flag
  msm: camera: sensor: Add support for CSIPHY 2.1.3
  msm: camera: isp: Recover missed SOF timestamp
  msm: camera: isp: Update internal recovery scheme
  msm: camera: flash: Add support for qup i2c flash
  msm: camera: isp: Only realtime context can pause CRM timer
  msm: camera: isp: Add handling for flush in flushed state
  msm: camera: isp: Add support for IFE scratch buffer

Change-Id: Ib88385e1287b0fc9dd5da877487d9b6982aa364d
Signed-off-by: Sridhar Gujje <sgujje@codeaurora.org>
2021-11-18 17:43:03 +05:30
Karthik Anantha Ram
40fc62f499 msm: camera: isp: Handle IRQ delays for offline streams
Update ISP offline state machine, to ensure any IRQ scheduling
issues would not lead to complete stalling of the stream.

CRs-Fixed: 3068998
Change-Id: I116019e4963f93c28bcfb1f09c5278f478961a5d
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-11-18 19:06:08 +08:00
Depeng Shao
997395bd54 msm: camera: isp: Handle deferred buf done for bubble case
Sometimes we already get all the buf done before the bubble
is detected, so we also need to handle the deferred buf done
when the bubble is detected, otherwise, the bubble request
can't be finished.

CRs-Fixed: 3066543
Change-Id: Ied46ad0a5efe3a7d8132bc9560ae3f35d69fee89
Signed-off-by: Depeng Shao <depengs@codeaurora.org>
2021-11-16 17:01:17 +08:00
Karthik Anantha Ram
105075926c msm: camera: tfe: Update arguments to addIO util
Update scratch buf arguments in TFE HW manager for addIO util.

CRs-Fixed: 3045706
Change-Id: Iaa7f47c1c67045d0427fddda64fa1414dd55ca9b
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-11-15 12:32:28 -08:00
Savita Patted
ac3b745e47 Merge "msm: camera: icp: Remove extra IPE/BPS core reset reg read" into camera-kernel.lnx.5.0 2021-11-12 17:38:38 -08:00
Savita Patted
f94cb9c0dd Merge "msm: camera: cpas: camnoc_reg_offset_fix" into camera-kernel.lnx.5.0 2021-11-12 17:37:20 -08:00
Savita Patted
0ad4a3a10e Merge "msm: camera: isp: Report frame timing events in correct sequence" into camera-kernel.lnx.5.0 2021-11-12 17:37:00 -08:00
Jigarkumar Zala
1a2540f2f4 msm: camera: flash: Correct log location
Flash acquire logs with device handle is getting printed at wrong
place. This change move acquire logging after succesful acquire
of flash hw.

CRs-Fixed: 3048249
Change-Id: Ibe5071c963faad87585e7ead74e4e41de0d2ddd4
Signed-off-by: Jigarkumar Zala <jzala@codeaurora.org>
2021-11-12 15:18:32 -08:00
Camera Software Integration
23448296de Merge "msm: camera: common: Remove QMAA flag check from camera-kernel" into camera-kernel.lnx.6.0 2021-11-12 00:21:16 -08:00
Savita Patted
1b13715a6e Merge "msm: camera: icp: Fix HFI init sequence" into camera-kernel.lnx.5.0 2021-11-11 18:37:18 -08:00
Savita Patted
b502e34473 Merge "msm: camera: sensor: Add support for CSIPHY 2.1.3" into camera-kernel.lnx.5.0 2021-11-11 18:37:08 -08:00
Savita Patted
4eb6436d98 Merge "msm: camera: isp: Recover missed SOF timestamp" into camera-kernel.lnx.5.0 2021-11-11 18:22:48 -08:00
Savita Patted
f2f3189463 Merge "msm: camera: isp: Update internal recovery scheme" into camera-kernel.lnx.5.0 2021-11-11 18:22:38 -08:00
Savita Patted
e8253ce8cd Merge "msm: camera: isp: Add support for IFE scratch buffer" into camera-kernel.lnx.5.0 2021-11-11 18:22:26 -08:00
Savita Patted
37b92699e1 Merge "msm: camera: isp: Only realtime context can pause CRM timer" into camera-kernel.lnx.5.0 2021-11-11 18:22:12 -08:00
Savita Patted
ba6a884318 Merge "msm: camera: isp: Reset rdi only flag" into camera-kernel.lnx.5.0 2021-11-11 18:22:01 -08:00
Savita Patted
fed17f2312 Merge "msm: camera: isp: Add handling for flush in flushed state" into camera-kernel.lnx.5.0 2021-11-11 18:21:50 -08:00
Sridhar Gujje
f8fb89e544 Merge tag 'camera-kernel.lnx.5.0-211105' into camera-kernel.lnx.6.0
FF: Upto PC669: Merge tag 'camera-kernel.lnx.5.0-211101.1' into 6.0

* tag 'camera-kernel.lnx.5.0-211105':
  msm: camera: isp: Enable line done config for SFE RDI0-2
  msm: camera: smmu: Add support for 36 bit address space
  msm: camera: cpas: Disable ICP QoS registers for kalama
  msm: camera: isp: Update RM stride correctly at stream on
  msm: camera: sensor: Add support for CSIPHY TPG 1.2
  msm: camera: isp: Add header file VFE and CSID for Cape
  msm: camera: cpas: Add support for Cape Camera
  msm: camera: sensor: Add support for CSIPHY 2.1.1
  msm: camera: common: Add path for ubwc and linear
  msm: camera: common: Add Kalama make configuration
  msm: camera: smmu: Moves custom smmu API's to cam_compat
  msm: camera: common: Remove return from debugfs_create_bool
  msm: camera: mem_mgr: Add dma_buf_vmap to cam_compat
  msm: camera: custom: Move include to cam_compat
  msm: camera: req_mgr: Update list_head to const
  msm: camera: common: DDR type selection deprecation
  msm: camera: csid: correction for printing long and short packet info
  msm: camera: isp: Refactor csid get rdi format function
  msm: camera: isp: Print additional debug info in case of csid errors

Change-Id: I46f3c1c34c2db76436ad02a30268e4c6f9a845b3
Signed-off-by: Sridhar Gujje <sgujje@codeaurora.org>
2021-11-11 17:05:31 +05:30
Anand Ravi
a3632ffe16 msm: camera: isp: Report frame timing events in correct sequence
Due to interrupt delays, when VFE top processes the interrupt registers
it might see EPOCH and EOF of frame n along with SOF of frame n+1. The
current logic is based on IRQ controller priority and hence will report
SOF of frame n+1 before EPOCH of frame n. This can result in ISP context
reporting SOF timestamp of frame n+1 for both frame n and frame n+1.

In order to report the events in the order that they occurred, we
maintain a state machine in VFE top to keep track of the last seen
event. This helps detect any missing IRQs and also warn when such
interrupt delays are observed.

The state machine logic is only able to handle delays less than 1 frame.
For example, EPOCH of frame n+1 occurs before VFE top has read EPOCH of
frame n, there is no way to tell that this is the case from the
interrupt registers.

CRs-Fixed: 3067696
Change-Id: I061732c20ff23ca9394ae9844d50729476ad07b5
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-11-10 17:24:13 -08:00
sokchetra eung
26855c8a9a msm: camera: icp: Remove extra IPE/BPS core reset reg read
Remove regs reread of cdm_irq_status and top_irq_status
after finishing read poll of the regs to avoid false
errors in core reset of IPE and BPS.

CRs-Fixed: 3071147
Change-Id: Ie4d65a7b527b025b623d365c77361e3db9ae89be
Signed-off-by: sokchetra eung <eung@codeaurora.org>
2021-11-10 10:57:11 -08:00
Shravan Nevatia
d841951985 msm: camera: sensor: Add support for CSIPHY fuse
Add support to disable the 5th CSIPHY based on
the CSIPHY SW fuse register bit.

Change-Id: Iae9dd7df0c0277eb48a258c91502390d042c9c43
CRs-Fixed: 3071805
Signed-off-by: Shravan Nevatia <quic_snevatia@quicinc.com>
2021-11-10 02:50:39 -08:00
Vikram Sharma
a80618bcb2 msm: camera: utils: Use mmrm api to check if mmrm is supported
Targets which use same SPF with CONFIG_MMRM enabled - but one
chipset need to use mmrm, other doesn't need. In such cases,
calling this mmrm API helps to differentiate the flow.
Returns false if mmrm is not supported and true if mmrm is
supported.

CRs-Fixed: 3066104
Change-Id: I11ad3c02e66575905a01e1eb0b6a8e053acfbe46
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
2021-11-09 21:46:11 -08:00
Depeng Shao
9bde405759 msm: camera: isp: Add more deferred buf done support
The reg upd and buf done irq may be got earlier
than the request is applied and before req is
added to wait req list, then these irq will
be dropped in current logic, then the req can't
be finished. This change stores the buf done as
deferred buf done in case of missing the buf done.

CRs-Fixed: 3063894
Change-Id: If0e2dbbc1ac033c13386ef06fda51736e4dbbf3b
Signed-off-by: Depeng Shao <depengs@codeaurora.org>
2021-11-10 12:56:30 +08:00
Savita Patted
258defb7e2 Merge "msm: camera: flash: Add support for qup i2c flash" into camera-kernel.lnx.5.0 2021-11-09 11:29:28 -08:00
Karthik Jayakumar
9d1844b4c8 msm: camera: common: Remove QMAA flag check from camera-kernel
QMAA flag check only applies in the Android build system.
It's primarily meant for controlling whether or not certain
UMD libraries are enabled in the compilation.

Change-Id: I295df2b02bbdf80b26783441908807f7309f148e
Signed-off-by: Karthik Jayakumar <kjayakum@codeaurora.org>
2021-11-09 09:48:07 -08:00
Vikram Sharma
5a84ddd89d msm: camera: cpas: camnoc_reg_offset_fix
Update camnoc register offsets for diwali camera.

CRs-Fixed: 3066104
Change-Id: Ifbbbde90d9620f7c5851d043af9680d902a3310d
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
2021-11-09 01:15:18 -08:00
Karthik Anantha Ram
bd10cccbc4 msm: camera: icp: Fix HFI init sequence
As part of HFI INIT ensure all CSR registers are configured prior
to setting INIT_REQUEST. Also monitor the INIT RESPONSE status
for 32 bits as opposed to 1 bit which will result in reading
a false value for FW error codes > 1.

CRs-Fixed: 3070374
Change-Id: Ib32f1cdf05c524072e5d6e55773351e95c9082a8
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
2021-11-08 15:06:44 -08:00
Depeng Shao
b50cedbfd7 msm: camera: isp: Reset rdi only flag
We will get wrong rdi only flag if we don't reset the flag.
So this change resets the rdi only flag during stopping resource.

CRs-Fixed: 3069713
Change-Id: If06ea32c3f9b5dbfa2f71da1496577c31b67b8c8
Signed-off-by: Depeng Shao <quic_depengs@quicinc.com>
2021-11-06 20:38:07 +08:00
Savita Patted
b2f122bb8b Merge "msm: camera: isp: Enable line done config for SFE RDI0-2" into camera-kernel.lnx.5.0 2021-11-05 19:01:20 -07:00
Savita Patted
6d69d3250b Merge "msm: camera: isp: Update RM stride correctly at stream on" into camera-kernel.lnx.5.0 2021-11-05 19:01:10 -07:00
Savita Patted
d8b7b5f0a9 Merge "msm: camera: sensor: Add support for CSIPHY TPG 1.2" into camera-kernel.lnx.5.0 2021-11-05 18:48:25 -07:00
Savita Patted
ec5830edae Merge "msm: camera: sensor: Add support for CSIPHY 2.1.1" into camera-kernel.lnx.5.0 2021-11-05 18:42:36 -07:00
Savita Patted
4b35b37f50 Merge "msm: camera: cpas: Disable ICP QoS registers for kalama" into camera-kernel.lnx.5.0 2021-11-05 18:41:54 -07:00
Savita Patted
b8e7311b43 Merge "msm: camera: common: Add path for ubwc and linear" into camera-kernel.lnx.5.0 2021-11-05 18:41:45 -07:00
Savita Patted
18feeabe4a Merge "msm: camera: common: Add Kalama make configuration" into camera-kernel.lnx.5.0 2021-11-05 18:41:37 -07:00
Savita Patted
7a41caaa1b Merge "msm: camera: smmu: Moves custom smmu API's to cam_compat" into camera-kernel.lnx.5.0 2021-11-05 18:41:18 -07:00
Savita Patted
869991d193 Merge "msm: camera: common: Remove return from debugfs_create_bool" into camera-kernel.lnx.5.0 2021-11-05 18:38:15 -07:00
Savita Patted
fd8920f5b8 Merge "msm: camera: mem_mgr: Add dma_buf_vmap to cam_compat" into camera-kernel.lnx.5.0 2021-11-05 18:37:52 -07:00
Savita Patted
be5c2963cc Merge "msm: camera: custom: Move include to cam_compat" into camera-kernel.lnx.5.0 2021-11-05 18:31:13 -07:00
Savita Patted
2360e333b9 Merge "msm: camera: req_mgr: Update list_head to const" into camera-kernel.lnx.5.0 2021-11-05 18:23:02 -07:00
Savita Patted
27f0bb1140 Merge "msm: camera: common: DDR type selection deprecation" into camera-kernel.lnx.5.0 2021-11-05 18:21:06 -07:00
Savita Patted
99aebe2c09 Merge "msm: camera: smmu: Add support for 36 bit address space" into camera-kernel.lnx.5.0 2021-11-05 18:11:44 -07:00
Jigar Agrawal
5227eac24e msm: camera: csiphy: Enhance csiphy logs
Add csiphy_type in csiphy logs for better
debugging.

CRs-fixed: 3065435
Change-Id: I19c8154351e44946c14a4c94dd90d3b507a69cc8
Signed-off-by: Jigar Agrawal <jigar@codeaurora.org>
2021-11-05 13:03:47 -07:00
Anil Kumar Kanakanti
510d709990 msm: camera: sensor: Add support for CSIPHY 2.1.3
Add support for new CSIPHY HW version 2.1.3.

Change-Id: I22e3658acc9a002e4323c0487e65f5ae0a495d6d
CRs-Fixed: 3068540
Signed-off-by: Anil Kumar Kanakanti <quic_akanakan@quicinc.com>
2021-11-05 17:35:24 +05:30
Abhijit Trivedi
2b4fa3dcde FF: Upto PC665: Merge tag 'camera-kernel.lnx.5.0-211101.1' into 6.0
* tag 'camera-kernel.lnx.5.0-211101.1':
  msm: camera: cdm: Fix incorrect condition in cdm code
  msm: camera: isp: Add YUV format as supported format
  msm: camera: isp: Force all IFE lite RDIs to line based
  msm: camera: isp: Additional fixes for KMD internal recovery
  msm: camera: cdm: handle dead lock scenario
  msm: camera: sensor: Remove NULL set for regulator phandle
  msm: camera: isp: Rearrange the rt-wrapper-base property
  msm: camera: isp: Handle error event notification to HW manager
  msm: camera: cdm: Fix cdm bl submit function
  msm: camera: isp: Update right out resource for PDAF parsed outport
  msm: camera: isp: Add SOF Retiming Disable Support
  msm: camera: isp: Enable line smoothing in RDI path for CSID 780
  msm: camera: isp: Add support for RDI LCR
  msm: camera: isp: Add new CDM BL Type
  msm: camera: csid: Fix excessive logging in CSID
  msm: camera: common: Update the ctx memory request logic
  msm: camera: csiphy: Add proper check for combo mode
  msm: camera: common: Fix kernel code and add checks
  msm: camera: isp: Add recovery support for custom AEB use-case
  msm: camera: cre: add degug fs entry to update clock rate
  msm: camera: core: Delete request from pending list in case of error
  msm: camera: csiphy: Update the csiphy bringup sequence
  msm: camera: csiphy: Enable PN9 infinite loop for test
  msm: camera: isp: Update reapply field in config args
  msm: camera: isp: Add common utility functions
  msm: camera: isp: Split event handler based on HW type
  msm: camera: isp: Apply scratch only on SOF trigger
  msm: camera: common: Add wrapper for presil locking
  msm: camera: isp: Fix BW voting corruption in top layer
  msm: camera: isp: Handle RUP for enabled CSID CAMIF IRQs
  msm: camera: reqmgr: Fix the crm driver
  msm: camera: cdm: Fix cdm driver for bufffer excursion
  msm: camera: common: fix map check failure for presil buffer send
  msm: camera: cpas: Add support for Diwali Camera
  msm: camera: uapi: Add new event causes
  msm: camera: isp: Add bw info dump on clk/bw update error
  msm: camera: common: Make msg_cb for cam_subdev generic
  msm: camera: req_mgr: Rearrange state change sequence
  msm: camera: isp: Add header file VFE and CSID for Diwali
  msm: camera: csiphy: Extend CSIPHY hw block support
  msm: camera: icp: send freq to ICP firmware
  msm: camera: cci: Increase HW block support for CCI
  msm: camera: isp: shdr enable pdaf occur overflow
  msm: camera: cdm: Correct the CDM iommu handle
  msm: camera: isp: Update last applied MUP for scratch
  msm: camera: reqmgr: Only do self correction after initial sync
  msm: camera: common: Add presil compilation and probe support
  msm: camera: ife: Program image addr for once in RDI batch mode
  msm: camera: icp: add mechanism to send/receive buffer for presil

Change-Id: Ib959b746db64825cc735fa80ddd5e79200c102a8
Signed-off-by: Abhijit Trivedi <abhijitt@codeaurora.org>
2021-11-04 14:20:33 -07:00
Anand Ravi
4a5c74e70f msm: camera: isp: Recover missed SOF timestamp
In case SOF interrupt is not received by the camera driver, we can
recover the missing SOF timestamp for the frame at epoch using the
previous and current SOF timestamps from CSID.

CRs-Fixed: 3067696
Change-Id: I25c8596132b99829d04ea38dbd3d904fc2a302c2
Signed-off-by: Anand Ravi <ananravi@codeaurora.org>
2021-11-04 09:22:19 -07:00
Savita Patted
8eb28b180d Merge "msm: camera: csid: correction for printing long and short packet info" into camera-kernel.lnx.5.0 2021-11-03 18:03:29 -07:00