📄 interrupt.cod
字号:
; 370 : //
; 371 : // if we're timing interrupts, keep track of when this one came in
; 372 : //
; 373 : if (fIntrTime)
00064 e59f00d4 ldr r0, [pc, #0xD4]
00068 e5901000 ldr r1, [r0]
0006c e3510000 cmp r1, #0
00070 0a000020 beq |$L14025|
; 374 : {
; 375 : dwIsrTime1 = PerfCountSinceTick();
00074 eb000000 bl PerfCountSinceTick
00078 e59f30bc ldr r3, [pc, #0xBC]
0007c e5830000 str r0, [r3]
; 376 : wNumInterrupts++;
00080 e59f30b0 ldr r3, [pc, #0xB0]
00084 e1d300b0 ldrh r0, [r3]
00088 e1a01800 mov r1, r0, lsl #16
0008c e1a02821 mov r2, r1, lsr #16
00090 e2820001 add r0, r2, #1
00094 e1a01800 mov r1, r0, lsl #16
00098 e1a02821 mov r2, r1, lsr #16
; 377 :
; 378 : //
; 379 : // Not profiling, update the millisecond counter
; 380 : //
; 381 : CurMSec += RESCHED_PERIOD;
0009c e59f1084 ldr r1, [pc, #0x84]
000a0 e1c320b0 strh r2, [r3]
000a4 e5910000 ldr r0, [r1]
; 382 : #if (CE_MAJOR_VER == 0x0003)
; 383 : DiffMSec += RESCHED_PERIOD;
; 384 : #endif
; 385 : dwIntrTimeCountdown--;
000a8 e59f2084 ldr r2, [pc, #0x84]
000ac e2804001 add r4, r0, #1
000b0 e5920000 ldr r0, [r2]
000b4 e5814000 str r4, [r1]
000b8 e2501001 subs r1, r0, #1
000bc e5821000 str r1, [r2]
; 386 :
; 387 : if (dwIntrTimeCountdown == 0)
000c0 1a000008 bne |$L14026|
; 388 : {
; 389 : dwIntrTimeCountdown = dwIntrTimeCountdownRef;
000c4 e59f0064 ldr r0, [pc, #0x64]
; 390 : wNumInterrupts = 0;
000c8 e1c350b0 strh r5, [r3]
000cc e5901000 ldr r1, [r0]
000d0 e5821000 str r1, [r2]
; 391 :
; 392 : dwIsrTime2 = PerfCountSinceTick();
000d4 eb000000 bl PerfCountSinceTick
000d8 e59f304c ldr r3, [pc, #0x4C]
; 393 : retval = SYSINTR_TIMING;
000dc e3a0500a mov r5, #0xA
000e0 e5830000 str r0, [r3]
; 394 : }
; 395 : else
000e4 ea00000b b |$L14032|
000e8 |$L14026|
; 396 : {
; 397 : #if (CE_MAJOR_VER == 0x0003)
; 398 : if (ticksleft || (dwSleepMin && (dwSleepMin <= DiffMSec)) ||
; 399 : (dwPreempt && (dwPreempt <= DiffMSec)))
; 400 : #else
; 401 : if ((int) (CurMSec - dwReschedTime) >= 0)
000e8 e59f0034 ldr r0, [pc, #0x34]
000ec e5901000 ldr r1, [r0]
000f0 e0542001 subs r2, r4, r1
; 402 : #endif
; 403 : {
; 404 : retval = SYSINTR_RESCHED;
; 405 : }
; 406 : }
; 407 : }
; 408 : else
000f4 ea000006 b |$L14243|
000f8 |$L14025|
; 409 : {
; 410 : //
; 411 : // not profiling, update the millisecond counter
; 412 : //
; 413 : CurMSec += RESCHED_PERIOD;
000f8 e59f1028 ldr r1, [pc, #0x28]
000fc e5910000 ldr r0, [r1]
00100 e2802001 add r2, r0, #1
; 414 : #if (CE_MAJOR_VER == 0x0003)
; 415 : DiffMSec += RESCHED_PERIOD;
; 416 : #endif
; 417 :
; 418 : #if (CE_MAJOR_VER == 0x0003)
; 419 : if (ticksleft || (dwSleepMin && (dwSleepMin <= DiffMSec)) ||
; 420 : (dwPreempt && (dwPreempt <= DiffMSec)))
; 421 : #else
; 422 : if ((int) (CurMSec - dwReschedTime) >= 0)
00104 e59f0018 ldr r0, [pc, #0x18]
00108 e5812000 str r2, [r1]
0010c e5901000 ldr r1, [r0]
00110 e0522001 subs r2, r2, r1
00114 |$L14243|
; 423 : #endif
; 424 : {
; 425 : retval = SYSINTR_RESCHED;
00114 53a05001 movpl r5, #1
00118 |$L14032|
; 426 : }
; 427 : }
; 428 : }
; 429 :
; 430 : return retval;
00118 e1a00005 mov r0, r5
; 431 : }
0011c e8bd4030 ldmia sp!, {r4, r5, lr}
00120 e12fff1e bx lr
00124 |$L14248|
00124 00000000 DCD |dwReschedTime|
00128 00000000 DCD |CurMSec|
0012c 00000000 DCD |dwIsrTime2|
00130 00000000 DCD |dwIntrTimeCountdownRef|
00134 00000000 DCD |dwIntrTimeCountdown|
00138 00000000 DCD |wNumInterrupts|
0013c 00000000 DCD |dwIsrTime1|
00140 00000000 DCD |fIntrTime|
00144 00000000 DCD |PProfileInterrupt|
00148 00000000 DCD |dwReschedIncrement|
0014c 00000000 DCD |CurTicks|
00150 |$M14245|
ENDP ; |TimerInterrupt|
EXPORT |OEMInterruptEnable|
EXPORT |??_C@_1EA@LKDN@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| [ DATA ] ; `string'
EXPORT |??_C@_1FC@KJAL@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| [ DATA ] ; `string'
EXPORT |??_C@_1FM@HJGP@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| [ DATA ] ; `string'
IMPORT |NKDbgPrintfW|
IMPORT |INTERRUPTS_ON|
IMPORT |INTERRUPTS_OFF|
00000 AREA |.text| { |OEMInterruptEnable| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 AREA |.pdata$$OEMInterruptEnable|, PDATA, SELECTION=5, ASSOC=|.text| { |OEMInterruptEnable| } ; comdat associative
|$T14261| DCD |OEMInterruptEnable|
DCD 0x40009f01
00000 AREA |.rdata| { |??_C@_1EA@LKDN@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| }, DATA, READONLY, SELECTION=2 ; comdat any
|??_C@_1EA@LKDN@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| DCB "O"
DCB 0x0, "E", 0x0, "M", 0x0, "I", 0x0, "n", 0x0, "t", 0x0, "e"
DCB 0x0, "r", 0x0, "r", 0x0, "u", 0x0, "p", 0x0, "t", 0x0, "E"
DCB 0x0, "n", 0x0, "a", 0x0, "b", 0x0, "l", 0x0, "e", 0x0, ":"
DCB 0x0, " ", 0x0, "S", 0x0, "Y", 0x0, "S", 0x0, "I", 0x0, "N"
DCB 0x0, "T", 0x0, "R", 0x0, "_", 0x0, "I", 0x0, "D", 0x0, "E"
DCB 0x0, 0x0, 0x0 ; `string'
00000 AREA |.rdata| { |??_C@_1FC@KJAL@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| }, DATA, READONLY, SELECTION=2 ; comdat any
|??_C@_1FC@KJAL@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| DCB "O"
DCB 0x0, "E", 0x0, "M", 0x0, "I", 0x0, "n", 0x0, "t", 0x0, "e"
DCB 0x0, "r", 0x0, "r", 0x0, "u", 0x0, "p", 0x0, "t", 0x0, "E"
DCB 0x0, "n", 0x0, "a", 0x0, "b", 0x0, "l", 0x0, "e", 0x0, ":"
DCB 0x0, " ", 0x0, "S", 0x0, "Y", 0x0, "S", 0x0, "I", 0x0, "N"
DCB 0x0, "T", 0x0, "R", 0x0, "_", 0x0, "P", 0x0, "C", 0x0, "M"
DCB 0x0, "C", 0x0, "I", 0x0, "A", 0x0, "_", 0x0, "L", 0x0, "E"
DCB 0x0, "V", 0x0, "E", 0x0, "L", 0x0, 0x0, 0x0 ; `string'
00000 AREA |.rdata| { |??_C@_1FM@HJGP@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| }, DATA, READONLY, SELECTION=2 ; comdat any
|??_C@_1FM@HJGP@?$AAO?$AAE?$AAM?$AAI?$AAn?$AAt?$AAe?$AAr?$AAr?$AAu?$AAp?$AAt?$AAE?$AAn?$AAa?$AAb?$AAl?$AAe?$AA?3?$AA?5@| DCB "O"
DCB 0x0, "E", 0x0, "M", 0x0, "I", 0x0, "n", 0x0, "t", 0x0, "e"
DCB 0x0, "r", 0x0, "r", 0x0, "u", 0x0, "p", 0x0, "t", 0x0, "E"
DCB 0x0, "n", 0x0, "a", 0x0, "b", 0x0, "l", 0x0, "e", 0x0, ":"
DCB 0x0, " ", 0x0, "U", 0x0, "n", 0x0, "k", 0x0, "n", 0x0, "o"
DCB 0x0, "w", 0x0, "n", 0x0, " ", 0x0, "I", 0x0, "n", 0x0, "t"
DCB 0x0, "e", 0x0, "r", 0x0, "r", 0x0, "u", 0x0, "p", 0x0, "t"
DCB 0x0, " ", 0x0, "#", 0x0, "%", 0x0, "0", 0x0, "2", 0x0, "d"
DCB 0x0, 0xd, 0x0, 0xa, 0x0, 0x0, 0x0 ; `string'
; Function compile flags: /Ogsy
00000 AREA |.text| { |OEMInterruptEnable| }, CODE, ARM, SELECTION=1 ; comdat noduplicate
00000 |OEMInterruptEnable| PROC
; 458 : {
00000 e92d4030 stmdb sp!, {r4, r5, lr}
00004 |$M14259|
00004 e1a04000 mov r4, r0
; 459 : BOOL bRet = TRUE;
00008 e3a05001 mov r5, #1
; 460 : // NKDbgPrintfW(L"OEMInterruptEnable: Interrupt #%02d\r\n", idInt);
; 461 :
; 462 :
; 463 : INTERRUPTS_OFF();
0000c eb000000 bl INTERRUPTS_OFF
; 464 : switch(idInt)
; 465 : {
00010 e244300a sub r3, r4, #0xA
00014 e353001e cmp r3, #0x1E
00018 8a000087 bhi |$L14076|
0001c e1a00083 mov r0, r3, lsl #1
00020 e080000f add r0, r0, pc
00024 e1d000b4 ldrh r0, [r0, #4]
00028 e08ff000 add pc, pc, r0
0002c |$L14258|
0002c |$L14257|
0002c 021c DCW 0x21c
0002e 020c DCW 0x20c
00030 020c DCW 0x20c
00032 0128 DCW 0x128
00034 020c DCW 0x20c
00036 020c DCW 0x20c
00038 00dc DCW 0xdc
0003a 0170 DCW 0x170
0003c 020c DCW 0x20c
0003e 01bc DCW 0x1bc
00040 01e4 DCW 0x1e4
00042 020c DCW 0x20c
00044 019c DCW 0x19c
00046 003c DCW 0x3c
00048 005c DCW 0x5c
0004a 007c DCW 0x7c
0004c 009c DCW 0x9c
0004e 00bc DCW 0xbc
00050 00fc DCW 0xfc
00052 0190 DCW 0x190
00054 020c DCW 0x20c
00056 0148 DCW 0x148
00058 0148 DCW 0x148
0005a 0148 DCW 0x148
0005c 0148 DCW 0x148
0005e 0148 DCW 0x148
00060 0148 DCW 0x148
00062 0148 DCW 0x148
00064 0148 DCW 0x148
00066 0148 DCW 0x148
00068 0148 DCW 0x148
; 562 : }
0006a 0148 DCW 0x148
0006c |$L14046|
; 466 : case SYSINTR_TIMING:
; 467 : //
; 468 : // No action necessary
; 469 : //
; 470 : break;
; 471 :
; 472 : case SYSINTR_ETHER:
; 473 : //EdbgOutputDebugString("OEMInterruptEnable:SYSINTR_ETHER\n");
; 474 : *VIC2_INTENABLE = INT2_ETHERNET;
0006c e59f11f0 ldr r1, [pc, #0x1F0]
00070 e3a00080 mov r0, #0x80
; 475 : gdwInterruptMask2 |= INT2_ETHERNET;
00074 e59f21e4 ldr r2, [pc, #0x1E4]
00078 e5810000 str r0, [r1]
0007c e5920000 ldr r0, [r2]
00080 e3801080 orr r1, r0, #0x80
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
00084 e5821000 str r1, [r2]
; 551 : break;
00088 ea00006f b |$L14042|
0008c |$L14048|
; 476 : break;
; 477 :
; 478 : case SYSINTR_USB:
; 479 : *VIC2_INTENABLE = INT2_USB;
0008c e59f11d0 ldr r1, [pc, #0x1D0]
00090 e3a00401 mov r0, #1, 8
; 480 : gdwInterruptMask2 |= INT2_USB;
00094 e59f21c4 ldr r2, [pc, #0x1C4]
00098 e5810000 str r0, [r1]
0009c e5920000 ldr r0, [r2]
000a0 e3801401 orr r1, r0, #1, 8
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
000a4 e5821000 str r1, [r2]
; 551 : break;
000a8 ea000067 b |$L14042|
000ac |$L14050|
; 481 : break;
; 482 :
; 483 : case SYSINTR_UART1:
; 484 : *VIC2_INTENABLE = INT2_UART1;
000ac e59f11b0 ldr r1, [pc, #0x1B0]
000b0 e3a00601 mov r0, #1, 12
; 485 : gdwInterruptMask2 |= INT2_UART1;
000b4 e59f21a4 ldr r2, [pc, #0x1A4]
000b8 e5810000 str r0, [r1]
000bc e5920000 ldr r0, [r2]
000c0 e3801601 orr r1, r0, #1, 12
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
000c4 e5821000 str r1, [r2]
; 551 : break;
000c8 ea00005f b |$L14042|
000cc |$L14052|
; 486 : break;
; 487 :
; 488 : case SYSINTR_UART2:
; 489 : *VIC2_INTENABLE = INT2_UART2;
000cc e59f1190 ldr r1, [pc, #0x190]
000d0 e3a00501 mov r0, #1, 10
; 490 : gdwInterruptMask2 |= INT2_UART2;
000d4 e59f2184 ldr r2, [pc, #0x184]
000d8 e5810000 str r0, [r1]
000dc e5920000 ldr r0, [r2]
000e0 e3801501 orr r1, r0, #1, 10
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
000e4 e5821000 str r1, [r2]
; 551 : break;
000e8 ea000057 b |$L14042|
000ec |$L14054|
; 491 : break;
; 492 :
; 493 : case SYSINTR_UART3:
; 494 : *VIC2_INTENABLE = INT2_UART3;
000ec e59f1170 ldr r1, [pc, #0x170]
000f0 e3a00502 mov r0, #2, 10
; 495 : gdwInterruptMask2 |= INT2_UART3;
000f4 e59f2164 ldr r2, [pc, #0x164]
000f8 e5810000 str r0, [r1]
000fc e5920000 ldr r0, [r2]
00100 e3801502 orr r1, r0, #2, 10
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
00104 e5821000 str r1, [r2]
; 551 : break;
00108 ea00004f b |$L14042|
0010c |$L14056|
; 496 : break;
; 497 :
; 498 : case SYSINTR_KEYBOARD:
; 499 : *VIC1_INTENABLE = INT1_KEYPAD;
0010c e59f115c ldr r1, [pc, #0x15C]
00110 e3a00202 mov r0, #2, 4
; 500 : gdwInterruptMask1 |= INT1_KEYPAD;
00114 e59f2158 ldr r2, [pc, #0x158]
00118 e5810000 str r0, [r1]
0011c e5920000 ldr r0, [r2]
00120 e3801202 orr r1, r0, #2, 4
; 550 : gdwInterruptMask2 |= INT2_GPIO6;
00124 e5821000 str r1, [r2]
; 551 : break;
00128 ea000047 b |$L14042|
0012c |$L14058|
; 501 : break;
; 502 :
; 503 : case SYSINTR_SPI:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -