Clock gating must be disabled at top level initialize
hardware routine as VFE is reset after resource level
initialize hardware routine.
CRs-Fixed: 2590331
Change-Id: I5c51c402a3a6076f056368493b774daa199228aa
Signed-off-by: Venkat Chinta <vchinta@codeaurora.org>
The EPOCH at which bubble is detected no setting is applied
to any device. This change will trigger applying the bubbled
setting to the device with highest pipeline delay.
CRs-Fixed: 2564669
Change-Id: I180b4a1d2d29267f330546b8860a099baf1688e9
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
Add support for immediate stop and reset during flush
for custom HW.
CRs-Fixed: 2585745
Change-Id: I542ac02f8d99c194efa498bc07dffae7879a6c8a
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
Currently as part of the page fault handler we only dump the
io_bufs. This change dumps all the patched addresses for
this request as well.
CRs-Fixed: 2579908
Change-Id: If5deec0ad3a8aec82824ef55366084c31a037515
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
In case user does not set any dump lvl, KMD will set
to dump on failure as default.
CRs-Fixed: 2579908
Change-Id: I036e91f5daceedf575815e7569c0e90c04f8de52
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
Due to race conditions, situation can arise where the process_irq
and flush for jpeg are being handled in parallel. This will cause
the jpeg list corruption.
This commit protects the code of adding back to free list
in process_irq with the mutex.
CRs-Fixed: 2578247
Change-Id: I28ee48bc0d5cfcf3ae4a936b2eb2976226ad88d5
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
This change will print ICP error names based on error type.
CRs-Fixed: 2456658
Change-Id: I975598a7404f7520912d7b3211b6baa249e7f238
Signed-off-by: Prakasha Nayak <pnayak@codeaurora.org>
The request frame cmds are submitted to the FW in workq context.
The abort cmd as part of flush is triggered in user thread context.
This change will enqueue the abort as part of flush to FW in workq,
thereby ensuring that if there are any pending frames they are
submitted prior to the abort cmd.
CRs-Fixed: 2588575
Change-Id: I5034ca500cf39dfa0e553c49917fedb8bd084b0b
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
This change attempts to retry waiting atleast 1 time for
a duration of 1 second for the abort ACK from FW. Also
adds some debug messages during flush and removes mutex
usage during page fault dump.
CRs-Fixed: 2588575
Change-Id: I2f273baa3d56ab2dc0368d882470360a3702c53c
Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
if cpas probe fails during initialization of soc resources
soc data is being accessed after freeing the memory.
This change handling the sequence on failure.
CRs-Fixed: 2585085
Change-Id: Ia89b02bce9cfb6512b33f8e7366a552635317ccd
Signed-off-by: Alok Pandey <akumarpa@codeaurora.org>
Fixed out of memory issue in triple camera usecase by increasing
number of logical jpeg contexts.
CRs-Fixed: 2587592
Change-Id: I25c99c0be8d3986bc11fbc2894a0dbf27c645d4e
Signed-off-by: Suraj Dongre <sdongre@codeaurora.org>
Signed-off-by: Mukund Madhusudan Atre <matre@codeaurora.org>
Reset the slot with the valid request on receiving
the buf_done which is reported on next EPOCH.
In case of back to back irqs slot is marked as skip idx
it will apply the request and try to reset a slot based
on MAX_PD + 1 calculation which might have the request
for which we have got a bubble. To make sure this does not
happen, reset a slot only on the buf_done for valid request.
If STOP ioctl is called from UMD for ISP, it will flush all
the lists. But this is not notified to CRM which might have
a stale entry of the half applied request, so on STOP ioctl
clear all the slots.
In case of SAT mode if one of the link has generated bubble,
while the sync_link has the sync_request slot reset sync_link
will not let the link recover of the bubble. To make sure the
recovery sync_mode is set to 0 for two consecutive slots of
the link.
CRs-Fixed: 2551701
Change-Id: If4b6f8a4a831ffddcef2cae6292d066778c18b04
Signed-off-by: Tejas Prajapati <tpraja@codeaurora.org>
Add a high-to-low transition in the CTRL0 register
during the common power-up sequence.
CRs-Fixed: 2580437
Change-Id: I66541d3d787fa2f161e5d8e647fb11c8075a1947
Signed-off-by: Shravan Nevatia <snevatia@codeaurora.org>
Due to scheduling delays, process trigger workq can be delayed.
In the meantime, link state can be reset to IDLE. This can cause
abnormal behaviour resulting in stability issues. Also, at the
time of apply fail for flash, failed_dev is not updated.
This causes crash while notifying the error on link.
This commit prevents the execution of workq process trigger if
the link has been reset to IDLE state.
Also, failed_dev is updated if the apply for flash fails.
CRs-Fixed: 2572511
Change-Id: Iaea1e0a7a24afc9e408a1530a5875f6b6c41a45b
Signed-off-by: Gaurav Jindal <gjindal@codeaurora.org>
When epoch comes along with RUP we report bubble as per current state
machine. This was because in camif_bottom_half handler we are handling
EPOCH before RUP. This change prioritize RUP over EPOCH and EOF over
SOF to handle race.
CRs-Fixed: 2567120
Change-Id: I236bcc44b609f8ef7f963f19d33d46a3d95ba0d2
Signed-off-by: Vikram Sharma <vikramsa@codeaurora.org>
Isp bus port secure mode not coming properly. Added proper
logic to get the bus port secure mode correctly.
Use secure iommu handle to get secure buffer for ope.
Add spin lock for tfe irq handler.
Use proper bw structure to copy the user send blob
data.
CRs-Fixed: 2594541
Change-Id: Icb8ecf869681c370efa084991505036f90a35065
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Correct the queue size for cci version 1.2 as below,
1. Queue 0 size = 64.
2. Queue 1 size = 16.
CRs-Fixed: 2594541
Change-Id: Ifc9407427fe2bf0996c77dc00c5dfe7e5ba22140
Signed-off-by: Tony Lijo Jose <tjose@codeaurora.org>
Adding fixes to set IRQ mask after reset and strings to
print OPE CPAS PATH enums.
CRs-Fixed: 2594541
Change-Id: I5873b8b0494623c36ca94edf7a26cc952fbb5e68
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
During flush OPE driver takes lock on OPE context and
calls the CDM flush, in which CDM notifies OPE for all
pending requests. If at the same time CDM is notifying
OPE for successful request that thread also tries to
take lock on OPE context. CDM also tries to takes lock
on CDM client in each notify call. Due to which,
dead lock is occurring.
So taking the lock on OPE context in OPE flush after
CDM flush.
CRs-Fixed: 2594541
Change-Id: I6ae9105d33a49a638141973cdd6a4a99621dc4c5
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
As we are accessing hw version register during probe so calling
cpas_start and cpas_stop during probe.
Disabling the read clients which are not enabled for the request.
Resetting the req_timer when we receive the request from UMD.
CRs-Fixed: 2594541
Change-Id: I4a739fedbb498bd0c6b5b1e4cef38de3e4c722ed
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
Do not read the hw register to update the bus width.
Update register with stored height and user space given width
Update the tfe core irq command register after clear the registers.
CRs-Fixed: 2594541
Change-Id: I3fd9e0ce4319cd19b94e9c83fa63aab37f26027e
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Corrected the parameter needed to be passed in cam_ope_deinit_idle_clk.
CRs-Fixed: 2594541
Change-Id: Ibeb8558fd0724fff61f4a6ddadd3b3cf6a6b3ed2
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
Arm arch does not support dividing 64 bit integer, replacing it with
do_div call.
Fix variable type to work with both 32/64 bit arch.
CRs-Fixed: 2594541
Change-Id: I6b30f089bc998e98c7f2e20dc7fc11eedf6e6bc7
Signed-off-by: Chandan Kumar Jha <cjha@codeaurora.org>
User space will send HBI and VBI values for tpg. Configure the TPG
HBI and VBI values based on the user space given values.
If user space does not send then configure the default values.
Assign the isp context variable in the hw update data during the
tfe hw config. Update proper comp group id for slave tfe.
CRs-Fixed: 2594541
Change-Id: I2771d3c663c0fcb58306952f161c11a473846f8d
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Camera QOS settings are updated for Bengal target as per the
Recommendations of hardware team.
CRs-Fixed: 2594541
Change-Id: I068683445b0ced92c22a5bfdc56d936ca64385c3
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
TFE is thin front end hardware that capture and process the
real time image. Support is added to enable the TFE
hardware.
CRs-Fixed: 2594541
Change-Id: I0ab2eff7924e9e01f6a0fcec772d3a7dda229b37
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
The bit corrresponding to enabling burst is 4th bit.
This change fixes its value by assigning the same.
CRs-Fixed: 2594541
Change-Id: Ibeec3fd4460f9040255fa77f60fd565aed824c1c
Signed-off-by: Abhilash Kumar <krabhi@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
Different CDM hardware have different capability and registers.
With old register space, handling new features and operations
would have been a complex task. This change takes care of old
version of CDM and also changes the regspace to provide every
register's access to CDM.
This change further adds support for "arbitration" in case of
multi-context CDMs.
Exports reset functionality to clients, detection of CDM hang.
Flushing the CDM requests and dumping the FIFO content for all
contexts.
It also adds submitting "debug_gen_irq" as BL_done IRQ is only
an indication for availability of FIFO's. The AHB operations
are completed can only be known if the added "debug_gen_irqs"
gets executed and are received by the CDM.
CRs-Fixed: 2594541
Change-Id: I9846b1c5320ba652c5d3b7d83d616d2dabc843e1
Signed-off-by: Abhilash Kumar <krabhi@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
Update datatypes to work with 32 bit kernel.
CRs-Fixed: 2594541
Change-Id: I72d628152134770d7e09c3684443e25c47d9d1dc
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
Bengal has different version of camnoc which requires
separate register space and camnoc interface changes.
This change adds the same.
CRs-Fixed: 2594541
Change-Id: I2a8e6cb8894444cb669ab1c4da5fa706dc6543ad
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
Hardware manager resource is generic. Move the resource definition
to isp hw manager so that it can be used by other hw manager.
Remove the parent and child graph in the hardware manager resource
as it is not used. Use the common isp resource type everywhere.
CRs-Fixed: 2594541
Change-Id: I41d49af0855f3bd3768450d850b1284ff1e3fea9
Signed-off-by: Ravikishore Pampana <rpampana@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
Currently sync driver is independent from dtsi matching in order
to get it probe. Update the logic to make sure probe is getting
invoked if respective dtsi is present.
CRs-Fixed: 2590413
Change-Id: I69124e49d68e223d082521a9431cb7e8d846e8d7
Signed-off-by: Jigarkumar Zala <jzala@codeaurora.org>
Corrected the striping creation for non real time device.
Disabled the ope stripe base bus. Corrected the batch mode
creation for ope bus read.
CRs-Fixed: 2594541
Change-Id: I87adbab25b84d74162a6a8ce2db1412a6d9058d0
Signed-off-by: Rishabh Jain <risjai@codeaurora.org>
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>