Claims
- 1. A method of serializing received packets of data accompanying commands from a data source, the method performed by a data processing system including a plurality of channel interfaces, each channel interface including a buffer and interface controller, with the data processing system further including a main packet data buffer, control data structures in a main memory, and a main processor, with the channel interfaces and main processor coupled by a locking system including request and grant signals, said method comprising the steps of:
- receiving a command at a first channel interface;
- utilizing said locking system to secure a lock by said first channel interface to prevent other channel interfaces from accessing ownership fields in said control data structures;
- querying a .sub.-- BUSY status element in a control data structure;
- if said .sub.-- BUSY status element is set:
- releasing the lock; and
- rejecting the command received at said first channel interface;
- if said .sub.-- BUSY status element is not set:
- setting the .sub.-- BUSY status element;
- releasing the lock to allow other channel interfaces to access other control data fields;
- accessing a PacketID field in the control data structure to obtain a packet ID number;
- assigning the packet ID number to an incoming packet associated with the command received;
- executing the command received while holding the .sub.-- BUSY status element set and storing a packet associated with the command in the buffer of said first channel interface;
- subsequent to executing the command, incrementing the packetID in the PacketID field of the control data structure and clearing the .sub.-- BUSY status element; and
- returning ending status to the data source.
- 2. The method of claim 1 further comprising the steps of:
- subsequent to executing the command, if said command is a write command:
- querying a .sub.-- DATA.sub.-- BUFFERED status element in said control data structure to determine whether the write command received is the first of any sequence of writes;
- if said .sub.-- DATA.sub.-- BUFFERED status element is not set,
- initializing the packet ID in a busPacket field of said data structure to equal a packet ID number assigned to the packet stored in the buffer of the first channel interface and setting the .sub.-- DATA.sub.-- BUFFERED status element;
- if said .sub.-- DATA.sub.-- BUFFERED status element is set:
- writing the packet stored in the buffer of the first channel interface to the main packet buffer when the packet ID number assigned to the packet has a same value as the packet ID in the busPacket field; and
- incrementing the value of the packet ID in the busPacket field.
- 3. A method of serializing received packets of data accompanying commands from a data source, with the packets included among those to be written to a particular virtual tape volume, the method performed by a data processing system including a plurality of channel interfaces, each channel interface including a buffer and interface controller, said system further including a main packet data buffer, control data structures stored in a main memory, and a main processor, and said control data structures each having a busPacket status element having a packet ID value, said method comprising the steps of:
- setting the packet ID value of said buspacket status element equal to a packet ID value of a packet associated with a first write command in a sequence of write commands for writing packets, with the packets associated with said series of write commands having sequential packetID values;
- for each write command in the sequence, transferring a packet from a channel interface buffer to the main packet buffer when the packet ID of the packet to be transferred is equal to the packet ID value of the busPacket status element;
- for each write command in the sequence, incrementing the value of said packet ID value in the busPacket status element subsequent to transferring the packet to the main packet buffer;
- for a synchronize command, executing said synchronize command to transfer packets from the main packet buffer to non-volatile storage when the packetID value at the time the synchronize command arrives is equal to the packet ID value of said buspacket status element to assure that all packets held in the channel interface buffers are stored in said main packet buffer prior to synchronization.
CROSS-REFERENCE TO RELATED APPLICATIONS
The present invention claims the benefit of Provisional Patent Application No. 60/049,928, filed Jun. 18, 1997 entitled "DATA SERIALIZATION", which is incorporated herein by reference for all purposes.
US Referenced Citations (9)