SEND processing using the HPDT interface

The following process explains how an application uses the HPDT interface to send data as shown in Figure 1.

  1. The application registers itself as a user of a CSM pool of a specific size and type by issuing the IVTCSM REQUEST=CREATE_POOL macroinstruction.
  2. The application obtains buffers from where the data will be sent using the IVTCSM REQUEST=GET_BUFFER macroinstruction. The BUFLIST parameter is used to indicate the address where CSM will build a list of buffer entries. Each buffer entry is mapped by the IVTBUFL DSECT, which is 28 bytes long.
  3. The application loads the data into the buffers. Using the CSM buffer list entries, the application builds an extended buffer list (48 bytes long). Each extended buffer list entry is mapped by the ISTBLXEN DSECT.
  4. The application invokes VTAM® to send the data by specifying OPTCD=XBUFLST on one of the following APPCCMD macroinstructions:
    • APPCCMD CONTROL=SEND,QUALIFY=DATA|DATACON|DATAFLU
    • APPCCMD CONTROL=DEALLOC,QUALIFY=DATACON|DATAFLU
    • APPCCMD CONTROL=PREPRCV,QUALIFY=DATACON|DATAFLU
    • APPCCMD CONTROL=SENDRCV,QUALIFY=DATAFLU
  5. VTAM accepts data in CSM buffers from the application. VTAM issues the IVTCSM REQUEST=CHANGE_OWNER macroinstruction to accept responsibility for returning the buffers.
  6. After the send is posted, the application examines the RPLXSRV field in the RPL to determine if VTAM accepted all of the buffers supplied by the application. The application is responsible for freeing any buffers that are not accepted by VTAM.
  7. VTAM performs the DLC I/O directly from the application-supplied CSM buffers.
  8. After VTAM has completed the transmission of the data, VTAM returns all storage to CSM. If the application has not previously requested the return of the buffers, CSM returns the storage directly to the CSM storage pools where they are available for reuse by other CSM requesters. If the application has previously requested the return of the buffers (using the FREERTN parameter on the GET_BUFFER request), CSM returns the storage to the application by scheduling an application exit routine.
  9. The application removes its registration as a user of the buffer pool at application termination using the IVTCSM REQUEST=DELETE_POOL macroinstruction.
Figure 1. SEND processing using CSM buffers
Diagram that explains how an application uses the CSM buffers to send data.
Note that CSM data must not be accessed by the application after the APPCCMD API is crossed until either:
  • The application's buffer return exit is scheduled with CSM buffers.

    This exit is specified when the CSM macroinstruction is issued to allocate CSM storage (IVTCSM REQUEST=GET_BUFFER). For more information, refer to z/OS Communications Server: CSM Guide

  • Certain error conditions result in the send being unsuccessful.

    In these error cases, VTAM may not have accepted responsibility for the CSM storage. For these situations, the application must not handle the CSM storage until the APPCCMD function is completed.