From: Tobias Platen Date: Wed, 24 Nov 2021 18:50:05 +0000 (+0100) Subject: fix exception handling in pi_ld X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a3eebf0b06c52cb13cbd7a67481ff4f3eb789fe9;p=soc.git fix exception handling in pi_ld --- diff --git a/src/soc/config/test/test_pi2ls.py b/src/soc/config/test/test_pi2ls.py index 486dc5c9..48f0e5b3 100644 --- a/src/soc/config/test/test_pi2ls.py +++ b/src/soc/config/test/test_pi2ls.py @@ -104,7 +104,7 @@ def pi_ld(port1, addr, datalen, msr_pr=0): print("print fast exception happened") yield port1.is_ld_i.eq(0) # end yield port1.addr.ok.eq(0) # set !ok - return 0, "fast" + return None, "fast" yield yield from wait_ldok(port1) # wait until ld ok @@ -115,10 +115,14 @@ def pi_ld(port1, addr, datalen, msr_pr=0): yield port1.is_ld_i.eq(0) # end yield port1.addr.ok.eq(0) # set !ok if exc_happened: - return 0, "slow" + return None, "slow" yield from wait_busy(port1,debug="pi_ld_E") # wait while busy + exc_happened = yield port1.exc_o.happened + if exc_happened: + return None, "slow" + return data, None