diff options
author | David Shah <dave@ds0.me> | 2020-07-13 21:11:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-13 21:11:16 +0100 |
commit | 44007eab6f6a7f20c257bb109bbc8f66a5fde12d (patch) | |
tree | 7e01578ce47adabfb7d7de657cb136dd1542e575 /ecp5/lpf.cc | |
parent | 5f241f6baafd8e2e63f6058116d391707d410af0 (diff) | |
parent | 467d26d9e698d49c7fd723005b26e454ddcc8998 (diff) | |
download | nextpnr-44007eab6f6a7f20c257bb109bbc8f66a5fde12d.tar.gz nextpnr-44007eab6f6a7f20c257bb109bbc8f66a5fde12d.tar.bz2 nextpnr-44007eab6f6a7f20c257bb109bbc8f66a5fde12d.zip |
Merge pull request #473 from YosysHQ/dave/lpf-param-check
ecp5: Add a warning for unknown LPF IOBUF attrs
Diffstat (limited to 'ecp5/lpf.cc')
-rw-r--r-- | ecp5/lpf.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ecp5/lpf.cc b/ecp5/lpf.cc index 18c81237..8b972380 100644 --- a/ecp5/lpf.cc +++ b/ecp5/lpf.cc @@ -31,6 +31,11 @@ static const std::unordered_set<std::string> sysconfig_keys = { "COMPRESS_CONFIG", "CONFIG_MODE", "INBUF", }; +static const std::unordered_set<std::string> iobuf_keys = { + "IO_TYPE", "BANK", "BANK_VCC", "VREF", "PULLMODE", "DRIVE", "SLEWRATE", + "CLAMP", "OPENDRAIN", "DIFFRESISTOR", "DIFFDRIVE", "HYSTERESIS", "TERMINATION", +}; + bool Arch::applyLPF(std::string filename, std::istream &in) { auto isempty = [](const std::string &str) { @@ -145,6 +150,9 @@ bool Arch::applyLPF(std::string filename, std::istream &in) "expected syntax 'IOBUF PORT <port name> <attr>=<value>...' (on line %d)\n", lineno); std::string key = setting.substr(0, eqpos), value = setting.substr(eqpos + 1); + if (!iobuf_keys.count(key)) + log_warning("IOBUF '%s' attribute '%s' is not recognised (on line %d)\n", + cell.c_str(), key.c_str(), lineno); fnd_cell->second->attrs[id(key)] = value; } } |