MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / read_word

Method read_word

crates/virtual-machine/src/bus.rs:293–296  ·  view source on GitHub ↗
(&mut self, addr: u64)

Source from the content-addressed store, hash-verified

291 // fall inside the ROM range. SYSCON writes are intercepted in `MemoryAccess` below.
292 #[inline]
293 fn route(&mut self, addr: u64) -> Option<(&mut dyn MemoryAccess, u64)> {
294 match addr {
295 a if a >= UART_BASE && a <= UART_END => Some((&mut self.uart, addr - UART_BASE)),
296 a if a >= CLINT_BASE && a <= CLINT_END => Some((&mut self.clint, addr - CLINT_BASE)),
297 a if a >= PLIC_BASE && a <= PLIC_END => Some((&mut self.plic, addr - PLIC_BASE)),
298 a if a >= FB_BASE && a <= FB_END => Some((&mut self.framebuffer, addr - FB_BASE)),
299 a if a >= KBD_BASE && a <= KBD_END => Some((&mut self.keyboard, addr - KBD_BASE)),

Callers

nothing calls this directly

Calls 1

routeMethod · 0.80

Tested by

no test coverage detected