Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

68 lines
1.5 KiB

  1. /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  2. Copyright (c) 1991, 1992, 1993 Microsoft Corporation
  3. Module Name:
  4. error.c
  5. Abstract:
  6. This module contains the code that is very specific to error
  7. operations in the serial driver
  8. Author:
  9. Anthony V. Ercolano 26-Sep-1991
  10. Environment:
  11. Kernel mode
  12. Revision History :
  13. -----------------------------------------------------------------------------*/
  14. #include "precomp.h"
  15. #ifdef ALLOC_PRAGMA
  16. #endif
  17. VOID
  18. SerialCommError(IN PKDPC Dpc, IN PVOID DeferredContext, IN PVOID SystemContext1, IN PVOID SystemContext2)
  19. /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  20. Routine Description:
  21. This routine is invoked at dpc level to in response to
  22. a comm error. All comm errors kill all read and writes
  23. Arguments:
  24. Dpc - Not Used.
  25. DeferredContext - Really points to the device object.
  26. SystemContext1 - Not Used.
  27. SystemContext2 - Not Used.
  28. Return Value:
  29. None.
  30. -----------------------------------------------------------------------------*/
  31. {
  32. PPORT_DEVICE_EXTENSION pPort = DeferredContext;
  33. UNREFERENCED_PARAMETER(Dpc);
  34. UNREFERENCED_PARAMETER(SystemContext1);
  35. UNREFERENCED_PARAMETER(SystemContext2);
  36. SerialKillAllReadsOrWrites(pPort->DeviceObject, &pPort->WriteQueue, &pPort->CurrentWriteIrp);
  37. SerialKillAllReadsOrWrites(pPort->DeviceObject, &pPort->ReadQueue, &pPort->CurrentReadIrp);
  38. }