]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
net: sh-eth: Fix coding style
authorNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Wed, 22 Jan 2014 22:52:19 +0000 (07:52 +0900)
committerNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Tue, 10 Jun 2014 08:05:03 +0000 (17:05 +0900)
This fixes checkpatch's warning.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
drivers/net/sh_eth.c
drivers/net/sh_eth.h

index 0cb963f8decf2927deb4aad4400022e92f6a5e18..81e8ddbbc7e80adaa2bc76c0fe049ed2246cfb83 100644 (file)
@@ -67,7 +67,8 @@ int sh_eth_send(struct eth_device *dev, void *packet, int len)
 
        /* packet must be a 4 byte boundary */
        if ((int)packet & 3) {
-               printf(SHETHER_NAME ": %s: packet not 4 byte alligned\n", __func__);
+               printf(SHETHER_NAME ": %s: packet not 4 byte alligned\n"
+                               , __func__);
                ret = -EFAULT;
                goto err;
        }
@@ -156,7 +157,7 @@ static int sh_eth_reset(struct sh_eth_dev *eth)
 
        /* Perform a software reset and wait for it to complete */
        sh_eth_write(eth, EDMR_SRST, EDMR);
-       for (i = 0; i < TIMEOUT_CNT ; i++) {
+       for (i = 0; i < TIMEOUT_CNT; i++) {
                if (!(sh_eth_read(eth, EDMR) & EDMR_SRST))
                        break;
                udelay(1000);
@@ -523,41 +524,41 @@ void sh_eth_halt(struct eth_device *dev)
 
 int sh_eth_initialize(bd_t *bd)
 {
-    int ret = 0;
+       int ret = 0;
        struct sh_eth_dev *eth = NULL;
-    struct eth_device *dev = NULL;
+       struct eth_device *dev = NULL;
 
-    eth = (struct sh_eth_dev *)malloc(sizeof(struct sh_eth_dev));
+       eth = (struct sh_eth_dev *)malloc(sizeof(struct sh_eth_dev));
        if (!eth) {
                printf(SHETHER_NAME ": %s: malloc failed\n", __func__);
                ret = -ENOMEM;
                goto err;
        }
 
-    dev = (struct eth_device *)malloc(sizeof(struct eth_device));
+       dev = (struct eth_device *)malloc(sizeof(struct eth_device));
        if (!dev) {
                printf(SHETHER_NAME ": %s: malloc failed\n", __func__);
                ret = -ENOMEM;
                goto err;
        }
-    memset(dev, 0, sizeof(struct eth_device));
-    memset(eth, 0, sizeof(struct sh_eth_dev));
+       memset(dev, 0, sizeof(struct eth_device));
+       memset(eth, 0, sizeof(struct sh_eth_dev));
 
        eth->port = CONFIG_SH_ETHER_USE_PORT;
        eth->port_info[eth->port].phy_addr = CONFIG_SH_ETHER_PHY_ADDR;
 
-    dev->priv = (void *)eth;
-    dev->iobase = 0;
-    dev->init = sh_eth_init;
-    dev->halt = sh_eth_halt;
-    dev->send = sh_eth_send;
-    dev->recv = sh_eth_recv;
-    eth->port_info[eth->port].dev = dev;
+       dev->priv = (void *)eth;
+       dev->iobase = 0;
+       dev->init = sh_eth_init;
+       dev->halt = sh_eth_halt;
+       dev->send = sh_eth_send;
+       dev->recv = sh_eth_recv;
+       eth->port_info[eth->port].dev = dev;
 
        sprintf(dev->name, SHETHER_NAME);
 
-    /* Register Device to EtherNet subsystem  */
-    eth_register(dev);
+       /* Register Device to EtherNet subsystem  */
+       eth_register(dev);
 
        bb_miiphy_buses[0].priv = eth;
        miiphy_register(dev->name, bb_miiphy_read, bb_miiphy_write);
index 09257590fdb78274382ab4b8608602fe4f8f1820..2909659fd59a0bda903cca46ebfe67b0da2918db 100644 (file)
@@ -452,7 +452,6 @@ enum PHY_STATUS_BIT { PHY_ST_LINK = 0x01, };
 
 /* EESR */
 enum EESR_BIT {
-
 #if defined(SH_ETH_TYPE_ETHER)
        EESR_TWB  = 0x40000000,
 #else
@@ -560,8 +559,8 @@ enum RECV_RST_BIT { RMCR_RST = 0x01, };
 /* ECMR */
 enum FELIC_MODE_BIT {
 #if defined(SH_ETH_TYPE_GETHER) || defined(SH_ETH_TYPE_RZ)
-       ECMR_TRCCM=0x04000000, ECMR_RCSC= 0x00800000, ECMR_DPAD= 0x00200000,
-       ECMR_RZPF = 0x00100000,
+       ECMR_TRCCM = 0x04000000, ECMR_RCSC = 0x00800000,
+       ECMR_DPAD = 0x00200000, ECMR_RZPF = 0x00100000,
 #endif
        ECMR_ZPF = 0x00080000, ECMR_PFR = 0x00040000, ECMR_RXF = 0x00020000,
        ECMR_TXF = 0x00010000, ECMR_MCT = 0x00002000, ECMR_PRCEF = 0x00001000,
@@ -577,8 +576,8 @@ enum FELIC_MODE_BIT {
 };
 
 #if defined(SH_ETH_TYPE_GETHER) || defined(SH_ETH_TYPE_RZ)
-#define ECMR_CHG_DM    (ECMR_TRCCM | ECMR_RZPF | ECMR_ZPF | ECMR_PFR | ECMR_RXF | \
-                                               ECMR_TXF | ECMR_MCT)
+#define ECMR_CHG_DM (ECMR_TRCCM | ECMR_RZPF | ECMR_ZPF | ECMR_PFR | \
+                       ECMR_RXF | ECMR_TXF | ECMR_MCT)
 #elif defined(SH_ETH_TYPE_ETHER)
 #define ECMR_CHG_DM (ECMR_ZPF | ECMR_PFR | ECMR_RXF | ECMR_TXF)
 #else