Patent ID: 8400924

Claim:
An apparatus comprising: a receiver comprising a credit management unit configured to manage flow control credits for an interface to which the receiver is coupled during use, wherein each packet received on the interface comprises a header and optionally data, and wherein the header is measured in terms of one or more header credits for flow control on the interface, and wherein data is measured in terms of one or more data credits for flow control on the interface, each data credit representing a fixed number of data bytes; and a buffer memory coupled to the receiver and configured to store packet headers and packet data corresponding to packets that are received on the interface by the receiver; and wherein the credit management unit is configured to advertise a first initial number of header credits and a second initial number of data credits during initialization of the interface, and wherein the credit management unit is configured to dynamically adjust a first allocated number of header credits and a second allocated number of data credits from the first initial number and the second initial number, respectively, based on a size of packet data received on the interface, wherein the credit management unit is configured to dynamically adjust the first allocated number and the second allocated number by determining that a first one of the header credits and data credits are ready to be freed but instead freeing an opposite one of the header credits and data credits.