From: Timur Tabi <timur@codeaurora.org>
To: Wei Yongjun <weiyj.lk@gmail.com>
Cc: Wei Yongjun <weiyongjun1@huawei.com>, netdev@vger.kernel.org
Subject: Re: [PATCH -next] net: qcom/emac: fix return value check in emac_sgmii_config()
Date: Mon, 3 Oct 2016 14:41:11 -0500 [thread overview]
Message-ID: <57F2B457.70900@codeaurora.org> (raw)
In-Reply-To: <1475313149-15233-1-git-send-email-weiyj.lk@gmail.com>
Wei Yongjun wrote:
> From: Wei Yongjun<weiyongjun1@huawei.com>
>
> In case of error, the function ioremap() returns NULL pointer
> not ERR_PTR(). The IS_ERR() test in the return value check
> should be replaced with NULL test.
>
> Also add check for return value of platform_get_resource().
>
> Fixes: 54e19bc74f33 ("net: qcom/emac: do not use devm on internal
> phy pdev")
> Signed-off-by: Wei Yongjun<weiyongjun1@huawei.com>
Acked-by: Timur Tabi <timur@codeaurora.org>
Thanks for this. When I switched from devm_ioremap_resource() to
ioremap(), I didn't think to verify the return values.
--
Qualcomm Datacenter Technologies, Inc. as an affiliate of Qualcomm
Technologies, Inc. Qualcomm Technologies, Inc. is a member of the
Code Aurora Forum, a Linux Foundation Collaborative Project.
next prev parent reply other threads:[~2016-10-03 19:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-01 9:12 [PATCH -next] net: qcom/emac: fix return value check in emac_sgmii_config() Wei Yongjun
2016-10-03 19:41 ` Timur Tabi [this message]
2016-10-04 1:53 ` David Miller
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=57F2B457.70900@codeaurora.org \
--to=timur@codeaurora.org \
--cc=netdev@vger.kernel.org \
--cc=weiyj.lk@gmail.com \
--cc=weiyongjun1@huawei.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).