Date: Sun, 17 Jan 2016 08:34:35 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r294204 - head/sys/fs/devfs Message-ID: <201601170834.u0H8YZ12014987@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Sun Jan 17 08:34:35 2016 New Revision: 294204 URL: https://svnweb.freebsd.org/changeset/base/294204 Log: Assert that the linkage between struct cdev_privdata and and struct file is consistent. Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Modified: head/sys/fs/devfs/devfs_vnops.c Modified: head/sys/fs/devfs/devfs_vnops.c ============================================================================== --- head/sys/fs/devfs/devfs_vnops.c Sun Jan 17 06:02:59 2016 (r294203) +++ head/sys/fs/devfs/devfs_vnops.c Sun Jan 17 08:34:35 2016 (r294204) @@ -185,6 +185,8 @@ devfs_destroy_cdevpriv(struct cdev_privd { mtx_assert(&cdevpriv_mtx, MA_OWNED); + KASSERT(p->cdpd_fp->f_cdevpriv == p, + ("devfs_destoy_cdevpriv %p != %p", p->cdpd_fp->f_cdevpriv, p)); p->cdpd_fp->f_cdevpriv = NULL; LIST_REMOVE(p, cdpd_list); mtx_unlock(&cdevpriv_mtx);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201601170834.u0H8YZ12014987>