Source code of Windows XP (NT5)
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.

110 lines
4.1 KiB

  1. /*++
  2. Copyright (C) Microsoft Corporation, 1993 - 1998
  3. Module Name:
  4. ecp.h
  5. Abstract:
  6. This module contains utility code used by other 1284
  7. ecp modules (currently swecp, hwecp, and becp).
  8. Author:
  9. Robbie Harris (Hewlett-Packard) 28-May-1998
  10. Environment:
  11. Kernel mode
  12. Revision History :
  13. --*/
  14. #ifndef _ECP_
  15. #define _ECP_
  16. #define DEFAULT_ECP_CHANNEL 0
  17. NTSTATUS
  18. ParEcpEnterReversePhase(
  19. IN PDEVICE_EXTENSION Extension
  20. );
  21. NTSTATUS
  22. ParEcpExitReversePhase(
  23. IN PDEVICE_EXTENSION Extension
  24. );
  25. NTSTATUS
  26. ParEcpSetupPhase(
  27. IN PDEVICE_EXTENSION Extension
  28. );
  29. #define ParTestEcpWrite(X) \
  30. (X->CurrentPhase != PHASE_FORWARD_IDLE && X->CurrentPhase != PHASE_FORWARD_XFER) \
  31. ? STATUS_IO_DEVICE_ERROR : STATUS_SUCCESS
  32. // ==================================================================
  33. // The following RECOVER codes are used for Hewlett-Packard devices.
  34. // Do not remove any of the error codes. These recover codes are
  35. // used to quickly get the host and periph back to a known state.
  36. // When using a recover code, add a comment where it is used at...
  37. #define RECOVER_0 0 // Reserved - not used anywhere
  38. #define RECOVER_1 1 // ECP_Terminate
  39. #define RECOVER_2 2 // SLP_SetupPhase init
  40. #define RECOVER_3 3 // SLP_FTP init DCR
  41. #define RECOVER_4 4 // SLP_FTP init DSR
  42. #define RECOVER_5 5 // SLP_FTP data xfer DCR
  43. #define RECOVER_6 6 // SLP_FRP init DCR
  44. #define RECOVER_7 7 // SLP_FRP init DSR
  45. #define RECOVER_8 8 // SLP_FRP state 38 DCR
  46. #define RECOVER_9 9 // SLP_FRP state 39 DCR
  47. #define RECOVER_10 10 // SLP_FRP state 40 DSR
  48. #define RECOVER_11 11 // SLP_RTP init DCR
  49. #define RECOVER_12 12 // SLP_RTP init DSR
  50. #define RECOVER_13 13 // SLP_RTP state 43 DCR
  51. #define RECOVER_14 14 // SLP_RFP init DCR
  52. #define RECOVER_15 15 // SLP_RFP init DSR
  53. #define RECOVER_16 16 // SLP_RFP state 47- DCR
  54. #define RECOVER_17 17 // SLP_RFP state 47 DCR
  55. #define RECOVER_18 18 // SLP_RFP state 48 DSR
  56. #define RECOVER_19 19 // SLP_RFP state 49 DSR
  57. #define RECOVER_20 20 // ZIP_EmptyFifo DCR
  58. #define RECOVER_21 21 // ZIP_FTP init DCR
  59. #define RECOVER_22 22 // ZIP_FTP init DSR
  60. #define RECOVER_23 23 // ZIP_FTP data xfer DCR
  61. #define RECOVER_24 24 // ZIP_FRP init DSR
  62. #define RECOVER_25 25 // ZIP_FRP init DCR
  63. #define RECOVER_26 26 // ZIP_FRP state 38 DCR
  64. #define RECOVER_27 27 // ZIP_FRP state 39 DCR
  65. #define RECOVER_28 28 // ZIP_FRP state 40 DSR
  66. #define RECOVER_29 29 // ZIP_FRP state 41 DCR
  67. #define RECOVER_30 30 // ZIP_RTP init DSR
  68. #define RECOVER_31 31 // ZIP_RTP init DCR
  69. #define RECOVER_32 32 // ZIP_RFP init DSR
  70. #define RECOVER_33 33 // ZIP_RFP init DCR
  71. #define RECOVER_34 34 // ZIP_RFP state 47- DCR
  72. #define RECOVER_35 35 // ZIP_RFP state 47 DCR
  73. #define RECOVER_36 36 // ZIP_RFP state 48 DSR
  74. #define RECOVER_37 37 // ZIP_RFP state 49 DSR
  75. #define RECOVER_38 38 // ZIP_RFP state 49+ DCR
  76. #define RECOVER_39 39 // Slippy_Terminate
  77. #define RECOVER_40 40 // ZIP_SCA init DCR
  78. #define RECOVER_41 41 // ZIP_SCA init DSR
  79. #define RECOVER_42 42 // SLP_SCA init DCR
  80. #define RECOVER_43 43 // SLP_SCA init DSR
  81. #define RECOVER_44 44 // ZIP_SP init DCR
  82. #define RECOVER_45 45 // SIP_FRP init DSR
  83. #define RECOVER_46 46 // SIP_FRP init DCR
  84. #define RECOVER_47 47 // SIP_FRP state 38 DCR
  85. #define RECOVER_48 48 // SIP_FRP state 39 DCR
  86. #define RECOVER_49 49 // SIP_FRP state 40 DSR
  87. #define RECOVER_50 50 // SIP_RTP init DCR
  88. #define RECOVER_51 51 // SIP_RFP init DSR
  89. #define RECOVER_52 52 // SIP_RFP state 43 DCR
  90. #endif