summaryrefslogtreecommitdiff
path: root/Kernel/DoubleBuffer.h
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2022-08-23 18:51:18 +0200
committerAndreas Kling <kling@serenityos.org>2022-08-24 14:57:51 +0200
commit30861daa93c06280cff4e355b31d11ecbf8079ec (patch)
treefdb41ebda018893cf9498a11126194cf71e9395a /Kernel/DoubleBuffer.h
parentcf16b2c8e64709d570c5f54a981017d217e95ed0 (diff)
downloadserenity-30861daa93c06280cff4e355b31d11ecbf8079ec.zip
Kernel: Simplify the File memory-mapping API
Before this change, we had File::mmap() which did all the work of setting up a VMObject, and then creating a Region in the current process's address space. This patch simplifies the interface by removing the region part. Files now only have to return a suitable VMObject from vmobject_for_mmap(), and then sys$mmap() itself will take care of actually mapping it into the address space. This fixes an issue where we'd try to block on I/O (for inode metadata lookup) while holding the address space spinlock. It also reduces time spent holding the address space lock.
Diffstat (limited to 'Kernel/DoubleBuffer.h')
0 files changed, 0 insertions, 0 deletions