📄 isr.cod
字号:
; 939 :
; 940 : SerialInsertQueueDpc(
; 941 : &Extension->StartTimerLowerRTSDpc,
; 942 : NULL,
; 943 : NULL,
; 944 : Extension
; 945 : )?Extension->CountOfTryingToLowerRTS++:0;
00462 56 push esi
00463 53 push ebx
00464 8d 86 4c 03 00
00 lea eax, DWORD PTR [esi+844]
0046a 53 push ebx
0046b 50 push eax
0046c e8 00 00 00 00 call _SerialInsertQueueDpc@16
00471 84 c0 test al, al
00473 74 23 je SHORT $L15022
00475 ff 86 3c 01 00
00 inc DWORD PTR [esi+316]
; 946 :
; 947 : } else {
0047b eb 1b jmp SHORT $L15022
$L15012:
; 948 :
; 949 : Extension->PerfStats.TransmittedCount++;
; 950 : Extension->WmiPerfData.TransmittedCount++;
; 951 : WRITE_TRANSMIT_HOLDING(
; 952 : Extension->Controller,
; 953 : Extension->ImmediateChar
; 954 : );
0047d 8a 86 d8 01 00
00 mov al, BYTE PTR [esi+472]
00483 ff 86 88 01 00
00 inc DWORD PTR [esi+392]
00489 ff 86 1c 06 00
00 inc DWORD PTR [esi+1564]
0048f 50 push eax
00490 ff b6 98 00 00
00 push DWORD PTR [esi+152]
00496 ff d7 call edi
$L15022:
; 955 :
; 956 : }
; 957 :
; 958 : Extension->HoldingEmpty = FALSE;
00498 80 a6 a0 01 00
00 00 and BYTE PTR [esi+416], 0
; 959 :
; 960 : SerialInsertQueueDpc(
; 961 : &Extension->CompleteImmediateDpc,
; 962 : NULL,
; 963 : NULL,
; 964 : Extension
; 965 : );
0049f 56 push esi
004a0 53 push ebx
004a1 53 push ebx
004a2 8d 86 cc 02 00
00 lea eax, DWORD PTR [esi+716]
$L15313:
004a8 50 push eax
004a9 e8 00 00 00 00 call _SerialInsertQueueDpc@16
; 966 :
; 967 : } else if (!Extension->TXHolding) {
004ae e9 63 fd ff ff jmp $L14916
$L15008:
004b3 39 9e 1c 01 00
00 cmp DWORD PTR [esi+284], ebx
004b9 0f 85 57 fd ff
ff jne $L14916
; 968 :
; 969 : ULONG amountToWrite;
; 970 :
; 971 : if (Extension->FifoPresent) {
004bf 80 be dd 01 00
00 00 cmp BYTE PTR [esi+477], 0
004c6 74 14 je SHORT $L15029
; 972 :
; 973 : amountToWrite = (Extension->TxFifoAmount <
; 974 : Extension->WriteLength)?
; 975 : Extension->TxFifoAmount:
; 976 : Extension->WriteLength;
004c8 8b 86 50 01 00
00 mov eax, DWORD PTR [esi+336]
004ce 8b be e0 00 00
00 mov edi, DWORD PTR [esi+224]
004d4 3b c7 cmp eax, edi
004d6 73 07 jae SHORT $L15030
004d8 8b f8 mov edi, eax
004da eb 03 jmp SHORT $L15030
$L15029:
; 977 :
; 978 : } else {
; 979 :
; 980 : amountToWrite = 1;
004dc 33 ff xor edi, edi
004de 47 inc edi
$L15030:
; 981 :
; 982 : }
; 983 : if ((Extension->HandFlow.FlowReplace &
; 984 : SERIAL_RTS_MASK) ==
; 985 : SERIAL_TRANSMIT_TOGGLE) {
004df 8b 86 78 01 00
00 mov eax, DWORD PTR [esi+376]
004e5 66 25 c0 00 and ax, 192 ; 000000c0H
004e9 3c c0 cmp al, 192 ; 000000c0H
004eb 75 6a jne SHORT $L15033
; 986 :
; 987 : //
; 988 : // We have to raise if we're sending
; 989 : // this character.
; 990 : //
; 991 :
; 992 : SerialSetRTS(Extension);
004ed 56 push esi
004ee e8 00 00 00 00 call _SerialSetRTS@4
; 993 :
; 994 : if (amountToWrite == 1) {
004f3 83 ff 01 cmp edi, 1
004f6 75 23 jne SHORT $L15034
; 995 :
; 996 : Extension->PerfStats.TransmittedCount++;
; 997 : Extension->WmiPerfData.TransmittedCount++;
; 998 : WRITE_TRANSMIT_HOLDING(
; 999 : Extension->Controller,
; 1000 : *(Extension->WriteCurrentChar)
; 1001 : );
004f8 8b 86 e4 00 00
00 mov eax, DWORD PTR [esi+228]
004fe ff 86 88 01 00
00 inc DWORD PTR [esi+392]
00504 ff 86 1c 06 00
00 inc DWORD PTR [esi+1564]
0050a 8a 00 mov al, BYTE PTR [eax]
0050c 50 push eax
0050d ff b6 98 00 00
00 push DWORD PTR [esi+152]
00513 ff 15 00 00 00
00 call DWORD PTR __imp__WRITE_PORT_UCHAR@8
; 1002 :
; 1003 : } else {
00519 eb 1f jmp SHORT $L15042
$L15034:
; 1004 :
; 1005 : Extension->PerfStats.TransmittedCount +=
; 1006 : amountToWrite;
0051b 01 be 88 01 00
00 add DWORD PTR [esi+392], edi
; 1007 : Extension->WmiPerfData.TransmittedCount +=
; 1008 : amountToWrite;
00521 01 be 1c 06 00
00 add DWORD PTR [esi+1564], edi
; 1009 : WRITE_TRANSMIT_FIFO_HOLDING(
; 1010 : Extension->Controller,
; 1011 : Extension->WriteCurrentChar,
; 1012 : amountToWrite
; 1013 : );
00527 57 push edi
00528 ff b6 e4 00 00
00 push DWORD PTR [esi+228]
0052e ff b6 98 00 00
00 push DWORD PTR [esi+152]
00534 ff 15 00 00 00
00 call DWORD PTR __imp__WRITE_PORT_BUFFER_UCHAR@12
$L15042:
; 1014 :
; 1015 : }
; 1016 :
; 1017 : SerialInsertQueueDpc(
; 1018 : &Extension->StartTimerLowerRTSDpc,
; 1019 : NULL,
; 1020 : NULL,
; 1021 : Extension
; 1022 : )?Extension->CountOfTryingToLowerRTS++:0;
0053a 56 push esi
0053b 6a 00 push 0
0053d 8d 86 4c 03 00
00 lea eax, DWORD PTR [esi+844]
00543 6a 00 push 0
00545 50 push eax
00546 e8 00 00 00 00 call _SerialInsertQueueDpc@16
0054b 84 c0 test al, al
0054d 74 4f je SHORT $L15055
0054f ff 86 3c 01 00
00 inc DWORD PTR [esi+316]
; 1023 :
; 1024 : } else {
00555 eb 47 jmp SHORT $L15055
$L15033:
; 1025 :
; 1026 : if (amountToWrite == 1) {
00557 83 ff 01 cmp edi, 1
0055a 75 23 jne SHORT $L15047
; 1027 :
; 1028 : Extension->PerfStats.TransmittedCount++;
; 1029 : Extension->WmiPerfData.TransmittedCount++;
; 1030 : WRITE_TRANSMIT_HOLDING(
; 1031 : Extension->Controller,
; 1032 : *(Extension->WriteCurrentChar)
; 1033 : );
0055c 8b 86 e4 00 00
00 mov eax, DWORD PTR [esi+228]
00562 ff 86 88 01 00
00 inc DWORD PTR [esi+392]
00568 ff 86 1c 06 00
00 inc DWORD PTR [esi+1564]
0056e 8a 00 mov al, BYTE PTR [eax]
00570 50 push eax
00571 ff b6 98 00 00
00 push DWORD PTR [esi+152]
00577 ff 15 00 00 00
00 call DWORD PTR __imp__WRITE_PORT_UCHAR@8
; 1034 :
; 1035 : } else {
0057d eb 1f jmp SHORT $L15055
$L15047:
; 1036 :
; 1037 : Extension->PerfStats.TransmittedCount +=
; 1038 : amountToWrite;
0057f 01 be 88 01 00
00 add DWORD PTR [esi+392], edi
; 1039 : Extension->WmiPerfData.TransmittedCount +=
; 1040 : amountToWrite;
00585 01 be 1c 06 00
00 add DWORD PTR [esi+1564], edi
; 1041 : WRITE_TRANSMIT_FIFO_HOLDING(
; 1042 : Extension->Controller,
; 1043 : Extension->WriteCurrentChar,
; 1044 : amountToWrite
; 1045 : );
0058b 57 push edi
0058c ff b6 e4 00 00
00 push DWORD PTR [esi+228]
00592 ff b6 98 00 00
00 push DWORD PTR [esi+152]
00598 ff 15 00 00 00
00 call DWORD PTR __imp__WRITE_PORT_BUFFER_UCHAR@12
$L15055:
; 1046 :
; 1047 : }
; 1048 :
; 1049 : }
; 1050 :
; 1051 : Extension->HoldingEmpty = FALSE;
0059e 80 a6 a0 01 00
00 00 and BYTE PTR [esi+416], 0
; 1052 : Extension->WriteCurrentChar += amountToWrite;
005a5 01 be e4 00 00
00 add DWORD PTR [esi+228], edi
; 1053 : Extension->WriteLength -= amountToWrite;
005ab 29 be e0 00 00
00 sub DWORD PTR [esi+224], edi
; 1054 :
; 1055 : if (!Extension->WriteLength) {
005b1 0f 85 5f fc ff
ff jne $L14916
; 1056 :
; 1057 : PIO_STACK_LOCATION IrpSp;
; 1058 : //
; 1059 : // No More characters left. This
; 1060 : // write is complete. Take care
; 1061 : // when updating the information field,
; 1062 : // we could have an xoff counter masquerading
; 1063 : // as a write irp.
; 1064 : //
; 1065 :
; 1066 : IrpSp = IoGetCurrentIrpStackLocation(
; 1067 : Extension->CurrentWriteIrp
; 1068 : );
005b7 8b 86 c8 00 00
00 mov eax, DWORD PTR [esi+200]
005bd 8b 48 60 mov ecx, DWORD PTR [eax+96]
; 1069 :
; 1070 : Extension->CurrentWriteIrp->
; 1071 : IoStatus.Information =
; 1072 : (IrpSp->MajorFunction == IRP_MJ_WRITE)?
; 1073 : (IrpSp->Parameters.Write.Length):
; 1074 : (1);
005c0 80 39 04 cmp BYTE PTR [ecx], 4
005c3 75 05 jne SHORT $L15276
005c5 8b 49 04 mov ecx, DWORD PTR [ecx+4]
005c8 eb 03 jmp SHORT $L15277
$L15276:
005ca 33 c9 xor ecx, ecx
005cc 41 inc ecx
$L15277:
; 1075 :
; 1076 : SerialInsertQueueDpc(
; 1077 : &Extension->CompleteWriteDpc,
; 1078 : NULL,
; 1079 : NULL,
; 1080 : Extension
; 1081 : );
005cd 56 push esi
005ce 89 48 1c mov DWORD PTR [eax+28], ecx
005d1 6a 00 push 0
005d3 6a 00 push 0
005d5 8d 86 ec 01 00
00 lea eax, DWORD PTR [esi+492]
; 1082 :
; 1083 : }
; 1084 :
; 1085 : }
; 1086 :
; 1087 : }
; 1088 :
; 1089 : break;
005db e9 c8 fe ff ff jmp $L15313
$L14893:
; 425 :
; 426 :
; 427 : //
; 428 : // We got an interrupt with the device being closed or when the
; 429 : // device is supposed to be powered down. This
; 430 : // is not unlikely with a serial device. We just quietly
; 431 : // keep servicing the causes until it calms down.
; 432 : //
; 433 :
; 434 : ServicedAnInterrupt = TRUE;
005e0 8b 3d 00 00 00
00 mov edi, DWORD PTR __imp__READ_PORT_UCHAR@4
005e6 c6 45 0f 01 mov BYTE PTR _ServicedAnInterrupt$[ebp], 1
$L14894:
; 435 : do {
; 436 :
; 437 : InterruptIdReg &= (~SERIAL_IIR_FIFOS_ENABLED);
005ea 83 e3 3f and ebx, 63 ; 0000003fH
; 438 : switch (InterruptIdReg) {
005ed 83 eb 00 sub ebx, 0
005f0 74 46 je SHORT $L14906
005f2 4b dec ebx
005f3 4b dec ebx
005f4 74 39 je SHORT $L14905
005f6 4b dec ebx
005f7 4b dec ebx
005f8 74 2d je SHORT $L14903
005fa 4b dec ebx
005fb 4b
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -