Commit 78923e8a authored by Guofeng Yue's avatar Guofeng Yue Committed by David S. Miller

net: amd: Switch and case should be at the same indent

Cleaning some static warnings of indent.
Signed-off-by: default avatarGuofeng Yue <yueguofeng@hisilicon.com>
Signed-off-by: default avatarHaoyue Xu <xuhaoyue1@hisilicon.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 7c13f442
...@@ -185,24 +185,23 @@ static void amd8111e_set_ext_phy(struct net_device *dev) ...@@ -185,24 +185,23 @@ static void amd8111e_set_ext_phy(struct net_device *dev)
advert = amd8111e_mdio_read(dev, lp->ext_phy_addr, MII_ADVERTISE); advert = amd8111e_mdio_read(dev, lp->ext_phy_addr, MII_ADVERTISE);
tmp = advert & ~(ADVERTISE_ALL | ADVERTISE_100BASE4); tmp = advert & ~(ADVERTISE_ALL | ADVERTISE_100BASE4);
switch (lp->ext_phy_option) { switch (lp->ext_phy_option) {
default:
default: case SPEED_AUTONEG: /* advertise all values */
case SPEED_AUTONEG: /* advertise all values */ tmp |= (ADVERTISE_10HALF | ADVERTISE_10FULL |
tmp |= (ADVERTISE_10HALF | ADVERTISE_10FULL | ADVERTISE_100HALF | ADVERTISE_100FULL);
ADVERTISE_100HALF | ADVERTISE_100FULL); break;
break; case SPEED10_HALF:
case SPEED10_HALF: tmp |= ADVERTISE_10HALF;
tmp |= ADVERTISE_10HALF; break;
break; case SPEED10_FULL:
case SPEED10_FULL: tmp |= ADVERTISE_10FULL;
tmp |= ADVERTISE_10FULL; break;
break; case SPEED100_HALF:
case SPEED100_HALF: tmp |= ADVERTISE_100HALF;
tmp |= ADVERTISE_100HALF; break;
break; case SPEED100_FULL:
case SPEED100_FULL: tmp |= ADVERTISE_100FULL;
tmp |= ADVERTISE_100FULL; break;
break;
} }
if(advert != tmp) if(advert != tmp)
......
...@@ -581,15 +581,15 @@ static unsigned long __init lance_probe1( struct net_device *dev, ...@@ -581,15 +581,15 @@ static unsigned long __init lance_probe1( struct net_device *dev,
/* Get the ethernet address */ /* Get the ethernet address */
switch( lp->cardtype ) { switch( lp->cardtype ) {
case OLD_RIEBL: case OLD_RIEBL:
/* No ethernet address! (Set some default address) */ /* No ethernet address! (Set some default address) */
eth_hw_addr_set(dev, OldRieblDefHwaddr); eth_hw_addr_set(dev, OldRieblDefHwaddr);
break; break;
case NEW_RIEBL: case NEW_RIEBL:
lp->memcpy_f(addr, RIEBL_HWADDR_ADDR, ETH_ALEN); lp->memcpy_f(addr, RIEBL_HWADDR_ADDR, ETH_ALEN);
eth_hw_addr_set(dev, addr); eth_hw_addr_set(dev, addr);
break; break;
case PAM_CARD: case PAM_CARD:
i = IO->eeprom; i = IO->eeprom;
for( i = 0; i < 6; ++i ) for( i = 0; i < 6; ++i )
addr[i] = addr[i] =
......
...@@ -485,10 +485,10 @@ static int mace_read(mace_private *lp, unsigned int ioaddr, int reg) ...@@ -485,10 +485,10 @@ static int mace_read(mace_private *lp, unsigned int ioaddr, int reg)
unsigned long flags; unsigned long flags;
switch (reg >> 4) { switch (reg >> 4) {
case 0: /* register 0-15 */ case 0: /* register 0-15 */
data = inb(ioaddr + AM2150_MACE_BASE + reg); data = inb(ioaddr + AM2150_MACE_BASE + reg);
break; break;
case 1: /* register 16-31 */ case 1: /* register 16-31 */
spin_lock_irqsave(&lp->bank_lock, flags); spin_lock_irqsave(&lp->bank_lock, flags);
MACEBANK(1); MACEBANK(1);
data = inb(ioaddr + AM2150_MACE_BASE + (reg & 0x0F)); data = inb(ioaddr + AM2150_MACE_BASE + (reg & 0x0F));
...@@ -512,10 +512,10 @@ static void mace_write(mace_private *lp, unsigned int ioaddr, int reg, ...@@ -512,10 +512,10 @@ static void mace_write(mace_private *lp, unsigned int ioaddr, int reg,
unsigned long flags; unsigned long flags;
switch (reg >> 4) { switch (reg >> 4) {
case 0: /* register 0-15 */ case 0: /* register 0-15 */
outb(data & 0xFF, ioaddr + AM2150_MACE_BASE + reg); outb(data & 0xFF, ioaddr + AM2150_MACE_BASE + reg);
break; break;
case 1: /* register 16-31 */ case 1: /* register 16-31 */
spin_lock_irqsave(&lp->bank_lock, flags); spin_lock_irqsave(&lp->bank_lock, flags);
MACEBANK(1); MACEBANK(1);
outb(data & 0xFF, ioaddr + AM2150_MACE_BASE + (reg & 0x0F)); outb(data & 0xFF, ioaddr + AM2150_MACE_BASE + (reg & 0x0F));
...@@ -567,13 +567,13 @@ static int mace_init(mace_private *lp, unsigned int ioaddr, ...@@ -567,13 +567,13 @@ static int mace_init(mace_private *lp, unsigned int ioaddr,
* Or just set ASEL in PHYCC below! * Or just set ASEL in PHYCC below!
*/ */
switch (if_port) { switch (if_port) {
case 1: case 1:
mace_write(lp, ioaddr, MACE_PLSCC, 0x02); mace_write(lp, ioaddr, MACE_PLSCC, 0x02);
break; break;
case 2: case 2:
mace_write(lp, ioaddr, MACE_PLSCC, 0x00); mace_write(lp, ioaddr, MACE_PLSCC, 0x00);
break; break;
default: default:
mace_write(lp, ioaddr, MACE_PHYCC, /* ASEL */ 4); mace_write(lp, ioaddr, MACE_PHYCC, /* ASEL */ 4);
/* ASEL Auto Select. When set, the PORTSEL[1-0] bits are overridden, /* ASEL Auto Select. When set, the PORTSEL[1-0] bits are overridden,
and the MACE device will automatically select the operating media and the MACE device will automatically select the operating media
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment