主权项 |
1. A computer implemented method for processing packets from a receive queue of a remote direct memory access device in a data processing system, the computer implemented method comprising:
determining, by the data processing system using a remote direct memory access controller software program located in a user space, whether packets are saved in a pre-fetched queue located within the remote direct memory access controller software program that stores an excess number of packets above a predetermined number of packets called for by an application of the data processing system in a previous packet retrieval cycle, wherein the remote direct memory access controller software program located in the user space monitors and controls remote direct memory access operations associated with the remote direct memory access device; responsive to the data processing system determining that packets are not saved in the pre-fetched queue located within the remote direct memory access controller software program that stores the excess number of packets above the predetermined number of packets called for by the application in the previous packet retrieval cycle, determining, by the data processing system using the remote direct memory access controller software program, a current number of packets within the receive queue of the remote direct memory access device ready to be retrieved; responsive to the data processing system determining the current number of packets within the receive queue of the remote direct memory access device ready to be retrieved, determining, by the data processing system using the remote direct memory access controller software program, whether the current number of packets within the receive queue of the remote direct memory access device ready to be retrieved is greater than a predetermined number of packets called for by the application of the data processing system; responsive to the data processing system determining that the current number of packets within the receive queue of the remote direct memory access device ready to be retrieved is greater than the predetermined number of packets called for by the application, saving, by the data processing system using the remote direct memory access controller software program, the excess number of packets above the predetermined number of packets called for by the application in the pre-fetched queue located within the remote direct memory access controller software program for a subsequent packet retrieval cycle; sending, by the data processing system using the remote direct memory access controller software program, an indication to the application of the excess number of packets saved in the pre-fetched queue located within the remote direct memory access controller software program for the subsequent packet retrieval cycle; and transferring, by the data processing system using the remote direct memory access controller software program, the predetermined number of packets called for by the application to the application from the receive queue of the remote direct memory access device. |