CVSROOT: /cvs
Module name: src
Changes by: [email protected] 2019/07/10 10:43:20
Modified files:
sys/dev/pci/drm: drm_linux.c
sys/isofs/cd9660: cd9660_vnops.c
sys/kern : kern_descrip.c kern_sysctl.c vfs_syscalls.c
vfs_vnops.c
sys/miscfs/fuse: fuse_vnops.c
sys/msdosfs : msdosfs_vnops.c
sys/nfs : nfs_kq.c
sys/sys : file.h
sys/tmpfs : tmpfs_vnops.c
sys/ufs/ufs : ufs_vnops.c
Log message:
Make read/write of the f_offset field belonging to struct file MP-safe;
as part of the effort to unlock the kernel. Instead of relying on the
vnode lock, introduce a dedicated lock per file. Exclusive write access
is granted using the new foffset_enter and foffset_leave API. A
convenience function foffset_get is also available for threads that only
need to read the current offset.
The lock acquisition order in vn_write has been changed to match the one
in vn_read in order to avoid a potential deadlock. This change also gets
rid of a documented race in vn_read().
Inspired by the FreeBSD implementation.
With help and ok mpi@ visa@