Skip to content

Commit

Permalink
m68knommu: improve mii_do_cmd code in FEC driver
Browse files Browse the repository at this point in the history
Improve the readability of mii_do_cmd().

Signed-off-by: Philippe De Muyter <phdm@macqel.be>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Philippe De Muyter authored and Linus Torvalds committed Oct 23, 2007
1 parent dbf18c8 commit be6cb66
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions drivers/net/fec.c
Original file line number Diff line number Diff line change
Expand Up @@ -766,14 +766,11 @@ mii_queue(struct net_device *dev, int regval, void (*func)(uint, struct net_devi

static void mii_do_cmd(struct net_device *dev, const phy_cmd_t *c)
{
int k;

if(!c)
return;

for(k = 0; (c+k)->mii_data != mk_mii_end; k++) {
mii_queue(dev, (c+k)->mii_data, (c+k)->funct);
}
for (; c->mii_data != mk_mii_end; c++)
mii_queue(dev, c->mii_data, c->funct);
}

static void mii_parse_sr(uint mii_reg, struct net_device *dev)
Expand Down

0 comments on commit be6cb66

Please sign in to comment.