diff options
author | Kevin Lo <kevlo@cvs.openbsd.org> | 2011-01-21 06:34:05 +0000 |
---|---|---|
committer | Kevin Lo <kevlo@cvs.openbsd.org> | 2011-01-21 06:34:05 +0000 |
commit | 37b96dee36e001e3b79d80ebcb5e7ef9456625f7 (patch) | |
tree | 078d58d8ee8ea6dbb8d638dafb8e31288da3ccf1 /sys/dev | |
parent | 84455a80d453fbd2b1c1cdfb87654bd62d24263c (diff) |
Get rid of the use of goto's within vte_iff funtion; from Brad
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/pci/if_vte.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/sys/dev/pci/if_vte.c b/sys/dev/pci/if_vte.c index d69e2ec05e3..d96d288c97a 100644 --- a/sys/dev/pci/if_vte.c +++ b/sys/dev/pci/if_vte.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vte.c,v 1.2 2011/01/15 10:08:50 kevlo Exp $ */ +/* $OpenBSD: if_vte.c,v 1.3 2011/01/21 06:34:04 kevlo Exp $ */ /*- * Copyright (c) 2010, Pyun YongHyeon <yongari@FreeBSD.org> * All rights reserved. @@ -1470,7 +1470,6 @@ vte_iff(struct vte_softc *sc) else mcr |= MCR0_MULTICAST; mchash[0] = mchash[1] = mchash[2] = mchash[3] = 0xFFFF; - goto chipit; } else { nperf = 0; ETHER_FIRST_MULTI(step, ac, enm); @@ -1495,12 +1494,11 @@ vte_iff(struct vte_softc *sc) mchash[crc >> 30] |= 1 << ((crc >> 26) & 0x0F); ETHER_NEXT_MULTI(step, enm); } + if (mchash[0] != 0 || mchash[1] != 0 || mchash[2] != 0 || + mchash[3] != 0) + mcr |= MCR0_MULTICAST; } - if (mchash[0] != 0 || mchash[1] != 0 || mchash[2] != 0 || - mchash[3] != 0) - mcr |= MCR0_MULTICAST; -chipit: /* Program multicast hash table. */ CSR_WRITE_2(sc, VTE_MAR0, mchash[0]); CSR_WRITE_2(sc, VTE_MAR1, mchash[1]); |