Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use synchronous global reset release on ECP5 #167

Closed
whitequark opened this issue Aug 5, 2019 · 5 comments · Fixed by #189
Closed

Use synchronous global reset release on ECP5 #167

whitequark opened this issue Aug 5, 2019 · 5 comments · Fixed by #189

Comments

@whitequark
Copy link
Contributor

It appears from Lattice documentation that what should be used is the SGSR primitive (more or less equivalent to using BUFGCE on Xilinx platforms, which we already do), but it is currently not available at all with Yosys.

@whitequark
Copy link
Contributor Author

Quoting off-channel communication with @daveshah:

There are really two GSR signals. The first one is an internal one driven by configuration logic that resets all flip flops at startup (perhaps better called PUR).
The second one is the user GSR signal which can optionally be used to reset flip flops. This is what GSR/SGSR drive.
However, right now Yosys and nextpnr tend to set GSR=DISABLED on everything so GSR/SGSR would have no effect
I've got way too much backlog to deal with this any time soon
Hmm, looks like nextpnr should already support SGSR if you use the Lattice postpnr primitive (which is how Trellis represents it) - a GSR primitive with CLK and GSR pins, and the "SYNCMODE" parameter set to "ASYNC", so it would only need a small packer rule to support SGSR itself (edited)
But as above it wouldn't do anything without GSR being enabled on flipflops etc

@whitequark
Copy link
Contributor Author

Upstream is working on this: YosysHQ/yosys#1332 YosysHQ/nextpnr#319

@whitequark
Copy link
Contributor Author

Merged upstream.

@whitequark
Copy link
Contributor Author

Needs YosysHQ/yosys#1343 upstream.

@whitequark
Copy link
Contributor Author

Merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant