summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/renesas
diff options
context:
space:
mode:
authorSimon Horman <horms+renesas@verge.net.au>2014-01-17 04:22:27 +0400
committerDavid S. Miller <davem@davemloft.net>2014-01-18 06:13:58 +0400
commit504c8ca55c70fb6cab0b97381e70ad0e143f539e (patch)
tree84a62e0dcce4e8db1a5e7ebce840d2d717e92c4c /drivers/net/ethernet/renesas
parent6a7cc41872dd46719fde09756e55e870cd453da8 (diff)
downloadlinux-504c8ca55c70fb6cab0b97381e70ad0e143f539e.tar.xz
sh_eth: Use bool as return type of sh_eth_is_gether()
Return a boolean from sh_eth_is_gether() and refactor it as a one-liner. Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Acked-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/renesas')
-rw-r--r--drivers/net/ethernet/renesas/sh_eth.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/net/ethernet/renesas/sh_eth.c b/drivers/net/ethernet/renesas/sh_eth.c
index 43d0a0db6e0d..fe2c8bb4d2f1 100644
--- a/drivers/net/ethernet/renesas/sh_eth.c
+++ b/drivers/net/ethernet/renesas/sh_eth.c
@@ -309,12 +309,9 @@ 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;
- else
- return 0;
+ return mdp->reg_offset == sh_eth_offset_gigabit;
}
static void sh_eth_select_mii(struct net_device *ndev)