Synchronization optimized queuing system
AssigneeInternational Business Machines Corporation
InventorsLakshminarayana Arimilli, Claude Basso, Piyush Chaudhary, Bernard C. Drerup, Jody B. Joyner, Jan-Bernd Themann, Christoph Raisch, Colin B. Verrilli
Life of this patent
Estimating the term…
Abstract
A synchronization optimized queuing method and device to minimize software/hardware interaction in network interface hardware during an end-of-initiative process, including network adapter queue implementations for network interface hardware for optimized communication in a computer system. An end-of-initiative procedure to ensure that the network interface hardware has received an interrupt enable and to recheck the interrupt queue is unnecessary in the present invention.
Claims15
An end-of-initiative method for data communication between a device driver running on a processor in a computer system, and a network adaptor, the method comprising:
- initializing (1) a data entry threshold count value ET which is maintained in the network adapter and represents a threshold count for a plurality of data entries to be written by the network adapter to the device driver, (2) a data entry written value W which is maintained in the network adaptor and represents a current count of the plurality of data entries which have been written by the network adapter to the device driver, and (3) a variable count value X which is maintained by the device driver and represents a count associated with the plurality of data entries processed by the device driver;
- processing data entries by the device driver from a communication memory which is communicatively coupled to the network adaptor and the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory, until a final data entry of the plurality of data entries is processed from the communication memory, such that the variable count value X has advanced to a count associated with the final data entry, and such that the processing of additional data entries from the communication memory by the device driver pauses;
- in response to the pausing of the processing of additional data entries from the communication memory by the device driver, providing the network adaptor with interrupt information from the device driver to be used by the network adapter to control the interrupt generated by the network adaptor to the device driver, such that the interrupt information includes a current value of X, and the value of ET is set equal to the current value of X, wherein the interrupt information is provided by the device driver to the network adaptor via a single memory-mapped input/output (MMIO) write to an address of a single register disposed in the network adaptor which has stored therein the data entry threshold count value ET and the data entry written value W;
- writing data entries of the plurality of data entries, by the network adaptor, to the communication memory, such that the data entry written value W is incremented by a count of one for each data entry of the plurality of data entries which is written to the communication memory by the network adaptor;
- comparing the value of ET with the value of W to determine whether a threshold condition exists;
- automatically generating an interrupt by the network adaptor to the device driver, in response to a determination that the threshold condition exists, to signal the device driver that the plurality of data entries written by the network adaptor to the communication memory are available in the communication memory to be processed by the device driver;
- disabling further interrupts by the network adaptor to the device driver until the device driver requests additional data entries to be processed by the device driver;
- and
- in response to the interrupt being generated by the network adaptor, unpausing the processing of additional data entries from the communication memory by the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory.
A data communication system, comprising:
- a network adaptor;
- a device driver running in a processor of the data communication system;
- a communication memory communicatively coupled to the network adaptor and the device driver:
- and
- an end-of initiative logic within the network adapter and the device driver that performs an end-of-initiative process for communication of packet data and control information between the network adaptor and the device driver, via the communication memory, wherein said logic comprises logic that:
- initializes (1) a data entry threshold count value ET which is maintained in the network adapter and represents a threshold count for a plurality of data entries to be written by the network adapter to the device driver, (2) a data entry written value W which is maintained in the network adaptor and represents a current count of the plurality of data entries which have been written by the network adapter to the device driver, and (3) a variable count value X which is maintained by the device driver and represents a count associated with the plurality of data entries processed by the device driver,
- processes data entries by the device driver from a communication memory which is communicatively coupled to the network adaptor and the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory, until a final data entry of the plurality of data entries is processed from the communication memory, such that the variable count value X has advanced to a count associated with the final data entry, and such that the processing of additional data entries from the communication memory by the device driver pauses;
- in response to the pausing of the processing of additional data entries from the communication memory by the device driver, provides the network adaptor with interrupt information from the device driver to be used by the network adapter to control the interrupt generated by the network adaptor to the device driver, such that the interrupt information includes a current value of X, and the value of ET is set equal to the current value of X, wherein the interrupt information is provided by the device driver to the network adaptor via a single memory-mapped input/output (MMIO) write to an address of a single register disposed in the network adaptor which has stored therein the data entry threshold count value ET and the data entry written value W;
- causes the network adapter to write data entries of the plurality of data entries to the communication memory, such that the data entry written value W is incremented by a count of one for each data entry of the plurality of data entries which is written to the communication memory by the network adaptor;
- compares the value of ET with the value of W to determine whether a threshold condition exists;
- enables the network adapter to automatically generate an interrupt by the network adaptor to the device driver, in response to a determination that the threshold condition exists, to signal the device driver that the plurality of data entries written by the network adaptor to the communication memory are available in the communication memory to be processed by the device driver;
- and
- disables further interrupts by the network adaptor to the device driver until the device driver requests additional data entries to be processed by the device driver;
- and in response to the interrupt being generated by the network adaptor, unpausing the processing of additional data entries from the communication memory by the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory.
A computer program product stored on a non-transitory computer- storage medium which includes computer readable instructions that when executed on a computer perform an end-of-initiative process which comprises:
- initializing a data entry threshold count value ET which is maintained in the network adapter and represents a threshold count for a plurality of data entries to be written by the network adapter to the device driver, a data entry written value W which is maintained in the network adaptor and represents a current count of the plurality of data entries which have been written by the network adapter to the device driver, and a variable count value X which is maintained by the device driver and represents a count associated with the plurality of data entries processed by the device driver, such that the values of ET, W and X are a same value;
- processing data entries by the device driver from a communication memory which is communicatively coupled to the network adaptor and the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory, until a final data entry of the plurality of data entries is processed from the communication memory, such that the variable count value X has advanced to a count associated with the final data entry, and such that the processing of additional data entries from the communication memory by the device driver pauses;
- in response to the pausing of the processing of additional data entries from the communication memory by the device driver, providing the network adaptor with interrupt information from the device driver to be used by the network adapter to control the interrupt generated by the network adaptor to the device driver, such that the interrupt information includes a current value of X, and the value of ET is set equal to the current value of X, wherein the interrupt information is provided by the device driver to the network adaptor via a single memory-mapped input/output (MMIO) write to an address of a single register disposed in the network adaptor which has stored therein the data entry threshold count value ET and the data entry written value W;
- writing data entries of the plurality of data entries, by the network adaptor, to the communication memory, such that the data entry written value W is incremented by a count of one for each data entry of the plurality of data entries which is written to the communication memory by the network adaptor;
- comparing the value of ET with the value of W to determine whether a threshold condition exists;
- automatically generating an interrupt by the network adaptor to the device driver, in response to a determination that the threshold condition exists, to signal the device driver that the plurality of data entries written by the network adaptor to the communication memory are available in the communication memory to be processed by the device driver;
- disabling further interrupts by the network adaptor to the device driver until the device driver requests additional data entries to be processed by the device driver;
- and in response to the interrupt being generated by the network adaptor, unpausing the processing of additional data entries from the communication memory by the device driver, such that the variable count value X is incremented by a count of one for each data entry of the plurality of data entries which is processed by the device driver from the communication memory.
Dependencies are inferred from the claim text.