A method, apparatus and computer program product are provided for
implementing virtual packet storage via packet work area (PWA) in a
network processor system. A mapping area including a packet work area and
a corresponding set of packet segment registers (PSRs) are provided. A
PSR is loaded with a Packet ID (PID) and a packet translation unit maps
the packet data into the corresponding PWA. The PWA address defining an
offset into the packet is translated into a physical address. The packet
translation unit redirects loads and stores of the PWA into the correct
data buffer or buffers in system memory. Packets include one or more data
buffers that are chained together, using a buffer descriptor providing
the packet physical address. The buffer descriptor points to a data
buffer for the packet and to a next buffer descriptor.