aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/phy/phy_device.c
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2013-12-18 00:38:12 -0500
committerDavid S. Miller <davem@davemloft.net>2013-12-18 00:49:02 -0500
commite109374f6b695fc988b8d4a964792e9ba7953dad (patch)
tree35177fb739eba324711383e56430d1fa4508ab8c /drivers/net/phy/phy_device.c
parent756b50895f8d47499b38b3f7328347f46f10a673 (diff)
net: phy: fix checkpatch errors
checkpatch spotted a few checkpatch errors such as whitespace damages and switch/case labels not being on the same column, fix them. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy/phy_device.c')
-rw-r--r--drivers/net/phy/phy_device.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
index 4eb5bba1db5e..d53242449c90 100644
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
@@ -162,7 +162,7 @@ struct phy_device *phy_device_create(struct mii_bus *bus, int addr, int phy_id,
162 dev = kzalloc(sizeof(*dev), GFP_KERNEL); 162 dev = kzalloc(sizeof(*dev), GFP_KERNEL);
163 163
164 if (NULL == dev) 164 if (NULL == dev)
165 return (struct phy_device*) PTR_ERR((void*)-ENOMEM); 165 return (struct phy_device *)PTR_ERR((void *)-ENOMEM);
166 166
167 dev->dev.release = phy_device_release; 167 dev->dev.release = phy_device_release;
168 168
@@ -459,7 +459,7 @@ EXPORT_SYMBOL(phy_connect_direct);
459 * choose to call only the subset of functions which provide 459 * choose to call only the subset of functions which provide
460 * the desired functionality. 460 * the desired functionality.
461 */ 461 */
462struct phy_device * phy_connect(struct net_device *dev, const char *bus_id, 462struct phy_device *phy_connect(struct net_device *dev, const char *bus_id,
463 void (*handler)(struct net_device *), 463 void (*handler)(struct net_device *),
464 phy_interface_t interface) 464 phy_interface_t interface)
465{ 465{
@@ -494,7 +494,7 @@ void phy_disconnect(struct phy_device *phydev)
494 phy_stop_interrupts(phydev); 494 phy_stop_interrupts(phydev);
495 495
496 phy_stop_machine(phydev); 496 phy_stop_machine(phydev);
497 497
498 phydev->adjust_link = NULL; 498 phydev->adjust_link = NULL;
499 499
500 phy_detach(phydev); 500 phy_detach(phydev);
@@ -792,7 +792,7 @@ int genphy_setup_forced(struct phy_device *phydev)
792 792
793 if (DUPLEX_FULL == phydev->duplex) 793 if (DUPLEX_FULL == phydev->duplex)
794 ctl |= BMCR_FULLDPLX; 794 ctl |= BMCR_FULLDPLX;
795 795
796 err = phy_write(phydev, MII_BMCR, ctl); 796 err = phy_write(phydev, MII_BMCR, ctl);
797 797
798 return err; 798 return err;
@@ -965,14 +965,14 @@ int genphy_read_status(struct phy_device *phydev)
965 phydev->duplex = DUPLEX_FULL; 965 phydev->duplex = DUPLEX_FULL;
966 } else if (lpa & (LPA_100FULL | LPA_100HALF)) { 966 } else if (lpa & (LPA_100FULL | LPA_100HALF)) {
967 phydev->speed = SPEED_100; 967 phydev->speed = SPEED_100;
968 968
969 if (lpa & LPA_100FULL) 969 if (lpa & LPA_100FULL)
970 phydev->duplex = DUPLEX_FULL; 970 phydev->duplex = DUPLEX_FULL;
971 } else 971 } else
972 if (lpa & LPA_10FULL) 972 if (lpa & LPA_10FULL)
973 phydev->duplex = DUPLEX_FULL; 973 phydev->duplex = DUPLEX_FULL;
974 974
975 if (phydev->duplex == DUPLEX_FULL){ 975 if (phydev->duplex == DUPLEX_FULL) {
976 phydev->pause = lpa & LPA_PAUSE_CAP ? 1 : 0; 976 phydev->pause = lpa & LPA_PAUSE_CAP ? 1 : 0;
977 phydev->asym_pause = lpa & LPA_PAUSE_ASYM ? 1 : 0; 977 phydev->asym_pause = lpa & LPA_PAUSE_ASYM ? 1 : 0;
978 } 978 }
@@ -1213,7 +1213,7 @@ static struct phy_driver genphy_driver = {
1213 .read_status = genphy_read_status, 1213 .read_status = genphy_read_status,
1214 .suspend = genphy_suspend, 1214 .suspend = genphy_suspend,
1215 .resume = genphy_resume, 1215 .resume = genphy_resume,
1216 .driver = {.owner= THIS_MODULE, }, 1216 .driver = { .owner = THIS_MODULE, },
1217}; 1217};
1218 1218
1219static int __init phy_init(void) 1219static int __init phy_init(void)