OSDN Git Service

dma-buf: Report signaled links inside dma-fence-chain
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 9 Apr 2020 11:01:00 +0000 (12:01 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 9 Apr 2020 18:52:03 +0000 (19:52 +0100)
commit5de376bb434f80a13138f0ebedc8351ab73d8b0d
treeffaaba4b130e7f4e1116a291d89bd719ba12dca0
parent29da47cfc1f0c3aad0daa89ccf284c3465971482
dma-buf: Report signaled links inside dma-fence-chain

Whenever we walk along the dma-fence-chain, we prune signaled links to
keep the chain nice and tidy. This leads to situations where we can
prune a link and report the earlier fence as the target seqno --
violating our own consistency checks that the seqno is not more advanced
than the last element in a dma-fence-chain.

Report a NULL fence and success if the seqno has already been signaled.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Tested-by: Venkata Sandeep Dhanalakota <venkata.s.dhanalakota@intel.com>
Reviewed-by: Venkata Sandeep Dhanalakota <venkata.s.dhanalakota@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200409110101.18400-2-chris@chris-wilson.co.uk
drivers/dma-buf/dma-fence-chain.c