z/OS MVS Installation Exits
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


ISGNQXIT — ISGENQ / ENQ / DEQ Installation Exit

z/OS MVS Installation Exits
SA23-1381-00

For the best performance, IBM® recommends that the installation use the ISGNQXITFAST rather than ISGNQXIT. The ISGNQXIT exit should only be used if the ISGNQXITFAST exit cannot be used. In no case should both exits be used because both will be called on every ENQ resulting in degraded system performance.

For each ISGENQ/ENQ/DEQ/RESERVE request with SCOPE=SYSTEM or SCOPE=SYSTEMS, the system invokes the ENQ/DEQ Installation Exit point, ISGNQXIT. The exit routines can modify attributes of the request prior to Resource Names List (RNL) processing. See z/OS MVS Planning: Global Resource Serialization in z/OS Internet Library at http://www.ibm.com/systems/z/os/zos/bkserv/ for the installation flow through ENQ/DEQ exits.

By altering the exit parameter list, the exit can:
  • Alter the resource name (QNAME and/or RNAME).
  • Alter the resource scope. See restrictions as stated in the Note.
  • Alter the UCB address (for a RESERVE). See restrictions as stated in the Note.
  • Convert a RESERVE to an ENQ by setting the UCB to zero. See restrictions as stated in the Note.
  • Convert an ENQ to a RESERVE by adding a UCB specification. See restrictions as stated in the Note.
  • Indicate to bypass the RNL processing.
Note: The exit routine cannot change the scope nor UCB address of a request when the program issues the ENQ or ISGENQ macro with RNL=NO. The Nqxp_SF1_RnlEqNo bit passed in the parameter list indicates if RNL=NO was specified.

This exit is invoked under the caller's unit of work on the system where the caller is running. For global resource requests, the exit is invoked only on the system where the request is made.

Note:
  1. Any changes made by ISGNQXIT are not honored for an ISGENQ CHANGE or RELEASE request. Instead, the original changes made by ISGNQXIT on the OBTAIN are used.
  2. This exit replaces the ISGGREX0 exit interface, which was removed in z/OS® V1R2; ISGGSIEX, ISGGSEEX, and ISGGRCEX are no longer used. Message ISG351I is issued and the exit is not invoked if any of these exits are installed.

Replacing the Exit Routine

Unlike RNL changes, GRS does not know how an exit alters the resource identity of a request. Therefore, to maintain data integrity, do not make an exit change that alters the resource identity of any outstanding or in-flight ENQ or DEQ requests. The resource identity consists of the QNAME, RNAME, SCOPE, and hardware reserve status. When you make exit changes, first stop the programs that are currently using the resource, and do not resume the programs until all the exit changes in the GRS complex have completed.

Any changes the exit makes must be taken into consideration. For information regarding dynamic exit routine replacement, see Replacing a Dynamic Exit Routine.

Exit Routine Environment

ISGNQXIT receives control in the following environment:
  • Enabled for interrupts.
  • In supervisor state with PSW key 0.
  • In primary mode with H = P = S = requestor's address space.
  • In AMODE 31 and RMODE ANY.
  • With no locks held.

Exit Recovery is as follows.

  • If an error occurs, ISGNQXIT provides its own recovery routine.
  • If no recovery exists, or the recovery continues with termination, GRS fails the request and continues processing. CSVDYNEX rules for the exit are used to determine whether the exit should be removed.

    The unplanned removal of an exit can result in serialization changes. Such changes might cause data integrity errors. Therefore, it is important to provide recovery and to understand how CSVDYNEX determines when to remove an abend exit. For more information about CSVDYNEX, see z/OS MVS Programming: Authorized Assembler Services Reference ALE-DYN.

Exit Routine Processing

The ISGNQXIT exit routine is invoked for every ENQ/DEQ/RESERVE/ISGENQ SCOPE=SYSTEM or SCOPE=SYSTEMS request issued for a resource. If any exit routines are defined to the dynamic exits facility, those routines are invoked before Resource Names List (RNL) processing.

By updating and using information in the parameter list, the exit routine alters the following characteristics of the request:
  • Resource major name (QNAME).
  • Resource minor name (RNAME).
  • Resource scope. If the requester specified RNL=NO, changes to this parameter are not honored.
  • Device UCB address (for RESERVE or DEQ with UCB requests). If the requester specified RNL=NO, changes to this parameter are not honored. A UCB address can be deleted from a RESERVE request, converting the request from a RESERVE to an ENQ or a UCB address can be added to an ENQ, converting the request to a RESERVE.

The exit routine can also indicate that RNL processing can be bypassed.

Programming Considerations

Observe the following conventions when coding an ISGENQ, ENQ, DEQ and RESERVE exit routine:
  • Every exit routine must be reentrant.
  • Because the exit is called for every ISGENQ, ENQ, DEQ, and RESERVE request, an increased path length increases processor utilization and can degrade performance.
  • Do not code the exit routine to issue the WAIT macro or call a service, such as WTOR, that issues a WAIT.
  • Do not code the exit routine to issue another ISGENQ, ENQ, RESERVE, or DEQ macro.
  • The QNAME, RNAME, SCOPE, and UCB must match both the ENQ and the DEQ.
  • Issuing the GETMAIN or STORAGE OBTAIN macro can slow down performance.

Entry Specifications

The ISGENQ/ENQ/DEQ/RESERVE mainline routine passes the address of the ENQ exit parameter list (ISGYNQXP).

Registers at Entry: The contents of the registers on entry to the exit are as follows.

Register
Contents
0
Not applicable
1
Address of the exit parameter list (ISGYNQXP).
2-12
Not applicable
13
Address of a 72-byte save area
14
Return address
15
Entry point address of ISGNQXIT

Parameter List Contents: Register 1 contains the address of the exit parameter (NQXP) that is mapped by macro ISGYNQXP. Refer to z/OS MVS Data Areas in z/OS Internet Library at http://www.ibm.com/systems/z/os/zos/bkserv/ for the mapping of the ISGYNQXP data area.

Return Specifications

The ISGENQ/ENQ/DEQ installation exit sets the appropriate request flag and alters the value in the parameter list. For example, to change the major name, the exit sets Nqxp_RFI_ChangeQName to '1'b and Nqxp_CP_QNAME to the new major name.

Registers at Exit: Upon return from the exit processing, the register contents must be as follows.

Register
Contents
0-14
Restored to contents on entry
15
0

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014