git: kernel - Fix one-cycle MP race in vshouldmsync()

看板DFBSD_commit作者時間15年前 (2010/09/13 02:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit aed76ef1f778cc4185ddd699631316d05d6811b6 Author: Matthew Dillon <dillon@apollo.backplane.com> Date: Sun Sep 12 10:30:38 2010 -0700 kernel - Fix one-cycle MP race in vshouldmsync() * vshouldmsync() is the mntvnode fast function, which is called without any vnode lock. vp->v_object can thus get ripped out from under the scan function. Hold vmobj_token through the scan so any pointer accessed via v_object remains stable (even if no longer related to the vnode due to the race). Reported-by: swildner Summary of changes: sys/kern/vfs_mount.c | 7 +++++++ sys/kern/vfs_subr.c | 14 ++++++++++---- 2 files changed, 17 insertions(+), 4 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/aed76ef1f778cc4185ddd699631316d05d6811b6 -- DragonFly BSD source repository
文章代碼(AID): #1CZHLgvx (DFBSD_commit)