1. 27 Apr, 2021 1 commit
    • Puranam V G Tejaswi's avatar
      msm: kgsl: Fix spinlock recursion issues · b6c5beaa
      Puranam V G Tejaswi authored
      Currently there is a possibility of spinlock recursion in
      kgsl_timeline_signal and kgsl_ioctl_timeline_destroy. The issue can happen
      if two fences are created on a timeline and KGSL_TIMELINE_WAIT_ANY flag is
      used. First fence is signalled and once the wait is complete, second fence
      is signalled. This results in a spinlock recursion as the release of first
      fence is called when the timeline->lock is held. Fix this by making sure
      that the lock to protect the list and lock used for dma_fence signalling
      are used correctly. Also make fence_lock per timeline to reduce lock
      contention among different timelines.
      Change-Id: I547d62f29d4407fceca9bd766d8e9f93a88b5c6f
      Signed-off-by: default avatarPuranam V G Tejaswi <pvgtejas@codeaurora.org>
  2. 23 Apr, 2021 1 commit
  3. 25 Mar, 2021 1 commit
    • Deepak Kumar's avatar
      msm: kgsl: Fix race between timeline create/others and destroy ioctls · 5a9059f4
      Deepak Kumar authored
      When creating a timeline allocate an ID but don't populate the slot
      with the timeline pointer until we are done initializing the timeline.
      This avoids a race if somebody tries to free the same identifier before
      the create operation is complete. Also, correct kgsl_timeline_by_id
      function by doing idr_find and refcount increase under same lock. This
      eliminates the chance that a timeline will be destroyed while somebody
      is still using it.
      Change-Id: Id894baac1bbd6042f668ea4afca39fae3b5a2d86
      Signed-off-by: default avatarDeepak Kumar <dkumar@codeaurora.org>
  4. 15 Sep, 2020 1 commit
    • Jordan Crouse's avatar
      msm: kgsl: Add software timelines · 36b196ce
      Jordan Crouse authored
      Some graphics APIs want the ability to create and use timelines
      with 64 bit sequence numbers to synchronize between threads.
      Add support for timelines that can be created, signaled and managed from
      user space. Timelines can also be signaled from a draw context command
      stream via an auxiliary command and a wait can be added as a sync object
      to any GPU command.
      Change-Id: Ic0dedbad0ffc99cc309951369eaf85b56727802c
      Signed-off-by: default avatarJordan Crouse <jcrouse@codeaurora.org>