Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Background
To run more complex applications like the Linux kernel, we need more memory. Therefore, we plan to support PSRAM (Pseudo-Static Random Access Memory).
Progress
By analyzing the code in bouffalo_sdk, we have a basic understanding of the PSRAM initialization process and ported it to Rust, completing the psram-demo. This program initializes PSRAM by directly reading and writing memory, runs a simple test and outputs the result through the serial port. We flashed it into the sipeed M1s DOCK board, and it ran successfully. However, the program has some issues, including a 0.3%~1% error rate in memory read/write operations and unexpected read/write latency (likely due to clock configuration). We will continue to improve it.
TODO