-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
SPI Engine: SDO data prefetch #1501
base: main
Are you sure you want to change the base?
Conversation
188d0a7
to
1840af0
Compare
1840af0
to
e6937d4
Compare
Switched SDO source control to software (memory-mapped register). SDO data can now be clocked in independently from the offload trigger. This allows lower latencies for executing transfers, since the data can be obtained from the DMA before the trigger. It also better separates the command path from the data path Signed-off-by: Laez Barbosa <[email protected]>
e6937d4
to
4f982aa
Compare
[31:0] 0x00000000 | ||
OFFLOAD0_SDO_SRC_SEL | ||
RW | ||
Selects data source for SDO offload. 0=SDO memory, 1=SDO stream (DMA). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Selects data source for SDO offload. 0=Memory Mapped, 1=Streaming.
@@ -447,6 +447,21 @@ ENDFIELD | |||
############################################################################################ | |||
############################################################################################ | |||
|
|||
REG | |||
0x43 | |||
OFFLOAD0_SDO_SRC_SEL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I already submitted patches to upstream Linux assuming that this was a compile time option instead of a runtime option. So if we are going to change this, I need to retract the changes in that patch.
However, having the setting globally like this instead of per transfer isn't as useful since it would limit a SPI offload to either using one or the other. We could never have a SPI message that does both types of TX transfers. So I would be OK if we just left this as a compile time option for now.
PR Description
Allows spi_engine_execution get sdo data independently of the instruction command. This reduces the trigger to transfer latency, and opens the door to further pipelining this path or reducing latency even more.
Also changes SDO source to be software-controlled, through a new register.
(this PR should be merged after #1499)
PR Type
PR Checklist