This change reduces repetitive code and also add SFE OUT resources
dump while executing dump for acquired resources.
CRs-Fixed: 3467287
Change-Id: I9d826bbbf90b3f97ce5d7d59a453f2c290dc8dee
Signed-off-by: Stark Lin <quic_starlin@quicinc.com>
This change adds rd info for SFE hw dump. Also when an SFE error
occurs, only the information of err res will be dump, it will
help on reducing burdensome logs.
CRs-Fixed: 3436435
Change-Id: I7e3395d8301e2a51cbaf62d3974f37468ffa785b
Signed-off-by: Stark Lin <quic_starlin@quicinc.com>
Add support to receive synx test cmds, and forward it to ICP FW.
Synx on ICP will process that cmd, and send a response. This
response is returned to the caller. The objective of this
infrastructure is to allow synx test app to validate synx
functionality on ICP without running any actual use-case.
CRs-Fixed: 3448052
Change-Id: I3785264f74c5c698146f4de1a82d25fe141cfc2a
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Change sequential to burst write in write calls for i2c and i3c.
CRs-Fixed: 3418153
Change-Id: I4b10b1b62e1075225867561297bddaaac2797a2d
Signed-off-by: Ridhi Shah <quic_ridhshah@quicinc.com>
This commit fixes the KW issues in CSID Driver while
fetching the index for UDI.
CRs-Fixed: 3484948
Change-Id: Ia7a7dbd2f4ace71830f3a652874cc1cc321a5ef6
Signed-off-by: Gaurav Jindal <quic_gjindal@quicinc.com>
Allocate memory based on what is configured to FW. Avoid
hardcoded allocations, thereby reducing the memory
footprint. The change also updates size check for a SMMU
mapping, if the size of the buffer is beyond the assigned
va range fail the mapping.
CRs-Fixed: 3477543
Change-Id: Idfdce7febfe6624db33ff466b978207e96d4a902
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Reduce size of the buffer to drain the dbg_q. Add a mutex for
dbg_q, and in HFI read validate the input buffer size prior
to copying the queue contents into the input buffer.
CRs-Fixed: 3477543
Change-Id: If7246f7d1d521ed683a6fe785aa4c8d0457b5f0f
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Allow plain1610/plain1612/plain14 output format reserve while
seamless switch between RAW10/RAW12/RAW14 sensor mode.
Fix the image size violation issue by using write master pack
to get correct pack format and width on rdi.
CRs-Fixed: 3478244
Change-Id: I4dc3660f40405604bfd04a1e0042bb11ca5b5bf9
Signed-off-by: chengxue <quic_chengxue@quicinc.com>
camera-kernel:
d5fec009 Merge "msm: camera: csiphy: Enhance the start dev log for csiphy" into camera-kernel.lnx.dev
a3f264c5 Merge "msm: camera: common: Increase the max tag length to 128" into camera-kernel.lnx.dev.
Change-Id: Id17e5ca28bffdc84f6a4dd2a06c655956f77d231
Signed-off-by: hchintal <quic_hchintal@quicinc.com>
Enhance the start dev log for csiphy.
CRs-Fixed: 3482293
Change-Id: I8887affedb0d7937e4105585e531c654eaa634ff
Signed-off-by: Depeng Shao <quic_depengs@quicinc.com>
Currently the maximum length of tag is 64, but in some
cases, the tag length we need is lager than 64, in
this case some information will be lost, which leads
to the failure to properly parse out the required
information. We need to make sure that all the tags
are the same length so that the parsing script can
parse them correctly. We also need to make sure that
the last character in tag is ":" in order for the
parsing script to get the full tag string correctly.
CRs-Fixed: 3467258
Change-Id: Ie8107ffd902d70d88026632a2c9fadaca0c276d8
Signed-off-by: mingpan <quic_mingpan@quicinc.com>
If ICP FW is to be redowloaded, issue a synx recover for
this ICP core so that IPC/synx for the previous session
can be cleaned up prior to the next ICP cold boot.
CRs-Fixed: 3448052
Change-Id: I9f8f772730f7e4a8873b6dbdcf7a896ad6193150
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
- Add support for Dynamic mode switch.
- Request store and apply from waiting queue.
- Add support for reapply request from active queue.
- Handling TPG interrupt.
CRs-Fixed: 3403974
Change-Id: I5dfe146b30631a94059f72d482610e04ba8e4e2c
Signed-off-by: Rishab Garg <quic_rishabg@quicinc.com>
Reorganize icp hw mgr structure to consolidate fields related to
device (IPE/BPS/OFE) to improve code readability and scalability
and avoid unnecessary array indexing. Optimizing ICP devices looping
by looping only available devices for current target instead of
looping to maximum devices.
CRs-Fixed: 3441726
Change-Id: I33ef62ceabbd85ff21aaf475b75d34b6c203b018
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Update CPAS HW driver to read multiple hw caps registers for v880
and v980 targets. Upgate CPAS API interface to provide multiple camera
caps to clients.
Move hw capability register offsets to cpas header files.
Update ICP driver to check the second hw capability mask
for OFE presence.
Based on the type of device(ICP/IPE/BPS/OFE) populated from DT, verify
with cpas titan hw capability to check if the device is supported for
the target. Verifying CPAS HW capability after populated devices from DT
removes the need for checking CPAS HW version.
CRs-Fixed: 3405111
Change-Id: I11a58920d97f25908e6bde49fd918b2cc90c1479
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
This change registers tfe on v980 as an mc_tfe device
for userspace to enumerate.
CRs-Fixed: 3321317
Change-Id: Ic7810dc198aece0d1d0fa50e547f69c72218d49a
Signed-off-by: Li Sha Lim <quic_lishlim@quicinc.com>
Get CDM callback done timestamp for LDAR to know
if CDM write delay. And enlarge event monitor
numbers to make sure dump 10+ frames info.
CRs-Fixed: 3430787
Change-Id: If5a1bd925d5d82d1856d880ccb1f4ed9effc5251
Signed-off-by: Wang Kan <quic_wkan@quicinc.com>
camera-kernel:
c38501c0 Merge "msm: camera: icp: Add support for new mem region cmd" into camera-kernel.lnx.dev
1ba50950 Merge "msm: camera: smmu: Add support for new subregions" into camera-kernel.lnx.dev
26439955 Merge "msm: camera: cpas: Update CPAS for v980" into camera-kernel.lnx.dev
92c1cbcb Merge "msm: camera: common: Return err on flush and log req id" into camera-kernel.lnx.dev
8a691fa0 Merge "msm: camera: memmgr: Reduce potential mutex optimistic spin" into camera-kernel.lnx.dev.
Change-Id: I1a4c3bafed7c9995dd9d04134736f5d257728e27
Signed-off-by: hchintal <quic_hchintal@quicinc.com>
To avoid using GP registers to send different memory region
info, use GP registers to configure only the consolidated region.
The specifics for different regions within the consolidated region
are later sent to FW as a new HFI cmd.
CRs-Fixed: 3469619
Change-Id: I2eb9511a4df5c8eb4ca09b60acd1fcffb3ac4dff
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Add support for new subregion to account for two different
HW mutex regions for ICP. The change also adds support for
new global cntr subregion.
CRs-Fixed: 3469619
Change-Id: I8625230bfec23d2a12699a283a33e6ab83acaf00
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
In CPAS v980, CAMNOC is split into RT and NRT. Camnoc RT and NRT each
has separate register base. Camnoc RT is used by TFE, IFE lite, RT CDM.
Camnoc NRT is used by OFE, IPE, ICP, JPEG, NRT CDM. There are also two
IRQ lines for CPAS: RT and NRT IRQs.
Add CPASTOP SBM IRQ for RT/NRT, static QOS NOC settings for RT/NRT,
Cesta, and others in the header file for v980. CPAS registers two IRQ
lines and handles the incoming (RT/NRT) IRQs based on the IRQ data for
each IRQ. CPAS SOC looks for IRQ identifier property in CPAS node DT
to classify the IRQ type.
Global Camnoc info variable and qchannel variable now contain separate
info for RT/NRT or combined info.
Add NRT reg base for camnoc NRT base. Add TFE UBWC Encode error.
CRs-Fixed: 3403163
Change-Id: I3044c6314fa65c4e486bfa1bff2e828ac5e285cd
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
When a client driver tries to obtain the HW iova for a given buffer,
the call is directed to SMMU layer. In mem_mgr each buffer entry
has it's own lock, but in SMMU it is a singleton lock for the
entire context bank. If there are multiple clients trying to
obtain iova for buffers from the same bank, it leads to waiting
on the same singleton mutex. To avoid this, when allocating
or mapping a buffer, save the iova addr of the buffer for a given
device in the mem_mgr bufq entry. When a client requests, check
the bufq entry for iova, redirect the call to SMMU only if the
address is not found in the mem_mgr. The change attempts to
reduce the number of CPU cycles in trying to obtain a buffer
iova.
CRs-Fixed: 3466755
Change-Id: I19b983ee59704eccf421ab808cbe885725571f5b
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
When UMD requests to flush specific request that was submitted
to HW/FW, return error code back to userspace and log the particular
active request id if the device does not flush active request.
Currently devices that do not support flushing a specific active
request are ICP, OPE, and CRE.
Return error if there is no request to flush upon UMD call to
flush specific request.
Print all ICP requests' id from all active streams when encountering
WD or ICP fatal errors.
CRs-Fixed: 3438283
Change-Id: I7921463250c6e5e45ec263ccdce9d60d2b0f1ed3
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Assign OFE clock voting level to clk update command in order
for hw mgr to scale ICP clock to the updated OFE clock level.
CRs-Fixed: 3463474
Change-Id: I680394270e6ada0253e524ed88be9226954a0103
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
When ICP encounters fatal errors, Kernel triggers a recovery and
UMD calls to release the hardware. Since FW encounters fatal erros
and no longer responds to HFI command, the abort and destroy command
to FW in release hw sequences bound to timeout anyway. So, this change
will avoid sending the commands in the release HW sequences.
CRs-Fixed: 3454098
Change-Id: I8dd119876df2f3cb360fbf5467221a31c47a8d22
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
camera-kernel:
eeb1f5bc Merge "msm: camera: isp: Refactoring top and rx irq related code" into camera-kernel.lnx.dev
15540ec6 Merge "msm: camera: common: Fixing memory leak issues and removing dead code" into camera-kernel.lnx.dev
41532b8d Merge "msm: camera: isp: Update lite header for MUP" into camera-kernel.lnx.dev.
Change-Id: I0b775cfe1ef9207f62bc8c821ff140aac4e853d6
Signed-off-by: hchintal <quic_hchintal@quicinc.com>
Refactoring top and rx irq related code, and add support
for multiple top and rx register.
CRs-Fixed: 3321317
Change-Id: Ib34485d8d7c08e2d3729920504819fe6edac6bf1
Signed-off-by: Ashish Bhimanpalliwar <quic_abhiman@quicinc.com>
Support raw plain format update for write master while do seamless
switch between RAW10/RAW12/RAW14 sensor mode, and check the updated
format and io config format to avoid wrong pack format programming
on target who doesn't support 2 decode format in CSID.
CRs-Fixed: 3419387
Change-Id: I712ca3a346a2e2eb3b79d947a31423025069bf33
Signed-off-by: chengxue <quic_chengxue@quicinc.com>
When receiving OFE IO config ack from FW, signal completion
to wake up awaiting thread who calls to send IO config command
to FW.
CRs-Fixed: 3458585
Change-Id: I23bc7d1acd3a9ddf2d6b7120d51cdecb55569651
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Vfe out resources memory allocation is done at the time of
probe based on max out ports supported. Considering the
number of contexts and the size of each node, the total
size comes around 16KB whereas in normal use cases, this
much memory is way too large. For upcoming multi context
targets, this number will be multifold, roughly around
48KB.
This commit changes the memory design to maintain the
out resources. With this commit, at the time of probe,
around 400 bytes will be allocated and rest of the
memory will be allocated at the time of acquire and freed
at the time of release. Only the required memory will be
allocated.
CRs-Fixed: 3321317
Change-Id: Ibb069962736a90bcf89ecfd0f54f983094be942a
Signed-off-by: Gaurav Jindal <quic_gjindal@quicinc.com>
For dual ife, we add res id from both left and right ife hw to bus
comp group, and cause warn log print for duplicate buf done, we
only need add res id from left split ife hw to bus comp group.
CRs-Fixed: 3454579
Change-Id: I319ae4dcbff5f009d9a98abc020b439ac4eac55b
Signed-off-by: chengxue <quic_chengxue@quicinc.com>