Use if_maddr_*lock() routines to lock the per-interface multicast

address list rather than manipulating the lock directly.
This commit is contained in:
John Baldwin 2012-02-13 19:35:35 +00:00
parent 1a26580ee8
commit 0187124bee

View File

@ -558,7 +558,7 @@ oce_hw_update_multicast(POCE_SOFTC sc)
bzero(req, sizeof(struct mbx_set_common_iface_multicast));
#if __FreeBSD_version > 800000
IF_ADDR_RLOCK(ifp);
if_maddr_rlock(ifp);
#endif
TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) {
if (ifma->ifma_addr->sa_family != AF_LINK)
@ -578,7 +578,7 @@ oce_hw_update_multicast(POCE_SOFTC sc)
req->params.req.num_mac = req->params.req.num_mac + 1;
}
#if __FreeBSD_version > 800000
IF_ADDR_RUNLOCK(ifp);
if_maddr_runlock(ifp);
#endif
req->params.req.if_id = sc->if_id;
rc = oce_update_multicast(sc, &dma);