Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygenserial.c
Go to the documentation of this file.
00001 /* 00002 * COPYRIGHT: See COPYING in the top level directory 00003 * PROJECT: Serial driver 00004 * FILE: drivers/dd/serial/serial.c 00005 * PURPOSE: Serial driver loading/unloading 00006 * 00007 * PROGRAMMERS: Hervé Poussineau (hpoussin@reactos.org) 00008 */ 00009 00010 #include "serial.h" 00011 00012 static DRIVER_UNLOAD DriverUnload; 00013 DRIVER_INITIALIZE DriverEntry; 00014 00015 static VOID NTAPI 00016 DriverUnload(IN PDRIVER_OBJECT DriverObject) 00017 { 00018 // nothing to do here yet 00019 } 00020 00021 /* 00022 * Standard DriverEntry method. 00023 */ 00024 NTSTATUS NTAPI 00025 DriverEntry( 00026 IN PDRIVER_OBJECT DriverObject, 00027 IN PUNICODE_STRING RegPath) 00028 { 00029 ULONG i; 00030 00031 DriverObject->DriverUnload = DriverUnload; 00032 DriverObject->DriverExtension->AddDevice = SerialAddDevice; 00033 00034 for (i = 0; i <= IRP_MJ_MAXIMUM_FUNCTION; i++) 00035 DriverObject->MajorFunction[i] = ForwardIrpAndForget; 00036 DriverObject->MajorFunction[IRP_MJ_CREATE] = SerialCreate; 00037 DriverObject->MajorFunction[IRP_MJ_CLOSE] = SerialClose; 00038 DriverObject->MajorFunction[IRP_MJ_CLEANUP] = SerialCleanup; 00039 DriverObject->MajorFunction[IRP_MJ_READ] = SerialRead; 00040 DriverObject->MajorFunction[IRP_MJ_WRITE] = SerialWrite; 00041 DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = SerialDeviceControl; 00042 DriverObject->MajorFunction[IRP_MJ_QUERY_INFORMATION] = SerialQueryInformation; 00043 DriverObject->MajorFunction[IRP_MJ_PNP] = SerialPnp; 00044 DriverObject->MajorFunction[IRP_MJ_POWER] = SerialPower; 00045 00046 return STATUS_SUCCESS; 00047 } Generated on Sat May 26 2012 04:17:47 for ReactOS by
1.7.6.1
|