Method and apparatus for describing multiple packets to hardware
First Claim
1. A method of describing multiple packets to a communication apparatus with a single descriptor, the method comprising:
- receiving a header buffer comprising a header for each of N packets, wherein N>
1;
receiving a data buffer comprising a payload for each of said N packets;
in a single descriptor configured to be read by the communication apparatus, storing;
a base address of said header buffer;
a base address of said data buffer;
a checksum start offset indicating where to compute a checksum on each of said N packets;
a checksum stuff offset indicating where to store the checksum in each of said N packets; and
for each of said N packets;
a length of the payload for said packet;
a sample of the payload for said packet; and
a length of the header for said packet.
2 Assignments
0 Petitions
Accused Products
Abstract
A system and method for describing multiple packets to a communication module or device without requiring descriptors for each packet. A device driver for the communication apparatus receives a set of packet headers and a set of packet payloads from an upper layer protocol. The headers may be received in a header buffer, and the payloads may be received in a separate data buffer. Or, the packets may be received, in assembled form, in a single buffer. The device driver configures a single descriptor to describe the multiple packets to the communication apparatus. The descriptor includes base address(es) of the buffer(s) in which the headers, payloads or assembled packets are stored, and the lengths of the individual headers, payloads or assembled packets. If the buffer contents are not packed, the descriptor may also include offsets of the headers, payloads or packets.
29 Citations
17 Claims
-
1. A method of describing multiple packets to a communication apparatus with a single descriptor, the method comprising:
-
receiving a header buffer comprising a header for each of N packets, wherein N>
1;receiving a data buffer comprising a payload for each of said N packets; in a single descriptor configured to be read by the communication apparatus, storing; a base address of said header buffer; a base address of said data buffer; a checksum start offset indicating where to compute a checksum on each of said N packets; a checksum stuff offset indicating where to store the checksum in each of said N packets; and for each of said N packets; a length of the payload for said packet; a sample of the payload for said packet; and a length of the header for said packet. - View Dependent Claims (2, 3, 4, 5)
-
-
6. A computer readable medium storing instructions that, when executed by a computer, cause the computer to perform a method of describing multiple packets to a communication apparatus with a single descriptor, the method comprising:
-
receiving a header buffer comprising a header for each of N packets, wherein N>
1;receiving a data buffer comprising a payload for each of said N packets; in a single descriptor configured to be read by the communication apparatus, storing; a base address of said header buffer; a base address of said data buffer; a checksum start offset indicating where to compute a checksum on each of said N packets; a checksum stuff offset indicating where to store the checksum in each of said N packets; and for each of said N packets; a length of the payload for said packet; a sample of the payload for said packet; and a length of the header for said packet.
-
-
7. A processor-implementable method of using a single descriptor to facilitate the passing of multiple packets to a communication apparatus from a device driver, the method comprising:
-
storing multiple packets'"'"' headers contiguously within a header buffer; storing payloads of the multiple packets contiguously within a data buffer; providing said header buffer and said data buffer to the device driver for the communication apparatus; configuring the single descriptor to describe the multiple packets, wherein configuring the single descriptor comprises including in the single descriptor; a base address of said header buffer; a base address of said data buffer; for each packet in the multiple packets; a length of a header of the packet; and a length of a payload of the packet; a checksum start value configured to indicate where, in each of the multiple packets, a checksum computation is to be initiated; and a checksum stuff value configured to indicate where, in each of the multiple packets, a checksum computation is to be stored; configuring a second descriptor to reference said single descriptor, wherein said second descriptor is a traditional descriptor configured to describe a single packet; passing said single descriptor and the second descriptor to the communication apparatus; and at the communication apparatus, reading the second descriptor to access said single descriptor, and using said single descriptor to transmit the multiple packets. - View Dependent Claims (8, 9)
-
-
10. A computer readable medium storing instructions that, when executed by a computer, cause the computer to perform a method of using a single descriptor to facilitate the passing of multiple packets to a communication apparatus from a device driver, the method comprising:
-
storing multiple packets'"'"' headers contiguously within a header buffer; storing payloads of the multiple packets contiguously within a data buffer; providing said header buffer and said data buffer to the device driver for the communication apparatus; configuring the single descriptor to describe the multiple packets, wherein configuring the single descriptor comprises including in the single descriptor; a base address of said header buffer; a base address of said data buffer; for each packet in the multiple packets; a length of a header of the packet; and a length of a payload of the packet; a checksum start value configured to indicate where, in each of the multiple packets, a checksum computation is to be initiated; and a checksum stuff value configured to indicate where, in each of the multiple packets, a checksum computation is to be stored; configuring a second descriptor to reference said single descriptor, wherein said second descriptor is a traditional descriptor configured to describe a single packet; passing said single descriptor and the second descriptor to the communication apparatus; and at the communication apparatus, reading the second descriptor to access said single descriptor, and using said single descriptor to transmit the multiple packets.
-
-
11. A computer readable medium containing a data structure configured to describe multiple packets to a communication apparatus for transmitting the multiple packets, the data structure comprising:
-
a base address of a header buffer storing headers for the multiple packets; a base address of a data buffer storing payloads for the multiple packets; for each packet in the multiple packets; a length of a header of the packet; and a length of a payload of the packet; a checksum start value configured to indicate where, in each of the multiple packets, a checksum computation is to be initiated; a checksum stuff value configured to indicate where, in each of the multiple packets, a checksum computation is to be stored a first indicator configured to indicate whether the headers are stored contiguously in said header buffer; and a second indicator configured to indicate whether the payloads are stored contiguously in said data buffer.
-
-
12. An apparatus for transmitting packets, comprising:
-
a reader module configured to read a single descriptor configured to describe multiple packets, wherein said single descriptor comprises; a base address of a header buffer storing headers for the multiple packets; a base address of a data buffer storing payloads for the multiple packets; for each packet in the multiple packets; a length of a header of the packet; and a length of a payload of the packet; a first indicator configured to indicate whether the headers are stored contiguously in said header buffer; and a second indicator configured to indicate whether the payloads are stored contiguously in said data buffer; a retrieval module configured to retrieve the multiple packets, wherein said retrieval module comprises; a header retriever configured to retrieve headers for the multiple packets; and a payload retriever configured to retrieve payloads for the multiple packets; and a transmitter module configured to transmit the multiple packets.
-
-
13. A method of describing multiple packets to a communication apparatus, the method comprising:
-
for each packet, configuring a first data structure to identify; a header length; a payload length; a checksum start value configured to indicate where, in each of the multiple packets, a checksum computation is to be initiated; a checksum stuff value configured to indicate where, in each of the multiple packets, a checksum computation is to be stored; and a type of checksum; storing in the first data structure headers for the packets and payloads for a subset of the packets; configuring a first descriptor to identify the first data structure; configuring said first descriptor to identify a location of the headers and a location of the payloads within the first data structure; storing in a second data structure payloads for a subset of the packets; configuring a second descriptor to identify a location of the payloads within the second data structure; and forwarding said first descriptor and said second descriptor to the communication apparatus to facilitate transmission of the packets.
-
-
14. A computer readable medium containing data structures for facilitating transmission of multiple packets from a communication apparatus, the data structures comprising:
-
a first metadata structure configured to include; a metadata section configured to identify, for each of the multiple packets; a header length; and a payload length; and a header section configured to store headers for the multiple packets; a first descriptor configured to identify; a memory location of said first metadata structure; and a location of said header section within said first metadata structure; and a checksum start value configured to indicate where, in each of the multiple packets, a checksum computation is to be initiated; and a checksum stuff value configured to indicate where, in each of the multiple packets, a checksum computation is to be stored. - View Dependent Claims (15, 16, 17)
-
Specification