ReactOS 0.4.15-dev-8245-gd24675b
processr.c
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Generic CPU Driver
3 * LICENSE: GNU GPLv2 only as published by the Free Software Foundation
4 * FILE: drivers/processor/processr/processr.c
5 * PURPOSE: Main Driver Routines
6 * PROGRAMMERS: Eric Kohl <eric.kohl@reactos.org>
7 */
8
9/* INCLUDES *******************************************************************/
10
11#include "processr.h"
12
13#define NDEBUG
14#include <debug.h>
15
16
17/* FUNCTIONS ******************************************************************/
18
19static
20VOID
24{
25 DPRINT("ProcessorUnload()\n");
26}
27
28
29static
34 IN PIRP Irp)
35{
36// PIO_STACK_LOCATION IrpSp;
37// NTSTATUS Status = Irp->IoStatus.Status;
38 PDEVICE_EXTENSION DeviceExtension = DeviceObject->DeviceExtension;
39
40 DPRINT("ProcessorPower()\n");
41
42// IrpSp = IoGetCurrentIrpStackLocation(Irp);
43
46 return PoCallDriver(DeviceExtension->LowerDevice, Irp);
47}
48
49
55{
56 DPRINT("Processr: DriverEntry()\n");
57
58 DriverObject->MajorFunction[IRP_MJ_PNP] = ProcessorPnp;
60
61 DriverObject->DriverExtension->AddDevice = ProcessorAddDevice;
62 DriverObject->DriverUnload = ProcessorUnload;
63
64 return STATUS_SUCCESS;
65}
LONG NTSTATUS
Definition: precomp.h:26
#define IRP_MJ_PNP
Definition: cdrw_usr.h:52
_In_ PIRP Irp
Definition: csq.h:116
DRIVER_INITIALIZE DriverEntry
Definition: condrv.c:21
NTSTATUS NTAPI ProcessorAddDevice(IN PDRIVER_OBJECT DriverObject, IN PDEVICE_OBJECT Pdo)
Definition: pnp.c:364
NTSTATUS NTAPI ProcessorPnp(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
Definition: pnp.c:262
#define IoSkipCurrentIrpStackLocation(Irp)
Definition: ntifs_ex.h:421
VOID NTAPI PoStartNextPowerIrp(IN PIRP Irp)
Definition: power.c:758
static NTSTATUS NTAPI ProcessorPower(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
Definition: processr.c:32
static VOID NTAPI ProcessorUnload(IN PDRIVER_OBJECT DriverObject)
Definition: processr.c:22
#define STATUS_SUCCESS
Definition: shellext.h:65
#define DPRINT
Definition: sndvol32.h:73
#define NTAPI
Definition: typedefs.h:36
#define IN
Definition: typedefs.h:39
_In_ PDEVICE_OBJECT DeviceObject
Definition: wdfdevice.h:2055
_Must_inspect_result_ _In_ PDRIVER_OBJECT _In_ PCUNICODE_STRING RegistryPath
Definition: wdfdriver.h:215
_Must_inspect_result_ _In_ PDRIVER_OBJECT DriverObject
Definition: wdfdriver.h:213
#define IRP_MJ_POWER