From 18e1d6e867b75337fc9fea121a8e584116e59132 Mon Sep 17 00:00:00 2001 From: bunnie Date: Sun, 2 Oct 2022 21:45:36 +0800 Subject: [PATCH] switch over to the log uart on boot this helps minimal configurations to be more useful without pulling in com/llio crates. The trade-off is that KP's early in boot (or during resume) are not visible, but, these are (thankfully??) less rare these days. --- loader/src/main.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/loader/src/main.rs b/loader/src/main.rs index d7361d552..07e1cf851 100644 --- a/loader/src/main.rs +++ b/loader/src/main.rs @@ -1313,6 +1313,10 @@ fn boot_sequence(args: KernelArguments, _signature: u32) -> ! { } } } + use utralib::generated::*; + let mut gpio_csr = CSR::new(utra::gpio::HW_GPIO_BASE as *mut u32); + gpio_csr.wfo(utra::gpio::UARTSEL_UARTSEL, 1); // patch us over to a different UART for debug (1=LOG 2=APP, 0=KERNEL(hw reset default)) + unsafe { start_kernel( arg_offset,