Queries the status of an open X.25 session.
Note: This call only succeeds on SVCs and PVCs.
The X25_QUERY_SESSION x25sioctl operation supplies the information for a session in the user data area. The packet size, window size, and throughput class values are not available until the session is completely established. To query the static configuration, use the CIO_QUERY operation.
For the X25_QUERY_SESSION operation the arg parameter points to the x25_query_session_data structure. Within this structure, the session to be queried is identified either by a nonzero session ID or a nonzero logical channel number. If both the session_id and logical_channel fields are nonzero, the session_id field is used.
The fields in the x25_query_session_data structure are set on return. All the X.25 facilities specified by the structure's field are encoded as in the ISO 8208 definition. The x25_query_session_data structure contains the following fields:
netid | Identifies the user-defined correlator set by the CIO_START operation. |
session_name | Identifies the user-defined name set by the CIO_START operation. |
session_id | Identifies the device handler correlator returned from the CIO_START operation. |
local_busy | Contains a value of 1 if the session is in Local Busy mode, or a 0, if not. |
session_protocol | Specifies the higher-level protocol specified by the user for this session in the CIO_START operation. |
logical_channel | Identifies the X.25 logical channel number used by the session. |
tx_tclass | Specifies the transmit throughput class facility in use on the session. If the call has not been established, this is 0. |
rx_tclass | Specifies the receive throughput class facility in use on the session. If the call has not been established, this is 0. |
tx_packet_size | Identifies the outbound packet size in use on the session. If the call has not been established, this field is set to 0. |
rx_packet_size | Identifies the inbound packet size in use on the session. If the call has not been established, this field is set to 0. |
tx_window_size | Identifies the outbound window size in use on the session. If the call has not been established, this field is set to 0. |
rx_window_size | Identifies the inbound window size in use on the session. If the call has not been established, this field is set to 0. |
The X25_QUERY_SESSION operation can be called from the process environment only.
A return code of -1 indicates an unsuccessful operation. If -1 is returned, the kernel sets the errno global variable to one of the following values:
EFAULT | Indicates a specified address was not valid. |
EINVAL | Indicates the session ID was not valid, or the logical_channel field was not valid. |
The X25_QUERY_SESSION operation functions with an X.25 Interface Co-Processor/2 that has been correctly configured for use on a qualified network. Consult adapter specifications for more information on configuring the adapter and network qualifications.
The CIO_START x25sioctl operation.
The x25sioctl entry point.