Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

161 lines
4.5 KiB

  1. ; SCCSID = @(#)dossym.asm 1.1 85/04/10
  2. ; SCCSID = @(#)dossym.asm 1.1 85/04/10
  3. ERROR - who uses this? Not DOS and kernel. Whoever uses this
  4. should use DOSSYM instead. See JGL if there's a problem
  5. ; PAGE 80,132
  6. TRUE EQU 0FFFFh
  7. FALSE EQU 0
  8. Installed = TRUE
  9. IFNDEF DEBUG
  10. DEBUG = FALSE
  11. ENDIF
  12. include dosmac.INC
  13. INCLUDE VERSIONA.INC ;DEFINE THE MAJOR AND MINOR VERSION NUMBERS
  14. IF2
  15. ; %OUT DOSSYM in Pass 2
  16. ENDIF
  17. BREAK <Control character definitions>
  18. c_DEL EQU 7Fh ; ASCII rubout or delete previous char
  19. c_BS EQU 08h ; ^H ASCII backspace
  20. c_CR EQU 0Dh ; ^M ASCII carriage return
  21. c_LF EQU 0Ah ; ^J ASCII linefeed
  22. c_ETB EQU 17h ; ^W ASCII end of transmission
  23. c_NAK EQU 15h ; ^U ASCII negative acknowledge
  24. c_ETX EQU 03h ; ^C ASCII end of text
  25. c_HT EQU 09h ; ^I ASCII tab
  26. BREAK <Read This and Weep>
  27. ;----+----+----+----+----+----+----+----+----+----+----+----+----+----+----;
  28. ; ;
  29. ; C A V E A T P R O G R A M M E R ;
  30. ; ;
  31. ; Certain structures, constants and system calls below are private to ;
  32. ; the DOS and are extremely version-dependent. They may change at any ;
  33. ; time at the implementors' whim. As a result, they must not be ;
  34. ; documented to the general public. If an extreme case arises, they ;
  35. ; must be documented with this warning. ;
  36. ; ;
  37. ; Those structures and constants that are subject to the above will be ;
  38. ; marked and bracketed with the flag: ;
  39. ; ;
  40. ; C A V E A T P R O G R A M M E R ;
  41. ; ;
  42. ;----+----+----+----+----+----+----+----+----+----+----+----+----+----+----;
  43. include bpb.INC
  44. include buffer.INC
  45. BREAK <User stack inside of system call and SysVars>
  46. ; Location of user registers relative user stack pointer
  47. user_environ STRUC
  48. user_AX DW ?
  49. user_BX DW ?
  50. user_CX DW ?
  51. user_DX DW ?
  52. user_SI DW ?
  53. user_DI DW ?
  54. user_BP DW ?
  55. user_DS DW ?
  56. user_ES DW ?
  57. user_IP DW ?
  58. user_CS DW ?
  59. user_F DW ?
  60. user_environ ENDS
  61. include sysvar.INC
  62. include vector.INC
  63. ;include mult.INC
  64. BREAK <Disk map>
  65. ; MSDOS partitions the disk into 4 sections:
  66. ;
  67. ; phys sector 0: +-------------------+
  68. ; | | boot/reserved |
  69. ; | +-------------------+
  70. ; | | File allocation |
  71. ; v | table(s) |
  72. ; | (multiple copies |
  73. ; | are kept) |
  74. ; +-------------------+
  75. ; | Directory |
  76. ; +-------------------+
  77. ; | File space |
  78. ; +-------------------+
  79. ; | Unaddressable |
  80. ; | (to end of disk) |
  81. ; +-------------------+
  82. ;
  83. ; All partition boundaries are sector boundaries. The size of the FAT is
  84. ; adjusted to maximize the file space addressable.
  85. include dirent.INC
  86. BREAK <File allocation Table information>
  87. ;
  88. ; The File Allocation Table uses a 12-bit entry for each allocation unit on
  89. ; the disk. These entries are packed, two for every three bytes. The contents
  90. ; of entry number N is found by 1) multiplying N by 1.5; 2) adding the result
  91. ; to the base address of the Allocation Table; 3) fetching the 16-bit word
  92. ; at this address; 4) If N was odd (so that N*1.5 was not an integer), shift
  93. ; the word right four bits; 5) mask to 12 bits (AND with 0FFF hex). Entry
  94. ; number zero is used as an end-of-file trap in the OS and is passed to the
  95. ; BIOS to help determine disk format. Entry 1 is reserved for future use.
  96. ; The first available allocation unit is assigned entry number two, and even
  97. ; though it is the first, is called cluster 2. Entries greater than 0FF8H
  98. ; (12-bit fats) or 0FFF8H (16-bit fats) are end of file marks; entries of zero
  99. ; are unallocated. Otherwise, the contents of a FAT entry is the number of
  100. ; the next cluster in the file.
  101. ;
  102. ; Clusters with bad sectors are tagged with FF7H. Any non-zero number would
  103. ; do because these clusters show as allocated, but are not part of any
  104. ; allocation chain and thus will never be allocated to a file. A particular
  105. ; number is selected so that disk checking programs know what to do (ie. a
  106. ; cluster with entry FF7H which is not in a chain is not an error).
  107. include dpb.INC
  108. include curdir.INC
  109. ;include cpmfcb.INC
  110. ;include find.INC
  111. include pdb.INC
  112. include exe.INC
  113. include sf.INC
  114. include arena.INC
  115. include intnat.INC
  116. include mi.INC
  117. fChk equ 1
  118. fDelim equ 2
  119. fSpChk equ 4
  120. fFCB equ 8
  121. ;include filemode.INC
  122. ;include error.INC
  123. include syscall.INC
  124. include doscntry.inc ;J.K. 5/26/86
  125. SUBTTL
  126.