- Merge 25417 by hpoussin (Disable some boot options on non-x86 platforms. You can enable them again for specific platforms if needed).

- Minor: Add debug_filesystem into DEBUG_CUSTOM, but commented out.

svn path=/branches/winldr/; revision=26874
This commit is contained in:
Aleksey Bragin
2007-05-23 21:11:35 +00:00
parent 27c1dc25f5
commit 83d5ae8eb4
10 changed files with 32 additions and 4 deletions
+4
View File
@@ -119,11 +119,14 @@ NoGui:
}
// Install the drive mapper according to this sections drive mappings
#ifdef __i386__
DriveMapMapDrivesInSection(OperatingSystemSectionNames[SelectedOperatingSystem]);
#endif
if (_stricmp(SettingValue, "ReactOS") == 0)
{
LoadAndBootReactOS(OperatingSystemSectionNames[SelectedOperatingSystem]);
}
#ifdef __i386__
else if (_stricmp(SettingValue, "WindowsNT40") == 0)
{
LoadAndBootWindows(OperatingSystemSectionNames[SelectedOperatingSystem], _WIN32_WINNT_NT4);
@@ -156,6 +159,7 @@ NoGui:
{
LoadAndBootDrive(OperatingSystemSectionNames[SelectedOperatingSystem]);
}
#endif
}
+13 -1
View File
@@ -33,7 +33,15 @@ const CHAR CustomBootPrompt[] = "Press ENTER to boot your custom boot setup.";
VOID OptionMenuCustomBoot(VOID)
{
PCSTR CustomBootMenuList[] = { "Disk", "Partition", "Boot Sector File", "ReactOS", "Linux" };
PCSTR CustomBootMenuList[] = {
#ifdef __i386__
"Disk",
"Partition",
"Boot Sector File",
"ReactOS",
"Linux"
#endif /* __i386__ */
};
ULONG CustomBootMenuCount = sizeof(CustomBootMenuList) / sizeof(CustomBootMenuList[0]);
ULONG SelectedMenuItem;
@@ -45,6 +53,7 @@ VOID OptionMenuCustomBoot(VOID)
switch (SelectedMenuItem)
{
#ifdef __i386__
case 0: // Disk
OptionMenuCustomBootDisk();
break;
@@ -60,9 +69,11 @@ VOID OptionMenuCustomBoot(VOID)
case 4: // Linux
OptionMenuCustomBootLinux();
break;
#endif /* __i386__ */
}
}
#ifdef __i386__
VOID OptionMenuCustomBootDisk(VOID)
{
CHAR SectionName[100];
@@ -397,3 +408,4 @@ VOID OptionMenuCustomBootLinux(VOID)
LoadAndBootLinux(SectionName, "Custom Linux Setup");
}
#endif /* __i386__ */
+1 -1
View File
@@ -38,7 +38,7 @@ ULONG DebugPrintMask = DPRINT_INIFILE;
#elif defined (DEBUG_REACTOS)
ULONG DebugPrintMask = DPRINT_REACTOS | DPRINT_REGISTRY;
#elif defined (DEBUG_CUSTOM)
ULONG DebugPrintMask = DPRINT_WARNING | DPRINT_MEMORY |
ULONG DebugPrintMask = DPRINT_WARNING | DPRINT_MEMORY | /*DPRINT_FILESYSTEM |*/
DPRINT_REACTOS | DPRINT_WINDOWS | DPRINT_HWDETECT;
#else //#elif defined (DEBUG_NONE)
ULONG DebugPrintMask = 0;
+2
View File
@@ -22,6 +22,7 @@
#define NDEBUG
#include <debug.h>
#ifdef __i386__
BOOLEAN DriveMapInstalled = FALSE; // Tells us if we have already installed our drive map int 13h handler code
ULONG OldInt13HandlerAddress = 0; // Address of BIOS int 13h handler
ULONG DriveMapHandlerAddress = 0; // Linear address of our drive map handler
@@ -222,3 +223,4 @@ VOID DriveMapRemoveInt13Handler(VOID)
DriveMapInstalled = FALSE;
}
}
#endif /* __i386__ */
+2 -1
View File
@@ -20,7 +20,7 @@
#ifndef __DRIVEMAP_H
#define __DRIVEMAP_H
#ifdef __i386__
typedef struct
{
UCHAR DriveMapCount; // Count of drives currently mapped
@@ -39,5 +39,6 @@ extern PVOID DriveMapInt13HandlerStart;
extern PVOID DriveMapInt13HandlerEnd;
extern ULONG DriveMapOldInt13HandlerAddress;
extern DRIVE_MAP_LIST DriveMapInt13HandlerMapList;
#endif /* __i386__ */
#endif // #defined __DRIVEMAP_H
+2 -1
View File
@@ -22,7 +22,7 @@
#ifndef __LINUX_H
#define __LINUX_H
#ifdef __i386__
#define LINUX_LOADER_TYPE_LILO 0x01
#define LINUX_LOADER_TYPE_LOADLIN 0x11
#define LINUX_LOADER_TYPE_BOOTSECT 0x21
@@ -135,5 +135,6 @@ BOOLEAN LinuxReadSetupSector(PFILE LinuxKernelFile);
BOOLEAN LinuxReadKernel(PFILE LinuxKernelFile);
BOOLEAN LinuxCheckKernelVersion(VOID);
BOOLEAN LinuxReadInitrd(PFILE LinuxInitrdFile);
#endif /* __i386__ */
#endif // defined __LINUX_H
+2
View File
@@ -20,8 +20,10 @@
#ifndef __BOOT_H
#define __BOOT_H
#ifdef __i386__
VOID LoadAndBootBootSector(PCSTR OperatingSystemName);
VOID LoadAndBootPartition(PCSTR OperatingSystemName);
VOID LoadAndBootDrive(PCSTR OperatingSystemName);
#endif /* __i386__ */
#endif // defined __BOOT_H
+2
View File
@@ -25,10 +25,12 @@ VOID DoOptionsMenu(VOID);
VOID OptionMenuReboot(VOID);
VOID OptionMenuCustomBoot(VOID);
#ifdef __i386__
VOID OptionMenuCustomBootDisk(VOID);
VOID OptionMenuCustomBootPartition(VOID);
VOID OptionMenuCustomBootBootSectorFile(VOID);
VOID OptionMenuCustomBootReactOS(VOID);
VOID OptionMenuCustomBootLinux(VOID);
#endif /* __i386__ */
#endif // #defined __OPTIONS_H
+2
View File
@@ -23,6 +23,7 @@
#define NDEBUG
#include <debug.h>
#ifdef __i386__
#define LINUX_READ_CHUNK_SIZE 0x20000 // Read 128k at a time
@@ -491,3 +492,4 @@ BOOLEAN LinuxReadInitrd(PFILE LinuxInitrdFile)
return TRUE;
}
#endif /* __i386__ */
+2
View File
@@ -19,6 +19,7 @@
#include <freeldr.h>
#ifdef __i386__
VOID LoadAndBootBootSector(PCSTR OperatingSystemName)
{
PFILE FilePointer;
@@ -213,3 +214,4 @@ VOID LoadAndBootDrive(PCSTR OperatingSystemName)
//DisableA20();
ChainLoadBiosBootSectorCode();
}
#endif /* __i386__ */