From: Guenter Roeck <linux@roeck-us.net>
To: Tiezhu Yang <yangtiezhu@loongson.cn>,
Wim Van Sebroeck <wim@linux-watchdog.org>,
Florian Fainelli <f.fainelli@gmail.com>,
Ray Jui <rjui@broadcom.com>,
Scott Branden <sbranden@broadcom.com>
Cc: bcm-kernel-feedback-list@broadcom.com,
linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org,
Xuefeng Li <lixuefeng@loongson.cn>
Subject: Re: [PATCH] watchdog: bcm_kona_wdt: Use correct return value for bcm_kona_wdt_probe()
Date: Mon, 25 May 2020 06:47:51 -0700 [thread overview]
Message-ID: <99e82049-2d99-9a8e-4023-96f585b47e30@roeck-us.net> (raw)
In-Reply-To: <1590391864-308-1-git-send-email-yangtiezhu@loongson.cn>
On 5/25/20 12:31 AM, Tiezhu Yang wrote:
> When call function devm_platform_ioremap_resource(), we should use IS_ERR()
> to check the return value and return PTR_ERR() if failed.
>
> Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
> ---
> drivers/watchdog/bcm_kona_wdt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/watchdog/bcm_kona_wdt.c b/drivers/watchdog/bcm_kona_wdt.c
> index eb850a8..8237c4e 100644
> --- a/drivers/watchdog/bcm_kona_wdt.c
> +++ b/drivers/watchdog/bcm_kona_wdt.c
> @@ -279,7 +279,7 @@ static int bcm_kona_wdt_probe(struct platform_device *pdev)
>
> wdt->base = devm_platform_ioremap_resource(pdev, 0);
> if (IS_ERR(wdt->base))
> - return -ENODEV;
> + return PTR_ERR(wdt->base);
>
> wdt->resolution = SECWDOG_DEFAULT_RESOLUTION;
> ret = bcm_kona_wdt_set_resolution_reg(wdt);
>
next prev parent reply other threads:[~2020-05-25 13:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-25 7:31 [PATCH] watchdog: bcm_kona_wdt: Use correct return value for bcm_kona_wdt_probe() Tiezhu Yang
2020-05-25 13:47 ` Guenter Roeck [this message]
2020-07-06 8:56 ` Tiezhu Yang
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=99e82049-2d99-9a8e-4023-96f585b47e30@roeck-us.net \
--to=linux@roeck-us.net \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=f.fainelli@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=lixuefeng@loongson.cn \
--cc=rjui@broadcom.com \
--cc=sbranden@broadcom.com \
--cc=wim@linux-watchdog.org \
--cc=yangtiezhu@loongson.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.