Commit 35076402 authored by Joe Perches's avatar Joe Perches Committed by David S. Miller

drivers/net/mac8390.c: Indent case labels

Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 698244ac
...@@ -164,70 +164,70 @@ static void word_memcpy_fromcard(void *tp, const void *fp, int count); ...@@ -164,70 +164,70 @@ static void word_memcpy_fromcard(void *tp, const void *fp, int count);
static enum mac8390_type __init mac8390_ident(struct nubus_dev *dev) static enum mac8390_type __init mac8390_ident(struct nubus_dev *dev)
{ {
switch (dev->dr_sw) { switch (dev->dr_sw) {
case NUBUS_DRSW_3COM: case NUBUS_DRSW_3COM:
switch (dev->dr_hw) { switch (dev->dr_hw) {
case NUBUS_DRHW_APPLE_SONIC_NB: case NUBUS_DRHW_APPLE_SONIC_NB:
case NUBUS_DRHW_APPLE_SONIC_LC: case NUBUS_DRHW_APPLE_SONIC_LC:
case NUBUS_DRHW_SONNET: case NUBUS_DRHW_SONNET:
return MAC8390_NONE; return MAC8390_NONE;
break;
default:
return MAC8390_APPLE;
break;
}
break; break;
default:
case NUBUS_DRSW_APPLE: return MAC8390_APPLE;
switch (dev->dr_hw) {
case NUBUS_DRHW_ASANTE_LC:
return MAC8390_NONE;
break;
case NUBUS_DRHW_CABLETRON:
return MAC8390_CABLETRON;
break;
default:
return MAC8390_APPLE;
break;
}
break; break;
}
break;
case NUBUS_DRSW_ASANTE: case NUBUS_DRSW_APPLE:
return MAC8390_ASANTE; switch (dev->dr_hw) {
case NUBUS_DRHW_ASANTE_LC:
return MAC8390_NONE;
break; break;
case NUBUS_DRHW_CABLETRON:
case NUBUS_DRSW_TECHWORKS: return MAC8390_CABLETRON;
case NUBUS_DRSW_DAYNA2:
case NUBUS_DRSW_DAYNA_LC:
if (dev->dr_hw == NUBUS_DRHW_CABLETRON)
return MAC8390_CABLETRON;
else
return MAC8390_APPLE;
break; break;
default:
case NUBUS_DRSW_FARALLON: return MAC8390_APPLE;
return MAC8390_FARALLON;
break; break;
}
break;
case NUBUS_DRSW_KINETICS: case NUBUS_DRSW_ASANTE:
switch (dev->dr_hw) { return MAC8390_ASANTE;
case NUBUS_DRHW_INTERLAN: break;
return MAC8390_INTERLAN;
break; case NUBUS_DRSW_TECHWORKS:
default: case NUBUS_DRSW_DAYNA2:
return MAC8390_KINETICS; case NUBUS_DRSW_DAYNA_LC:
break; if (dev->dr_hw == NUBUS_DRHW_CABLETRON)
} return MAC8390_CABLETRON;
break; else
return MAC8390_APPLE;
break;
case NUBUS_DRSW_FARALLON:
return MAC8390_FARALLON;
break;
case NUBUS_DRSW_DAYNA: case NUBUS_DRSW_KINETICS:
// These correspond to Dayna Sonic cards switch (dev->dr_hw) {
// which use the macsonic driver case NUBUS_DRHW_INTERLAN:
if (dev->dr_hw == NUBUS_DRHW_SMC9194 || return MAC8390_INTERLAN;
dev->dr_hw == NUBUS_DRHW_INTERLAN )
return MAC8390_NONE;
else
return MAC8390_DAYNA;
break; break;
default:
return MAC8390_KINETICS;
break;
}
break;
case NUBUS_DRSW_DAYNA:
// These correspond to Dayna Sonic cards
// which use the macsonic driver
if (dev->dr_hw == NUBUS_DRHW_SMC9194 ||
dev->dr_hw == NUBUS_DRHW_INTERLAN )
return MAC8390_NONE;
else
return MAC8390_DAYNA;
break;
} }
return MAC8390_NONE; return MAC8390_NONE;
} }
...@@ -373,54 +373,54 @@ struct net_device * __init mac8390_probe(int unit) ...@@ -373,54 +373,54 @@ struct net_device * __init mac8390_probe(int unit)
dev->mem_end = dev->mem_start + offset; dev->mem_end = dev->mem_start + offset;
} else { } else {
switch (cardtype) { switch (cardtype) {
case MAC8390_KINETICS: case MAC8390_KINETICS:
case MAC8390_DAYNA: /* it's the same */ case MAC8390_DAYNA: /* it's the same */
dev->base_addr = dev->base_addr =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
DAYNA_8390_BASE); DAYNA_8390_BASE);
dev->mem_start = dev->mem_start =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
DAYNA_8390_MEM); DAYNA_8390_MEM);
dev->mem_end = dev->mem_end =
dev->mem_start + dev->mem_start +
mac8390_memsize(dev->mem_start); mac8390_memsize(dev->mem_start);
break; break;
case MAC8390_INTERLAN: case MAC8390_INTERLAN:
dev->base_addr = dev->base_addr =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
INTERLAN_8390_BASE); INTERLAN_8390_BASE);
dev->mem_start = dev->mem_start =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
INTERLAN_8390_MEM); INTERLAN_8390_MEM);
dev->mem_end = dev->mem_end =
dev->mem_start + dev->mem_start +
mac8390_memsize(dev->mem_start); mac8390_memsize(dev->mem_start);
break; break;
case MAC8390_CABLETRON: case MAC8390_CABLETRON:
dev->base_addr = dev->base_addr =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
CABLETRON_8390_BASE); CABLETRON_8390_BASE);
dev->mem_start = dev->mem_start =
(int)(ndev->board->slot_addr + (int)(ndev->board->slot_addr +
CABLETRON_8390_MEM); CABLETRON_8390_MEM);
/* The base address is unreadable if 0x00 /* The base address is unreadable if 0x00
* has been written to the command register * has been written to the command register
* Reset the chip by writing E8390_NODMA + * Reset the chip by writing E8390_NODMA +
* E8390_PAGE0 + E8390_STOP just to be * E8390_PAGE0 + E8390_STOP just to be
* sure * sure
*/ */
i = (void *)dev->base_addr; i = (void *)dev->base_addr;
*i = 0x21; *i = 0x21;
dev->mem_end = dev->mem_end =
dev->mem_start + dev->mem_start +
mac8390_memsize(dev->mem_start); mac8390_memsize(dev->mem_start);
break; break;
default: default:
printk(KERN_ERR "Card type %s is" printk(KERN_ERR "Card type %s is"
" unsupported, sorry\n", " unsupported, sorry\n",
ndev->board->name); ndev->board->name);
continue; continue;
} }
} }
...@@ -540,33 +540,33 @@ static int __init mac8390_initdev(struct net_device * dev, struct nubus_dev * nd ...@@ -540,33 +540,33 @@ static int __init mac8390_initdev(struct net_device * dev, struct nubus_dev * nd
} }
/* Fill in model-specific information and functions */ /* Fill in model-specific information and functions */
switch(type) { switch (type) {
case MAC8390_FARALLON: case MAC8390_FARALLON:
case MAC8390_APPLE: case MAC8390_APPLE:
switch(mac8390_testio(dev->mem_start)) { switch (mac8390_testio(dev->mem_start)) {
case ACCESS_UNKNOWN: case ACCESS_UNKNOWN:
printk("Don't know how to access card memory!\n"); printk("Don't know how to access card memory!\n");
return -ENODEV; return -ENODEV;
break; break;
case ACCESS_16: case ACCESS_16:
/* 16 bit card, register map is reversed */ /* 16 bit card, register map is reversed */
ei_status.reset_8390 = &mac8390_no_reset; ei_status.reset_8390 = &mac8390_no_reset;
ei_status.block_input = &slow_sane_block_input; ei_status.block_input = &slow_sane_block_input;
ei_status.block_output = &slow_sane_block_output; ei_status.block_output = &slow_sane_block_output;
ei_status.get_8390_hdr = &slow_sane_get_8390_hdr; ei_status.get_8390_hdr = &slow_sane_get_8390_hdr;
ei_status.reg_offset = back4_offsets; ei_status.reg_offset = back4_offsets;
break; break;
case ACCESS_32: case ACCESS_32:
/* 32 bit card, register map is reversed */ /* 32 bit card, register map is reversed */
ei_status.reset_8390 = &mac8390_no_reset; ei_status.reset_8390 = &mac8390_no_reset;
ei_status.block_input = &sane_block_input; ei_status.block_input = &sane_block_input;
ei_status.block_output = &sane_block_output; ei_status.block_output = &sane_block_output;
ei_status.get_8390_hdr = &sane_get_8390_hdr; ei_status.get_8390_hdr = &sane_get_8390_hdr;
ei_status.reg_offset = back4_offsets; ei_status.reg_offset = back4_offsets;
access_bitmode = 1; access_bitmode = 1;
break; break;
} }
break; break;
......
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