From: Neil Armstrong <narmstrong@baylibre.com>
To: Tang Bin <tangbin@cmss.chinamobile.com>,
clabbe@baylibre.com, herbert@gondor.apana.org.au,
davem@davemloft.net
Cc: linux-amlogic@lists.infradead.org, linux-crypto@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] crypto:amlogic - use platform_get_irq_optional()
Date: Thu, 2 Apr 2020 15:26:18 +0200 [thread overview]
Message-ID: <c43b85f8-2bc9-7b19-6b86-953246c88d2c@baylibre.com> (raw)
In-Reply-To: <20200402113344.16772-1-tangbin@cmss.chinamobile.com>
Hi,
On 02/04/2020 13:33, Tang Bin wrote:
> In order to simply code,because platform_get_irq() already has
> dev_err() message.
>
> Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com>
> ---
> drivers/crypto/amlogic/amlogic-gxl-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/crypto/amlogic/amlogic-gxl-core.c b/drivers/crypto/amlogic/amlogic-gxl-core.c
> index 9d4ead2f7..37901bd81 100644
> --- a/drivers/crypto/amlogic/amlogic-gxl-core.c
> +++ b/drivers/crypto/amlogic/amlogic-gxl-core.c
> @@ -252,7 +252,7 @@ static int meson_crypto_probe(struct platform_device *pdev)
>
> mc->irqs = devm_kcalloc(mc->dev, MAXFLOW, sizeof(int), GFP_KERNEL);
> for (i = 0; i < MAXFLOW; i++) {
> - mc->irqs[i] = platform_get_irq(pdev, i);
> + mc->irqs[i] = platform_get_irq_optional(pdev, i);
> if (mc->irqs[i] < 0) {
> dev_err(mc->dev, "Cannot get IRQ for flow %d\n", i);
> return mc->irqs[i];
>
NACK, the irq is not optional, I don't see why platform_get_irq_optional() should be used here
and how it could "simply code".
Neil
next prev parent reply other threads:[~2020-04-02 13:26 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-02 11:33 [PATCH] crypto:amlogic - use platform_get_irq_optional() Tang Bin
2020-04-02 13:26 ` Neil Armstrong [this message]
[not found] ` <202004022329105659148@cmss.chinamobile.com>
2020-04-02 15:35 ` Neil Armstrong
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=c43b85f8-2bc9-7b19-6b86-953246c88d2c@baylibre.com \
--to=narmstrong@baylibre.com \
--cc=clabbe@baylibre.com \
--cc=davem@davemloft.net \
--cc=herbert@gondor.apana.org.au \
--cc=linux-amlogic@lists.infradead.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tangbin@cmss.chinamobile.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).