Date: Thu, 4 Aug 2005 11:07:36 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 81438 for review Message-ID: <200508041107.j74B7adD073352@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=81438 Change 81438 by rwatson@rwatson_zoo on 2005/08/04 11:06:58 Annotate problem with if_addr_mtx locking in the vlan code, the reason that I haven't yet merged thes changes. Affected files ... .. //depot/projects/netsmp/src/sys/net/if_vlan.c#3 edit Differences ... ==== //depot/projects/netsmp/src/sys/net/if_vlan.c#3 (text+ko) ==== @@ -188,6 +188,15 @@ } /* Now program new ones. */ + + /* + * XXXRW: Really, this should happen in two steps, interlocked by the + * vlan mutex (if any: first, the parent interface's address list + * should be propagated to the softc, then from the softc to the + * child, in order to avoid holding parent's and child's if_addr_mtx + * at the same time. Races can occur, but won't result in + * incorrectness. Assuming there is a vlan mutex. + */ IF_ADDR_LOCK(ifp); TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200508041107.j74B7adD073352>