Skip to content

Commit 292a376

Browse files
[FREELDR:APPLETV] Implement DiskGetConfigType for Apple TV platform
1 parent c000c1a commit 292a376

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

boot/freeldr/freeldr/arch/i386/appletv/appletvdisk.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,16 @@ ULONG FrldrBootPartition = 1; // Partition 1
2424

2525
/* FUNCTIONS *****************************************************************/
2626

27+
CONFIGURATION_TYPE
28+
DiskGetConfigType(
29+
_In_ UCHAR DriveNumber)
30+
{
31+
if ((DriveNumber == FrldrBootDrive)/* && DiskIsDriveRemovable(DriveNumber) */ && (FrldrBootPartition == 0xFF))
32+
return CdromController; /* This is our El Torito boot CD-ROM */
33+
else
34+
return DiskPeripheral;
35+
}
36+
2737
VOID
2838
AppleTVDiskInit(VOID)
2939
{

boot/freeldr/freeldr/include/arch/appletv/machappletv.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,3 +61,7 @@ VOID AppleTVBeep(VOID);
6161
extern UCHAR FrldrBootDrive;
6262
extern ULONG FrldrBootPartition;
6363
LONG DiskReportError(BOOLEAN bShowError);
64+
65+
CONFIGURATION_TYPE
66+
DiskGetConfigType(
67+
_In_ UCHAR DriveNumber);

0 commit comments

Comments
 (0)