.TITLE ISUSHOMSG .IDENT \ISUQUOTA 2.9\ ARG_COUNT= 0 ARG_STS= 4 ARG_QUAX= 8 MAX_MSGVEC_L= 10 .PAGE .SBTTL MACROS ; USER MACROS QCKDEF QUOMSGDEF QUAXDEF .PAGE .SBTTL LOCAL READ-ONLY DATA .PSECT LCLRODATA,RD,NOWRT,NOEXE,LONG MASK_DOLRTYP: .LONG QMSK_M_DOLLARS MASK_TIMETYP: .LONG QMSK_M_AUTHEXP! - QMSK_M_CPU! - QMSK_M_CONN TAB_QUOUSE: .LONG QMSK_M_AUTHEXP .LONG QXR_EXPIRE_T .LONG QXR_AUTHOR_T .LONG ISUQUO_WARNEXP .LONG ISUQUO_NOTAUTH .LONG QMSK_M_DOLLARS .LONG QXR_Q_DOLLARS .LONG QXR_U_DOLLARS .LONG ISUQUO_LOWDOLR .LONG ISUQUO_OVRDOLR .LONG QMSK_M_CPU .LONG QXR_Q_CPU_C .LONG QXR_U_CPU_C .LONG ISUQUO_LOWCPU .LONG ISUQUO_OVRCPU .LONG QMSK_M_CONN .LONG QXR_Q_CONN_C .LONG QXR_U_CONN_C .LONG ISUQUO_LOWCONN .LONG ISUQUO_OVRCONN .LONG QMSK_M_DISK .LONG QXR_Q_DISK_C .LONG QXR_U_DISK_C .LONG 0 .LONG ISUQUO_OVRDISK .LONG QMSK_M_CONSESS .LONG QXR_Q_CONSESS .LONG QXR_U_CONSESS .LONG 0 .LONG ISUQUO_OVRSESS .LONG QMSK_M_PRINT .LONG QXR_Q_PAGE_C .LONG QXR_U_PAGE_C .LONG ISUQUO_LOWPAGE .LONG ISUQUO_OVRPAGE N_QUOUSE= .-TAB_QUOUSE/QCK_K_LENGTH .PAGE .SBTTL LOCAL READ-WRITE DATA .PSECT LCLRWDATA,RD,WRT,NOEXE,LONG DYN_ASC_TIME1: .LONG 0 .LONG 10$ 10$: .BLKB 23 DYN_ASC_TIME2: .LONG 0 .LONG 10$ 10$: .BLKB 23 ASCTIM_CVTFLG: .BLKL 1 WORK: .BLKB 4*4 .PAGE .SBTTL CODE,RD,NOWRT,EXE,LONG .ENTRY SHOWARN,^M CLRL R7 ; SHOWARN SELECTOR BRW DO_SHOMSG .ENTRY SHOFAIL,^M MOVL #1,R7 ; SHOFAIL SELECTOR DO_SHOMSG: MOVL ARG_STS(AP),R11 ; ADR STATUS MOVL ARG_QUAX(AP),R10 ; ADR QUAX MOVAL TAB_QUOUSE,R8 ; ADR QUOTA/USE INFO SUBL #MAX_MSGVEC_L*4,SP ; WORK AREA MOVAL (SP),R9 ; ADR MSGVEC CLRL R6 ; LOOP INDEX LOOP_SHOMSG: BITL QCK_MASK(R8),(R11) ; STS BIT SET FOR THIS MSG? BEQL CONT_SHOMSG ; NO BITL MASK_DOLRTYP,QCK_MASK(R8) ; DOLLARS? (SPECIAL HANDLING) BEQL 10$ ; NO JSB PROC_SETDOLRMSG ; FILL IN DOLLAR MSG BRW GOTO_STSTYPE 10$: BITL MASK_TIMETYP,QCK_MASK(R8) ; TIME VALUES? BEQL 20$ ; NO JSB PROC_SETTYMMSG ; FILL IN ASCII TIMES BRW GOTO_STSTYPE 20$: JSB PROC_SETMSG ; FILL IN STANDARD MSG GOTO_STSTYPE: CASEB R7,#0,#2 ; INSERT WARN OR FATAL MSGID 1$: .WORD 21$-1$ .WORD 22$-1$ CLRL R0 ; ERROR RETURN BRW RET_SHOMSG 21$: MOVL QCK_WAR_MSGID(R8),QMSG_MSGID(R9) ; WARNING MSG BRW 30$ 22$: MOVL QCK_FAT_MSGID(R8),QMSG_MSGID(R9) ; FATAL MSG 30$: TSTL QMSG_MSGID(R9) ; IF NO MESSAGE THEN SKIP IT BEQL CONT_SHOMSG $PUTMSG_S MSGVEC=(R9) ; DISPLAY MESSAGE CONT_SHOMSG: ADDL #QCK_K_LENGTH,R8 ; NEXT ENTRY AOBLSS #N_QUOUSE,R6,LOOP_SHOMSG ; CONTINUE RET_SHOMSG: ADDL #MAX_MSGVEC_L*4,SP ; RLSE WORK AREA RET .PAGE .SBTTL PROC_SETDOLRMSG ; PROC_SETDOLRMSG: MOVL #6,QMSG_LENGTH(R9) ; FILL IN PART OF MSGVEC MOVL #4,QMSG_FAO_CNT(R9) CLRQ -(SP) ; WORK AREA MULF3 #100.0,QXR_U_DOLLARS(R10),(SP) ; CVT DOLLARS-TO-CENTS CVTRFL (SP),(SP) ; CVT TO INTEGER EDIV #100,(SP),WORK,WORK+4 ; DOLLARS AND CENTS MOVL WORK,QMSG_FAO_ARG(R9) MOVL WORK+4,QMSG_FAO_ARG+4(R9) MULF3 #100.0,QXR_Q_DOLLARS(R10),(SP) ; CVT DOLLARS-TO-CENTS CVTRFL (SP),(SP) ; CVT TO INTEGER EDIV #100,(SP),WORK,WORK+4 ; DOLLARS AND CENTS MOVL WORK,QMSG_FAO_ARG+8(R9) MOVL WORK+4,QMSG_FAO_ARG+12(R9) MOVAB 8(SP),SP ; RLSE WORK AREA RSB_SETDOLRMSG: RSB .PAGE .SBTTL PROC_SETTYMMSG ; MASK_SETTYMMSG= ^M PROC_SETTYMMSG: PUSHR #MASK_SETTYMMSG ; SAVE WORK REGS MOVL #4,QMSG_LENGTH(R9) ; FILL IN MSGVEC LENS MOVL #2,QMSG_FAO_CNT(R9) ADDL3 QCK_U_OFFSET(R8),R10,R7 ; ADR TIME USAGE MOVAQ DYN_ASC_TIME1,R6 ; ADR 1ST ASCII DESCRIPTOR LOOP_SETTYMMSG: MOVL #23,(R6) ; INIT ASCII TIME DESCRIPTOR CLRL ASCTIM_CVTFLG ; INIT CVTFLG TO INCL DAYS BITL #QMSK_M_AUTHEXP,QCK_MASK(R8) ; DATE? BNEQ 20$ ; YES BITL #QMSK_M_CPU,QCK_MASK(R8) ; CPU? BEQL 10$ ; NO EMUL #-100000,(R7),#0,WORK ; CVT 10-MILLISEC TO DELTA TIME MOVL #1,ASCTIM_CVTFLG ; SUPPRESS CPU DAYS BRB 15$ 10$: EMUL #-10000000,(R7),#0,WORK ; CVT SEC TO DELTA TIME 15$: MOVAQ WORK,R7 ; ADR TIME FOR $ASCTIM 20$: $ASCTIM_S TIMLEN=WORK+8,- ; GENERATE ASCII DATE STRG TIMBUF=(R6),- TIMADR=(R7),- CVTFLG=ASCTIM_CVTFLG MOVZWL WORK+8,(R6) ; UPDATE ASCII TIME DESCRIPTOR CMPL R6,#DYN_ASC_TIME2 ; DONE? BEQL RSB_SETTYMMSG ; YES MOVAQ DYN_ASC_TIME2,R6 ; ADR 2ND ASCII DESRIPTOR ADDL3 QCK_Q_OFFSET(R8),R10,R7 ; ADR QUAX QUOTA BRW LOOP_SETTYMMSG RSB_SETTYMMSG: MOVAQ DYN_ASC_TIME1,QMSG_FAO_ARG(R9) ; SET MSG ARGS MOVAQ DYN_ASC_TIME2,QMSG_FAO_ARG+4(R9) POPR #MASK_SETTYMMSG ; RESTORE WORK REGS RSB .PAGE .SBTTL PROC_SETMSG ; PROC_SETMSG: MOVL #4,QMSG_LENGTH(R9) ; FILL IN PART OF MSGVEC MOVL #2,QMSG_FAO_CNT(R9) ADDL3 QCK_U_OFFSET(R8),R10,QMSG_FAO_ARG(R9) ; ADR USAGE ARG MOVL @QMSG_FAO_ARG(R9),QMSG_FAO_ARG(R9) ; VALUE USAGE ADDL3 QCK_Q_OFFSET(R8),R10,QMSG_FAO_ARG+4(R9) ; ADR QUOTA ARG MOVL @QMSG_FAO_ARG+4(R9),QMSG_FAO_ARG+4(R9) ; VALUE QUOTA RSB_SETMSG: RSB .END