Commit 335c836
committed
xen: implement GuestMemoryRegion for mmap_xen::MmapRegion
Xen's MmapRegion struct already stores a `GuestAddress` inside of it, so
there's no need to wrap it into a tuple of `(MmapRegion, GuestAddress)`
to implement this trait on (which is essentially what happens in
`mmap.rs`) - in fact, duplicating the GuestAddress seems wrong to be
because I don't see any mechanism for keeping them in-sync.
Do not duplication over the functions defined on mmap::GuestRegionMmap,
because there already exist functions with colliding names in mmap_xen.
Signed-off-by: Patrick Roy <roypat@amazon.co.uk>1 parent 68cd523 commit 335c836
3 files changed
+54
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
69 | 72 | | |
70 | 73 | | |
71 | 74 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
154 | | - | |
| 154 | + | |
155 | 155 | | |
156 | 156 | | |
157 | 157 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
30 | 34 | | |
31 | 35 | | |
32 | 36 | | |
| |||
151 | 155 | | |
152 | 156 | | |
153 | 157 | | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
154 | 202 | | |
155 | 203 | | |
156 | 204 | | |
| |||
308 | 356 | | |
309 | 357 | | |
310 | 358 | | |
311 | | - | |
312 | | - | |
| 359 | + | |
| 360 | + | |
313 | 361 | | |
314 | 362 | | |
315 | 363 | | |
| |||
0 commit comments