IDENT 0RF,URFX PERIPH J BASE MIXED SST REL$ SET 0 QUAL$ EQU 1 DEFINE UNQUALIFIED COMMON DECKS *COMMENT 0RF - UPDATE RESOURCE DEMAND FILE. COMMENT COPYRIGHT CONTROL DATA SYSTEMS INC. 1992. TITLE 0RF - UPDATE RESOURCE DEMAND FILE. SPACE 4,10 *** 0RF - UPDATE RESOURCE DEMAND FILE. * M. E. MADDEN. 73/04/01. * W. E. GOEBEL. 76/05/12. * J. L. LARSON. 77/01/17. * J. L. LARSON. 81/12/14. * J. L. LARSON. 82/06/24. SPACE 4,10 *** *0RF* IS A LOCATION FREE ROUTINE USED TO CLEAR * THE RESOURCE DEMAND (RSXDID) FILE ENTRY AT JOB COMPLETION * OR TO UPDATE THE RESOURCE DEMAND FILE ENTRY FOR RETURN * OF A REMOVABLE PACK RESOURCE. * * *0RF* IS CALLED BY *0DF* (RETURN/UNLOAD USER,S LAST * DIRECT ACCESS FILE ON A REMOVABLE PACK), *PFM* (DECREMENT * DEMAND ENTRY FOR *GET* ON REMOVABLE PACK), AND BY *1AJ* * FOR JOB TERMINATION PROCESSING (CLEAR DEMAND FILE ENTRY * ON JOB COMPLETION). SPACE 4,10 *** ENTRY CONDITIONS. * * (FA) = RELATIVE FNT ADDRESS IN NFL. * (FS) = EQ * (FS+1) = X * ((LA)-1) = Y * WHERE LA = LOAD ADDRESS * X = OPTION * 4 = RSXDID ENTRY CLEAR * 5 = RSXDID ENTRY UPDATE FOR RETURN OF * REMOVABLE PACK RESOURCE * Y = RESOURCE UPDATE CONTROL * BIT 0 = 0, IF UPDATING ASSIGNED AND DEMAND * 1, IF NOT UPDATING DEMAND COUNT * EQ = EST ORDINAL FOR RETURN OF REMOVABLE * PACK RESOURCE (OPTION 1). * (FN - FN+4) = PACK NAME, IF RETURN REMOVABLE PACK RESOURCE * AND DEVICE IS CURRENTLY UNAVAILABLE. * * USES DIRECT CELLS 0 - 17. * *BFMS* MS SECTOR BUFFER. SPACE 4,10 *** EXIT CONDITIONS. * * (A) .LT. 0 IF RESOURCE DEMAND FILE DEVICE INACCESSIBLE. * (T5) = EST ORDINAL OF RESOURCE DEMAND FILE. * (FSTL OF FNT) UPDATED IN CM. SPACE 4,10 ** COMMON DECKS. *CALL COMPMAC *CALL COMSCPS *CALL COMSMSP ORG 5 KEEP LOCATIONS UNDER 473B *CALL COMPREL QUAL COMSRSX *CALL COMSRSX QUAL * *CALL COMSZOL SPACE 4,10 **** DIRECT LOCATION ASSIGNMENTS. RI EQU 16 - 17 RANDOM INDEX (2 LOCATIONS) FS EQU 20 - 24 FST INFORMATION (5 LOCATIONS) FN EQU 40 - 44 PACK NAME FA EQU 57 RELATIVE FNT ADDRESS IN NFL SPACE 4,10 * ASSEMBLY CONSTANTS. RPST EQU BFMS+2+/COMSRSX/RRPS*5-500B FWA SHARE TABLE RPSTL EQU BFMS+2+/COMSRSX/RPSL*5 LWA+1 SHARE TABLE TACT EQU BFMS+2+/COMSRSX/RVAL*5+3 TOTAL ASSIGNED COUNT TDCT EQU BFMS+2+/COMSRSX/RVAL*5+4 TOTAL DEMAND COUNT **** TITLE MAIN PROGRAM. URF SPACE 4,10 ** URF - MAIN ROUTINE. ORG 5 URF SUBR ENTRY/EXIT RJM IFP INITIALIZE GLOBAL FNT PROCESSOR * READ RESOURCE DEMAND FILE ENTRY. LDN RDFO FETCH RESOURCE DEMAND FILE FST ENTRY SFA FNT ADN FSTG CRD T5 SETMS IO,RW LDD CM+4 SHN 3 ADN TRLL FETCH TRT POINTER CRD CM LDD T6 PRESERVE FIRST TRACK OF DEMAND FILE STD T3 URF0 ZJN URFX IF FILE UNUSED LDD CM+3 LPN 77 SHN 14 LMD CM+4 PRESET *COMPCRA* SBD TH STM CRAA+1 SHN -14 RAM CRAA * PAUSE AND CHECK FOR OPERATOR OVERRIDE. PSE LDN 20 SET TWO MILLISECOND DELAY STD T1 PSE1 DELAY PAUSE LDD CM+1 CHECK ERROR FLAG LMN ORET ZJN URF0 IF OPERATOR OVERRIDE SOD T1 NJN PSE1 IF NOT END OF DELAY * LDN SFIN ERRNZ SFIN CODE DEPENDS ON VALUE * STD T1 LDN RDFO INTERLOCK DEMAND FILE FNT ENTRY SFA FNT RJM SFI NJN PSE IF INTERLOCK UNAVAILABLE * CALCULATE ENTRY SECTOR NUMBER FOR OPTION. URF1 LCN 2 RAD FS+1 SHN -1 STD T1 LDD CP FETCH DEMAND FILE RANDOM INDEX ADN RFCW CRD CM LDD CM+3 LPN 77 SHN 14 ADD CM+4 ZJN URF6 IF NO RANDOM INDEX ADD T1 BIAS FOR FIRST OR SECOND SECTOR STD RI+1 SHN -14 STD RI RJM CRA CONVERT RANDOM INDEX MJN URF6 IF RANDOM ADDRESS ERROR LDC BFMS RJM. RDS READ SECTOR PJN URF7 IF NO READ ERROR URF3 SHN 21-12 MJN URF4 IF NON-RECOVERABLE ERROR SOM URFA URF4 LCN 0 SET CHANNEL RELEASE WITH NO UPDATE URF5 RJM CLE URF6 LDN CFIN SELECT CLEAR OPTION STD T1 LDN RDFO SFA FNT RJM SFI CLEAR RESOURCE FILE INTERLOCK * LDN 0 URFA ADN 0 SET EXIT CONDITION * LCN 77 (RECOVERABLE MS ERROR ENCOUNTERED) LJM URFX RETURN * DETERMINE TYPE OF PROCESSING. URF7 LDD FS+1 ZJN URF5 IF CLEARING SECTOR 1 ENTRY SBN 2 NJN URF9 IF NOT CLEARING SECTOR 2 ENTRY URF8 RJM CLE LDD T3 RESET FIRST TRACK STD T6 LJM URF1 PROCESS SECTOR 1 URF9 PJN RRP IF UPDATING SHARE TABLE IN SECTOR 2 LJM URC UPDATE RESOURCE COUNTS IN SECTOR 1 RRP SPACE 4,10 ** RRP - RETURN REMOVABLE PACK RESOURCE (OPTION 1). * * EXIT TO *URF8* TO UPDATE SECTOR 2 DEMAND ENTRY. * * ERROR TO *HNG* IF MATCHING SHARE TABLE ENTRY NOT FOUND. * * MACROS SFA. RRP BSS 0 ENTRY LDC RPST-5 SCAN SHARE TABLE ENTRIES STD T2 LDD MA MOVE PACK NAME CWD FN CRD CM LDD FS ZJN RRP1 IF EST ORDINAL NOT SPECIFIED SFA EST ADK EQDE CRD CM LDD CM+4 FETCH PACKNAME FOR SELECTED DEVICE SHN 3 ADN PFGL CRD CM RRP1 LDN 5 CHECK NEXT SHARE TABLE ENTRY RAD T2 STM RRPA ADC -RPSTL NJN RRP2 IF NOT END OF SHARE TABLE ENTRIES LJM HNG HANG PP RRP2 LDI T2 LMD CM NJN RRP1 IF NO MATCH LDM. 1,T2 LMD CM+1 NJN RRP1 IF NO MATCH LDM. 2,T2 LMD CM+2 NJN RRP1 IF NO MATCH LDM. 3,T2 COMPARE LAST CHARACTER LMD CM+3 SCN 77 NJN RRP1 IF NO MATCH LDM. 4,T2 GET RESOURCE POINTER STD FS+3 LDN ZERL CRM. *,ON CLEAR SHARE TABLE ENTRY RRPA EQU *-1 * LDN ZERL+1 LJM URF8 UPDATE SECTOR 2 DEMAND FILE ENTRY URC SPACE 4,10 ** URC - UPDATE RESOURCE COUNTS. * * ENTRY (FS+3) = 3/, 3/UNIT COUNT, 6/RESOURCE INDEX. * * EXIT TO *URF5* TO UPDATE SECTOR 1 DEMAND FILE ENTRY * * ERROR TO *HNG* IF RESOURCE COUNTS INVALID. * * USES T1, T2. URC BSS 0 ENTRY LDD FS+3 CALCULATE RESOURCE BYTE POSITION SHN 14 STD T1 UNIT COUNT SHN -14 STD T2 SHN 2 ADC BFMS+2+5 RAD T2 LDD T1 SBN 5 MJN URC1 IF NOT IN SECOND WORD OF ENTRY ADN 1 ADJUST TO SECOND WORD URC1 RAD T2 * DECREMENT RESOURCE ASSIGNED COUNT AND TOTAL ASSIGNED COUNT. LDC -100 DECREMENT RESOURCE ASSIGNED COUNT RAI T2 MJN HNG IF RESOURCE ASSIGNED COUNT OUT OF RANGE LDM. TDCT CHECK TOTAL DEMAND COUNT = 1 SBN 1 ZJN URC2 IF ONLY ONE CONCURRENT RESOURCE SCHEDULED LDM -1 NJN URC3 IF UNLOAD (DECREMENT ASSIGNED COUNT) * IF ALL DEMANDS SATISFIED, DECREMENT RESOURCE DEMAND COUNT * AND TOTAL DEMAND COUNT. URC2 LDM. TACT CHECK ALL DEMANDS SATISFIED SBM. TDCT MJN URC3 IF NOT ALL DEMANDS SATISFIED SOI T2 DECREMENT RESOURCE DEMAND COUNT SHN 21-5 MJN HNG IF RESOURCE DEMAND COUNT OUT OF RANGE SOM. TDCT DECREMENT TOTAL DEMAND COUNT MJN HNG IF TOTAL DEMAND COUNT NOT IN RANGE URC3 SOM. TACT MJN HNG IF TOTAL ASSIGNED COUNT OUT OF RANGE LDN 1 LJM URF5 UPDATE DEMAND FILE ENTRY AND EXIT HNG SPACE 4,10 ** HNG - HANG PP. * * EXIT TO *URF4* IF PP HANG CLEARED. * * MACROS MONITOR. HNG BSS 0 ENTRY MONITOR HNGM HANG PP LJM URF4 RELEASE CHANNEL AND EXIT TITLE SUBROUTINES. CLE SPACE 4,20 ** CLE - CLEAR/UPDATE FILE ENTRY. * * ENTRY (A) = 0, IF CLEAR FILE ENTRY. * (A) .GT. 0, IF UPDATE FILE ENTRY. * (A) .LT. 0, IF RELEASE CHANNEL WITH NO UPDATE. * (FA) = RELATIVE FNT ADDRESS IN NFL. * (T5 - T7) = RESOURCE DEMAND FILE MS PARAMETERS. * (FS - FS+4) = FST INFORMATION. * (BFMS) = DEMAND FILE ENTRY (MS SECTOR). * * EXIT RESOURCE FILE SECTOR REWRITTEN FROM BFMS BUFFER * FOR ENTRY CONDITION (A) .GE. 0. * * ERROR TO *URF3* IF MASS STORAGE ERROR. * * USES T1, CM - CM+4. * * CALLS WDS. * * MACROS ENDMS, NFA. CLE3 LDD FA ZJN CLE4 IF NO FNT ENTRY NFA FA,R ADN FSTL UPDATE FST INFORMATION CWD FS CLE4 ENDMS CLE SUBR EXTRY/EXIT NJN CLE2 IF UPDATE ONLY LDC 500 STD T1 CLE1 LDN 0 STM. BFMS+1,T1 SOD T1 NJN CLE1 IF MORE TO CLEAR CLE2 MJN CLE4 IF NO UPDATE LDC BFMS+WLSF RJM. WDS WRITE SECTOR PJN CLE3 IF NO ERROR LJM URF3 PROCESS MASS STORAGE ERROR SPACE 4,10 ** COMMON DECKS. IRA$ SET 1 DEFINE INITIALIZATION REL$ SET 1 *CALL COMPCRA FNT$ EQU 1 ASSEMBLE SYSTEM FNT PROCESSOR IFP$ EQU 1 ASSEMBLE REMOTE INITIALIZATION CODE *CALL COMPGFP SFI$ EQU 1 SELECT IMMEDIATE RETURN FROM *SFI* *CALL COMPSFI IFP HERE CODE TO INITIALIZE SYSTEM FNT PROCESSOR SPACE 4,10 RSTR SPACE 4,10 OVERFLOW 5,ZRFL END