z/OS MVS Programming: Authorized Assembler Services Reference ALE-DYN
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


ASDES — Terminate an address space

z/OS MVS Programming: Authorized Assembler Services Reference ALE-DYN
SA23-1372-00

Description

The ASDES macro terminates an address space that was created through the ASCRE macro.

z/OS MVS Programming: Extended Addressability Guide describes how to create and terminate address spaces.

ASDES processing circumvents all task recovery and task resource manager processing. Its use should be restricted to a select group of routines that can determine that task recovery and task manager clean-up are either not warranted or will not successfully operate in the address space being terminated. An alternate way to terminate an address space is to use CALLRTM TYPE=ABTERM and specify the jobstep TCB.

Environment

Requirements for the caller of ASDES are:

Environmental factor Requirement
Minimum authorization: Supervisor state
Dispatchable unit mode: Task
Cross memory mode: PASN=HASN or PASN¬=HASN
AMODE: Any
ASC mode: Primary or AR
Interrupt status: Enabled for I/O and external interrupts
Locks: No locks held
Control parameters: For callers in primary mode, control parameters must be in the primary address space. For callers in AR mode, the parameters can be in any space addressable through public entries in the caller's dispatchable unit access list (DU-AL).

Programming requirements

Callers in access register (AR) mode must have issued SYSSTATE ASCENV=AR to tell ASDES to generate code and addresses appropriate for callers in AR mode.

The caller must not have an enabled unlocked task (EUT) functional recovery routine (FRR) established.

Output register information

After the caller issues the macro, the macro might use some registers as work registers or might change the contents of some registers. When the macro returns control to the caller, the contents of these registers are not the same as they were before the macro was issued. Therefore, if the caller depends on these registers containing the same value before and after issuing the macro, the caller must save these registers before issuing the macro and restore them after the system returns control.

When control returns to the caller, the general purpose registers (GPRs) contain:
Register
Contents
0
Reason code
1
Used as a work register by the macro
2-13
Unchanged
14
Used as a work register by the macro
15
Return code
When control returns to the caller, the access registers (ARs) contain:
Register
Contents
0-1
Used as work registers by the macro
2-13
Unchanged
14-15
Used as work registers by the macro

Syntax

The syntax of the ASDES macro is as follows:

Syntax Description
   
   name name: Symbol. Begin name in column 1.
   
One or more blanks must precede ASDES.
   
ASDES  
   
One or more blanks must follow ASDES.
   
STOKEN=stoken-addr stoken-addr: RX-type address or registers (2) - (12).
   
   ,RELATED=value value: Any valid macro parameter specification.
   

Parameters

The parameters are explained as follows:

STOKEN=stoken-addr
Specifies the address of an eight-byte area that contains the STOKEN of the address space you want to terminate. The system returned the STOKEN in the 24-byte area requested by the ODA parameter on the ASCRE macro that created the address space. STOKEN is a required parameter.
,RELATED=value
Specifies information used to self-document macros by “relating” functions or services to corresponding functions or services. The format and contents of the information specified are at the discretion of the user, and may be any valid coding values.

Return and reason codes

Return codes and reason codes (in decimal form) are shown in the following table.

Table 1. Return and Reason Codes for the ASDES Macro
Decimal Return Code Decimal Reason Code Meaning
00 00 Meaning: Address space is terminated.
08 04 Meaning: Caller is not in supervisor state.
08 08 Meaning: Caller is not enabled.
08 12 Meaning: Caller is not in task mode.
08 16 Meaning: Caller is not unlocked.
08 20 Meaning: GPR 0 had invalid function code.
08 24 Meaning: ASDES could not establish recovery.
12 04 Meaning: ASDES could not reference the STOKEN parameter.
12 08 Meaning: STOKEN does not map to a valid address space. Address space might have already terminated.
16 04 Meaning: The address space was not created by ASCRE.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014