From: Joe Perches <joe@perches.com>
To: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net, stigge@antcom.de,
edumazet@google.com, gregkh@linuxfoundation.org,
jiri@resnulli.us, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ethernet: nxp: use resource_size()
Date: Tue, 12 Mar 2013 12:10:31 -0700 [thread overview]
Message-ID: <1363115431.2125.13.camel@joe-AO722> (raw)
In-Reply-To: <1363113035-11269-1-git-send-email-silviupopescu1990@gmail.com>
On Tue, 2013-03-12 at 20:30 +0200, Silviu-Mihai Popescu wrote:
> Use resource_size() instead of explicit calculation. This was found via
> make coccicheck.
[]
> diff --git a/drivers/net/ethernet/nxp/lpc_eth.c b/drivers/net/ethernet/nxp/lpc_eth.c
[]
> @@ -1421,7 +1421,7 @@ static int lpc_eth_drv_probe(struct platform_device *pdev)
> netdev_dbg(ndev, "IO address start :0x%08x\n",
> res->start);
> netdev_dbg(ndev, "IO address size :%d\n",
> - res->end - res->start + 1);
> + resource_size(res));
This might be better as
netdev_dbg(ndev, "IO resource :%pR\n", res);
next prev parent reply other threads:[~2013-03-12 19:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-12 18:30 [PATCH] ethernet: nxp: use resource_size() Silviu-Mihai Popescu
2013-03-12 19:10 ` Joe Perches [this message]
2013-03-12 22:35 ` Silviu Popescu
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=1363115431.2125.13.camel@joe-AO722 \
--to=joe@perches.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=gregkh@linuxfoundation.org \
--cc=jiri@resnulli.us \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=silviupopescu1990@gmail.com \
--cc=stigge@antcom.de \
/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