From 0c1de42547526a7a40955c49568d4d4098331787 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Mon, 6 Jul 2020 00:54:44 +0800 Subject: [PATCH] use simplified ps7_init --- src/Cargo.lock | 10 +++++----- src/runtime/src/main.rs | 6 +++++- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/Cargo.lock b/src/Cargo.lock index a9590ba..ecf50c0 100644 --- a/src/Cargo.lock +++ b/src/Cargo.lock @@ -200,7 +200,7 @@ dependencies = [ [[package]] name = "libasync" version = "0.0.0" -source = "git+https://git.m-labs.hk/M-Labs/zc706.git#90e33f688ab8de54173caca1e8d9a7357def5df8" +source = "git+https://git.m-labs.hk/M-Labs/zc706.git#9fcf9243f2dd2e9fcd61d17ddb1d6d495a68893f" dependencies = [ "embedded-hal", "libcortex_a9", @@ -212,7 +212,7 @@ dependencies = [ [[package]] name = "libboard_zynq" version = "0.0.0" -source = "git+https://git.m-labs.hk/M-Labs/zc706.git#90e33f688ab8de54173caca1e8d9a7357def5df8" +source = "git+https://git.m-labs.hk/M-Labs/zc706.git#9fcf9243f2dd2e9fcd61d17ddb1d6d495a68893f" dependencies = [ "bit_field", "embedded-hal", @@ -236,7 +236,7 @@ dependencies = [ [[package]] name = "libcortex_a9" version = "0.0.0" -source = "git+https://git.m-labs.hk/M-Labs/zc706.git#90e33f688ab8de54173caca1e8d9a7357def5df8" +source = "git+https://git.m-labs.hk/M-Labs/zc706.git#9fcf9243f2dd2e9fcd61d17ddb1d6d495a68893f" dependencies = [ "bit_field", "libregister", @@ -245,7 +245,7 @@ dependencies = [ [[package]] name = "libregister" version = "0.0.0" -source = "git+https://git.m-labs.hk/M-Labs/zc706.git#90e33f688ab8de54173caca1e8d9a7357def5df8" +source = "git+https://git.m-labs.hk/M-Labs/zc706.git#9fcf9243f2dd2e9fcd61d17ddb1d6d495a68893f" dependencies = [ "bit_field", "vcell", @@ -255,7 +255,7 @@ dependencies = [ [[package]] name = "libsupport_zynq" version = "0.0.0" -source = "git+https://git.m-labs.hk/M-Labs/zc706.git#90e33f688ab8de54173caca1e8d9a7357def5df8" +source = "git+https://git.m-labs.hk/M-Labs/zc706.git#9fcf9243f2dd2e9fcd61d17ddb1d6d495a68893f" dependencies = [ "compiler_builtins", "libboard_zynq", diff --git a/src/runtime/src/main.rs b/src/runtime/src/main.rs index 8c31963..99d0282 100644 --- a/src/runtime/src/main.rs +++ b/src/runtime/src/main.rs @@ -9,7 +9,7 @@ extern crate alloc; use core::{cmp, str}; use log::{info, error}; -use libboard_zynq::{timer::GlobalTimer, logger, devc}; +use libboard_zynq::{timer::GlobalTimer, logger, devc, slcr}; use libsupport_zynq::ram; mod sd_reader; @@ -72,6 +72,10 @@ pub fn main_core0() { // Do not load again: assume that the gateware already present is // what we want (e.g. gateware configured via JTAG before PS // startup, or by FSBL). + // Make sure that the PL/PS interface is enabled (e.g. OpenOCD does not enable it). + slcr::RegisterBlock::unlocked(|slcr| { + slcr.init_postload_fpga(); + }); } else { // Load from SD card match load_pl::load_bitstream_from_sd() {