]> git.baikalelectronics.ru Git - kernel.git/commit
dma-buf: Use atomic_fetch_add() for the context id
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 13 May 2020 07:47:47 +0000 (08:47 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 13 May 2020 12:38:59 +0000 (13:38 +0100)
commit280bf5fe8fe66b4269353925f2f8be8c107cbae7
tree06a1acc1f0cd38f59b2b4b6adc653d7a0a461daa
parent053208378985231455c8b69d82755ed425c1de89
dma-buf: Use atomic_fetch_add() for the context id

Now that atomic64_fetch_add() exists we can use it to return the base
context id, rather than the atomic64_add_return(N) - N concoction.

Suggested-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Reviewed-by: Maciej Patelczyk <maciej.patelczyk@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200513074809.18194-2-chris@chris-wilson.co.uk
drivers/dma-buf/dma-fence.c