DFHSNEP macros for generating the sample node error program

The routing mechanism, common subroutines, CICS®-supplied error processors, and user-supplied error processors are generated by means of DFHSNEP macros.

The sample node error program and table need to be translated, assembled, and link-edited. For information about the job control statements required to assemble and link-edit user-replaceable programs, refer to Assembling and link-editing user-replaceable programs. Note that you should code the translator options NOPROLOG and NOEPILOG in your node error program.

Note also that an additional 24 bytes are required for the common subroutines register save area, and further space is required for the error processor save area. The CICS sample processors use 4 bytes of this area.

The DFHSNEP macro to generate the sample node error program has seven types, as follows:
  • DFHSNEP TYPE=USTOR, to indicate the start of user storage definitions.
  • DFHSNEP TYPE=USTOREND, to indicate the end of user storage definitions.
  • DFHSNEP TYPE=INITIAL, to generate the routing mechanism and, optionally, the common subroutines.
  • DFHSNEP TYPE=DEF3270, to generate the default CICS-supplied error processors for 3270 devices.
  • DFHSNEP TYPE=DEFILU, to generate the default CICS-supplied error processor for interactive logical units operating in contention mode.
  • DFHSNEP TYPE=ERRPROC, to indicate the start of a user-supplied error processor.
  • DFHSNEP TYPE=FINAL, to indicate the end of the sample node error program.

DFHSNEP TYPE=USTOR and DFHSNEP TYPE= USTOREND (Defining user storage)

The DFHSNEP TYPE=USTOR and DFHSNEP TYPE=USTOREND macros indicate the start and end respectively of user storage definitions.

The DFHSNEP TYPE=USTOR macro indicates the start of user storage definitions. It must be followed by your storage definitions, and then by DFHSNEP TYPE=USTOREND. If you use DFHSNEP TYPE=USTOR to define storage, then both it and DFHSNEP TYPE=USTOREND must be coded before DFHSNEP TYPE=INITIAL.

DFHSNEP  TYPE=USTOR

The DFHSNEP TYPE=USTOREND macro indicates the end of user storage definitions. Its use is mandatory if DFHSNEP TYPE=USTOR has been coded. If you use DFHSNEP TYPE=USTOR to define storage, then both it and DFHSNEP TYPE=USTOREND must be coded before DFHSNEP TYPE=INITIAL.

DFHSNEP  TYPE=USTOREND

DFHSNEP TYPE=INITIAL (Generating the routing mechanism)

The DFHSNEP TYPE=INITIAL macro indicates the start of the sample node error program and causes the routing mechanism to be generated.

One DFHSNEP TYPE=INITIAL macro must appear immediately after DFHSNEP TYPE=USTOR and DFHSNEP TYPE=USTOREND (if they are coded) and before the remaining macros.

DFHSNEP  TYPE=INITIAL
         [,CS=NO]
         [,NAME=name]
         [,NETNAME=netname]
TYPE=INITIAL
indicates the start of the sample node error program and causes the routing mechanism to be generated.
CS=NO
specifies that the generation of the common subroutines is to be suppressed.
NAME=name
specifies the name of the node error program module identifier. The name must be a string of 1 through 8 characters. This operand is optional, and the default is DFHZNEP0. If you allow the NAME operand to default, you can use the examples in Link-edit statements for DFHTEP and DFHZNEP to create link-edit statements, but if you specify a different NAME, you must change the link-edit statements accordingly. If the interface module DFHZNEP (generated by the DFHZNEPI macro) is used, this operand must be specified (with a name other than DFHZNEP).
NETNAME=netname
specifies the name of the node error table to be loaded at initialization. The name must be a string of 1 through 8 characters. This operand is optional, and the default is DFHNET.

DFHSNEP TYPE=DEF3270 (Including error processors for 3270 LUs)

The DFHSNEP TYPE=DEF3270 macro specifies that the CICS-supplied error processors for 3270 logical units are to be included in the node error program.

DFHSNEP  TYPE=DEF3270
This macro causes the following source code to be generated:
DFHSNEP TYPE=ERRPROC,GROUP=1,CODE=(D9,DC,DD,F2)
Sense/status error processor code.
 
DFHSNEP TYPE=ERRPROC,GROUP=2,CODE=42
Unavailable printer error processor code.

DFHSNEP TYPE=DEFILU (Including error processors for INTLUs)

The DFHSNEP TYPE=DEFILU macro specifies that the CICS-supplied error processor for interactive logical units is to be included in the node error program.

DFHSNEP  TYPE=DEFILU
This macro causes the following source code to be generated:
DFHSNEP TYPE=ERRPROC,GROUP=1,CODE=DC
(receiver in transmit mode error processor code)

DFHSNEP TYPE=ERRPROC (Specifying a user error processor)

The DFHSNEP TYPE=ERRPROC macro is used to indicate the start of a user-supplied error processor. The actual error processor code should immediately follow this macro. The assembly should be terminated by the statement END DFHNEPNA.

The following operands can be used on the DFHSNEP TYPE=ERRPROC macro:
DFHSNEP  TYPE=ERRPROC
         ,CODE=(error-code,...)
         ,GROUP=error-group-index
TYPE=ERRPROC
indicates the start of a user-supplied error processor.
CODE=(error-code,...)
specifies the error codes that make up the error group, and which are therefore handled by the error processor supplied. The operand is coded as a sublist of 2-character representations of 1-byte hexadecimal codes. (The parentheses can be omitted for a single code.) For each code specified, the error group index is placed at the equivalent offset in the translate table. Thus, when this code occurs, the appropriate error processor can be identified.
GROUP=error-group-index
specifies an error group index for the error processor. This index is used to name the error processor, locate its address from the error processor vector table (EPVT), and optionally associate it with an ESB in each NEB. The index specified must be a 2-character representation of a 1-byte hexadecimal number in the range X'01' through X'FF' (a leading zero can be omitted). The error processor name has the form NEPROCxx, where “xx” is the error group index. A CSECT statement of this name is generated, which causes the error processor code to be assembled at the end of the node error program module and to have its own addressability.
If you intend to add your own error processors to the sample node error program, you should consider the following factors:
  • The layout of the communication area. The communication area is described in detail in Figure 2.
  • The fact that certain functions cannot be used within DFHZNEP. (See Restrictions on the use of EXEC CICS commands.)
  • The register conventions used by the sample node error program. These are described in Table 1.
Table 1. Register assignment
Register Use
0 Work register
1 Address of the EXEC parameter list
2 NEB base register (DFHSNEP only)
3 ESB base register (DFHSNEP only) NEP error class register (DFHZNEPI only)
4 NEP name pointer register (DFHZNEPI only)
5 NEP interface base register (DFHZNEPI only)
6 Work register
7 Work register
8 Work register
9 Work register
10 Code base register
11 Address of the EIB
12 Address of the communication area
13 Address of DFHEISTG storage
14 CSVT base and error processor link register Common subroutine link register
15 Error processor branch register Common subroutine branch register.
Note:
  1. Register 14 must be saved for return from error processors. The common subroutine vector table (CSVT) is coded after the BALR to the error processor and so this register is also the CSVT base.
  2. Registers 1, 10, 12, 13, 14, and 15 are set up on entry to error processors.
  3. Registers 14 through 11 can be saved by error processors in an area reserved in EXEC interface storage at label NEPEPRS. Registers 15 through 11 do not need to be restored before return from error processors.
  4. Registers 4 through 9 can be saved by common subroutines in an area reserved in EXEC interface storage at label NEPCSRS. They must be restored before return from the subroutines.

DFHSNEP TYPE=FINAL (Terminating DFHSNEP entries)

One DFHSNEP TYPE=FINAL macro must follow all the other DFHSNEP macros to indicate the end of the node error program. It causes the error processor vector table (EPVT) to be generated. The EPVT is a table containing addresses of the error group processors invoked by the routing mechanism of the node error program.

DFHSNEP  TYPE=FINAL