Commit 3e53ef91 authored by Fabien Dessenne's avatar Fabien Dessenne Committed by Jonathan Cameron
Browse files

iio: adc: stm32-dfsdm: manage the get_irq error case



During probe, check the "get_irq" error value.

Signed-off-by: default avatarFabien Dessenne <fabien.dessenne@st.com>
Acked-by: default avatarFabrice Gasnier <fabrice.gasnier@st.com>
Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 17b62779
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1456,6 +1456,12 @@ static int stm32_dfsdm_adc_probe(struct platform_device *pdev)
	 * So IRQ associated to filter instance 0 is dedicated to the Filter 0.
	 */
	irq = platform_get_irq(pdev, 0);
	if (irq < 0) {
		if (irq != -EPROBE_DEFER)
			dev_err(dev, "Failed to get IRQ: %d\n", irq);
		return irq;
	}

	ret = devm_request_irq(dev, irq, stm32_dfsdm_irq,
			       0, pdev->name, adc);
	if (ret < 0) {