ReactOS 0.4.15-dev-8241-g63935f8
pnp.c
Go to the documentation of this file.
1/*
2 * PROJECT: VFAT Filesystem
3 * LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
4 * PURPOSE: Plug & Play handlers
5 * COPYRIGHT: Copyright 2010-2015 Pierre Schweitzer <pierre@reactos.org>
6 */
7
8/* INCLUDES *****************************************************************/
9
10#include "vfat.h"
11
12#define NDEBUG
13#include <debug.h>
14
15/* FUNCTIONS ****************************************************************/
16
19 PVFAT_IRP_CONTEXT IrpContext)
20{
21 PVCB Vcb = NULL;
23
24 /* PRECONDITION */
25 ASSERT(IrpContext);
26
27 switch (IrpContext->Stack->MinorFunction)
28 {
34 break;
35
36 default:
38 Vcb = (PVCB)IrpContext->Stack->DeviceObject->DeviceExtension;
39 IrpContext->Flags &= ~IRPCONTEXT_COMPLETE;
40 Status = IoCallDriver(Vcb->StorageDevice, IrpContext->Irp);
41 }
42
43 return Status;
44}
LONG NTSTATUS
Definition: precomp.h:26
struct _VCB * PVCB
Definition: fatstruc.h:557
#define NULL
Definition: types.h:112
#define IRPCONTEXT_COMPLETE
Definition: ntfs.h:475
NTSTATUS VfatPnp(PVFAT_IRP_CONTEXT IrpContext)
Definition: pnp.c:18
Status
Definition: gdiplustypes.h:25
#define ASSERT(a)
Definition: mode.c:44
#define IRP_MN_SURPRISE_REMOVAL
Definition: ntifs_ex.h:408
#define IoSkipCurrentIrpStackLocation(Irp)
Definition: ntifs_ex.h:421
#define IoCallDriver
Definition: irp.c:1225
#define STATUS_NOT_IMPLEMENTED
Definition: ntstatus.h:239
#define Vcb
Definition: cdprocs.h:1415
ULONG Flags
Definition: vfat.h:586
PIO_STACK_LOCATION Stack
Definition: vfat.h:588
PVOID DeviceExtension
Definition: env_spec_w32.h:418
PDEVICE_OBJECT DeviceObject
Definition: iotypes.h:3223
Definition: cdstruc.h:498
#define IRP_MN_REMOVE_DEVICE
#define IRP_MN_CANCEL_REMOVE_DEVICE
#define IRP_MN_QUERY_REMOVE_DEVICE