TITLE 'HZSTUTAC - IBM Health Checker for z/OS ADD CHECK SampleX ' */* START OF SPECIFICATIONS ******************************************* * *01* MODULE NAME: HZSTUTAC * * *01* DESCRIPTIVE-NAME: IBM Health Checker for z/OS * Sample Add Check Exit Routine * * *01* PROPRIETARY STATEMENT= * * **PROPRIETARY_STATEMENT********************************************* * * * * * LICENSED MATERIALS - PROPERTY OF IBM * * THIS MACRO IS "RESTRICTED MATERIALS OF IBM" * * 5694-A01 (C) COPYRIGHT IBM CORP. 2005 * * * * STATUS= HZS7720 * * * * **END_OF_PROPRIETARY_STATEMENT************************************** * * * * *01* EXTERNAL CLASSIFICATION: OTHER @P1C* *01* END OF EXTERNAL CLASSIFICATION: * * * * * *01* DISCLAIMER = * * * * This sample source is provided for tutorial purposes only. A * * complete handling of error conditions has not been shown or * * attempted. * * * * * *01* FUNCTION: This module has the following entry points. * * 1. HZSTUTAC HZSTUTAC exit routine that defines checks to * IBM Health Checker for z/OS * * *02* OPERATION: HZSTUTAC * * HZSTUTAC * 1 ENTRY * 2 INVOKE HZSADDCK MACRO to define One Time check to * IBM Health Checker for z/OS * 3 INVOKE HZSADDCK MACRO to define Interval check to * IBM Health Checker for z/OS * 4 RETURN * 5 END HZSTUTAC * *02* RECOVERY-OPERATION: * No recovery is provided for this exit point * *********************************************************************** * *01* NOTES: * * None * *02* DEPENDENCIES: * * None * *02* RESTRICTIONS: * * None * *02* REGISTER-CONVENTIONS: * *03* REGISTERS SAVED: R0-R15 *03* REGISTERS RESTORED: R0-R14 *03* CODE REGISTER: R12 *03* DATA REGISTER: R13 * *02* PATCH-LABEL: None * *01* MODULE-TYPE: Procedure * *02* PROCESSOR: High Level Assembler * *02* MODULE-SIZE: See External Symbol Dictionary * *02* ATTRIBUTES: * *03* LOCATION: Authorized Link List Library *03* LOAD MOD: HZSTUTAC *03* TYPE: Reentrant *03* APF: NO - AC(0) *03* AMODE: 31 *03* RMODE: Any *03* SYSGEN: NONE * *********************************************************************** * *01* ENTRY-POINT: HZSTUTAC * *02* PURPOSE: See FUNCTION section for this module. * *03* OPERATION: See OPERATION section for this module. * *02* ATTRIBUTES: * *03* ENTRY * *04* MODE: Enabled *04* STATE: Supervisor *04* KEY: 8 *04* AMODE: 31 *04* LOCKS HELD: None *04* ASCMODE: Primary *04* MEMORY MODE: P=S=H *04* DISPATCH MODE: Task *04* ADDRESS SPACE: IBM Health Checker for z/OS * *03* EXECUTION * *04* MODE: Enabled *04* STATE: Supervisor *04* KEY: 8 *04* AMODE: 31 *04* LOCKS OBTAINED: None *04* ASCMODE: Primary *04* MEMORY MODE: P=S=H *04* ADDRESS SPACE: IBM Health Checker for z/OS * *02* LINKAGE: Branch Entry * *03* CALLERS: * * IBM Health Checker for z/OS under the HZSADDCHECK exit * *02* INPUT: * * None * *03* ENTRY-REGISTERS: * * R0 - R15 - Irrelevant * *02* OUTPUT: * * 1) Checks added to IBM Health Checker for z/OS via * HZASDDCK MACRO * *02* EXIT-NORMAL: RETURN TO CALLER * *03* CONDITIONS: Successful completion * *03* EXIT-REGISTERS: * * R0 - R14 - Unchanged * R15 - Return Code * *03* RETURN-CODES: * * 0 - Completed successfully * 8 - HZSADDCHK Macro failure * *02* EXIT-ERROR: None * *********************************************************************** * *01* EXTERNAL-REFERENCES : * *02* ROUTINES: * * None * *02* DATA-AREAS: * * None * *02* CONTROL-BLOCKS: * * Name Macro Use Description * ---------- ---------- ------ --------------------------- * None * * Legend: C=Create, R=Read, W=Write, D=Delete * *01* MACRO-EXCUTABLE: * * Name Macro Use Note * ---------- ---------- ------ ----------------------------- * FREEMAIN FREEMAIN G Release working storage * GETMAIN GETMAIN G Obtain working storage * HZSADDCK HZSADDCK G Define checks with HC * * Legend: G=Generally used macro * *01* CHANGE-ACTIVITY: * * $L0=HCHECK ,HZS7720,050701,PDXB: Sample Healh Checker checks * **** END OF SPECIFICATIONS *******************************************/ HZSTUTAC CSECT HZSTUTAC AMODE 31 Run in 31 bit addressing mode HZSTUTAC RMODE 31 Load load module in any storage R0 EQU 0 Work Register R1 EQU 1 Work Register R2 EQU 2 Available for use R3 EQU 3 Available for use R4 EQU 4 Available for use R5 EQU 5 Available for use R6 EQU 6 Available for use R7 EQU 7 Available for use R8 EQU 8 Available for use R9 EQU 9 Available for use R10 EQU 10 Available for use R11 EQU 11 Available for use R12 EQU 12 Program Base R13 EQU 13 Work Area Base R14 EQU 14 Work Register R15 EQU 15 Work Register SYSSTATE ARCHLVL=1 J Chk_Over_ID Jump over the identifier DC CL8'HZSTUTAC' ... Program Name DC CL8'&SYSDATE' ... Assembly Date Chk_Over_ID DS 0H STM R14,R12,12(R13) Save Callers Registers LR R12,R15 ... and Establish Program Base USING HZSTUTAC,R12 @@@ Program Base GETMAIN RU, Unconditionally obtain storage * LV=Dynamic_Work_Len, ... of this size in 31 bit * LOC=(31,31) ... addressing and storage ST R13,4(0,R1) Set save area Back Chain pointer ST R1,8(0,R13) ... forward chain pointer LR R13,R1 ... and my save/work area base USING Dynamic_Work,R13 @@@ Work Area Base * ------------------------------------------------------------------- * * Add a One Time Only health check to the * * IBM Health Checker for z/OS * * ------------------------------------------------------------------- * HZSADDCK CHECKOWNER=CK_Owner, Supply Owners Name of the check * CHECKNAME=CK1_Name, ... the Name of the Check * CHECKROUTINE=CK_Routine, .. Name of the module with chk * ACTIVE, ... Activate check immediately * LOCAL, ... Run check on every system * ENTRYCODE=CK1_Entry_Code, . Entry code for this check * EXITRTN=CK_Xit_Routine, ... Name of routine adding chk * MSGTBL=CK_MSG_Table, ... Name of message table * DATE=CK1_Date, ... Base date for defaults * REASON=CK1_Reason, ... Reason for this check * REASONLEN=CK1_Rsn_Len, ... ... and its length * PARMS=Ck1_Parm, ... Default Parameters * PARMSLEN=Ck1_Parm_Len, ... ... and their length * SEVERITY=LOW, ... Severity of check * INTERVAL=ONETIME, ... A one time check * USS=NO, ... Check does not use USS * MF=(E,HZSADDCK_PLIST) ... Execute form * * There is no reason to check the return code. Any "bad" error * would result in an abend. And there are some cases during refresh * processing where non-zero return codes are expected. * HZSADDCK CHECKOWNER=CK_Owner, Supply Owners Name of the check * CHECKNAME=CK2_Name, ... the Name of the Check * CHECKROUTINE=CK_Routine, .. Name of the module with chk * ACTIVE, ... Activate check immediately * LOCAL, ... Run check on every system * ENTRYCODE=CK2_Entry_Code, . Entry code for this check * EXITRTN=CK_Xit_Routine, ... Name of routine adding chk * MSGTBL=CK_MSG_Table, ... Name of message table * DATE=CK2_Date, ... Base date for defaults * REASON=CK2_Reason, ... Reason for this check * REASONLEN=CK2_Rsn_Len, ... ... and its length * SEVERITY=LOW, ... Severity of check * INTERVAL=TIMER, ... A check that is executed * HOURS=CK2_Hours, ... ... Every this many hours * MINUTES=CK2_Minutes, ... ... and this many minutes * USS=NO, ... Check does not use USS * MF=(E,HZSADDCK_PLIST) ... Execute form * * There is no reason to check the return code. Any "bad" error * would result in an abend. And there are some cases during refresh * processing where non-zero return codes are expected. * Return_To_Caller DS 0H LR R1,R13 Address of area to release L R13,4(0,R13) ... back up the save area chain FREEMAIN RC, Release our working storage * LV=Dynamic_Work_Len, ... of this length and * A=(1) ... pointed at by this register LM R14,R12,12(R13) ... Restore registers BR R14 ... There is no return code. DROP R13 @@@ Work Area Base DROP R12 @@@ Program Base * ------------------------------------------------------------------- * * Literal Pool * * ------------------------------------------------------------------- * LTORG * ------------------------------------------------------------------- * * HZSADDCK Macro Common Constants * * ------------------------------------------------------------------- * CK_Xit_Routine DC CL8'HZSTUTAC' Name of this routine CK_Routine DC CL8'HZSTUTCK' Name of health check routine CK_MSG_Table DC CL8'HZSTUTMT' Name of Message Table for checks CK_Owner DC CL16'IBMSAMPLE' Owner of these health checks * ------------------------------------------------------------------- * * HZSADDCK Macro Check Specific Constants * * ------------------------------------------------------------------- * CK1_Name DC CL32'HZS_SAMPLE_ONE_TIME' Name for this Hlth Check CK1_Entry_Code DC F'1' Entry code for this check CK1_Date DC CL8'20051031' ... Date this check's defaults * ... were set. The installation * ... must provide a date after * ... this in order to override * ... the defaults CK1_Rsn_Len DC A(L'CK1_Reason) Length of health check reason CK1_Parm_Len DC A(L'CK1_Parm) Length of health check parms CK1_Reason DC C'A sample health check to demonstrate a one time hx ealth check.' Reason for this Health Check CK1_Parm DC C'LIMIT(047)' Set the initial limit CK2_Name DC CL32'HZS_SAMPLE_INTERVAL' Name for this Hlth Check CK2_Entry_Code DC F'2' Entry code for this check CK2_Date DC CL8'20051031' ... Date this check's defaults * ... were set. The installation * ... must provide a date after * ... this in order to override * ... the defaults CK2_Hours DC H'00' Hours and Minutes between calls CK2_Minutes DC H'05' ... of this check. CK2_Rsn_Len DC A(L'CK2_Reason) Length of health check reason CK2_Reason DC C'A sample check to demonstrate an interval check' * Reason for this health check Dynamic_Work DSECT DS CL72 Save Area HZSADDCK MF=(L,HZSADDCK_PLIST) HZSADDCK parm list Dynamic_Work_Len EQU *-Dynamic_Work END HZSTUTAC