mirror of
https://github.com/reactos/reactos.git
synced 2024-09-05 18:26:53 +00:00
30 lines
719 B
C
30 lines
719 B
C
/*
|
|
* COPYRIGHT: See COPYING in the top level directory
|
|
* PROJECT: Serial port driver
|
|
* FILE: drivers/dd/serial/close.c
|
|
* PURPOSE: Serial IRP_MJ_CLOSE operations
|
|
*
|
|
* PROGRAMMERS: Hervé Poussineau (hpoussin@reactos.org)
|
|
*/
|
|
|
|
#include "serial.h"
|
|
|
|
#include <debug.h>
|
|
|
|
NTSTATUS NTAPI
|
|
SerialClose(
|
|
IN PDEVICE_OBJECT DeviceObject,
|
|
IN PIRP Irp)
|
|
{
|
|
PSERIAL_DEVICE_EXTENSION pDeviceExtension;
|
|
|
|
TRACE_(SERIAL, "IRP_MJ_CLOSE\n");
|
|
pDeviceExtension = (PSERIAL_DEVICE_EXTENSION)DeviceObject->DeviceExtension;
|
|
pDeviceExtension->IsOpened = FALSE;
|
|
|
|
Irp->IoStatus.Information = 0;
|
|
Irp->IoStatus.Status = STATUS_SUCCESS;
|
|
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
|
return STATUS_SUCCESS;
|
|
}
|