[BOOT] Improve TODO comments

This commit is contained in:
Quinn Stephens 2024-09-01 09:36:09 -04:00
parent 75197cc8b5
commit a32d72be1e
4 changed files with 12 additions and 8 deletions

View File

@ -206,6 +206,9 @@ Return Value:
} }
BootDevice->Size = sizeof(BOOT_DEVICE); BootDevice->Size = sizeof(BOOT_DEVICE);
//
// Memory map devices are treated as ramdisks.
//
if (DevicePathType(EfiDevicePath) == HARDWARE_DEVICE_PATH && DevicePathSubType(EfiDevicePath) == HW_MEMMAP_DP) { if (DevicePathType(EfiDevicePath) == HARDWARE_DEVICE_PATH && DevicePathSubType(EfiDevicePath) == HW_MEMMAP_DP) {
MemmapNode = (MEMMAP_DEVICE_PATH *)EfiDevicePath; MemmapNode = (MEMMAP_DEVICE_PATH *)EfiDevicePath;
BlockDevice = &BootDevice->Block; BlockDevice = &BootDevice->Block;
@ -218,7 +221,7 @@ Return Value:
} }
// //
// TODO: Only media devices and ramdisks are currently supported. // TODO: Support more devices than just HDD/CD-ROM and ramdisks.
// //
DeviceNode = EfiInitpGetDeviceNode(EfiDevicePath); DeviceNode = EfiInitpGetDeviceNode(EfiDevicePath);
if (DevicePathType(DeviceNode) != MEDIA_DEVICE_PATH) { if (DevicePathType(DeviceNode) != MEDIA_DEVICE_PATH) {
@ -547,7 +550,7 @@ Return Value:
// //
// Convert the EFI file path into a boot file path option. // Convert the EFI file path into a boot file path option.
// TODO: UDP/PXE are not supported. // TODO: Support UDP/PXE boot.
// //
PrevOption = Option; PrevOption = Option;
Option = (PBOOT_APPLICATION_OPTION)((PUCHAR)&Entry->Options + OptionsSize); Option = (PBOOT_APPLICATION_OPTION)((PUCHAR)&Entry->Options + OptionsSize);
@ -561,7 +564,7 @@ Return Value:
BufferRemaining -= Size; BufferRemaining -= Size;
// //
// TODO: Additional options in LoadOptions are not parsed. // TODO: Parse additional options from LoadOptions.
// //
PrevOption = Option; PrevOption = Option;
Option = (PBOOT_APPLICATION_OPTION)((PUCHAR)&Entry->Options + OptionsSize); Option = (PBOOT_APPLICATION_OPTION)((PUCHAR)&Entry->Options + OptionsSize);

View File

@ -572,7 +572,7 @@ Return Value:
} }
// //
// TODO: Account for possible MDL changes due to EfiFreePages(EfiBuffer). // TODO: Account for possible MDL changes due to freeing EfiBuffer.
// //
exit: exit:

View File

@ -41,7 +41,7 @@ Return Value:
{ {
// //
// TODO: Implement this. // TODO: Implement this routine.
// //
return STATUS_SUCCESS; return STATUS_SUCCESS;

View File

@ -83,7 +83,7 @@ Return Value:
} }
// //
// TODO: Incomplete. // TODO: Implement the rest of this routine.
// //
ConsolePrint(L"MmMdpHasPrecedence() is incomplete\r\n"); ConsolePrint(L"MmMdpHasPrecedence() is incomplete\r\n");
return TRUE; return TRUE;
@ -441,7 +441,7 @@ Return Value:
} }
// //
// TODO: Finish this function. // TODO: Implement the rest of this routine.
// //
return STATUS_SUCCESS; return STATUS_SUCCESS;
@ -490,7 +490,7 @@ Return Value:
// //
// Free the descriptor from the heap. // Free the descriptor from the heap.
// TODO: Use BlMmFreeHeap() // TODO: Use BlMmFreeHeap().
// //
ConsolePrint(L"MmMdFreeDescriptor(): need BlMmFreeHeap() to free descriptor\r\n"); ConsolePrint(L"MmMdFreeDescriptor(): need BlMmFreeHeap() to free descriptor\r\n");
return STATUS_NOT_IMPLEMENTED; return STATUS_NOT_IMPLEMENTED;
@ -565,6 +565,7 @@ Return Value:
PMEMORY_DESCRIPTOR Descriptor; PMEMORY_DESCRIPTOR Descriptor;
if (MmGlobalMemoryDescriptorsUsed >= MmGlobalMemoryDescriptorCount) { if (MmGlobalMemoryDescriptorsUsed >= MmGlobalMemoryDescriptorCount) {
DebugPrint(L"MmMdInitDescriptor(): No free descriptors available\r\n");
return NULL; return NULL;
} }