linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Matthias Brugger <matthias.bgg@gmail.com>
To: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Cc: roger.lu@mediatek.com, khilman@baylibre.com,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org,
	nfraprado@collabora.com, kernel@collabora.com
Subject: Re: [PATCH 2/6] soc: mediatek: mtk-svs: Switch to platform_get_irq()
Date: Thu, 25 Aug 2022 15:26:38 +0200	[thread overview]
Message-ID: <c757c143-44b4-a6f9-299a-6a35b05d9f64@gmail.com> (raw)
In-Reply-To: <20220726141653.177948-3-angelogioacchino.delregno@collabora.com>



On 26/07/2022 16:16, AngeloGioacchino Del Regno wrote:
> Instead of using irq_of_parse_and_map() to retrieve the interrupt from
> devicetree, switch to platform_get_irq() instead: this function will
> conveniently also write an error message in case the irq is not found.
> 
> Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>

Applied, thanks.

> ---
>   drivers/soc/mediatek/mtk-svs.c | 10 +++++++---
>   1 file changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/soc/mediatek/mtk-svs.c b/drivers/soc/mediatek/mtk-svs.c
> index 600492dc334c..ee990acfc2d5 100644
> --- a/drivers/soc/mediatek/mtk-svs.c
> +++ b/drivers/soc/mediatek/mtk-svs.c
> @@ -2757,8 +2757,7 @@ static struct svs_platform *svs_platform_probe(struct platform_device *pdev)
>   static int svs_probe(struct platform_device *pdev)
>   {
>   	struct svs_platform *svsp;
> -	unsigned int svsp_irq;
> -	int ret;
> +	int svsp_irq, ret;
>   
>   	svsp = svs_platform_probe(pdev);
>   	if (IS_ERR(svsp))
> @@ -2776,7 +2775,12 @@ static int svs_probe(struct platform_device *pdev)
>   		goto svs_probe_free_resource;
>   	}
>   
> -	svsp_irq = irq_of_parse_and_map(svsp->dev->of_node, 0);
> +	svsp_irq = platform_get_irq(pdev, 0);
> +	if (svsp_irq < 0) {
> +		ret = svsp_irq;
> +		goto svs_probe_free_resource;
> +	}
> +
>   	ret = devm_request_threaded_irq(svsp->dev, svsp_irq, NULL, svs_isr,
>   					svsp->irqflags | IRQF_ONESHOT,
>   					svsp->name, svsp);

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-08-25 13:27 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-26 14:16 [PATCH 0/6] soc: mediatek: Cleanups for MediaTek SVS driver AngeloGioacchino Del Regno
2022-07-26 14:16 ` [PATCH 1/6] soc: mediatek: mtk-svs: Commonize t-calibration-data fuse array read AngeloGioacchino Del Regno
2022-08-25 13:27   ` Matthias Brugger
2022-07-26 14:16 ` [PATCH 2/6] soc: mediatek: mtk-svs: Switch to platform_get_irq() AngeloGioacchino Del Regno
2022-08-25 13:26   ` Matthias Brugger [this message]
2022-07-26 14:16 ` [PATCH 3/6] soc: mediatek: mtk-svs: Remove hardcoded irqflags AngeloGioacchino Del Regno
2022-08-25 13:28   ` Matthias Brugger
2022-07-26 14:16 ` [PATCH 4/6] soc: mediatek: mtk-svs: Drop of_match_ptr() for of_match_table AngeloGioacchino Del Regno
2022-08-25 13:28   ` Matthias Brugger
2022-07-26 14:16 ` [PATCH 5/6] soc: mediatek: mtk-svs: Use devm variant for dev_pm_opp_of_add_table() AngeloGioacchino Del Regno
2022-08-25 13:28   ` Matthias Brugger
2022-07-26 14:16 ` [PATCH 6/6] soc: mediatek: mtk-svs: Use bitfield access macros where possible AngeloGioacchino Del Regno
2022-08-25 13:29   ` Matthias Brugger
2022-08-25 18:50     ` Nícolas F. R. A. Prado
2022-08-29  9:36       ` AngeloGioacchino Del Regno
2022-08-29  9:33     ` AngeloGioacchino Del Regno
2022-08-29 11:02       ` Matthias Brugger
2022-07-26 14:22 ` [PATCH 0/6] soc: mediatek: Cleanups for MediaTek SVS driver AngeloGioacchino Del Regno

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=c757c143-44b4-a6f9-299a-6a35b05d9f64@gmail.com \
    --to=matthias.bgg@gmail.com \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=kernel@collabora.com \
    --cc=khilman@baylibre.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=nfraprado@collabora.com \
    --cc=roger.lu@mediatek.com \
    /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).