/* INCLUDES ******************************************************************/
#include <ntoskrnl.h>
-#include <ntos/bootvid.h>
-#include <ddk/ntbootvid.h>
+#include "../../drivers/base/bootvid/ntbootvid.h"
#define NDEBUG
#include <internal/debug.h>
+#if defined (ALLOC_PRAGMA)
+#pragma alloc_text(INIT, InbvEnableBootDriver)
+#endif
+
/* GLOBALS *******************************************************************/
{
NTSTATUS Status;
OBJECT_ATTRIBUTES ObjectAttributes;
- UNICODE_STRING BootVidName;
+ UNICODE_STRING BootVidName = RTL_CONSTANT_STRING(L"\\Device\\BootVid");
- RtlRosInitUnicodeStringFromLiteral(&BootVidName, L"\\Device\\BootVid");
InitializeObjectAttributes(&ObjectAttributes,
&BootVidName,
0,
/* Notify the hal we will acquire the display. */
HalAcquireDisplayOwnership(InbvResetDisplayParameters);
- Status = NtDeviceIoControlFile(BootVidDevice,
+ Status = ZwDeviceIoControlFile(BootVidDevice,
NULL,
NULL,
NULL,
}
else
{
- Status = NtDeviceIoControlFile(BootVidDevice,
+ Status = ZwDeviceIoControlFile(BootVidDevice,
NULL,
NULL,
NULL,
BootVidDriverInstalled = FALSE;
/* Notify the hal we have released the display. */
HalReleaseDisplayOwnership();
-
- NtClose(BootVidDevice);
- BootVidDevice = NULL;
}
+
+ ZwClose(BootVidDevice);
+ BootVidDevice = NULL;
}