From: "irqchip-bot for Andy Shevchenko" <tip-bot2@linutronix.de>
To: linux-kernel@vger.kernel.org
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Marc Zyngier <maz@kernel.org>,
tglx@linutronix.de
Subject: [irqchip: irq/irqchip-next] irqchip/alpine-msi: Switch to bitmap_zalloc()
Date: Mon, 26 Jul 2021 17:12:29 -0000 [thread overview]
Message-ID: <162731954972.395.4894923090543170959.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20210618151657.65305-2-andriy.shevchenko@linux.intel.com>
The following commit has been merged into the irq/irqchip-next branch of irqchip:
Commit-ID: 3f1808f63f0458762403549b3d975ef6e971b6e0
Gitweb: https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/3f1808f63f0458762403549b3d975ef6e971b6e0
Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
AuthorDate: Fri, 18 Jun 2021 18:16:52 +03:00
Committer: Marc Zyngier <maz@kernel.org>
CommitterDate: Mon, 26 Jul 2021 18:01:44 +01:00
irqchip/alpine-msi: Switch to bitmap_zalloc()
Switch to bitmap_zalloc() to show clearly what we are allocating.
Besides that it returns pointer of bitmap type instead of opaque void *.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20210618151657.65305-2-andriy.shevchenko@linux.intel.com
---
drivers/irqchip/irq-alpine-msi.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/irqchip/irq-alpine-msi.c b/drivers/irqchip/irq-alpine-msi.c
index ede02dc..5ddb8e5 100644
--- a/drivers/irqchip/irq-alpine-msi.c
+++ b/drivers/irqchip/irq-alpine-msi.c
@@ -267,9 +267,7 @@ static int alpine_msix_init(struct device_node *node,
goto err_priv;
}
- priv->msi_map = kcalloc(BITS_TO_LONGS(priv->num_spis),
- sizeof(*priv->msi_map),
- GFP_KERNEL);
+ priv->msi_map = bitmap_zalloc(priv->num_spis, GFP_KERNEL);
if (!priv->msi_map) {
ret = -ENOMEM;
goto err_priv;
@@ -285,7 +283,7 @@ static int alpine_msix_init(struct device_node *node,
return 0;
err_map:
- kfree(priv->msi_map);
+ bitmap_free(priv->msi_map);
err_priv:
kfree(priv);
return ret;
next prev parent reply other threads:[~2021-07-26 17:26 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-18 15:16 [PATCH v1 1/7] irqchip: Switch to bitmap_zalloc() Andy Shevchenko
2021-06-18 15:16 ` [PATCH v1 2/7] irqchip/alpine-msi: " Andy Shevchenko
2021-07-26 17:12 ` irqchip-bot for Andy Shevchenko [this message]
2021-06-18 15:16 ` [PATCH v1 3/7] irqchip/gic-v2m: " Andy Shevchenko
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] " irqchip-bot for Andy Shevchenko
2021-06-18 15:16 ` [PATCH v1 4/7] irqchip/gic-v3: " Andy Shevchenko
2021-07-26 17:05 ` Marc Zyngier
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] " irqchip-bot for Andy Shevchenko
2021-06-18 15:16 ` [PATCH v1 5/7] irqchip/ls-scfg-msi: Switch to devm_bitmap_zalloc() Andy Shevchenko
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] " irqchip-bot for Andy Shevchenko
2021-06-18 15:16 ` [PATCH v1 6/7] irqchip/mvebu-gicp: " Andy Shevchenko
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] " irqchip-bot for Andy Shevchenko
2021-06-18 15:16 ` [PATCH v1 7/7] irqchip/mvebu-odmi: Switch to bitmap_zalloc() Andy Shevchenko
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] " irqchip-bot for Andy Shevchenko
2021-07-26 17:12 ` [irqchip: irq/irqchip-next] irqchip/partitions: " irqchip-bot for Andy Shevchenko
2021-07-26 17:12 ` [PATCH v1 1/7] irqchip: " Marc Zyngier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=162731954972.395.4894923090543170959.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=andriy.shevchenko@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=maz@kernel.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).