mirror of
https://github.com/torvalds/linux.git
synced 2024-11-26 22:21:42 +00:00
spi: stm32-qspi: manage the get_irq error case
During probe, check the "get_irq" error value. Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com> Acked-by: Ludovic Barre <ludovic.barre@st.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
8b7bd10eb0
commit
4b562de4e2
@ -574,6 +574,12 @@ static int stm32_qspi_probe(struct platform_device *pdev)
|
||||
}
|
||||
|
||||
irq = platform_get_irq(pdev, 0);
|
||||
if (irq < 0) {
|
||||
if (irq != -EPROBE_DEFER)
|
||||
dev_err(dev, "IRQ error missing or invalid\n");
|
||||
return irq;
|
||||
}
|
||||
|
||||
ret = devm_request_irq(dev, irq, stm32_qspi_irq, 0,
|
||||
dev_name(dev), qspi);
|
||||
if (ret) {
|
||||
|
Loading…
Reference in New Issue
Block a user