IP Library Granted Patent US 7,512,684
Granted Patent B2
US 7,512,684 · App. 10/957,145 · Granted Mar 31, 2009

Flow based packet processing

Assignee: Intel Corporation
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 7,512,684
App. No.
10/957,145
Granted
Mar 31, 2009
Kind
B2
Abstract

In general, in one aspect, the disclosure describes a method that includes accessing a packet, determining a flow associated with the packet, and determining, based at least in part on the packet, whether to remove the flow from a list of flows to handle using page-flipping.

Claims (73)

1. A method, comprising:

accessing an Internet Protocol (IP) datagram encapsulating a Transmission Control Protocol (TCP) segment (TCP/IP packet);

determining a TCP/IP flow associated with the received TCP/IP packet;

based on the TCP/IP flow, determining whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow;

if it is determined to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the TCP/IP flow, causing placement of data of the received TCP/IP packet into the page of memory assigned to the flow to subsequently be flipped into a host application's address space; and

if it is determined to not cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the flow, causing placement of data of the received TCP/IP packet in the host application's address space without page flipping of a page of memory assigned to the TCP/IP flow;

wherein data of at least a first on-going TCP/IP flow is placed into the host application's address space using page-flipping of a page of memory assigned to the first on-going TCP/IP flow and data of at least a second on-going TCP/IP flow is placed into the host application's address space without page-flipping of a page of memory assigned to the second on-going TCP/IP flow.

2. The method of claim 1 , further comprising

determining, based at least in part on the received TCP/IP packet, whether to remove the TCP/IP flow from a list of flows to handle using page-flipping; and

wherein the determining whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow comprises determining based on whether or not the TCP/IP flow is in the list of flows to handle using page-flipping.

3. The method of claim 1 , further comprising altering a mapping of virtual addresses to physical addresses after packet data of multiple TCP/IP packets of the TCP/IP flow have been written to the page allocated to the TCP/IP flow.

4. The method of claim 2 , wherein the determining whether to remove the flow from the list of flows comprises determining whether the Transmission Control Protocol (TCP) segment encapsulated by the IP datagram was received out-of-order.

5. The method of claim 2 , wherein the determining whether to remove the TCP/IP flow from the list of flows comprises determining whether a size of the TCP/IP packet falls below a threshold size.

6. The method of claim 2 , wherein the determining whether to remove the TCP/IP flow from the list of flows comprises determining whether the TCP/IP packet comprises a Transmission Control Protocol (TCP) FIN or RST segment.

7. The method of claim 2 , wherein the determining whether to remove the TCP/IP flow from the list of flows comprises determining whether the received TCP/IP packet comprises an Internet Protocol fragment.

8. The method of claim 2 , further comprising removing the TCP/IP flow from the list of flows based on a period of time exceeding a threshold, the period of time comprising at least one selected from the following group: (1) a period of time since a packet was last received for the flow; and (2) a period of time without advancing a receive window for the flow.

9. The method of claim 2 , further comprising removing the TCP/IP flow from the list of flows based on a transmission of a Transmission Control Protocol (TCP) FIN or RST segment form the flow.

10. The method of claim 2 , further comprising removing the TCP/IP flow from the list of flows based on a reduction in a Transmission Control Protocol (TCP) window for the flow.

11. The method of claim 1 , further comprising:

maintaining a list of flows to not handle using page flipping; and

wherein the determining whether to place data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow comprises determining based on whether or not the TCP/IP flow is in the list of flows to not handle using page-flipping.

12. A network interface controller, the controller comprising:

at least one interface to a communications medium;

circuitry to:

determine a TCP/IP flow associated with a TCP/IP packet received via the communications medium; and

based on the TCP/IP flow, determine whether to cause Placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the flow;

if it is determined to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the TCP/IP flow, causing placement data of the received TCP/IP packet into the page of memory assigned to the flow to subsequently be flipped into a host application's address space; and

if it is determined to not cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the flow, causing placement of data of the received TCP/IP packet in the host application's address space without page flipping of a page of memory assigned to the TCP/IP flow;

wherein data of at least a first on-going TCP/IP flow is placed into the host application's address space using page-flipping of a page of memory assigned to the first on-going TCP/IP flow and data of at least a second on-going TCP/IP flow is placed into the host application's address space without page-flipping of a page of memory assigned to the second on-going TCP/IP flow.

13. The controller of claim 12 , wherein the circuitry comprises circuitry to:

determine, based at least in part on the received TCP/IP packet, whether to remove the TCP/IP flow from a list of flows to handle using page-flipping;

wherein the circuitry to determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow comprises circuitry to determine based on whether or not the TCP/IP flow is in the list of flows to handle using page-flipping.

14. The controller of claim 13 , wherein the circuitry to determine whether to remove the TCP/IP flow from the list of flows comprises circuitry to determine whether a Transmission Control Protocol (TCP) segment of the TCP/IP packet was received out-of-order.

15. The controller of claim 13 , wherein the circuitry to determine whether to remove the flow from the list of flows comprises circuitry to determine whether a size of the TCP/IP packet falls below a threshold size.

16. The controller of claim 13 , wherein the circuitry to determine whether to remove the TCP/IP flow from the list of flows comprises circuitry to determine whether the received TCP/IP packet comprises a Transmission Control Protocol (TCP) FIN or RST segment.

17. The controller of claim 13 , wherein the circuitry to determine whether to remove the TCP/IP flow from the list of flows comprises to determine whether the received TCP/IP packet comprises an Internet Protocol fragment.

18. An article of manufacture, comprising executable instructions to:

determine a TCP/IP flow associated with a TCP/IP packet; and

based on the TCP/IP flow, determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the flow;

if it is determined to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the TCP/IP flow, causing placement data of the received TCP/IP packet into the page of memory assigned to the flow to subsequently be flipped into a host application's address space; and

if it is determined to not cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the flow, causing placement of data of the received TCP/IP packet in the host application's address space without page flipping of a page of memory assigned to the TCP/IP flow;

wherein data of at least a first on-going TCP/IP flow is placed into the host application's address space using page-flipping of a page of memory assigned to the first on-going TCP/IP flow and data of at least a second on-going TCP/IP flow is placed into the host application's address space without page-flipping of a page of memory assigned to the second on-going TCP/IP flow.

19. The article of claim 18 ,

determine, based at least in part on the received TCP/IP packet, whether to remove the TCP/IP flow from a list of flows to handle using page-flipping;

wherein the instructions to determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow comprise instructions to determine based on whether or not the TCP/IP flow is in the list of flows to handle using page-flipping.

20. The article of claim 19 , wherein the instructions to determine whether to remove the TCP/IP flow from the list of flows comprise instructions to determine whether a Transmission Control Protocol (TCP) segment of the TCP/IP packet was received out-of-order.

21. The article of claim 19 , wherein the instructions to determine whether to remove the flow from the list of flows comprise instructions to determine whether a size of the TCP/IP packet falls below a threshold size.

22. The article of claim 19 , wherein the instructions to determine whether to remove the TCP/IP flow from the list of flows comprise instructions to determine whether the TCP/IP packet comprises a Transmission Control Protocol (TCP) FIN or RST segment.

23. The article of claim 19 , wherein the instructions to determine whether to remove the TCP/IP flow from the list of flows comprise instructions to determine whether the received TCP/IP packet comprises an internet Protocol fragment.

24. The article of claim 19 , further comprising instructions to remove the TCP/IP flow from the list of flows based on a period of time exceeding a threshold, the period of time comprising at least one selected from the following group: (1) a period of time since a TCP/IP packet was last received for the flow; and (2) a period of time without advancing a receive window for the flow.

25. The article of claim 19 , further comprising instructions to remove the TCP/IP flow from the list of flows based on a transmission of a Transmission Control Protocol (TCP) FIN or RST segment from the flow.

26. The article of claim 19 , further comprising removing the TCP/IP flow from the list of flows based on a reduction in a Transmission Control Protocol (TCP) window for the TCP/IP flow.

27. The article of claim 18 , further comprising:

maintaining a list of flows to not handle using page flipping;

wherein the circuitry to determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow, comprises circuitry to determine based on whether or not the TCP/IP flow is in the list of flows to not handle using page-flipping.

28. A system, comprising:

at least one processor;

at least one randomly accessible memory communicatively coupled to the processor; and

circuitry to:

access a TCP/IP packet;

determine a TCP/IP flow associated with the TCP/IP packet, wherein the TCP/IP flow comprises a TCP/IP flow identified by, at least, the packet's Internet Protocol (IP) source address, P destination address, source port, and destination port;

based on the TCP/IP flow, determine whether to cause placement of data from the TCP/IP packet into a host applications address space using a page flipping operation of a page of memory allocated to the flow;

if it is determined to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page allocated to the TCP/IP flow, cause placement of data of the received TCP/IP packet into the page of memory assigned to the flow to subsequently be flipped into a host application's address space; and

if it is determined to not cause placement of data from the TCP/IP packet into a host applications address space using a page flipping operation of a page allocated to the flow, cause placement data of the received TCP/IP packet in the host application's address space without page flipping of a page of memory assigned to the TCP/IP flow;

wherein data of at least a first on-going TCP/IP flow is placed into the host application's address space using page-flipping of a page of memory assigned to the first on-going TCP/IP flow and data of at least a second on-going TCP/IP flow is placed into the host application's address space without page-flipping of a page of memory assigned to the second on-going TCP/IP flow;

determine, based, at least in part, on the TCP/IP packet, whether to remove the flow from a list of flows to handle using page-flipping, wherein the determination comprises at least one selected from the following group:

(a) determining whether a Transmission Control Protocol (TCP) segment was received out-of-order;

(b) determining whether a size of the TCP/IP packet falls below a threshold size; and

(c) determining whether the TCP/IP packet comprises an Internet Protocol fragment;

wherein the circuitry to determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow comprises circuitry to determine based on whether or not the TCP/IP flow is in a list of flows to handle using page-flipping.

29. The system of claim 28 ,

wherein the circuitry comprises circuitry to maintain a list of flows to not handle using page flipping; and

wherein the circuitry to determine whether to cause placement of data from the TCP/IP packet into a host application's address space using a page flipping operation of a page of memory allocated to the TCP/IP flow, comprises circuitry to determine based on whether or not the TCP/IP flow is in the list of flows to not handle using page-flipping.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 11, 2005
From: RONCIAK, JOHN; LEECH, CHRISTOPHER; DEUSKAR, PRAFULLA; BRANDEBURG, JESSE; CONNOR, PATRICK
To: INTEL CORPORATION
Reel/Frame 016148/0153 →
Continuity (1)
Related Publication 20060067228A1 · Mar 30, 2006