2014-02-06 11:18:34 +00:00
|
|
|
#ifndef _ISAPNP_PCH_
|
|
|
|
#define _ISAPNP_PCH_
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
#include <wdm.h>
|
2007-07-06 20:25:30 +00:00
|
|
|
|
2001-05-01 23:00:05 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2009-08-24 17:12:25 +00:00
|
|
|
#define TAG_ISAPNP 'PNPI'
|
2007-07-06 20:25:30 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
typedef enum {
|
|
|
|
dsStopped,
|
|
|
|
dsStarted
|
|
|
|
} ISAPNP_DEVICE_STATE;
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
typedef struct _ISAPNP_COMMON_EXTENSION {
|
|
|
|
PDEVICE_OBJECT Self;
|
|
|
|
BOOLEAN IsFdo;
|
|
|
|
ISAPNP_DEVICE_STATE State;
|
|
|
|
} ISAPNP_COMMON_EXTENSION, *PISAPNP_COMMON_EXTENSION;
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
typedef struct _ISAPNP_FDO_EXTENSION {
|
|
|
|
ISAPNP_COMMON_EXTENSION Common;
|
|
|
|
PDEVICE_OBJECT Ldo;
|
|
|
|
PDEVICE_OBJECT Pdo;
|
|
|
|
LIST_ENTRY DeviceListHead;
|
|
|
|
ULONG DeviceCount;
|
|
|
|
PUCHAR ReadDataPort;
|
|
|
|
KSPIN_LOCK Lock;
|
|
|
|
} ISAPNP_FDO_EXTENSION, *PISAPNP_FDO_EXTENSION;
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
typedef struct _ISAPNP_LOGICAL_DEVICE {
|
|
|
|
ISAPNP_COMMON_EXTENSION Common;
|
2001-05-01 23:00:05 +00:00
|
|
|
USHORT VendorId;
|
2010-04-07 20:19:29 +00:00
|
|
|
USHORT ProdId;
|
|
|
|
USHORT IoAddr;
|
|
|
|
UCHAR IrqNo;
|
|
|
|
UCHAR CSN;
|
|
|
|
UCHAR LDN;
|
2001-05-01 23:00:05 +00:00
|
|
|
LIST_ENTRY ListEntry;
|
2010-04-07 20:19:29 +00:00
|
|
|
} ISAPNP_LOGICAL_DEVICE, *PISAPNP_LOGICAL_DEVICE;
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
/* isapnp.c */
|
2013-05-09 14:06:21 +00:00
|
|
|
|
|
|
|
DRIVER_INITIALIZE DriverEntry;
|
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
DriverEntry(
|
|
|
|
IN PDRIVER_OBJECT DriverObject,
|
|
|
|
IN PUNICODE_STRING RegistryPath);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaForwardIrpSynchronous(
|
|
|
|
IN PISAPNP_FDO_EXTENSION FdoExt,
|
|
|
|
IN PIRP Irp);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
/* fdo.c */
|
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaFdoPnp(
|
|
|
|
IN PISAPNP_FDO_EXTENSION FdoExt,
|
|
|
|
IN PIRP Irp,
|
|
|
|
IN PIO_STACK_LOCATION IrpSp);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
/* pdo.c */
|
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaPdoPnp(
|
|
|
|
IN PISAPNP_LOGICAL_DEVICE LogDev,
|
|
|
|
IN PIRP Irp,
|
|
|
|
IN PIO_STACK_LOCATION IrpSp);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
/* hardware.c */
|
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaHwDetectReadDataPort(
|
|
|
|
IN PISAPNP_FDO_EXTENSION FdoExt);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaHwFillDeviceList(
|
|
|
|
IN PISAPNP_FDO_EXTENSION FdoExt);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2010-04-07 20:19:29 +00:00
|
|
|
NTSTATUS
|
|
|
|
NTAPI
|
|
|
|
IsaHwDeactivateDevice(
|
|
|
|
IN PISAPNP_LOGICAL_DEVICE LogicalDevice);
|
2001-05-01 23:00:05 +00:00
|
|
|
|
2005-10-06 21:39:18 +00:00
|
|
|
NTSTATUS
|
2008-11-30 11:16:55 +00:00
|
|
|
NTAPI
|
2010-04-07 20:19:29 +00:00
|
|
|
IsaHwActivateDevice(
|
|
|
|
IN PISAPNP_LOGICAL_DEVICE LogicalDevice);
|
2005-10-06 21:39:18 +00:00
|
|
|
|
2001-05-01 23:00:05 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
2014-02-06 11:18:34 +00:00
|
|
|
|
|
|
|
#endif /* _ISAPNP_PCH_ */
|