We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 188f312 commit d4b93c4Copy full SHA for d4b93c4
source/chapter4/5kernel-app-spaces.rst
@@ -107,7 +107,7 @@
107
fn push(&mut self, mut map_area: MapArea, data: Option<&[u8]>) {
108
map_area.map(&mut self.page_table);
109
if let Some(data) = data {
110
- map_area.copy_data(&mut self.page_table, data);
+ map_area.copy_data(&self.page_table, data);
111
}
112
self.areas.push(map_area);
113
@@ -170,7 +170,7 @@
170
171
/// data: start-aligned but maybe with shorter length
172
/// assume that all frames were cleared before
173
- pub fn copy_data(&mut self, page_table: &mut PageTable, data: &[u8]) {
+ pub fn copy_data(&mut self, page_table: &PageTable, data: &[u8]) {
174
assert_eq!(self.map_type, MapType::Framed);
175
let mut start: usize = 0;
176
let mut current_vpn = self.vpn_range.get_start();
0 commit comments