From 207b8f48bbf7d43e579a24e98aeab9fed24c88fc Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Wed, 30 Sep 2020 19:38:43 +0200 Subject: [PATCH] common: simplify/rename get_sys_phase (cmd_phase is always -1 can be calculated on phys). --- litedram/common.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/litedram/common.py b/litedram/common.py index 79f3718..7507a61 100644 --- a/litedram/common.py +++ b/litedram/common.py @@ -56,10 +56,8 @@ def get_cl_cw(memtype, tck): def get_sys_latency(nphases, cas_latency): return math.ceil(cas_latency/nphases) -def get_sys_phases(nphases, sys_latency, cas_latency): - dat_phase = sys_latency*nphases - cas_latency - cmd_phase = (dat_phase - 1)%nphases - return cmd_phase, dat_phase +def get_sys_phase(nphases, sys_latency, cas_latency): + return sys_latency*nphases - cas_latency # PHY Pads Transformers ----------------------------------------------------------------------------