We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fa55b7d commit 1ed9b96Copy full SHA for 1ed9b96
drivers/pci/controller/pci-xgene-msi.c
@@ -269,9 +269,7 @@ static void xgene_free_domains(struct xgene_msi *msi)
269
270
static int xgene_msi_init_allocator(struct xgene_msi *xgene_msi)
271
{
272
- int size = BITS_TO_LONGS(NR_MSI_VEC) * sizeof(long);
273
-
274
- xgene_msi->bitmap = kzalloc(size, GFP_KERNEL);
+ xgene_msi->bitmap = bitmap_zalloc(NR_MSI_VEC, GFP_KERNEL);
275
if (!xgene_msi->bitmap)
276
return -ENOMEM;
277
@@ -360,7 +358,7 @@ static int xgene_msi_remove(struct platform_device *pdev)
360
358
361
359
kfree(msi->msi_groups);
362
363
- kfree(msi->bitmap);
+ bitmap_free(msi->bitmap);
364
msi->bitmap = NULL;
365
366
xgene_free_domains(msi);
0 commit comments