]> www.infradead.org Git - users/dwmw2/linux.git/commit
dma-buf: add a warning when drv try to reserve 0 fence slots
authorChristian König <ckoenig.leichtzumerken@gmail.com>
Wed, 29 May 2024 08:43:22 +0000 (10:43 +0200)
committerChristian König <christian.koenig@amd.com>
Fri, 31 May 2024 08:12:52 +0000 (10:12 +0200)
commitc9402efe492bb46ccbf94fedc4783eb8f8747567
tree9e13353300e31e6340b00c6a11cdae66ab57f762
parentc4e3267868e1debb3d87d21a36efc8a2255298e2
dma-buf: add a warning when drv try to reserve 0 fence slots

When dma_resv_reserve_fences() is called with num_fences=0 it usually
means that a driver or other component messed up its calculation how
many fences are needed. Warn in that situation.

When no fence are needed the function shouldn't be called in the first
place.

Signed-off-by: Christian König <christian.koenig@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240529084322.2284-1-christian.koenig@amd.com
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
drivers/dma-buf/dma-resv.c