Type ASSEMBLE
Source Lines : 1,257
Fixes Applied : 4
Most Recent Version : Wednesday, December 13, 1978
Last Fix ID : [HRC029DK]
Module
DMKCFS
Function
TO PROCESS NON PRIVILEGED SET COMMANDS
Attributes
REENTRANT, PAGEABLE, CALLED VIA SVC
Operation
1. CALL DMKSCNFD TO SEE IF THERE IS A SECOND ARGUMENT. IF NONE IS FOUND, SET A FLAG TO INDICATE THIS AND CONTINUE. IF HAVE ONE, SAVE IT IN SAVEWRK5/6. 2. USING THE INDEX SET BY DMKCFC, BRANCH TO THE APPROPRIATE ROUTINE TO HANDLE THE REQUEST. TSTONOFF - THIS IS THE SUBROUTINE TO TEST THE ON/OFF ARGUMENT. IF THE ARGUMENT = ON, RETURN ON REGISTER 8. IF THE ARGUMENT = OFF, RETURN ON REGISTER 10. IF NO OTHER ARGUMENTS ARE LEGAL, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFS026E. IF SOMETHING ELSE LEGAL, RETURN ON REGISTER 7. SET TIMER 1. SETIMER - ROUTINE TO PROCESS THE SET TIME REQUEST. SET UP REGISTERS 7 AND 8 FOR RETURN FROM TSTONOFF. THEN BAL R10 TO THE SUBROUTINE LABELED TSTONOFF. 2. IF OFF WAS SPECIFIED, CHECK IF REAL IS NOW ACTIVE. IF IT IS, CALL DMKFRET TO FRET THE TIMER BLOK FOR THIS USER. SET THE VMTLEVEL FOR OFF, DISABLE THE VIRTUAL TIMER ASSIST, AND EXIT. 3. IF ON WAS SPECIFIED, CHECK FOR REAL ACTIVE. IF SO, CALL DMKFRET TO FRET THE TIMER BLOK. SET UP VMTLEVEL FOR ON, CHECK IF VIRTUAL TIMER ASSIST CAN BE USED, AND EXIT. 4. IF GET A RETURN FOR OTHER THAN ON/OFF, CHECK IF 'REAL'. IF NOT, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFS003E. IF OK, CALL DMKFREE TO GET STORAGE FOR A TIMER BLOK. INITIALIZE THE TIMER BLOK, ENABLE TIMER FEATURE IF IT CAN BE USED, AND THEN EXIT. SET ISAM 1. SETISAM - ROUTINE FOR THE SET ISAM REQUEST. SET UP FOR RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMISAM FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE VMISAM FLAG IN THE VMBLOK AND EXIT. SET AUTOPOLL 1. SETAUTO - ROUTINE FOR THE SET AUTOPOLL REQUEST. SET UP FOR RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMFAUTO FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE VMFAUTO FLAG IN THE VMBLOK AND EXIT. SET EMSG 1. SETERROR - ROUTINE TO PROCESS THE SET EMSG REQUEST. SET UP REGISTERS 7 AND 8 FOR THE RETURN FROM ON/OFF TESTING. BAL R10 TO THE SUBROUTINE LABELED TSTONOFF TO TEST THE ON/OFF/CODE/TEXT. 2. IF RETURN FOR OFF CONDITION, SET THE VMMLEVEL FOR NO EMSG AND EXIT. 3. IF RETURN FOR ON, SET UP VMMLEVEL FOR BOTH CODE AND TEXT AND EXIT. 4. IF RETURN FOR OTHER THAN ON/OFF, CHECK FOR 'CODE'. IF IT IS, SET UP THE VMMLEVEL FOR ERROR CODE ONLY AND EXIT. IF FOR 'TEXT' SET VMMLEVEL FOR TEXT ONLY AND EXIT. IF NEITHER OF THESE, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFS003E. SET ACNT 1. SETACNT - ROUTINE FOR THE SET ACNT REQUEST. SET UP THE RETURNS FOR ON/OFF AND BAL R10 TO SUBROUTINE LABELED TSTONOFF. 2. IF RETURN FOR OFF, RESET THE VMACCON FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, TURN ON THE VMACCON FLAG IN THE VMBLOK AND EXIT. SET LINEDIT 1. SETLINE - ROUTINE FOR THE SET LINED REQUEST. SET UP FOR RETURN FROM SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMLINED FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE VMLINED FLAG IN THE VMBLOK AND EXIT. SET RUN 1. SETRUN - ROUTINE FOR THE SET RUN REQUEST. SET UP FOR RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMRUNON FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE VMRUNON FLAG IN THE VMBLOK AND EXIT. SET WNG 1. SETWNG - ROUTINE FOR SET WNG REQUEST. SET UP FOR THE RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMWNGON FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE VMWNGON FLAG IN THE VMBLOK AND EXIT. SET MSG 1. SETMSG - ROUTINE FOR THE SET MSG REQUEST. SET UP FOR THE RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE VMMSGON FLAG IN THE VMBLOK AND EXIT. 3. IF THE RETURN IS FOR ON, SET THE VMMSGON FLAG IN THE VMBLOK AND EXIT. SET NOTRANS 1. SETNTRAN - ROUTINE TO HANDLE NOTRAN REQUEST. IF NOT A VALID NOTRAN USER, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFS003E. IF THE USER IS A VALID ONE, SET UP REGISTERS FOR THE RETURN FROM THE SUBROUTINE LABELED TSTONOFF AND BAL R10 TO THAT ROUTINE. 2. IF RETURN FOR OFF, RESET THE NOTRANS FLAG IN THE VMBLOK AND EXIT. 3. IF RETURN FOR ON, SET THE NOTRANS FLAG IN THE VMBLOK AND EXIT. SET PFNN 1. GET IMMED OR DELAYED PARM IF ENTERED 2. SET PF FUNCTION RELEASING OLD ONE IF PRESENT 3. SCAN TO SEE IF ALL FUNCTIONS NULL AND FRET FUNCTION TABLE IF SO SET ASSIST 1. SETASST - ROUTINE TO PROCESS SET ASSIST REQUEST. IF THERE IS NO SECOND ARGUMENT, CALL DMKERMSG TO SEND ERROR MESSAGE DMKCFS026E. IF THERE IS ONE, ASCERTAIN WHAT IT IS. 2. IF ARGUMENT IS SVC, VERIFY THAT VM ASSIST IS AVAILABLE IF NOT, ISSUE MSG DMKCFS184E. ELSE TURN ON VMMICSVC BIT IN THE VMBLOK AND IF NO ADSTOP IS IN EFFECT TURN OFF THE VMMSVC BIT IN THE VMBLOK. GO TO STEP 8. 3. IF ARGUMENT IS NOSVC, TURN OFF VMMICSVC BIT AND TURN ON VMMSVC BIT (BOTH IN VMBLOK). GO TO STEP 8. 4. IF ARGUMENT IS TMR, CHECK FOR VM ASSIST AND TIMER ASSIST AVAILABLE, IF NOT SEND ERROR MESSAGE DMKCFS187E. ELSE TURN ON VMFVTMR BIT IN VMBLOK AND CHECK IF TIMER ASSIST CAN BE ENABLED. IF IT CAN, TURN ON VMMVTMR BIT IN VMBLOK AND SET UP MICVTMR POINTER IN MICBLOK. 5. IF ARGUMENT IS NOTMR, TURN OFF VMFVTMR BIT IN VMBLOK AND DISABLE VIRTUAL TIMER ASSIST. GO TO STEP 8. 6. IF ARGUMENT IS ON, CHECK IF VM ASSIST IS AVAILABLE FOR THE SYSTEM. IF NOT, ISSUE MSG DMKCFS184E. ELSE GET SPACE FOR MICBLOK; PUT ADDRESS OF MICBLOK INTO VMBLOK; CHECK IF VIRTUAL TIMER ASSIST CAN BE ENABLED; GO TO STEP 8. 7. IF ARGUMENT IS OFF, FRET MICBLOK; TURN OFF VMMFE, VMMVTMR BITS IN VMBLOK; ZERO VMMADDR IN VMBLOK; GO TO STEP 8. 8. CALL DMKSCNFD TO FIND ANOTHER ARGUMENT. IF FOUND, MOVE IT TO SAVEWRK5 AND GO TO STEP 2. ELSE CONTINUE 9. EXIT, GIVING USER INFORMATION DESCRIBING AVAILABILITY OF VM ASSIST AS FOLLOWS: 10. IF USER HAS VM ASSIST AND AFFINITY BUT SYSTEM VM ASSIST IS NOT ON FOR THE AFFINITY PROCESSOR, THEN A. IF PROCESSOR HAS VM ASSIST, SEND MSG DMKCFS183E B. IF VM ASSIST IS NOT AVAILABLE ON THAT PROCESSOR, SEND MSG DMKCFS184E WITH THE PROCESSOR ADDRESS 11. IF USER HAS VM ASSIST AND NO AFFINITY AND VM ASSIST IS NOT ON FOR ANY PROCESSOR, SEND MSG DMKCFS183E SET PAGEX 1. SET PAGEX ON/OFF - ENABLE/DISABLE PSEUDO PAGE FAULTS VERIFY THAT USER HAS ECMODE PRIVILEGES; IF NOT, CALL DMKERMSG FOR MESSAGE DMKCFS003E 2. VERIFY THAT 2ND ARGUMENT EXISTS AND IS EITHER "ON" OR "OFF"; IF NOT, CALL DMKERMSG FOR MESSAGE DMKCFS003 3. BASED ON ON/OFF TEST, SET OR RESET FLAG VMPAGEX IN VMPSTAT AND EXIT. SET IMSG 1. SETIMSG - ROUTINE TO HANDLE SET IMSG ON|OFF. VERIFY THAT 2ND ARGUMENT EXISTS AND THAT IT'S ON OR OFF. IF ARGUMENT MISSING, ISSUE MSG DMKCFS0026E, IF INVALID, ISSUE MSG DMKCFS003E. 2. BASED ON ON/OFF TEST, SET OR RESET VMMIMSG BIT IN VMMLVL2 AND EXIT. SET SMSG - ROUTINE TO SET SMSG FLAG IN USER'S VMBLOK 'ON' OR 'OFF' 1. GET ON/OFF OPTION AND VALIDATE. 2. IF OPTION IS INVALID, SEND MSG DMKCFS026E. 3. ELSE SETUP FOR RETURN FROM TSTONOFF SUBROUTINE. BAL R10 TO THAT ROUTINE. 4. IF OPTION IS 'OFF', TURN OFF APPROPRIATE FLAG IN VMBLOK. 5. IF OPTION IS 'ON', TURN ON APPROPRIATE FLAG IN VMBLOK. 6. RETURN TO CALLER WITH CODE OF 0. SET CPUID BBBBBB 1. SETCPUID - ROUTINE TO HANDLE SET CUPID BBBBBB; VERIFY THAT SECOND ARGUMENT EXISTS. IF NOT, ISSUE DMKCFS026E MESSAGE. 2. IF 'BBBBBB' FIELD IS GREATER THAN 6 DIGITS, ISSUE MESSAGE DMKCFS026E. 3. OTHERWISE, CONVERT CPU SERIAL (BBBBBB) FROM HEX TO BINARY AND STORE IN VMCPUID FIELD. SET AFFINITY SET THE VMAFF BYTE IN THE VMBLOK TO INDICATE WHETHER AFFINITY IS WANTED, AND IF SO, WHICH PROCESSOR 1. SET USERID = ISSUER. IF NO ARGS, GO TO 18 2. USE TSTONOFF TO SEE IF 2ND ARG IS ON|OFF|NUMERIC|UID 3. IF RETURN FOR OFF, SET TARGET PROC = 0 AND GO TO 17 4. IF RETURN FOR ON, GO TO 18 5. CHECK USER FOR COMMAND CLASS A ELSE ISSUE MSG 26 6. IF ARGUMENT IS NUMERIC, GO TO 12 7. IF ARGUMENT IS NOT NUMERIC, SAVE AS A USERID AND GET NEXT ARGUMENT. IF NONE, GO TO 18 8. USE TSTONOFF TO SEE IF 3RD ARG IS ON|OFF|NUMERIC 9. IF RETURN FOR OFF, SET TARGET PROC = 0, AND GO TO 17 10. IF RETURN FOR ON, GO TO 18 11. CONVERT ARGUMENT TO BINARY 12. IF ARG > 63 OR NOT DECIMAL, ISSUE ERROR MSG 26 AND EXIT 13. OR X'40' OVER BINARY VALUE AND SAVE AS TARGET PROCESSOR 14. IF TARGET PROCESSOR = LPUADDR, A. IF SYSTEM RUNNING AP, GO TO 17 B. ELSE, ISSUE MSG 189 AND EXIT 15. IF ARG ¬= LPUADDR & SYSTEM RUNNING UP, ISSUE MSG 188 16. IF SYSTEM RUNNING AP, A. IF TARGET PROCESSOR = LPUADDRX, GO TO 17 B. ELSE ISSUE MSG 188 AND EXIT 17. LOOK FOR SPECIFIED USER LOGGED ON. IF NOT, ISSUE MSG 45 SET AFFINITY INTO VMAFF IN TARGET USER'S VMBLOK 18. LOOK FOR TARGET USER'S DIRECTORY ENTRY A. IF NO AFFINITY IN DIRECTORY, GIVE MSG 190 AND EXIT B. ELSE, USE UMACAFF AS TARGET PROCESSOR, GO TO 14
Calls to Other Routines
DMKSCNFD - LOCATE ARGUMENTS IN THE COMMAND LINE DMKQCNWT - TO OUTPUT MESSAGES TO TERMINAL DMKSCNAU - TO FIND USERS VMBLOK ADDRESS DMKCVTBH - TO CONVERT BINARY TO HEX DMKCVTDB - TO CONVERT DECIMAL TO BINARY DMKCVTHB - TO CONVERT HEX TO BINARY DMKFREE - TO OBTAIN A BLOCK OF FREE STORAGE DMKFRET - TO RETURN A BLOCK OF STORAGE DMKQCNRD - TO READ A RESPONSE FROM THE TERMINAL DMKCVTDT - TO GET THE DATE AND TIME DMKSTKIO - TO STACK A TIMER REQUEST BLOK (TRQBLOK) DMKERMSG - TO SEND AN ERROR MESSAGE DMKSCHRT - TO FREE A TIMER REQUEST BLOK DMKSCNAU - TO FIND A USER'S VMBLOK @V4075A0 DMKUDRFU - TO FIND THE USER'S DIRECTORY ENTRY @V4075A0 DMKUDRMD - TO READ THE USER'S MACHINE DESCRIPTOR @V4075A0 DMKUDRRV - TO RELEASE THE DIRECTORY PAGE IN VM VM @V4075A0