Use this system macro to lock a virtual file access (VFA) shared lock or
exclusive lock.
Format
- label
- A symbolic name can be assigned to the macro statement.
- LOCK
- Specifies the type of lock, where:
- VFAS
- Specifies shared lock.
- VFAX
- Specifies exclusive lock.
Entry Requirements
Register 5 (R5) must contain the address of the VFA buffer control area
(BCA) only.
Return Conditions
- Control is returned to the next sequential instruction (NSI).
- Register 14 (R14) and register 15 (R15) are used to branch and link to the
macro service routine so the contents of both registers are corrupted.
All other registers are preserved.
Programming Considerations
- You can run this macro from any I-stream.
- This macro is for use in the control program (CP) only.
- System errors can occur while processing the $LCKRC request.
See Messages (System Error and Offline) for more
information about these system errors.
Examples
The following example shows you how to lock an exclusive lock using this
macro.
$LCKRC LOCK=VFAX