CPCAP

From MILEDROPEDIA
Revision as of 11:13, 30 August 2010 by XVilka (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

it is a Motorola's name of Power Manager chip (TWL5030 for our phones)

<syntaxhighligiht lang="asm"> ROM:8F31C666  ; =============== S U B R O U T I N E ======================================= ROM:8F31C666 ROM:8F31C666  ; Attributes: noreturn ROM:8F31C666 ROM:8F31C666  ; int __fastcall pcap_init() ROM:8F31C666 pcap_init  ; CODE XREF: hardware_init+1E�p ROM:8F31C666 000 10 B5 PUSH {R4,LR}  ; Push registers ROM:8F31C668 008 59 A0 ADR R0, comments_0_msg  ; "\r\n************* \r\n" ROM:8F31C66A 008 01 F0 F6 F9 BL log_write  ; Branch with Link ROM:8F31C66E 008 5D A0 ADR R0, CPCAP_INIT_MSG  ; "CPCAP_init( ) \r\n" ROM:8F31C670 008 01 F0 F3 F9 BL log_write  ; Branch with Link ROM:8F31C674 008 60 A0 ADR R0, comments_1_msg  ; "************* \r\n" ROM:8F31C676 008 01 F0 F0 F9 BL log_write  ; Branch with Link ROM:8F31C67A 008 05 F0 2F FE BL spi_read_write_3  ; Branch with Link ROM:8F31C67E 008 FF F7 EA FE BL check_ULPI_and_VBUS  ; Branch with Link ROM:8F31C682 008 FF F7 53 FF BL pcap_init_key  ; Branch with Link ROM:8F31C686  ; --------------------------------------------------------------------------- ROM:8F31C686 008 80 21 MOVS R1, #0x80  ; Rd = Op2 ROM:8F31C688 008 60 48 LDR R0, =0x8FB52188  ; Load from Memory ROM:8F31C68A 008 0D F0 56 EA BLX memclr_1  ; Branch with Link and Exchange (immediate address) ROM:8F31C68E 008 10 BD POP {R4,PC}  ; Pop registers ROM:8F31C68E  ; End of function pcap_init ROM:8F31C68E </syntaxhightlight>

<syntaxhighligiht lang="asm"> ROM:8F31C52C  ; =============== S U B R O U T I N E ======================================= ROM:8F31C52C ROM:8F31C52C  ; Attributes: noreturn ROM:8F31C52C ROM:8F31C52C  ; void __fastcall pcap_init_key() ROM:8F31C52C pcap_init_key  ; CODE XREF: pcap_init+1C�p ROM:8F31C52C 000 10 B5 PUSH {R4,LR}  ; Push registers ROM:8F31C52E 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C532 008 46 F2 38 41 MOVW R1, #0x6438  ; arg_2 ROM:8F31C536 008 40 F2 83 10 MOVW R0, #0x183  ; arg_1 ROM:8F31C53A 008 FF F7 A7 FF BL pcap_send_something  ; Branch with Link ROM:8F31C53E 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C542 008 28 21 MOVS R1, #0x28  ; arg_2 ROM:8F31C544 008 4F F4 C5 70 MOV.W R0, #0x18A  ; arg_1 ROM:8F31C548 008 FF F7 A0 FF BL pcap_send_something  ; Branch with Link ROM:8F31C54C 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C550 008 40 F2 01 11 MOVW R1, #0x101  ; arg_2 ROM:8F31C554 008 0C 20 MOVS R0, #0xC  ; arg_1 ROM:8F31C556 008 FF F7 99 FF BL pcap_send_something  ; Branch with Link ROM:8F31C55A 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C55E 008 40 F2 39 51 MOVW R1, #0x539  ; arg_2 ROM:8F31C562 008 40 F2 87 10 MOVW R0, #0x187  ; arg_1 ROM:8F31C566 008 FF F7 91 FF BL pcap_send_something  ; Branch with Link ROM:8F31C56A 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C56E 008 40 F2 01 21 MOVW R1, #0x201  ; arg_2 ROM:8F31C572 008 40 F2 81 10 MOVW R0, #0x181  ; arg_1 ROM:8F31C576 008 FF F7 89 FF BL pcap_send_something  ; Branch with Link ROM:8F31C57A 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C57E 008 C4 21 MOVS R1, #0xC4  ; arg_2 ROM:8F31C580 008 4F F4 C1 70 MOV.W R0, #0x182  ; arg_1 ROM:8F31C584 008 FF F7 82 FF BL pcap_send_something  ; Branch with Link ROM:8F31C588 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C58C 008 13 21 MOVS R1, #0x13  ; arg_2 ROM:8F31C58E 008 40 F2 8D 10 MOVW R0, #0x18D  ; arg_1 ROM:8F31C592 008 FF F7 7B FF BL pcap_send_something  ; Branch with Link ROM:8F31C596 008 01 20 MOVS R0, #1  ; pause_size ROM:8F31C598 008 FF F7 24 FD BL delay  ; Branch with Link ROM:8F31C59C 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5A0 008 4F F4 A2 71 MOV.W R1, #0x144  ; arg_2 ROM:8F31C5A4 008 40 F2 9B 10 MOVW R0, #0x19B  ; arg_1 ROM:8F31C5A8 008 FF F7 70 FF BL pcap_send_something  ; Branch with Link ROM:8F31C5AC 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5B0 008 29 21 MOVS R1, #0x29  ; arg_2 ROM:8F31C5B2 008 4F F4 CE 70 MOV.W R0, #0x19C  ; arg_1 ROM:8F31C5B6 008 FF F7 69 FF BL pcap_send_something  ; Branch with Link ROM:8F31C5BA 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5BE 008 29 21 MOVS R1, #0x29  ; arg_2 ROM:8F31C5C0 008 40 F2 9D 10 MOVW R0, #0x19D  ; arg_1 ROM:8F31C5C4 008 FF F7 62 FF BL pcap_send_something  ; Branch with Link ROM:8F31C5C8 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5CC 008 4F F4 80 51 MOV.W R1, #0x1000  ; arg_2 ROM:8F31C5D0 008 4F F4 40 70 MOV.W R0, #0x300  ; arg_1 ROM:8F31C5D4 008 FF F7 5A FF BL pcap_send_something  ; Branch with Link ROM:8F31C5D8 008 4F F6 7F 72 MOVW R2, #0xFF7F  ; arg_3 ROM:8F31C5DC 008 44 F2 73 11 MOVW R1, #0x4173  ; arg_2 ROM:8F31C5E0 008 40 F2 01 30 MOVW R0, #0x301  ; arg_1 ROM:8F31C5E4 008 FF F7 52 FF BL pcap_send_something  ; Branch with Link ROM:8F31C5E8 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5EC 008 41 F2 01 01 MOVW R1, #0x1001  ; arg_2 ROM:8F31C5F0 008 4F F4 60 70 MOV.W R0, #0x380  ; arg_1 ROM:8F31C5F4 008 FF F7 4A FF BL pcap_send_something  ; Branch with Link ROM:8F31C5F8 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C5FC 008 4C F2 20 01 MOVW R1, #0xC020  ; arg_2 ROM:8F31C600 008 40 F2 81 30 MOVW R0, #0x381  ; arg_1 ROM:8F31C604 008 FF F7 42 FF BL pcap_send_something  ; Branch with Link ROM:8F31C608 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C60C 008 43 F6 FF 41 MOVW R1, #0x3CFF  ; arg_2 ROM:8F31C610 008 40 F2 82 30 MOVW R0, #0x382  ; arg_1 ROM:8F31C614 008 FF F7 3A FF BL pcap_send_something  ; Branch with Link ROM:8F31C618 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C61C 008 91 10 ASRS R1, R2, #2  ; Arithmetic Shift Right ROM:8F31C61E 008 4F F4 80 60 MOV.W R0, #0x400  ; arg_1 ROM:8F31C622 008 FF F7 33 FF BL pcap_send_something  ; Branch with Link ROM:8F31C626 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C62A 008 45 F2 49 41 MOVW R1, #0x5449  ; arg_2 ROM:8F31C62E 008 4F F4 F8 50 MOV.W R0, #0x1F00  ; arg_1 ROM:8F31C632 008 FF F7 2B FF BL pcap_send_something  ; Branch with Link ROM:8F31C636 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C63A 008 4F F4 2A 61 MOV.W R1, #0xAA0  ; arg_2 ROM:8F31C63E 008 41 F6 22 70 MOVW R0, #0x1F22  ; arg_1 ROM:8F31C642 008 FF F7 23 FF BL pcap_send_something  ; Branch with Link ROM:8F31C646 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C64A 008 00 21 MOVS R1, #0  ; arg_2 ROM:8F31C64C 008 4F F4 F8 50 MOV.W R0, #0x1F00  ; arg_1 ROM:8F31C650 008 FF F7 1C FF BL pcap_send_something  ; Branch with Link ROM:8F31C654 008 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C658 008 4D F6 04 31 MOVW R1, #0xDB04  ; arg_2 ROM:8F31C65C 008 4F F4 C0 70 MOV.W R0, #0x180  ; arg_1 ROM:8F31C660 008 FF F7 14 FF BL pcap_send_something  ; Branch with Link ROM:8F31C664 008 10 BD POP {R4,PC}  ; Pop registers ROM:8F31C664  ; End of function pcap_init_key ROM:8F31C664 </syntaxhightlight>

<syntaxhighligiht lang="asm"> ROM:8F31C48C ROM:8F31C48C  ; =============== S U B R O U T I N E ======================================= ROM:8F31C48C ROM:8F31C48C ROM:8F31C48C  ; int __fastcall pcap_send_something(int arg_1, int arg_2, int arg_3) ROM:8F31C48C pcap_send_something  ; CODE XREF: enter_os+2C�p ROM:8F31C48C  ; boot_load_and_validate_objects+C�p ... ROM:8F31C48C ROM:8F31C48C var_20 = -0x20 ROM:8F31C48C var_1C = -0x1C ROM:8F31C48C ROM:8F31C48C 000 2D E9 FC 41 PUSH.W {R2-R8,LR}  ; Push registers ROM:8F31C490 020 04 46 MOV R4, R0  ; Rd = Op2 ROM:8F31C492 020 0D 46 MOV R5, R1  ; Rd = Op2 ROM:8F31C494 020 16 46 MOV R6, R2  ; Rd = Op2 ROM:8F31C496 020 00 20 MOVS R0, #0  ; Rd = Op2 ROM:8F31C498 020 01 90 STR R0, [SP,#0x20+var_1C]  ; Store to Memory ROM:8F31C49A 020 00 27 MOVS R7, #0  ; Rd = Op2 ROM:8F31C49C 020 00 90 STR R0, [SP,#0x20+var_20]  ; Store to Memory ROM:8F31C49E 020 4F F6 FF 72 MOVW R2, #0xFFFF  ; arg_3 ROM:8F31C4A2 020 01 A9 ADD R1, SP, #0x20+var_1C  ; arg_2 ROM:8F31C4A4 020 20 46 MOV R0, R4  ; arg_1 ROM:8F31C4A6 020 FF F7 43 FF BL read_pcap_reg  ; Branch with Link ROM:8F31C4AA 020 01 98 LDR R0, [SP,#0x20+var_1C]  ; Load from Memory ROM:8F31C4AC 020 B0 43 BICS R0, R6  ; Rd = Op1 & ~Op2 ROM:8F31C4AE 020 01 90 STR R0, [SP,#0x20+var_1C]  ; Store to Memory ROM:8F31C4B0 020 05 EA 06 00 AND.W R0, R5, R6  ; Rd = Op1 & Op2 ROM:8F31C4B4 020 01 99 LDR R1, [SP,#0x20+var_1C]  ; Load from Memory ROM:8F31C4B6 020 40 EA 01 07 ORR.W R7, R0, R1  ; Rd = Op1 | Op2 ROM:8F31C4BA 020 C4 F3 0C 00 UBFX.W R0, R4, #0, #0xD  ; Unsigned Bit Field Extract ROM:8F31C4BE 020 4F F0 00 41 MOV.W R1, #0x80000000  ; Rd = Op2 ROM:8F31C4C2 020 41 EA 80 40 ORR.W R0, R1, R0,LSL#18  ; Rd = Op1 | Op2 ROM:8F31C4C6 020 B9 B2 UXTH R1, R7  ; Unsigned extend halfword to word ROM:8F31C4C8 020 08 43 ORRS R0, R1  ; Rd = Op1 | Op2 ROM:8F31C4CA 020 00 90 STR R0, [SP,#0x20+var_20]  ; Store to Memory ROM:8F31C4CC 020 00 21 MOVS R1, #0  ; Rd = Op2 ROM:8F31C4CE 020 08 46 MOV R0, R1  ; Rd = Op2 ROM:8F31C4D0 020 06 F0 69 F8 BL spi_read_write_0  ; Branch with Link ROM:8F31C4D4 020 01 AB ADD R3, SP, #0x20+var_1C  ; Rd = Op1 + Op2 ROM:8F31C4D6 020 6A 46 MOV R2, SP  ; Rd = Op2 ROM:8F31C4D8 020 00 21 MOVS R1, #0  ; Rd = Op2 ROM:8F31C4DA 020 08 46 MOV R0, R1  ; Rd = Op2 ROM:8F31C4DC 020 06 F0 8F F8 BL spi_read_write_2  ; Branch with Link ROM:8F31C4E0 020 00 21 MOVS R1, #0  ; Rd = Op2 ROM:8F31C4E2 020 08 46 MOV R0, R1  ; Rd = Op2 ROM:8F31C4E4 020 06 F0 75 F8 BL spi_read_write_1  ; Branch with Link ROM:8F31C4E8 020 01 98 LDR R0, [SP,#0x20+var_1C]  ; Load from Memory ROM:8F31C4EA 020 85 B2 UXTH R5, R0  ; Unsigned extend halfword to word ROM:8F31C4EC 020 01 98 LDR R0, [SP,#0x20+var_1C]  ; Load from Memory ROM:8F31C4EE 020 BD E8 FC 81 POP.W {R2-R8,PC}  ; Pop registers ROM:8F31C4EE 020  ; End of function pcap_send_something ROM:8F31C4EE ROM:8F31C4EE  ; --------------------------------------------------------------------------- ROM:8F31C4F2 70 47 DCW 0x4770 ROM:8F31C4F4 </syntaxhightlight>