Method and apparatus for gigabit packet assignment for multithreaded packet processing
First Claim
1. A method of forwarding data, comprising:
- receiving a network packet on a first port, the network packet comprising a first portion and a second portion;
associating first control information with the first portion of the network packet, the first control information designating a relative position of the first portion with respect to one or more other portions of the network packet, the one or more other portions including the second portion;
associating second control information with the second portion of the network packet, the second control information designating a relative position of the second portion with respect to one or more other portions of the network packet, the one or more other portions including the first portion;
processing the first portion of the network packet;
processing the second portion of the network packet at least partially in parallel with processing the first portion of the network packet; and
using the first control information and the second control information to enqueue the first portion and the second portion for transmission to a second port to maintain the relative positions of the first portion and the second portion.
1 Assignment
0 Petitions
Accused Products
Abstract
A network processor that has multiple processing elements, each processing element supporting multiple simultaneous program threads with access to shared resources in an interface. Packet data is received from high-speed ports in segments and each segment is assigned to one of the program threads. Each packet may be assigned to a single program thread, two program threads, or a different program thread for segment of data in a packet. For the two program threads, one program thread can be used for header segment processing and the other program thread can be used for handling payload segment(s). Dedicated inputs for ready status and sequence numbers can provide assistance for receiving the packet data over a high speed port. The dedicated inputs are used to monitor ready flags from the high speed ports on a cycle-by-cycle basis. The sequence numbers are used by the assigned threads to maintain ordering of segments within a packet, as well as to order the writes of the complete packets to transmit queues.
-
Citations
27 Claims
-
1. A method of forwarding data, comprising:
-
receiving a network packet on a first port, the network packet comprising a first portion and a second portion;
associating first control information with the first portion of the network packet, the first control information designating a relative position of the first portion with respect to one or more other portions of the network packet, the one or more other portions including the second portion;
associating second control information with the second portion of the network packet, the second control information designating a relative position of the second portion with respect to one or more other portions of the network packet, the one or more other portions including the first portion;
processing the first portion of the network packet;
processing the second portion of the network packet at least partially in parallel with processing the first portion of the network packet; and
using the first control information and the second control information to enqueue the first portion and the second portion for transmission to a second port to maintain the relative positions of the first portion and the second portion. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
processing the first portion of the network packet to determine the second port to which the first portion and the second portion are to be transmitted.
-
-
6. The method of claim 2, wherein the second control information includes one or more second portion sequence numbers indicating the relative position of the second portion in the network packet, and wherein using the first control information and the second control information to enqueue the first portion and the second portion for transmission to a second port comprises enqueueing the first portion and the second portion based on the first portion sequence numbers and the second portion sequence numbers associating further comprises maintaining second sequence numbers.
-
7. The method of claim 1, further comprising:
controlling transfer of the first portion of the network packet from the first port to a particular receive processing program threads for processing.
-
8. The method of claim 7, wherein controlling comprises:
assigning the particular receive processing program threads to process the first portion of the network packet.
-
9. The method of claim 8, wherein controlling comprises:
directing the first portion of the network packet to the attention of the particular receive processing program thread.
-
10. The method of claim 8, wherein controlling comprises:
directing the both the first portion of the network packet and the second portion of the network packet to the attention of the particular receive processing program threads.
-
11. The method of claim 8, wherein controlling comprises:
directing the first portion of the network packet for processing by the particular receive processing program thread, and directing the second portion of the network packet for processing by a different receive processing program thread, and wherein the first portion of the network packet comprises a packet header and a portion of payload data, and wherein the second portion of the network packet comprises another portion of the payload data.
-
12. The method of claim 2, wherein the one or more first portion sequence numbers includes a start-of-packet sequence number, and further comprising:
-
maintaining a sequence number count for generating start-of-packet sequence numbers; and
incrementing the sequence number count upon associating a current count value of the sequence number count with the first portion of the network packet as the start-of-packet sequence number.
-
-
13. The method of claim 3, further comprising:
-
maintaining an enqueue sequence number count for generating enqueue sequence numbers; and
incrementing the enqueue sequence number count after determining that a the network packet is ready to be enqueued for transmission to the second port.
-
-
14. A processor for forwarding data from a first port to a second port comprises:
-
one or more microengines to execute program threads, the threads including a plurality of receive processing program threads, the threads further including a receive scheduler program thread to assign a first portion of a network packet received at the first port to a first receive processing program thread, the receive scheduler program thread further to assign a second portion of the network packet to a second receive processing program thread, the first receive processing program thread and the second receive processing program thread to process the first portion and the second portion at least partially in parallel; and
a bus interface, responsive to the one or more `microengines, the bus interface to receive the first portion and the second portion from the first port and directing the first portion and the second portion to the first and second receive processing program threads for processing and enqueueing the first portion and the second portion in the order in which they were received from the first port for transmission to the second port. - View Dependent Claims (15, 16, 17, 18, 19, 20, 21, 22, 23, 24)
-
-
25. An article comprising a computer-readable medium which stores computer-executable instructions for forwarding data, the instructions causing a one or more computers to perform operations comprising:
-
associating first control information with a first portion of a network packet received at a first port, the first control information designating a relative position of the first portion with respect to one or more other portions of the network packet, the one or more other portions including a second portion;
associating second control information with, the second control information designating a relative position of the second portion with respect to one or more other portions of the network packet, the one or more other portions including the first portion;
processing the first portion of the network packet;
processing the second portion of the network packet at least partially in parallel with processing the first portion of the network packet; and
using the first control information and the second control information to enqueue the first portion and the second portion for transmission to a second port to maintain the relative positions of the first portion and the second portion. - View Dependent Claims (26, 27)
determine the order in which the first portion and the second portion are to be enqueued based on the first portion sequence numbers and the second portion sequence numbers.
-
Specification