Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 May 2011 14:47:53 +0300
From:      Kostik Belousov <kostikbel@gmail.com>
To:        Oliver Pinter <oliver.pntr@gmail.com>
Cc:        svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   Re: svn commit: r222274 - stable/8/sys/kern
Message-ID:  <20110525114753.GY48734@deviant.kiev.zoral.com.ua>
In-Reply-To: <BANLkTimE9eYRP-nkzVOdreHR_3Ahvvxg1Q@mail.gmail.com>
References:  <201105250325.p4P3PEvI097170@svn.freebsd.org> <BANLkTimE9eYRP-nkzVOdreHR_3Ahvvxg1Q@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--CJhilzLIyAgaRUK6
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Wed, May 25, 2011 at 12:11:29PM +0200, Oliver Pinter wrote:
> MFC to 7-STABLE?
Somebody need to test it for 7 (I do not expect any failures, but I also
prefer to not commit untested changes).

The testing should include destroying some devfs nodes, e.g. by loading
and unloading a driver that creates and destroys them.
>=20
> On 5/25/11, Konstantin Belousov <kib@freebsd.org> wrote:
> > Author: kib
> > Date: Wed May 25 03:25:14 2011
> > New Revision: 222274
> > URL: http://svn.freebsd.org/changeset/base/222274
> >
> > Log:
> >   MFC r222086:
> >   The protection against the race with dev_rel(), introduced in r163328,
> >   should be extended to cover destroy_devl() calls for the children of =
the
> >   destroyed dev.
> >
> > Modified:
> >   stable/8/sys/kern/kern_conf.c
> > Directory Properties:
> >   stable/8/sys/   (props changed)
> >   stable/8/sys/amd64/include/xen/   (props changed)
> >   stable/8/sys/cddl/contrib/opensolaris/   (props changed)
> >   stable/8/sys/contrib/dev/acpica/   (props changed)
> >   stable/8/sys/contrib/pf/   (props changed)
> >
> > Modified: stable/8/sys/kern/kern_conf.c
> > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D
> > --- stable/8/sys/kern/kern_conf.c	Wed May 25 01:04:12 2011	(r222273)
> > +++ stable/8/sys/kern/kern_conf.c	Wed May 25 03:25:14 2011	(r222274)
> > @@ -885,6 +885,8 @@ destroy_devl(struct cdev *dev)
> >  	/* Remove name marking */
> >  	dev->si_flags &=3D ~SI_NAMED;
> >
> > +	dev->si_refcount++;	/* Avoid race with dev_rel() */
> > +
> >  	/* If we are a child, remove us from the parents list */
> >  	if (dev->si_flags & SI_CHILD) {
> >  		LIST_REMOVE(dev, si_siblings);
> > @@ -901,7 +903,6 @@ destroy_devl(struct cdev *dev)
> >  		dev->si_flags &=3D ~SI_CLONELIST;
> >  	}
> >
> > -	dev->si_refcount++;	/* Avoid race with dev_rel() */
> >  	csw =3D dev->si_devsw;
> >  	dev->si_devsw =3D NULL;	/* already NULL for SI_ALIAS */
> >  	while (csw !=3D NULL && csw->d_purge !=3D NULL && dev->si_threadcount=
) {
> > _______________________________________________
> > svn-src-stable@freebsd.org mailing list
> > http://lists.freebsd.org/mailman/listinfo/svn-src-stable
> > To unsubscribe, send any mail to "svn-src-stable-unsubscribe@freebsd.or=
g"
> >

--CJhilzLIyAgaRUK6
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (FreeBSD)

iEYEARECAAYFAk3c7GkACgkQC3+MBN1Mb4gDxwCeK/R6qSfnG9tedZr+Iw+jKY+N
sn4AoLPok6OmOzCMZokuUCg3wp9cHv5t
=qMp9
-----END PGP SIGNATURE-----

--CJhilzLIyAgaRUK6--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110525114753.GY48734>