mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mukesh Ojha <mojha@codeaurora.org>
To: Dan Carpenter <dan.carpenter@oracle.com>,
	Florian Fainelli <f.fainelli@gmail.com>
Cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] vlynq: Fix uninitialized error code in probe()
Date: Thu, 28 Mar 2019 20:01:45 +0530	[thread overview]
Message-ID: <9a8d9a48-e95d-8607-5181-f264bcabd3c8@codeaurora.org> (raw)
In-Reply-To: <20190328141742.GM32590@kadam>


On 3/28/2019 7:47 PM, Dan Carpenter wrote:
> The "result" variable isn't initialized on this error path.
>
> Fixes: 55e331cf7ebe ("drivers: add support for the TI VLYNQ bus")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Mukesh Ojha <mojha@codeaurora.org>

-Mukesh
> ---
>   drivers/vlynq/vlynq.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/vlynq/vlynq.c b/drivers/vlynq/vlynq.c
> index c0227f9418eb..44d3485d1108 100644
> --- a/drivers/vlynq/vlynq.c
> +++ b/drivers/vlynq/vlynq.c
> @@ -727,7 +727,8 @@ static int vlynq_probe(struct platform_device *pdev)
>   	dev->local_irq = dev->irq_end - dev->irq_start;
>   	dev->remote_irq = dev->local_irq - 1;
>   
> -	if (device_register(&dev->dev))
> +	result = device_register(&dev->dev);
> +	if (result)
>   		goto fail_register;
>   	platform_set_drvdata(pdev, dev);
>   

  reply	other threads:[~2019-03-28 14:31 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-28 14:17 Dan Carpenter
2019-03-28 14:31 ` Mukesh Ojha [this message]
2019-03-28 17:01 ` Florian Fainelli

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=9a8d9a48-e95d-8607-5181-f264bcabd3c8@codeaurora.org \
    --to=mojha@codeaurora.org \
    --cc=dan.carpenter@oracle.com \
    --cc=f.fainelli@gmail.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /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

Powered by JetHome