Function mod_mgmt::crate_name_from_path
pub fn crate_name_from_path(object_file_path: &Path) -> Option<&str>
Expand description
Returns the crate name that is derived from a crate object file path.
+Function mod_mgmt::crate_name_from_path
source · pub fn crate_name_from_path(object_file_path: &Path) -> Option<&str>
Expand description
Returns the crate name that is derived from a crate object file path.
Examples of acceptable paths
Legal paths can:
-
diff --git a/doc/mod_mgmt/fn.get_containing_crate_name.html b/doc/mod_mgmt/fn.get_containing_crate_name.html
index e9826e11a3..453722dae5 100644
--- a/doc/mod_mgmt/fn.get_containing_crate_name.html
+++ b/doc/mod_mgmt/fn.get_containing_crate_name.html
@@ -1,4 +1,4 @@
-
[beginning : at_page - 1]
@@ -45,7 +45,7 @@ - If
at_page == self.end + 1
, the second returnedAllocatedPages
object will be empty.
Function mod_mgmt::get_containing_crate_name
pub fn get_containing_crate_name(
+get_containing_crate_name in mod_mgmt - Rust Function mod_mgmt::get_containing_crate_name
source · pub fn get_containing_crate_name(
demangled_full_symbol: &str
) -> Vec<&str, Global>
Expand description
Parses the given symbol string to try to find the name of the parent crate
that contains the symbol.
diff --git a/doc/mod_mgmt/fn.get_containing_crate_name_ranges.html b/doc/mod_mgmt/fn.get_containing_crate_name_ranges.html
index 48cdd1d6c9..57b9508e98 100644
--- a/doc/mod_mgmt/fn.get_containing_crate_name_ranges.html
+++ b/doc/mod_mgmt/fn.get_containing_crate_name_ranges.html
@@ -1,4 +1,4 @@
-
get_containing_crate_name_ranges in mod_mgmt - Rust Function mod_mgmt::get_containing_crate_name_ranges
pub fn get_containing_crate_name_ranges(
+get_containing_crate_name_ranges in mod_mgmt - Rust Function mod_mgmt::get_containing_crate_name_ranges
source · pub fn get_containing_crate_name_ranges(
demangled_full_symbol: &str
) -> Vec<Range<usize>, Global>
Expand description
Same as get_containing_crate_name()
,
but returns the substring Range
s of where the parent crate names
diff --git a/doc/mod_mgmt/fn.is_valid_crate_name_char.html b/doc/mod_mgmt/fn.is_valid_crate_name_char.html
index 8f9a331665..28b4e9fb6e 100644
--- a/doc/mod_mgmt/fn.is_valid_crate_name_char.html
+++ b/doc/mod_mgmt/fn.is_valid_crate_name_char.html
@@ -1,3 +1,3 @@
-
is_valid_crate_name_char in mod_mgmt - Rust Function mod_mgmt::is_valid_crate_name_char
pub fn is_valid_crate_name_char(c: char) -> bool
Expand description
Crate names must be only alphanumeric characters, an underscore, or a dash.
+is_valid_crate_name_char in mod_mgmt - Rust Function mod_mgmt::is_valid_crate_name_char
source · pub fn is_valid_crate_name_char(c: char) -> bool
Expand description
Crate names must be only alphanumeric characters, an underscore, or a dash.
See: https://www.reddit.com/r/rust/comments/4rlom7/what_characters_are_allowed_in_a_crate_name/
\ No newline at end of file
diff --git a/doc/mod_mgmt/fn.replace_containing_crate_name.html b/doc/mod_mgmt/fn.replace_containing_crate_name.html
index a5f8b39ec7..01dee5aace 100644
--- a/doc/mod_mgmt/fn.replace_containing_crate_name.html
+++ b/doc/mod_mgmt/fn.replace_containing_crate_name.html
@@ -1,4 +1,4 @@
-replace_containing_crate_name in mod_mgmt - Rust Function mod_mgmt::replace_containing_crate_name
pub fn replace_containing_crate_name(
+replace_containing_crate_name in mod_mgmt - Rust Function mod_mgmt::replace_containing_crate_name
source · pub fn replace_containing_crate_name(
demangled_full_symbol: &str,
old_crate_name: &str,
new_crate_name: &str
diff --git a/doc/page_allocator/enum.AllocationError.html b/doc/page_allocator/enum.AllocationError.html
index d07533918b..68571d07e4 100644
--- a/doc/page_allocator/enum.AllocationError.html
+++ b/doc/page_allocator/enum.AllocationError.html
@@ -1,10 +1,10 @@
AllocationError in page_allocator - Rust Enum page_allocator::AllocationError
source · pub enum AllocationError {
- AddressNotFree(Page<Page4K>, usize),
- OutOfAddressSpace(usize, Option<PageRange<Page4K>>),
+ AddressNotFree(Page<Page4K>, usize),
+ OutOfAddressSpace(usize, Option<PageRange<Page4K>>),
NotInitialized,
}
Expand description
Possible errors returned by the page allocator.
-Variants§
§AddressNotFree(Page<Page4K>, usize)
The requested address was not free: it was already allocated, or is outside the range of this allocator.
-§OutOfAddressSpace(usize, Option<PageRange<Page4K>>)
The address space was full, or there was not a large-enough chunk
+
Variants§
§AddressNotFree(Page<Page4K>, usize)
The requested address was not free: it was already allocated, or is outside the range of this allocator.
+§OutOfAddressSpace(usize, Option<PageRange<Page4K>>)
The address space was full, or there was not a large-enough chunk
or enough remaining chunks (within the given PageRange
, if any)
that could satisfy the requested allocation size.
§NotInitialized
The allocator has not yet been initialized.
diff --git a/doc/page_allocator/enum.AllocationRequest.html b/doc/page_allocator/enum.AllocationRequest.html
index 27f89292f9..907fc30a02 100644
--- a/doc/page_allocator/enum.AllocationRequest.html
+++ b/doc/page_allocator/enum.AllocationRequest.html
@@ -1,17 +1,17 @@
AllocationRequest in page_allocator - Rust pub enum AllocationRequest<'r> {
- AtVirtualAddress(VirtualAddress),
+ AtVirtualAddress(VirtualAddress),
AlignedTo {
alignment_4k_pages: usize,
},
- WithinRange(&'r PageRange<Page4K>),
+ WithinRange(&'r PageRange<Page4K>),
Any,
}
Expand description
Possible options when requesting pages from the page allocator.
-Variants§
§AtVirtualAddress(VirtualAddress)
The allocated pages must start exactly at the given VirtualAddress
.
+Variants§
§AtVirtualAddress(VirtualAddress)
The allocated pages must start exactly at the given VirtualAddress
.
§AlignedTo
The allocated pages may be located at any virtual address,
but the starting page must be aligned to a multiple of alignment_4k_pages
.
An alignment of 1
page is equivalent to specifying no alignment requirement.
Note: alignment is specified in number of 4KiB pages, not number of bytes.
-§WithinRange(&'r PageRange<Page4K>)
The allocated pages can be located anywhere within the given range.
+§WithinRange(&'r PageRange<Page4K>)
The allocated pages can be located anywhere within the given range.
§Any
The allocated pages can be located at any virtual address
and have no special alignment requirements beyond a single page.
Auto Trait Implementations§
§impl<'r> RefUnwindSafe for AllocationRequest<'r>
§impl<'r> Send for AllocationRequest<'r>
§impl<'r> Sync for AllocationRequest<'r>
§impl<'r> Unpin for AllocationRequest<'r>
§impl<'r> UnwindSafe for AllocationRequest<'r>
Blanket Implementations§
source§impl<T> Any for Twhere
diff --git a/doc/page_allocator/fn.allocate_pages.html b/doc/page_allocator/fn.allocate_pages.html
index 72cdaf6ef8..277efb2f14 100644
--- a/doc/page_allocator/fn.allocate_pages.html
+++ b/doc/page_allocator/fn.allocate_pages.html
@@ -1,3 +1,3 @@
-allocate_pages in page_allocator - Rust Function page_allocator::allocate_pages
source · pub fn allocate_pages(num_pages: usize) -> Option<AllocatedPages<Page4K>>
Expand description
Allocates the given number of pages with no constraints on the starting virtual address.
+allocate_pages in page_allocator - Rust Function page_allocator::allocate_pages
source · pub fn allocate_pages(num_pages: usize) -> Option<AllocatedPages<Page4K>>
Expand description
Allocates the given number of pages with no constraints on the starting virtual address.
See allocate_pages_deferred()
for more details.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.allocate_pages_at.html b/doc/page_allocator/fn.allocate_pages_at.html
index ba88cabdb9..df9a0d2399 100644
--- a/doc/page_allocator/fn.allocate_pages_at.html
+++ b/doc/page_allocator/fn.allocate_pages_at.html
@@ -1,6 +1,6 @@
allocate_pages_at in page_allocator - Rust Function page_allocator::allocate_pages_at
source · pub fn allocate_pages_at(
- vaddr: VirtualAddress,
+ vaddr: VirtualAddress,
num_pages: usize
-) -> Result<AllocatedPages<Page4K>, &'static str>
Expand description
Allocates the given number of pages starting at (inclusive of) the page containing the given VirtualAddress
.
+) -> Result<AllocatedPages<Page4K>, &'static str>Expand description
Allocates the given number of pages starting at (inclusive of) the page containing the given VirtualAddress
.
See allocate_pages_deferred()
for more details.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.allocate_pages_by_bytes.html b/doc/page_allocator/fn.allocate_pages_by_bytes.html
index 64874a6431..fe373c4d4b 100644
--- a/doc/page_allocator/fn.allocate_pages_by_bytes.html
+++ b/doc/page_allocator/fn.allocate_pages_by_bytes.html
@@ -1,6 +1,6 @@
allocate_pages_by_bytes in page_allocator - Rust Function page_allocator::allocate_pages_by_bytes
source · pub fn allocate_pages_by_bytes(
num_bytes: usize
-) -> Option<AllocatedPages<Page4K>>
Expand description
Allocates pages with no constraints on the starting virtual address,
+) -> Option<AllocatedPages<Page4K>>Expand description
Allocates pages with no constraints on the starting virtual address,
with a size given by the number of bytes.
This function still allocates whole pages by rounding up the number of bytes.
See allocate_pages_deferred()
for more details.
diff --git a/doc/page_allocator/fn.allocate_pages_by_bytes_at.html b/doc/page_allocator/fn.allocate_pages_by_bytes_at.html
index 3a30a86252..70896e1171 100644
--- a/doc/page_allocator/fn.allocate_pages_by_bytes_at.html
+++ b/doc/page_allocator/fn.allocate_pages_by_bytes_at.html
@@ -1,7 +1,7 @@
allocate_pages_by_bytes_at in page_allocator - Rust Function page_allocator::allocate_pages_by_bytes_at
source · pub fn allocate_pages_by_bytes_at(
- vaddr: VirtualAddress,
+ vaddr: VirtualAddress,
num_bytes: usize
-) -> Result<AllocatedPages<Page4K>, &'static str>
Expand description
Allocates pages starting at the given VirtualAddress
with a size given in number of bytes.
+) -> Result<AllocatedPages<Page4K>, &'static str>Expand description
Allocates pages starting at the given VirtualAddress
with a size given in number of bytes.
This function still allocates whole pages by rounding up the number of bytes.
See allocate_pages_deferred()
for more details.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.allocate_pages_by_bytes_deferred.html b/doc/page_allocator/fn.allocate_pages_by_bytes_deferred.html
index 1aa1792f32..83ff9e138d 100644
--- a/doc/page_allocator/fn.allocate_pages_by_bytes_deferred.html
+++ b/doc/page_allocator/fn.allocate_pages_by_bytes_deferred.html
@@ -1,7 +1,7 @@
allocate_pages_by_bytes_deferred in page_allocator - Rust Function page_allocator::allocate_pages_by_bytes_deferred
source · pub fn allocate_pages_by_bytes_deferred(
request: AllocationRequest<'_>,
num_bytes: usize
-) -> Result<(AllocatedPages<Page4K>, DeferredAllocAction<'static>), &'static str>
Expand description
Similar to allocated_pages_deferred()
,
+) -> Result<(AllocatedPages<Page4K>, DeferredAllocAction<'static>), &'static str>Expand description
Similar to allocated_pages_deferred()
,
but accepts a size value for the allocated pages in number of bytes instead of number of pages.
This function still allocates whole pages by rounding up the number of bytes.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.allocate_pages_by_bytes_in_range.html b/doc/page_allocator/fn.allocate_pages_by_bytes_in_range.html
index 52828dc36c..219ee84f6c 100644
--- a/doc/page_allocator/fn.allocate_pages_by_bytes_in_range.html
+++ b/doc/page_allocator/fn.allocate_pages_by_bytes_in_range.html
@@ -1,6 +1,6 @@
allocate_pages_by_bytes_in_range in page_allocator - Rust Function page_allocator::allocate_pages_by_bytes_in_range
source · pub fn allocate_pages_by_bytes_in_range(
num_bytes: usize,
- range: &PageRange<Page4K>
-) -> Result<AllocatedPages<Page4K>, &'static str>
Expand description
Allocates pages with a size given in number of bytes with the constraint that
+ range: &PageRange<Page4K>
+) -> Result<AllocatedPages<Page4K>, &'static str>Expand description
Allocates pages with a size given in number of bytes with the constraint that
they must be within the given inclusive range
of pages.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.allocate_pages_deferred.html b/doc/page_allocator/fn.allocate_pages_deferred.html
index a1331e31b9..f171eead89 100644
--- a/doc/page_allocator/fn.allocate_pages_deferred.html
+++ b/doc/page_allocator/fn.allocate_pages_deferred.html
@@ -1,7 +1,7 @@
allocate_pages_deferred in page_allocator - Rust Function page_allocator::allocate_pages_deferred
source · pub fn allocate_pages_deferred(
request: AllocationRequest<'_>,
num_pages: usize
-) -> Result<(AllocatedPages<Page4K>, DeferredAllocAction<'static>), &'static str>
Expand description
The core page allocation routine that allocates the given number of virtual pages,
+) -> Result<(AllocatedPages<Page4K>, DeferredAllocAction<'static>), &'static str>Expand description
The core page allocation routine that allocates the given number of virtual pages,
optionally at the requested starting VirtualAddress
.
This simply reserves a range of virtual addresses, it does not allocate
actual physical memory frames nor do any memory mapping.
diff --git a/doc/page_allocator/fn.allocate_pages_in_range.html b/doc/page_allocator/fn.allocate_pages_in_range.html
index 8efeccfee1..96dd0c8fc6 100644
--- a/doc/page_allocator/fn.allocate_pages_in_range.html
+++ b/doc/page_allocator/fn.allocate_pages_in_range.html
@@ -1,6 +1,6 @@
allocate_pages_in_range in page_allocator - Rust Function page_allocator::allocate_pages_in_range
source · pub fn allocate_pages_in_range(
num_pages: usize,
- range: &PageRange<Page4K>
-) -> Result<AllocatedPages<Page4K>, &'static str>
Expand description
Allocates the given number of pages with the constraint that
+ range: &PageRange<Page4K>
+) -> Result<AllocatedPages<Page4K>, &'static str>Expand description
Allocates the given number of pages with the constraint that
they must be within the given inclusive range
of pages.
\ No newline at end of file
diff --git a/doc/page_allocator/fn.init.html b/doc/page_allocator/fn.init.html
index 70e9b800dc..85c618925b 100644
--- a/doc/page_allocator/fn.init.html
+++ b/doc/page_allocator/fn.init.html
@@ -1,5 +1,5 @@
init in page_allocator - Rust Function page_allocator::init
source · pub fn init(
- end_vaddr_of_low_designated_region: VirtualAddress
+ end_vaddr_of_low_designated_region: VirtualAddress
) -> Result<(), &'static str>
Expand description
Initialize the page allocator.
Arguments
diff --git a/doc/page_allocator/struct.AllocatedPages.html b/doc/page_allocator/struct.AllocatedPages.html
index 2651e527de..1643ad75ef 100644
--- a/doc/page_allocator/struct.AllocatedPages.html
+++ b/doc/page_allocator/struct.AllocatedPages.html
@@ -1,23 +1,23 @@
-AllocatedPages in page_allocator - Rust Struct page_allocator::AllocatedPages
source · pub struct AllocatedPages<P: PageSize = Page4K> { /* private fields */ }
Expand description
Represents a range of allocated VirtualAddress
es, specified in Page
s.
+AllocatedPages in page_allocator - Rust Struct page_allocator::AllocatedPages
source · pub struct AllocatedPages<P: PageSize = Page4K> { /* private fields */ }
Expand description
Represents a range of allocated VirtualAddress
es, specified in Page
s.
These pages are not initially mapped to any physical memory frames, you must do that separately
in order to actually use their memory; see the MappedPages
type for more.
This object represents ownership of the allocated virtual pages;
if this object falls out of scope, its allocated pages will be auto-deallocated upon drop.
-Implementations§
source§impl<P: PageSize> AllocatedPages<P>
sourcepub const fn empty() -> AllocatedPages<P>
Returns an empty AllocatedPages object that performs no page allocation.
+
Implementations§
source§impl<P: PageSize> AllocatedPages<P>
sourcepub const fn empty() -> AllocatedPages<P>
Returns an empty AllocatedPages object that performs no page allocation.
Can be used as a placeholder, but will not permit any real usage.
-sourcepub const fn start_address(&self) -> VirtualAddress
Returns the starting VirtualAddress
in this range of pages.
+sourcepub const fn start_address(&self) -> VirtualAddress
Returns the starting VirtualAddress
in this range of pages.
sourcepub const fn size_in_bytes(&self) -> usize
Returns the size in bytes of this range of pages.
sourcepub const fn size_in_pages(&self) -> usize
Returns the size in number of pages of this range of pages.
-sourcepub const fn end(&self) -> &Page<P>
Returns the ending Page
(inclusive) in this range of pages.
-sourcepub const fn range(&self) -> &PageRange<P>
Returns a reference to the inner PageRange
, which is cloneable/iterable.
-sourcepub const fn offset_of_address(&self, addr: VirtualAddress) -> Option<usize>
Returns the offset of the given VirtualAddress
within this range of pages,
+
sourcepub const fn end(&self) -> &Page<P>
Returns the ending Page
(inclusive) in this range of pages.
+sourcepub const fn range(&self) -> &PageRange<P>
Returns a reference to the inner PageRange
, which is cloneable/iterable.
+sourcepub const fn offset_of_address(&self, addr: VirtualAddress) -> Option<usize>
Returns the offset of the given VirtualAddress
within this range of pages,
i.e., addr - self.start_address()
.
If the given addr
is not covered by this range of pages, this returns None
.
Examples
If the range covers addresses 0x2000
to 0x4000
,
then offset_of_address(0x3500)
would return Some(0x1500)
.
-sourcepub const fn address_at_offset(&self, offset: usize) -> Option<VirtualAddress>
Returns the VirtualAddress
at the given offset into this range of pages,
+
sourcepub const fn address_at_offset(&self, offset: usize) -> Option<VirtualAddress>
sourcepub fn split(
self,
- at_page: Page<P>
+ at_page: Page<P>
) -> Result<(AllocatedPages<P>, AllocatedPages<P>), AllocatedPages<P>>
Splits this AllocatedPages
into two separate AllocatedPages
objects:
Examples
Returns an Err
containing this AllocatedPages
if at_page
is otherwise out of bounds.
-Trait Implementations§
source§impl<P: PageSize> Debug for AllocatedPages<P>
source§impl<P: PageSize> Default for AllocatedPages<P>
source§fn default() -> AllocatedPages<P>
Returns the “default value” for a type. Read moreAuto Trait Implementations§
§impl<P> RefUnwindSafe for AllocatedPages<P>where
+
Trait Implementations§
source§impl<P: PageSize> Debug for AllocatedPages<P>
source§impl<P: PageSize> Default for AllocatedPages<P>
source§fn default() -> AllocatedPages<P>
Returns the “default value” for a type. Read moreAuto Trait Implementations§
§impl<P> RefUnwindSafe for AllocatedPages<P>where
P: RefUnwindSafe,
§impl<P> Send for AllocatedPages<P>where
P: Send,
§impl<P> Sync for AllocatedPages<P>where
P: Sync,
§impl<P> Unpin for AllocatedPages<P>where
diff --git a/doc/stdio/struct.KeyEventQueueReader.html b/doc/stdio/struct.KeyEventQueueReader.html
index 4abc76dd32..358a177fae 100644
--- a/doc/stdio/struct.KeyEventQueueReader.html
+++ b/doc/stdio/struct.KeyEventQueueReader.html
@@ -1,5 +1,5 @@
KeyEventQueueReader in stdio - Rust Struct stdio::KeyEventQueueReader
source · pub struct KeyEventQueueReader { /* private fields */ }
Expand description
A reader to keyevent ring buffer.
-Implementations§
source§impl KeyEventQueueReader
sourcepub fn read_one(&self) -> Option<KeyEvent>
Try to read a keyevent from the ring buffer. It returns None
if currently
+
Implementations§
Trait Implementations§
source§impl Clone for KeyEventQueueReader
source§fn clone(&self) -> KeyEventQueueReader
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read moreAuto Trait Implementations§
§impl !RefUnwindSafe for KeyEventQueueReader
§impl Send for KeyEventQueueReader
§impl Sync for KeyEventQueueReader
§impl Unpin for KeyEventQueueReader
§impl !UnwindSafe for KeyEventQueueReader
Blanket Implementations§
source§impl<T> Borrow<T> for Twhere
diff --git a/doc/stdio/struct.KeyEventQueueWriter.html b/doc/stdio/struct.KeyEventQueueWriter.html
index b642149cad..535db9cf36 100644
--- a/doc/stdio/struct.KeyEventQueueWriter.html
+++ b/doc/stdio/struct.KeyEventQueueWriter.html
@@ -1,5 +1,5 @@
KeyEventQueueWriter in stdio - Rust Struct stdio::KeyEventQueueWriter
source · pub struct KeyEventQueueWriter { /* private fields */ }
Expand description
A writer to keyevent ring buffer.
-Implementations§
source§impl KeyEventQueueWriter
Implementations§
Trait Implementations§
source§impl Clone for KeyEventQueueWriter
source§fn clone(&self) -> KeyEventQueueWriter
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read moreAuto Trait Implementations§
§impl !RefUnwindSafe for KeyEventQueueWriter
§impl Send for KeyEventQueueWriter
§impl Sync for KeyEventQueueWriter
§impl Unpin for KeyEventQueueWriter
§impl !UnwindSafe for KeyEventQueueWriter
Blanket Implementations§