SLI_STSN_ROUTINE(3) — Subroutines
Name
SLI_STSN_ROUTINE − Receives an SNA STSN request from the remote host application program. This verb control block is supplied by the interface and is passed to the STSN routine specified in the LUA_EXT_LIST structure referenced by the SLI_OPEN’s common.lua_extension_list_ptr parameter.
FORMAT
#include <lua_c.h>
void SLI(LUA_VERB_RECORD ∗sli_stsn_routine_vcb);
Supplied Verb Control Block Fields
common.lua_verb
An unsigned short value indicating the verb code LUA_VERB_SLI.
common.lua_verb_length
An unsigned short value indicating the length of the verb control block. The returned value is LUA_COMMON_LENGTH.
common.lua_opcode
An unsigned short value indicating the verb opcode. The returned value is LUA_OPCODE_SLI_STSN_ROUTINE.
common.lua_luname
An unsigned char 8-element array indicating the local LU name (in ASCII). If the name is fewer than 8 characters in length, the name is padded with space characters.
common.sid
An unsigned int value indicating the session ID that the interface is using to identify the local LU.
common.lua_data_length
An unsigned short value specifying the length of the STSN request in the buffer referenced by the common.lua_data_ptr parameter.
common.lua_data_ptr
An unsigned char pointer to the data buffer that contains the STSN request.
common.lua_th
The STSN’s transmission header.
common.lua_rh
The STSN’s request/response header.
Required Verb Control Block Fields
common.lua_prim_rc
An unsigned short value specifying the primary error code.
common.lua_data_length
An unsigned short value specifying the length of the STSN response in the buffer referenced by the common.lua_data_ptr parameter.
Description
The LUA interface builds this verb control block in internal memory and passes it to the extension routine. To complete the request, the extension routine should do the following:
1Overwrite the STSN request with the STSN response. This response can be positive or negative. If negative, the LUA application should overwrite the STSN request with the sense code data.
2Set the common.lua_prim_rc parameter to LUA_OK or LUA_NEGATIVE_RESPONSE.
3Set the common.lua_data_length parameter to the length of the response.
4Do not modify the common.lua_data_ptr parameter.
Note that a negative response cancels the pending SLI_OPEN verb. The SLI_OPEN verb returns with a primary return code of LUA_SESSION_FAILURE and a secondary return code of LUA_NEG_RSP_FROM_STSN_ROUTINE.
By default, if no SLI_STSN_ROUTINE extension routine is specified in the SLI_OPEN verb, the LUA interface issues a positive response.
Primary Return Codes
LUA_OK
LUA_NEGATIVE_RESPONSE