From 647504d4c55e6fb28012efd72178f255aaf04fd6 Mon Sep 17 00:00:00 2001 From: Arne Jansen Date: Mon, 30 Jan 2023 07:46:37 +0100 Subject: [PATCH] align fixup --- litex/soc/integration/soc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litex/soc/integration/soc.py b/litex/soc/integration/soc.py index a63ce9bc9..bc68db3c7 100755 --- a/litex/soc/integration/soc.py +++ b/litex/soc/integration/soc.py @@ -260,7 +260,7 @@ class SoCBusHandler(LiteXModule): while (origin + size) < (search_region.origin + search_region.size_pow2): # Align Origin on Size. if (origin%size_pow2): - origin += (origin - origin%size_pow2) + origin += (size_pow2 - origin%size_pow2) continue # Create a Candidate. candidate = SoCRegion(origin=origin, size=size, cached=cached)