Skip to content

Commit 380f98f

Browse files
Merge pull request #1234 from phip1611/mem
mem: introduce traits MemoryMap and MemoryMapMut
2 parents 94938ef + db5e9c8 commit 380f98f

File tree

5 files changed

+271
-121
lines changed

5 files changed

+271
-121
lines changed

uefi-test-runner/src/boot/memory.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use uefi::table::boot::{AllocateType, BootServices, MemoryType};
1+
use uefi::table::boot::{AllocateType, BootServices, MemoryMap, MemoryMapMut, MemoryType};
22

33
use alloc::vec::Vec;
44

uefi-test-runner/src/main.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ use uefi::prelude::*;
1212
use uefi::proto::console::serial::Serial;
1313
use uefi::proto::device_path::build::{self, DevicePathBuilder};
1414
use uefi::proto::device_path::messaging::Vendor;
15-
use uefi::table::boot::MemoryType;
15+
use uefi::table::boot::{MemoryMap, MemoryType};
1616
use uefi::{print, println, Result};
1717

1818
mod boot;

uefi/CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44
- **Breaking:** `uefi::helpers::init` no longer takes an argument.
55
- The lifetime of the `SearchType` returned from
66
`BootServices::register_protocol_notify` is now tied to the protocol GUID.
7+
- The traits `MemoryMap` and `MemoryMapMut` have been introduced together with
8+
the implementations `MemoryMapRef`, `MemoryMapRefMut`, and `MemoryMapOwned`.
9+
The old `MemoryMap` was renamed to `MemoryMapOwned`.
10+
- `pub fn memory_map(&self, mt: MemoryType) -> Result<MemoryMap>` now returns
11+
a `MemoryMapOwned`.
712

813

914
# uefi - 0.29.0 (2024-07-02)

0 commit comments

Comments
 (0)