Commit Graph

13 Commits

Author SHA1 Message Date
Amir Suhail
51b2182fea msm: synx: Fixing cleanup of merge synx and dma fences
1. dma fence framework takes care of putting the child dma fence reference
when the array fence is being destroyed. Synx shouldn't put the child
dma fence reference taken for dma fence array.
2. When destroying the child dma fence we have to signal the fence if
synx has taken the last reference. If there are more than 1 reference on
dma fence, then check if the other references are from merge fences
instead of any client taking direct reference on the dma fence.

Change-Id: I8b0879b8c1d2401cdd08f85ae330b74af99a2dad
Signed-off-by: Amir Suhail <quic_asuhail@quicinc.com>
(cherry picked from commit a2795fd6f5)
2024-02-07 01:57:14 -08:00
Amir Suhail
d5bed2898a msm: synx: Fixing import of dma-fence checks
1. invalid values is being passed to fence variable because of
   improper position of DMA_FENCE flag check.
2. added dma_fence_put for the reference taken by sync_file_get_fence.

Change-Id: I6f2a8f2041149bd3553967aee5ee3e1626993adf
Signed-off-by: Amir Suhail <quic_asuhail@quicinc.com>
2023-12-20 19:40:21 +05:30
Priyanko Sarkar
2993c7c4d6 msm: debugfs v2 changes
1. Prints Global shared memory & hashtables on console.
 2. Provides flexibility to select tables and columns.
 3. Provides option to specify handle range.
 4. Option to print details of specific handle.

Change-Id: I974cb16004328aa81020c008b486b4a78167f7be
Signed-off-by: Priyanko Sarkar <quic_priyanko@quicinc.com>
2023-08-03 02:53:44 -07:00
Urvesh Rathod
d87e10c694 msm: synx: async_wait timeout changes
Adding timeout parameter for async wait so the callback
will be invoked on timer expiry if not signalled.

Change-Id: Ia31f59021f00befed5317fdac262d823c659c6bf
Signed-off-by: Ram Nagesh <quic_ramnages@quicinc.com>
Signed-off-by: Urvesh Rathod <quic_urathod@quicinc.com>
2023-07-03 02:11:34 -07:00
Urvesh Rathod
e7e3b4aaac msm: synx: Custom signal support
This change ensures clients can send anything greater
than 64 as custom status from APSS to other cores.

Change-Id: Ib7f507e666fe0b60c5fc09f90652a09e15634376
Signed-off-by: Urvesh Rathod <quic_urathod@quicinc.com>
2023-06-06 10:59:33 +05:30
qctecmdr
a2aea0f81c Merge "msm: synx: Releases global handle index if handle is not signaled" 2023-05-19 00:24:27 -07:00
Urvesh Rathod
6b566f4639 msm: synx: Releases global handle index if handle is not signaled
This change provides fix for below issues :
1. If local handle is imported as global, synx takes extra reference
   on global handles which were not released because on signal
   callback data had local handle instead of global causing handle
   leak.
2. If all the child handles of merge fence are local and
   merged fence is global, upon merge its signaled incorrectly
   as num_child == 0 even if no one signaled merged fence.
3. During merge synx takes one reference each child dma fences.
   When merged fence is released, dma fence reference of child handles
   were not released causing handle/dma fence leak. This change
   signals underlying child fences if the merged handle is ACTIVE
   during release and release reference on dma fence.
4. If local handle is imported as global, map_count was not getting
   incremented because of which object was destroyed more than once.
   This change increases the map_count variable when local handle is
   imported as global or vice-versa.
5. In synx_signal API, synx_signal_offload_job followed by signaling
   dma fence. synx_signal_offload_job internally calls
   synx_signal_handler which signals dma fence and because of which
   sometimes synx_signal was returning failure. This fix ensures that
   synx_signal_handler does not overtake synx signal API.

Change-Id: Ia8d2eb969514347cac30f8ae33ce2028119dfd47
Signed-off-by: Urvesh Rathod <quic_urathod@quicinc.com>
2023-05-19 00:45:47 +05:30
Urvesh Rathod
888868eca3 msm: synx: Dipatching un-released callbacks during release
This change ensures that any undispatched callbacks are released
while destroying object if handle is not signaled.

Change-Id: I18ee66b9a6ceb390df4d5f5c4f4cd77c5f9f2090
Signed-off-by: Urvesh Rathod <quic_urathod@quicinc.com>
2023-05-09 18:50:22 +05:30
Pravin Kumar Ravi
a1825820d5 msm: synx: Move dprintk outside spinlock
synx_client_destroy prints a log holding a spinlock which causes
watchdog bite due to excessive log. This change prints the log after
releasing the lock.

Change-Id: I42021fd8d07cc595a31a0396f138ac18bcb5bd0f
Signed-off-by: Pravin Kumar Ravi <quic_pravinku@quicinc.com>
2023-04-26 17:22:46 -07:00
Urvesh Rathod
d120b83d98 msm: synx: Adding merge API support for synx V2
This change enables clients to signal synx merged handles
from same and other cores. This change also ensures
that underlying child dma fences are signaled when composite
synx handle is signaled from other core.

Change-Id: Ib81bc2291c85b93fe11eddf5d0ce450bbe486c83
Signed-off-by: Urvesh Rathod <quic_urathod@quicinc.com>
2023-03-21 18:07:43 +05:30
Pravin Kumar Ravi
33788f7297 synx: Propagating changes from msm-5.10
Includes param change for async_wait(timeout) and other fixes

Change-Id: If8ff795538bbfaf53ee1758561fbd2841e5a71c7
Signed-off-by: Pravin Kumar Ravi <quic_pravinku@quicinc.com>
2023-02-21 17:02:26 -08:00
Pravin Kumar Ravi
eeb75f9c23 synx: support ICP core
This change adds necessary functionality to support ICP core.

Change-Id: I55793f6508ae5d7180b0f50d477e366842199148
Signed-off-by: Pravin Kumar Ravi <quic_pravinku@quicinc.com>
2023-01-30 16:13:38 -08:00
NITIN LAXMIDAS NAIK
25cb61693a msm: synx: build script as DLKM for Vendor SI
added mk and Kbuild script to support building synx driver as external module for Vendor SI

Change-Id: Ib66325d115ca46e6b61de1e168e85d09419f73e2
Signed-off-by: NITIN LAXMIDAS NAIK <quic_nitinlax@quicinc.com>
2022-09-15 10:11:42 -07:00