linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case
@ 2019-04-24 14:49 Fabien Dessenne
  2019-04-25  7:58 ` Christophe Kerello
  2019-05-20 14:31 ` Miquel Raynal
  0 siblings, 2 replies; 3+ messages in thread
From: Fabien Dessenne @ 2019-04-24 14:49 UTC (permalink / raw)
  To: Boris Brezillon, Miquel Raynal, Richard Weinberger,
	David Woodhouse, Brian Norris, Marek Vasut, Maxime Coquelin,
	Alexandre Torgue, Christophe Kerello, linux-mtd, linux-stm32,
	linux-arm-kernel, linux-kernel
  Cc: Fabien Dessenne

During probe, check the "get_irq" error value.

Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
---
 drivers/mtd/nand/raw/stm32_fmc2_nand.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/mtd/nand/raw/stm32_fmc2_nand.c b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
index 999ca6a..4aabea2 100644
--- a/drivers/mtd/nand/raw/stm32_fmc2_nand.c
+++ b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
@@ -1909,6 +1909,12 @@ static int stm32_fmc2_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_fmc2_irq, 0,
 			       dev_name(dev), fmc2);
 	if (ret) {
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case
  2019-04-24 14:49 [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case Fabien Dessenne
@ 2019-04-25  7:58 ` Christophe Kerello
  2019-05-20 14:31 ` Miquel Raynal
  1 sibling, 0 replies; 3+ messages in thread
From: Christophe Kerello @ 2019-04-25  7:58 UTC (permalink / raw)
  To: Fabien Dessenne, Boris Brezillon, Miquel Raynal,
	Richard Weinberger, David Woodhouse, Brian Norris, Marek Vasut,
	Maxime Coquelin, Alexandre Torgue, linux-mtd, linux-stm32,
	linux-arm-kernel, linux-kernel



On 4/24/19 4:49 PM, Fabien Dessenne wrote:
> During probe, check the "get_irq" error value.
> 
> Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>

Acked-by: Christophe Kerello <christophe.kerello@st.com>

> ---
>   drivers/mtd/nand/raw/stm32_fmc2_nand.c | 6 ++++++
>   1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/mtd/nand/raw/stm32_fmc2_nand.c b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> index 999ca6a..4aabea2 100644
> --- a/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> +++ b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> @@ -1909,6 +1909,12 @@ static int stm32_fmc2_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_fmc2_irq, 0,
>   			       dev_name(dev), fmc2);
>   	if (ret) {
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case
  2019-04-24 14:49 [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case Fabien Dessenne
  2019-04-25  7:58 ` Christophe Kerello
@ 2019-05-20 14:31 ` Miquel Raynal
  1 sibling, 0 replies; 3+ messages in thread
From: Miquel Raynal @ 2019-05-20 14:31 UTC (permalink / raw)
  To: Fabien Dessenne
  Cc: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Maxime Coquelin, Alexandre Torgue,
	Christophe Kerello, linux-mtd, linux-stm32, linux-arm-kernel,
	linux-kernel

Hi Fabien,

Fabien Dessenne <fabien.dessenne@st.com> wrote on Wed, 24 Apr 2019
16:49:06 +0200:

> During probe, check the "get_irq" error value.
> 
> Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
> ---
>  drivers/mtd/nand/raw/stm32_fmc2_nand.c | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/drivers/mtd/nand/raw/stm32_fmc2_nand.c b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> index 999ca6a..4aabea2 100644
> --- a/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> +++ b/drivers/mtd/nand/raw/stm32_fmc2_nand.c
> @@ -1909,6 +1909,12 @@ static int stm32_fmc2_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_fmc2_irq, 0,
>  			       dev_name(dev), fmc2);
>  	if (ret) {


Applied to nand/next.

Thanks,
Miquèl

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-05-20 14:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-24 14:49 [PATCH] mtd: rawnand: stm32_fmc2: manage the get_irq error case Fabien Dessenne
2019-04-25  7:58 ` Christophe Kerello
2019-05-20 14:31 ` Miquel Raynal

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).