Date: Fri, 15 Oct 2004 18:25:36 -0700 From: Bruce M Simpson <bms@spc.org> To: nbco@screaming.net, freebsd-gnats-submit@FreeBSD.org Cc: current@FreeBSD.org Subject: Re: kern/72748: em0 problems on t41 after updating to 5.3 Message-ID: <20041016012536.GS61186@empiric.icir.org>
next in thread | raw e-mail | index | archive | help
--00sTfE/IIAT5d2r5
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
[Cc: to current@ as this could be a show-stopper for RELENG_5_3]
Could you please try the attached patch, which reverts the ALTQ
changes introduced on the RELENG_5 branch, and let me know if this
resolves the issue?
Thanks,
BMS
--00sTfE/IIAT5d2r5
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="altq-releng5-em-backout.diff"
Index: if_em.c
===================================================================
RCS file: /home/ncvs/src/sys/dev/em/if_em.c,v
retrieving revision 1.44.2.2
diff -u -p -r1.44.2.2 if_em.c
--- if_em.c 15 Oct 2004 22:12:59 -0000 1.44.2.2
+++ if_em.c 16 Oct 2004 00:30:26 -0000
@@ -610,15 +610,15 @@ em_start_locked(struct ifnet *ifp)
if (!adapter->link_active)
return;
- while (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) {
+ while (ifp->if_snd.ifq_head != NULL) {
- IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head);
+ IF_DEQUEUE(&ifp->if_snd, m_head);
if (m_head == NULL) break;
if (em_encap(adapter, m_head)) {
ifp->if_flags |= IFF_OACTIVE;
- IFQ_DRV_PREPEND(&ifp->if_snd, m_head);
+ IF_PREPEND(&ifp->if_snd, m_head);
break;
}
@@ -949,7 +949,7 @@ em_poll_locked(struct ifnet *ifp, enum p
em_clean_transmit_interrupts(adapter);
}
- if (ifp->if_flags & IFF_RUNNING && !IFQ_DRV_IS_EMPTY(&ifp->if_snd))
+ if (ifp->if_flags & IFF_RUNNING && ifp->if_snd.ifq_head != NULL)
em_start_locked(ifp);
}
@@ -1019,7 +1019,7 @@ em_intr(void *arg)
loop_cnt--;
}
- if (ifp->if_flags & IFF_RUNNING && !IFQ_DRV_IS_EMPTY(&ifp->if_snd))
+ if (ifp->if_flags & IFF_RUNNING && ifp->if_snd.ifq_head != NULL)
em_start_locked(ifp);
EM_UNLOCK(adapter);
@@ -1892,9 +1892,7 @@ em_setup_interface(device_t dev, struct
ifp->if_ioctl = em_ioctl;
ifp->if_start = em_start;
ifp->if_watchdog = em_watchdog;
- IFQ_SET_MAXLEN(&ifp->if_snd, adapter->num_tx_desc - 1);
- ifp->if_snd.ifq_drv_maxlen = adapter->num_tx_desc - 1;
- IFQ_SET_READY(&ifp->if_snd);
+ ifp->if_snd.ifq_maxlen = adapter->num_tx_desc - 1;
#if __FreeBSD_version < 500000
ether_ifattach(ifp, ETHER_BPF_SUPPORTED);
--00sTfE/IIAT5d2r5--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041016012536.GS61186>
