summaryrefslogtreecommitdiff
path: root/drivers/mfd/sprd-sc27xx-spi.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mfd/sprd-sc27xx-spi.c')
-rw-r--r--drivers/mfd/sprd-sc27xx-spi.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/mfd/sprd-sc27xx-spi.c b/drivers/mfd/sprd-sc27xx-spi.c
index 3460ef07623c..69df27769c21 100644
--- a/drivers/mfd/sprd-sc27xx-spi.c
+++ b/drivers/mfd/sprd-sc27xx-spi.c
@@ -199,8 +199,9 @@ static int sprd_pmic_probe(struct spi_device *spi)
ddata->irq_chip.num_irqs = pdata->num_irqs;
ddata->irq_chip.mask_invert = true;
- ddata->irqs = devm_kzalloc(&spi->dev, sizeof(struct regmap_irq) *
- pdata->num_irqs, GFP_KERNEL);
+ ddata->irqs = devm_kcalloc(&spi->dev,
+ pdata->num_irqs, sizeof(struct regmap_irq),
+ GFP_KERNEL);
if (!ddata->irqs)
return -ENOMEM;