On Tue, 22 Dec 2015, Konstantin Belousov wrote:
Log:
Keep devfs mount locked for the whole duration of the devfs_setattr(),
and ensure that our dirent is instantiated.
Reported and tested by: bde
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Thanks.
This is part of fixing revoke(2). Even stat() doesn't work right when
it races revoke(). setattr() is used surprisingly often since it is used
for opening with O_TRUNC. open() racing with revoke() caused problems
doing the truncation even though truncation is a no-op for devfs.
Truncation is not atomic for opening with O_TRUNC.
Bruce
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"