aboutsummaryrefslogtreecommitdiff
path: root/sys/compat/linuxkpi/common/include/linux/sched.h
diff options
context:
space:
mode:
authorHans Petter Selasky <hselasky@FreeBSD.org>2017-04-06 09:34:54 +0000
committerHans Petter Selasky <hselasky@FreeBSD.org>2017-04-06 09:34:54 +0000
commit1ea4c85781e9404e78b9444f27cf4f8ed3915649 (patch)
tree138c3bb83d0e8e006c09e00b5f341add3f65a7e6 /sys/compat/linuxkpi/common/include/linux/sched.h
parente54b103e700fe6c38316cecd39957561197379a6 (diff)
downloadsrc-1ea4c85781e9404e78b9444f27cf4f8ed3915649.tar.gz
src-1ea4c85781e9404e78b9444f27cf4f8ed3915649.zip
Implement proper support for memory map operations in the LinuxKPI,
like open, close and fault using the character device pager. Some notes about the implementation: 1) Linux drivers set the vm_ops and vm_private_data fields during a mmap() call to indicate that the driver wants to use the LinuxKPI VM operations. Else these operations are not used. 2) The vm_private_data pointer is associated with a VM area structure and inserted into an internal LinuxKPI list. If the vm_private_data pointer already exists, the existing VM area structure is used instead of the allocated one which gets freed. 3) The LinuxKPI's vm_private_data pointer is used as the callback handle for the FreeBSD VM object. The VM subsystem in FreeBSD has a similar list to identify equal handles and will only call the character device pager's close function once. 4) All LinuxKPI VM operations are serialized through the mmap_sem sempaphore, which is per procedure, which prevents simultaneous access to the shared VM area structure when receiving page faults. Obtained from: kmacy @ MFC after: 1 week Sponsored by: Mellanox Technologies
Notes
Notes: svn path=/head/; revision=316562
Diffstat (limited to 'sys/compat/linuxkpi/common/include/linux/sched.h')
0 files changed, 0 insertions, 0 deletions