When check CSID frame size err, is not bus overflow, result in
the err event data don't get error type info and can't transfer
hw err info rightly from ife hw to isp ctx. So first let err
event data get err type info.
CRs-Fixed: 3500372
Change-Id: Ia90a8c28028ae63174d30d2513e6d1f042810d43
Signed-off-by: Wang Kan <quic_wkan@quicinc.com>
This change is to validate session, device and link handle.
Also, checks whether the device handle belongs to
correct session handle or not.
CRs-Fixed: 3496553
Change-Id: I6b86bf7d0908a280e90e085a3b3e1727facdf8c6
Signed-off-by: Karthik Dillibabu <quic_kard@quicinc.com>
camera-kernel:
2ed8378c Merge "msm: camera: isp: Avoid race condition to prevent list corruption" into camera-kernel.lnx.dev
4fcf71ff Merge "msm: camera: sensor: Check the result of i2c transfer" into camera-kernel.lnx.dev.
Change-Id: I49de5733995595180987f43220b86c802164885b
Signed-off-by: hchintal <quic_hchintal@quicinc.com>
in case of back-to-back bubble requests, We do internal recovery.
We don't have locks for list protection in the internal recovery flow.
From the core dump, we had seen that we were handling bubble in one core
but we had done list modification on another core during internal
recovery without list protection, which results in list corruption.
We are accessing the request queue during internal recovery without
any locks which are resulting in list corruption.
We need to use locks to prevent list corruption in the internal
recovery flow.
CRs-Fixed: 3444802
Change-Id: Id72077647795e51e112b030d4fb75d80299c1bed
Signed-off-by: Chandan Kumar Jha <quic_cjha@quicinc.com>
The i2c transfer interface returns the num of message is
processed if there is no issue, this change checks if the
result of i2c transfer is same with the num of message,
the return value is assigned as 0 if they are same.
CRs-Fixed: 3495774
Change-Id: I408038120ac2371f1ed031daa364c2e2563e3606
Signed-off-by: Depeng Shao <quic_depengs@quicinc.com>
It is wrong to use crop_v_en_shift_val and early_eof_en_shift_val
to do AND operation with cfg1, instead, we should use
BIT(crop_v_en_shift_val) and BIT(early_eof_en_shift_val). Besides,
register rup_aup_cmd_addr is not a readable register, so we can't
read it's value from it.
CRs-Fixed: 3500551
Change-Id: Ied566a968b0403498ce859544659f9dbe40ce770
Signed-off-by: mingpan <quic_mingpan@quicinc.com>
Sometimes need to avoid access clock/regulator/icc api, this change
add support bypass clock/regulator/icc wrapper through enable
some debugfs parameters and devicetree.
CRs-Fixed: 3445248
Change-Id: I0546975bf063625b39b771c776813e7dbff84e06
Signed-off-by: zhuo <quic_zhuo@quicinc.com>
In VFE top, currently it is assumed that frame timing
IRQs will be part of status 1 register. Remove that
assumption to support v980 hw as well. Also, when
frame irq debug is enabled in ife hw manager, don't
trigger callback, as we just want to see if frame
reached IFE/TFE or not.
CRs-Fixed: 3321317
Change-Id: I544727d4bec628b9041531015f24bf73e8ae2be1
Signed-off-by: Mukund Madhusudan Atre <quic_matre@quicinc.com>
For v980, new formats are added. This change also
fixes mismatch of plain16_10_lsb format between
kmd and userspace.
CRs-Fixed: 3321317
Change-Id: I1d951d3e55b37b11ebe6dad67bea220d47998d59
Signed-off-by: Li Sha Lim <quic_lishlim@quicinc.com>
This change adds support to detect early
unmapping of buffers from UMD, and signal
when the error occurs by sending an error
code to UMD.
At present, buffers are allocated and/or mapped
by UMD, and the following sequence occurs.
KMD prepares packets sent during a config ioctl,
and these packets reside in the mapped buffers;
HW blocks then access these buffers, and may
write output to other mapped buffers(io buffers);
Once HW is done(upon a buf done), KMD signals
this event to UMD;
UMD may free/unmap these relevant buffers.
This change adds support to detect cases where a
free/unmap happens before/while HW is accessing
these buffers.
This feature is enabled by default, but a debugfs
variable disable_buf_tracking is added under smmu
which will enable the user to disable the feature.
Camera server needs to be restarted whenever this
variable is set/unset for changes to take place.
CRs-Fixed: 3382609
Change-Id: I39c3f0c373743c10bc2e6304ffbdc820e3c95970
Signed-off-by: Li Sha Lim <quic_lishlim@quicinc.com>
HWPD is associated with several modules, but only image size violation
displayed in the kernel when an error occur. Now we will pass the error
code of HWPD violation to UMD to help UMD to take necessary action and
dump relevant info.
CRs-Fixed: 3440015
Change-Id: I6483b228a8eeaac3bf54f5f83f8f8deab3da6250
Signed-off-by: Stark Lin <quic_starlin@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: I3c2e262f57cdfdbd51255679b2405d855d7d5353
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: I2043f3db6189ebfc8b8ead8db0266a83bc94b6a2
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Monitor frame events driving the state machine.
To better understand what led to the state machine stalling update
debug info that is logged on errors.
CRs-Fixed: 3309151
Change-Id: Iccf0efd82069b342e5d4b1731292604d37263b0b
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Correct the check for comparing SMMU client names when
trying to create new handles.
CRs-Fixed: 4653426
Change-Id: I04e0d75e87bf88f1ae05b7d61b6853ac6794d6eb
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Current logic of logging passes the strings as arguments to
logging Macros. This converts them into string literals and
increase the data section size.
This commit changes the logic to convert the tags into
strings inside a function, thus optimizing the data section size.
Top level estimations shows the reduction of 1.5MB .ko size.
CRs-Fixed: 3470008
Change-Id: Ifcd5bedc374e8c5f36b8c0be5ae050959b432666
Signed-off-by: Gaurav Jindal <quic_gjindal@quicinc.com>
Currently at image size violation we just get info about width
and height for that particular port which is sometimes not
sufficient if in case some other register incorrectly configured.
This change will dump few CSID registers like crop register in
case of error which will help to get more info.
CRs-Fixed: 3467438
Change-Id: I034f2686b3689b52cdd0309d09bbdb920f88222b
Signed-off-by: Yash Upadhyay <quic_yupadhya@quicinc.com>
This change fixes below kw issues:
1. Operands in a bitwise operation have different size.
2. err_evt_info might be used uninitialized.
CRs-Fixed: 3491937
Change-Id: Ied038b18c72485646dc641f6d1396d15c50c06e2
Signed-off-by: Stark Lin <quic_starlin@quicinc.com>
This change add irq set register offset for VFE and SFE, it provides the
foundation for the implementation of BUS IRQ injection of VFE and SFE.
CRs-Fixed: 3433678
Change-Id: Idc2aa59eb805f9ebc397112c5e5c800f68423e5a
Signed-off-by: Stark Lin <quic_starlin@quicinc.com>
Add a flag for different channel settings
including short and standard channel.
CRs-Fixed: 3440178
Change-Id: I3f9ea83483a1706e660a8c5ddf225f5d9eb3abcb
Signed-off-by: Wang Kan <quic_wkan@quicinc.com>
This change aims at reducing the num of update entries
during the prepare stage. This change combines the change
base entry and RUP entry at the end of each request,
squeezes related entries from handling blob and combines RUP
entry when adding go cmd for offline context.
This change also refactors code on adding and combining
entries, removes unused variables and cleans some coding
style issues.
This change turns UNUSED entry to IQ entry for
convience but it's also compatible for further change on
the BL type of those entries.
CRs-Fixed: 3444613
Change-Id: I0301436971a86b72d8e98018caf130de78b44011
Signed-off-by: Haochen Yang <quic_haocyang@quicinc.com>
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>