From 46e6dd8ffb1bf56921388c25ce10a07a4e3e1706 Mon Sep 17 00:00:00 2001 From: Weongyo Jeong Date: Thu, 25 Dec 2008 04:29:40 +0000 Subject: [PATCH] fix a silly bug that I missed a for-loop to initialize AL2230S PHY. Reported by: Hans Petter Selasky --- sys/dev/usb/if_zyd.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/usb/if_zyd.c b/sys/dev/usb/if_zyd.c index fdbe7273bc01..3a4abce6bf7d 100644 --- a/sys/dev/usb/if_zyd.c +++ b/sys/dev/usb/if_zyd.c @@ -1061,8 +1061,10 @@ zyd_al2230_init_b(struct zyd_rf *rf) for (i = 0; i < N(phyini); i++) zyd_write16_m(sc, phyini[i].reg, phyini[i].val); - if (sc->sc_rfrev == ZYD_RF_AL2230S || sc->sc_al2230s != 0) - zyd_write16_m(sc, phy2230s[i].reg, phy2230s[i].val); + if (sc->sc_rfrev == ZYD_RF_AL2230S || sc->sc_al2230s != 0) { + for (i = 0; i < N(phy2230s); i++) + zyd_write16_m(sc, phy2230s[i].reg, phy2230s[i].val); + } for (i = 0; i < 3; i++) { error = zyd_rfwrite_cr(sc, zyd_al2230_chtable[0][i]);