SLI_SEND

This verb transfers, from the LUA application program to the communication link, user data, an SNA command, or an SNA response. SLI_SEND for an LU-LU session flow can only be issued on a previously opened session. If the SLI_OPEN initiation type is primary with SSCP access and INIT_COMPLETE status is achieved, the application program can issue SLI_SEND to transmit data on the SSCP-LU normal flow.

An LUA application can have two active SLI_SEND verbs simultaneously for each defined LUA LU. The two verbs can be for any two discrete flows.

Supplied Parameters

The application supplies the following parameters:
lua_verb
LUA_VERB_SLI

The verb-code indicator for the LUA verbs.

lua_verb_length
The length of the verb control block. This number must equal the length expected by the SLI for the SLI_SEND verb.
lua_opcode
LUA_OPCODE_SLI_SEND

The operation code for this verb.

lua_correlator
A value that an LUA application program can supply to help correlate this verb with other information that the program supplies. SLI ignores this parameter.
lua_luname
The local LU name in ASCII. If the name contains fewer than 8 characters, you must pad it with blanks. LUA examines this parameter only if lua_sid is 0. Using the lua_luname parameter on all verbs helps make debugging easier, especially when multiple LUs are configured.
lua_sid
The session ID returned by SLI_OPEN that identifies the session to be used. If this parameter is 0, the lua_luname parameter is used for identification.
lua_data_length
The length of the data being sent.
lua_data_ptr
A pointer to the application program data that is to be sent to the host application. Because this buffer is used for data and SNA commands, the contents of the buffer are usually in EBCDIC.
lua_post_handle
A 4-byte handle that is used to post the completion of asynchronous verbs.
lua_th.snf
The sequence number of the RU.
lua_rh
A 3-byte parameter that contains the SNA request/response header (RH) for the message.
lua_message_type
The type of SNA data and commands. When the SLI application program wants to send data, the application program must set this parameter. For more information about the SNA commands, refer to Systems Network Architecture Network Product Formats. The valid message types are as follows:
  • LUA_MESSAGE_TYPE_BID
  • LUA_MESSAGE_TYPE_BIS
  • LUA_MESSAGE_TYPE_CANCEL
  • LUA_MESSAGE_TYPE_CHASE
  • LUA_MESSAGE_TYPE_LU_DATA
  • LUA_MESSAGE_TYPE_LUSTAT_LU
  • LUA_MESSAGE_TYPE_LUSTAT_SSCP
  • LUA_MESSAGE_TYPE_QC
  • LUA_MESSAGE_TYPE_QEC
  • LUA_MESSAGE_TYPE_RELQ
  • LUA_MESSAGE_TYPE_RQR
  • LUA_MESSAGE_TYPE_RSP
  • LUA_MESSAGE_TYPE_RTR
  • LUA_MESSAGE_TYPE_SBI
  • LUA_MESSAGE_TYPE_SSCP_DATA
lua_flag1.sscp_exp
Specifies SSCP-expedited flow
lua_flag1.sscp_norm
Specifies SSCP-normal flow
lua_flag1.lu_exp
Specifies LU-expedited flow
lua_flag1.lu_norm
Specifies LU-normal flow

Returned Parameters

If the verb executes successfully, LUA returns the following parameters:

lua_data_length
The length of the peek data received.
lua_th
A 6-byte parameter that contains the SNA transmission header (TH) for the message.
lua_flag2.async
A flag that indicates that this verb completes asynchronously.
lua_flag2.sscp_exp
Specifies SSCP-expedited flow.
lua_flag2.sscp_norm
Specifies SSCP-normal flow.
lua_flag2.lu_exp
Specifies LU-expedited flow.
lua_flag2.lu_norm
Specifies LU-normal flow.
lua_sequence_number
The sequence number of the first-in-chain or the only-in-chain RU for the SLI_SEND verb. It is not byte-reversed.
lua_prim_rc
The primary return code, set by the verb function. For details, see LUA Verb Return Codes.
lua_sec_rc
The secondary return code, set by the verb function. For details, see LUA Verb Return Codes.

Usage Notes

SLI_SEND performs special processing based on the lua_message_type parameter, such as setting RH and TH bits and flow flags. For example, if the application sets the lua_message_type parameter to X'84' (CHASE), the SLI component automatically sets the lua_rh parameter to X'4B8000'.  Parameter Settings Based on Message Type shows the parameters that the application program should set if it is appropriate to do so, given the current program state.

Table 1. Parameter Settings Based on Message Type

Value of lua_message_type parameter
SLI_SEND parameter LU_DATA SSCP_DATA RSP BID, BIS, RTR CHASE QC QEC, RELQ, SBI, SIG RQR LUSTAT_LU LUSTAT_SSCP
lua_rh FI, DR1I, DR2I, RI, BBI, EBI, CDI, CSI, EDI RI SDI, QRI SDI, QRI, EBI, CDI SDI 0 SDI, QRI, DR1I, DR2I, RI, BBI, EBI, CDI
lua_th 0 SNF 0 0 0 0 0
lua_data_ptr Required (0 if no data) Required (0 if no data) 0 0 0 0 Required
lua_data_length Required Required (0 if no data) 0 0 0 0 Required
lua_flag1 flow flags 0 Required (set one) 0 0 0 0 0

An SLI_SEND verb transfers data from the location specified in the lua_data_ptr parameter for the length specified in the lua_data_length. The SLI chains data as needed. SLI_SEND can complete synchronously or asynchronously. When the application program returns from the call to the SLI, the lua_flag2.async flag indicates how the verb completes. When lua_flag2.async is set to ON, an IN_PROGRESS primary return code indicates that the verb was received and is in progress. A primary return code of OK indicates that the data or the command was written to the RUI. The application program receives the sequence number of the last chain element successfully sent using RUI_WRITE with synchronous return from the call to the SLI. After all chain elements are written, the application program receives the final return code and ending sequence number in the TH. These sequence numbers will differ if, for example, the SLI is sending a chain and has to wait for a pacing response from the host before the SLI_SEND operation can be completed.

When the SLI sends a response, the information required on the SLI_SEND verb depends on the type of response. For all responses, the application program must perform the following steps:
  • Set the lua_message_type parameter to LUA_MESSAGE_TYPE_RSP
  • Supply the sequence number (lua_th.snf) that corresponds to the request being responded to
  • Set the selected lua_flag1 flow flag
The rules for supplying additional parameters follow:
  • For positive responses that require only the request code, the application program must also supply the following parameters:
    • lua_rh.ri set to 0
    • lua_data_length set to 0
    The SLI refers to the supplied sequence number to fill in the request code.
  • For negative responses, the application program must also supply the following parameters:
    • lua_rh.ri set to 1
    • lua_data_ptr set to the address of an SNA sense code
    • lua_data_length set to the length of the SNA sense code (4 bytes).
    The SLI fills in the request code following the sense data.