mirror of https://github.com/openXC7/prjxray.git
Fixed the 030 fuzzer to automatically detect where the PUDC_B site is.
Signed-off-by: Maciej Kurc <mkurc@antmicro.com>
This commit is contained in:
parent
2339c0715e
commit
9183126bdd
|
|
@ -5,6 +5,7 @@ from prjxray import segmaker
|
||||||
from prjxray import verilog
|
from prjxray import verilog
|
||||||
import os
|
import os
|
||||||
import json
|
import json
|
||||||
|
import csv
|
||||||
|
|
||||||
|
|
||||||
def bitfilter(frame, word):
|
def bitfilter(frame, word):
|
||||||
|
|
@ -20,20 +21,6 @@ def mk_drive_opt(iostandard, drive):
|
||||||
return '{}.DRIVE.I{}'.format(iostandard, drive)
|
return '{}.DRIVE.I{}'.format(iostandard, drive)
|
||||||
|
|
||||||
|
|
||||||
def skip_broken_tiles(d):
|
|
||||||
""" Skip tiles that appear to have bits always set.
|
|
||||||
|
|
||||||
This is likely caused by a defect?
|
|
||||||
|
|
||||||
"""
|
|
||||||
if os.getenv('XRAY_DATABASE') == 'artix7' and d['tile'] == 'LIOB33_X0Y43':
|
|
||||||
return True
|
|
||||||
if os.getenv('XRAY_DATABASE') == 'zynq7' and d['tile'] == 'RIOB33_X31Y43':
|
|
||||||
return True
|
|
||||||
|
|
||||||
return False
|
|
||||||
|
|
||||||
|
|
||||||
def drives_for_iostandard(iostandard):
|
def drives_for_iostandard(iostandard):
|
||||||
if iostandard in ['LVTTL', 'LVCMOS18']:
|
if iostandard in ['LVTTL', 'LVCMOS18']:
|
||||||
drives = [4, 8, 12, 16, 24]
|
drives = [4, 8, 12, 16, 24]
|
||||||
|
|
@ -71,6 +58,14 @@ def main():
|
||||||
for iobank in iobanks:
|
for iobank in iobanks:
|
||||||
iobank_iostandards[iobank] = set()
|
iobank_iostandards[iobank] = set()
|
||||||
|
|
||||||
|
# Load a list of PUDC_B pin function tiles. They are configured differently
|
||||||
|
# by the vendor tools so need to be skipped
|
||||||
|
pudc_tiles = set()
|
||||||
|
with open(os.path.join(os.getenv('FUZDIR'), 'build',
|
||||||
|
'pudc_sites.csv')) as f:
|
||||||
|
for l in csv.DictReader(f):
|
||||||
|
pudc_tiles.add(l["tile"])
|
||||||
|
|
||||||
print("Loading tags")
|
print("Loading tags")
|
||||||
segmk = Segmaker("design.bits")
|
segmk = Segmaker("design.bits")
|
||||||
'''
|
'''
|
||||||
|
|
@ -90,7 +85,7 @@ def main():
|
||||||
for d in design['tiles']:
|
for d in design['tiles']:
|
||||||
site = d['site']
|
site = d['site']
|
||||||
|
|
||||||
if skip_broken_tiles(d):
|
if d['tile'] in pudc_tiles:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
if site in diff_pairs:
|
if site in diff_pairs:
|
||||||
|
|
|
||||||
|
|
@ -17,3 +17,19 @@ foreach site_type { IOB33M IOB33S IDELAYCTRL} {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
close $fp
|
close $fp
|
||||||
|
|
||||||
|
set fp [open "pudc_sites.csv" "w"]
|
||||||
|
puts $fp "tile,site"
|
||||||
|
foreach tile [get_tiles *IOB33*] {
|
||||||
|
foreach site [get_sites -of_objects $tile] {
|
||||||
|
set site_type [get_property SITE_TYPE $site]
|
||||||
|
|
||||||
|
set pin [get_package_pins -of_objects $site]
|
||||||
|
set pin_func [get_property PIN_FUNC $pin]
|
||||||
|
|
||||||
|
if {[string first "PUDC_B" $pin_func] != -1} {
|
||||||
|
puts $fp "$tile,$site,$site_type"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
close $fp
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue