Source-Changes-D archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/sys/net
Sorry for delayed review.
> @@ -410,6 +419,10 @@
> /* Tear down the routing table. */
> bridge_rtable_fini(sc);
>
> +
> +
> + softint_disestablish(sc->sc_softintr);
> +
> free(sc, M_DEVBUF);
>
> return (0);
Please trim these blank lines.
> @@ -1305,124 +1318,139 @@
> * The forwarding function of the bridge.
> */
> static void
> -bridge_forward(struct bridge_softc *sc, struct mbuf *m)
> +bridge_forward(void *v)
> {
> + struct bridge_softc *sc = v;
> + struct mbuf *m;
> struct bridge_iflist *bif;
> struct ifnet *src_if, *dst_if;
> struct ether_header *eh;
> + int s;
>
I think you have to take softnet_lock, since bridge_forward() is called from
softint where not lock is held.
> - src_if = m->m_pkthdr.rcvif;
> + if ((sc->sc_if.if_flags & IFF_RUNNING) == 0)
> + return;
>
> - sc->sc_if.if_ipackets++;
> - sc->sc_if.if_ibytes += m->m_pkthdr.len;
> + s = splbio();
> + while (1) {
> + IFQ_POLL(&sc->sc_if.if_snd, m);
> + if (m == NULL)
> + break;
> + IFQ_DEQUEUE(&sc->sc_if.if_snd, m);
>
Why splbio(), not splnet()???
Masao
Home |
Main Index |
Thread Index |
Old Index