targets/arty/genesys2: fix EthernetSoC/EtherboneSoC selection
authorFlorent Kermarrec <florent@enjoy-digital.fr>
Thu, 16 Jan 2020 12:17:33 +0000 (13:17 +0100)
committerFlorent Kermarrec <florent@enjoy-digital.fr>
Thu, 16 Jan 2020 12:17:33 +0000 (13:17 +0100)
litex/boards/targets/arty.py
litex/boards/targets/genesys2.py

index 903ef59478fb0812eeb9f4541e234154e6db93f5..4e46344920595ff366b397f491141d029f8dcc9b 100755 (executable)
@@ -148,8 +148,11 @@ def main():
     args = parser.parse_args()
 
     assert not (args.with_ethernet and args.with_etherbone)
-    cls = EthernetSoC if args.with_ethernet else BaseSoC
-    cls = EtherboneSoC if args.with_etherbone else BaseSoC
+    cls = BaseSoC
+    if args.with_ethernet:
+        cls = EthernetSoC
+    if args.with_etherbone:
+        cls = EtherboneSoC
     soc = cls(**soc_sdram_argdict(args))
     builder = Builder(soc, **builder_argdict(args))
     builder.build(**vivado_build_argdict(args))
index afa4b2bdcf4d8ea9ee31e142007d762a5127b9db..30478c0101f85e1458495a34c8c4d9a4ad585717 100755 (executable)
@@ -139,8 +139,11 @@ def main():
     args = parser.parse_args()
 
     assert not (args.with_ethernet and args.with_etherbone)
-    cls = EthernetSoC if args.with_ethernet else BaseSoC
-    cls = EtherboneSoC if args.with_etherbone else BaseSoC
+    cls = BaseSoC
+    if args.with_ethernet:
+        cls = EthernetSoC
+    if args.with_etherbone:
+        cls = EtherboneSoC
     soc = cls(**soc_sdram_argdict(args))
     builder = Builder(soc, **builder_argdict(args))
     builder.build()