Replies: 2 comments 1 reply
-
|
Hi @zjmletang, I think CQ is implemented a way it is mostly due to historical reasons. Probably copy paste from the first driver that needed it (virtio-serial, but I might be mistaken). Latest changes in CQ handing: https://github.com/virtio-win/kvm-guest-drivers-windows/pull/1353/commits
If you have propositions for different handling, let's discuss. Best regards, |
Beta Was this translation helpful? Give feedback.
1 reply
-
|
@zjmletang I agree that such separation make sense. But I suggest to wait. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi team,
I'm studying the NetKVM control queue implementation and noticed something I don't fully understand. I'd appreciate any insight from the community.
Current behavior
The control queue (CXPath) configures both:
What I observed
All control operations (
SendControlMessage) appear to use synchronous polling:m_VirtQueue.AddBuf(...);
m_VirtQueue.Kick();
// Poll for response
p = m_VirtQueue.GetBuf(&len);
for (int i = 0; i < 600000 && !p; ++i) {
NdisStallExecution(5);
p = m_VirtQueue.GetBuf(&len);
}And the DPC handler (
ParaNdis_CXDPCWorkBody) only reads from config space, not from the control queue itself.My confusion
Since control messages already poll for responses synchronously, the queue interrupt seems to trigger unnecessarily:
GetBuf()call)This creates spurious interrupts and DPC overhead. While control operations are infrequent so the performance impact is likely negligible, it still seems suboptimal.
Question
What am I missing? Is there a scenario where:
Or could this be simplified to only configure the config change interrupt, avoiding the unnecessary queue interrupts?
Thanks for any guidance!
Beta Was this translation helpful? Give feedback.
All reactions