z/OS MVS Programming: Assembler Services Reference ABE-HSP
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


CSRC4RG1 — Allocate a cell from a cell pool (register interface)

z/OS MVS Programming: Assembler Services Reference ABE-HSP
SA23-1369-00

Description

Call the CSRC4RG1 cell pool service to allocate a cell from the cell pool using the register interface, if your program cannot obtain storage for a parameter list. CSRC4RG1 allocates cells from the lowest- to highest-numbered active extents, and within each extent, from the lowest to highest cell address. (The CSRC4RGT service provides the same function but slightly slower performance.)

Environment

The requirements for the caller are:

Environmental factor Requirement
Minimum authorization: Problem state with PSW key 8-15
Dispatchable unit mode: Task or SRB
Cross memory mode: Any PASN, any HASN, any SASN.
AMODE: 64-bit addressing mode. All input addresses must be valid 64-bit addresses.
ASC mode: Primary or AR mode. (If the anchor and the extents are located in a data space, the caller must be in AR mode.)
Interrupt status: Enabled or disabled for I/O and external interrupts
Locks: The caller may hold locks, but is not required to hold any.
Control parameters: None.

Programming requirements

As the program must be running in AMODE 64 to call this service, be sure to issue SYSSTATE AMODE64=YES at the point(s) where the program begins running in AMODE 64.

Before you use cell pool services, you can optionally include the CSRC4ASM macro to generate cell pool services equate (EQU) statements. CSRC4ASM provides the following constants for use in your program:
*  Length of the cell pool anchor data area:
*
CSRC4_ANCHOR_LENGTH     EQU     64
*
*
*  Base length of the cell pool extent data area:
*
CSRC4_EXTENT_BASE       EQU     192
*
*
*  Length of the user-supplied pool name:
*
CSRC4_POOL_NAME_LEN     EQU     8
*
*
*  Length of the user-supplied savearea:
*
CSRC4_SAVEAREA_LEN     EQU     216
*
*

Restrictions

None.

Input register information

Before calling the CSRC4RG1 service, the caller must ensure that the following access registers (ARs) and general purpose registers (GPRs) contain the specified information:
Register
Contents
AR 1
The ALET used to access all the cell storage areas. Specify 0 if your program is running in AR mode and the anchor and extents are in the primary address space. If your program is running in primary ASC mode, CSRC4RG1 ignores the value.
GPR 1
The doubleword anchor address
GPR 13
The address of a 216-byte save area that your program provides. The system does not change the first 8 bytes of this area.

Output register information

When control returns to the caller, the 64-bit general purpose registers (GPRs) contain:
Register
Contents
0-1
Used as work registers by the system
2-13
Unchanged
14
Used as a work register by the system
15
Return code in low 32 bits. High 32 bits are used as a work area by the system.
When control returns to the caller, the ARs contain:
Register
Contents
0
Used as a work register by the system
1-14
Unchanged
15
Used as a work register 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

Write the call as shown on the syntax diagram.

Syntax Description

CALL CSRC4RG1
 

 

ABEND codes

None.

Return and reason codes

When the CSRC4RG1 service returns control to your program, GPR 15 contains one of the following return codes:

Hexadecimal Return Code Decimal Return Code Meaning and Action
00 00 Meaning: The operation was successful.

Action: None.

08 08 Meaning: Program error. There were no available cells in the pool.

Action: Retry the request one or more times. If the problem persists, consider freeing existing cells, adding new cells to the cell pool, or both.

1C 28 Meaning: Program error. The anchor address is not valid.

Action: Check to see if your program passed the wrong anchor address or inadvertently overlaid the anchor area.

64 100 Meaning: Program error or system error. An extent chain was broken.

Action: Check to see if your program inadvertently overlaid an extent area. Make sure that no extent belongs to more than one cell pool.

68 104 Meaning: Program error or system error. An extent chain is circular.

Action: Check to see if your program inadvertently overlaid an extent area. Make sure that no extent belongs to more than one cell pool.

74 116 Meaning: Program error or system error. An extent has been overlaid.

Action: Check to see if your program inadvertently overlaid an extent area. Make sure that no extent belongs to more than one cell pool.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014