pradeep singh rautela
2007-Sep-28 10:24 UTC
[Xen-devel] [Xen-3.1.0] Network transmission loss between dom0 and domU
Hi All, I am facing a problem related to network transmission between dom0 and PV domU in Xen 3.1.0. here is a brief summary of what i am doing - - I want to send some custom header from domU to network driver in dom0.As the frontend and backend communicate using shared ring buffers which employ use of grant table mechanism,I can only put that custom header along with the data in the skb''s data. - I need this custom header in network driver in dom0 and thus get some information appended to it in the domU. here is brief summary of how i am doing this - - i have allocated extra space for my custom header in the alloc_skb at the tcp layer itself. After the data is copied to the skb i skb_push and then memcpy the header to the data part of the skb. - This skb goes through the netfront driver in domU and is treated like any other skb as it does not care about the data part[not even the checksum] and sends it to the netback driver in dom0. - Once this is received by the dom0 it is forwarded to the bridge xenbrX in the dom0. - bridge sends it to the correct network driver in dom0. - In driver i am doing a skb_pull and get[copy actually] the custom header out from the skb->data part. - Once i have done this, i switch to another mode of operation for the NIC depending on the custom header value i have. - At the reception side the procedure is exactly reverse of the above mentioned insanity. :-/. here is what happens with a simple client and server program running in userspace - - One way transmission on data from either client to server is working without any hiccups. Problem and its cause - - If i modify the client server program for simultaneous transmission. Client sends data, server sends data again as part of the program. - Running this program the server and client they both hang indefinitely after random packets are transmitted between domU on machine one and other client machine. - After putting a lots of printks i came to this conclusion. 1. netif_int in netfront is not getting invoked just before the domU seems to be hanged. As a result the receive socket queue sleeps indefinitely waiting for someone to come and wake it up. 2. Further inquiry helped me to find out that the EVTCHNOP_send event is not getting transmitted to domU at all.The event is a valid one indeed[i.e it is not zero]. It seems like either it is lost in the Xen hypervisor or domU is ignoring the event sent through eventchannel through hypervisor. So, what are the cases when domU can not respond to the event passed to it by the hypervisor?As i can see at it, either interrupts are disabled in the domU at that unfateful moment or it is not getting delivered at all. Can someone point me what i am doing wrong? I bet i am messing something somewhere. Any help? sorry for a tedious mail. Couldn''t explain it better. Thanks -- pradeep singh rautela "question = ( to ) ? be : ! be;" -- Wm. Shakespeare _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel