mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Winiarska, Iwona" <iwona.winiarska@intel.com>
To: "andrew@aj.id.au" <andrew@aj.id.au>,
	"cgel.zte@gmail.com" <cgel.zte@gmail.com>,
	"joel@jms.id.au" <joel@jms.id.au>
Cc: "lv.ruyi@zte.com.cn" <lv.ruyi@zte.com.cn>,
	"jae.hyun.yoo@linux.intel.com" <jae.hyun.yoo@linux.intel.com>,
	"zealci@zte.com.cn" <zealci@zte.com.cn>,
	"linux-aspeed@lists.ozlabs.org" <linux-aspeed@lists.ozlabs.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"pierre-louis.bossart@linux.intel.com" 
	<pierre-louis.bossart@linux.intel.com>,
	"openbmc@lists.ozlabs.org" <openbmc@lists.ozlabs.org>
Subject: Re: [PATCH] peci: fix error check return value of platform_get_irq()
Date: Tue, 12 Apr 2022 21:12:36 +0000	[thread overview]
Message-ID: <d09484f7cda13de3f156bd1bcba8c2671495dcd1.camel@intel.com> (raw)
In-Reply-To: <20220412090148.2533219-1-lv.ruyi@zte.com.cn>

On Tue, 2022-04-12 at 09:01 +0000, cgel.zte@gmail.com wrote:
> From: Lv Ruyi <lv.ruyi@zte.com.cn>

Thanks for the fix. Can we prefix the subject with "peci: aspeed:"? Just to
distinguish changes related to specific controller from the ones touching peci-
core.

> 
> platform_get_irq() return negative value on failure, so null check of
> priv->irq is incorrect. Fix it by comparing whether it is less than zero.
> 
> Fixes: a85e4c52086c ("peci: Add peci-aspeed controller driver")
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: Lv Ruyi <lv.ruyi@zte.com.cn>

Reviewed-by: Iwona Winiarska <iwona.winiarska@intel.com>

-Iwona

> ---
>  drivers/peci/controller/peci-aspeed.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/peci/controller/peci-aspeed.c
> b/drivers/peci/controller/peci-aspeed.c
> index 1925ddc13f00..731c5d8f75c6 100644
> --- a/drivers/peci/controller/peci-aspeed.c
> +++ b/drivers/peci/controller/peci-aspeed.c
> @@ -523,7 +523,7 @@ static int aspeed_peci_probe(struct platform_device *pdev)
>                 return PTR_ERR(priv->base);
>  
>         priv->irq = platform_get_irq(pdev, 0);
> -       if (!priv->irq)
> +       if (priv->irq < 0)
>                 return priv->irq;
>  
>         ret = devm_request_irq(&pdev->dev, priv->irq, aspeed_peci_irq_handler,

  reply	other threads:[~2022-04-12 23:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-12  9:01 cgel.zte
2022-04-12 21:12 ` Winiarska, Iwona [this message]
2022-04-13  1:04   ` [PATCH v2] peci: aspeed: " cgel.zte

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=d09484f7cda13de3f156bd1bcba8c2671495dcd1.camel@intel.com \
    --to=iwona.winiarska@intel.com \
    --cc=andrew@aj.id.au \
    --cc=cgel.zte@gmail.com \
    --cc=jae.hyun.yoo@linux.intel.com \
    --cc=joel@jms.id.au \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-aspeed@lists.ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lv.ruyi@zte.com.cn \
    --cc=openbmc@lists.ozlabs.org \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=zealci@zte.com.cn \
    /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

all inboxes | Powered by JetHome®