Microkernel Message Buffer Memory Mapping for IPC Efficiency
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional operating systems, including microkernel configurations, face inefficiencies and security vulnerabilities due to resource-intensive inter-process communication (IPC) methods that require numerous system calls and copying actions, and tight coupling between user-space processes can compromise security.
Innovation Solution
The implementation of an IPC channel with a message buffer mapped to both kernel and user-space virtual address spaces, allowing one-way communication with reduced system calls and copy actions, while maintaining process isolation through controlled access rights.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If conventional IPC methods with multiple system calls and copy actions are used, then communication between isolated user-space processes is possible, but resource consumption increases and efficiency decreases
Solution Approach 1:
The patent merges the kernel-space message buffer with user-space address spaces through memory mapping, allowing producer and consumer processes to access the same physical memory region without requiring data copying. This combines the isolation benefits of microkernel architecture with the efficiency of shared memory, resolving the contradiction between process isolation and communication efficiency
Solution Approach 2:
The kernel acts as an intermediary that manages the message buffer and controls access permissions. By using memory-mapped files with controlled access rights, the kernel enables direct process-to-process communication while maintaining security boundaries, eliminating the need for multiple system calls and copy actions
2Productivity
If shared memory regions are used for process communication, then communication efficiency improves, but security vulnerabilities increase due to tight coupling
Solution Approach 1:
The patent applies different access permissions to different processes accessing the same message buffer. The producer process has write permissions while the consumer process has read permissions, creating localized quality differences in access rights. This allows efficient shared memory communication while maintaining security through permission-based isolation
Solution Approach 2:
The message buffer is segmented into distinct access regions with different permission levels. By dividing the shared memory space into producer-write regions and consumer-read regions with controlled access rights, the system achieves both communication efficiency and security, preventing untrusted processes from compromising other processes
3Reliability
If microkernel configuration with user-space processes is used, then system security and reliability improve, but resource-intensive system calls and copy actions increase
Solution Approach 1:
The patent merges kernel-space and user-space address spaces through memory mapping, allowing user-space processes to communicate directly through shared memory without requiring resource-intensive system calls and copy actions. This maintains the security benefits of microkernel architecture while dramatically reducing resource consumption
Solution Approach 2:
The patent eliminates unnecessary data copying by using memory-mapped shared memory. Instead of copying data between kernel space and user space through multiple system calls, processes access the same physical memory region directly, reducing resource consumption while maintaining security through controlled access rights
Data Source
AI summary
In one embodiment, a kernel of an operating system receives a request to store a message in a message buffer, which includes a plurality of chunks. Each chunk of the message buffer is associated with a message-occupancy indicator. The kernel determines a start and end position of the message when stored in the message buffer. The kernel determines, based on the start and end positions, whether the message, when stored, will occupy more than one chunk. Responsive to determining that the message will occupy more than one chunk, the kernel determines each chunk that will contain the message when stored. If a message occupancy-indicator associated with each chunk indicates that at least each chunk after a first chunk associated with the start position is unoccupied, the kernel stores the message in the message buffer and updates the message-occupancy indicator for each chunk containing the stored message.


