Update from error injection framework to event injection framework to
support PF event inducement and node event. Different set of user
input parameters are required dependent on which event to injection.
ICP and ISP support error event and page fault event injection. JPEG
supports node event and page fault event injection. However, buf done
error injection is only supported for JPEG and ICP.
Create a query API to check whether PF is fatal for a context bank.
Using the API, if PF is fatal, page fault event injection is not
supported for the device that owns the context bank.
Make change to JPEG context event callback handling to account for
various events including Event Injection event.
CRs-Fixed: 3210139
Change-Id: I582ee0bda8dbf631ece2522a5a8145f38ec71928
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Rename symbols in ICP driver to accommodate for newly added
OFE driver. Symbols that specifically contain string "ipe_bps"
or "ipebps" are renamed to "dev" or "device" to make the symbol
generic and adaptable to any distinct HW names such as OFE.
CRs-fixed: 3266661
Change-Id: I141342e40d52cbb3c676389a13f1428435054913
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Handle the deferred buf done in case of a back-to-back
bubble scenario.
CRs-Fixed: 3297235
Change-Id: I62a4fcd906742ffe20ad1648739528357870f20d
Signed-off-by: Chandan Kumar Jha <quic_cjha@quicinc.com>
Remove direct shell commands from Android makefiles to better make use
of android function definitions.
Also changes mmrm dependency to be based on whether or not the driver
is detected in the build before setting it as a dependency.
CRs-Fixed: 3298147
Change-Id: I0d5f2c9eb34ac635604c515638c9f00e29ae0b2a
Signed-off-by: Suraj Dongre <quic_sdongre@quicinc.com>
Currently, we are checking the clock struct pointer for NULL
returned from clk_get functions. certain critical clocks might
have NULL returned for clk pointer, since they are enabled during
boot itself. Update return check condition for err only and ignore
NULL value and skip its usage.
CRs-Fixed: 3296865
Change-Id: I5c1852f2348ae8aeeb0508a2f4a052a8c4f1989e
Signed-off-by: Mukund Madhusudan Atre <quic_matre@quicinc.com>
Update register offset for CSID and CSID-Lite 880.
Discarding CSID secure register offset which is beginning
of reg space and not accessible from HLOS.
CRs-Fixed: 3291241
Change-Id: I693f85ef4f824e159f3fb0589b7d4bfc2148d000
Signed-off-by: Chandan Kumar Jha <quic_cjha@quicinc.com>
The process_req is locked by session lock, then sub devices
on different links can't apply setting concurrently, it will
affect the performance for per frame req applying on bokeh
mode. This change removes the session lock for sending req
and adds it only for checking req ready.
CRs-Fixed: 3292804
Change-Id: I97025774ddb5f89fcc3a3d596921e1240a2d464c
Signed-off-by: Depeng Shao <quic_depengs@quicinc.com>
This change add the timestamp in different io config when read
actuator packet. In order to ensure the accuracy of the time dimension
of the data, the timestamp of the Kernel is returned synchronously when
read HALL data.
CRs-Fixed: 3244812
Change-Id: I2ddb9450108e2b0f47769c7b02078903c4f3812b
Signed-off-by: Wang Kan <quic_wkan@quicinc.com>
Instead of caching packet address pointer, store packet handle
in page fault req info structutre to obtain packet address through
mem manager to avoid potential access to dangling packet pointer which
resulted from UMD called to free the packet buffer before kernel finishes
handling page fault. If the packet was freed, then querying to get packet
address from memory manager will fail since the mem handle is invalid.
If it is invalid, the page fault handler will return before accessing
the dangling packet.
CRs-Fixed: 3287554
Change-Id: I02bc0c706b64f1dc0d098d8189f2f129a91efba7
Signed-off-by: Sokchetra Eung <quic_eung@quicinc.com>
Update the correct WM idx for ALSC client for v880. The
change also removes dependency on comp group type for
buf done irq masking. The order is not maintained in HW
so breaking that assumption in SW, and making the buf done
irq bit mask as an array for comp groups.
CRs-Fixed: 3254772
Change-Id: I7ac1dcf4150761b2f6f124e389a5e5b1ea67bd83
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
Spi driver remove function signature changed between kernel version
5.15 and 5.18.
CRs-Fixed: 3245727
Change-Id: I0352e8b9b5f5990a89b082df9f9ca4000bcd5da0
Signed-off-by: zhuo <quic_zhuo@quicinc.com>
camera-kernel:
32a20f7 Merge "msm: camera: isp: Flag acquired rdi res for all RDIs acquire" into camera-kernel.lnx.dev
2b857a0 Merge "msm: camera: cci: Semaphore may sleep in spin lock" into camera-kernel.lnx.dev.
Change-Id: Ib73ab2e35bd2375491eb9ae1b9c69e1a03e801f8
Signed-off-by: hchintal <quic_hchintal@quicinc.com>
When we enable CONFIG_DEBUG_ATOMIC_SLEEP=y, the kernel will do
might_sleep check when we down a semaphore, if the might_sleep
found it is in atomic context, it will eventually call BUG() to
raise kernel panic because sleep is not permitted in atomic
context. What we do now is get a spink lock before down a
semaphore, this is possible to make might_sleep reise a
kernel panic because semaphore might sleep in spin lock. So now
change the spin lock to mutex lock to avoid this situation.
CRs-Fixed: 3269325
Change-Id: I37735dfa615ec7dfe0fc38d04688025badd255d5
Signed-off-by: mingpan <quic_mingpan@quicinc.com>
For SFE enabled usecase, if the RDI0 is an input image stream
for SFE IPP, we doesn't flag the global value acquired rdi res,
if PDAF stream is enabled, the RDI0 will be acquired again, and
reserve another CSID set, and the stream on fail.
CRs-Fixed: 3288480
Change-Id: I2a6b2363c5cc6bff27736e6848686781cba3f560
Signed-off-by: chengxue <quic_chengxue@quicinc.com>
Some definitions need to be updated based on device tree
configuration for new target. Add appropriate changes to
support it.
CRs-Fixed: 3244380
Change-Id: I919facfe319ca56477e594b782dcd2ad659cb193
Signed-off-by: Mukund Madhusudan Atre <quic_matre@quicinc.com>
Update register offset for VFE-Lite 880.
Discarding csid secure register offset which is beginning
of reg space and not accesable from HLOS.
CRs-Fixed: 3263421
Change-Id: Ib10a9b54057f262a92612e3a53bc29dd8afb5fe3
Signed-off-by: zhuo <quic_zhuo@quicinc.com>
Due to dma-buf symbols into the dma_buf module namespace,
when use them, need to import dma-buf name space.
CRs-Fixed: 3245719
Change-Id: I57bb808c675105bf567f7a628fb88c3259512721
Signed-off-by: zhuo <quic_zhuo@quicinc.com>
There is a narrow window, in which the critical section is
not fully protected which possibly could lead to use after free.
To avoid this, hold the row lock and validate the state prior
to processing the dma fence.
CRs-Fixed: 3273450
Change-Id: Ib1f09e62a5060a38b5cd8f3d4594bce2e533b3d3
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
camera_banner contains compilation timestamp, which can be used
to find mismatch between ramdump and symbols.
CRs-Fixed: 3261129
Change-Id: I021f6f9417b227d07a4424f7522e27c8535b0363
Signed-off-by: Trishansh Bhardwaj <quic_tbhardwa@quicinc.com>
In HW, the rup_aup latching scheme is enabled for dynamic switch
use-cases. The feature is to handle delayed rup_aup programming
between CSID SOF and CAMIF SOF. On Kailua with this feature enabled
we seem to be encountering CCIF protocol violations on IPP/PPP paths.
Disabling the feature, for now. The issue this feature is trying
to address is SW programming in a narrow window of 4 CSID clock cycles,
which is really small in SW.
CRs-Fixed: 3247669
Change-Id: I7678174541e8dd6b533eb95922e0814035811258
Signed-off-by: Karthik Anantha Ram <quic_kartanan@quicinc.com>
In function cam_ife_hw_mgr_acquire_res_ife_csid_pxl, if csid_res is added
to res_list_ife_csid, and if no_res_acquired is true, the csid_res will be
add to free_res_list without list delete operation, this will damage the
res_list_ife_csid.
CRs-Fixed: 3272891
Change-Id: Ic6ee6edeed8dce82fb7a2907daf5fa634cca8a7f
Signed-off-by: mingpan <quic_mingpan@quicinc.com>
camera-kernel:
fecbcff Merge "msm: camera: csiphy: Stop csiphy during shutdown" into camera-kernel.lnx.dev
93379dd Merge "msm: camera: sensor: Support backup sensor use different power voltage" into camera-kernel.lnx.dev.
Change-Id: I2330bff3455f102f8790e9aaa4d28bbd94cb45db
Signed-off-by: Haritha Chintalapati <quic_hchintal@quicinc.com>
Sometimes, userland may release the csiphy but doesn't
stop the csiphy, then the csiphy can't be stopped since
the state isn't in start state. We can't recovery to
normal state even shutdown the csiphy.
This change also checks the start count during shutdown
and stop the csiphy if the start count isn't zero. Then
we can make sure the state can be recovered after shutdown.
CRs-Fixed: 3261846
Change-Id: I5eef839e84125785e17c5f11f4118a8627b1fb63
Signed-off-by: Depeng Shao <quic_depengs@quicinc.com>
On customer side, the main and backup sensor who share a same
dtsi slot, may have different power voltage for VDIG/VIO/VANA
and so on, use sensor driver xml file power configValue on
powerUpSequence to enable regulator for both main and backup
sensor.
CRs-Fixed: 3254166
Change-Id: Ica54eb66ec9c5050aa3ee70f44fb6dfd3b7c4103
Signed-off-by: chengxue <quic_chengxue@quicinc.com>
When generic blobs are added to process debugging information
from userspace, these blobs are sent as separate packets
from the packets which carry actual configuration settings.
However, both are sent as the same packet opcode of
CAM_SENSOR_PACKET_OPCODE_SENSOR_CONFIG, where they differ is
a level below, within the meta_data type of the command buffer.
Further downstream after parsing the packets, packets with
config opcodes get applied. With this new change, we want to
add an exception for those sent as generic blobs. This change
introduces the fix for it.
CRs-Fixed: 3266290
Change-Id: Iee2ea186e594479d61dbe30dd1d0399352986028
Signed-off-by: Li Sha Lim <quic_lishlim@quicinc.com>
Currently, the mechanism to create platform device out of i3c slave DT
nodes is done through "simple-bus" compatibility string in camera DT. The
addition of this compatibility string in parent nodes is causing probes
to be fired for parent drivers when they don't expect it. Change this
mechanism and add support to do the same using of_platform_populate()
call for camera sensor module nodes under i3c master DT node.
CRs-Fixed: 3259550
Change-Id: I92523e7178ff78cdc783ca0b67b2dfbcebd0be61
Signed-off-by: Mukund Madhusudan Atre <quic_matre@quicinc.com>
This change adds domain-id support for new
targets. This change involves adding information
to the SCM call currently in use such that it is
a superset, and the additional fields needed are
the IFE and CDM number being used, and VC mask.
These are in addition to existing PHY mask selection,
and lane/trio mask selection.
All the information above will be sent over from CSID
to the PHY driver, and the PHY driver will pack the
information in a generic format before sending it
over in an SCM call. Where previously, this information
is packed in format that matches the register, this
will be sent generically moving forward.
Given that there are multiple instances per physical
PHY hardware, and that the usual dev_handle used by
userspace to identify them are not accessible CSID
side, the lane_assign/lane_cfg parameter is used to find
the specific PHY instance used in conjunction with the
CSID instance in a session. lane_assign from PHY driver
and lane_cfg from CSID have the same values.
CRs-Fixed: 3259706
Change-Id: Ie050b1b9e742c6a63812eb38db7eca76db24667f
Signed-off-by: Li Sha Lim <quic_lishlim@quicinc.com>