Table of Contents

ALLOC Source

References

Source Listing

ALLOC.COPY.txt
  1. *COPY ALLOC 00001000
  2. PUSH PRINT 00001200
  3. AIF ('&SYSPARM' NE 'SUP').ALL01 00001400
  4. PRINT OFF,NOGEN 00001600
  5. .ALL01 ANOP 00001800
  6. OWNDLIST DSECT 00004000
  7. SPACE 00005000
  8. *** OWNDLIST - CP OWNED VOLUME LIST 00006000
  9. * 00007000
  10. * 0 +-----------------------------------+-----------+ 00008000
  11. * | OWNDVSER | OWNDRDEV | 00009000
  12. * 8 +-----------------------------------+-----------+ 00010000
  13. * 00011000
  14. *** OWNDLIST - CP OWNED VOLUME LIST 00012000
  15. SPACE 00015000
  16. OWNDVSER DS CL6 VOLUME SERIAL NUMBER 00016000
  17. OWNDRDEV DS 1H DISPLACEMENT OF RDEVBLOK FOR THE VOLUME 00017000
  18. ORG OWNDRDEV 00018000
  19. OWNDPREF DS 1H ALLOCATION PREFERENCE 00019000
  20. EJECT 00020000
  21. ALOCBLOK DSECT 00021000
  22. SPACE 1 00022000
  23. *** ALOCBLOK - DASD CYLINDER ALLOCATION BLOCK 00023000
  24. * 00024000
  25. * 0 +-----------------------+-----------+-----------+ 00025000
  26. * | ALOCPNT | ALOCUSED | ALOCMAX | 00026000
  27. * 8 +-----------+-----------+-----------+-----------+ 00026500
  28. * | ALOCNTMP | | 00027000
  29. * 10 +-----------+-----------------------------------+ 00027500
  30. * | | 00028000
  31. * = ALOCMAP = 00029000
  32. * | | 00030000
  33. * +-----------------------------------------------+ 00031000
  34. * 00032000
  35. *** ALOCBLOK - DASD CYLINDER ALLOCATION BLOCK 00033000
  36. SPACE 1 00034000
  37. ALOCPNT DS 1F POINTER TO NEXT ALOCBLOK ON CHAIN 00035000
  38. ALOCUSED DS 1H NUMBER OF CYLINDERS CURRENTLY IN USE 00036000
  39. ALOCMAX DS 1H MAXIMUM NUMBER OF CYLINDERS AVAILABLE 00037000
  40. ALOCNTMP DS 1H NO. OF NON-TEMP CYLINDERS 00037250
  41. DS 3H RESERVED FOR IBM USE 00037500
  42. ALOCMAP DS 0F CYLINDER ALLOCATION BIT MAP 00038000
  43. SPACE 1 00039000
  44. * BITS DEFINED IN ALOCMAP 00040000
  45. * BIT = 0 - CYLINDER IS AVAILABLE 00041000
  46. * BIT = 1 - CYLINDER HAS BEEN ASSIGNED 00042000
  47. SPACE 1 00043000
  48. * NOTE THAT THE SIZE OF THE ALOCMAP IS VARIABLE AND DEPENDS ON 00044000
  49. * THE NUMBER OF CYLINDERS ON THE DEVICE. GENERALLY, THE SIZE 00045000
  50. * OF THE ALOCBLOK IS GIVEN BY THE FORMULA 00046000
  51. * 00047000
  52. * ALOCSIZE(DOUBLE WORDS) = ((ALOCMAX+63)/64)+2 00047500
  53. * = (NO OF CYLS / BITS PER DOUBLEWORD) + HEADER 00048000
  54. * 00049000
  55. * WHERE ALOCMAX FOR 2314 = 203, FOR 3340 = (35MB=349,70MB=698), 00050100
  56. * FOR 3330 MODEL 1 = 404, FOR 3330 MODEL 11 = 808, 00050200
  57. * FOR 3350 = 555, FOR 2305 MODEL 1 = 48 AND MODEL 2 = 96 00050300
  58. * ANY BITS IN THE MAP THAT REPRESENT CYLINDERS NOT PRESENT ON 00052000
  59. * THE DEVICE ARE SET TO ONE 00053000
  60. SPACE 1 00054000
  61. * FOR TDISK ALLOCATION BLOCKS 00055000
  62. ORG ALOCUSED 00056000
  63. ALOCCYL1 DS 1H FIRST CYLINDER OF TDISK AREA 00057000
  64. ALOCCYL2 DS 1H LAST CYLINDER OF TDISK AREA 00058000
  65. SPACE 1 00059000
  66. * BYTES DEFINED IN ALOCMAP 00060000
  67. * BYTE = X'00' - CYLINDER IS AVAILABLE 00061000
  68. * BYTE = X'AA' - CYLINDER HAS BEEN ALLOCATED 00062000
  69. SPACE 1 00063000
  70. * NOTE THAT THE SIZE OF THE TDISK ALOCMAP IS VARIABLE AND 00064000
  71. * DEPENDS ON THE NUMBER OF CYLINDERS IN THE RANGE ALOCCYL1 TO 00065000
  72. * ALOCCYL2. GENERALLY, THE SIZE OF A GIVEN BLOK IS GIVEN BY 00066000
  73. * THE FORMULA 00067000
  74. * ALOCSIZE(DOUBLE WORDS) = ((ALOCCYL2-ALOCCYL1+1+7)/8)+2 00067500
  75. * = (NO OF CYLS (INCLUSIVE) / BYTES PER DOUBLEWORD) + HEADER 00068000
  76. * ALOCSIZE(DOUBLE WORDS) = ((ALOCCYL2-ALOCCYL1+8)/8)+1 00069000
  77. * 00070000
  78. * BYTES FOR CYLINDERS NOT AVAILABLE WILL BE MARKED ALLOCATED 00071000
  79. EJECT 00072000
  80. RECBLOK DSECT 00073000
  81. SPACE 1 00074000
  82. *** RECBLOK - DASD PAGE ALLOCATION BLOCK 00075000
  83. * 00076000
  84. * 0 +-----------------------+-----------+-----+-----+ 00077000
  85. * | RECPNT | RECCYL | R*1 | R*2 | 00078000
  86. * 8 +-----------------------+-----------+-----+-----+ 00079000
  87. * | RECMAP | 00080000
  88. * | (192 pages max) | C106DK 00081300
  89. * 20 +-----------------------------------------------+ C106DK 00081400
  90. * 00082000
  91. *** RECBLOK - DASD PAGE ALLOCATION BLOCK 00083000
  92. SPACE 1 00086000
  93. RECPNT DS 1F POINTER TO NEXT RECBLOK ON CHAIN 00087000
  94. RECCYL DS 1H CYLINDER ADDRESS FOR PAGES IN THIS BLOCK 00088000
  95. RECUSED DS 1X R*1 NUMBER OF PAGES CURRENTLY IN USE 00089000
  96. RECMAX DS 1X R*2 MAXIMUM NUMBER OF PAGES AVAILABLE 00090000
  97. RECMAP DS CL24 Page allocation bit map HRC106DK 00091200
  98. SPACE 1 00092000
  99. RECSIZE EQU (*-RECBLOK)/8 RECBLOK SIZE IN DOUBLE WORDS 00093000
  100. SPACE 1 00094000
  101. * BITS DEFINED IN RECMAP 00095000
  102. * BIT = 0 - PAGE IS AVAILABLE 00096000
  103. * BIT = 1 - PAGE HAS BEEN ASSIGNED 00097000
  104. * 00098000
  105. * NOTE THAT ALTHOUGH THE SIZE OF RECMAP IS FIXED, THE MAXIMUM 00099000
  106. * NUMBER OF PAGES AVAILABLE ON A CYLINDER IS DEVICE DEPENDENT 00100000
  107. * ANY PAGES THAT ARE NOT PHYSICALLY PRESENT ON A CYLINDER 00101000
  108. * WILL HAVE THEIR CORRESPONDING BITS SET TO ONE 00102000
  109. EJECT 00103000
  110. POP PRINT 00104000
  111. SPACE 00105000