Skip to content

[ot] hw/opentitan: ot_clkmgr, ot_spi_host: Earlgrey 1.0.0 backwards compatability #148

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

Merged

Conversation

AlexJones0
Copy link

This PR is to a new branch intended to maintain temporary backwards compatibility with the earlgrey-1.0.0 target. This includes reverting HW changes to the QEMU model since that branch was taken (including the SPI Host changes), and replicating RTL bugs present in that version (e.g. the clkmgr bug in this PR).

This branch is intended to likely be a temporary workaround: it would be nice to have a better solution for supporting different tops in QEMU, where earlgrey-1.0.0 could just be a slightly modified top from Earlgrey master, but since we have need for this now we just manually ad this with some conditional #ifdefs.

Earlgrey 1.0.0 uses SPI Host V2, not V3, which has breaking changes to
the size and locations of the field in the SPI Host command register.
This can just be adapted by changing the field definitions; the command
length in earlgrey-1.0.0 is smaller and so the rest of the code is
backwards-compatible.

For the clkmgr, there was a known RTL bug in 1.0.0 where the jitter
enable register was not actually protected by its respective REGWEN
register. This replicates that behaviour for correct testing on the
earlgrey-1.0.0 branch.

Signed-off-by: Alex Jones <alex.jones@lowrisc.org>
@AlexJones0 AlexJones0 merged commit 5f6e84e into lowRISC:ot-earlgrey_1.0.0-9.2.0 Feb 26, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants