]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/ocrdma: Use bitmap_zalloc() when applicable
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Thu, 25 Nov 2021 19:34:10 +0000 (20:34 +0100)
committerJason Gunthorpe <jgg@nvidia.com>
Mon, 29 Nov 2021 18:33:55 +0000 (14:33 -0400)
commite86320a3187faff198bdf5f51957691fd9cc0fb7
treef4ca66c0c69275f600d0295fb98f45a11fdffa25
parente0b2c4663ef01ae7cd2b6cc15902e191507bf59d
RDMA/ocrdma: Use bitmap_zalloc() when applicable

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.

Link: https://lore.kernel.org/r/b157f9e1586fb4d1083cb4058d7ac81b10bb86d7.1637868728.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/hw/ocrdma/ocrdma_hw.c