Lazy deregistration protocol for a split socket stack
First Claim
1. A method in a data processing system for managing memory, the method comprising:
- responsive to a data transfer request from a requester, registering a section of memory for use in a data transfer to form a section of registered memory, wherein the section of memory is pinned ensuring that every page in the memory region is resident in memory; and
responsive to the data transfer completing, deregistering the section of memory after a selected period of time, wherein another data transfer request occurring before the selected period of time is handled using the section of memory without requiring a second registration of the memory region.
1 Assignment
0 Petitions
Accused Products
Abstract
A method, computer program product, and distributed data processing system for lazy deregistration of memory regions. Specifically, the present invention is directed to memory regions that are written to and from by an Integrated Protocol Suite Offload Engine (IPSOE) in accordance with a preferred embodiment of the present invention. A mechanism is provided for lazy deregistration of memory regions once the region is no longer required for a specific data transfer being carried out by the IPSOE. Rather than deregistering a memory region after a data transfer has been carried out, the memory region remains registered for some selected period of time. After that selected period of time passes, the region is then deregistered. If a second data transfer using this memory region occurs while the memory region is still registered, the registration overhead is avoided for this second data transfer. This mechanism reduces the amount of CPU resources required for transferring data by allowing reuse of previously registered memory regions.
-
Citations
36 Claims
-
1. A method in a data processing system for managing memory, the method comprising:
-
responsive to a data transfer request from a requester, registering a section of memory for use in a data transfer to form a section of registered memory, wherein the section of memory is pinned ensuring that every page in the memory region is resident in memory; and
responsive to the data transfer completing, deregistering the section of memory after a selected period of time, wherein another data transfer request occurring before the selected period of time is handled using the section of memory without requiring a second registration of the memory region. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A method in a data processing system for managing memory, the method comprising:
-
receiving a request for a transfer of data from a consumer;
determining whether the request references a buffer;
responsive to the request referencing the buffer, determining whether the buffer is within a registered memory region for a first type of data transfer;
responsive to the buffer being within the registered memory region for the first type of transfer, transferring the data using the first type of transfer, wherein a deregistration timer used to deregister the memory region after a period of time is disabled until the transfer of data has completed;
responsive to a first portion of the buffer being inside the memory region and a second portion of the buffer being outside the registered memory region for the first type of transfer, comparing a size of the second portion to a threshold;
transferring data in the first portion of the buffer in the registered memory region using the first type of data transfer if the size of the second portion of the buffer is less than or equal to the threshold, wherein the deregistration timer is disabled; and
transferring data in the second portion of the buffer using the second type of data transfer if the size of the second portion is less than or equal to the threshold. - View Dependent Claims (10, 11, 12, 13, 14, 15, 16)
-
-
17. A data processing system for managing memory, the data processing system comprising:
-
a bus system;
a communications unit connected to the bus system;
a memory connected to the bus system, wherein the memory includes a set of instructions; and
a processing unit connected to the bus system, wherein the processing unit executes the set of instructions to register a section of memory for use in a data transfer to form a section of registered memory in which the section of registered memory is pinned ensuring that every page in the memory region is resident in memory in response to a data transfer request from a requester; and
deregister the section of memory after a selected period of time in which another data transfer request occurring before the selected period of time is handled using the section of memory without requiring a second registration of the memory region in response to the data transfer completing.
-
-
18. A data processing system for managing memory, the data processing system comprising:
-
a bus system;
a communications unit connected to the bus system;
a memory connected to the bus system, wherein the memory includes a set of instructions; and
a processing unit connected to the bus system, wherein the processing unit executes the set of instructions to receive a request for a transfer of data from a consumer;
determine whether the request references a buffer;
determine whether the buffer is within a registered memory region for a first type of data transfer in response to the request referencing the buffer;
transfer the data using the first type of transfer in which a deregistration timer used to deregister the memory region after a period of time is disabled until the transfer of data has completed in response to the buffer being within the registered memory region for the first type of transfer;
compare a size of the second portion to a threshold responsive to a first portion of the buffer being inside the memory region and a second portion of the buffer being outside the registered memory region for the first type of transfer;
transfer data in the first portion of the registered memory region using the first type of data transfer if the size of the second portion is less than or equal to the threshold in which the deregistration timer is disabled; and
transfer data in the second portion of the registered memory region using the second type of data transfer if the size of the second portion is less than or equal to the threshold.
-
-
19. A data processing system for managing memory, the data processing system comprising:
-
registering means, responsive to a data transfer request from a requester, for registering a section of memory for use in the data transfer to form a section of registered memory, wherein the section of memory is pinned ensuring consistent virtual-to-physical translations; and
deregistering means, responsive to the data transfer completing, for deregistering the section of memory after a selected period of time, wherein another data transfer request occurring before the selected period of time is handled using the section of memory without requiring a second registration of the memory region. - View Dependent Claims (20, 21, 22, 23, 24, 25, 26)
-
-
27. A data processing system for managing memory, the data processing system comprising:
-
receiving means for receiving a request for a transfer of data from a consumer;
first determining means for determining whether the request references a buffer;
second determining means, responsive to the request referencing the buffer, for determining whether the buffer is within a registered memory region for a first type of data transfer;
first transferring means, responsive to the buffer being within the registered memory region for the first type of transfer, for transferring the data using the first type of transfer, wherein a deregistration timer used to deregister the memory region after a period of time is disabled until the transfer of data has completed;
comparing means, responsive to a first portion of the buffer being inside the memory region and a second portion of the buffer being outside the registered memory region for the first type of transfer, for comparing a size of the second portion to a threshold;
second transferring means for transferring data in the first portion of the buffer in the registered memory region using the first type of data transfer if the size of the second portion of the buffer is less than or equal to the threshold, wherein the deregistration timer is disabled; and
third transferring means for transferring data in the second portion of the buffer using the second type of data transfer if the size of the second portion is less than or equal to the threshold. - View Dependent Claims (28, 29, 30, 31, 32, 33, 34)
-
-
35. A computer program product in a computer readable medium for managing memory, the computer program product comprising:
-
first instructions, responsive to a data transfer request from a requester, for registering a section of memory for use in the data transfer to form a section of registered memory, wherein the section of memory is pinned ensuring consistent virtual-to-physical translations; and
second instructions, responsive to the data transfer completing, for deregistering the section of memory after a selected period of time, wherein another data transfer request occurring before the selected period of time is handled using the section of memory without requiring a second registration of the memory region.
-
-
36. A computer program product in a computer readable medium for managing memory, the computer program product comprising:
-
first instructions for receiving a request for a transfer of data from a consumer;
second instructions for determining whether the request references a buffer;
third instructions, responsive to the request referencing the buffer, for determining whether the buffer is within a registered memory region for a first type of data transfer;
fourth instructions, responsive to the buffer being within the registered memory region for the first type of transfer, for transferring the data using the first type of transfer, wherein a deregistration timer used to deregister the memory region after a period of time is disabled until the transfer of data has completed;
fifth instructions, responsive to a first portion of the buffer being inside the memory region and a second portion of the buffer being outside the registered memory region for the first type of transfer, for comparing a size of the second portion to a threshold;
sixth instructions for transferring data in the first portion of the registered memory region using the first type of data transfer if the size of the second portion is less than or equal to the threshold, wherein the deregistration timer is disabled; and
seventh instructions for transferring data in the second portion of the registered memory region using the second type of data transfer if the size of the second portion is less than or equal to the threshold.
-
Specification