From f252e8b27f5a0fb66f04b7814d4fb79e1eeb13a1 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Sun, 26 Jan 2020 12:55:14 +0100 Subject: [PATCH] phy/usddrphy: simplify dqs_serdes_pattern --- litedram/phy/usddrphy.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/litedram/phy/usddrphy.py b/litedram/phy/usddrphy.py index cde1315..6a27859 100644 --- a/litedram/phy/usddrphy.py +++ b/litedram/phy/usddrphy.py @@ -1,4 +1,4 @@ -# This file is Copyright (c) 2015-2019 Florent Kermarrec +# This file is Copyright (c) 2015-2020 Florent Kermarrec # License: BSD # 1:4 frequency-ratio DDR3/DDR4 PHY for Kintex/Virtex Ultrascale @@ -252,16 +252,15 @@ class USDDRPHY(Module, AutoCSR): # DQS and DM ------------------------------------------------------------------------------- oe_dqs = Signal() dqs_serdes_pattern = Signal(8) - self.comb += \ + self.comb += [ + dqs_serdes_pattern.eq(0b01010101), If(self._wlevel_en.storage, + dqs_serdes_pattern.eq(0b00000000), If(self._wlevel_strobe.re, dqs_serdes_pattern.eq(0b00000001) - ).Else( - dqs_serdes_pattern.eq(0b00000000) ) - ).Else( - dqs_serdes_pattern.eq(0b01010101) ) + ] for i in range(databits//8): dm_o_nodelay = Signal() self.specials += [