Leaked source code of windows server 2003
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.

197 lines
4.0 KiB

  1. /*++
  2. Copyright (c) 1992 Microsoft Corporation
  3. Module Name:
  4. spntfix.h
  5. Abstract:
  6. initializing and maintaining list of nts to repair
  7. Author:
  8. Shie-Lin Tzong (shielint) 6-Feb-1994
  9. Revision History:
  10. --*/
  11. #ifndef _SPNTFIX_H_
  12. #define _SPNTFIX_H_
  13. //
  14. // Repair items -
  15. // defines the items which setup can repair
  16. // Note, the ordering must be the same as SP_REPAIR_MENU_ITEM_x defined in msg.mc.
  17. typedef enum {
  18. // RepairHives, // BCL - Seagate: hives will not be in the menu.
  19. RepairNvram,
  20. RepairFiles,
  21. #if defined(_AMD64_) || defined(_X86_)
  22. RepairBootSect,
  23. #endif // defined(_AMD64_) || defined(_X86_)
  24. RepairItemMax
  25. } RepairItem;
  26. //
  27. // The hives that repair cares about. We pass around the keys to the hives
  28. // in an array. Use the following enum values to access
  29. // the hive members
  30. // Note, the ordering of the hives must be the same as SP_REPAIE_HIVE_ITEM_x
  31. // defined in msg.mc.
  32. //
  33. typedef enum {
  34. RepairHiveSystem,
  35. RepairHiveSoftware,
  36. RepairHiveDefault,
  37. RepairHiveUser,
  38. RepairHiveSecurity,
  39. RepairHiveSam,
  40. RepairHiveMax
  41. } RepairHive;
  42. //
  43. // Public functions
  44. //
  45. BOOLEAN
  46. SpDisplayRepairMenu(
  47. VOID
  48. );
  49. BOOLEAN
  50. SpFindNtToRepair(
  51. IN PVOID SifHandle,
  52. OUT PDISK_REGION *TargetRegion,
  53. OUT PWSTR *TargetPath,
  54. OUT PDISK_REGION *SystemPartitionRegion,
  55. OUT PWSTR *SystemPartitionDirectory,
  56. OUT PBOOLEAN RepairableBootSetsFound
  57. );
  58. VOID
  59. SpRepairWinnt(
  60. IN PVOID LogFileHandle,
  61. IN PVOID MasterSifHandle,
  62. IN PWSTR SourceDevicePath,
  63. IN PWSTR DirectoryOnSourceDevice
  64. );
  65. VOID
  66. SpRepairDiskette(
  67. OUT PVOID *SifHandle,
  68. OUT PDISK_REGION *TargetRegion,
  69. OUT PWSTR *TargetPath,
  70. OUT PDISK_REGION *SystemPartitionRegion,
  71. OUT PWSTR *SystemPartitionDirectory
  72. );
  73. BOOLEAN
  74. SpLoadRepairLogFile(
  75. IN PWCHAR Filename,
  76. OUT PVOID *Handle
  77. );
  78. BOOLEAN
  79. SpErDiskScreen (
  80. BOOLEAN *HasErDisk
  81. );
  82. //
  83. // Private functions
  84. //
  85. BOOLEAN
  86. SppSelectNTSingleRepair(
  87. IN PDISK_REGION Region,
  88. IN PWSTR OsLoadFileName,
  89. IN PWSTR LoadIdentifier
  90. );
  91. BOOLEAN
  92. SppSelectNTMultiRepair(
  93. OUT PSP_BOOT_ENTRY *BootSetChosen
  94. );
  95. BOOLEAN
  96. SppRepairReportError(
  97. IN BOOLEAN AllowEsc,
  98. IN ULONG ErrorScreenId,
  99. IN ULONG SubErrorId,
  100. IN PWSTR SectionName,
  101. IN ULONG LineNumber,
  102. IN PBOOLEAN DoNotPromptAgain
  103. );
  104. VOID
  105. SppVerifyAndRepairFiles(
  106. IN PVOID LogFileHandle,
  107. IN PVOID MasterSifHandle,
  108. IN PWSTR SectionName,
  109. IN PWSTR SourceDevicePath,
  110. IN PWSTR DirectoryOnSourceDevice,
  111. IN PWSTR TargetDevicePath,
  112. IN PWSTR DirectoryOnTargetDevice,
  113. IN BOOLEAN SystemPartitionFiles,
  114. IN OUT PBOOLEAN RepairWithoutConfirming
  115. );
  116. VOID
  117. SppVerifyAndRepairNtTreeAccess(
  118. IN PVOID MasterSifHandle,
  119. IN PWSTR TargetDevicePath,
  120. IN PWSTR DirectoryOnTargetDevice,
  121. IN PWSTR SystemPartition,
  122. IN PWSTR SystemPartitionDirectory
  123. );
  124. VOID
  125. SppVerifyAndRepairVdmFiles(
  126. IN PVOID LogFileHandle,
  127. IN PWSTR TargetDevicePath,
  128. IN PWSTR DirectoryOnTargetDevice,
  129. IN OUT PBOOLEAN RepairWithoutConfirming
  130. );
  131. VOID
  132. SppGetRepairPathInformation(
  133. IN PVOID LogFileHandle,
  134. OUT PWSTR *SystemPartition,
  135. OUT PWSTR *SystemPartitionDirectory,
  136. OUT PWSTR *WinntPartition,
  137. OUT PWSTR *WinntPartitionDirectory
  138. );
  139. //
  140. // External functions
  141. //
  142. extern
  143. VOID
  144. SpCopyFilesScreenRepaint(
  145. IN PWSTR FullSourcename, OPTIONAL
  146. IN PWSTR FullTargetname, OPTIONAL
  147. IN BOOLEAN RepaintEntireScreen
  148. );
  149. //
  150. // External data references
  151. //
  152. extern PVOID RepairGauge;
  153. extern ULONG RepairItems[RepairItemMax];
  154. extern BOOLEAN RepairFromErDisk;
  155. extern PVOID Gbl_HandleToSetupLog;
  156. extern PWSTR Gbl_SystemPartitionName;
  157. extern PWSTR Gbl_SystemPartitionDirectory;
  158. extern PWSTR Gbl_BootPartitionName;
  159. extern PWSTR Gbl_BootPartitionDirectory;
  160. #endif // for _SPNTFIX_H_