From: Joe Perches <joe@perches.com>
To: Simon Horman <horms+renesas@verge.net.au>
Cc: "David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, linux-sh@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
Magnus Damm <magnus.damm@gmail.com>,
Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Subject: Re: [PATCH v5 net-next 1/4] sh_eth: Use bool as return type of sh_eth_is_gether()
Date: Wed, 15 Jan 2014 01:35:20 -0800 [thread overview]
Message-ID: <1389778520.14001.16.camel@joe-AO722> (raw)
In-Reply-To: <1389766341-14001-2-git-send-email-horms+renesas@verge.net.au>
On Wed, 2014-01-15 at 15:12 +0900, Simon Horman wrote:
> Return a boolean and use true and false.
[]
> diff --git a/drivers/net/ethernet/renesas/sh_eth.c b/drivers/net/ethernet/renesas/sh_eth.c
[]
> @@ -310,12 +310,12 @@ static const u16 sh_eth_offset_fast_sh3_sh2[SH_ETH_MAX_REGISTER_OFFSET] = {
> [TSU_ADRL31] = 0x01fc,
> };
>
> -static int sh_eth_is_gether(struct sh_eth_private *mdp)
> +static bool sh_eth_is_gether(struct sh_eth_private *mdp)
> {
> if (mdp->reg_offset == sh_eth_offset_gigabit)
> - return 1;
> + return true;
> else
> - return 0;
> + return false;
> }
Or maybe:
static bool sh_eth_is_gether(struct sh_eth_private *mdp)
{
return mdp->reg_offset == sh_eth_offset_gigabit;
}
next prev parent reply other threads:[~2014-01-15 9:35 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-15 6:12 [PATCH v5 0/4] Add ethernet support for r7s72100 Simon Horman
2014-01-15 6:12 ` [PATCH v5 net-next 1/4] sh_eth: Use bool as return type of sh_eth_is_gether() Simon Horman
2014-01-15 9:35 ` Joe Perches [this message]
2014-01-16 1:15 ` Simon Horman
2014-01-15 6:12 ` [PATCH v5 net-next 2/4] sh_eth: Add support for r7s72100 Simon Horman
2014-01-15 22:26 ` Sergei Shtylyov
2014-01-16 0:14 ` Simon Horman
2014-01-15 6:12 ` [PATCH v5 3/4] ARM: shmobile: r7s72100: Add clock for r7s72100-ether Simon Horman
2014-01-15 6:12 ` [PATCH v5 4/4] ARM: shmobile: genmai: Enable r7s72100-ether Simon Horman
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=1389778520.14001.16.camel@joe-AO722 \
--to=joe@perches.com \
--cc=davem@davemloft.net \
--cc=horms+renesas@verge.net.au \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-sh@vger.kernel.org \
--cc=magnus.damm@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=sergei.shtylyov@cogentembedded.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