mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:17:36 +00:00
Kernel: Implement read functionality for MemoryDevice
So far we only had mmap(2) functionality on the /dev/mem device, but now we can also do read(2) on it. The test unit was updated to check we are doing it safely.
This commit is contained in:
parent
6feb07fe43
commit
ca254699ec
4 changed files with 81 additions and 18 deletions
|
@ -230,7 +230,7 @@ public:
|
|||
PageDirectory& kernel_page_directory() { return *m_kernel_page_directory; }
|
||||
|
||||
Vector<UsedMemoryRange> const& used_memory_ranges() { return m_used_memory_ranges; }
|
||||
bool is_allowed_to_mmap_physical_memory_to_userspace(PhysicalAddress, VirtualRange const&) const;
|
||||
bool is_allowed_to_read_physical_memory_for_userspace(PhysicalAddress, size_t read_length) const;
|
||||
|
||||
PhysicalPageEntry& get_physical_page_entry(PhysicalAddress);
|
||||
PhysicalAddress get_physical_address(PhysicalPage const&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue