]> git.baikalelectronics.ru Git - kernel.git/commit
dma-mapping: use 'bitmap_zalloc()' when applicable
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 24 Oct 2021 17:40:23 +0000 (19:40 +0200)
committerChristoph Hellwig <hch@lst.de>
Wed, 27 Oct 2021 06:20:09 +0000 (08:20 +0200)
commit0c932ca047bf790cdd49b1563d50c2a48fc7d058
tree0be05b49287ea696ecbb850bfc19d2036f15a1cf
parent750ac74067eb5b3e964797eb196524247aec3372
dma-mapping: use 'bitmap_zalloc()' when applicable

'dma_mem->bitmap' is a bitmap. So use 'bitmap_zalloc()' to simplify code,
improve the semantic and avoid some open-coded arithmetic in allocator
arguments.

Also change the corresponding 'kfree()' into 'bitmap_free()' to keep
consistency.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Christoph Hellwig <hch@lst.de>
kernel/dma/coherent.c