#include <freeldr.h>
#include <debug.h>
Go to the source code of this file.
◆ DBG_DEFAULT_CHANNEL()
DBG_DEFAULT_CHANNEL |
( |
DISK |
| ) |
|
◆ DriveMapGetBiosDriveNumber()
UCHAR DriveMapGetBiosDriveNumber |
( |
PCSTR |
DeviceName | ) |
|
Definition at line 66 of file drivemap.c.
67{
68 UCHAR BiosDriveNumber = 0;
69
71
72
73
75 {
77 }
78
79
80
82
83
86 {
87 BiosDriveNumber |= 0x80;
88 }
89
90 return BiosDriveNumber;
91}
UINT32 strtoul(const char *String, char **Terminator, UINT32 Base)
_Check_return_ int __cdecl atoi(_In_z_ const char *_Str)
_Must_inspect_result_ _In_ PWDFDEVICE_INIT _In_opt_ PCUNICODE_STRING DeviceName
◆ DriveMapIsValidDriveString()
Definition at line 34 of file drivemap.c.
35{
37
38
39 if ((
strlen(DriveString) < 3) ||
40 ((DriveString[0] != 'f') && (DriveString[0] != 'F') &&
41 (DriveString[0] != 'h') && (DriveString[0] != 'H')) ||
42 ((DriveString[1] != 'd') && (DriveString[1] != 'D')))
43 {
45 }
46
47
48
50 {
51 if (DriveString[
Index] <
'0' || DriveString[
Index] >
'9')
52 {
54 }
55 }
56
57
58 if ((
atoi(&DriveString[2]) < 0) || (
atoi(&DriveString[2]) > 0xff))
59 {
61 }
62
64}
ACPI_SIZE strlen(const char *String)
_In_ WDFCOLLECTION _In_ ULONG Index