diff options
author | Jonathan Lemon <jlemon@FreeBSD.org> | 2000-11-25 07:35:38 +0000 |
---|---|---|
committer | Jonathan Lemon <jlemon@FreeBSD.org> | 2000-11-25 07:35:38 +0000 |
commit | df5e1987230850fe5983a4479523708640160215 (patch) | |
tree | 05531b0125a3669b45ffc6aa7dc93115e4123969 /sys/net/if_fddisubr.c | |
parent | f4e13f88b630686808a03dc19e3243ca37fa5645 (diff) | |
download | src-df5e1987230850fe5983a4479523708640160215.tar.gz src-df5e1987230850fe5983a4479523708640160215.zip |
Notes
Diffstat (limited to 'sys/net/if_fddisubr.c')
-rw-r--r-- | sys/net/if_fddisubr.c | 28 |
1 files changed, 3 insertions, 25 deletions
diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c index f88a02bf02a8..186fec5f915a 100644 --- a/sys/net/if_fddisubr.c +++ b/sys/net/if_fddisubr.c @@ -128,7 +128,7 @@ fddi_output(ifp, m, dst, rt0) struct rtentry *rt0; { u_int16_t type; - int s, loop_copy = 0, error = 0, hdrcmplt = 0; + int loop_copy = 0, error = 0, hdrcmplt = 0; u_char esrc[6], edst[6]; register struct rtentry *rt; register struct fddi_header *fh; @@ -350,23 +350,8 @@ fddi_output(ifp, m, dst, rt0) } } - s = splimp(); - /* - * Queue message on interface, and start output if interface - * not yet active. - */ - if (IF_QFULL(&ifp->if_snd)) { - IF_DROP(&ifp->if_snd); - splx(s); + if (! IF_HANDOFF(&ifp->if_snd, m, ifp)) senderr(ENOBUFS); - } - ifp->if_obytes += m->m_pkthdr.len; - if (m->m_flags & M_MCAST) - ifp->if_omcasts++; - IF_ENQUEUE(&ifp->if_snd, m); - if ((ifp->if_flags & IFF_OACTIVE) == 0) - (*ifp->if_start)(ifp); - splx(s); return (error); bad: @@ -388,7 +373,6 @@ fddi_input(ifp, fh, m) { register struct ifqueue *inq; register struct llc *l; - int s; if ((ifp->if_flags & IFF_UP) == 0) { m_freem(m); @@ -520,13 +504,7 @@ fddi_input(ifp, fh, m) return; } - s = splimp(); - if (IF_QFULL(inq)) { - IF_DROP(inq); - m_freem(m); - } else - IF_ENQUEUE(inq, m); - splx(s); + (void) IF_HANDOFF(inq, m, NULL); } /* * Perform common duties while attaching to interface list |