if_epair: ifdef vars only used with ALTQ

Sponsored by:	Rubicon Communications, LLC ("Netgate")
This commit is contained in:
Mateusz Guzik 2021-11-24 21:28:54 +00:00
parent 35b12b8711
commit 2cedfc3f7e

View File

@ -271,8 +271,11 @@ epair_transmit(struct ifnet *ifp, struct mbuf *m)
{
struct epair_softc *sc;
struct ifnet *oifp;
int error, len;
int error;
#ifdef ALTQ
int len;
short mflags;
#endif
if (m == NULL)
return (0);
@ -309,10 +312,11 @@ epair_transmit(struct ifnet *ifp, struct mbuf *m)
m_freem(m);
return (0);
}
#ifdef ALTQ
len = m->m_pkthdr.len;
mflags = m->m_flags;
#ifdef ALTQ
/* Support ALTQ via the classic if_start() path. */
IF_LOCK(&ifp->if_snd);
if (ALTQ_IS_ENABLED(&ifp->if_snd)) {