xvsec: use mutex lock instead of spin lock for Linux v6.x #217
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.
The xvsec takes about 50 seconds to replace a 30MB PR block bitstream on VCU118. When I use Linux v6.3 with an xvsec patch from #142 on my host, the host usually jams when using xvsec to replace a bitstream. IMHO, using spin lock for quite a long time will harm the host system, which makes my host stop responding.
When I use QEMU and passthrough my FPGA PCIe to the guest and use xvsec to program bitstream, although the system still works, there are some bugs printed in dmesg:
After replacing
spin_lock
withmutex_lock
, everything works well on Linux Kernel v6.3. Use my branch with other patches mentioned in #210. I can run firesim on VCU118 on Linux v6.3 with the correct XDMA and XVSEC.