Correct use of logical and where binary and was intended.
authorjsg <jsg@openbsd.org>
Tue, 3 Aug 2010 16:11:57 +0000 (16:11 +0000)
committerjsg <jsg@openbsd.org>
Tue, 3 Aug 2010 16:11:57 +0000 (16:11 +0000)
Spotted by lint, but mirrors a similiar change in the
original FreeBSD code from over a year ago.

ok deraadt@

sys/dev/pci/if_bnx.c

index e87f892..8ff6db8 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: if_bnx.c,v 1.88 2010/05/24 21:23:23 sthen Exp $       */
+/*     $OpenBSD: if_bnx.c,v 1.89 2010/08/03 16:11:57 jsg Exp $ */
 
 /*-
  * Copyright (c) 2006 Broadcom Corporation
@@ -2227,7 +2227,7 @@ bnx_get_media(struct bnx_softc *sc)
        } else if (BNX_CHIP_BOND_ID(sc) & BNX_CHIP_BOND_ID_SERDES_BIT)
                sc->bnx_phy_flags |= BNX_PHY_SERDES_FLAG;
 
-       if (sc->bnx_phy_flags && BNX_PHY_SERDES_FLAG) {
+       if (sc->bnx_phy_flags & BNX_PHY_SERDES_FLAG) {
                sc->bnx_flags |= BNX_NO_WOL_FLAG;
 
                if (BNX_CHIP_NUM(sc) == BNX_CHIP_NUM_5709)