This ioctl is used to configure the wlcfg database for a link. The wlcfg database appropriate to a link is carried as the M_DATA part of the ioctl N_linkconfig. The U_LINK_ID member of the wlcfg structure specifies the link to be configured. The wlcfg database structure is defined in the /usr/include/netx25/x25_control.h file.
This ioctl affects currently open connections and could therefore disrupt users significantly. For this reason it can only be used by root.
The wlcfg database structure contains the members described below:
The upper level link identifier which is quoted by upper level software in the xaddrf address structure to specify which link a call is to be sent on. It is also used to identify which link an incoming call arrived on.
This determines the characteristics of the network protocol Possible values are:
Table 7-18 NET_MODE values
String |
Value |
Network, X.25 Type, or Country |
---|---|---|
X25_LLC |
1 |
X.25(84/88)/LLC2 |
X25_88 |
2 |
X.25(88) |
X25_84 |
3 |
X.25(84) |
X25_80 |
4 |
X.25(80) |
GNS |
5 |
UK |
AUSTPAC |
6 |
Australia |
DATAPAC |
7 |
Canada |
DDN |
8 |
USA |
TELENET |
9 |
USA |
TRANSPAC |
10 |
France |
TYMNET |
11 |
USA |
DATEX_P |
12 |
Germany |
DDX_P |
13 |
Japan |
VENUS_P |
14 |
Japan |
ACCUNET |
15 |
USA |
ITAPAC |
16 |
Italy |
DATAPAK |
17 |
Sweden |
DATANET |
18 |
Holland |
DCS |
19 |
Belgium |
TELEPAC |
20 |
Switzerland |
F_DATAPAC |
21 |
Finland |
FINPAC |
22 |
Finland |
PACNET |
23 |
New Zealand |
LUXPAC |
24 |
Luxembourg |
X25_Circuit |
25 |
dialup call |
This determines the version of the X.25 protocol used over the network. Allowed values are:
0 indicating X.25(80)
1 indicating X.25(84)
2 indicating X.25(88)
Setting NET_MODE to X25_LLC overrides an X.25 (80) value.
Indicates whether the link is DTE or DCE. Allowed values are:
0 indicating DCE
1 indicating DTE
2 indicating that this is to be resolved by following the procedures in ISO 8208 for DTE-DTE operation
LPC to HPC
Logical channel range assigned to PVCs.
LIC to HIC
Logical channel range assigned to one way incoming logical channels.
LTC to HTC
Logical channel range assigned to two-way logical channels.
LOC to HOC
Logical channel range assigned to one-way outgoing logical channels.
In a DTE/DTE environment, one of the interacting pairs views these ranges as a DCE, for example, LIC to HIC are viewed as one-way outgoing. HxC = LxC = 0 denotes no channels in that grouping.
NPCchannels, NICchannels, NTCchannels, NOCchannels and Nochnls
The number of logical channels assigned. This is calculated from the logical channel ranges and can only be changed only by altering these ranges.
THISGFI
0x10 indicates Modulo 8. 0x20 indicates Modulo 128 sequence numbering operates on the network.
LOCMAXPKTSIZE
The maximum acceptable size of local to remote data packets, expressed as a power of 2.
REMMAXPKTSIZE
The maximum acceptable size of remote to local data packets expressed as a power of 2.
LOCDEFPKTSIZE
The default local-to-remote packet size expressed as a power of 2.
REMDEFPKTSIZE
The default remote-to-local packet size on a particular link, expressed as a power of 2.
LOCMAXWSIZE
The maximum acceptable local to remote X.25 window size.
REMMAXWSIZE
The maximum acceptable remote to local X.25 window size.
LOCDEFWSIZE
The local-to-remote default window size.
REMDEFWSIZE
The remote-to-local default window size.
MAXNSDULEN
The default maximum length beyond which concatenation is stopped and the data currently held is passed to the NS-user. This parameter can be overridden on a per-circuit basis using the nsdulimit parameter on N-CONNECT requests and N-CONNECT responses.
ACKDELAY
The maximum delay in ticks (0.1 second units) over which a pending acknowledgement will be withheld. The default value is 5, the permitted range 1--32000.
T20value
The length of DTE timer T20, the Restart Request Response Timer, in ticks (0.1 second units). The default value is 1800. The permitted range is 0--32000.
T21value
The length of DTE timer T21, the Call Request Response Timer, in ticks (0.1 second units). The default value is 2000. The permitted range is 0--32000.
T22value
The length of DTE timer T22, the Reset Request Response Timer, in ticks (0.1 second units). The default value is 1800. The permitted range is 0--32000.
T23value
The length of DTE timer T20, the Clear Request Response Timer, in ticks (0.1 second units). The default value is 1800. The permitted range is 0--32000.
Tvalue
The maximum time over which acknowledgments of data received from the remote transmitter will be withheld. After this timer expires any withheld acknowledgments are carried by a Receive Not Ready (RNR) packet. This timer ensures that non-receipt of acknowledgment by the remote transmitter does not cause resets within the virtual circuit. This timer does not cause transmission of window status every Tvalue ticks (0.1 second units). The default value is 750. The permitted range is 0--32000.
T25value
The length of DTE timer T25, the Window Rotation Timer, in ticks (0.1 second units). The default value is 1500, as specified in ISO 8208. The permitted range is 0--32000.
The code may be configured to be lenient in the case of flow control inhibition (see Section 11.2 of ISO 8208). That is, a decision has to be made in order to cater for the case when the remote station does not rotate the window fast enough to prevent expiration of T25. ISO 8208 recommends strongly that high level protocols be used to effect recovery, to achieve this, set T25 to either zero (implying infinite) or a very large value.
The timer Tvalue, should be set to a value approximately half T25value, in order to prevent the remote PLP from resetting on T25 expiration. The timer ACKDELAY should be approximately 0.5 seconds, although this recommendation may change after evaluation and experience is gained.
Finally, the idlevalue timer may be set according to how quickly the LAN administration wishes the resource to be reclaimed, while connectvalue should be about three times the T20 value.
Note also that ISO 8208 recommends that the retry values R20, R22 and R23 should never be set to zero in order to cater for the possibility of collisions (see footnote to Figure 6, ISO 8208).
T26value
The length of DTE timer T26, the Interrupt Response Timer, in ticks (0.1 second units). The default value is 1800. The permitted range is 0--32000.
T28value
The length of DTE timer T28, the Registration Request Timer, in ticks (0.1 second units). The default value is 1800. The permitted range is 0--32000.
idlevalue
The number of ticks (0.1 second units) over which a link-level connection associated with no connections is maintained. This timer is meaningful on a LAN or on a dial-up WAN connection. The default value is 600. The permitted range is 0--32000.
connectvalue
The number of ticks (0.1 second units) over which the DTE/DCE resolution phase must be complete. On expiration of this timer, the link connection is disconnected and all pending connections are aborted. The default value is 2000. The permitted range is 0--32000.
The DTE Restart Request Retransmission Count. The default value is 1. The permitted range is 1--255.
R22value
The DTE Restart Request Retransmission Count. The default value is 1. The permitted range is 1--255.
R23value
The DTE Restart Request Retransmission Count. The default value is 1. The permitted range is 1--255.
localdelay and accessdelay
In milliseconds, the values of the transit delay attributed to internal processing and the effect of the line transmission rate. These values are used to check whether any maximum acceptable end-to-end transit delay specified in an N-CONNECT request or an N-CONNECT indication is in fact available.
locmaxthclass
The maximum value of the throughput class quality of service parameter in the local-to-remote direction which is supported. According to ISO 8208 this parameter is bounded in the range 3 and <= 12 corresponding to a range 75 to 48000 bits/second.
remmaxthclass
The maximum value of the throughput class quality of service parameter in the remote-to-local direction which is supported. According to ISO 8208 this parameter is bounded in the range 3 and <= 12 corresponding to a range 75 to 48000 bits/second.
locdefthclass
In some PSDNs, for example, TELENET, negotiation of throughput class is constrained to be towards a configured default throughput class. In such cases the flag thclass_neg_to_def (see below) is non-zero and locdefthclass is the default for the local-to-remote direction. In other PSDNs, locdefthclass should be set equal to the value of locmaxthclass (see above).
Note that locmaxthclass must be greater than or equal to locdefthclass.
remdefthclass
In some PSDNs, for example, TELENET, negotiation of throughput class is constrained to be towards a configured default throughput class. In such cases the flag thclass_neg_to_def is non-zero and remdefthclass is the default for the remote-to-local direction. In other PSDNs, set remdefthclass equal to the value of remmaxthclass (see above).
Note that remmaxthclass must be greater than or equal to remdefthclass.
locminthclass
According to ISO 8208, the throughput class parameter must be greater than or equal to 3 and less than or equal to 12. Some PSDNs may provide a different mapping, in which case locminthclass is the minimum value in the local-to-remote direction. Note that locmaxthclass must be less than or equal to locdefthclass which must be greater than or equal to locminthclass.
remminthclass
According to ISO 8208, the throughput class parameter is defined in the range 3 and 12. Some PSDNs may provide a different mapping, in which case remminthclass is the minimum value in the remote-to-local direction. Note that remmaxthclass must be greater than or equal to remdefthclass which must be greater than or equal to remminthclass.
CUG_CONTROL
This member controls Closed User Group actions in two ways. Firstly, it describes the type, if any, of Closed User Group facilities subscribed to. This is used to choose the appropriate encoding for any closed user group facilities in N-CONNECT requests. Secondly, it specifies the action to be taken if the Closed User Group optional facility is present in an incoming call. It is a bit map where the bits have the following meanings:
Table 7-19 bit map summary
Bit |
Description |
---|---|
0 |
subscription to CUGs with no Outgoing or Incoming Access |
1 |
subscription to Preferential CUG |
2 |
subscription to CUGs with Outgoing Access |
3 |
subscription to CUGs with Incoming Access (For Information Only) |
4 |
subscription to Basic Format CUGs |
5 |
subscription to Extended format CUGs |
6 |
reject incoming calls containing any Closed User Group facility |
7 |
reserved |
Bits 0 and 2 are mutually exclusive as are bits 4 and 5.
SUB_MODES
This member is a bit map, which contains information on the various subscription options for a particular PSDN link. The entries mean:
Table 7-20 SUB_MODES summary
Some PSDNs require certain procedures to be followed which are not standard for all X.25 networks. The structure psdn_local contains the flags used to tune the actions of the X.25 driver to the requirements of the particular network to which the configuration refers. The entries and values taken by the psdn_local structure are described below.
PSDN_MODES
This is used to tune the various options for a particular PSDN link. It is a bit map in which the various entries when set imply:
Table 7-21 PSDN Modes
The BAR_DIAG and DISC_NZ_DIAG entries specify the treatment of incoming diagnostic packets. When BAR_DIAG is set, incoming diagnostic packets are handled as follows. If USE_DIAG is set, and the link is configured as a DCE, then a diagnostic packet is sent to the DTE. Otherwise, the incoming diagnostic packet is simply discarded. When DISC_NZ_DIAG is set, diagnostic packets will be discarded when received on non-zero logical channel numbers. If ACC_HEX_ADD is set, DTE addresses are not restricted to containing only BCD digits.
intl_addr_recogn
The main use of this feature is in conjunction with the intl_prioritised member discussed below. Possible values are:
Table 7-22 Intl_addr_recogn summary
Value |
Description |
---|---|
0 |
International calls are not distinguished. |
1 |
The DNIC of the called DTE address is examined and compared to that held in psdn_local members dnic1 and dnic2. A mismatch implies an international call. |
2 |
International calls are distinguished by having a "1" prefix on the called DTE address; for example, DATAPAC has this feature. |
3 |
International calls are distinguished by having a "0" prefix on the called DTE address. |
dnic1, dnic2
The first four BCD digits of the DNIC and is only used when intl_addr_recogn has the value one.
intl_prioritised
This determines whether some prioritization method is to be used for international calls, and is used in conjunction with prty_encode_control and prty_pkt_forced_value.
intl_prioritised has two values: zero implying no priority, while non-zero implies an attempt to prioritize according to ptry_encode_control.
intl_addr_recogn has the value one.
prty_encode_control
This describes how the priority request is to be encoded for this PSDN. Values are:
Table 7-23 prty_encode_control values
prty_pkt_forced_value
If this entry is non-zero then it implies that all priority call requests and incoming calls should have the associated packet size parameter forced to this value (note that the actual packet size is two to the power of this parameter; for example, 7 implies 128 byte packets). A zero value implies no special action on packet size is required.
src_addr_control
This provides the means to override or set the calling address in outgoing call requests for this PSDN. It takes the following values:
Table 7-24 src_addr_control values
Value |
Description |
---|---|
0 |
No special action. Calling DTE addresses are encoded as and if provided by the network service user. |
1 |
Force omission of the calling DTE address, even if the network service user supplied one. |
2 |
If the network service user does not supply a DTE address, use the configured DTE address (local_address) for this PSDN (which can, of course, be NULL). |
3 |
Force the calling DTE address to that contained in local_address, even if the network service user supplied one. |
dbit_control
This member specifies the action to be taken:
during the call setup phase, where both parties do not agree on the use of the D-bit;
during the data transfer phase, on receipt of a data packet with the D-bit set, where the use of the D-bit has not been agreed by both parties.
Actions which may be specified during the call setup phase are:
Leave the D-bit set and pass the packet on.
Zero the D-bit and pass the packet on.
Clear the call.
Actions which may be specified during the data transfer phase are:
Leave the D-bit set and pass the packet on.
Zero the D-bit and pass the packet on.
Reset the call.
thclass_neg_to_def
This accommodates certain network procedures which dictate that negotiation of throughput class must be towards the default value (for example, TELENET), the default value being configured into the member defthclass. A non-zero value in this member requests use of this option, zero implies non-use.
thclass_type
This provides the means by which throughput class encodings can be used to assign window and packet sizes (according to the arrays thclass_wmap and thclass_pmap described below). It should be noted that some implementations of X.25 do not use the X.25 packet and window negotiation but instead rely on mapping the throughput class to these parameters (see thclass_type 1,2 and 3). Thclass_type should be used on such PSDNs. Note also that the values of locmaxthclass and remmaxthclass may have an effect on what is achieved through the mapping.
The values assigned to thclass_type to indicate the mapping are:
Table 7-25 thclass_type values
Value |
Description |
---|---|
0 |
No special action is to be taken on throughput class. |
1 |
Use only the low nibble of the throughput class parameter to map window and packet size for both directions and encode the high nibble as zero. Note that the window and packet sizes are intended to be asserted by the throughput class parameter. |
2 |
Use only the high nibble of the throughput class parameter to map window and packet size for both directions and encode the low nibble as zero. Note that the window and packet sizes are intended to be asserted by the throughput class parameter. |
3 |
Use both nibbles of the throughput class to map window and packet size for the appropriate directions. Note that the window and packet sizes are intended to be asserted by the throughput class parameter. |
Values 1, 2 and 3 are intended for use on non-standard X.25 PSDN implementations. Note the following.
For the special values 1 and 2:
Do not select these values when window and packet sizes can appear in call setup packets (that is, subscription to window and packet size negotiation) since this algorithm is designed for those PSDNs which support only the mapping procedure.
In call requests, the network service user should specify equal values for locthroughput and remthroughput in the qosformat, to ensure that the correct behavior is obtained (see also high and low nibble usage for these two values).
The user will be barred from negotiating window and packet sizes, and the throughput class will not be indicated in a connect indication.
For the value 3, window and packet sizes can be negotiated by the network service user only through the throughput class parameter. Negotiations through the flow negotiation parameters when subscribing to the extended facility option are overridden. However, as for values 1 and 2, this value is intended only for cases where this is the only means of negotiating window and packet sizes.
Since window and packet sizes can be mapped using these three values without the use of window and packet negotiation facilities, it is important that the map (thclass_wmap and thclass_pmap) is correct for the PSDN, in order to ensure that both called and calling parties agree on the values associated with a particular throughput class.
thclass_wmap, thclass_pmap
The mapping between the value of the throughput class (a number 0 to 15) and a window and packet parameter. Zero in this table indicates that the currently set or default value be used.
local_address
Holds the local DTE address for this X.25 link in a byte array, local_address.lsap_add, with an associated length byte local_address.lsap_len.