Description

The EDTINFO macro enables you to obtain information from the eligible device table (EDT) and to check your device specification against the information in the EDT. See z/OS HCD Planning and z/OS MVS Programming: Assembler Services Guide for further information about the EDT.

For callers only in supervisor state AND PSW key 0, the EDTINFO macro performs the following function:
Note: If the RTNEDTLT function is specified, no other EDTINFO functions can be requested on the same invocation nor can the IOCTOKEN and EDTADDR keywords be specified.

For a list of functions performed by the EDTINFO macro for both unauthorized and authorized callers, see z/OS MVS Programming: Assembler Services Reference ABE-HSP.

Environment

The requirements for the caller are:

Environmental factor Requirement
Minimum authorization: Supervisor state and any PSW key 0.
Dispatchable unit mode: Task
Cross memory mode: PASN=HASN=SASN or PASN¬=HASN¬=SASN
AMODE: 24- or 31- bit
ASC mode: Primary or access register (AR)
Interrupt status: Enabled for I/O and external interrupts
Locks: No locks held
Control parameters: Must be in the primary address space.

Programming requirements

Callers requesting the RTNEDTLT function of the EDTINFO macro must be in 31-bit AMODE to reference the areas returned through the ELTPRI and ELTSEC pointers.

Callers requesting the RTNEDTLT function of the EDTINFO macro are required to free the storage returned through the ELTPRI and ELTSEC pointers.

Restrictions

Callers must be supervisor state and PSW key 0 in order to invoke the RTNEDTLT function.

Input register information

Before issuing the EDTINFO macro, the caller does not have to place any information into any register unless using it in register notation for a particular parameter, or using it as a base register.

Output register information

When control returns to the caller, the general purpose registers (GPRs) contain:
Register
Contents
0
Reason code if GPR 15 contains a return code of 04 or 08; otherwise, used as a work register by the system
1
Used as a work register by the system
2-13
Unchanged
14
Used as a work register by the system
15
Return code
When control returns to the caller, the access registers (ARs) contain:
Register
Contents
0-1
Used as work registers by the system
2-13
Unchanged
14-15
Used as work registers by the system

Some callers depend on register contents remaining the same before and after issuing a service. If the system changes the contents of registers on which the caller depends, the caller must save them before issuing the service, and restore them after the system returns control.

Performance implications

None.

Syntax

The standard form of the EDTINFO macro is written as follows:

Syntax Description
   
   name name: Symbol. Begin name in column 1.
   
One or more blanks must precede EDTINFO.
   
EDTINFO  
   
One or more blanks must follow EDTINFO.
   
   RTNEDTLT
Note: If this function is specified, no other functions can be requested.
   
   ,ELTPRI=eltpri eltpri: RS-type address or register (2) - (12).
   
   ,ELTSEC=eltsec eltsec: RS-type address or register (2) - (12).
   
   ,RETCODE=retcode retcode: RX-type address or register (2) - (12).
   
   ,RSNCODE=rsncode rsncode: RX-type address or register (2) - (12).
   

Parameters

The parameters are explained as follows:

RTNEDTLT
Specifies that the EDTINFO service should return both the primary and secondary EDT Latch Tables.
,ELTPRI=eltpri
Specifies the fullword output field that will contain the address of the primary EDT Latch Table. The area returned can be mapped by IEFDELT.
ELTSEC=eltsec
Specifies the fullword output field that will contain the address of the secondary EDT Latch Table. The area returned can be mapped by IEFDELT.
,RETCODE=retcode
Specifies the fullword location where the system is to store the return code. The return code is also in GPR 15.
,RSNCODE=rsncode
Specifies the fullword location where the system is to store the reason code. The reason code is also in GPR 0.

Return and reason codes

When control returns from EDTINFO, GPR 15 (and retcode addr, if you coded RETCODE) contains one of the following hexadecimal return codes:

Return Code Meaning
00 The requested function or functions were performed and no reason code information has been returned.
04 The requested function or functions were performed and information has been returned, as explained by the hexadecimal reason code that accompanies this return code. The reason code is in GPR 0 (and in rsncode, if you coded RSNCODE).
Reason Code
Meaning
04
Either the primary EDT Latch Table or the secondary EDT Latch Table or both EDT Latch Tables contain no entries.
08 There is data in the input parameter list that is not valid, as explained by the hexadecimal reason code that accompanies this return code. The reason code is in GPR 0 (and in rsncode, if you coded RSNCODE).
Reason Code
Meaning
01
The input unit name could not be found in the EDT.
02
The input device type could not be found in the EDT.
03
One or more of the input device numbers is invalid.
04
The caller did not provide sufficient storage for the returned information.
05
The MAXELIG function requires a generic device type as input, but the input specified does not represent a generic device type.
06
The caller did not request any functions.
07
The caller requested functions that are not valid
08
For a required input, the caller specified a value that is not valid. For example, other functions were specified with a function that requires no other function requests.
09
The caller was not in supervisor state and PSW key 0 for a function that requires this environment.
10 Storage could not be obtained for the request.
18 An unexpected system error occurred.

Example

Obtain the EDT Latch Tables for both the primary and secondary EDTs.
EDTINFO RTNEDTLT,ELTPRI=PRI_ELT_PTR,ELTSEC=SEC_ELT_PTR