aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSrikanth Thokala <srikanth.thokala@xilinx.com>2015-05-05 05:25:59 -0400
committerDavid S. Miller <davem@davemloft.net>2015-05-05 19:33:58 -0400
commitc81a97b5ca146a5cc6c206831eb6bc39215678f3 (patch)
treee83cba849c6321d001e1c9426145771fa98ac164
parentd7cc3163e026300f37a64d9e2fe5ad64a87504bc (diff)
net: axienet: Removed coding style errors and warnings
Removed checkpatch.pl errors and warnings. Signed-off-by: Srikanth Thokala <sthokal@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/xilinx/xilinx_axienet_main.c20
-rw-r--r--drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c21
2 files changed, 21 insertions, 20 deletions
diff --git a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
index c6f2ba056c26..39bb2e93cc65 100644
--- a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
+++ b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
@@ -444,8 +444,8 @@ static void __axienet_device_reset(struct axienet_local *lp,
444 while (axienet_dma_in32(lp, offset) & XAXIDMA_CR_RESET_MASK) { 444 while (axienet_dma_in32(lp, offset) & XAXIDMA_CR_RESET_MASK) {
445 udelay(1); 445 udelay(1);
446 if (--timeout == 0) { 446 if (--timeout == 0) {
447 dev_err(dev, "axienet_device_reset DMA " 447 netdev_err(lp->ndev, "%s: DMA reset timeout!\n",
448 "reset timeout!\n"); 448 __func__);
449 break; 449 break;
450 } 450 }
451 } 451 }
@@ -484,8 +484,8 @@ static void axienet_device_reset(struct net_device *ndev)
484 } 484 }
485 485
486 if (axienet_dma_bd_init(ndev)) { 486 if (axienet_dma_bd_init(ndev)) {
487 dev_err(&ndev->dev, "axienet_device_reset descriptor " 487 netdev_err(ndev, "%s: descriptor allocation failed\n",
488 "allocation failed\n"); 488 __func__);
489 } 489 }
490 490
491 axienet_status = axienet_ior(lp, XAE_RCW1_OFFSET); 491 axienet_status = axienet_ior(lp, XAE_RCW1_OFFSET);
@@ -560,8 +560,8 @@ static void axienet_adjust_link(struct net_device *ndev)
560 lp->last_link = link_state; 560 lp->last_link = link_state;
561 phy_print_status(phy); 561 phy_print_status(phy);
562 } else { 562 } else {
563 dev_err(&ndev->dev, "Error setting Axi Ethernet " 563 netdev_err(ndev,
564 "mac speed\n"); 564 "Error setting Axi Ethernet mac speed\n");
565 } 565 }
566 } 566 }
567} 567}
@@ -1238,8 +1238,8 @@ axienet_ethtools_set_pauseparam(struct net_device *ndev,
1238 struct axienet_local *lp = netdev_priv(ndev); 1238 struct axienet_local *lp = netdev_priv(ndev);
1239 1239
1240 if (netif_running(ndev)) { 1240 if (netif_running(ndev)) {
1241 printk(KERN_ERR "%s: Please stop netif before applying " 1241 netdev_err(ndev,
1242 "configruation\n", ndev->name); 1242 "Please stop netif before applying configuration\n");
1243 return -EFAULT; 1243 return -EFAULT;
1244 } 1244 }
1245 1245
@@ -1295,8 +1295,8 @@ static int axienet_ethtools_set_coalesce(struct net_device *ndev,
1295 struct axienet_local *lp = netdev_priv(ndev); 1295 struct axienet_local *lp = netdev_priv(ndev);
1296 1296
1297 if (netif_running(ndev)) { 1297 if (netif_running(ndev)) {
1298 printk(KERN_ERR "%s: Please stop netif before applying " 1298 netdev_err(ndev,
1299 "configruation\n", ndev->name); 1299 "Please stop netif before applying configuration\n");
1300 return -EFAULT; 1300 return -EFAULT;
1301 } 1301 }
1302 1302
diff --git a/drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c b/drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c
index 3b67d60d4378..fce557518b7d 100644
--- a/drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c
+++ b/drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c
@@ -161,19 +161,19 @@ int axienet_mdio_setup(struct axienet_local *lp, struct device_node *np)
161 161
162 np1 = of_find_node_by_name(NULL, "cpu"); 162 np1 = of_find_node_by_name(NULL, "cpu");
163 if (!np1) { 163 if (!np1) {
164 printk(KERN_WARNING "%s(): Could not find CPU device node.", 164 netdev_warn(lp->ndev, "Could not find CPU device node.\n");
165 __func__); 165 netdev_warn(lp->ndev,
166 printk(KERN_WARNING "Setting MDIO clock divisor to " 166 "Setting MDIO clock divisor to default %d\n",
167 "default %d\n", DEFAULT_CLOCK_DIVISOR); 167 DEFAULT_CLOCK_DIVISOR);
168 clk_div = DEFAULT_CLOCK_DIVISOR; 168 clk_div = DEFAULT_CLOCK_DIVISOR;
169 goto issue; 169 goto issue;
170 } 170 }
171 property_p = (u32 *) of_get_property(np1, "clock-frequency", NULL); 171 property_p = (u32 *) of_get_property(np1, "clock-frequency", NULL);
172 if (!property_p) { 172 if (!property_p) {
173 printk(KERN_WARNING "%s(): Could not find CPU property: " 173 netdev_warn(lp->ndev, "clock-frequency property not found.\n");
174 "clock-frequency.", __func__); 174 netdev_warn(lp->ndev,
175 printk(KERN_WARNING "Setting MDIO clock divisor to " 175 "Setting MDIO clock divisor to default %d\n",
176 "default %d\n", DEFAULT_CLOCK_DIVISOR); 176 DEFAULT_CLOCK_DIVISOR);
177 clk_div = DEFAULT_CLOCK_DIVISOR; 177 clk_div = DEFAULT_CLOCK_DIVISOR;
178 of_node_put(np1); 178 of_node_put(np1);
179 goto issue; 179 goto issue;
@@ -187,8 +187,9 @@ int axienet_mdio_setup(struct axienet_local *lp, struct device_node *np)
187 if (host_clock % (MAX_MDIO_FREQ * 2)) 187 if (host_clock % (MAX_MDIO_FREQ * 2))
188 clk_div++; 188 clk_div++;
189 189
190 printk(KERN_DEBUG "%s(): Setting MDIO clock divisor to %u based " 190 netdev_dbg(lp->ndev,
191 "on %u Hz host clock.\n", __func__, clk_div, host_clock); 191 "Setting MDIO clock divisor to %u/%u Hz host clock.\n",
192 clk_div, host_clock);
192 193
193 of_node_put(np1); 194 of_node_put(np1);
194issue: 195issue: