../build/bt6702/stm32bt6702/stm32bt6702.elf: file format elf32-littlearm Sections: Idx Name Size VMA LMA File off Algn 0 .isr_vector 00000188 08020000 08020000 00008000 2**0 CONTENTS, ALLOC, LOAD, READONLY, DATA 1 .text 00020878 08020188 08020188 00008188 2**3 CONTENTS, ALLOC, LOAD, READONLY, CODE 2 .ARM 00000008 08040a00 08040a00 00028a00 2**2 CONTENTS, ALLOC, LOAD, READONLY, DATA 3 .init_array 00000004 08040a08 08040a08 00028a08 2**2 CONTENTS, ALLOC, LOAD, DATA 4 .fini_array 00000004 08040a0c 08040a0c 00028a0c 2**2 CONTENTS, ALLOC, LOAD, DATA 5 .data 00001900 20000000 08040a10 00030000 2**2 CONTENTS, ALLOC, LOAD, DATA 6 .fill 0007dcec 08042310 08042310 00032310 2**0 CONTENTS, ALLOC, LOAD, DATA 7 .crc 00000004 080bfffc 080bfffc 000afffc 2**2 CONTENTS, ALLOC, LOAD, DATA 8 .bss 0001393c 20001900 08042310 000b1900 2**2 ALLOC 9 ._user_heap_stack 00000200 2001523c 08055c4c 000b1900 2**0 ALLOC 10 .memory_b1_text 0000f000 10000000 10000000 000b0000 2**0 ALLOC 11 .ARM.attributes 0000002f 00000000 00000000 000b0000 2**0 CONTENTS, READONLY 12 .debug_info 00047ada 00000000 00000000 000b002f 2**0 CONTENTS, READONLY, DEBUGGING 13 .debug_abbrev 0000bc52 00000000 00000000 000f7b09 2**0 CONTENTS, READONLY, DEBUGGING 14 .debug_loc 0002322f 00000000 00000000 0010375b 2**0 CONTENTS, READONLY, DEBUGGING 15 .debug_aranges 00002dc8 00000000 00000000 00126990 2**3 CONTENTS, READONLY, DEBUGGING 16 .debug_ranges 00003728 00000000 00000000 00129758 2**3 CONTENTS, READONLY, DEBUGGING 17 .debug_macro 0001f0a9 00000000 00000000 0012ce80 2**0 CONTENTS, READONLY, DEBUGGING 18 .debug_line 000221cd 00000000 00000000 0014bf29 2**0 CONTENTS, READONLY, DEBUGGING 19 .debug_str 000803ff 00000000 00000000 0016e0f6 2**0 CONTENTS, READONLY, DEBUGGING 20 .comment 00000030 00000000 00000000 001ee4f5 2**0 CONTENTS, READONLY 21 .debug_frame 00007ac0 00000000 00000000 001ee528 2**2 CONTENTS, READONLY, DEBUGGING Disassembly of section .text: 08020188 : 8020188: b508 push {r3, lr} 802018a: f641 1000 movw r0, #6400 ; 0x1900 802018e: 4b07 ldr r3, [pc, #28] ; (80201ac ) 8020190: f2c2 0000 movt r0, #8192 ; 0x2000 8020194: 1a1b subs r3, r3, r0 8020196: 2b06 cmp r3, #6 8020198: d800 bhi.n 802019c 802019a: bd08 pop {r3, pc} 802019c: f240 0300 movw r3, #0 80201a0: f2c0 0300 movt r3, #0 80201a4: 2b00 cmp r3, #0 80201a6: d0f8 beq.n 802019a 80201a8: 4798 blx r3 80201aa: e7f6 b.n 802019a 80201ac: 20001903 .word 0x20001903 080201b0 : 80201b0: b508 push {r3, lr} 80201b2: f641 1000 movw r0, #6400 ; 0x1900 80201b6: f641 1300 movw r3, #6400 ; 0x1900 80201ba: f2c2 0000 movt r0, #8192 ; 0x2000 80201be: f2c2 0300 movt r3, #8192 ; 0x2000 80201c2: 1a1b subs r3, r3, r0 80201c4: 109b asrs r3, r3, #2 80201c6: eb03 73d3 add.w r3, r3, r3, lsr #31 80201ca: 1059 asrs r1, r3, #1 80201cc: d100 bne.n 80201d0 80201ce: bd08 pop {r3, pc} 80201d0: f240 0200 movw r2, #0 80201d4: f2c0 0200 movt r2, #0 80201d8: 2a00 cmp r2, #0 80201da: d0f8 beq.n 80201ce 80201dc: 4790 blx r2 80201de: e7f6 b.n 80201ce 080201e0 <__do_global_dtors_aux>: 80201e0: b510 push {r4, lr} 80201e2: f641 1400 movw r4, #6400 ; 0x1900 80201e6: f2c2 0400 movt r4, #8192 ; 0x2000 80201ea: 7823 ldrb r3, [r4, #0] 80201ec: b973 cbnz r3, 802020c <__do_global_dtors_aux+0x2c> 80201ee: f7ff ffcb bl 8020188 80201f2: f240 0300 movw r3, #0 80201f6: f2c0 0300 movt r3, #0 80201fa: b12b cbz r3, 8020208 <__do_global_dtors_aux+0x28> 80201fc: f640 10e8 movw r0, #2536 ; 0x9e8 8020200: f6c0 0004 movt r0, #2052 ; 0x804 8020204: f3af 8000 nop.w 8020208: 2301 movs r3, #1 802020a: 7023 strb r3, [r4, #0] 802020c: bd10 pop {r4, pc} 802020e: bf00 nop 08020210 : 8020210: b508 push {r3, lr} 8020212: f240 0300 movw r3, #0 8020216: f2c0 0300 movt r3, #0 802021a: b14b cbz r3, 8020230 802021c: f640 10e8 movw r0, #2536 ; 0x9e8 8020220: f641 1104 movw r1, #6404 ; 0x1904 8020224: f6c0 0004 movt r0, #2052 ; 0x804 8020228: f2c2 0100 movt r1, #8192 ; 0x2000 802022c: f3af 8000 nop.w 8020230: f641 1000 movw r0, #6400 ; 0x1900 8020234: f2c2 0000 movt r0, #8192 ; 0x2000 8020238: 6803 ldr r3, [r0, #0] 802023a: b12b cbz r3, 8020248 802023c: f240 0300 movw r3, #0 8020240: f2c0 0300 movt r3, #0 8020244: b103 cbz r3, 8020248 8020246: 4798 blx r3 8020248: e8bd 4008 ldmia.w sp!, {r3, lr} 802024c: f7ff bfb0 b.w 80201b0 08020250 <__aeabi_drsub>: 8020250: f081 4100 eor.w r1, r1, #2147483648 ; 0x80000000 8020254: e002 b.n 802025c <__adddf3> 8020256: bf00 nop 08020258 <__aeabi_dsub>: 8020258: f083 4300 eor.w r3, r3, #2147483648 ; 0x80000000 0802025c <__adddf3>: 802025c: b530 push {r4, r5, lr} 802025e: ea4f 0441 mov.w r4, r1, lsl #1 8020262: ea4f 0543 mov.w r5, r3, lsl #1 8020266: ea94 0f05 teq r4, r5 802026a: bf08 it eq 802026c: ea90 0f02 teqeq r0, r2 8020270: bf1f itttt ne 8020272: ea54 0c00 orrsne.w ip, r4, r0 8020276: ea55 0c02 orrsne.w ip, r5, r2 802027a: ea7f 5c64 mvnsne.w ip, r4, asr #21 802027e: ea7f 5c65 mvnsne.w ip, r5, asr #21 8020282: f000 80e2 beq.w 802044a <__adddf3+0x1ee> 8020286: ea4f 5454 mov.w r4, r4, lsr #21 802028a: ebd4 5555 rsbs r5, r4, r5, lsr #21 802028e: bfb8 it lt 8020290: 426d neglt r5, r5 8020292: dd0c ble.n 80202ae <__adddf3+0x52> 8020294: 442c add r4, r5 8020296: ea80 0202 eor.w r2, r0, r2 802029a: ea81 0303 eor.w r3, r1, r3 802029e: ea82 0000 eor.w r0, r2, r0 80202a2: ea83 0101 eor.w r1, r3, r1 80202a6: ea80 0202 eor.w r2, r0, r2 80202aa: ea81 0303 eor.w r3, r1, r3 80202ae: 2d36 cmp r5, #54 ; 0x36 80202b0: bf88 it hi 80202b2: bd30 pophi {r4, r5, pc} 80202b4: f011 4f00 tst.w r1, #2147483648 ; 0x80000000 80202b8: ea4f 3101 mov.w r1, r1, lsl #12 80202bc: f44f 1c80 mov.w ip, #1048576 ; 0x100000 80202c0: ea4c 3111 orr.w r1, ip, r1, lsr #12 80202c4: d002 beq.n 80202cc <__adddf3+0x70> 80202c6: 4240 negs r0, r0 80202c8: eb61 0141 sbc.w r1, r1, r1, lsl #1 80202cc: f013 4f00 tst.w r3, #2147483648 ; 0x80000000 80202d0: ea4f 3303 mov.w r3, r3, lsl #12 80202d4: ea4c 3313 orr.w r3, ip, r3, lsr #12 80202d8: d002 beq.n 80202e0 <__adddf3+0x84> 80202da: 4252 negs r2, r2 80202dc: eb63 0343 sbc.w r3, r3, r3, lsl #1 80202e0: ea94 0f05 teq r4, r5 80202e4: f000 80a7 beq.w 8020436 <__adddf3+0x1da> 80202e8: f1a4 0401 sub.w r4, r4, #1 80202ec: f1d5 0e20 rsbs lr, r5, #32 80202f0: db0d blt.n 802030e <__adddf3+0xb2> 80202f2: fa02 fc0e lsl.w ip, r2, lr 80202f6: fa22 f205 lsr.w r2, r2, r5 80202fa: 1880 adds r0, r0, r2 80202fc: f141 0100 adc.w r1, r1, #0 8020300: fa03 f20e lsl.w r2, r3, lr 8020304: 1880 adds r0, r0, r2 8020306: fa43 f305 asr.w r3, r3, r5 802030a: 4159 adcs r1, r3 802030c: e00e b.n 802032c <__adddf3+0xd0> 802030e: f1a5 0520 sub.w r5, r5, #32 8020312: f10e 0e20 add.w lr, lr, #32 8020316: 2a01 cmp r2, #1 8020318: fa03 fc0e lsl.w ip, r3, lr 802031c: bf28 it cs 802031e: f04c 0c02 orrcs.w ip, ip, #2 8020322: fa43 f305 asr.w r3, r3, r5 8020326: 18c0 adds r0, r0, r3 8020328: eb51 71e3 adcs.w r1, r1, r3, asr #31 802032c: f001 4500 and.w r5, r1, #2147483648 ; 0x80000000 8020330: d507 bpl.n 8020342 <__adddf3+0xe6> 8020332: f04f 0e00 mov.w lr, #0 8020336: f1dc 0c00 rsbs ip, ip, #0 802033a: eb7e 0000 sbcs.w r0, lr, r0 802033e: eb6e 0101 sbc.w r1, lr, r1 8020342: f5b1 1f80 cmp.w r1, #1048576 ; 0x100000 8020346: d31b bcc.n 8020380 <__adddf3+0x124> 8020348: f5b1 1f00 cmp.w r1, #2097152 ; 0x200000 802034c: d30c bcc.n 8020368 <__adddf3+0x10c> 802034e: 0849 lsrs r1, r1, #1 8020350: ea5f 0030 movs.w r0, r0, rrx 8020354: ea4f 0c3c mov.w ip, ip, rrx 8020358: f104 0401 add.w r4, r4, #1 802035c: ea4f 5244 mov.w r2, r4, lsl #21 8020360: f512 0f80 cmn.w r2, #4194304 ; 0x400000 8020364: f080 809a bcs.w 802049c <__adddf3+0x240> 8020368: f1bc 4f00 cmp.w ip, #2147483648 ; 0x80000000 802036c: bf08 it eq 802036e: ea5f 0c50 movseq.w ip, r0, lsr #1 8020372: f150 0000 adcs.w r0, r0, #0 8020376: eb41 5104 adc.w r1, r1, r4, lsl #20 802037a: ea41 0105 orr.w r1, r1, r5 802037e: bd30 pop {r4, r5, pc} 8020380: ea5f 0c4c movs.w ip, ip, lsl #1 8020384: 4140 adcs r0, r0 8020386: eb41 0101 adc.w r1, r1, r1 802038a: f411 1f80 tst.w r1, #1048576 ; 0x100000 802038e: f1a4 0401 sub.w r4, r4, #1 8020392: d1e9 bne.n 8020368 <__adddf3+0x10c> 8020394: f091 0f00 teq r1, #0 8020398: bf04 itt eq 802039a: 4601 moveq r1, r0 802039c: 2000 moveq r0, #0 802039e: fab1 f381 clz r3, r1 80203a2: bf08 it eq 80203a4: 3320 addeq r3, #32 80203a6: f1a3 030b sub.w r3, r3, #11 80203aa: f1b3 0220 subs.w r2, r3, #32 80203ae: da0c bge.n 80203ca <__adddf3+0x16e> 80203b0: 320c adds r2, #12 80203b2: dd08 ble.n 80203c6 <__adddf3+0x16a> 80203b4: f102 0c14 add.w ip, r2, #20 80203b8: f1c2 020c rsb r2, r2, #12 80203bc: fa01 f00c lsl.w r0, r1, ip 80203c0: fa21 f102 lsr.w r1, r1, r2 80203c4: e00c b.n 80203e0 <__adddf3+0x184> 80203c6: f102 0214 add.w r2, r2, #20 80203ca: bfd8 it le 80203cc: f1c2 0c20 rsble ip, r2, #32 80203d0: fa01 f102 lsl.w r1, r1, r2 80203d4: fa20 fc0c lsr.w ip, r0, ip 80203d8: bfdc itt le 80203da: ea41 010c orrle.w r1, r1, ip 80203de: 4090 lslle r0, r2 80203e0: 1ae4 subs r4, r4, r3 80203e2: bfa2 ittt ge 80203e4: eb01 5104 addge.w r1, r1, r4, lsl #20 80203e8: 4329 orrge r1, r5 80203ea: bd30 popge {r4, r5, pc} 80203ec: ea6f 0404 mvn.w r4, r4 80203f0: 3c1f subs r4, #31 80203f2: da1c bge.n 802042e <__adddf3+0x1d2> 80203f4: 340c adds r4, #12 80203f6: dc0e bgt.n 8020416 <__adddf3+0x1ba> 80203f8: f104 0414 add.w r4, r4, #20 80203fc: f1c4 0220 rsb r2, r4, #32 8020400: fa20 f004 lsr.w r0, r0, r4 8020404: fa01 f302 lsl.w r3, r1, r2 8020408: ea40 0003 orr.w r0, r0, r3 802040c: fa21 f304 lsr.w r3, r1, r4 8020410: ea45 0103 orr.w r1, r5, r3 8020414: bd30 pop {r4, r5, pc} 8020416: f1c4 040c rsb r4, r4, #12 802041a: f1c4 0220 rsb r2, r4, #32 802041e: fa20 f002 lsr.w r0, r0, r2 8020422: fa01 f304 lsl.w r3, r1, r4 8020426: ea40 0003 orr.w r0, r0, r3 802042a: 4629 mov r1, r5 802042c: bd30 pop {r4, r5, pc} 802042e: fa21 f004 lsr.w r0, r1, r4 8020432: 4629 mov r1, r5 8020434: bd30 pop {r4, r5, pc} 8020436: f094 0f00 teq r4, #0 802043a: f483 1380 eor.w r3, r3, #1048576 ; 0x100000 802043e: bf06 itte eq 8020440: f481 1180 eoreq.w r1, r1, #1048576 ; 0x100000 8020444: 3401 addeq r4, #1 8020446: 3d01 subne r5, #1 8020448: e74e b.n 80202e8 <__adddf3+0x8c> 802044a: ea7f 5c64 mvns.w ip, r4, asr #21 802044e: bf18 it ne 8020450: ea7f 5c65 mvnsne.w ip, r5, asr #21 8020454: d029 beq.n 80204aa <__adddf3+0x24e> 8020456: ea94 0f05 teq r4, r5 802045a: bf08 it eq 802045c: ea90 0f02 teqeq r0, r2 8020460: d005 beq.n 802046e <__adddf3+0x212> 8020462: ea54 0c00 orrs.w ip, r4, r0 8020466: bf04 itt eq 8020468: 4619 moveq r1, r3 802046a: 4610 moveq r0, r2 802046c: bd30 pop {r4, r5, pc} 802046e: ea91 0f03 teq r1, r3 8020472: bf1e ittt ne 8020474: 2100 movne r1, #0 8020476: 2000 movne r0, #0 8020478: bd30 popne {r4, r5, pc} 802047a: ea5f 5c54 movs.w ip, r4, lsr #21 802047e: d105 bne.n 802048c <__adddf3+0x230> 8020480: 0040 lsls r0, r0, #1 8020482: 4149 adcs r1, r1 8020484: bf28 it cs 8020486: f041 4100 orrcs.w r1, r1, #2147483648 ; 0x80000000 802048a: bd30 pop {r4, r5, pc} 802048c: f514 0480 adds.w r4, r4, #4194304 ; 0x400000 8020490: bf3c itt cc 8020492: f501 1180 addcc.w r1, r1, #1048576 ; 0x100000 8020496: bd30 popcc {r4, r5, pc} 8020498: f001 4500 and.w r5, r1, #2147483648 ; 0x80000000 802049c: f045 41fe orr.w r1, r5, #2130706432 ; 0x7f000000 80204a0: f441 0170 orr.w r1, r1, #15728640 ; 0xf00000 80204a4: f04f 0000 mov.w r0, #0 80204a8: bd30 pop {r4, r5, pc} 80204aa: ea7f 5c64 mvns.w ip, r4, asr #21 80204ae: bf1a itte ne 80204b0: 4619 movne r1, r3 80204b2: 4610 movne r0, r2 80204b4: ea7f 5c65 mvnseq.w ip, r5, asr #21 80204b8: bf1c itt ne 80204ba: 460b movne r3, r1 80204bc: 4602 movne r2, r0 80204be: ea50 3401 orrs.w r4, r0, r1, lsl #12 80204c2: bf06 itte eq 80204c4: ea52 3503 orrseq.w r5, r2, r3, lsl #12 80204c8: ea91 0f03 teqeq r1, r3 80204cc: f441 2100 orrne.w r1, r1, #524288 ; 0x80000 80204d0: bd30 pop {r4, r5, pc} 80204d2: bf00 nop 080204d4 <__aeabi_ui2d>: 80204d4: f090 0f00 teq r0, #0 80204d8: bf04 itt eq 80204da: 2100 moveq r1, #0 80204dc: 4770 bxeq lr 80204de: b530 push {r4, r5, lr} 80204e0: f44f 6480 mov.w r4, #1024 ; 0x400 80204e4: f104 0432 add.w r4, r4, #50 ; 0x32 80204e8: f04f 0500 mov.w r5, #0 80204ec: f04f 0100 mov.w r1, #0 80204f0: e750 b.n 8020394 <__adddf3+0x138> 80204f2: bf00 nop 080204f4 <__aeabi_i2d>: 80204f4: f090 0f00 teq r0, #0 80204f8: bf04 itt eq 80204fa: 2100 moveq r1, #0 80204fc: 4770 bxeq lr 80204fe: b530 push {r4, r5, lr} 8020500: f44f 6480 mov.w r4, #1024 ; 0x400 8020504: f104 0432 add.w r4, r4, #50 ; 0x32 8020508: f010 4500 ands.w r5, r0, #2147483648 ; 0x80000000 802050c: bf48 it mi 802050e: 4240 negmi r0, r0 8020510: f04f 0100 mov.w r1, #0 8020514: e73e b.n 8020394 <__adddf3+0x138> 8020516: bf00 nop 08020518 <__aeabi_f2d>: 8020518: 0042 lsls r2, r0, #1 802051a: ea4f 01e2 mov.w r1, r2, asr #3 802051e: ea4f 0131 mov.w r1, r1, rrx 8020522: ea4f 7002 mov.w r0, r2, lsl #28 8020526: bf1f itttt ne 8020528: f012 437f andsne.w r3, r2, #4278190080 ; 0xff000000 802052c: f093 4f7f teqne r3, #4278190080 ; 0xff000000 8020530: f081 5160 eorne.w r1, r1, #939524096 ; 0x38000000 8020534: 4770 bxne lr 8020536: f092 0f00 teq r2, #0 802053a: bf14 ite ne 802053c: f093 4f7f teqne r3, #4278190080 ; 0xff000000 8020540: 4770 bxeq lr 8020542: b530 push {r4, r5, lr} 8020544: f44f 7460 mov.w r4, #896 ; 0x380 8020548: f001 4500 and.w r5, r1, #2147483648 ; 0x80000000 802054c: f021 4100 bic.w r1, r1, #2147483648 ; 0x80000000 8020550: e720 b.n 8020394 <__adddf3+0x138> 8020552: bf00 nop 08020554 <__aeabi_ul2d>: 8020554: ea50 0201 orrs.w r2, r0, r1 8020558: bf08 it eq 802055a: 4770 bxeq lr 802055c: b530 push {r4, r5, lr} 802055e: f04f 0500 mov.w r5, #0 8020562: e00a b.n 802057a <__aeabi_l2d+0x16> 08020564 <__aeabi_l2d>: 8020564: ea50 0201 orrs.w r2, r0, r1 8020568: bf08 it eq 802056a: 4770 bxeq lr 802056c: b530 push {r4, r5, lr} 802056e: f011 4500 ands.w r5, r1, #2147483648 ; 0x80000000 8020572: d502 bpl.n 802057a <__aeabi_l2d+0x16> 8020574: 4240 negs r0, r0 8020576: eb61 0141 sbc.w r1, r1, r1, lsl #1 802057a: f44f 6480 mov.w r4, #1024 ; 0x400 802057e: f104 0432 add.w r4, r4, #50 ; 0x32 8020582: ea5f 5c91 movs.w ip, r1, lsr #22 8020586: f43f aedc beq.w 8020342 <__adddf3+0xe6> 802058a: f04f 0203 mov.w r2, #3 802058e: ea5f 0cdc movs.w ip, ip, lsr #3 8020592: bf18 it ne 8020594: 3203 addne r2, #3 8020596: ea5f 0cdc movs.w ip, ip, lsr #3 802059a: bf18 it ne 802059c: 3203 addne r2, #3 802059e: eb02 02dc add.w r2, r2, ip, lsr #3 80205a2: f1c2 0320 rsb r3, r2, #32 80205a6: fa00 fc03 lsl.w ip, r0, r3 80205aa: fa20 f002 lsr.w r0, r0, r2 80205ae: fa01 fe03 lsl.w lr, r1, r3 80205b2: ea40 000e orr.w r0, r0, lr 80205b6: fa21 f102 lsr.w r1, r1, r2 80205ba: 4414 add r4, r2 80205bc: e6c1 b.n 8020342 <__adddf3+0xe6> 80205be: bf00 nop 080205c0 <__aeabi_dmul>: 80205c0: b570 push {r4, r5, r6, lr} 80205c2: f04f 0cff mov.w ip, #255 ; 0xff 80205c6: f44c 6ce0 orr.w ip, ip, #1792 ; 0x700 80205ca: ea1c 5411 ands.w r4, ip, r1, lsr #20 80205ce: bf1d ittte ne 80205d0: ea1c 5513 andsne.w r5, ip, r3, lsr #20 80205d4: ea94 0f0c teqne r4, ip 80205d8: ea95 0f0c teqne r5, ip 80205dc: f000 f8de bleq 802079c <__aeabi_dmul+0x1dc> 80205e0: 442c add r4, r5 80205e2: ea81 0603 eor.w r6, r1, r3 80205e6: ea21 514c bic.w r1, r1, ip, lsl #21 80205ea: ea23 534c bic.w r3, r3, ip, lsl #21 80205ee: ea50 3501 orrs.w r5, r0, r1, lsl #12 80205f2: bf18 it ne 80205f4: ea52 3503 orrsne.w r5, r2, r3, lsl #12 80205f8: f441 1180 orr.w r1, r1, #1048576 ; 0x100000 80205fc: f443 1380 orr.w r3, r3, #1048576 ; 0x100000 8020600: d038 beq.n 8020674 <__aeabi_dmul+0xb4> 8020602: fba0 ce02 umull ip, lr, r0, r2 8020606: f04f 0500 mov.w r5, #0 802060a: fbe1 e502 umlal lr, r5, r1, r2 802060e: f006 4200 and.w r2, r6, #2147483648 ; 0x80000000 8020612: fbe0 e503 umlal lr, r5, r0, r3 8020616: f04f 0600 mov.w r6, #0 802061a: fbe1 5603 umlal r5, r6, r1, r3 802061e: f09c 0f00 teq ip, #0 8020622: bf18 it ne 8020624: f04e 0e01 orrne.w lr, lr, #1 8020628: f1a4 04ff sub.w r4, r4, #255 ; 0xff 802062c: f5b6 7f00 cmp.w r6, #512 ; 0x200 8020630: f564 7440 sbc.w r4, r4, #768 ; 0x300 8020634: d204 bcs.n 8020640 <__aeabi_dmul+0x80> 8020636: ea5f 0e4e movs.w lr, lr, lsl #1 802063a: 416d adcs r5, r5 802063c: eb46 0606 adc.w r6, r6, r6 8020640: ea42 21c6 orr.w r1, r2, r6, lsl #11 8020644: ea41 5155 orr.w r1, r1, r5, lsr #21 8020648: ea4f 20c5 mov.w r0, r5, lsl #11 802064c: ea40 505e orr.w r0, r0, lr, lsr #21 8020650: ea4f 2ece mov.w lr, lr, lsl #11 8020654: f1b4 0cfd subs.w ip, r4, #253 ; 0xfd 8020658: bf88 it hi 802065a: f5bc 6fe0 cmphi.w ip, #1792 ; 0x700 802065e: d81e bhi.n 802069e <__aeabi_dmul+0xde> 8020660: f1be 4f00 cmp.w lr, #2147483648 ; 0x80000000 8020664: bf08 it eq 8020666: ea5f 0e50 movseq.w lr, r0, lsr #1 802066a: f150 0000 adcs.w r0, r0, #0 802066e: eb41 5104 adc.w r1, r1, r4, lsl #20 8020672: bd70 pop {r4, r5, r6, pc} 8020674: f006 4600 and.w r6, r6, #2147483648 ; 0x80000000 8020678: ea46 0101 orr.w r1, r6, r1 802067c: ea40 0002 orr.w r0, r0, r2 8020680: ea81 0103 eor.w r1, r1, r3 8020684: ebb4 045c subs.w r4, r4, ip, lsr #1 8020688: bfc2 ittt gt 802068a: ebd4 050c rsbsgt r5, r4, ip 802068e: ea41 5104 orrgt.w r1, r1, r4, lsl #20 8020692: bd70 popgt {r4, r5, r6, pc} 8020694: f441 1180 orr.w r1, r1, #1048576 ; 0x100000 8020698: f04f 0e00 mov.w lr, #0 802069c: 3c01 subs r4, #1 802069e: f300 80ab bgt.w 80207f8 <__aeabi_dmul+0x238> 80206a2: f114 0f36 cmn.w r4, #54 ; 0x36 80206a6: bfde ittt le 80206a8: 2000 movle r0, #0 80206aa: f001 4100 andle.w r1, r1, #2147483648 ; 0x80000000 80206ae: bd70 pople {r4, r5, r6, pc} 80206b0: f1c4 0400 rsb r4, r4, #0 80206b4: 3c20 subs r4, #32 80206b6: da35 bge.n 8020724 <__aeabi_dmul+0x164> 80206b8: 340c adds r4, #12 80206ba: dc1b bgt.n 80206f4 <__aeabi_dmul+0x134> 80206bc: f104 0414 add.w r4, r4, #20 80206c0: f1c4 0520 rsb r5, r4, #32 80206c4: fa00 f305 lsl.w r3, r0, r5 80206c8: fa20 f004 lsr.w r0, r0, r4 80206cc: fa01 f205 lsl.w r2, r1, r5 80206d0: ea40 0002 orr.w r0, r0, r2 80206d4: f001 4200 and.w r2, r1, #2147483648 ; 0x80000000 80206d8: f021 4100 bic.w r1, r1, #2147483648 ; 0x80000000 80206dc: eb10 70d3 adds.w r0, r0, r3, lsr #31 80206e0: fa21 f604 lsr.w r6, r1, r4 80206e4: eb42 0106 adc.w r1, r2, r6 80206e8: ea5e 0e43 orrs.w lr, lr, r3, lsl #1 80206ec: bf08 it eq 80206ee: ea20 70d3 biceq.w r0, r0, r3, lsr #31 80206f2: bd70 pop {r4, r5, r6, pc} 80206f4: f1c4 040c rsb r4, r4, #12 80206f8: f1c4 0520 rsb r5, r4, #32 80206fc: fa00 f304 lsl.w r3, r0, r4 8020700: fa20 f005 lsr.w r0, r0, r5 8020704: fa01 f204 lsl.w r2, r1, r4 8020708: ea40 0002 orr.w r0, r0, r2 802070c: f001 4100 and.w r1, r1, #2147483648 ; 0x80000000 8020710: eb10 70d3 adds.w r0, r0, r3, lsr #31 8020714: f141 0100 adc.w r1, r1, #0 8020718: ea5e 0e43 orrs.w lr, lr, r3, lsl #1 802071c: bf08 it eq 802071e: ea20 70d3 biceq.w r0, r0, r3, lsr #31 8020722: bd70 pop {r4, r5, r6, pc} 8020724: f1c4 0520 rsb r5, r4, #32 8020728: fa00 f205 lsl.w r2, r0, r5 802072c: ea4e 0e02 orr.w lr, lr, r2 8020730: fa20 f304 lsr.w r3, r0, r4 8020734: fa01 f205 lsl.w r2, r1, r5 8020738: ea43 0302 orr.w r3, r3, r2 802073c: fa21 f004 lsr.w r0, r1, r4 8020740: f001 4100 and.w r1, r1, #2147483648 ; 0x80000000 8020744: fa21 f204 lsr.w r2, r1, r4 8020748: ea20 0002 bic.w r0, r0, r2 802074c: eb00 70d3 add.w r0, r0, r3, lsr #31 8020750: ea5e 0e43 orrs.w lr, lr, r3, lsl #1 8020754: bf08 it eq 8020756: ea20 70d3 biceq.w r0, r0, r3, lsr #31 802075a: bd70 pop {r4, r5, r6, pc} 802075c: f094 0f00 teq r4, #0 8020760: d10f bne.n 8020782 <__aeabi_dmul+0x1c2> 8020762: f001 4600 and.w r6, r1, #2147483648 ; 0x80000000 8020766: 0040 lsls r0, r0, #1 8020768: eb41 0101 adc.w r1, r1, r1 802076c: f411 1f80 tst.w r1, #1048576 ; 0x100000 8020770: bf08 it eq 8020772: 3c01 subeq r4, #1 8020774: d0f7 beq.n 8020766 <__aeabi_dmul+0x1a6> 8020776: ea41 0106 orr.w r1, r1, r6 802077a: f095 0f00 teq r5, #0 802077e: bf18 it ne 8020780: 4770 bxne lr 8020782: f003 4600 and.w r6, r3, #2147483648 ; 0x80000000 8020786: 0052 lsls r2, r2, #1 8020788: eb43 0303 adc.w r3, r3, r3 802078c: f413 1f80 tst.w r3, #1048576 ; 0x100000 8020790: bf08 it eq 8020792: 3d01 subeq r5, #1 8020794: d0f7 beq.n 8020786 <__aeabi_dmul+0x1c6> 8020796: ea43 0306 orr.w r3, r3, r6 802079a: 4770 bx lr 802079c: ea94 0f0c teq r4, ip 80207a0: ea0c 5513 and.w r5, ip, r3, lsr #20 80207a4: bf18 it ne 80207a6: ea95 0f0c teqne r5, ip 80207aa: d00c beq.n 80207c6 <__aeabi_dmul+0x206> 80207ac: ea50 0641 orrs.w r6, r0, r1, lsl #1 80207b0: bf18 it ne 80207b2: ea52 0643 orrsne.w r6, r2, r3, lsl #1 80207b6: d1d1 bne.n 802075c <__aeabi_dmul+0x19c> 80207b8: ea81 0103 eor.w r1, r1, r3 80207bc: f001 4100 and.w r1, r1, #2147483648 ; 0x80000000 80207c0: f04f 0000 mov.w r0, #0 80207c4: bd70 pop {r4, r5, r6, pc} 80207c6: ea50 0641 orrs.w r6, r0, r1, lsl #1 80207ca: bf06 itte eq 80207cc: 4610 moveq r0, r2 80207ce: 4619 moveq r1, r3 80207d0: ea52 0643 orrsne.w r6, r2, r3, lsl #1 80207d4: d019 beq.n 802080a <__aeabi_dmul+0x24a> 80207d6: ea94 0f0c teq r4, ip 80207da: d102 bne.n 80207e2 <__aeabi_dmul+0x222> 80207dc: ea50 3601 orrs.w r6, r0, r1, lsl #12 80207e0: d113 bne.n 802080a <__aeabi_dmul+0x24a> 80207e2: ea95 0f0c teq r5, ip 80207e6: d105 bne.n 80207f4 <__aeabi_dmul+0x234> 80207e8: ea52 3603 orrs.w r6, r2, r3, lsl #12 80207ec: bf1c itt ne 80207ee: 4610 movne r0, r2 80207f0: 4619 movne r1, r3 80207f2: d10a bne.n 802080a <__aeabi_dmul+0x24a> 80207f4: ea81 0103 eor.w r1, r1, r3 80207f8: f001 4100 and.w r1, r1, #2147483648 ; 0x80000000 80207fc: f041 41fe orr.w r1, r1, #2130706432 ; 0x7f000000 8020800: f441 0170 orr.w r1, r1, #15728640 ; 0xf00000 8020804: f04f 0000 mov.w r0, #0 8020808: bd70 pop {r4, r5, r6, pc} 802080a: f041 41fe orr.w r1, r1, #2130706432 ; 0x7f000000 802080e: f441 0178 orr.w r1, r1, #16252928 ; 0xf80000 8020812: bd70 pop {r4, r5, r6, pc} 08020814 <__aeabi_ddiv>: 8020814: b570 push {r4, r5, r6, lr} 8020816: f04f 0cff mov.w ip, #255 ; 0xff 802081a: f44c 6ce0 orr.w ip, ip, #1792 ; 0x700 802081e: ea1c 5411 ands.w r4, ip, r1, lsr #20 8020822: bf1d ittte ne 8020824: ea1c 5513 andsne.w r5, ip, r3, lsr #20 8020828: ea94 0f0c teqne r4, ip 802082c: ea95 0f0c teqne r5, ip 8020830: f000 f8a7 bleq 8020982 <__aeabi_ddiv+0x16e> 8020834: eba4 0405 sub.w r4, r4, r5 8020838: ea81 0e03 eor.w lr, r1, r3 802083c: ea52 3503 orrs.w r5, r2, r3, lsl #12 8020840: ea4f 3101 mov.w r1, r1, lsl #12 8020844: f000 8088 beq.w 8020958 <__aeabi_ddiv+0x144> 8020848: ea4f 3303 mov.w r3, r3, lsl #12 802084c: f04f 5580 mov.w r5, #268435456 ; 0x10000000 8020850: ea45 1313 orr.w r3, r5, r3, lsr #4 8020854: ea43 6312 orr.w r3, r3, r2, lsr #24 8020858: ea4f 2202 mov.w r2, r2, lsl #8 802085c: ea45 1511 orr.w r5, r5, r1, lsr #4 8020860: ea45 6510 orr.w r5, r5, r0, lsr #24 8020864: ea4f 2600 mov.w r6, r0, lsl #8 8020868: f00e 4100 and.w r1, lr, #2147483648 ; 0x80000000 802086c: 429d cmp r5, r3 802086e: bf08 it eq 8020870: 4296 cmpeq r6, r2 8020872: f144 04fd adc.w r4, r4, #253 ; 0xfd 8020876: f504 7440 add.w r4, r4, #768 ; 0x300 802087a: d202 bcs.n 8020882 <__aeabi_ddiv+0x6e> 802087c: 085b lsrs r3, r3, #1 802087e: ea4f 0232 mov.w r2, r2, rrx 8020882: 1ab6 subs r6, r6, r2 8020884: eb65 0503 sbc.w r5, r5, r3 8020888: 085b lsrs r3, r3, #1 802088a: ea4f 0232 mov.w r2, r2, rrx 802088e: f44f 1080 mov.w r0, #1048576 ; 0x100000 8020892: f44f 2c00 mov.w ip, #524288 ; 0x80000 8020896: ebb6 0e02 subs.w lr, r6, r2 802089a: eb75 0e03 sbcs.w lr, r5, r3 802089e: bf22 ittt cs 80208a0: 1ab6 subcs r6, r6, r2 80208a2: 4675 movcs r5, lr 80208a4: ea40 000c orrcs.w r0, r0, ip 80208a8: 085b lsrs r3, r3, #1 80208aa: ea4f 0232 mov.w r2, r2, rrx 80208ae: ebb6 0e02 subs.w lr, r6, r2 80208b2: eb75 0e03 sbcs.w lr, r5, r3 80208b6: bf22 ittt cs 80208b8: 1ab6 subcs r6, r6, r2 80208ba: 4675 movcs r5, lr 80208bc: ea40 005c orrcs.w r0, r0, ip, lsr #1 80208c0: 085b lsrs r3, r3, #1 80208c2: ea4f 0232 mov.w r2, r2, rrx 80208c6: ebb6 0e02 subs.w lr, r6, r2 80208ca: eb75 0e03 sbcs.w lr, r5, r3 80208ce: bf22 ittt cs 80208d0: 1ab6 subcs r6, r6, r2 80208d2: 4675 movcs r5, lr 80208d4: ea40 009c orrcs.w r0, r0, ip, lsr #2 80208d8: 085b lsrs r3, r3, #1 80208da: ea4f 0232 mov.w r2, r2, rrx 80208de: ebb6 0e02 subs.w lr, r6, r2 80208e2: eb75 0e03 sbcs.w lr, r5, r3 80208e6: bf22 ittt cs 80208e8: 1ab6 subcs r6, r6, r2 80208ea: 4675 movcs r5, lr 80208ec: ea40 00dc orrcs.w r0, r0, ip, lsr #3 80208f0: ea55 0e06 orrs.w lr, r5, r6 80208f4: d018 beq.n 8020928 <__aeabi_ddiv+0x114> 80208f6: ea4f 1505 mov.w r5, r5, lsl #4 80208fa: ea45 7516 orr.w r5, r5, r6, lsr #28 80208fe: ea4f 1606 mov.w r6, r6, lsl #4 8020902: ea4f 03c3 mov.w r3, r3, lsl #3 8020906: ea43 7352 orr.w r3, r3, r2, lsr #29 802090a: ea4f 02c2 mov.w r2, r2, lsl #3 802090e: ea5f 1c1c movs.w ip, ip, lsr #4 8020912: d1c0 bne.n 8020896 <__aeabi_ddiv+0x82> 8020914: f411 1f80 tst.w r1, #1048576 ; 0x100000 8020918: d10b bne.n 8020932 <__aeabi_ddiv+0x11e> 802091a: ea41 0100 orr.w r1, r1, r0 802091e: f04f 0000 mov.w r0, #0 8020922: f04f 4c00 mov.w ip, #2147483648 ; 0x80000000 8020926: e7b6 b.n 8020896 <__aeabi_ddiv+0x82> 8020928: f411 1f80 tst.w r1, #1048576 ; 0x100000 802092c: bf04 itt eq 802092e: 4301 orreq r1, r0 8020930: 2000 moveq r0, #0 8020932: f1b4 0cfd subs.w ip, r4, #253 ; 0xfd 8020936: bf88 it hi 8020938: f5bc 6fe0 cmphi.w ip, #1792 ; 0x700 802093c: f63f aeaf bhi.w 802069e <__aeabi_dmul+0xde> 8020940: ebb5 0c03 subs.w ip, r5, r3 8020944: bf04 itt eq 8020946: ebb6 0c02 subseq.w ip, r6, r2 802094a: ea5f 0c50 movseq.w ip, r0, lsr #1 802094e: f150 0000 adcs.w r0, r0, #0 8020952: eb41 5104 adc.w r1, r1, r4, lsl #20 8020956: bd70 pop {r4, r5, r6, pc} 8020958: f00e 4e00 and.w lr, lr, #2147483648 ; 0x80000000 802095c: ea4e 3111 orr.w r1, lr, r1, lsr #12 8020960: eb14 045c adds.w r4, r4, ip, lsr #1 8020964: bfc2 ittt gt 8020966: ebd4 050c rsbsgt r5, r4, ip 802096a: ea41 5104 orrgt.w r1, r1, r4, lsl #20 802096e: bd70 popgt {r4, r5, r6, pc} 8020970: f441 1180 orr.w r1, r1, #1048576 ; 0x100000 8020974: f04f 0e00 mov.w lr, #0 8020978: 3c01 subs r4, #1 802097a: e690 b.n 802069e <__aeabi_dmul+0xde> 802097c: ea45 0e06 orr.w lr, r5, r6 8020980: e68d b.n 802069e <__aeabi_dmul+0xde> 8020982: ea0c 5513 and.w r5, ip, r3, lsr #20 8020986: ea94 0f0c teq r4, ip 802098a: bf08 it eq 802098c: ea95 0f0c teqeq r5, ip 8020990: f43f af3b beq.w 802080a <__aeabi_dmul+0x24a> 8020994: ea94 0f0c teq r4, ip 8020998: d10a bne.n 80209b0 <__aeabi_ddiv+0x19c> 802099a: ea50 3401 orrs.w r4, r0, r1, lsl #12 802099e: f47f af34 bne.w 802080a <__aeabi_dmul+0x24a> 80209a2: ea95 0f0c teq r5, ip 80209a6: f47f af25 bne.w 80207f4 <__aeabi_dmul+0x234> 80209aa: 4610 mov r0, r2 80209ac: 4619 mov r1, r3 80209ae: e72c b.n 802080a <__aeabi_dmul+0x24a> 80209b0: ea95 0f0c teq r5, ip 80209b4: d106 bne.n 80209c4 <__aeabi_ddiv+0x1b0> 80209b6: ea52 3503 orrs.w r5, r2, r3, lsl #12 80209ba: f43f aefd beq.w 80207b8 <__aeabi_dmul+0x1f8> 80209be: 4610 mov r0, r2 80209c0: 4619 mov r1, r3 80209c2: e722 b.n 802080a <__aeabi_dmul+0x24a> 80209c4: ea50 0641 orrs.w r6, r0, r1, lsl #1 80209c8: bf18 it ne 80209ca: ea52 0643 orrsne.w r6, r2, r3, lsl #1 80209ce: f47f aec5 bne.w 802075c <__aeabi_dmul+0x19c> 80209d2: ea50 0441 orrs.w r4, r0, r1, lsl #1 80209d6: f47f af0d bne.w 80207f4 <__aeabi_dmul+0x234> 80209da: ea52 0543 orrs.w r5, r2, r3, lsl #1 80209de: f47f aeeb bne.w 80207b8 <__aeabi_dmul+0x1f8> 80209e2: e712 b.n 802080a <__aeabi_dmul+0x24a> 080209e4 <__gedf2>: 80209e4: f04f 3cff mov.w ip, #4294967295 80209e8: e006 b.n 80209f8 <__cmpdf2+0x4> 80209ea: bf00 nop 080209ec <__ledf2>: 80209ec: f04f 0c01 mov.w ip, #1 80209f0: e002 b.n 80209f8 <__cmpdf2+0x4> 80209f2: bf00 nop 080209f4 <__cmpdf2>: 80209f4: f04f 0c01 mov.w ip, #1 80209f8: f84d cd04 str.w ip, [sp, #-4]! 80209fc: ea4f 0c41 mov.w ip, r1, lsl #1 8020a00: ea7f 5c6c mvns.w ip, ip, asr #21 8020a04: ea4f 0c43 mov.w ip, r3, lsl #1 8020a08: bf18 it ne 8020a0a: ea7f 5c6c mvnsne.w ip, ip, asr #21 8020a0e: d01b beq.n 8020a48 <__cmpdf2+0x54> 8020a10: b001 add sp, #4 8020a12: ea50 0c41 orrs.w ip, r0, r1, lsl #1 8020a16: bf0c ite eq 8020a18: ea52 0c43 orrseq.w ip, r2, r3, lsl #1 8020a1c: ea91 0f03 teqne r1, r3 8020a20: bf02 ittt eq 8020a22: ea90 0f02 teqeq r0, r2 8020a26: 2000 moveq r0, #0 8020a28: 4770 bxeq lr 8020a2a: f110 0f00 cmn.w r0, #0 8020a2e: ea91 0f03 teq r1, r3 8020a32: bf58 it pl 8020a34: 4299 cmppl r1, r3 8020a36: bf08 it eq 8020a38: 4290 cmpeq r0, r2 8020a3a: bf2c ite cs 8020a3c: 17d8 asrcs r0, r3, #31 8020a3e: ea6f 70e3 mvncc.w r0, r3, asr #31 8020a42: f040 0001 orr.w r0, r0, #1 8020a46: 4770 bx lr 8020a48: ea4f 0c41 mov.w ip, r1, lsl #1 8020a4c: ea7f 5c6c mvns.w ip, ip, asr #21 8020a50: d102 bne.n 8020a58 <__cmpdf2+0x64> 8020a52: ea50 3c01 orrs.w ip, r0, r1, lsl #12 8020a56: d107 bne.n 8020a68 <__cmpdf2+0x74> 8020a58: ea4f 0c43 mov.w ip, r3, lsl #1 8020a5c: ea7f 5c6c mvns.w ip, ip, asr #21 8020a60: d1d6 bne.n 8020a10 <__cmpdf2+0x1c> 8020a62: ea52 3c03 orrs.w ip, r2, r3, lsl #12 8020a66: d0d3 beq.n 8020a10 <__cmpdf2+0x1c> 8020a68: f85d 0b04 ldr.w r0, [sp], #4 8020a6c: 4770 bx lr 8020a6e: bf00 nop 08020a70 <__aeabi_cdrcmple>: 8020a70: 4684 mov ip, r0 8020a72: 4610 mov r0, r2 8020a74: 4662 mov r2, ip 8020a76: 468c mov ip, r1 8020a78: 4619 mov r1, r3 8020a7a: 4663 mov r3, ip 8020a7c: e000 b.n 8020a80 <__aeabi_cdcmpeq> 8020a7e: bf00 nop 08020a80 <__aeabi_cdcmpeq>: 8020a80: b501 push {r0, lr} 8020a82: f7ff ffb7 bl 80209f4 <__cmpdf2> 8020a86: 2800 cmp r0, #0 8020a88: bf48 it mi 8020a8a: f110 0f00 cmnmi.w r0, #0 8020a8e: bd01 pop {r0, pc} 08020a90 <__aeabi_dcmpeq>: 8020a90: f84d ed08 str.w lr, [sp, #-8]! 8020a94: f7ff fff4 bl 8020a80 <__aeabi_cdcmpeq> 8020a98: bf0c ite eq 8020a9a: 2001 moveq r0, #1 8020a9c: 2000 movne r0, #0 8020a9e: f85d fb08 ldr.w pc, [sp], #8 8020aa2: bf00 nop 08020aa4 <__aeabi_dcmplt>: 8020aa4: f84d ed08 str.w lr, [sp, #-8]! 8020aa8: f7ff ffea bl 8020a80 <__aeabi_cdcmpeq> 8020aac: bf34 ite cc 8020aae: 2001 movcc r0, #1 8020ab0: 2000 movcs r0, #0 8020ab2: f85d fb08 ldr.w pc, [sp], #8 8020ab6: bf00 nop 08020ab8 <__aeabi_dcmple>: 8020ab8: f84d ed08 str.w lr, [sp, #-8]! 8020abc: f7ff ffe0 bl 8020a80 <__aeabi_cdcmpeq> 8020ac0: bf94 ite ls 8020ac2: 2001 movls r0, #1 8020ac4: 2000 movhi r0, #0 8020ac6: f85d fb08 ldr.w pc, [sp], #8 8020aca: bf00 nop 08020acc <__aeabi_dcmpge>: 8020acc: f84d ed08 str.w lr, [sp, #-8]! 8020ad0: f7ff ffce bl 8020a70 <__aeabi_cdrcmple> 8020ad4: bf94 ite ls 8020ad6: 2001 movls r0, #1 8020ad8: 2000 movhi r0, #0 8020ada: f85d fb08 ldr.w pc, [sp], #8 8020ade: bf00 nop 08020ae0 <__aeabi_dcmpgt>: 8020ae0: f84d ed08 str.w lr, [sp, #-8]! 8020ae4: f7ff ffc4 bl 8020a70 <__aeabi_cdrcmple> 8020ae8: bf34 ite cc 8020aea: 2001 movcc r0, #1 8020aec: 2000 movcs r0, #0 8020aee: f85d fb08 ldr.w pc, [sp], #8 8020af2: bf00 nop 08020af4 <__aeabi_d2iz>: 8020af4: ea4f 0241 mov.w r2, r1, lsl #1 8020af8: f512 1200 adds.w r2, r2, #2097152 ; 0x200000 8020afc: d215 bcs.n 8020b2a <__aeabi_d2iz+0x36> 8020afe: d511 bpl.n 8020b24 <__aeabi_d2iz+0x30> 8020b00: f46f 7378 mvn.w r3, #992 ; 0x3e0 8020b04: ebb3 5262 subs.w r2, r3, r2, asr #21 8020b08: d912 bls.n 8020b30 <__aeabi_d2iz+0x3c> 8020b0a: ea4f 23c1 mov.w r3, r1, lsl #11 8020b0e: f043 4300 orr.w r3, r3, #2147483648 ; 0x80000000 8020b12: ea43 5350 orr.w r3, r3, r0, lsr #21 8020b16: f011 4f00 tst.w r1, #2147483648 ; 0x80000000 8020b1a: fa23 f002 lsr.w r0, r3, r2 8020b1e: bf18 it ne 8020b20: 4240 negne r0, r0 8020b22: 4770 bx lr 8020b24: f04f 0000 mov.w r0, #0 8020b28: 4770 bx lr 8020b2a: ea50 3001 orrs.w r0, r0, r1, lsl #12 8020b2e: d105 bne.n 8020b3c <__aeabi_d2iz+0x48> 8020b30: f011 4000 ands.w r0, r1, #2147483648 ; 0x80000000 8020b34: bf08 it eq 8020b36: f06f 4000 mvneq.w r0, #2147483648 ; 0x80000000 8020b3a: 4770 bx lr 8020b3c: f04f 0000 mov.w r0, #0 8020b40: 4770 bx lr 8020b42: bf00 nop 08020b44 <__aeabi_d2f>: 8020b44: ea4f 0241 mov.w r2, r1, lsl #1 8020b48: f1b2 43e0 subs.w r3, r2, #1879048192 ; 0x70000000 8020b4c: bf24 itt cs 8020b4e: f5b3 1c00 subscs.w ip, r3, #2097152 ; 0x200000 8020b52: f1dc 5cfe rsbscs ip, ip, #532676608 ; 0x1fc00000 8020b56: d90d bls.n 8020b74 <__aeabi_d2f+0x30> 8020b58: f001 4c00 and.w ip, r1, #2147483648 ; 0x80000000 8020b5c: ea4f 02c0 mov.w r2, r0, lsl #3 8020b60: ea4c 7050 orr.w r0, ip, r0, lsr #29 8020b64: f1b2 4f00 cmp.w r2, #2147483648 ; 0x80000000 8020b68: eb40 0083 adc.w r0, r0, r3, lsl #2 8020b6c: bf08 it eq 8020b6e: f020 0001 biceq.w r0, r0, #1 8020b72: 4770 bx lr 8020b74: f011 4f80 tst.w r1, #1073741824 ; 0x40000000 8020b78: d121 bne.n 8020bbe <__aeabi_d2f+0x7a> 8020b7a: f113 7238 adds.w r2, r3, #48234496 ; 0x2e00000 8020b7e: bfbc itt lt 8020b80: f001 4000 andlt.w r0, r1, #2147483648 ; 0x80000000 8020b84: 4770 bxlt lr 8020b86: f441 1180 orr.w r1, r1, #1048576 ; 0x100000 8020b8a: ea4f 5252 mov.w r2, r2, lsr #21 8020b8e: f1c2 0218 rsb r2, r2, #24 8020b92: f1c2 0c20 rsb ip, r2, #32 8020b96: fa10 f30c lsls.w r3, r0, ip 8020b9a: fa20 f002 lsr.w r0, r0, r2 8020b9e: bf18 it ne 8020ba0: f040 0001 orrne.w r0, r0, #1 8020ba4: ea4f 23c1 mov.w r3, r1, lsl #11 8020ba8: ea4f 23d3 mov.w r3, r3, lsr #11 8020bac: fa03 fc0c lsl.w ip, r3, ip 8020bb0: ea40 000c orr.w r0, r0, ip 8020bb4: fa23 f302 lsr.w r3, r3, r2 8020bb8: ea4f 0343 mov.w r3, r3, lsl #1 8020bbc: e7cc b.n 8020b58 <__aeabi_d2f+0x14> 8020bbe: ea7f 5362 mvns.w r3, r2, asr #21 8020bc2: d107 bne.n 8020bd4 <__aeabi_d2f+0x90> 8020bc4: ea50 3301 orrs.w r3, r0, r1, lsl #12 8020bc8: bf1e ittt ne 8020bca: f04f 40fe movne.w r0, #2130706432 ; 0x7f000000 8020bce: f440 0040 orrne.w r0, r0, #12582912 ; 0xc00000 8020bd2: 4770 bxne lr 8020bd4: f001 4000 and.w r0, r1, #2147483648 ; 0x80000000 8020bd8: f040 40fe orr.w r0, r0, #2130706432 ; 0x7f000000 8020bdc: f440 0000 orr.w r0, r0, #8388608 ; 0x800000 8020be0: 4770 bx lr 8020be2: bf00 nop 08020be4 <__aeabi_frsub>: 8020be4: f080 4000 eor.w r0, r0, #2147483648 ; 0x80000000 8020be8: e002 b.n 8020bf0 <__addsf3> 8020bea: bf00 nop 08020bec <__aeabi_fsub>: 8020bec: f081 4100 eor.w r1, r1, #2147483648 ; 0x80000000 08020bf0 <__addsf3>: 8020bf0: 0042 lsls r2, r0, #1 8020bf2: bf1f itttt ne 8020bf4: ea5f 0341 movsne.w r3, r1, lsl #1 8020bf8: ea92 0f03 teqne r2, r3 8020bfc: ea7f 6c22 mvnsne.w ip, r2, asr #24 8020c00: ea7f 6c23 mvnsne.w ip, r3, asr #24 8020c04: d06a beq.n 8020cdc <__addsf3+0xec> 8020c06: ea4f 6212 mov.w r2, r2, lsr #24 8020c0a: ebd2 6313 rsbs r3, r2, r3, lsr #24 8020c0e: bfc1 itttt gt 8020c10: 18d2 addgt r2, r2, r3 8020c12: 4041 eorgt r1, r0 8020c14: 4048 eorgt r0, r1 8020c16: 4041 eorgt r1, r0 8020c18: bfb8 it lt 8020c1a: 425b neglt r3, r3 8020c1c: 2b19 cmp r3, #25 8020c1e: bf88 it hi 8020c20: 4770 bxhi lr 8020c22: f010 4f00 tst.w r0, #2147483648 ; 0x80000000 8020c26: f440 0000 orr.w r0, r0, #8388608 ; 0x800000 8020c2a: f020 407f bic.w r0, r0, #4278190080 ; 0xff000000 8020c2e: bf18 it ne 8020c30: 4240 negne r0, r0 8020c32: f011 4f00 tst.w r1, #2147483648 ; 0x80000000 8020c36: f441 0100 orr.w r1, r1, #8388608 ; 0x800000 8020c3a: f021 417f bic.w r1, r1, #4278190080 ; 0xff000000 8020c3e: bf18 it ne 8020c40: 4249 negne r1, r1 8020c42: ea92 0f03 teq r2, r3 8020c46: d03f beq.n 8020cc8 <__addsf3+0xd8> 8020c48: f1a2 0201 sub.w r2, r2, #1 8020c4c: fa41 fc03 asr.w ip, r1, r3 8020c50: eb10 000c adds.w r0, r0, ip 8020c54: f1c3 0320 rsb r3, r3, #32 8020c58: fa01 f103 lsl.w r1, r1, r3 8020c5c: f000 4300 and.w r3, r0, #2147483648 ; 0x80000000 8020c60: d502 bpl.n 8020c68 <__addsf3+0x78> 8020c62: 4249 negs r1, r1 8020c64: eb60 0040 sbc.w r0, r0, r0, lsl #1 8020c68: f5b0 0f00 cmp.w r0, #8388608 ; 0x800000 8020c6c: d313 bcc.n 8020c96 <__addsf3+0xa6> 8020c6e: f1b0 7f80 cmp.w r0, #16777216 ; 0x1000000 8020c72: d306 bcc.n 8020c82 <__addsf3+0x92> 8020c74: 0840 lsrs r0, r0, #1 8020c76: ea4f 0131 mov.w r1, r1, rrx 8020c7a: f102 0201 add.w r2, r2, #1 8020c7e: 2afe cmp r2, #254 ; 0xfe 8020c80: d251 bcs.n 8020d26 <__addsf3+0x136> 8020c82: f1b1 4f00 cmp.w r1, #2147483648 ; 0x80000000 8020c86: eb40 50c2 adc.w r0, r0, r2, lsl #23 8020c8a: bf08 it eq 8020c8c: f020 0001 biceq.w r0, r0, #1 8020c90: ea40 0003 orr.w r0, r0, r3 8020c94: 4770 bx lr 8020c96: 0049 lsls r1, r1, #1 8020c98: eb40 0000 adc.w r0, r0, r0 8020c9c: f410 0f00 tst.w r0, #8388608 ; 0x800000 8020ca0: f1a2 0201 sub.w r2, r2, #1 8020ca4: d1ed bne.n 8020c82 <__addsf3+0x92> 8020ca6: fab0 fc80 clz ip, r0 8020caa: f1ac 0c08 sub.w ip, ip, #8 8020cae: ebb2 020c subs.w r2, r2, ip 8020cb2: fa00 f00c lsl.w r0, r0, ip 8020cb6: bfaa itet ge 8020cb8: eb00 50c2 addge.w r0, r0, r2, lsl #23 8020cbc: 4252 neglt r2, r2 8020cbe: 4318 orrge r0, r3 8020cc0: bfbc itt lt 8020cc2: 40d0 lsrlt r0, r2 8020cc4: 4318 orrlt r0, r3 8020cc6: 4770 bx lr 8020cc8: f092 0f00 teq r2, #0 8020ccc: f481 0100 eor.w r1, r1, #8388608 ; 0x800000 8020cd0: bf06 itte eq 8020cd2: f480 0000 eoreq.w r0, r0, #8388608 ; 0x800000 8020cd6: 3201 addeq r2, #1 8020cd8: 3b01 subne r3, #1 8020cda: e7b5 b.n 8020c48 <__addsf3+0x58> 8020cdc: ea4f 0341 mov.w r3, r1, lsl #1 8020ce0: ea7f 6c22 mvns.w ip, r2, asr #24 8020ce4: bf18 it ne 8020ce6: ea7f 6c23 mvnsne.w ip, r3, asr #24 8020cea: d021 beq.n 8020d30 <__addsf3+0x140> 8020cec: ea92 0f03 teq r2, r3 8020cf0: d004 beq.n 8020cfc <__addsf3+0x10c> 8020cf2: f092 0f00 teq r2, #0 8020cf6: bf08 it eq 8020cf8: 4608 moveq r0, r1 8020cfa: 4770 bx lr 8020cfc: ea90 0f01 teq r0, r1 8020d00: bf1c itt ne 8020d02: 2000 movne r0, #0 8020d04: 4770 bxne lr 8020d06: f012 4f7f tst.w r2, #4278190080 ; 0xff000000 8020d0a: d104 bne.n 8020d16 <__addsf3+0x126> 8020d0c: 0040 lsls r0, r0, #1 8020d0e: bf28 it cs 8020d10: f040 4000 orrcs.w r0, r0, #2147483648 ; 0x80000000 8020d14: 4770 bx lr 8020d16: f112 7200 adds.w r2, r2, #33554432 ; 0x2000000 8020d1a: bf3c itt cc 8020d1c: f500 0000 addcc.w r0, r0, #8388608 ; 0x800000 8020d20: 4770 bxcc lr 8020d22: f000 4300 and.w r3, r0, #2147483648 ; 0x80000000 8020d26: f043 40fe orr.w r0, r3, #2130706432 ; 0x7f000000 8020d2a: f440 0000 orr.w r0, r0, #8388608 ; 0x800000 8020d2e: 4770 bx lr 8020d30: ea7f 6222 mvns.w r2, r2, asr #24 8020d34: bf16 itet ne 8020d36: 4608 movne r0, r1 8020d38: ea7f 6323 mvnseq.w r3, r3, asr #24 8020d3c: 4601 movne r1, r0 8020d3e: 0242 lsls r2, r0, #9 8020d40: bf06 itte eq 8020d42: ea5f 2341 movseq.w r3, r1, lsl #9 8020d46: ea90 0f01 teqeq r0, r1 8020d4a: f440 0080 orrne.w r0, r0, #4194304 ; 0x400000 8020d4e: 4770 bx lr 08020d50 <__aeabi_ui2f>: 8020d50: f04f 0300 mov.w r3, #0 8020d54: e004 b.n 8020d60 <__aeabi_i2f+0x8> 8020d56: bf00 nop 08020d58 <__aeabi_i2f>: 8020d58: f010 4300 ands.w r3, r0, #2147483648 ; 0x80000000 8020d5c: bf48 it mi 8020d5e: 4240 negmi r0, r0 8020d60: ea5f 0c00 movs.w ip, r0 8020d64: bf08 it eq 8020d66: 4770 bxeq lr 8020d68: f043 4396 orr.w r3, r3, #1258291200 ; 0x4b000000 8020d6c: 4601 mov r1, r0 8020d6e: f04f 0000 mov.w r0, #0 8020d72: e01c b.n 8020dae <__aeabi_l2f+0x2a> 08020d74 <__aeabi_ul2f>: 8020d74: ea50 0201 orrs.w r2, r0, r1 8020d78: bf08 it eq 8020d7a: 4770 bxeq lr 8020d7c: f04f 0300 mov.w r3, #0 8020d80: e00a b.n 8020d98 <__aeabi_l2f+0x14> 8020d82: bf00 nop 08020d84 <__aeabi_l2f>: 8020d84: ea50 0201 orrs.w r2, r0, r1 8020d88: bf08 it eq 8020d8a: 4770 bxeq lr 8020d8c: f011 4300 ands.w r3, r1, #2147483648 ; 0x80000000 8020d90: d502 bpl.n 8020d98 <__aeabi_l2f+0x14> 8020d92: 4240 negs r0, r0 8020d94: eb61 0141 sbc.w r1, r1, r1, lsl #1 8020d98: ea5f 0c01 movs.w ip, r1 8020d9c: bf02 ittt eq 8020d9e: 4684 moveq ip, r0 8020da0: 4601 moveq r1, r0 8020da2: 2000 moveq r0, #0 8020da4: f043 43b6 orr.w r3, r3, #1526726656 ; 0x5b000000 8020da8: bf08 it eq 8020daa: f1a3 5380 subeq.w r3, r3, #268435456 ; 0x10000000 8020dae: f5a3 0300 sub.w r3, r3, #8388608 ; 0x800000 8020db2: fabc f28c clz r2, ip 8020db6: 3a08 subs r2, #8 8020db8: eba3 53c2 sub.w r3, r3, r2, lsl #23 8020dbc: db10 blt.n 8020de0 <__aeabi_l2f+0x5c> 8020dbe: fa01 fc02 lsl.w ip, r1, r2 8020dc2: 4463 add r3, ip 8020dc4: fa00 fc02 lsl.w ip, r0, r2 8020dc8: f1c2 0220 rsb r2, r2, #32 8020dcc: f1bc 4f00 cmp.w ip, #2147483648 ; 0x80000000 8020dd0: fa20 f202 lsr.w r2, r0, r2 8020dd4: eb43 0002 adc.w r0, r3, r2 8020dd8: bf08 it eq 8020dda: f020 0001 biceq.w r0, r0, #1 8020dde: 4770 bx lr 8020de0: f102 0220 add.w r2, r2, #32 8020de4: fa01 fc02 lsl.w ip, r1, r2 8020de8: f1c2 0220 rsb r2, r2, #32 8020dec: ea50 004c orrs.w r0, r0, ip, lsl #1 8020df0: fa21 f202 lsr.w r2, r1, r2 8020df4: eb43 0002 adc.w r0, r3, r2 8020df8: bf08 it eq 8020dfa: ea20 70dc biceq.w r0, r0, ip, lsr #31 8020dfe: 4770 bx lr 08020e00 <__gesf2>: 8020e00: f04f 3cff mov.w ip, #4294967295 8020e04: e006 b.n 8020e14 <__cmpsf2+0x4> 8020e06: bf00 nop 08020e08 <__lesf2>: 8020e08: f04f 0c01 mov.w ip, #1 8020e0c: e002 b.n 8020e14 <__cmpsf2+0x4> 8020e0e: bf00 nop 08020e10 <__cmpsf2>: 8020e10: f04f 0c01 mov.w ip, #1 8020e14: f84d cd04 str.w ip, [sp, #-4]! 8020e18: ea4f 0240 mov.w r2, r0, lsl #1 8020e1c: ea4f 0341 mov.w r3, r1, lsl #1 8020e20: ea7f 6c22 mvns.w ip, r2, asr #24 8020e24: bf18 it ne 8020e26: ea7f 6c23 mvnsne.w ip, r3, asr #24 8020e2a: d011 beq.n 8020e50 <__cmpsf2+0x40> 8020e2c: b001 add sp, #4 8020e2e: ea52 0c53 orrs.w ip, r2, r3, lsr #1 8020e32: bf18 it ne 8020e34: ea90 0f01 teqne r0, r1 8020e38: bf58 it pl 8020e3a: ebb2 0003 subspl.w r0, r2, r3 8020e3e: bf88 it hi 8020e40: 17c8 asrhi r0, r1, #31 8020e42: bf38 it cc 8020e44: ea6f 70e1 mvncc.w r0, r1, asr #31 8020e48: bf18 it ne 8020e4a: f040 0001 orrne.w r0, r0, #1 8020e4e: 4770 bx lr 8020e50: ea7f 6c22 mvns.w ip, r2, asr #24 8020e54: d102 bne.n 8020e5c <__cmpsf2+0x4c> 8020e56: ea5f 2c40 movs.w ip, r0, lsl #9 8020e5a: d105 bne.n 8020e68 <__cmpsf2+0x58> 8020e5c: ea7f 6c23 mvns.w ip, r3, asr #24 8020e60: d1e4 bne.n 8020e2c <__cmpsf2+0x1c> 8020e62: ea5f 2c41 movs.w ip, r1, lsl #9 8020e66: d0e1 beq.n 8020e2c <__cmpsf2+0x1c> 8020e68: f85d 0b04 ldr.w r0, [sp], #4 8020e6c: 4770 bx lr 8020e6e: bf00 nop 08020e70 <__aeabi_cfrcmple>: 8020e70: 4684 mov ip, r0 8020e72: 4608 mov r0, r1 8020e74: 4661 mov r1, ip 8020e76: e7ff b.n 8020e78 <__aeabi_cfcmpeq> 08020e78 <__aeabi_cfcmpeq>: 8020e78: b50f push {r0, r1, r2, r3, lr} 8020e7a: f7ff ffc9 bl 8020e10 <__cmpsf2> 8020e7e: 2800 cmp r0, #0 8020e80: bf48 it mi 8020e82: f110 0f00 cmnmi.w r0, #0 8020e86: bd0f pop {r0, r1, r2, r3, pc} 08020e88 <__aeabi_fcmpeq>: 8020e88: f84d ed08 str.w lr, [sp, #-8]! 8020e8c: f7ff fff4 bl 8020e78 <__aeabi_cfcmpeq> 8020e90: bf0c ite eq 8020e92: 2001 moveq r0, #1 8020e94: 2000 movne r0, #0 8020e96: f85d fb08 ldr.w pc, [sp], #8 8020e9a: bf00 nop 08020e9c <__aeabi_fcmplt>: 8020e9c: f84d ed08 str.w lr, [sp, #-8]! 8020ea0: f7ff ffea bl 8020e78 <__aeabi_cfcmpeq> 8020ea4: bf34 ite cc 8020ea6: 2001 movcc r0, #1 8020ea8: 2000 movcs r0, #0 8020eaa: f85d fb08 ldr.w pc, [sp], #8 8020eae: bf00 nop 08020eb0 <__aeabi_fcmple>: 8020eb0: f84d ed08 str.w lr, [sp, #-8]! 8020eb4: f7ff ffe0 bl 8020e78 <__aeabi_cfcmpeq> 8020eb8: bf94 ite ls 8020eba: 2001 movls r0, #1 8020ebc: 2000 movhi r0, #0 8020ebe: f85d fb08 ldr.w pc, [sp], #8 8020ec2: bf00 nop 08020ec4 <__aeabi_fcmpge>: 8020ec4: f84d ed08 str.w lr, [sp, #-8]! 8020ec8: f7ff ffd2 bl 8020e70 <__aeabi_cfrcmple> 8020ecc: bf94 ite ls 8020ece: 2001 movls r0, #1 8020ed0: 2000 movhi r0, #0 8020ed2: f85d fb08 ldr.w pc, [sp], #8 8020ed6: bf00 nop 08020ed8 <__aeabi_fcmpgt>: 8020ed8: f84d ed08 str.w lr, [sp, #-8]! 8020edc: f7ff ffc8 bl 8020e70 <__aeabi_cfrcmple> 8020ee0: bf34 ite cc 8020ee2: 2001 movcc r0, #1 8020ee4: 2000 movcs r0, #0 8020ee6: f85d fb08 ldr.w pc, [sp], #8 8020eea: bf00 nop 08020eec <__aeabi_uldivmod>: 8020eec: b94b cbnz r3, 8020f02 <__aeabi_uldivmod+0x16> 8020eee: b942 cbnz r2, 8020f02 <__aeabi_uldivmod+0x16> 8020ef0: 2900 cmp r1, #0 8020ef2: bf08 it eq 8020ef4: 2800 cmpeq r0, #0 8020ef6: d002 beq.n 8020efe <__aeabi_uldivmod+0x12> 8020ef8: f04f 31ff mov.w r1, #4294967295 8020efc: 4608 mov r0, r1 8020efe: f000 b83b b.w 8020f78 <__aeabi_idiv0> 8020f02: b082 sub sp, #8 8020f04: 46ec mov ip, sp 8020f06: e92d 5000 stmdb sp!, {ip, lr} 8020f0a: f000 f81d bl 8020f48 <__gnu_uldivmod_helper> 8020f0e: f8dd e004 ldr.w lr, [sp, #4] 8020f12: b002 add sp, #8 8020f14: bc0c pop {r2, r3} 8020f16: 4770 bx lr 08020f18 <__gnu_ldivmod_helper>: 8020f18: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 8020f1c: 4690 mov r8, r2 8020f1e: 4699 mov r9, r3 8020f20: 4606 mov r6, r0 8020f22: 460f mov r7, r1 8020f24: f000 f82a bl 8020f7c <__divdi3> 8020f28: 9b08 ldr r3, [sp, #32] 8020f2a: fba8 4500 umull r4, r5, r8, r0 8020f2e: fb08 f801 mul.w r8, r8, r1 8020f32: fb00 8209 mla r2, r0, r9, r8 8020f36: 1955 adds r5, r2, r5 8020f38: 1b34 subs r4, r6, r4 8020f3a: eb67 0505 sbc.w r5, r7, r5 8020f3e: e9c3 4500 strd r4, r5, [r3] 8020f42: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 8020f46: bf00 nop 08020f48 <__gnu_uldivmod_helper>: 8020f48: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8020f4c: 4690 mov r8, r2 8020f4e: 4606 mov r6, r0 8020f50: 460f mov r7, r1 8020f52: 461d mov r5, r3 8020f54: f000 f9c8 bl 80212e8 <__udivdi3> 8020f58: fb00 f305 mul.w r3, r0, r5 8020f5c: fba0 4508 umull r4, r5, r0, r8 8020f60: fb08 3801 mla r8, r8, r1, r3 8020f64: 9b06 ldr r3, [sp, #24] 8020f66: 4445 add r5, r8 8020f68: 1b34 subs r4, r6, r4 8020f6a: eb67 0505 sbc.w r5, r7, r5 8020f6e: e9c3 4500 strd r4, r5, [r3] 8020f72: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8020f76: bf00 nop 08020f78 <__aeabi_idiv0>: 8020f78: 4770 bx lr 8020f7a: bf00 nop 08020f7c <__divdi3>: 8020f7c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8020f80: 2500 movs r5, #0 8020f82: 2900 cmp r1, #0 8020f84: b085 sub sp, #20 8020f86: 461c mov r4, r3 8020f88: f2c0 8149 blt.w 802121e <__divdi3+0x2a2> 8020f8c: 2c00 cmp r4, #0 8020f8e: f2c0 8141 blt.w 8021214 <__divdi3+0x298> 8020f92: 468c mov ip, r1 8020f94: 460f mov r7, r1 8020f96: 4682 mov sl, r0 8020f98: 4691 mov r9, r2 8020f9a: 4614 mov r4, r2 8020f9c: 4606 mov r6, r0 8020f9e: 4619 mov r1, r3 8020fa0: 2b00 cmp r3, #0 8020fa2: d14b bne.n 802103c <__divdi3+0xc0> 8020fa4: 4562 cmp r2, ip 8020fa6: d959 bls.n 802105c <__divdi3+0xe0> 8020fa8: fab2 f382 clz r3, r2 8020fac: b143 cbz r3, 8020fc0 <__divdi3+0x44> 8020fae: f1c3 0220 rsb r2, r3, #32 8020fb2: fa0c f703 lsl.w r7, ip, r3 8020fb6: fa20 f202 lsr.w r2, r0, r2 8020fba: 409c lsls r4, r3 8020fbc: 4317 orrs r7, r2 8020fbe: 409e lsls r6, r3 8020fc0: ea4f 4814 mov.w r8, r4, lsr #16 8020fc4: 4638 mov r0, r7 8020fc6: 4641 mov r1, r8 8020fc8: fa1f f984 uxth.w r9, r4 8020fcc: f000 fb18 bl 8021600 <__aeabi_uidiv> 8020fd0: 4641 mov r1, r8 8020fd2: 4682 mov sl, r0 8020fd4: 4638 mov r0, r7 8020fd6: f000 fc41 bl 802185c <__aeabi_uidivmod> 8020fda: 0c33 lsrs r3, r6, #16 8020fdc: fb09 f00a mul.w r0, r9, sl 8020fe0: ea43 4101 orr.w r1, r3, r1, lsl #16 8020fe4: 4288 cmp r0, r1 8020fe6: d90a bls.n 8020ffe <__divdi3+0x82> 8020fe8: 1909 adds r1, r1, r4 8020fea: f10a 32ff add.w r2, sl, #4294967295 8020fee: d205 bcs.n 8020ffc <__divdi3+0x80> 8020ff0: 4288 cmp r0, r1 8020ff2: bf84 itt hi 8020ff4: f1aa 0a02 subhi.w sl, sl, #2 8020ff8: 1909 addhi r1, r1, r4 8020ffa: d800 bhi.n 8020ffe <__divdi3+0x82> 8020ffc: 4692 mov sl, r2 8020ffe: ebc0 0b01 rsb fp, r0, r1 8021002: 4641 mov r1, r8 8021004: 4658 mov r0, fp 8021006: b2b6 uxth r6, r6 8021008: f000 fafa bl 8021600 <__aeabi_uidiv> 802100c: 4641 mov r1, r8 802100e: 4607 mov r7, r0 8021010: 4658 mov r0, fp 8021012: f000 fc23 bl 802185c <__aeabi_uidivmod> 8021016: fb09 f907 mul.w r9, r9, r7 802101a: ea46 4101 orr.w r1, r6, r1, lsl #16 802101e: 4589 cmp r9, r1 8021020: d907 bls.n 8021032 <__divdi3+0xb6> 8021022: 1e7b subs r3, r7, #1 8021024: 190c adds r4, r1, r4 8021026: f080 8157 bcs.w 80212d8 <__divdi3+0x35c> 802102a: 3f02 subs r7, #2 802102c: 45a1 cmp r9, r4 802102e: f240 8153 bls.w 80212d8 <__divdi3+0x35c> 8021032: ea47 400a orr.w r0, r7, sl, lsl #16 8021036: f04f 0800 mov.w r8, #0 802103a: e004 b.n 8021046 <__divdi3+0xca> 802103c: 4563 cmp r3, ip 802103e: d958 bls.n 80210f2 <__divdi3+0x176> 8021040: f04f 0800 mov.w r8, #0 8021044: 4640 mov r0, r8 8021046: 4602 mov r2, r0 8021048: 4643 mov r3, r8 802104a: b115 cbz r5, 8021052 <__divdi3+0xd6> 802104c: 4252 negs r2, r2 802104e: eb63 0343 sbc.w r3, r3, r3, lsl #1 8021052: 4610 mov r0, r2 8021054: 4619 mov r1, r3 8021056: b005 add sp, #20 8021058: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802105c: b922 cbnz r2, 8021068 <__divdi3+0xec> 802105e: 2001 movs r0, #1 8021060: 4611 mov r1, r2 8021062: f000 facd bl 8021600 <__aeabi_uidiv> 8021066: 4604 mov r4, r0 8021068: fab4 f384 clz r3, r4 802106c: 2b00 cmp r3, #0 802106e: f040 80dc bne.w 802122a <__divdi3+0x2ae> 8021072: 1b3f subs r7, r7, r4 8021074: ea4f 4914 mov.w r9, r4, lsr #16 8021078: fa1f fa84 uxth.w sl, r4 802107c: f04f 0801 mov.w r8, #1 8021080: 4649 mov r1, r9 8021082: 4638 mov r0, r7 8021084: f000 fabc bl 8021600 <__aeabi_uidiv> 8021088: 4649 mov r1, r9 802108a: 4683 mov fp, r0 802108c: 4638 mov r0, r7 802108e: f000 fbe5 bl 802185c <__aeabi_uidivmod> 8021092: 0c33 lsrs r3, r6, #16 8021094: fb0a f00b mul.w r0, sl, fp 8021098: ea43 4101 orr.w r1, r3, r1, lsl #16 802109c: 4288 cmp r0, r1 802109e: d90b bls.n 80210b8 <__divdi3+0x13c> 80210a0: 1909 adds r1, r1, r4 80210a2: f10b 33ff add.w r3, fp, #4294967295 80210a6: f080 8115 bcs.w 80212d4 <__divdi3+0x358> 80210aa: 4288 cmp r0, r1 80210ac: bf84 itt hi 80210ae: f1ab 0b02 subhi.w fp, fp, #2 80210b2: 1909 addhi r1, r1, r4 80210b4: f240 810e bls.w 80212d4 <__divdi3+0x358> 80210b8: 1a0b subs r3, r1, r0 80210ba: 4649 mov r1, r9 80210bc: 4618 mov r0, r3 80210be: 9301 str r3, [sp, #4] 80210c0: f000 fa9e bl 8021600 <__aeabi_uidiv> 80210c4: 9b01 ldr r3, [sp, #4] 80210c6: 4649 mov r1, r9 80210c8: b2b6 uxth r6, r6 80210ca: 4607 mov r7, r0 80210cc: 4618 mov r0, r3 80210ce: f000 fbc5 bl 802185c <__aeabi_uidivmod> 80210d2: fb0a fa07 mul.w sl, sl, r7 80210d6: ea46 4101 orr.w r1, r6, r1, lsl #16 80210da: 458a cmp sl, r1 80210dc: d906 bls.n 80210ec <__divdi3+0x170> 80210de: 1e7b subs r3, r7, #1 80210e0: 190c adds r4, r1, r4 80210e2: d202 bcs.n 80210ea <__divdi3+0x16e> 80210e4: 3f02 subs r7, #2 80210e6: 45a2 cmp sl, r4 80210e8: d800 bhi.n 80210ec <__divdi3+0x170> 80210ea: 461f mov r7, r3 80210ec: ea47 400b orr.w r0, r7, fp, lsl #16 80210f0: e7a9 b.n 8021046 <__divdi3+0xca> 80210f2: fab3 f483 clz r4, r3 80210f6: 2c00 cmp r4, #0 80210f8: f000 80e4 beq.w 80212c4 <__divdi3+0x348> 80210fc: f1c4 0320 rsb r3, r4, #32 8021100: fa01 f104 lsl.w r1, r1, r4 8021104: fa22 fa03 lsr.w sl, r2, r3 8021108: fa2c fb03 lsr.w fp, ip, r3 802110c: ea4a 0a01 orr.w sl, sl, r1 8021110: fa20 f803 lsr.w r8, r0, r3 8021114: fa0c fc04 lsl.w ip, ip, r4 8021118: 4658 mov r0, fp 802111a: ea4f 471a mov.w r7, sl, lsr #16 802111e: ea48 080c orr.w r8, r8, ip 8021122: 4639 mov r1, r7 8021124: fa02 f904 lsl.w r9, r2, r4 8021128: f8cd 900c str.w r9, [sp, #12] 802112c: f000 fa68 bl 8021600 <__aeabi_uidiv> 8021130: 4639 mov r1, r7 8021132: 4681 mov r9, r0 8021134: 4658 mov r0, fp 8021136: f000 fb91 bl 802185c <__aeabi_uidivmod> 802113a: fa1f fc8a uxth.w ip, sl 802113e: ea4f 4318 mov.w r3, r8, lsr #16 8021142: fb0c f009 mul.w r0, ip, r9 8021146: ea43 4301 orr.w r3, r3, r1, lsl #16 802114a: 4298 cmp r0, r3 802114c: d90c bls.n 8021168 <__divdi3+0x1ec> 802114e: eb13 030a adds.w r3, r3, sl 8021152: f109 31ff add.w r1, r9, #4294967295 8021156: f080 80c3 bcs.w 80212e0 <__divdi3+0x364> 802115a: 4298 cmp r0, r3 802115c: bf84 itt hi 802115e: f1a9 0902 subhi.w r9, r9, #2 8021162: 4453 addhi r3, sl 8021164: f240 80bc bls.w 80212e0 <__divdi3+0x364> 8021168: 1a1b subs r3, r3, r0 802116a: 4639 mov r1, r7 802116c: 4618 mov r0, r3 802116e: f8cd c008 str.w ip, [sp, #8] 8021172: 9301 str r3, [sp, #4] 8021174: f000 fa44 bl 8021600 <__aeabi_uidiv> 8021178: 9b01 ldr r3, [sp, #4] 802117a: 4639 mov r1, r7 802117c: fa1f f888 uxth.w r8, r8 8021180: 4683 mov fp, r0 8021182: 4618 mov r0, r3 8021184: f000 fb6a bl 802185c <__aeabi_uidivmod> 8021188: f8dd c008 ldr.w ip, [sp, #8] 802118c: fb0c f30b mul.w r3, ip, fp 8021190: ea48 4101 orr.w r1, r8, r1, lsl #16 8021194: 428b cmp r3, r1 8021196: d90c bls.n 80211b2 <__divdi3+0x236> 8021198: eb11 010a adds.w r1, r1, sl 802119c: f10b 30ff add.w r0, fp, #4294967295 80211a0: f080 809c bcs.w 80212dc <__divdi3+0x360> 80211a4: 428b cmp r3, r1 80211a6: bf84 itt hi 80211a8: f1ab 0b02 subhi.w fp, fp, #2 80211ac: 4451 addhi r1, sl 80211ae: f240 8095 bls.w 80212dc <__divdi3+0x360> 80211b2: 9f03 ldr r7, [sp, #12] 80211b4: ea4b 4009 orr.w r0, fp, r9, lsl #16 80211b8: 1ac9 subs r1, r1, r3 80211ba: fa1f fc80 uxth.w ip, r0 80211be: b2ba uxth r2, r7 80211c0: ea4f 4917 mov.w r9, r7, lsr #16 80211c4: 0c07 lsrs r7, r0, #16 80211c6: fb02 f80c mul.w r8, r2, ip 80211ca: fb02 f207 mul.w r2, r2, r7 80211ce: fb09 230c mla r3, r9, ip, r2 80211d2: fb09 f907 mul.w r9, r9, r7 80211d6: eb03 4318 add.w r3, r3, r8, lsr #16 80211da: 429a cmp r2, r3 80211dc: bf88 it hi 80211de: f509 3980 addhi.w r9, r9, #65536 ; 0x10000 80211e2: eb09 4913 add.w r9, r9, r3, lsr #16 80211e6: 4549 cmp r1, r9 80211e8: d310 bcc.n 802120c <__divdi3+0x290> 80211ea: fa1f f888 uxth.w r8, r8 80211ee: bf14 ite ne 80211f0: 2200 movne r2, #0 80211f2: 2201 moveq r2, #1 80211f4: fa06 f404 lsl.w r4, r6, r4 80211f8: eb08 4303 add.w r3, r8, r3, lsl #16 80211fc: 429c cmp r4, r3 80211fe: bf2c ite cs 8021200: 2300 movcs r3, #0 8021202: f002 0301 andcc.w r3, r2, #1 8021206: 2b00 cmp r3, #0 8021208: f43f af15 beq.w 8021036 <__divdi3+0xba> 802120c: 3801 subs r0, #1 802120e: f04f 0800 mov.w r8, #0 8021212: e718 b.n 8021046 <__divdi3+0xca> 8021214: 4252 negs r2, r2 8021216: eb63 0343 sbc.w r3, r3, r3, lsl #1 802121a: 43ed mvns r5, r5 802121c: e6b9 b.n 8020f92 <__divdi3+0x16> 802121e: 4240 negs r0, r0 8021220: eb61 0141 sbc.w r1, r1, r1, lsl #1 8021224: f04f 35ff mov.w r5, #4294967295 8021228: e6b0 b.n 8020f8c <__divdi3+0x10> 802122a: 409c lsls r4, r3 802122c: f1c3 0b20 rsb fp, r3, #32 8021230: fa27 f80b lsr.w r8, r7, fp 8021234: fa07 f703 lsl.w r7, r7, r3 8021238: ea4f 4914 mov.w r9, r4, lsr #16 802123c: 4640 mov r0, r8 802123e: 4649 mov r1, r9 8021240: fa26 fb0b lsr.w fp, r6, fp 8021244: 409e lsls r6, r3 8021246: f000 f9db bl 8021600 <__aeabi_uidiv> 802124a: 4649 mov r1, r9 802124c: fa1f fa84 uxth.w sl, r4 8021250: ea4b 0b07 orr.w fp, fp, r7 8021254: 4603 mov r3, r0 8021256: 4640 mov r0, r8 8021258: 9301 str r3, [sp, #4] 802125a: f000 faff bl 802185c <__aeabi_uidivmod> 802125e: 9b01 ldr r3, [sp, #4] 8021260: ea4f 421b mov.w r2, fp, lsr #16 8021264: fb0a f003 mul.w r0, sl, r3 8021268: ea42 4101 orr.w r1, r2, r1, lsl #16 802126c: 4288 cmp r0, r1 802126e: d906 bls.n 802127e <__divdi3+0x302> 8021270: 1e5a subs r2, r3, #1 8021272: 1909 adds r1, r1, r4 8021274: d236 bcs.n 80212e4 <__divdi3+0x368> 8021276: 4288 cmp r0, r1 8021278: d934 bls.n 80212e4 <__divdi3+0x368> 802127a: 3b02 subs r3, #2 802127c: 1909 adds r1, r1, r4 802127e: 1a0f subs r7, r1, r0 8021280: 4649 mov r1, r9 8021282: 4638 mov r0, r7 8021284: 9301 str r3, [sp, #4] 8021286: f000 f9bb bl 8021600 <__aeabi_uidiv> 802128a: 4649 mov r1, r9 802128c: fa1f fb8b uxth.w fp, fp 8021290: 4680 mov r8, r0 8021292: 4638 mov r0, r7 8021294: f000 fae2 bl 802185c <__aeabi_uidivmod> 8021298: 9b01 ldr r3, [sp, #4] 802129a: fb0a f708 mul.w r7, sl, r8 802129e: ea4b 4101 orr.w r1, fp, r1, lsl #16 80212a2: 428f cmp r7, r1 80212a4: d90a bls.n 80212bc <__divdi3+0x340> 80212a6: 1909 adds r1, r1, r4 80212a8: f108 32ff add.w r2, r8, #4294967295 80212ac: d205 bcs.n 80212ba <__divdi3+0x33e> 80212ae: 428f cmp r7, r1 80212b0: bf84 itt hi 80212b2: f1a8 0802 subhi.w r8, r8, #2 80212b6: 1909 addhi r1, r1, r4 80212b8: d800 bhi.n 80212bc <__divdi3+0x340> 80212ba: 4690 mov r8, r2 80212bc: 1bcf subs r7, r1, r7 80212be: ea48 4803 orr.w r8, r8, r3, lsl #16 80212c2: e6dd b.n 8021080 <__divdi3+0x104> 80212c4: 2001 movs r0, #1 80212c6: 4563 cmp r3, ip 80212c8: bf28 it cs 80212ca: 4552 cmpcs r2, sl 80212cc: 46a0 mov r8, r4 80212ce: f67f aeba bls.w 8021046 <__divdi3+0xca> 80212d2: e6b5 b.n 8021040 <__divdi3+0xc4> 80212d4: 469b mov fp, r3 80212d6: e6ef b.n 80210b8 <__divdi3+0x13c> 80212d8: 461f mov r7, r3 80212da: e6aa b.n 8021032 <__divdi3+0xb6> 80212dc: 4683 mov fp, r0 80212de: e768 b.n 80211b2 <__divdi3+0x236> 80212e0: 4689 mov r9, r1 80212e2: e741 b.n 8021168 <__divdi3+0x1ec> 80212e4: 4613 mov r3, r2 80212e6: e7ca b.n 802127e <__divdi3+0x302> 080212e8 <__udivdi3>: 80212e8: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 80212ec: 4606 mov r6, r0 80212ee: b083 sub sp, #12 80212f0: 460d mov r5, r1 80212f2: 4614 mov r4, r2 80212f4: 4607 mov r7, r0 80212f6: 4688 mov r8, r1 80212f8: 2b00 cmp r3, #0 80212fa: d14a bne.n 8021392 <__udivdi3+0xaa> 80212fc: 428a cmp r2, r1 80212fe: d955 bls.n 80213ac <__udivdi3+0xc4> 8021300: fab2 f382 clz r3, r2 8021304: b14b cbz r3, 802131a <__udivdi3+0x32> 8021306: f1c3 0220 rsb r2, r3, #32 802130a: fa01 f803 lsl.w r8, r1, r3 802130e: fa20 f202 lsr.w r2, r0, r2 8021312: 409c lsls r4, r3 8021314: ea42 0808 orr.w r8, r2, r8 8021318: 409f lsls r7, r3 802131a: 0c25 lsrs r5, r4, #16 802131c: 4640 mov r0, r8 802131e: 4629 mov r1, r5 8021320: fa1f fa84 uxth.w sl, r4 8021324: f000 f96c bl 8021600 <__aeabi_uidiv> 8021328: 4629 mov r1, r5 802132a: 4681 mov r9, r0 802132c: 4640 mov r0, r8 802132e: f000 fa95 bl 802185c <__aeabi_uidivmod> 8021332: 0c3b lsrs r3, r7, #16 8021334: fb0a f009 mul.w r0, sl, r9 8021338: ea43 4101 orr.w r1, r3, r1, lsl #16 802133c: 4288 cmp r0, r1 802133e: d90a bls.n 8021356 <__udivdi3+0x6e> 8021340: 1909 adds r1, r1, r4 8021342: f109 32ff add.w r2, r9, #4294967295 8021346: d205 bcs.n 8021354 <__udivdi3+0x6c> 8021348: 4288 cmp r0, r1 802134a: bf84 itt hi 802134c: f1a9 0902 subhi.w r9, r9, #2 8021350: 1909 addhi r1, r1, r4 8021352: d800 bhi.n 8021356 <__udivdi3+0x6e> 8021354: 4691 mov r9, r2 8021356: ebc0 0801 rsb r8, r0, r1 802135a: 4629 mov r1, r5 802135c: 4640 mov r0, r8 802135e: b2bf uxth r7, r7 8021360: f000 f94e bl 8021600 <__aeabi_uidiv> 8021364: 4629 mov r1, r5 8021366: 4606 mov r6, r0 8021368: 4640 mov r0, r8 802136a: f000 fa77 bl 802185c <__aeabi_uidivmod> 802136e: fb0a fa06 mul.w sl, sl, r6 8021372: ea47 4101 orr.w r1, r7, r1, lsl #16 8021376: 458a cmp sl, r1 8021378: d907 bls.n 802138a <__udivdi3+0xa2> 802137a: 1e73 subs r3, r6, #1 802137c: 190c adds r4, r1, r4 802137e: f080 8122 bcs.w 80215c6 <__udivdi3+0x2de> 8021382: 3e02 subs r6, #2 8021384: 45a2 cmp sl, r4 8021386: f240 811e bls.w 80215c6 <__udivdi3+0x2de> 802138a: ea46 4009 orr.w r0, r6, r9, lsl #16 802138e: 2600 movs r6, #0 8021390: e058 b.n 8021444 <__udivdi3+0x15c> 8021392: 428b cmp r3, r1 8021394: d854 bhi.n 8021440 <__udivdi3+0x158> 8021396: fab3 f483 clz r4, r3 802139a: 2c00 cmp r4, #0 802139c: d156 bne.n 802144c <__udivdi3+0x164> 802139e: 428b cmp r3, r1 80213a0: bf28 it cs 80213a2: 4282 cmpcs r2, r0 80213a4: d84c bhi.n 8021440 <__udivdi3+0x158> 80213a6: 4626 mov r6, r4 80213a8: 2001 movs r0, #1 80213aa: e04b b.n 8021444 <__udivdi3+0x15c> 80213ac: b922 cbnz r2, 80213b8 <__udivdi3+0xd0> 80213ae: 2001 movs r0, #1 80213b0: 4611 mov r1, r2 80213b2: f000 f925 bl 8021600 <__aeabi_uidiv> 80213b6: 4604 mov r4, r0 80213b8: fab4 f384 clz r3, r4 80213bc: 2b00 cmp r3, #0 80213be: f040 80b9 bne.w 8021534 <__udivdi3+0x24c> 80213c2: 1b2d subs r5, r5, r4 80213c4: ea4f 4814 mov.w r8, r4, lsr #16 80213c8: fa1f fa84 uxth.w sl, r4 80213cc: 2601 movs r6, #1 80213ce: 4641 mov r1, r8 80213d0: 4628 mov r0, r5 80213d2: f000 f915 bl 8021600 <__aeabi_uidiv> 80213d6: 4641 mov r1, r8 80213d8: 4681 mov r9, r0 80213da: 4628 mov r0, r5 80213dc: f000 fa3e bl 802185c <__aeabi_uidivmod> 80213e0: 0c3b lsrs r3, r7, #16 80213e2: fb0a f009 mul.w r0, sl, r9 80213e6: ea43 4101 orr.w r1, r3, r1, lsl #16 80213ea: 4288 cmp r0, r1 80213ec: d90b bls.n 8021406 <__udivdi3+0x11e> 80213ee: 1909 adds r1, r1, r4 80213f0: f109 33ff add.w r3, r9, #4294967295 80213f4: f080 80e9 bcs.w 80215ca <__udivdi3+0x2e2> 80213f8: 4288 cmp r0, r1 80213fa: bf84 itt hi 80213fc: f1a9 0902 subhi.w r9, r9, #2 8021400: 1909 addhi r1, r1, r4 8021402: f240 80e2 bls.w 80215ca <__udivdi3+0x2e2> 8021406: ebc0 0b01 rsb fp, r0, r1 802140a: 4641 mov r1, r8 802140c: 4658 mov r0, fp 802140e: b2bf uxth r7, r7 8021410: f000 f8f6 bl 8021600 <__aeabi_uidiv> 8021414: 4641 mov r1, r8 8021416: 4605 mov r5, r0 8021418: 4658 mov r0, fp 802141a: f000 fa1f bl 802185c <__aeabi_uidivmod> 802141e: fb0a fa05 mul.w sl, sl, r5 8021422: ea47 4101 orr.w r1, r7, r1, lsl #16 8021426: 458a cmp sl, r1 8021428: d907 bls.n 802143a <__udivdi3+0x152> 802142a: 1e6b subs r3, r5, #1 802142c: 190c adds r4, r1, r4 802142e: f080 80ce bcs.w 80215ce <__udivdi3+0x2e6> 8021432: 3d02 subs r5, #2 8021434: 45a2 cmp sl, r4 8021436: f240 80ca bls.w 80215ce <__udivdi3+0x2e6> 802143a: ea45 4009 orr.w r0, r5, r9, lsl #16 802143e: e001 b.n 8021444 <__udivdi3+0x15c> 8021440: 2600 movs r6, #0 8021442: 4630 mov r0, r6 8021444: 4631 mov r1, r6 8021446: b003 add sp, #12 8021448: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802144c: f1c4 0120 rsb r1, r4, #32 8021450: fa03 f304 lsl.w r3, r3, r4 8021454: fa22 f801 lsr.w r8, r2, r1 8021458: fa25 f701 lsr.w r7, r5, r1 802145c: ea48 0803 orr.w r8, r8, r3 8021460: fa20 f101 lsr.w r1, r0, r1 8021464: fa05 f504 lsl.w r5, r5, r4 8021468: 4638 mov r0, r7 802146a: ea4f 4918 mov.w r9, r8, lsr #16 802146e: 430d orrs r5, r1 8021470: 4649 mov r1, r9 8021472: fa02 f204 lsl.w r2, r2, r4 8021476: 9201 str r2, [sp, #4] 8021478: f000 f8c2 bl 8021600 <__aeabi_uidiv> 802147c: 4649 mov r1, r9 802147e: 4682 mov sl, r0 8021480: 4638 mov r0, r7 8021482: f000 f9eb bl 802185c <__aeabi_uidivmod> 8021486: fa1f f288 uxth.w r2, r8 802148a: 0c2f lsrs r7, r5, #16 802148c: fb02 f00a mul.w r0, r2, sl 8021490: ea47 4701 orr.w r7, r7, r1, lsl #16 8021494: 42b8 cmp r0, r7 8021496: d906 bls.n 80214a6 <__udivdi3+0x1be> 8021498: eb17 0708 adds.w r7, r7, r8 802149c: f10a 31ff add.w r1, sl, #4294967295 80214a0: f0c0 809f bcc.w 80215e2 <__udivdi3+0x2fa> 80214a4: 468a mov sl, r1 80214a6: 1a3f subs r7, r7, r0 80214a8: 4649 mov r1, r9 80214aa: 4638 mov r0, r7 80214ac: 9200 str r2, [sp, #0] 80214ae: f000 f8a7 bl 8021600 <__aeabi_uidiv> 80214b2: 4649 mov r1, r9 80214b4: b2ad uxth r5, r5 80214b6: 4683 mov fp, r0 80214b8: 4638 mov r0, r7 80214ba: f000 f9cf bl 802185c <__aeabi_uidivmod> 80214be: 9a00 ldr r2, [sp, #0] 80214c0: fb02 f70b mul.w r7, r2, fp 80214c4: ea45 4101 orr.w r1, r5, r1, lsl #16 80214c8: 428f cmp r7, r1 80214ca: d905 bls.n 80214d8 <__udivdi3+0x1f0> 80214cc: eb11 0108 adds.w r1, r1, r8 80214d0: f10b 32ff add.w r2, fp, #4294967295 80214d4: d37d bcc.n 80215d2 <__udivdi3+0x2ea> 80214d6: 4693 mov fp, r2 80214d8: 9b01 ldr r3, [sp, #4] 80214da: ea4b 400a orr.w r0, fp, sl, lsl #16 80214de: 1bc9 subs r1, r1, r7 80214e0: ea4f 4c10 mov.w ip, r0, lsr #16 80214e4: b29d uxth r5, r3 80214e6: ea4f 4a13 mov.w sl, r3, lsr #16 80214ea: b283 uxth r3, r0 80214ec: fb05 f203 mul.w r2, r5, r3 80214f0: fb05 f50c mul.w r5, r5, ip 80214f4: fb0a 5303 mla r3, sl, r3, r5 80214f8: fb0a fa0c mul.w sl, sl, ip 80214fc: eb03 4312 add.w r3, r3, r2, lsr #16 8021500: 429d cmp r5, r3 8021502: bf88 it hi 8021504: f50a 3a80 addhi.w sl, sl, #65536 ; 0x10000 8021508: eb0a 4a13 add.w sl, sl, r3, lsr #16 802150c: 4551 cmp r1, sl 802150e: d30e bcc.n 802152e <__udivdi3+0x246> 8021510: b292 uxth r2, r2 8021512: bf14 ite ne 8021514: 2100 movne r1, #0 8021516: 2101 moveq r1, #1 8021518: fa06 f604 lsl.w r6, r6, r4 802151c: eb02 4303 add.w r3, r2, r3, lsl #16 8021520: 429e cmp r6, r3 8021522: bf2c ite cs 8021524: 2600 movcs r6, #0 8021526: f001 0601 andcc.w r6, r1, #1 802152a: 2e00 cmp r6, #0 802152c: d08a beq.n 8021444 <__udivdi3+0x15c> 802152e: 3801 subs r0, #1 8021530: 2600 movs r6, #0 8021532: e787 b.n 8021444 <__udivdi3+0x15c> 8021534: 409c lsls r4, r3 8021536: f1c3 0220 rsb r2, r3, #32 802153a: fa25 fa02 lsr.w sl, r5, r2 802153e: fa26 f902 lsr.w r9, r6, r2 8021542: ea4f 4814 mov.w r8, r4, lsr #16 8021546: 4650 mov r0, sl 8021548: 4641 mov r1, r8 802154a: fa05 f503 lsl.w r5, r5, r3 802154e: fa06 f703 lsl.w r7, r6, r3 8021552: f000 f855 bl 8021600 <__aeabi_uidiv> 8021556: 4641 mov r1, r8 8021558: ea49 0905 orr.w r9, r9, r5 802155c: 4683 mov fp, r0 802155e: 4650 mov r0, sl 8021560: f000 f97c bl 802185c <__aeabi_uidivmod> 8021564: fa1f fa84 uxth.w sl, r4 8021568: ea4f 4319 mov.w r3, r9, lsr #16 802156c: fb0a f00b mul.w r0, sl, fp 8021570: ea43 4101 orr.w r1, r3, r1, lsl #16 8021574: 4288 cmp r0, r1 8021576: d909 bls.n 802158c <__udivdi3+0x2a4> 8021578: 1909 adds r1, r1, r4 802157a: f10b 33ff add.w r3, fp, #4294967295 802157e: d238 bcs.n 80215f2 <__udivdi3+0x30a> 8021580: 4288 cmp r0, r1 8021582: bf84 itt hi 8021584: f1ab 0b02 subhi.w fp, fp, #2 8021588: 1909 addhi r1, r1, r4 802158a: d932 bls.n 80215f2 <__udivdi3+0x30a> 802158c: 1a0d subs r5, r1, r0 802158e: 4641 mov r1, r8 8021590: 4628 mov r0, r5 8021592: fa1f f989 uxth.w r9, r9 8021596: f000 f833 bl 8021600 <__aeabi_uidiv> 802159a: 4641 mov r1, r8 802159c: 4606 mov r6, r0 802159e: 4628 mov r0, r5 80215a0: f000 f95c bl 802185c <__aeabi_uidivmod> 80215a4: fb0a f506 mul.w r5, sl, r6 80215a8: ea49 4101 orr.w r1, r9, r1, lsl #16 80215ac: 428d cmp r5, r1 80215ae: d906 bls.n 80215be <__udivdi3+0x2d6> 80215b0: 1e73 subs r3, r6, #1 80215b2: 1909 adds r1, r1, r4 80215b4: d21f bcs.n 80215f6 <__udivdi3+0x30e> 80215b6: 428d cmp r5, r1 80215b8: d91d bls.n 80215f6 <__udivdi3+0x30e> 80215ba: 3e02 subs r6, #2 80215bc: 1909 adds r1, r1, r4 80215be: 1b4d subs r5, r1, r5 80215c0: ea46 460b orr.w r6, r6, fp, lsl #16 80215c4: e703 b.n 80213ce <__udivdi3+0xe6> 80215c6: 461e mov r6, r3 80215c8: e6df b.n 802138a <__udivdi3+0xa2> 80215ca: 4699 mov r9, r3 80215cc: e71b b.n 8021406 <__udivdi3+0x11e> 80215ce: 461d mov r5, r3 80215d0: e733 b.n 802143a <__udivdi3+0x152> 80215d2: 428f cmp r7, r1 80215d4: bf84 itt hi 80215d6: f1ab 0b02 subhi.w fp, fp, #2 80215da: 4441 addhi r1, r8 80215dc: f63f af7c bhi.w 80214d8 <__udivdi3+0x1f0> 80215e0: e779 b.n 80214d6 <__udivdi3+0x1ee> 80215e2: 42b8 cmp r0, r7 80215e4: bf84 itt hi 80215e6: f1aa 0a02 subhi.w sl, sl, #2 80215ea: 4447 addhi r7, r8 80215ec: f63f af5b bhi.w 80214a6 <__udivdi3+0x1be> 80215f0: e758 b.n 80214a4 <__udivdi3+0x1bc> 80215f2: 469b mov fp, r3 80215f4: e7ca b.n 802158c <__udivdi3+0x2a4> 80215f6: 461e mov r6, r3 80215f8: e7e1 b.n 80215be <__udivdi3+0x2d6> 80215fa: bf00 nop 80215fc: 0000 movs r0, r0 80215fe: 0000 movs r0, r0 08021600 <__aeabi_uidiv>: 8021600: 1e4a subs r2, r1, #1 8021602: bf08 it eq 8021604: 4770 bxeq lr 8021606: f0c0 8124 bcc.w 8021852 <__aeabi_uidiv+0x252> 802160a: 4288 cmp r0, r1 802160c: f240 8116 bls.w 802183c <__aeabi_uidiv+0x23c> 8021610: 4211 tst r1, r2 8021612: f000 8117 beq.w 8021844 <__aeabi_uidiv+0x244> 8021616: fab0 f380 clz r3, r0 802161a: fab1 f281 clz r2, r1 802161e: eba2 0303 sub.w r3, r2, r3 8021622: f1c3 031f rsb r3, r3, #31 8021626: a204 add r2, pc, #16 ; (adr r2, 8021638 <__aeabi_uidiv+0x38>) 8021628: eb02 1303 add.w r3, r2, r3, lsl #4 802162c: f04f 0200 mov.w r2, #0 8021630: 469f mov pc, r3 8021632: bf00 nop 8021634: f3af 8000 nop.w 8021638: ebb0 7fc1 cmp.w r0, r1, lsl #31 802163c: bf00 nop 802163e: eb42 0202 adc.w r2, r2, r2 8021642: bf28 it cs 8021644: eba0 70c1 subcs.w r0, r0, r1, lsl #31 8021648: ebb0 7f81 cmp.w r0, r1, lsl #30 802164c: bf00 nop 802164e: eb42 0202 adc.w r2, r2, r2 8021652: bf28 it cs 8021654: eba0 7081 subcs.w r0, r0, r1, lsl #30 8021658: ebb0 7f41 cmp.w r0, r1, lsl #29 802165c: bf00 nop 802165e: eb42 0202 adc.w r2, r2, r2 8021662: bf28 it cs 8021664: eba0 7041 subcs.w r0, r0, r1, lsl #29 8021668: ebb0 7f01 cmp.w r0, r1, lsl #28 802166c: bf00 nop 802166e: eb42 0202 adc.w r2, r2, r2 8021672: bf28 it cs 8021674: eba0 7001 subcs.w r0, r0, r1, lsl #28 8021678: ebb0 6fc1 cmp.w r0, r1, lsl #27 802167c: bf00 nop 802167e: eb42 0202 adc.w r2, r2, r2 8021682: bf28 it cs 8021684: eba0 60c1 subcs.w r0, r0, r1, lsl #27 8021688: ebb0 6f81 cmp.w r0, r1, lsl #26 802168c: bf00 nop 802168e: eb42 0202 adc.w r2, r2, r2 8021692: bf28 it cs 8021694: eba0 6081 subcs.w r0, r0, r1, lsl #26 8021698: ebb0 6f41 cmp.w r0, r1, lsl #25 802169c: bf00 nop 802169e: eb42 0202 adc.w r2, r2, r2 80216a2: bf28 it cs 80216a4: eba0 6041 subcs.w r0, r0, r1, lsl #25 80216a8: ebb0 6f01 cmp.w r0, r1, lsl #24 80216ac: bf00 nop 80216ae: eb42 0202 adc.w r2, r2, r2 80216b2: bf28 it cs 80216b4: eba0 6001 subcs.w r0, r0, r1, lsl #24 80216b8: ebb0 5fc1 cmp.w r0, r1, lsl #23 80216bc: bf00 nop 80216be: eb42 0202 adc.w r2, r2, r2 80216c2: bf28 it cs 80216c4: eba0 50c1 subcs.w r0, r0, r1, lsl #23 80216c8: ebb0 5f81 cmp.w r0, r1, lsl #22 80216cc: bf00 nop 80216ce: eb42 0202 adc.w r2, r2, r2 80216d2: bf28 it cs 80216d4: eba0 5081 subcs.w r0, r0, r1, lsl #22 80216d8: ebb0 5f41 cmp.w r0, r1, lsl #21 80216dc: bf00 nop 80216de: eb42 0202 adc.w r2, r2, r2 80216e2: bf28 it cs 80216e4: eba0 5041 subcs.w r0, r0, r1, lsl #21 80216e8: ebb0 5f01 cmp.w r0, r1, lsl #20 80216ec: bf00 nop 80216ee: eb42 0202 adc.w r2, r2, r2 80216f2: bf28 it cs 80216f4: eba0 5001 subcs.w r0, r0, r1, lsl #20 80216f8: ebb0 4fc1 cmp.w r0, r1, lsl #19 80216fc: bf00 nop 80216fe: eb42 0202 adc.w r2, r2, r2 8021702: bf28 it cs 8021704: eba0 40c1 subcs.w r0, r0, r1, lsl #19 8021708: ebb0 4f81 cmp.w r0, r1, lsl #18 802170c: bf00 nop 802170e: eb42 0202 adc.w r2, r2, r2 8021712: bf28 it cs 8021714: eba0 4081 subcs.w r0, r0, r1, lsl #18 8021718: ebb0 4f41 cmp.w r0, r1, lsl #17 802171c: bf00 nop 802171e: eb42 0202 adc.w r2, r2, r2 8021722: bf28 it cs 8021724: eba0 4041 subcs.w r0, r0, r1, lsl #17 8021728: ebb0 4f01 cmp.w r0, r1, lsl #16 802172c: bf00 nop 802172e: eb42 0202 adc.w r2, r2, r2 8021732: bf28 it cs 8021734: eba0 4001 subcs.w r0, r0, r1, lsl #16 8021738: ebb0 3fc1 cmp.w r0, r1, lsl #15 802173c: bf00 nop 802173e: eb42 0202 adc.w r2, r2, r2 8021742: bf28 it cs 8021744: eba0 30c1 subcs.w r0, r0, r1, lsl #15 8021748: ebb0 3f81 cmp.w r0, r1, lsl #14 802174c: bf00 nop 802174e: eb42 0202 adc.w r2, r2, r2 8021752: bf28 it cs 8021754: eba0 3081 subcs.w r0, r0, r1, lsl #14 8021758: ebb0 3f41 cmp.w r0, r1, lsl #13 802175c: bf00 nop 802175e: eb42 0202 adc.w r2, r2, r2 8021762: bf28 it cs 8021764: eba0 3041 subcs.w r0, r0, r1, lsl #13 8021768: ebb0 3f01 cmp.w r0, r1, lsl #12 802176c: bf00 nop 802176e: eb42 0202 adc.w r2, r2, r2 8021772: bf28 it cs 8021774: eba0 3001 subcs.w r0, r0, r1, lsl #12 8021778: ebb0 2fc1 cmp.w r0, r1, lsl #11 802177c: bf00 nop 802177e: eb42 0202 adc.w r2, r2, r2 8021782: bf28 it cs 8021784: eba0 20c1 subcs.w r0, r0, r1, lsl #11 8021788: ebb0 2f81 cmp.w r0, r1, lsl #10 802178c: bf00 nop 802178e: eb42 0202 adc.w r2, r2, r2 8021792: bf28 it cs 8021794: eba0 2081 subcs.w r0, r0, r1, lsl #10 8021798: ebb0 2f41 cmp.w r0, r1, lsl #9 802179c: bf00 nop 802179e: eb42 0202 adc.w r2, r2, r2 80217a2: bf28 it cs 80217a4: eba0 2041 subcs.w r0, r0, r1, lsl #9 80217a8: ebb0 2f01 cmp.w r0, r1, lsl #8 80217ac: bf00 nop 80217ae: eb42 0202 adc.w r2, r2, r2 80217b2: bf28 it cs 80217b4: eba0 2001 subcs.w r0, r0, r1, lsl #8 80217b8: ebb0 1fc1 cmp.w r0, r1, lsl #7 80217bc: bf00 nop 80217be: eb42 0202 adc.w r2, r2, r2 80217c2: bf28 it cs 80217c4: eba0 10c1 subcs.w r0, r0, r1, lsl #7 80217c8: ebb0 1f81 cmp.w r0, r1, lsl #6 80217cc: bf00 nop 80217ce: eb42 0202 adc.w r2, r2, r2 80217d2: bf28 it cs 80217d4: eba0 1081 subcs.w r0, r0, r1, lsl #6 80217d8: ebb0 1f41 cmp.w r0, r1, lsl #5 80217dc: bf00 nop 80217de: eb42 0202 adc.w r2, r2, r2 80217e2: bf28 it cs 80217e4: eba0 1041 subcs.w r0, r0, r1, lsl #5 80217e8: ebb0 1f01 cmp.w r0, r1, lsl #4 80217ec: bf00 nop 80217ee: eb42 0202 adc.w r2, r2, r2 80217f2: bf28 it cs 80217f4: eba0 1001 subcs.w r0, r0, r1, lsl #4 80217f8: ebb0 0fc1 cmp.w r0, r1, lsl #3 80217fc: bf00 nop 80217fe: eb42 0202 adc.w r2, r2, r2 8021802: bf28 it cs 8021804: eba0 00c1 subcs.w r0, r0, r1, lsl #3 8021808: ebb0 0f81 cmp.w r0, r1, lsl #2 802180c: bf00 nop 802180e: eb42 0202 adc.w r2, r2, r2 8021812: bf28 it cs 8021814: eba0 0081 subcs.w r0, r0, r1, lsl #2 8021818: ebb0 0f41 cmp.w r0, r1, lsl #1 802181c: bf00 nop 802181e: eb42 0202 adc.w r2, r2, r2 8021822: bf28 it cs 8021824: eba0 0041 subcs.w r0, r0, r1, lsl #1 8021828: ebb0 0f01 cmp.w r0, r1 802182c: bf00 nop 802182e: eb42 0202 adc.w r2, r2, r2 8021832: bf28 it cs 8021834: eba0 0001 subcs.w r0, r0, r1 8021838: 4610 mov r0, r2 802183a: 4770 bx lr 802183c: bf0c ite eq 802183e: 2001 moveq r0, #1 8021840: 2000 movne r0, #0 8021842: 4770 bx lr 8021844: fab1 f281 clz r2, r1 8021848: f1c2 021f rsb r2, r2, #31 802184c: fa20 f002 lsr.w r0, r0, r2 8021850: 4770 bx lr 8021852: b108 cbz r0, 8021858 <__aeabi_uidiv+0x258> 8021854: f04f 30ff mov.w r0, #4294967295 8021858: f7ff bb8e b.w 8020f78 <__aeabi_idiv0> 0802185c <__aeabi_uidivmod>: 802185c: 2900 cmp r1, #0 802185e: d0f8 beq.n 8021852 <__aeabi_uidiv+0x252> 8021860: e92d 4003 stmdb sp!, {r0, r1, lr} 8021864: f7ff fecc bl 8021600 <__aeabi_uidiv> 8021868: e8bd 4006 ldmia.w sp!, {r1, r2, lr} 802186c: fb02 f300 mul.w r3, r2, r0 8021870: eba1 0103 sub.w r1, r1, r3 8021874: 4770 bx lr 8021876: bf00 nop 08021878 : 8021878: 2100 movs r1, #0 802187a: f001 bde7 b.w 802344c 802187e: bf00 nop 08021880 : 8021880: 2100 movs r1, #0 8021882: 220a movs r2, #10 8021884: f001 bee2 b.w 802364c 08021888 <_atoi_r>: 8021888: 2200 movs r2, #0 802188a: 230a movs r3, #10 802188c: f001 be3c b.w 8023508 <_strtol_r> 08021890 <__libc_init_array>: 8021890: b570 push {r4, r5, r6, lr} 8021892: f640 2608 movw r6, #2568 ; 0xa08 8021896: f640 2508 movw r5, #2568 ; 0xa08 802189a: f6c0 0604 movt r6, #2052 ; 0x804 802189e: f6c0 0504 movt r5, #2052 ; 0x804 80218a2: 1b76 subs r6, r6, r5 80218a4: 10b6 asrs r6, r6, #2 80218a6: d007 beq.n 80218b8 <__libc_init_array+0x28> 80218a8: 3d04 subs r5, #4 80218aa: 2400 movs r4, #0 80218ac: f855 3f04 ldr.w r3, [r5, #4]! 80218b0: 3401 adds r4, #1 80218b2: 4798 blx r3 80218b4: 42a6 cmp r6, r4 80218b6: d1f9 bne.n 80218ac <__libc_init_array+0x1c> 80218b8: f640 260c movw r6, #2572 ; 0xa0c 80218bc: f640 2508 movw r5, #2568 ; 0xa08 80218c0: f6c0 0604 movt r6, #2052 ; 0x804 80218c4: f6c0 0504 movt r5, #2052 ; 0x804 80218c8: 1b76 subs r6, r6, r5 80218ca: f01f f88d bl 80409e8 <_init> 80218ce: 10b6 asrs r6, r6, #2 80218d0: d008 beq.n 80218e4 <__libc_init_array+0x54> 80218d2: 3d04 subs r5, #4 80218d4: 2400 movs r4, #0 80218d6: f855 3f04 ldr.w r3, [r5, #4]! 80218da: 3401 adds r4, #1 80218dc: 4798 blx r3 80218de: 42a6 cmp r6, r4 80218e0: d1f9 bne.n 80218d6 <__libc_init_array+0x46> 80218e2: bd70 pop {r4, r5, r6, pc} 80218e4: bd70 pop {r4, r5, r6, pc} 80218e6: bf00 nop 080218e8 : 80218e8: 2a03 cmp r2, #3 80218ea: b470 push {r4, r5, r6} 80218ec: d922 bls.n 8021934 80218ee: ea41 0300 orr.w r3, r1, r0 80218f2: 079b lsls r3, r3, #30 80218f4: d013 beq.n 802191e 80218f6: 7805 ldrb r5, [r0, #0] 80218f8: 3a01 subs r2, #1 80218fa: 780c ldrb r4, [r1, #0] 80218fc: 2300 movs r3, #0 80218fe: 42a5 cmp r5, r4 8021900: d006 beq.n 8021910 8021902: e01b b.n 802193c 8021904: f810 5f01 ldrb.w r5, [r0, #1]! 8021908: f811 4f01 ldrb.w r4, [r1, #1]! 802190c: 42a5 cmp r5, r4 802190e: d115 bne.n 802193c 8021910: 4293 cmp r3, r2 8021912: f103 0301 add.w r3, r3, #1 8021916: d1f5 bne.n 8021904 8021918: 2000 movs r0, #0 802191a: bc70 pop {r4, r5, r6} 802191c: 4770 bx lr 802191e: 460c mov r4, r1 8021920: 4603 mov r3, r0 8021922: 3104 adds r1, #4 8021924: 3004 adds r0, #4 8021926: 681e ldr r6, [r3, #0] 8021928: 6825 ldr r5, [r4, #0] 802192a: 42ae cmp r6, r5 802192c: d108 bne.n 8021940 802192e: 3a04 subs r2, #4 8021930: 2a03 cmp r2, #3 8021932: d8f4 bhi.n 802191e 8021934: 2a00 cmp r2, #0 8021936: d1de bne.n 80218f6 8021938: 4610 mov r0, r2 802193a: e7ee b.n 802191a 802193c: 1b28 subs r0, r5, r4 802193e: e7ec b.n 802191a 8021940: 4621 mov r1, r4 8021942: 4618 mov r0, r3 8021944: 2a00 cmp r2, #0 8021946: d1d6 bne.n 80218f6 8021948: e7f6 b.n 8021938 802194a: bf00 nop 0802194c : 802194c: 2a03 cmp r2, #3 802194e: e92d 0ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp} 8021952: d809 bhi.n 8021968 8021954: b12a cbz r2, 8021962 8021956: 2300 movs r3, #0 8021958: 5ccc ldrb r4, [r1, r3] 802195a: 54c4 strb r4, [r0, r3] 802195c: 3301 adds r3, #1 802195e: 4293 cmp r3, r2 8021960: d1fa bne.n 8021958 8021962: e8bd 0ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp} 8021966: 4770 bx lr 8021968: 0783 lsls r3, r0, #30 802196a: 4402 add r2, r0 802196c: d00e beq.n 802198c 802196e: 1c44 adds r4, r0, #1 8021970: 1c4d adds r5, r1, #1 8021972: f815 7c01 ldrb.w r7, [r5, #-1] 8021976: f004 0603 and.w r6, r4, #3 802197a: 4623 mov r3, r4 802197c: 3401 adds r4, #1 802197e: 4629 mov r1, r5 8021980: 3501 adds r5, #1 8021982: f804 7c02 strb.w r7, [r4, #-2] 8021986: 2e00 cmp r6, #0 8021988: d1f3 bne.n 8021972 802198a: e000 b.n 802198e 802198c: 4603 mov r3, r0 802198e: f011 0403 ands.w r4, r1, #3 8021992: d06d beq.n 8021a70 8021994: 1ad7 subs r7, r2, r3 8021996: 1b0d subs r5, r1, r4 8021998: 2f03 cmp r7, #3 802199a: 682e ldr r6, [r5, #0] 802199c: dd19 ble.n 80219d2 802199e: f1c4 0c04 rsb ip, r4, #4 80219a2: ea4f 08c4 mov.w r8, r4, lsl #3 80219a6: 1d1c adds r4, r3, #4 80219a8: ea4f 0ccc mov.w ip, ip, lsl #3 80219ac: f855 7f04 ldr.w r7, [r5, #4]! 80219b0: ebc4 0902 rsb r9, r4, r2 80219b4: 4623 mov r3, r4 80219b6: 3104 adds r1, #4 80219b8: 3404 adds r4, #4 80219ba: f1b9 0f03 cmp.w r9, #3 80219be: fa26 fa08 lsr.w sl, r6, r8 80219c2: fa07 fb0c lsl.w fp, r7, ip 80219c6: 463e mov r6, r7 80219c8: ea4b 070a orr.w r7, fp, sl 80219cc: f844 7c08 str.w r7, [r4, #-8] 80219d0: dcec bgt.n 80219ac 80219d2: 429a cmp r2, r3 80219d4: d9c5 bls.n 8021962 80219d6: 3301 adds r3, #1 80219d8: 3101 adds r1, #1 80219da: 3201 adds r2, #1 80219dc: f811 4c01 ldrb.w r4, [r1, #-1] 80219e0: 3301 adds r3, #1 80219e2: 3101 adds r1, #1 80219e4: 4293 cmp r3, r2 80219e6: f803 4c02 strb.w r4, [r3, #-2] 80219ea: d1f7 bne.n 80219dc 80219ec: e7b9 b.n 8021962 80219ee: 680c ldr r4, [r1, #0] 80219f0: 3340 adds r3, #64 ; 0x40 80219f2: 3140 adds r1, #64 ; 0x40 80219f4: f843 4c40 str.w r4, [r3, #-64] 80219f8: f851 4c3c ldr.w r4, [r1, #-60] 80219fc: f843 4c3c str.w r4, [r3, #-60] 8021a00: f851 4c38 ldr.w r4, [r1, #-56] 8021a04: f843 4c38 str.w r4, [r3, #-56] 8021a08: f851 4c34 ldr.w r4, [r1, #-52] 8021a0c: f843 4c34 str.w r4, [r3, #-52] 8021a10: f851 4c30 ldr.w r4, [r1, #-48] 8021a14: f843 4c30 str.w r4, [r3, #-48] 8021a18: f851 4c2c ldr.w r4, [r1, #-44] 8021a1c: f843 4c2c str.w r4, [r3, #-44] 8021a20: f851 4c28 ldr.w r4, [r1, #-40] 8021a24: f843 4c28 str.w r4, [r3, #-40] 8021a28: f851 4c24 ldr.w r4, [r1, #-36] 8021a2c: f843 4c24 str.w r4, [r3, #-36] 8021a30: f851 4c20 ldr.w r4, [r1, #-32] 8021a34: f843 4c20 str.w r4, [r3, #-32] 8021a38: f851 4c1c ldr.w r4, [r1, #-28] 8021a3c: f843 4c1c str.w r4, [r3, #-28] 8021a40: f851 4c18 ldr.w r4, [r1, #-24] 8021a44: f843 4c18 str.w r4, [r3, #-24] 8021a48: f851 4c14 ldr.w r4, [r1, #-20] 8021a4c: f843 4c14 str.w r4, [r3, #-20] 8021a50: f851 4c10 ldr.w r4, [r1, #-16] 8021a54: f843 4c10 str.w r4, [r3, #-16] 8021a58: f851 4c0c ldr.w r4, [r1, #-12] 8021a5c: f843 4c0c str.w r4, [r3, #-12] 8021a60: f851 4c08 ldr.w r4, [r1, #-8] 8021a64: f843 4c08 str.w r4, [r3, #-8] 8021a68: f851 4c04 ldr.w r4, [r1, #-4] 8021a6c: f843 4c04 str.w r4, [r3, #-4] 8021a70: 1ad4 subs r4, r2, r3 8021a72: 2c3f cmp r4, #63 ; 0x3f 8021a74: dcbb bgt.n 80219ee 8021a76: e011 b.n 8021a9c 8021a78: 680c ldr r4, [r1, #0] 8021a7a: 3310 adds r3, #16 8021a7c: 3110 adds r1, #16 8021a7e: f843 4c10 str.w r4, [r3, #-16] 8021a82: f851 4c0c ldr.w r4, [r1, #-12] 8021a86: f843 4c0c str.w r4, [r3, #-12] 8021a8a: f851 4c08 ldr.w r4, [r1, #-8] 8021a8e: f843 4c08 str.w r4, [r3, #-8] 8021a92: f851 4c04 ldr.w r4, [r1, #-4] 8021a96: f843 4c04 str.w r4, [r3, #-4] 8021a9a: 1ad4 subs r4, r2, r3 8021a9c: 2c0f cmp r4, #15 8021a9e: dceb bgt.n 8021a78 8021aa0: 2c03 cmp r4, #3 8021aa2: dd96 ble.n 80219d2 8021aa4: 1d1c adds r4, r3, #4 8021aa6: 1d0d adds r5, r1, #4 8021aa8: f855 7c04 ldr.w r7, [r5, #-4] 8021aac: 1b16 subs r6, r2, r4 8021aae: 4623 mov r3, r4 8021ab0: 4629 mov r1, r5 8021ab2: 3404 adds r4, #4 8021ab4: 3504 adds r5, #4 8021ab6: 2e03 cmp r6, #3 8021ab8: f844 7c08 str.w r7, [r4, #-8] 8021abc: dcf4 bgt.n 8021aa8 8021abe: e788 b.n 80219d2 08021ac0 : 8021ac0: 2a03 cmp r2, #3 8021ac2: b2c9 uxtb r1, r1 8021ac4: b470 push {r4, r5, r6} 8021ac6: d808 bhi.n 8021ada 8021ac8: b12a cbz r2, 8021ad6 8021aca: 4603 mov r3, r0 8021acc: 1812 adds r2, r2, r0 8021ace: f803 1b01 strb.w r1, [r3], #1 8021ad2: 4293 cmp r3, r2 8021ad4: d1fb bne.n 8021ace 8021ad6: bc70 pop {r4, r5, r6} 8021ad8: 4770 bx lr 8021ada: 0783 lsls r3, r0, #30 8021adc: 4402 add r2, r0 8021ade: d009 beq.n 8021af4 8021ae0: 1c44 adds r4, r0, #1 8021ae2: f004 0503 and.w r5, r4, #3 8021ae6: 4623 mov r3, r4 8021ae8: f804 1c01 strb.w r1, [r4, #-1] 8021aec: 3401 adds r4, #1 8021aee: 2d00 cmp r5, #0 8021af0: d1f7 bne.n 8021ae2 8021af2: e000 b.n 8021af6 8021af4: 4603 mov r3, r0 8021af6: 1ad5 subs r5, r2, r3 8021af8: eb01 2401 add.w r4, r1, r1, lsl #8 8021afc: 2d3f cmp r5, #63 ; 0x3f 8021afe: eb04 4404 add.w r4, r4, r4, lsl #16 8021b02: dd2c ble.n 8021b5e 8021b04: 601c str r4, [r3, #0] 8021b06: 3340 adds r3, #64 ; 0x40 8021b08: 1ad5 subs r5, r2, r3 8021b0a: f843 4c3c str.w r4, [r3, #-60] 8021b0e: 2d3f cmp r5, #63 ; 0x3f 8021b10: f843 4c38 str.w r4, [r3, #-56] 8021b14: f843 4c34 str.w r4, [r3, #-52] 8021b18: f843 4c30 str.w r4, [r3, #-48] 8021b1c: f843 4c2c str.w r4, [r3, #-44] 8021b20: f843 4c28 str.w r4, [r3, #-40] 8021b24: f843 4c24 str.w r4, [r3, #-36] 8021b28: f843 4c20 str.w r4, [r3, #-32] 8021b2c: f843 4c1c str.w r4, [r3, #-28] 8021b30: f843 4c18 str.w r4, [r3, #-24] 8021b34: f843 4c14 str.w r4, [r3, #-20] 8021b38: f843 4c10 str.w r4, [r3, #-16] 8021b3c: f843 4c0c str.w r4, [r3, #-12] 8021b40: f843 4c08 str.w r4, [r3, #-8] 8021b44: f843 4c04 str.w r4, [r3, #-4] 8021b48: dcdc bgt.n 8021b04 8021b4a: e008 b.n 8021b5e 8021b4c: 601c str r4, [r3, #0] 8021b4e: 3310 adds r3, #16 8021b50: 1ad5 subs r5, r2, r3 8021b52: f843 4c0c str.w r4, [r3, #-12] 8021b56: f843 4c08 str.w r4, [r3, #-8] 8021b5a: f843 4c04 str.w r4, [r3, #-4] 8021b5e: 2d0f cmp r5, #15 8021b60: dcf4 bgt.n 8021b4c 8021b62: 2d03 cmp r5, #3 8021b64: dd08 ble.n 8021b78 8021b66: 1d1d adds r5, r3, #4 8021b68: 1b56 subs r6, r2, r5 8021b6a: f845 4c04 str.w r4, [r5, #-4] 8021b6e: 2e03 cmp r6, #3 8021b70: 462b mov r3, r5 8021b72: f105 0504 add.w r5, r5, #4 8021b76: dcf7 bgt.n 8021b68 8021b78: 429a cmp r2, r3 8021b7a: d9ac bls.n 8021ad6 8021b7c: 3301 adds r3, #1 8021b7e: 3201 adds r2, #1 8021b80: f803 1c01 strb.w r1, [r3, #-1] 8021b84: 3301 adds r3, #1 8021b86: 4293 cmp r3, r2 8021b88: d1fa bne.n 8021b80 8021b8a: e7a4 b.n 8021ad6 08021b8c : 8021b8c: 0783 lsls r3, r0, #30 8021b8e: b570 push {r4, r5, r6, lr} 8021b90: 4606 mov r6, r0 8021b92: d114 bne.n 8021bbe 8021b94: 6803 ldr r3, [r0, #0] 8021b96: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 8021b9a: ea22 0303 bic.w r3, r2, r3 8021b9e: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 8021ba2: d10c bne.n 8021bbe 8021ba4: 1d03 adds r3, r0, #4 8021ba6: 461a mov r2, r3 8021ba8: f853 4b04 ldr.w r4, [r3], #4 8021bac: f1a4 3501 sub.w r5, r4, #16843009 ; 0x1010101 8021bb0: ea25 0404 bic.w r4, r5, r4 8021bb4: f014 3f80 tst.w r4, #2155905152 ; 0x80808080 8021bb8: d0f5 beq.n 8021ba6 8021bba: 4610 mov r0, r2 8021bbc: e000 b.n 8021bc0 8021bbe: 4630 mov r0, r6 8021bc0: 7803 ldrb r3, [r0, #0] 8021bc2: b12b cbz r3, 8021bd0 8021bc4: 1c43 adds r3, r0, #1 8021bc6: 4618 mov r0, r3 8021bc8: 3301 adds r3, #1 8021bca: 7804 ldrb r4, [r0, #0] 8021bcc: 2c00 cmp r4, #0 8021bce: d1fa bne.n 8021bc6 8021bd0: f000 f8f0 bl 8021db4 8021bd4: 4630 mov r0, r6 8021bd6: bd70 pop {r4, r5, r6, pc} 08021bd8 : 8021bd8: ea80 0201 eor.w r2, r0, r1 8021bdc: f012 0f03 tst.w r2, #3 8021be0: f040 803a bne.w 8021c58 8021be4: f010 0203 ands.w r2, r0, #3 8021be8: f020 0003 bic.w r0, r0, #3 8021bec: f021 0103 bic.w r1, r1, #3 8021bf0: f850 cb04 ldr.w ip, [r0], #4 8021bf4: bf08 it eq 8021bf6: f851 3b04 ldreq.w r3, [r1], #4 8021bfa: d00d beq.n 8021c18 8021bfc: f082 0203 eor.w r2, r2, #3 8021c00: ea4f 02c2 mov.w r2, r2, lsl #3 8021c04: f06f 437f mvn.w r3, #4278190080 ; 0xff000000 8021c08: fa23 f202 lsr.w r2, r3, r2 8021c0c: f851 3b04 ldr.w r3, [r1], #4 8021c10: ea4c 0c02 orr.w ip, ip, r2 8021c14: ea43 0302 orr.w r3, r3, r2 8021c18: f1ac 3201 sub.w r2, ip, #16843009 ; 0x1010101 8021c1c: 459c cmp ip, r3 8021c1e: bf01 itttt eq 8021c20: ea22 020c biceq.w r2, r2, ip 8021c24: f012 3f80 tsteq.w r2, #2155905152 ; 0x80808080 8021c28: f850 cb04 ldreq.w ip, [r0], #4 8021c2c: f851 3b04 ldreq.w r3, [r1], #4 8021c30: d0f2 beq.n 8021c18 8021c32: ea4f 600c mov.w r0, ip, lsl #24 8021c36: ea4f 2c1c mov.w ip, ip, lsr #8 8021c3a: 2801 cmp r0, #1 8021c3c: bf28 it cs 8021c3e: ebb0 6f03 cmpcs.w r0, r3, lsl #24 8021c42: bf08 it eq 8021c44: 0a1b lsreq r3, r3, #8 8021c46: d0f4 beq.n 8021c32 8021c48: f003 03ff and.w r3, r3, #255 ; 0xff 8021c4c: ea4f 6010 mov.w r0, r0, lsr #24 8021c50: eba0 0003 sub.w r0, r0, r3 8021c54: 4770 bx lr 8021c56: bf00 nop 08021c58 : 8021c58: f010 0f03 tst.w r0, #3 8021c5c: d00a beq.n 8021c74 8021c5e: f810 2b01 ldrb.w r2, [r0], #1 8021c62: f811 3b01 ldrb.w r3, [r1], #1 8021c66: 2a01 cmp r2, #1 8021c68: bf28 it cs 8021c6a: 429a cmpcs r2, r3 8021c6c: d0f4 beq.n 8021c58 8021c6e: eba2 0003 sub.w r0, r2, r3 8021c72: 4770 bx lr 8021c74: f84d 5d04 str.w r5, [sp, #-4]! 8021c78: f84d 4d04 str.w r4, [sp, #-4]! 8021c7c: f04f 0201 mov.w r2, #1 8021c80: ea42 2202 orr.w r2, r2, r2, lsl #8 8021c84: ea42 4202 orr.w r2, r2, r2, lsl #16 8021c88: f001 0c03 and.w ip, r1, #3 8021c8c: f021 0103 bic.w r1, r1, #3 8021c90: f850 4b04 ldr.w r4, [r0], #4 8021c94: f851 5b04 ldr.w r5, [r1], #4 8021c98: f1bc 0f02 cmp.w ip, #2 8021c9c: d026 beq.n 8021cec 8021c9e: d84b bhi.n 8021d38 8021ca0: f024 4c7f bic.w ip, r4, #4278190080 ; 0xff000000 8021ca4: ebbc 2f15 cmp.w ip, r5, lsr #8 8021ca8: eba4 0302 sub.w r3, r4, r2 8021cac: ea23 0304 bic.w r3, r3, r4 8021cb0: d10d bne.n 8021cce 8021cb2: ea13 13c2 ands.w r3, r3, r2, lsl #7 8021cb6: bf08 it eq 8021cb8: f851 5b04 ldreq.w r5, [r1], #4 8021cbc: d10a bne.n 8021cd4 8021cbe: ea8c 0c04 eor.w ip, ip, r4 8021cc2: ebbc 6f05 cmp.w ip, r5, lsl #24 8021cc6: d10c bne.n 8021ce2 8021cc8: f850 4b04 ldr.w r4, [r0], #4 8021ccc: e7e8 b.n 8021ca0 8021cce: ea4f 2515 mov.w r5, r5, lsr #8 8021cd2: e05c b.n 8021d8e 8021cd4: f033 437f bics.w r3, r3, #4278190080 ; 0xff000000 8021cd8: d152 bne.n 8021d80 8021cda: 780d ldrb r5, [r1, #0] 8021cdc: ea4f 6c14 mov.w ip, r4, lsr #24 8021ce0: e055 b.n 8021d8e 8021ce2: ea4f 6c14 mov.w ip, r4, lsr #24 8021ce6: f005 05ff and.w r5, r5, #255 ; 0xff 8021cea: e050 b.n 8021d8e 8021cec: ea4f 4c04 mov.w ip, r4, lsl #16 8021cf0: eba4 0302 sub.w r3, r4, r2 8021cf4: ea4f 4c1c mov.w ip, ip, lsr #16 8021cf8: ea23 0304 bic.w r3, r3, r4 8021cfc: ebbc 4f15 cmp.w ip, r5, lsr #16 8021d00: d117 bne.n 8021d32 8021d02: ea13 13c2 ands.w r3, r3, r2, lsl #7 8021d06: bf08 it eq 8021d08: f851 5b04 ldreq.w r5, [r1], #4 8021d0c: d107 bne.n 8021d1e 8021d0e: ea8c 0c04 eor.w ip, ip, r4 8021d12: ebbc 4f05 cmp.w ip, r5, lsl #16 8021d16: d108 bne.n 8021d2a 8021d18: f850 4b04 ldr.w r4, [r0], #4 8021d1c: e7e6 b.n 8021cec 8021d1e: 041b lsls r3, r3, #16 8021d20: d12e bne.n 8021d80 8021d22: 880d ldrh r5, [r1, #0] 8021d24: ea4f 4c14 mov.w ip, r4, lsr #16 8021d28: e031 b.n 8021d8e 8021d2a: ea4f 4505 mov.w r5, r5, lsl #16 8021d2e: ea4f 4c14 mov.w ip, r4, lsr #16 8021d32: ea4f 4515 mov.w r5, r5, lsr #16 8021d36: e02a b.n 8021d8e 8021d38: f004 0cff and.w ip, r4, #255 ; 0xff 8021d3c: ebbc 6f15 cmp.w ip, r5, lsr #24 8021d40: eba4 0302 sub.w r3, r4, r2 8021d44: ea23 0304 bic.w r3, r3, r4 8021d48: d10d bne.n 8021d66 8021d4a: ea13 13c2 ands.w r3, r3, r2, lsl #7 8021d4e: bf08 it eq 8021d50: f851 5b04 ldreq.w r5, [r1], #4 8021d54: d10a bne.n 8021d6c 8021d56: ea8c 0c04 eor.w ip, ip, r4 8021d5a: ebbc 2f05 cmp.w ip, r5, lsl #8 8021d5e: d10a bne.n 8021d76 8021d60: f850 4b04 ldr.w r4, [r0], #4 8021d64: e7e8 b.n 8021d38 8021d66: ea4f 6515 mov.w r5, r5, lsr #24 8021d6a: e010 b.n 8021d8e 8021d6c: f014 0fff tst.w r4, #255 ; 0xff 8021d70: d006 beq.n 8021d80 8021d72: f851 5b04 ldr.w r5, [r1], #4 8021d76: ea4f 2c14 mov.w ip, r4, lsr #8 8021d7a: f025 457f bic.w r5, r5, #4278190080 ; 0xff000000 8021d7e: e006 b.n 8021d8e 8021d80: f04f 0000 mov.w r0, #0 8021d84: f85d 4b04 ldr.w r4, [sp], #4 8021d88: f85d 5b04 ldr.w r5, [sp], #4 8021d8c: 4770 bx lr 8021d8e: f00c 02ff and.w r2, ip, #255 ; 0xff 8021d92: f005 00ff and.w r0, r5, #255 ; 0xff 8021d96: 2801 cmp r0, #1 8021d98: bf28 it cs 8021d9a: 4290 cmpcs r0, r2 8021d9c: bf04 itt eq 8021d9e: ea4f 2c1c moveq.w ip, ip, lsr #8 8021da2: 0a2d lsreq r5, r5, #8 8021da4: d0f3 beq.n 8021d8e 8021da6: eba2 0000 sub.w r0, r2, r0 8021daa: f85d 4b04 ldr.w r4, [sp], #4 8021dae: f85d 5b04 ldr.w r5, [sp], #4 8021db2: 4770 bx lr 08021db4 : 8021db4: ea80 0201 eor.w r2, r0, r1 8021db8: 4684 mov ip, r0 8021dba: f012 0f03 tst.w r2, #3 8021dbe: d14f bne.n 8021e60 8021dc0: f011 0f03 tst.w r1, #3 8021dc4: d132 bne.n 8021e2c 8021dc6: f84d 4d04 str.w r4, [sp, #-4]! 8021dca: f011 0f04 tst.w r1, #4 8021dce: f851 3b04 ldr.w r3, [r1], #4 8021dd2: d00b beq.n 8021dec 8021dd4: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 8021dd8: 439a bics r2, r3 8021dda: f012 3f80 tst.w r2, #2155905152 ; 0x80808080 8021dde: bf04 itt eq 8021de0: f84c 3b04 streq.w r3, [ip], #4 8021de4: f851 3b04 ldreq.w r3, [r1], #4 8021de8: d116 bne.n 8021e18 8021dea: bf00 nop 8021dec: f851 4b04 ldr.w r4, [r1], #4 8021df0: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 8021df4: 439a bics r2, r3 8021df6: f012 3f80 tst.w r2, #2155905152 ; 0x80808080 8021dfa: f1a4 3201 sub.w r2, r4, #16843009 ; 0x1010101 8021dfe: d10b bne.n 8021e18 8021e00: f84c 3b04 str.w r3, [ip], #4 8021e04: 43a2 bics r2, r4 8021e06: f012 3f80 tst.w r2, #2155905152 ; 0x80808080 8021e0a: bf04 itt eq 8021e0c: f851 3b04 ldreq.w r3, [r1], #4 8021e10: f84c 4b04 streq.w r4, [ip], #4 8021e14: d0ea beq.n 8021dec 8021e16: 4623 mov r3, r4 8021e18: f80c 3b01 strb.w r3, [ip], #1 8021e1c: f013 0fff tst.w r3, #255 ; 0xff 8021e20: ea4f 2333 mov.w r3, r3, ror #8 8021e24: d1f8 bne.n 8021e18 8021e26: f85d 4b04 ldr.w r4, [sp], #4 8021e2a: 4770 bx lr 8021e2c: f011 0f01 tst.w r1, #1 8021e30: d006 beq.n 8021e40 8021e32: f811 2b01 ldrb.w r2, [r1], #1 8021e36: f80c 2b01 strb.w r2, [ip], #1 8021e3a: 2a00 cmp r2, #0 8021e3c: bf08 it eq 8021e3e: 4770 bxeq lr 8021e40: f011 0f02 tst.w r1, #2 8021e44: d0bf beq.n 8021dc6 8021e46: f831 2b02 ldrh.w r2, [r1], #2 8021e4a: f012 0fff tst.w r2, #255 ; 0xff 8021e4e: bf16 itet ne 8021e50: f82c 2b02 strhne.w r2, [ip], #2 8021e54: f88c 2000 strbeq.w r2, [ip] 8021e58: f412 4f7f tstne.w r2, #65280 ; 0xff00 8021e5c: d1b3 bne.n 8021dc6 8021e5e: 4770 bx lr 8021e60: f811 2b01 ldrb.w r2, [r1], #1 8021e64: f80c 2b01 strb.w r2, [ip], #1 8021e68: 2a00 cmp r2, #0 8021e6a: d1f9 bne.n 8021e60 8021e6c: 4770 bx lr 8021e6e: bf00 nop 08021e70 : 8021e70: f020 0103 bic.w r1, r0, #3 8021e74: f010 0003 ands.w r0, r0, #3 8021e78: f1c0 0000 rsb r0, r0, #0 8021e7c: f851 3b04 ldr.w r3, [r1], #4 8021e80: f100 0c04 add.w ip, r0, #4 8021e84: ea4f 0ccc mov.w ip, ip, lsl #3 8021e88: f06f 0200 mvn.w r2, #0 8021e8c: bf1c itt ne 8021e8e: fa22 f20c lsrne.w r2, r2, ip 8021e92: 4313 orrne r3, r2 8021e94: f04f 0c01 mov.w ip, #1 8021e98: ea4c 2c0c orr.w ip, ip, ip, lsl #8 8021e9c: ea4c 4c0c orr.w ip, ip, ip, lsl #16 8021ea0: eba3 020c sub.w r2, r3, ip 8021ea4: ea22 0203 bic.w r2, r2, r3 8021ea8: ea12 12cc ands.w r2, r2, ip, lsl #7 8021eac: bf04 itt eq 8021eae: f851 3b04 ldreq.w r3, [r1], #4 8021eb2: 3004 addeq r0, #4 8021eb4: d0f4 beq.n 8021ea0 8021eb6: f013 0fff tst.w r3, #255 ; 0xff 8021eba: bf1f itttt ne 8021ebc: 3001 addne r0, #1 8021ebe: f413 4f7f tstne.w r3, #65280 ; 0xff00 8021ec2: 3001 addne r0, #1 8021ec4: f413 0f7f tstne.w r3, #16711680 ; 0xff0000 8021ec8: bf18 it ne 8021eca: 3001 addne r0, #1 8021ecc: 4770 bx lr 8021ece: bf00 nop 08021ed0 : 8021ed0: 0783 lsls r3, r0, #30 8021ed2: b470 push {r4, r5, r6} 8021ed4: d113 bne.n 8021efe 8021ed6: 6803 ldr r3, [r0, #0] 8021ed8: f1a3 3401 sub.w r4, r3, #16843009 ; 0x1010101 8021edc: ea24 0303 bic.w r3, r4, r3 8021ee0: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 8021ee4: d10b bne.n 8021efe 8021ee6: 1d03 adds r3, r0, #4 8021ee8: 461d mov r5, r3 8021eea: f853 4b04 ldr.w r4, [r3], #4 8021eee: f1a4 3601 sub.w r6, r4, #16843009 ; 0x1010101 8021ef2: ea26 0404 bic.w r4, r6, r4 8021ef6: f014 3f80 tst.w r4, #2155905152 ; 0x80808080 8021efa: d0f5 beq.n 8021ee8 8021efc: e000 b.n 8021f00 8021efe: 4605 mov r5, r0 8021f00: 782b ldrb r3, [r5, #0] 8021f02: b12b cbz r3, 8021f10 8021f04: 1c6b adds r3, r5, #1 8021f06: 461d mov r5, r3 8021f08: 3301 adds r3, #1 8021f0a: 782c ldrb r4, [r5, #0] 8021f0c: 2c00 cmp r4, #0 8021f0e: d1fa bne.n 8021f06 8021f10: 3901 subs r1, #1 8021f12: 3d01 subs r5, #1 8021f14: 1e53 subs r3, r2, #1 8021f16: b15a cbz r2, 8021f30 8021f18: f811 4f01 ldrb.w r4, [r1, #1]! 8021f1c: 461a mov r2, r3 8021f1e: f805 4f01 strb.w r4, [r5, #1]! 8021f22: b12c cbz r4, 8021f30 8021f24: 2b00 cmp r3, #0 8021f26: d1f5 bne.n 8021f14 8021f28: 706b strb r3, [r5, #1] 8021f2a: 1e53 subs r3, r2, #1 8021f2c: 2a00 cmp r2, #0 8021f2e: d1f3 bne.n 8021f18 8021f30: bc70 pop {r4, r5, r6} 8021f32: 4770 bx lr 08021f34 : 8021f34: b470 push {r4, r5, r6} 8021f36: 2a00 cmp r2, #0 8021f38: d045 beq.n 8021fc6 8021f3a: ea41 0300 orr.w r3, r1, r0 8021f3e: f013 0303 ands.w r3, r3, #3 8021f42: d129 bne.n 8021f98 8021f44: 2a03 cmp r2, #3 8021f46: d927 bls.n 8021f98 8021f48: 6805 ldr r5, [r0, #0] 8021f4a: 680c ldr r4, [r1, #0] 8021f4c: 42a5 cmp r5, r4 8021f4e: d123 bne.n 8021f98 8021f50: 1f14 subs r4, r2, #4 8021f52: d03a beq.n 8021fca 8021f54: f1a5 3201 sub.w r2, r5, #16843009 ; 0x1010101 8021f58: ea22 0505 bic.w r5, r2, r5 8021f5c: f015 3f80 tst.w r5, #2155905152 ; 0x80808080 8021f60: d00d beq.n 8021f7e 8021f62: e03a b.n 8021fda 8021f64: 685b ldr r3, [r3, #4] 8021f66: 686a ldr r2, [r5, #4] 8021f68: f1a3 3501 sub.w r5, r3, #16843009 ; 0x1010101 8021f6c: 4293 cmp r3, r2 8021f6e: ea25 0503 bic.w r5, r5, r3 8021f72: d12e bne.n 8021fd2 8021f74: 3c04 subs r4, #4 8021f76: d028 beq.n 8021fca 8021f78: f015 3f80 tst.w r5, #2155905152 ; 0x80808080 8021f7c: d127 bne.n 8021fce 8021f7e: 460d mov r5, r1 8021f80: 4603 mov r3, r0 8021f82: 3104 adds r1, #4 8021f84: 3004 adds r0, #4 8021f86: 2c03 cmp r4, #3 8021f88: d8ec bhi.n 8021f64 8021f8a: 1e66 subs r6, r4, #1 8021f8c: b92c cbnz r4, 8021f9a 8021f8e: 791c ldrb r4, [r3, #4] 8021f90: 792a ldrb r2, [r5, #4] 8021f92: 1aa0 subs r0, r4, r2 8021f94: bc70 pop {r4, r5, r6} 8021f96: 4770 bx lr 8021f98: 1e56 subs r6, r2, #1 8021f9a: 7804 ldrb r4, [r0, #0] 8021f9c: 780a ldrb r2, [r1, #0] 8021f9e: 4294 cmp r4, r2 8021fa0: d1f7 bne.n 8021f92 8021fa2: b1c6 cbz r6, 8021fd6 8021fa4: b18c cbz r4, 8021fca 8021fa6: 3601 adds r6, #1 8021fa8: 1c8b adds r3, r1, #2 8021faa: 1989 adds r1, r1, r6 8021fac: e004 b.n 8021fb8 8021fae: 428b cmp r3, r1 8021fb0: f103 0301 add.w r3, r3, #1 8021fb4: d00b beq.n 8021fce 8021fb6: b144 cbz r4, 8021fca 8021fb8: f813 2c01 ldrb.w r2, [r3, #-1] 8021fbc: f810 4f01 ldrb.w r4, [r0, #1]! 8021fc0: 4294 cmp r4, r2 8021fc2: d0f4 beq.n 8021fae 8021fc4: e7e5 b.n 8021f92 8021fc6: 4610 mov r0, r2 8021fc8: e7e4 b.n 8021f94 8021fca: 4620 mov r0, r4 8021fcc: e7e2 b.n 8021f94 8021fce: 2000 movs r0, #0 8021fd0: e7e0 b.n 8021f94 8021fd2: 1e66 subs r6, r4, #1 8021fd4: e7e1 b.n 8021f9a 8021fd6: 4630 mov r0, r6 8021fd8: e7dc b.n 8021f94 8021fda: 4618 mov r0, r3 8021fdc: e7da b.n 8021f94 8021fde: bf00 nop 08021fe0 : 8021fe0: ea41 0300 orr.w r3, r1, r0 8021fe4: f013 0f03 tst.w r3, #3 8021fe8: 4603 mov r3, r0 8021fea: b470 push {r4, r5, r6} 8021fec: d025 beq.n 802203a 8021fee: b1aa cbz r2, 802201c 8021ff0: 780c ldrb r4, [r1, #0] 8021ff2: 3a01 subs r2, #1 8021ff4: f803 4b01 strb.w r4, [r3], #1 8021ff8: b14c cbz r4, 802200e 8021ffa: 461c mov r4, r3 8021ffc: b172 cbz r2, 802201c 8021ffe: f811 5f01 ldrb.w r5, [r1, #1]! 8022002: 3a01 subs r2, #1 8022004: f804 5b01 strb.w r5, [r4], #1 8022008: 4623 mov r3, r4 802200a: 2d00 cmp r5, #0 802200c: d1f6 bne.n 8021ffc 802200e: b12a cbz r2, 802201c 8022010: 189a adds r2, r3, r2 8022012: 2100 movs r1, #0 8022014: f803 1b01 strb.w r1, [r3], #1 8022018: 4293 cmp r3, r2 802201a: d1fb bne.n 8022014 802201c: bc70 pop {r4, r5, r6} 802201e: 4770 bx lr 8022020: 460e mov r6, r1 8022022: f851 4b04 ldr.w r4, [r1], #4 8022026: f1a4 3501 sub.w r5, r4, #16843009 ; 0x1010101 802202a: ea25 0504 bic.w r5, r5, r4 802202e: f015 3f80 tst.w r5, #2155905152 ; 0x80808080 8022032: d105 bne.n 8022040 8022034: 3a04 subs r2, #4 8022036: f843 4b04 str.w r4, [r3], #4 802203a: 2a03 cmp r2, #3 802203c: d8f0 bhi.n 8022020 802203e: e7d6 b.n 8021fee 8022040: 4631 mov r1, r6 8022042: e7d4 b.n 8021fee 08022044 : 8022044: b4f0 push {r4, r5, r6, r7} 8022046: 7804 ldrb r4, [r0, #0] 8022048: 2c00 cmp r4, #0 802204a: d021 beq.n 8022090 802204c: 780f ldrb r7, [r1, #0] 802204e: 4606 mov r6, r0 8022050: 4630 mov r0, r6 8022052: b1af cbz r7, 8022080 8022054: 42a7 cmp r7, r4 8022056: d019 beq.n 802208c 8022058: 1c4b adds r3, r1, #1 802205a: e001 b.n 8022060 802205c: 4294 cmp r4, r2 802205e: d009 beq.n 8022074 8022060: 461d mov r5, r3 8022062: f813 2b01 ldrb.w r2, [r3], #1 8022066: 2a00 cmp r2, #0 8022068: d1f8 bne.n 802205c 802206a: 7844 ldrb r4, [r0, #1] 802206c: 3601 adds r6, #1 802206e: 2c00 cmp r4, #0 8022070: d1ee bne.n 8022050 8022072: 782a ldrb r2, [r5, #0] 8022074: 2a00 cmp r2, #0 8022076: bf14 ite ne 8022078: 4630 movne r0, r6 802207a: 2000 moveq r0, #0 802207c: bcf0 pop {r4, r5, r6, r7} 802207e: 4770 bx lr 8022080: 7844 ldrb r4, [r0, #1] 8022082: 460d mov r5, r1 8022084: 3601 adds r6, #1 8022086: 2c00 cmp r4, #0 8022088: d1e2 bne.n 8022050 802208a: e7f2 b.n 8022072 802208c: 463a mov r2, r7 802208e: e7f1 b.n 8022074 8022090: 4620 mov r0, r4 8022092: e7f3 b.n 802207c 08022094 : 8022094: e92d 07f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl} 8022098: 2701 movs r7, #1 802209a: 463c mov r4, r7 802209c: 2500 movs r5, #0 802209e: f04f 36ff mov.w r6, #4294967295 80220a2: 1963 adds r3, r4, r5 80220a4: eb00 0c06 add.w ip, r0, r6 80220a8: 428b cmp r3, r1 80220aa: d20d bcs.n 80220c8 80220ac: f81c c004 ldrb.w ip, [ip, r4] 80220b0: f810 8003 ldrb.w r8, [r0, r3] 80220b4: 45e0 cmp r8, ip 80220b6: d22e bcs.n 8022116 80220b8: 2401 movs r4, #1 80220ba: 461d mov r5, r3 80220bc: 1b9f subs r7, r3, r6 80220be: 1963 adds r3, r4, r5 80220c0: 428b cmp r3, r1 80220c2: eb00 0c06 add.w ip, r0, r6 80220c6: d3f1 bcc.n 80220ac 80220c8: f04f 0a01 mov.w sl, #1 80220cc: 2500 movs r5, #0 80220ce: 4654 mov r4, sl 80220d0: f04f 3cff mov.w ip, #4294967295 80220d4: 6017 str r7, [r2, #0] 80220d6: 1963 adds r3, r4, r5 80220d8: eb00 080c add.w r8, r0, ip 80220dc: 4299 cmp r1, r3 80220de: d90e bls.n 80220fe 80220e0: f818 8004 ldrb.w r8, [r8, r4] 80220e4: f810 9003 ldrb.w r9, [r0, r3] 80220e8: 45c1 cmp r9, r8 80220ea: d91a bls.n 8022122 80220ec: 2401 movs r4, #1 80220ee: 461d mov r5, r3 80220f0: ebcc 0a03 rsb sl, ip, r3 80220f4: 1963 adds r3, r4, r5 80220f6: 4299 cmp r1, r3 80220f8: eb00 080c add.w r8, r0, ip 80220fc: d8f0 bhi.n 80220e0 80220fe: f10c 0001 add.w r0, ip, #1 8022102: 3601 adds r6, #1 8022104: 42b0 cmp r0, r6 8022106: bf3c itt cc 8022108: 46ba movcc sl, r7 802210a: 4630 movcc r0, r6 802210c: f8c2 a000 str.w sl, [r2] 8022110: e8bd 07f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl} 8022114: 4770 bx lr 8022116: d00b beq.n 8022130 8022118: 2701 movs r7, #1 802211a: 462e mov r6, r5 802211c: 463c mov r4, r7 802211e: 19ed adds r5, r5, r7 8022120: e7bf b.n 80220a2 8022122: d009 beq.n 8022138 8022124: f04f 0a01 mov.w sl, #1 8022128: 46ac mov ip, r5 802212a: 4654 mov r4, sl 802212c: 4455 add r5, sl 802212e: e7d2 b.n 80220d6 8022130: 42bc cmp r4, r7 8022132: d005 beq.n 8022140 8022134: 3401 adds r4, #1 8022136: e7b4 b.n 80220a2 8022138: 4554 cmp r4, sl 802213a: d005 beq.n 8022148 802213c: 3401 adds r4, #1 802213e: e7ca b.n 80220d6 8022140: 4627 mov r7, r4 8022142: 461d mov r5, r3 8022144: 2401 movs r4, #1 8022146: e7ac b.n 80220a2 8022148: 46a2 mov sl, r4 802214a: 461d mov r5, r3 802214c: 2401 movs r4, #1 802214e: e7c2 b.n 80220d6 08022150 : 8022150: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8022154: f2ad 4d24 subw sp, sp, #1060 ; 0x424 8022158: 4616 mov r6, r2 802215a: 4680 mov r8, r0 802215c: 460c mov r4, r1 802215e: 4610 mov r0, r2 8022160: 4619 mov r1, r3 8022162: aa07 add r2, sp, #28 8022164: 461d mov r5, r3 8022166: f7ff ff95 bl 8022094 802216a: ab07 add r3, sp, #28 802216c: f20d 421c addw r2, sp, #1052 ; 0x41c 8022170: 9003 str r0, [sp, #12] 8022172: f843 5f04 str.w r5, [r3, #4]! 8022176: 4293 cmp r3, r2 8022178: d1fb bne.n 8022172 802217a: 1e6f subs r7, r5, #1 802217c: 2300 movs r3, #0 802217e: a808 add r0, sp, #32 8022180: b135 cbz r5, 8022190 8022182: 5cf2 ldrb r2, [r6, r3] 8022184: 1af9 subs r1, r7, r3 8022186: 3301 adds r3, #1 8022188: 42ab cmp r3, r5 802218a: f840 1022 str.w r1, [r0, r2, lsl #2] 802218e: d1f8 bne.n 8022182 8022190: 9907 ldr r1, [sp, #28] 8022192: 4630 mov r0, r6 8022194: 9a03 ldr r2, [sp, #12] 8022196: 1871 adds r1, r6, r1 8022198: f7ff fba6 bl 80218e8 802219c: 2800 cmp r0, #0 802219e: d17f bne.n 80222a0 80221a0: f8dd c00c ldr.w ip, [sp, #12] 80221a4: 4622 mov r2, r4 80221a6: 4682 mov sl, r0 80221a8: 1e6f subs r7, r5, #1 80221aa: f10c 3cff add.w ip, ip, #4294967295 80221ae: f8cd c008 str.w ip, [sp, #8] 80221b2: 44b4 add ip, r6 80221b4: f8cd c014 str.w ip, [sp, #20] 80221b8: f8dd c00c ldr.w ip, [sp, #12] 80221bc: 4604 mov r4, r0 80221be: 9501 str r5, [sp, #4] 80221c0: f1cc 0c01 rsb ip, ip, #1 80221c4: f8cd c010 str.w ip, [sp, #16] 80221c8: e009 b.n 80221de 80221ca: b134 cbz r4, 80221da 80221cc: 9a07 ldr r2, [sp, #28] 80221ce: 4293 cmp r3, r2 80221d0: bf3e ittt cc 80221d2: 4604 movcc r4, r0 80221d4: 9901 ldrcc r1, [sp, #4] 80221d6: ebc2 0301 rsbcc r3, r2, r1 80221da: 449a add sl, r3 80221dc: 462a mov r2, r5 80221de: 9b01 ldr r3, [sp, #4] 80221e0: eb08 0002 add.w r0, r8, r2 80221e4: 2100 movs r1, #0 80221e6: eb0a 0503 add.w r5, sl, r3 80221ea: 1aaa subs r2, r5, r2 80221ec: f002 fa90 bl 8024710 80221f0: 2800 cmp r0, #0 80221f2: d14f bne.n 8022294 80221f4: 2d00 cmp r5, #0 80221f6: d04d beq.n 8022294 80221f8: eb08 0305 add.w r3, r8, r5 80221fc: a908 add r1, sp, #32 80221fe: f813 3c01 ldrb.w r3, [r3, #-1] 8022202: f851 3023 ldr.w r3, [r1, r3, lsl #2] 8022206: 2b00 cmp r3, #0 8022208: d1df bne.n 80221ca 802220a: 9a03 ldr r2, [sp, #12] 802220c: 4294 cmp r4, r2 802220e: bf28 it cs 8022210: 4622 movcs r2, r4 8022212: 42ba cmp r2, r7 8022214: d211 bcs.n 802223a 8022216: eb08 030a add.w r3, r8, sl 802221a: f816 c002 ldrb.w ip, [r6, r2] 802221e: 18b1 adds r1, r6, r2 8022220: 5c98 ldrb r0, [r3, r2] 8022222: 4584 cmp ip, r0 8022224: d006 beq.n 8022234 8022226: e02f b.n 8022288 8022228: f811 0f01 ldrb.w r0, [r1, #1]! 802222c: f813 c002 ldrb.w ip, [r3, r2] 8022230: 4584 cmp ip, r0 8022232: d129 bne.n 8022288 8022234: 3201 adds r2, #1 8022236: 42ba cmp r2, r7 8022238: d3f6 bcc.n 8022228 802223a: 9b03 ldr r3, [sp, #12] 802223c: 9802 ldr r0, [sp, #8] 802223e: 429c cmp r4, r3 8022240: bf28 it cs 8022242: 4618 movcs r0, r3 8022244: d218 bcs.n 8022278 8022246: f8dd c008 ldr.w ip, [sp, #8] 802224a: eb08 030a add.w r3, r8, sl 802224e: f816 100c ldrb.w r1, [r6, ip] 8022252: f813 200c ldrb.w r2, [r3, ip] 8022256: 4291 cmp r1, r2 8022258: f040 8085 bne.w 8022366 802225c: 9a05 ldr r2, [sp, #20] 802225e: eb06 0b04 add.w fp, r6, r4 8022262: e006 b.n 8022272 8022264: f813 c001 ldrb.w ip, [r3, r1] 8022268: f812 9d01 ldrb.w r9, [r2, #-1]! 802226c: 45e1 cmp r9, ip 802226e: d103 bne.n 8022278 8022270: 4608 mov r0, r1 8022272: 1e41 subs r1, r0, #1 8022274: 455a cmp r2, fp 8022276: d1f5 bne.n 8022264 8022278: 3401 adds r4, #1 802227a: 4284 cmp r4, r0 802227c: d875 bhi.n 802236a 802227e: 9c07 ldr r4, [sp, #28] 8022280: 9b01 ldr r3, [sp, #4] 8022282: 44a2 add sl, r4 8022284: 1b1c subs r4, r3, r4 8022286: e7a9 b.n 80221dc 8022288: f8dd c010 ldr.w ip, [sp, #16] 802228c: 2400 movs r4, #0 802228e: 44e2 add sl, ip 8022290: 4492 add sl, r2 8022292: e7a3 b.n 80221dc 8022294: 2000 movs r0, #0 8022296: b009 add sp, #36 ; 0x24 8022298: f50d 6d80 add.w sp, sp, #1024 ; 0x400 802229c: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 80222a0: f8dd c00c ldr.w ip, [sp, #12] 80222a4: f04f 0a00 mov.w sl, #0 80222a8: f8dd b00c ldr.w fp, [sp, #12] 80222ac: f10d 0920 add.w r9, sp, #32 80222b0: ebcc 0305 rsb r3, ip, r5 80222b4: 1e6f subs r7, r5, #1 80222b6: 4563 cmp r3, ip 80222b8: bf38 it cc 80222ba: 4663 movcc r3, ip 80222bc: 4622 mov r2, r4 80222be: 3301 adds r3, #1 80222c0: 9307 str r3, [sp, #28] 80222c2: f10c 33ff add.w r3, ip, #4294967295 80222c6: 9301 str r3, [sp, #4] 80222c8: 9b03 ldr r3, [sp, #12] 80222ca: 44b4 add ip, r6 80222cc: f8cd c008 str.w ip, [sp, #8] 80222d0: f1c3 0301 rsb r3, r3, #1 80222d4: 9304 str r3, [sp, #16] 80222d6: eb0a 0405 add.w r4, sl, r5 80222da: eb08 0002 add.w r0, r8, r2 80222de: 2100 movs r1, #0 80222e0: 1aa2 subs r2, r4, r2 80222e2: f002 fa15 bl 8024710 80222e6: 2800 cmp r0, #0 80222e8: d1d4 bne.n 8022294 80222ea: 2c00 cmp r4, #0 80222ec: d0d2 beq.n 8022294 80222ee: eb08 0304 add.w r3, r8, r4 80222f2: f813 3c01 ldrb.w r3, [r3, #-1] 80222f6: f859 3023 ldr.w r3, [r9, r3, lsl #2] 80222fa: bb63 cbnz r3, 8022356 80222fc: 45bb cmp fp, r7 80222fe: eb08 000a add.w r0, r8, sl 8022302: d215 bcs.n 8022330 8022304: f8dd c008 ldr.w ip, [sp, #8] 8022308: f810 300b ldrb.w r3, [r0, fp] 802230c: f89c 2000 ldrb.w r2, [ip] 8022310: 429a cmp r2, r3 8022312: bf18 it ne 8022314: 465b movne r3, fp 8022316: d121 bne.n 802235c 8022318: 9a02 ldr r2, [sp, #8] 802231a: 465b mov r3, fp 802231c: e005 b.n 802232a 802231e: f812 1f01 ldrb.w r1, [r2, #1]! 8022322: f810 c003 ldrb.w ip, [r0, r3] 8022326: 458c cmp ip, r1 8022328: d118 bne.n 802235c 802232a: 3301 adds r3, #1 802232c: 42bb cmp r3, r7 802232e: d3f6 bcc.n 802231e 8022330: 9b01 ldr r3, [sp, #4] 8022332: 1c5a adds r2, r3, #1 8022334: d0af beq.n 8022296 8022336: f8dd c004 ldr.w ip, [sp, #4] 802233a: f816 100c ldrb.w r1, [r6, ip] 802233e: f810 200c ldrb.w r2, [r0, ip] 8022342: 4291 cmp r1, r2 8022344: d106 bne.n 8022354 8022346: f113 33ff adds.w r3, r3, #4294967295 802234a: d3a4 bcc.n 8022296 802234c: 5cf1 ldrb r1, [r6, r3] 802234e: 5cc2 ldrb r2, [r0, r3] 8022350: 4291 cmp r1, r2 8022352: d0f8 beq.n 8022346 8022354: 9b07 ldr r3, [sp, #28] 8022356: 449a add sl, r3 8022358: 4622 mov r2, r4 802235a: e7bc b.n 80222d6 802235c: f8dd c010 ldr.w ip, [sp, #16] 8022360: 44e2 add sl, ip 8022362: 449a add sl, r3 8022364: e7f8 b.n 8022358 8022366: 9803 ldr r0, [sp, #12] 8022368: e786 b.n 8022278 802236a: eb08 000a add.w r0, r8, sl 802236e: e792 b.n 8022296 08022370 : 8022370: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8022374: 4680 mov r8, r0 8022376: 7803 ldrb r3, [r0, #0] 8022378: b087 sub sp, #28 802237a: 460e mov r6, r1 802237c: 2b00 cmp r3, #0 802237e: f000 80f7 beq.w 8022570 8022382: 780a ldrb r2, [r1, #0] 8022384: b19a cbz r2, 80223ae 8022386: 4684 mov ip, r0 8022388: 3101 adds r1, #1 802238a: 2701 movs r7, #1 802238c: e002 b.n 8022394 802238e: f811 2b01 ldrb.w r2, [r1], #1 8022392: b15a cbz r2, 80223ac 8022394: 4293 cmp r3, r2 8022396: bf14 ite ne 8022398: 2700 movne r7, #0 802239a: f007 0701 andeq.w r7, r7, #1 802239e: f81c 3f01 ldrb.w r3, [ip, #1]! 80223a2: 460d mov r5, r1 80223a4: 2b00 cmp r3, #0 80223a6: d1f2 bne.n 802238e 80223a8: 782b ldrb r3, [r5, #0] 80223aa: bb03 cbnz r3, 80223ee 80223ac: b11f cbz r7, 80223b6 80223ae: 4640 mov r0, r8 80223b0: b007 add sp, #28 80223b2: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 80223b6: f108 0001 add.w r0, r8, #1 80223ba: 7831 ldrb r1, [r6, #0] 80223bc: f002 fe92 bl 80250e4 80223c0: 1bad subs r5, r5, r6 80223c2: 2d01 cmp r5, #1 80223c4: bf18 it ne 80223c6: 2800 cmpne r0, #0 80223c8: 4607 mov r7, r0 80223ca: bf08 it eq 80223cc: 4680 moveq r8, r0 80223ce: d0ee beq.n 80223ae 80223d0: 44a8 add r8, r5 80223d2: 4540 cmp r0, r8 80223d4: bf94 ite ls 80223d6: ebc0 0408 rsbls r4, r0, r8 80223da: 2401 movhi r4, #1 80223dc: 2d1f cmp r5, #31 80223de: d909 bls.n 80223f4 80223e0: 4621 mov r1, r4 80223e2: 4632 mov r2, r6 80223e4: 462b mov r3, r5 80223e6: f7ff feb3 bl 8022150 80223ea: 4680 mov r8, r0 80223ec: e7df b.n 80223ae 80223ee: f04f 0800 mov.w r8, #0 80223f2: e7dc b.n 80223ae 80223f4: 4629 mov r1, r5 80223f6: aa05 add r2, sp, #20 80223f8: 4630 mov r0, r6 80223fa: f7ff fe4b bl 8022094 80223fe: 9905 ldr r1, [sp, #20] 8022400: 1871 adds r1, r6, r1 8022402: 9001 str r0, [sp, #4] 8022404: 4630 mov r0, r6 8022406: 9a01 ldr r2, [sp, #4] 8022408: f7ff fa6e bl 80218e8 802240c: 2800 cmp r0, #0 802240e: d152 bne.n 80224b6 8022410: 9b01 ldr r3, [sp, #4] 8022412: 4683 mov fp, r0 8022414: 4680 mov r8, r0 8022416: 3b01 subs r3, #1 8022418: 9300 str r3, [sp, #0] 802241a: 18f3 adds r3, r6, r3 802241c: 9303 str r3, [sp, #12] 802241e: 9b01 ldr r3, [sp, #4] 8022420: f1c3 0301 rsb r3, r3, #1 8022424: 9302 str r3, [sp, #8] 8022426: 4622 mov r2, r4 8022428: eb08 0405 add.w r4, r8, r5 802242c: 18b8 adds r0, r7, r2 802242e: 2100 movs r1, #0 8022430: 1aa2 subs r2, r4, r2 8022432: f002 f96d bl 8024710 8022436: 2800 cmp r0, #0 8022438: d1d9 bne.n 80223ee 802243a: 2c00 cmp r4, #0 802243c: d0d7 beq.n 80223ee 802243e: 9b01 ldr r3, [sp, #4] 8022440: 459b cmp fp, r3 8022442: bf28 it cs 8022444: 465b movcs r3, fp 8022446: 429d cmp r5, r3 8022448: d913 bls.n 8022472 802244a: 18f9 adds r1, r7, r3 802244c: 5cf0 ldrb r0, [r6, r3] 802244e: 18f2 adds r2, r6, r3 8022450: f811 1008 ldrb.w r1, [r1, r8] 8022454: 4288 cmp r0, r1 8022456: f040 8085 bne.w 8022564 802245a: eb07 0c08 add.w ip, r7, r8 802245e: e005 b.n 802246c 8022460: f812 1f01 ldrb.w r1, [r2, #1]! 8022464: f81c 0003 ldrb.w r0, [ip, r3] 8022468: 4288 cmp r0, r1 802246a: d17b bne.n 8022564 802246c: 3301 adds r3, #1 802246e: 429d cmp r5, r3 8022470: d8f6 bhi.n 8022460 8022472: e89d 000a ldmia.w sp, {r1, r3} 8022476: 455b cmp r3, fp 8022478: d97d bls.n 8022576 802247a: eb07 0908 add.w r9, r7, r8 802247e: 5c72 ldrb r2, [r6, r1] 8022480: f819 3001 ldrb.w r3, [r9, r1] 8022484: 429a cmp r2, r3 8022486: d176 bne.n 8022576 8022488: 9b03 ldr r3, [sp, #12] 802248a: eb06 0a0b add.w sl, r6, fp 802248e: e006 b.n 802249e 8022490: f819 0002 ldrb.w r0, [r9, r2] 8022494: f813 cd01 ldrb.w ip, [r3, #-1]! 8022498: 4584 cmp ip, r0 802249a: d103 bne.n 80224a4 802249c: 4611 mov r1, r2 802249e: 1e4a subs r2, r1, #1 80224a0: 4553 cmp r3, sl 80224a2: d1f5 bne.n 8022490 80224a4: f10b 0b01 add.w fp, fp, #1 80224a8: 458b cmp fp, r1 80224aa: d866 bhi.n 802257a 80224ac: 9b05 ldr r3, [sp, #20] 80224ae: 4498 add r8, r3 80224b0: ebc3 0b05 rsb fp, r3, r5 80224b4: e7b7 b.n 8022426 80224b6: 9801 ldr r0, [sp, #4] 80224b8: f04f 0b00 mov.w fp, #0 80224bc: 4622 mov r2, r4 80224be: 1a2b subs r3, r5, r0 80224c0: eb06 0900 add.w r9, r6, r0 80224c4: f100 38ff add.w r8, r0, #4294967295 80224c8: 4682 mov sl, r0 80224ca: 4283 cmp r3, r0 80224cc: bf38 it cc 80224ce: 4603 movcc r3, r0 80224d0: 1839 adds r1, r7, r0 80224d2: 3301 adds r3, #1 80224d4: 9100 str r1, [sp, #0] 80224d6: 9305 str r3, [sp, #20] 80224d8: f1c0 0301 rsb r3, r0, #1 80224dc: 9302 str r3, [sp, #8] 80224de: eb0b 0405 add.w r4, fp, r5 80224e2: 18b8 adds r0, r7, r2 80224e4: 2100 movs r1, #0 80224e6: 1aa2 subs r2, r4, r2 80224e8: f002 f912 bl 8024710 80224ec: 2800 cmp r0, #0 80224ee: f47f af7e bne.w 80223ee 80224f2: 2c00 cmp r4, #0 80224f4: f43f af7b beq.w 80223ee 80224f8: 4555 cmp r5, sl 80224fa: bf98 it ls 80224fc: eb07 000b addls.w r0, r7, fp 8022500: d914 bls.n 802252c 8022502: 9800 ldr r0, [sp, #0] 8022504: f899 2000 ldrb.w r2, [r9] 8022508: f810 300b ldrb.w r3, [r0, fp] 802250c: 429a cmp r2, r3 802250e: d124 bne.n 802255a 8022510: 464a mov r2, r9 8022512: 4653 mov r3, sl 8022514: eb07 000b add.w r0, r7, fp 8022518: e005 b.n 8022526 802251a: f812 1f01 ldrb.w r1, [r2, #1]! 802251e: f810 c003 ldrb.w ip, [r0, r3] 8022522: 458c cmp ip, r1 8022524: d11a bne.n 802255c 8022526: 3301 adds r3, #1 8022528: 429d cmp r5, r3 802252a: d8f6 bhi.n 802251a 802252c: f1b8 3fff cmp.w r8, #4294967295 8022530: 4643 mov r3, r8 8022532: f43f af5a beq.w 80223ea 8022536: f816 1008 ldrb.w r1, [r6, r8] 802253a: f810 2008 ldrb.w r2, [r0, r8] 802253e: 4291 cmp r1, r2 8022540: d107 bne.n 8022552 8022542: f113 33ff adds.w r3, r3, #4294967295 8022546: f4ff af50 bcc.w 80223ea 802254a: 5cf1 ldrb r1, [r6, r3] 802254c: 5cc2 ldrb r2, [r0, r3] 802254e: 4291 cmp r1, r2 8022550: d0f7 beq.n 8022542 8022552: 9b05 ldr r3, [sp, #20] 8022554: 449b add fp, r3 8022556: 4622 mov r2, r4 8022558: e7c1 b.n 80224de 802255a: 4653 mov r3, sl 802255c: 9a02 ldr r2, [sp, #8] 802255e: 4493 add fp, r2 8022560: 449b add fp, r3 8022562: e7f8 b.n 8022556 8022564: 9902 ldr r1, [sp, #8] 8022566: f04f 0b00 mov.w fp, #0 802256a: 4488 add r8, r1 802256c: 4498 add r8, r3 802256e: e75a b.n 8022426 8022570: 460d mov r5, r1 8022572: 2701 movs r7, #1 8022574: e718 b.n 80223a8 8022576: 9901 ldr r1, [sp, #4] 8022578: e794 b.n 80224a4 802257a: 44b8 add r8, r7 802257c: e717 b.n 80223ae 802257e: bf00 nop 08022580 <_strtod_r>: 8022580: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8022584: b09d sub sp, #116 ; 0x74 8022586: 468c mov ip, r1 8022588: 4683 mov fp, r0 802258a: 9210 str r2, [sp, #64] ; 0x40 802258c: 4662 mov r2, ip 802258e: 2000 movs r0, #0 8022590: 2100 movs r1, #0 8022592: f8cd c05c str.w ip, [sp, #92] ; 0x5c 8022596: e9cd 0106 strd r0, r1, [sp, #24] 802259a: 4611 mov r1, r2 802259c: f812 3b01 ldrb.w r3, [r2], #1 80225a0: 2b2d cmp r3, #45 ; 0x2d 80225a2: f200 8147 bhi.w 8022834 <_strtod_r+0x2b4> 80225a6: e8df f013 tbh [pc, r3, lsl #1] 80225aa: 0131 .short 0x0131 80225ac: 01450145 .word 0x01450145 80225b0: 01450145 .word 0x01450145 80225b4: 01450145 .word 0x01450145 80225b8: 01450145 .word 0x01450145 80225bc: 01640164 .word 0x01640164 80225c0: 01640164 .word 0x01640164 80225c4: 01450164 .word 0x01450164 80225c8: 01450145 .word 0x01450145 80225cc: 01450145 .word 0x01450145 80225d0: 01450145 .word 0x01450145 80225d4: 01450145 .word 0x01450145 80225d8: 01450145 .word 0x01450145 80225dc: 01450145 .word 0x01450145 80225e0: 01450145 .word 0x01450145 80225e4: 01450145 .word 0x01450145 80225e8: 01640145 .word 0x01640145 80225ec: 01450145 .word 0x01450145 80225f0: 01450145 .word 0x01450145 80225f4: 01450145 .word 0x01450145 80225f8: 01450145 .word 0x01450145 80225fc: 01450145 .word 0x01450145 8022600: 0145012e .word 0x0145012e 8022604: 002e .short 0x002e 8022606: 2501 movs r5, #1 8022608: 9512 str r5, [sp, #72] ; 0x48 802260a: 1c4e adds r6, r1, #1 802260c: 9617 str r6, [sp, #92] ; 0x5c 802260e: 784b ldrb r3, [r1, #1] 8022610: 4699 mov r9, r3 8022612: 469a mov sl, r3 8022614: 2b00 cmp r3, #0 8022616: f000 80fc beq.w 8022812 <_strtod_r+0x292> 802261a: 2b30 cmp r3, #48 ; 0x30 802261c: bf18 it ne 802261e: f04f 0900 movne.w r9, #0 8022622: f000 8110 beq.w 8022846 <_strtod_r+0x2c6> 8022626: 2b2f cmp r3, #47 ; 0x2f 8022628: 461d mov r5, r3 802262a: f04f 0a00 mov.w sl, #0 802262e: f340 84f9 ble.w 8023024 <_strtod_r+0xaa4> 8022632: 2b39 cmp r3, #57 ; 0x39 8022634: f300 84f6 bgt.w 8023024 <_strtod_r+0xaa4> 8022638: 1c72 adds r2, r6, #1 802263a: 4657 mov r7, sl 802263c: 4654 mov r4, sl 802263e: e001 b.n 8022644 <_strtod_r+0xc4> 8022640: 2b39 cmp r3, #57 ; 0x39 8022642: dc18 bgt.n 8022676 <_strtod_r+0xf6> 8022644: eb07 0187 add.w r1, r7, r7, lsl #2 8022648: 2c08 cmp r4, #8 802264a: eb03 0141 add.w r1, r3, r1, lsl #1 802264e: bfd8 it le 8022650: f1a1 0730 suble.w r7, r1, #48 ; 0x30 8022654: dd07 ble.n 8022666 <_strtod_r+0xe6> 8022656: eb0a 018a add.w r1, sl, sl, lsl #2 802265a: 2c0f cmp r4, #15 802265c: eb03 0341 add.w r3, r3, r1, lsl #1 8022660: bfd8 it le 8022662: f1a3 0a30 suble.w sl, r3, #48 ; 0x30 8022666: 9217 str r2, [sp, #92] ; 0x5c 8022668: 4690 mov r8, r2 802266a: f812 3b01 ldrb.w r3, [r2], #1 802266e: 3401 adds r4, #1 8022670: 2b2f cmp r3, #47 ; 0x2f 8022672: 461d mov r5, r3 8022674: dce4 bgt.n 8022640 <_strtod_r+0xc0> 8022676: 4658 mov r0, fp 8022678: f8cd c010 str.w ip, [sp, #16] 802267c: f001 fd5a bl 8024134 <_localeconv_r> 8022680: 6801 ldr r1, [r0, #0] 8022682: 4658 mov r0, fp 8022684: 9105 str r1, [sp, #20] 8022686: f001 fd55 bl 8024134 <_localeconv_r> 802268a: 6800 ldr r0, [r0, #0] 802268c: f7ff fbf0 bl 8021e70 8022690: 9905 ldr r1, [sp, #20] 8022692: 4602 mov r2, r0 8022694: 4640 mov r0, r8 8022696: f7ff fc4d bl 8021f34 802269a: f8dd c010 ldr.w ip, [sp, #16] 802269e: 4680 mov r8, r0 80226a0: 2800 cmp r0, #0 80226a2: f000 8142 beq.w 802292a <_strtod_r+0x3aa> 80226a6: 2000 movs r0, #0 80226a8: 46a0 mov r8, r4 80226aa: 4601 mov r1, r0 80226ac: 9009 str r0, [sp, #36] ; 0x24 80226ae: f025 0320 bic.w r3, r5, #32 80226b2: 2b45 cmp r3, #69 ; 0x45 80226b4: f040 80df bne.w 8022876 <_strtod_r+0x2f6> 80226b8: ea48 0300 orr.w r3, r8, r0 80226bc: ea53 0309 orrs.w r3, r3, r9 80226c0: f000 811d beq.w 80228fe <_strtod_r+0x37e> 80226c4: f8dd c05c ldr.w ip, [sp, #92] ; 0x5c 80226c8: f10c 0301 add.w r3, ip, #1 80226cc: 9317 str r3, [sp, #92] ; 0x5c 80226ce: f89c 5001 ldrb.w r5, [ip, #1] 80226d2: 2d2b cmp r5, #43 ; 0x2b 80226d4: f000 84ab beq.w 802302e <_strtod_r+0xaae> 80226d8: 2d2d cmp r5, #45 ; 0x2d 80226da: f000 833d beq.w 8022d58 <_strtod_r+0x7d8> 80226de: 2200 movs r2, #0 80226e0: 920a str r2, [sp, #40] ; 0x28 80226e2: f1a5 0330 sub.w r3, r5, #48 ; 0x30 80226e6: 2b09 cmp r3, #9 80226e8: f200 842c bhi.w 8022f44 <_strtod_r+0x9c4> 80226ec: 2d30 cmp r5, #48 ; 0x30 80226ee: d106 bne.n 80226fe <_strtod_r+0x17e> 80226f0: 9b17 ldr r3, [sp, #92] ; 0x5c 80226f2: 3301 adds r3, #1 80226f4: 9317 str r3, [sp, #92] ; 0x5c 80226f6: f813 5b01 ldrb.w r5, [r3], #1 80226fa: 2d30 cmp r5, #48 ; 0x30 80226fc: d0fa beq.n 80226f4 <_strtod_r+0x174> 80226fe: f1a5 0331 sub.w r3, r5, #49 ; 0x31 8022702: 2b08 cmp r3, #8 8022704: f200 80b7 bhi.w 8022876 <_strtod_r+0x2f6> 8022708: 9a17 ldr r2, [sp, #92] ; 0x5c 802270a: 3d30 subs r5, #48 ; 0x30 802270c: 950d str r5, [sp, #52] ; 0x34 802270e: 1c53 adds r3, r2, #1 8022710: 9317 str r3, [sp, #92] ; 0x5c 8022712: 7855 ldrb r5, [r2, #1] 8022714: 920b str r2, [sp, #44] ; 0x2c 8022716: 2d2f cmp r5, #47 ; 0x2f 8022718: dd16 ble.n 8022748 <_strtod_r+0x1c8> 802271a: 2d39 cmp r5, #57 ; 0x39 802271c: dc14 bgt.n 8022748 <_strtod_r+0x1c8> 802271e: 1c93 adds r3, r2, #2 8022720: 910c str r1, [sp, #48] ; 0x30 8022722: 9a0d ldr r2, [sp, #52] ; 0x34 8022724: e001 b.n 802272a <_strtod_r+0x1aa> 8022726: 2d39 cmp r5, #57 ; 0x39 8022728: dc0b bgt.n 8022742 <_strtod_r+0x1c2> 802272a: 9317 str r3, [sp, #92] ; 0x5c 802272c: 4619 mov r1, r3 802272e: eb02 0282 add.w r2, r2, r2, lsl #2 8022732: 3301 adds r3, #1 8022734: eb05 0242 add.w r2, r5, r2, lsl #1 8022738: f813 5c01 ldrb.w r5, [r3, #-1] 802273c: 3a30 subs r2, #48 ; 0x30 802273e: 2d2f cmp r5, #47 ; 0x2f 8022740: dcf1 bgt.n 8022726 <_strtod_r+0x1a6> 8022742: 460b mov r3, r1 8022744: 990c ldr r1, [sp, #48] ; 0x30 8022746: 920d str r2, [sp, #52] ; 0x34 8022748: 9a0b ldr r2, [sp, #44] ; 0x2c 802274a: 1a9b subs r3, r3, r2 802274c: 2b08 cmp r3, #8 802274e: bfc8 it gt 8022750: f644 621f movwgt r2, #19999 ; 0x4e1f 8022754: dc05 bgt.n 8022762 <_strtod_r+0x1e2> 8022756: 9a0d ldr r2, [sp, #52] ; 0x34 8022758: f644 631f movw r3, #19999 ; 0x4e1f 802275c: 429a cmp r2, r3 802275e: bfa8 it ge 8022760: 461a movge r2, r3 8022762: 9b0a ldr r3, [sp, #40] ; 0x28 8022764: b103 cbz r3, 8022768 <_strtod_r+0x1e8> 8022766: 4252 negs r2, r2 8022768: f1b8 0f00 cmp.w r8, #0 802276c: f000 8088 beq.w 8022880 <_strtod_r+0x300> 8022770: 9d09 ldr r5, [sp, #36] ; 0x24 8022772: 4638 mov r0, r7 8022774: 2c00 cmp r4, #0 8022776: bf08 it eq 8022778: 4644 moveq r4, r8 802277a: 940a str r4, [sp, #40] ; 0x28 802277c: 1b52 subs r2, r2, r5 802277e: 9209 str r2, [sp, #36] ; 0x24 8022780: f7fd fea8 bl 80204d4 <__aeabi_ui2d> 8022784: f1b8 0f10 cmp.w r8, #16 8022788: bfb4 ite lt 802278a: 46c1 movlt r9, r8 802278c: f04f 0910 movge.w r9, #16 8022790: f1b9 0f09 cmp.w r9, #9 8022794: 4602 mov r2, r0 8022796: 460b mov r3, r1 8022798: e9cd 2306 strd r2, r3, [sp, #24] 802279c: dd16 ble.n 80227cc <_strtod_r+0x24c> 802279e: f645 4318 movw r3, #23576 ; 0x5c18 80227a2: f6c0 0303 movt r3, #2051 ; 0x803 80227a6: eb03 03c9 add.w r3, r3, r9, lsl #3 80227aa: e953 2312 ldrd r2, r3, [r3, #-72] ; 0x48 80227ae: f7fd ff07 bl 80205c0 <__aeabi_dmul> 80227b2: 4604 mov r4, r0 80227b4: 4650 mov r0, sl 80227b6: 460d mov r5, r1 80227b8: f7fd fe8c bl 80204d4 <__aeabi_ui2d> 80227bc: 4602 mov r2, r0 80227be: 460b mov r3, r1 80227c0: 4620 mov r0, r4 80227c2: 4629 mov r1, r5 80227c4: f7fd fd4a bl 802025c <__adddf3> 80227c8: e9cd 0106 strd r0, r1, [sp, #24] 80227cc: f1b8 0f0f cmp.w r8, #15 80227d0: f300 80f2 bgt.w 80229b8 <_strtod_r+0x438> 80227d4: 9c09 ldr r4, [sp, #36] ; 0x24 80227d6: 2c00 cmp r4, #0 80227d8: f000 80a2 beq.w 8022920 <_strtod_r+0x3a0> 80227dc: f340 8591 ble.w 8023302 <_strtod_r+0xd82> 80227e0: 9d09 ldr r5, [sp, #36] ; 0x24 80227e2: 2d16 cmp r5, #22 80227e4: f300 8545 bgt.w 8023272 <_strtod_r+0xcf2> 80227e8: f645 4118 movw r1, #23576 ; 0x5c18 80227ec: e9dd 2306 ldrd r2, r3, [sp, #24] 80227f0: f6c0 0103 movt r1, #2051 ; 0x803 80227f4: eb01 01c5 add.w r1, r1, r5, lsl #3 80227f8: e9d1 0100 ldrd r0, r1, [r1] 80227fc: f7fd fee0 bl 80205c0 <__aeabi_dmul> 8022800: 4681 mov r9, r0 8022802: 468a mov sl, r1 8022804: e009 b.n 802281a <_strtod_r+0x29a> 8022806: 2400 movs r4, #0 8022808: 9412 str r4, [sp, #72] ; 0x48 802280a: e6fe b.n 802260a <_strtod_r+0x8a> 802280c: f04f 0900 mov.w r9, #0 8022810: 46ca mov sl, r9 8022812: 2400 movs r4, #0 8022814: f8cd c05c str.w ip, [sp, #92] ; 0x5c 8022818: 9412 str r4, [sp, #72] ; 0x48 802281a: 9c10 ldr r4, [sp, #64] ; 0x40 802281c: b10c cbz r4, 8022822 <_strtod_r+0x2a2> 802281e: 9b17 ldr r3, [sp, #92] ; 0x5c 8022820: 6023 str r3, [r4, #0] 8022822: 9d12 ldr r5, [sp, #72] ; 0x48 8022824: b10d cbz r5, 802282a <_strtod_r+0x2aa> 8022826: f10a 4a00 add.w sl, sl, #2147483648 ; 0x80000000 802282a: 4648 mov r0, r9 802282c: 4651 mov r1, sl 802282e: b01d add sp, #116 ; 0x74 8022830: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 8022834: 2500 movs r5, #0 8022836: 2b30 cmp r3, #48 ; 0x30 8022838: 460e mov r6, r1 802283a: 9512 str r5, [sp, #72] ; 0x48 802283c: bf18 it ne 802283e: f04f 0900 movne.w r9, #0 8022842: f47f aef0 bne.w 8022626 <_strtod_r+0xa6> 8022846: 7873 ldrb r3, [r6, #1] 8022848: 2b58 cmp r3, #88 ; 0x58 802284a: f000 8383 beq.w 8022f54 <_strtod_r+0x9d4> 802284e: 1c72 adds r2, r6, #1 8022850: 2b78 cmp r3, #120 ; 0x78 8022852: f000 837f beq.w 8022f54 <_strtod_r+0x9d4> 8022856: 4616 mov r6, r2 8022858: 9217 str r2, [sp, #92] ; 0x5c 802285a: f812 3b01 ldrb.w r3, [r2], #1 802285e: 2b30 cmp r3, #48 ; 0x30 8022860: d0f9 beq.n 8022856 <_strtod_r+0x2d6> 8022862: f04f 0901 mov.w r9, #1 8022866: 2b00 cmp r3, #0 8022868: f47f aedd bne.w 8022626 <_strtod_r+0xa6> 802286c: 4699 mov r9, r3 802286e: 469a mov sl, r3 8022870: e7d3 b.n 802281a <_strtod_r+0x29a> 8022872: 9217 str r2, [sp, #92] ; 0x5c 8022874: e691 b.n 802259a <_strtod_r+0x1a> 8022876: 2200 movs r2, #0 8022878: f1b8 0f00 cmp.w r8, #0 802287c: f47f af78 bne.w 8022770 <_strtod_r+0x1f0> 8022880: ea50 0009 orrs.w r0, r0, r9 8022884: d14c bne.n 8022920 <_strtod_r+0x3a0> 8022886: 2900 cmp r1, #0 8022888: d139 bne.n 80228fe <_strtod_r+0x37e> 802288a: 3d49 subs r5, #73 ; 0x49 802288c: 2d25 cmp r5, #37 ; 0x25 802288e: d836 bhi.n 80228fe <_strtod_r+0x37e> 8022890: e8df f015 tbh [pc, r5, lsl #1] 8022894: 0035026a .word 0x0035026a 8022898: 00350035 .word 0x00350035 802289c: 00260035 .word 0x00260035 80228a0: 00350035 .word 0x00350035 80228a4: 00350035 .word 0x00350035 80228a8: 00350035 .word 0x00350035 80228ac: 00350035 .word 0x00350035 80228b0: 00350035 .word 0x00350035 80228b4: 00350035 .word 0x00350035 80228b8: 00350035 .word 0x00350035 80228bc: 00350035 .word 0x00350035 80228c0: 00350035 .word 0x00350035 80228c4: 00350035 .word 0x00350035 80228c8: 00350035 .word 0x00350035 80228cc: 00350035 .word 0x00350035 80228d0: 00350035 .word 0x00350035 80228d4: 0035026a .word 0x0035026a 80228d8: 00350035 .word 0x00350035 80228dc: 00260035 .word 0x00260035 80228e0: 4853 ldr r0, [pc, #332] ; (8022a30 <_strtod_r+0x4b0>) 80228e2: 9a17 ldr r2, [sp, #92] ; 0x5c 80228e4: f810 1f01 ldrb.w r1, [r0, #1]! 80228e8: 4613 mov r3, r2 80228ea: b169 cbz r1, 8022908 <_strtod_r+0x388> 80228ec: 785b ldrb r3, [r3, #1] 80228ee: 3201 adds r2, #1 80228f0: 2b40 cmp r3, #64 ; 0x40 80228f2: dd02 ble.n 80228fa <_strtod_r+0x37a> 80228f4: 2b5a cmp r3, #90 ; 0x5a 80228f6: bfd8 it le 80228f8: 3320 addle r3, #32 80228fa: 428b cmp r3, r1 80228fc: d0f2 beq.n 80228e4 <_strtod_r+0x364> 80228fe: f8dd 9018 ldr.w r9, [sp, #24] 8022902: f8dd a01c ldr.w sl, [sp, #28] 8022906: e784 b.n 8022812 <_strtod_r+0x292> 8022908: 1c53 adds r3, r2, #1 802290a: 9317 str r3, [sp, #92] ; 0x5c 802290c: 7853 ldrb r3, [r2, #1] 802290e: 2b28 cmp r3, #40 ; 0x28 8022910: f000 8575 beq.w 80233fe <_strtod_r+0xe7e> 8022914: 2300 movs r3, #0 8022916: 9306 str r3, [sp, #24] 8022918: 461c mov r4, r3 802291a: f6cf 74f8 movt r4, #65528 ; 0xfff8 802291e: 9407 str r4, [sp, #28] 8022920: f8dd 9018 ldr.w r9, [sp, #24] 8022924: f8dd a01c ldr.w sl, [sp, #28] 8022928: e777 b.n 802281a <_strtod_r+0x29a> 802292a: 4658 mov r0, fp 802292c: 9d17 ldr r5, [sp, #92] ; 0x5c 802292e: f001 fc01 bl 8024134 <_localeconv_r> 8022932: 6800 ldr r0, [r0, #0] 8022934: f7ff fa9c bl 8021e70 8022938: f8dd c010 ldr.w ip, [sp, #16] 802293c: 182b adds r3, r5, r0 802293e: 9317 str r3, [sp, #92] ; 0x5c 8022940: 5c2d ldrb r5, [r5, r0] 8022942: 2c00 cmp r4, #0 8022944: f040 819b bne.w 8022c7e <_strtod_r+0x6fe> 8022948: 2d30 cmp r5, #48 ; 0x30 802294a: 4620 mov r0, r4 802294c: d105 bne.n 802295a <_strtod_r+0x3da> 802294e: 3301 adds r3, #1 8022950: 9317 str r3, [sp, #92] ; 0x5c 8022952: 3001 adds r0, #1 8022954: 781d ldrb r5, [r3, #0] 8022956: 2d30 cmp r5, #48 ; 0x30 8022958: d0f9 beq.n 802294e <_strtod_r+0x3ce> 802295a: f1a5 0331 sub.w r3, r5, #49 ; 0x31 802295e: 2b08 cmp r3, #8 8022960: f200 819a bhi.w 8022c98 <_strtod_r+0x718> 8022964: 9e17 ldr r6, [sp, #92] ; 0x5c 8022966: f04f 0800 mov.w r8, #0 802296a: 9009 str r0, [sp, #36] ; 0x24 802296c: f1a5 0130 sub.w r1, r5, #48 ; 0x30 8022970: 2001 movs r0, #1 8022972: 960a str r6, [sp, #40] ; 0x28 8022974: 2900 cmp r1, #0 8022976: f000 836c beq.w 8023052 <_strtod_r+0xad2> 802297a: 9a09 ldr r2, [sp, #36] ; 0x24 802297c: 2801 cmp r0, #1 802297e: 4402 add r2, r0 8022980: 9209 str r2, [sp, #36] ; 0x24 8022982: f000 8532 beq.w 80233ea <_strtod_r+0xe6a> 8022986: eb08 0200 add.w r2, r8, r0 802298a: 4643 mov r3, r8 802298c: 3a01 subs r2, #1 802298e: f8cd 802c str.w r8, [sp, #44] ; 0x2c 8022992: 4690 mov r8, r2 8022994: e003 b.n 802299e <_strtod_r+0x41e> 8022996: 006f lsls r7, r5, #1 8022998: 4543 cmp r3, r8 802299a: f000 834b beq.w 8023034 <_strtod_r+0xab4> 802299e: 3301 adds r3, #1 80229a0: eb07 0587 add.w r5, r7, r7, lsl #2 80229a4: 1e5a subs r2, r3, #1 80229a6: 2a08 cmp r2, #8 80229a8: ddf5 ble.n 8022996 <_strtod_r+0x416> 80229aa: eb0a 028a add.w r2, sl, sl, lsl #2 80229ae: 2b10 cmp r3, #16 80229b0: bfd8 it le 80229b2: ea4f 0a42 movle.w sl, r2, lsl #1 80229b6: e7ef b.n 8022998 <_strtod_r+0x418> 80229b8: 9d09 ldr r5, [sp, #36] ; 0x24 80229ba: ebc9 0908 rsb r9, r9, r8 80229be: eb05 0409 add.w r4, r5, r9 80229c2: 2c00 cmp r4, #0 80229c4: f340 83de ble.w 8023184 <_strtod_r+0xc04> 80229c8: f014 000f ands.w r0, r4, #15 80229cc: d00d beq.n 80229ea <_strtod_r+0x46a> 80229ce: f645 4118 movw r1, #23576 ; 0x5c18 80229d2: e9dd 2306 ldrd r2, r3, [sp, #24] 80229d6: f6c0 0103 movt r1, #2051 ; 0x803 80229da: eb01 01c0 add.w r1, r1, r0, lsl #3 80229de: e9d1 0100 ldrd r0, r1, [r1] 80229e2: f7fd fded bl 80205c0 <__aeabi_dmul> 80229e6: e9cd 0106 strd r0, r1, [sp, #24] 80229ea: f034 040f bics.w r4, r4, #15 80229ee: f040 815f bne.w 8022cb0 <_strtod_r+0x730> 80229f2: f8dd 9018 ldr.w r9, [sp, #24] 80229f6: f8dd a01c ldr.w sl, [sp, #28] 80229fa: 940b str r4, [sp, #44] ; 0x2c 80229fc: 9700 str r7, [sp, #0] 80229fe: 4658 mov r0, fp 8022a00: 4631 mov r1, r6 8022a02: 9a0a ldr r2, [sp, #40] ; 0x28 8022a04: 4643 mov r3, r8 8022a06: f001 ff67 bl 80248d8 <__s2b> 8022a0a: 9d09 ldr r5, [sp, #36] ; 0x24 8022a0c: 2d00 cmp r5, #0 8022a0e: 9011 str r0, [sp, #68] ; 0x44 8022a10: f2c0 8472 blt.w 80232f8 <_strtod_r+0xd78> 8022a14: 2400 movs r4, #0 8022a16: 940d str r4, [sp, #52] ; 0x34 8022a18: 9d09 ldr r5, [sp, #36] ; 0x24 8022a1a: 9c11 ldr r4, [sp, #68] ; 0x44 8022a1c: ea25 75e5 bic.w r5, r5, r5, asr #31 8022a20: f8cd 9024 str.w r9, [sp, #36] ; 0x24 8022a24: 340c adds r4, #12 8022a26: 950e str r5, [sp, #56] ; 0x38 8022a28: 9413 str r4, [sp, #76] ; 0x4c 8022a2a: f8cd a028 str.w sl, [sp, #40] ; 0x28 8022a2e: e073 b.n 8022b18 <_strtod_r+0x598> 8022a30: 080409b3 .word 0x080409b3 8022a34: 9b0f ldr r3, [sp, #60] ; 0x3c 8022a36: 2b00 cmp r3, #0 8022a38: f000 81a8 beq.w 8022d8c <_strtod_r+0x80c> 8022a3c: f04f 0900 mov.w r9, #0 8022a40: 2500 movs r5, #0 8022a42: f8dd c01c ldr.w ip, [sp, #28] 8022a46: 2400 movs r4, #0 8022a48: f6c3 75f0 movt r5, #16368 ; 0x3ff0 8022a4c: f6c3 79f0 movt r9, #16368 ; 0x3ff0 8022a50: f8cd 8030 str.w r8, [sp, #48] ; 0x30 8022a54: f04f 0800 mov.w r8, #0 8022a58: 4643 mov r3, r8 8022a5a: f6c7 78f0 movt r8, #32752 ; 0x7ff0 8022a5e: f6c7 73e0 movt r3, #32736 ; 0x7fe0 8022a62: ea0c 0808 and.w r8, ip, r8 8022a66: 4598 cmp r8, r3 8022a68: f000 81c5 beq.w 8022df6 <_strtod_r+0x876> 8022a6c: 9a0b ldr r2, [sp, #44] ; 0x2c 8022a6e: f1b8 6fd4 cmp.w r8, #111149056 ; 0x6a00000 8022a72: bf8c ite hi 8022a74: 2300 movhi r3, #0 8022a76: 2301 movls r3, #1 8022a78: 2a00 cmp r2, #0 8022a7a: bf08 it eq 8022a7c: 2300 moveq r3, #0 8022a7e: b1eb cbz r3, 8022abc <_strtod_r+0x53c> 8022a80: 980c ldr r0, [sp, #48] ; 0x30 8022a82: 4649 mov r1, r9 8022a84: a388 add r3, pc, #544 ; (adr r3, 8022ca8 <_strtod_r+0x728>) 8022a86: e9d3 2300 ldrd r2, r3, [r3] 8022a8a: f7fe f815 bl 8020ab8 <__aeabi_dcmple> 8022a8e: b188 cbz r0, 8022ab4 <_strtod_r+0x534> 8022a90: 980c ldr r0, [sp, #48] ; 0x30 8022a92: 4649 mov r1, r9 8022a94: f002 fbd6 bl 8025244 <__aeabi_d2uiz> 8022a98: 2800 cmp r0, #0 8022a9a: f000 8246 beq.w 8022f2a <_strtod_r+0x9aa> 8022a9e: f7fd fd19 bl 80204d4 <__aeabi_ui2d> 8022aa2: 4689 mov r9, r1 8022aa4: 900c str r0, [sp, #48] ; 0x30 8022aa6: 9c0f ldr r4, [sp, #60] ; 0x3c 8022aa8: f109 4300 add.w r3, r9, #2147483648 ; 0x80000000 8022aac: b104 cbz r4, 8022ab0 <_strtod_r+0x530> 8022aae: 464b mov r3, r9 8022ab0: 9c0c ldr r4, [sp, #48] ; 0x30 8022ab2: 461d mov r5, r3 8022ab4: f105 63d6 add.w r3, r5, #112197632 ; 0x6b00000 8022ab8: ebc8 0503 rsb r5, r8, r3 8022abc: 9809 ldr r0, [sp, #36] ; 0x24 8022abe: 990a ldr r1, [sp, #40] ; 0x28 8022ac0: f002 f98a bl 8024dd8 <__ulp> 8022ac4: 4602 mov r2, r0 8022ac6: 460b mov r3, r1 8022ac8: 4620 mov r0, r4 8022aca: 4629 mov r1, r5 8022acc: f7fd fd78 bl 80205c0 <__aeabi_dmul> 8022ad0: 4602 mov r2, r0 8022ad2: 460b mov r3, r1 8022ad4: 9809 ldr r0, [sp, #36] ; 0x24 8022ad6: 990a ldr r1, [sp, #40] ; 0x28 8022ad8: f7fd fbc0 bl 802025c <__adddf3> 8022adc: e9cd 0106 strd r0, r1, [sp, #24] 8022ae0: 9c07 ldr r4, [sp, #28] 8022ae2: 9009 str r0, [sp, #36] ; 0x24 8022ae4: 910a str r1, [sp, #40] ; 0x28 8022ae6: 9d0b ldr r5, [sp, #44] ; 0x2c 8022ae8: b935 cbnz r5, 8022af8 <_strtod_r+0x578> 8022aea: 2300 movs r3, #0 8022aec: f6c7 73f0 movt r3, #32752 ; 0x7ff0 8022af0: 4023 ands r3, r4 8022af2: 4598 cmp r8, r3 8022af4: f000 81bc beq.w 8022e70 <_strtod_r+0x8f0> 8022af8: 4658 mov r0, fp 8022afa: 9918 ldr r1, [sp, #96] ; 0x60 8022afc: f001 fe8c bl 8024818 <_Bfree> 8022b00: 4658 mov r0, fp 8022b02: 4651 mov r1, sl 8022b04: f001 fe88 bl 8024818 <_Bfree> 8022b08: 4658 mov r0, fp 8022b0a: 4639 mov r1, r7 8022b0c: f001 fe84 bl 8024818 <_Bfree> 8022b10: 4658 mov r0, fp 8022b12: 4631 mov r1, r6 8022b14: f001 fe80 bl 8024818 <_Bfree> 8022b18: 9c11 ldr r4, [sp, #68] ; 0x44 8022b1a: 4658 mov r0, fp 8022b1c: ad16 add r5, sp, #88 ; 0x58 8022b1e: 6861 ldr r1, [r4, #4] 8022b20: f001 fe44 bl 80247ac <_Balloc> 8022b24: 6923 ldr r3, [r4, #16] 8022b26: 9913 ldr r1, [sp, #76] ; 0x4c 8022b28: 1c9a adds r2, r3, #2 8022b2a: 0092 lsls r2, r2, #2 8022b2c: 4682 mov sl, r0 8022b2e: 300c adds r0, #12 8022b30: f7fe ff0c bl 802194c 8022b34: 9a09 ldr r2, [sp, #36] ; 0x24 8022b36: 9b0a ldr r3, [sp, #40] ; 0x28 8022b38: a819 add r0, sp, #100 ; 0x64 8022b3a: 9500 str r5, [sp, #0] 8022b3c: 9001 str r0, [sp, #4] 8022b3e: 4658 mov r0, fp 8022b40: f002 f9c4 bl 8024ecc <__d2b> 8022b44: 2101 movs r1, #1 8022b46: 9018 str r0, [sp, #96] ; 0x60 8022b48: 4658 mov r0, fp 8022b4a: f001 ff5d bl 8024a08 <__i2b> 8022b4e: 9a16 ldr r2, [sp, #88] ; 0x58 8022b50: 9b19 ldr r3, [sp, #100] ; 0x64 8022b52: f46f 717f mvn.w r1, #1020 ; 0x3fc 8022b56: 2a00 cmp r2, #0 8022b58: bfaa itet ge 8022b5a: 9d0d ldrge r5, [sp, #52] ; 0x34 8022b5c: 9c0e ldrlt r4, [sp, #56] ; 0x38 8022b5e: 18ac addge r4, r5, r2 8022b60: 9d0b ldr r5, [sp, #44] ; 0x2c 8022b62: 4607 mov r7, r0 8022b64: bfb8 it lt 8022b66: ebc2 0004 rsblt r0, r2, r4 8022b6a: ebc5 0202 rsb r2, r5, r2 8022b6e: bfb8 it lt 8022b70: 9c0d ldrlt r4, [sp, #52] ; 0x34 8022b72: eb02 0503 add.w r5, r2, r3 8022b76: bfa8 it ge 8022b78: 980e ldrge r0, [sp, #56] ; 0x38 8022b7a: 428d cmp r5, r1 8022b7c: 990d ldr r1, [sp, #52] ; 0x34 8022b7e: bfb4 ite lt 8022b80: f202 4333 addwlt r3, r2, #1075 ; 0x433 8022b84: f1c3 0336 rsbge r3, r3, #54 ; 0x36 8022b88: 18e6 adds r6, r4, r3 8022b8a: 18c3 adds r3, r0, r3 8022b8c: 980b ldr r0, [sp, #44] ; 0x2c 8022b8e: 181d adds r5, r3, r0 8022b90: 42a6 cmp r6, r4 8022b92: bfb4 ite lt 8022b94: 4633 movlt r3, r6 8022b96: 4623 movge r3, r4 8022b98: 42ab cmp r3, r5 8022b9a: bfa8 it ge 8022b9c: 462b movge r3, r5 8022b9e: 2b00 cmp r3, #0 8022ba0: bfc2 ittt gt 8022ba2: ebc3 0606 rsbgt r6, r3, r6 8022ba6: ebc3 0505 rsbgt r5, r3, r5 8022baa: ebc3 0404 rsbgt r4, r3, r4 8022bae: b189 cbz r1, 8022bd4 <_strtod_r+0x654> 8022bb0: 460a mov r2, r1 8022bb2: 4658 mov r0, fp 8022bb4: 4639 mov r1, r7 8022bb6: f001 ffcf bl 8024b58 <__pow5mult> 8022bba: 9a18 ldr r2, [sp, #96] ; 0x60 8022bbc: 4607 mov r7, r0 8022bbe: 4658 mov r0, fp 8022bc0: 4639 mov r1, r7 8022bc2: f001 ff2b bl 8024a1c <__multiply> 8022bc6: 9918 ldr r1, [sp, #96] ; 0x60 8022bc8: 4680 mov r8, r0 8022bca: 4658 mov r0, fp 8022bcc: f001 fe24 bl 8024818 <_Bfree> 8022bd0: f8cd 8060 str.w r8, [sp, #96] ; 0x60 8022bd4: 2e00 cmp r6, #0 8022bd6: dd05 ble.n 8022be4 <_strtod_r+0x664> 8022bd8: 4658 mov r0, fp 8022bda: 9918 ldr r1, [sp, #96] ; 0x60 8022bdc: 4632 mov r2, r6 8022bde: f002 f80d bl 8024bfc <__lshift> 8022be2: 9018 str r0, [sp, #96] ; 0x60 8022be4: 9a0e ldr r2, [sp, #56] ; 0x38 8022be6: b122 cbz r2, 8022bf2 <_strtod_r+0x672> 8022be8: 4651 mov r1, sl 8022bea: 4658 mov r0, fp 8022bec: f001 ffb4 bl 8024b58 <__pow5mult> 8022bf0: 4682 mov sl, r0 8022bf2: 2d00 cmp r5, #0 8022bf4: dd05 ble.n 8022c02 <_strtod_r+0x682> 8022bf6: 4651 mov r1, sl 8022bf8: 4658 mov r0, fp 8022bfa: 462a mov r2, r5 8022bfc: f001 fffe bl 8024bfc <__lshift> 8022c00: 4682 mov sl, r0 8022c02: 2c00 cmp r4, #0 8022c04: dd05 ble.n 8022c12 <_strtod_r+0x692> 8022c06: 4639 mov r1, r7 8022c08: 4658 mov r0, fp 8022c0a: 4622 mov r2, r4 8022c0c: f001 fff6 bl 8024bfc <__lshift> 8022c10: 4607 mov r7, r0 8022c12: 9918 ldr r1, [sp, #96] ; 0x60 8022c14: 4652 mov r2, sl 8022c16: 4658 mov r0, fp 8022c18: f04f 0800 mov.w r8, #0 8022c1c: f002 f866 bl 8024cec <__mdiff> 8022c20: 4639 mov r1, r7 8022c22: 68c4 ldr r4, [r0, #12] 8022c24: 4606 mov r6, r0 8022c26: f8c0 800c str.w r8, [r0, #12] 8022c2a: 940f str r4, [sp, #60] ; 0x3c 8022c2c: f002 f840 bl 8024cb0 <__mcmp> 8022c30: 4540 cmp r0, r8 8022c32: f2c0 8213 blt.w 802305c <_strtod_r+0xadc> 8022c36: f000 8261 beq.w 80230fc <_strtod_r+0xb7c> 8022c3a: 4630 mov r0, r6 8022c3c: 4639 mov r1, r7 8022c3e: f002 f9a3 bl 8024f88 <__ratio> 8022c42: 2200 movs r2, #0 8022c44: f04f 4380 mov.w r3, #1073741824 ; 0x40000000 8022c48: 4604 mov r4, r0 8022c4a: 460d mov r5, r1 8022c4c: f7fd ff34 bl 8020ab8 <__aeabi_dcmple> 8022c50: 2800 cmp r0, #0 8022c52: f47f aeef bne.w 8022a34 <_strtod_r+0x4b4> 8022c56: 2300 movs r3, #0 8022c58: 4620 mov r0, r4 8022c5a: f6c3 73e0 movt r3, #16352 ; 0x3fe0 8022c5e: 4629 mov r1, r5 8022c60: 2200 movs r2, #0 8022c62: f7fd fcad bl 80205c0 <__aeabi_dmul> 8022c66: 9c0f ldr r4, [sp, #60] ; 0x3c 8022c68: 900c str r0, [sp, #48] ; 0x30 8022c6a: 4689 mov r9, r1 8022c6c: f101 4300 add.w r3, r1, #2147483648 ; 0x80000000 8022c70: b104 cbz r4, 8022c74 <_strtod_r+0x6f4> 8022c72: 460b mov r3, r1 8022c74: 9c0c ldr r4, [sp, #48] ; 0x30 8022c76: 461d mov r5, r3 8022c78: f8dd c01c ldr.w ip, [sp, #28] 8022c7c: e6ea b.n 8022a54 <_strtod_r+0x4d4> 8022c7e: 4640 mov r0, r8 8022c80: 46a0 mov r8, r4 8022c82: 9009 str r0, [sp, #36] ; 0x24 8022c84: f1a5 0130 sub.w r1, r5, #48 ; 0x30 8022c88: 2909 cmp r1, #9 8022c8a: d803 bhi.n 8022c94 <_strtod_r+0x714> 8022c8c: 9a17 ldr r2, [sp, #92] ; 0x5c 8022c8e: 3001 adds r0, #1 8022c90: 920a str r2, [sp, #40] ; 0x28 8022c92: e66f b.n 8022974 <_strtod_r+0x3f4> 8022c94: 2101 movs r1, #1 8022c96: e50a b.n 80226ae <_strtod_r+0x12e> 8022c98: f04f 0800 mov.w r8, #0 8022c9c: 2101 movs r1, #1 8022c9e: f8cd 8024 str.w r8, [sp, #36] ; 0x24 8022ca2: e504 b.n 80226ae <_strtod_r+0x12e> 8022ca4: f3af 8000 nop.w 8022ca8: ffc00000 .word 0xffc00000 8022cac: 41dfffff .word 0x41dfffff 8022cb0: f5b4 7f9a cmp.w r4, #308 ; 0x134 8022cb4: f300 8258 bgt.w 8023168 <_strtod_r+0xbe8> 8022cb8: 1124 asrs r4, r4, #4 8022cba: f645 5a08 movw sl, #23816 ; 0x5d08 8022cbe: 2c01 cmp r4, #1 8022cc0: f340 8398 ble.w 80233f4 <_strtod_r+0xe74> 8022cc4: f6c0 0a03 movt sl, #2051 ; 0x803 8022cc8: e9dd 2306 ldrd r2, r3, [sp, #24] 8022ccc: f04f 0900 mov.w r9, #0 8022cd0: 4655 mov r5, sl 8022cd2: f014 0f01 tst.w r4, #1 8022cd6: 4610 mov r0, r2 8022cd8: 4619 mov r1, r3 8022cda: ea4f 0464 mov.w r4, r4, asr #1 8022cde: f109 0901 add.w r9, r9, #1 8022ce2: d005 beq.n 8022cf0 <_strtod_r+0x770> 8022ce4: e9d5 2300 ldrd r2, r3, [r5] 8022ce8: f7fd fc6a bl 80205c0 <__aeabi_dmul> 8022cec: 4602 mov r2, r0 8022cee: 460b mov r3, r1 8022cf0: 3508 adds r5, #8 8022cf2: 2c01 cmp r4, #1 8022cf4: dced bgt.n 8022cd2 <_strtod_r+0x752> 8022cf6: 4610 mov r0, r2 8022cf8: 4619 mov r1, r3 8022cfa: e9cd 0106 strd r0, r1, [sp, #24] 8022cfe: 9907 ldr r1, [sp, #28] 8022d00: eb0a 09c9 add.w r9, sl, r9, lsl #3 8022d04: f1a1 7154 sub.w r1, r1, #55574528 ; 0x3500000 8022d08: 9107 str r1, [sp, #28] 8022d0a: e9dd 2306 ldrd r2, r3, [sp, #24] 8022d0e: e9d9 0100 ldrd r0, r1, [r9] 8022d12: f7fd fc55 bl 80205c0 <__aeabi_dmul> 8022d16: 2300 movs r3, #0 8022d18: 2200 movs r2, #0 8022d1a: f6c7 73f0 movt r3, #32752 ; 0x7ff0 8022d1e: f6c7 42a0 movt r2, #31904 ; 0x7ca0 8022d22: e9cd 0106 strd r0, r1, [sp, #24] 8022d26: 9907 ldr r1, [sp, #28] 8022d28: 400b ands r3, r1 8022d2a: 4293 cmp r3, r2 8022d2c: f200 821c bhi.w 8023168 <_strtod_r+0xbe8> 8022d30: 2200 movs r2, #0 8022d32: f6c7 4290 movt r2, #31888 ; 0x7c90 8022d36: 4293 cmp r3, r2 8022d38: f240 8305 bls.w 8023346 <_strtod_r+0xdc6> 8022d3c: f64f 72ff movw r2, #65535 ; 0xffff 8022d40: f04f 30ff mov.w r0, #4294967295 8022d44: 4615 mov r5, r2 8022d46: 2400 movs r4, #0 8022d48: f6c7 75ef movt r5, #32751 ; 0x7fef 8022d4c: 940b str r4, [sp, #44] ; 0x2c 8022d4e: 9507 str r5, [sp, #28] 8022d50: 4681 mov r9, r0 8022d52: 9006 str r0, [sp, #24] 8022d54: 46aa mov sl, r5 8022d56: e651 b.n 80229fc <_strtod_r+0x47c> 8022d58: 2301 movs r3, #1 8022d5a: 930a str r3, [sp, #40] ; 0x28 8022d5c: f10c 0302 add.w r3, ip, #2 8022d60: 9317 str r3, [sp, #92] ; 0x5c 8022d62: f89c 5002 ldrb.w r5, [ip, #2] 8022d66: e4bc b.n 80226e2 <_strtod_r+0x162> 8022d68: 48ab ldr r0, [pc, #684] ; (8023018 <_strtod_r+0xa98>) 8022d6a: 9a17 ldr r2, [sp, #92] ; 0x5c 8022d6c: f810 1f01 ldrb.w r1, [r0, #1]! 8022d70: 4613 mov r3, r2 8022d72: 2900 cmp r1, #0 8022d74: f000 8311 beq.w 802339a <_strtod_r+0xe1a> 8022d78: 785b ldrb r3, [r3, #1] 8022d7a: 3201 adds r2, #1 8022d7c: 2b40 cmp r3, #64 ; 0x40 8022d7e: dd02 ble.n 8022d86 <_strtod_r+0x806> 8022d80: 2b5a cmp r3, #90 ; 0x5a 8022d82: bfd8 it le 8022d84: 3320 addle r3, #32 8022d86: 428b cmp r3, r1 8022d88: d0f0 beq.n 8022d6c <_strtod_r+0x7ec> 8022d8a: e5b8 b.n 80228fe <_strtod_r+0x37e> 8022d8c: 9b06 ldr r3, [sp, #24] 8022d8e: f8dd c01c ldr.w ip, [sp, #28] 8022d92: 2b00 cmp r3, #0 8022d94: f040 80a6 bne.w 8022ee4 <_strtod_r+0x964> 8022d98: f3cc 0313 ubfx r3, ip, #0, #20 8022d9c: bb03 cbnz r3, 8022de0 <_strtod_r+0x860> 8022d9e: 2300 movs r3, #0 8022da0: 4620 mov r0, r4 8022da2: 4629 mov r1, r5 8022da4: 2200 movs r2, #0 8022da6: f6c3 73f0 movt r3, #16368 ; 0x3ff0 8022daa: f8cd c010 str.w ip, [sp, #16] 8022dae: f7fd fe79 bl 8020aa4 <__aeabi_dcmplt> 8022db2: f8dd c010 ldr.w ip, [sp, #16] 8022db6: 2800 cmp r0, #0 8022db8: f040 8246 bne.w 8023248 <_strtod_r+0xcc8> 8022dbc: 2300 movs r3, #0 8022dbe: 2200 movs r2, #0 8022dc0: f6c3 73e0 movt r3, #16352 ; 0x3fe0 8022dc4: 4620 mov r0, r4 8022dc6: 4629 mov r1, r5 8022dc8: f7fd fbfa bl 80205c0 <__aeabi_dmul> 8022dcc: f8dd c010 ldr.w ip, [sp, #16] 8022dd0: 4689 mov r9, r1 8022dd2: 4602 mov r2, r0 8022dd4: f101 4300 add.w r3, r1, #2147483648 ; 0x80000000 8022dd8: 900c str r0, [sp, #48] ; 0x30 8022dda: 4614 mov r4, r2 8022ddc: 461d mov r5, r3 8022dde: e639 b.n 8022a54 <_strtod_r+0x4d4> 8022de0: f04f 0900 mov.w r9, #0 8022de4: 2500 movs r5, #0 8022de6: f8cd 9030 str.w r9, [sp, #48] ; 0x30 8022dea: 2400 movs r4, #0 8022dec: f6cb 75f0 movt r5, #49136 ; 0xbff0 8022df0: f6c3 79f0 movt r9, #16368 ; 0x3ff0 8022df4: e62e b.n 8022a54 <_strtod_r+0x4d4> 8022df6: f1ac 7c54 sub.w ip, ip, #55574528 ; 0x3500000 8022dfa: 9a09 ldr r2, [sp, #36] ; 0x24 8022dfc: f8cd c01c str.w ip, [sp, #28] 8022e00: 9b0a ldr r3, [sp, #40] ; 0x28 8022e02: e9dd 0106 ldrd r0, r1, [sp, #24] 8022e06: e9cd 4502 strd r4, r5, [sp, #8] 8022e0a: 4614 mov r4, r2 8022e0c: 461d mov r5, r3 8022e0e: e9cd 4514 strd r4, r5, [sp, #80] ; 0x50 8022e12: f001 ffe1 bl 8024dd8 <__ulp> 8022e16: 4602 mov r2, r0 8022e18: 460b mov r3, r1 8022e1a: e9dd 0102 ldrd r0, r1, [sp, #8] 8022e1e: f7fd fbcf bl 80205c0 <__aeabi_dmul> 8022e22: 4602 mov r2, r0 8022e24: 460b mov r3, r1 8022e26: e9dd 0106 ldrd r0, r1, [sp, #24] 8022e2a: f7fd fa17 bl 802025c <__adddf3> 8022e2e: 2300 movs r3, #0 8022e30: f6c7 73f0 movt r3, #32752 ; 0x7ff0 8022e34: f64f 72ff movw r2, #65535 ; 0xffff 8022e38: f6c7 429f movt r2, #31903 ; 0x7c9f 8022e3c: e9cd 0106 strd r0, r1, [sp, #24] 8022e40: 9c07 ldr r4, [sp, #28] 8022e42: 4023 ands r3, r4 8022e44: 4293 cmp r3, r2 8022e46: d976 bls.n 8022f36 <_strtod_r+0x9b6> 8022e48: f64f 73ff movw r3, #65535 ; 0xffff 8022e4c: 9d15 ldr r5, [sp, #84] ; 0x54 8022e4e: f6c7 73ef movt r3, #32751 ; 0x7fef 8022e52: 429d cmp r5, r3 8022e54: f000 8177 beq.w 8023146 <_strtod_r+0xbc6> 8022e58: f64f 71ff movw r1, #65535 ; 0xffff 8022e5c: f04f 33ff mov.w r3, #4294967295 8022e60: 460a mov r2, r1 8022e62: 9306 str r3, [sp, #24] 8022e64: f6c7 72ef movt r2, #32751 ; 0x7fef 8022e68: 9309 str r3, [sp, #36] ; 0x24 8022e6a: 9207 str r2, [sp, #28] 8022e6c: 920a str r2, [sp, #40] ; 0x28 8022e6e: e643 b.n 8022af8 <_strtod_r+0x578> 8022e70: 4649 mov r1, r9 8022e72: 980c ldr r0, [sp, #48] ; 0x30 8022e74: f7fd fe3e bl 8020af4 <__aeabi_d2iz> 8022e78: f7fd fb3c bl 80204f4 <__aeabi_i2d> 8022e7c: 4602 mov r2, r0 8022e7e: 460b mov r3, r1 8022e80: 980c ldr r0, [sp, #48] ; 0x30 8022e82: 4649 mov r1, r9 8022e84: f7fd f9e8 bl 8020258 <__aeabi_dsub> 8022e88: 9d0f ldr r5, [sp, #60] ; 0x3c 8022e8a: 4680 mov r8, r0 8022e8c: 4689 mov r9, r1 8022e8e: 2d00 cmp r5, #0 8022e90: d137 bne.n 8022f02 <_strtod_r+0x982> 8022e92: 9a06 ldr r2, [sp, #24] 8022e94: 2a00 cmp r2, #0 8022e96: d134 bne.n 8022f02 <_strtod_r+0x982> 8022e98: f3c4 0413 ubfx r4, r4, #0, #20 8022e9c: 2c00 cmp r4, #0 8022e9e: d130 bne.n 8022f02 <_strtod_r+0x982> 8022ea0: a357 add r3, pc, #348 ; (adr r3, 8023000 <_strtod_r+0xa80>) 8022ea2: e9d3 2300 ldrd r2, r3, [r3] 8022ea6: f7fd fdfd bl 8020aa4 <__aeabi_dcmplt> 8022eaa: 2800 cmp r0, #0 8022eac: f43f ae24 beq.w 8022af8 <_strtod_r+0x578> 8022eb0: 4654 mov r4, sl 8022eb2: f8dd 9024 ldr.w r9, [sp, #36] ; 0x24 8022eb6: f8dd a028 ldr.w sl, [sp, #40] ; 0x28 8022eba: 4658 mov r0, fp 8022ebc: 9918 ldr r1, [sp, #96] ; 0x60 8022ebe: f001 fcab bl 8024818 <_Bfree> 8022ec2: 4658 mov r0, fp 8022ec4: 4621 mov r1, r4 8022ec6: f001 fca7 bl 8024818 <_Bfree> 8022eca: 4658 mov r0, fp 8022ecc: 4639 mov r1, r7 8022ece: f001 fca3 bl 8024818 <_Bfree> 8022ed2: 4658 mov r0, fp 8022ed4: 9911 ldr r1, [sp, #68] ; 0x44 8022ed6: f001 fc9f bl 8024818 <_Bfree> 8022eda: 4658 mov r0, fp 8022edc: 4631 mov r1, r6 8022ede: f001 fc9b bl 8024818 <_Bfree> 8022ee2: e49a b.n 802281a <_strtod_r+0x29a> 8022ee4: 2b01 cmp r3, #1 8022ee6: f47f af7b bne.w 8022de0 <_strtod_r+0x860> 8022eea: 4661 mov r1, ip 8022eec: 2900 cmp r1, #0 8022eee: f47f af77 bne.w 8022de0 <_strtod_r+0x860> 8022ef2: 4654 mov r4, sl 8022ef4: f04f 0900 mov.w r9, #0 8022ef8: 46ca mov sl, r9 8022efa: 2322 movs r3, #34 ; 0x22 8022efc: f8cb 3000 str.w r3, [fp] 8022f00: e7db b.n 8022eba <_strtod_r+0x93a> 8022f02: 4640 mov r0, r8 8022f04: 4649 mov r1, r9 8022f06: a340 add r3, pc, #256 ; (adr r3, 8023008 <_strtod_r+0xa88>) 8022f08: e9d3 2300 ldrd r2, r3, [r3] 8022f0c: f7fd fdca bl 8020aa4 <__aeabi_dcmplt> 8022f10: 2800 cmp r0, #0 8022f12: d1cd bne.n 8022eb0 <_strtod_r+0x930> 8022f14: 4640 mov r0, r8 8022f16: 4649 mov r1, r9 8022f18: a33d add r3, pc, #244 ; (adr r3, 8023010 <_strtod_r+0xa90>) 8022f1a: e9d3 2300 ldrd r2, r3, [r3] 8022f1e: f7fd fddf bl 8020ae0 <__aeabi_dcmpgt> 8022f22: 2800 cmp r0, #0 8022f24: f43f ade8 beq.w 8022af8 <_strtod_r+0x578> 8022f28: e7c2 b.n 8022eb0 <_strtod_r+0x930> 8022f2a: f04f 0900 mov.w r9, #0 8022f2e: 900c str r0, [sp, #48] ; 0x30 8022f30: f6c3 79f0 movt r9, #16368 ; 0x3ff0 8022f34: e5b7 b.n 8022aa6 <_strtod_r+0x526> 8022f36: 9906 ldr r1, [sp, #24] 8022f38: f104 7454 add.w r4, r4, #55574528 ; 0x3500000 8022f3c: 9407 str r4, [sp, #28] 8022f3e: 940a str r4, [sp, #40] ; 0x28 8022f40: 9109 str r1, [sp, #36] ; 0x24 8022f42: e5d0 b.n 8022ae6 <_strtod_r+0x566> 8022f44: f8cd c05c str.w ip, [sp, #92] ; 0x5c 8022f48: 2200 movs r2, #0 8022f4a: f1b8 0f00 cmp.w r8, #0 8022f4e: f47f ac0f bne.w 8022770 <_strtod_r+0x1f0> 8022f52: e495 b.n 8022880 <_strtod_r+0x300> 8022f54: 9d12 ldr r5, [sp, #72] ; 0x48 8022f56: f240 0404 movw r4, #4 8022f5a: f2c2 0400 movt r4, #8192 ; 0x2000 8022f5e: ab18 add r3, sp, #96 ; 0x60 8022f60: 4658 mov r0, fp 8022f62: e88d 0028 stmia.w sp, {r3, r5} 8022f66: a917 add r1, sp, #92 ; 0x5c 8022f68: 4622 mov r2, r4 8022f6a: ab19 add r3, sp, #100 ; 0x64 8022f6c: f000 fd1c bl 80239a8 <__gethex> 8022f70: f010 0707 ands.w r7, r0, #7 8022f74: 4605 mov r5, r0 8022f76: bf04 itt eq 8022f78: 46b9 moveq r9, r7 8022f7a: 46ca moveq sl, r9 8022f7c: f43f ac4d beq.w 802281a <_strtod_r+0x29a> 8022f80: 2f06 cmp r7, #6 8022f82: f000 816f beq.w 8023264 <_strtod_r+0xce4> 8022f86: 9a18 ldr r2, [sp, #96] ; 0x60 8022f88: b13a cbz r2, 8022f9a <_strtod_r+0xa1a> 8022f8a: 6821 ldr r1, [r4, #0] 8022f8c: a81a add r0, sp, #104 ; 0x68 8022f8e: f002 f845 bl 802501c <__copybits> 8022f92: 4658 mov r0, fp 8022f94: 9918 ldr r1, [sp, #96] ; 0x60 8022f96: f001 fc3f bl 8024818 <_Bfree> 8022f9a: 9b19 ldr r3, [sp, #100] ; 0x64 8022f9c: 2f06 cmp r7, #6 8022f9e: d80b bhi.n 8022fb8 <_strtod_r+0xa38> 8022fa0: e8df f007 tbb [pc, r7] 8022fa4: 141b203c .word 0x141b203c 8022fa8: 2004 .short 0x2004 8022faa: 3c .byte 0x3c 8022fab: 00 .byte 0x00 8022fac: f06f 4400 mvn.w r4, #2147483648 ; 0x80000000 8022fb0: f04f 30ff mov.w r0, #4294967295 8022fb4: 9407 str r4, [sp, #28] 8022fb6: 9006 str r0, [sp, #24] 8022fb8: 072b lsls r3, r5, #28 8022fba: f57f acb1 bpl.w 8022920 <_strtod_r+0x3a0> 8022fbe: 9907 ldr r1, [sp, #28] 8022fc0: f8dd 9018 ldr.w r9, [sp, #24] 8022fc4: f041 4300 orr.w r3, r1, #2147483648 ; 0x80000000 8022fc8: 469a mov sl, r3 8022fca: e426 b.n 802281a <_strtod_r+0x29a> 8022fcc: 2100 movs r1, #0 8022fce: 9106 str r1, [sp, #24] 8022fd0: 460a mov r2, r1 8022fd2: f6c7 72f0 movt r2, #32752 ; 0x7ff0 8022fd6: 9207 str r2, [sp, #28] 8022fd8: e7ee b.n 8022fb8 <_strtod_r+0xa38> 8022fda: 9b1a ldr r3, [sp, #104] ; 0x68 8022fdc: 9c1b ldr r4, [sp, #108] ; 0x6c 8022fde: 9306 str r3, [sp, #24] 8022fe0: 9407 str r4, [sp, #28] 8022fe2: e7e9 b.n 8022fb8 <_strtod_r+0xa38> 8022fe4: 981a ldr r0, [sp, #104] ; 0x68 8022fe6: f203 4333 addw r3, r3, #1075 ; 0x433 8022fea: 9a1b ldr r2, [sp, #108] ; 0x6c 8022fec: f422 1280 bic.w r2, r2, #1048576 ; 0x100000 8022ff0: 9006 str r0, [sp, #24] 8022ff2: ea42 5203 orr.w r2, r2, r3, lsl #20 8022ff6: 9207 str r2, [sp, #28] 8022ff8: e7de b.n 8022fb8 <_strtod_r+0xa38> 8022ffa: bf00 nop 8022ffc: f3af 8000 nop.w 8023000: 94a03595 .word 0x94a03595 8023004: 3fcfffff .word 0x3fcfffff 8023008: 94a03595 .word 0x94a03595 802300c: 3fdfffff .word 0x3fdfffff 8023010: 35afe535 .word 0x35afe535 8023014: 3fe00000 .word 0x3fe00000 8023018: 080409a7 .word 0x080409a7 802301c: 2100 movs r1, #0 802301e: 9107 str r1, [sp, #28] 8023020: 9106 str r1, [sp, #24] 8023022: e7c9 b.n 8022fb8 <_strtod_r+0xa38> 8023024: 46b0 mov r8, r6 8023026: 4657 mov r7, sl 8023028: 4654 mov r4, sl 802302a: f7ff bb24 b.w 8022676 <_strtod_r+0xf6> 802302e: 2300 movs r3, #0 8023030: 930a str r3, [sp, #40] ; 0x28 8023032: e693 b.n 8022d5c <_strtod_r+0x7dc> 8023034: f8dd 802c ldr.w r8, [sp, #44] ; 0x2c 8023038: eb08 0300 add.w r3, r8, r0 802303c: 3b01 subs r3, #1 802303e: 2b08 cmp r3, #8 8023040: f103 0801 add.w r8, r3, #1 8023044: f300 8172 bgt.w 802332c <_strtod_r+0xdac> 8023048: eb07 0787 add.w r7, r7, r7, lsl #2 802304c: 2000 movs r0, #0 802304e: eb01 0747 add.w r7, r1, r7, lsl #1 8023052: 9d0a ldr r5, [sp, #40] ; 0x28 8023054: 1c6b adds r3, r5, #1 8023056: 9317 str r3, [sp, #92] ; 0x5c 8023058: 786d ldrb r5, [r5, #1] 802305a: e613 b.n 8022c84 <_strtod_r+0x704> 802305c: 9d0f ldr r5, [sp, #60] ; 0x3c 802305e: 4654 mov r4, sl 8023060: bb7d cbnz r5, 80230c2 <_strtod_r+0xb42> 8023062: 9806 ldr r0, [sp, #24] 8023064: bb68 cbnz r0, 80230c2 <_strtod_r+0xb42> 8023066: 9a07 ldr r2, [sp, #28] 8023068: f3c2 0313 ubfx r3, r2, #0, #20 802306c: bb4b cbnz r3, 80230c2 <_strtod_r+0xb42> 802306e: 4643 mov r3, r8 8023070: f6c7 73f0 movt r3, #32752 ; 0x7ff0 8023074: 4013 ands r3, r2 8023076: f1b3 6fd6 cmp.w r3, #112197632 ; 0x6b00000 802307a: d922 bls.n 80230c2 <_strtod_r+0xb42> 802307c: 6973 ldr r3, [r6, #20] 802307e: b913 cbnz r3, 8023086 <_strtod_r+0xb06> 8023080: 6933 ldr r3, [r6, #16] 8023082: 2b01 cmp r3, #1 8023084: dd1d ble.n 80230c2 <_strtod_r+0xb42> 8023086: 4631 mov r1, r6 8023088: 2201 movs r2, #1 802308a: 4658 mov r0, fp 802308c: f001 fdb6 bl 8024bfc <__lshift> 8023090: 4639 mov r1, r7 8023092: 4606 mov r6, r0 8023094: f001 fe0c bl 8024cb0 <__mcmp> 8023098: 2800 cmp r0, #0 802309a: dd12 ble.n 80230c2 <_strtod_r+0xb42> 802309c: 9d0b ldr r5, [sp, #44] ; 0x2c 802309e: 2d00 cmp r5, #0 80230a0: f040 8195 bne.w 80233ce <_strtod_r+0xe4e> 80230a4: 9807 ldr r0, [sp, #28] 80230a6: f020 4300 bic.w r3, r0, #2147483648 ; 0x80000000 80230aa: 0d1b lsrs r3, r3, #20 80230ac: 051b lsls r3, r3, #20 80230ae: f5a3 1380 sub.w r3, r3, #1048576 ; 0x100000 80230b2: f04f 32ff mov.w r2, #4294967295 80230b6: 9206 str r2, [sp, #24] 80230b8: ea6f 5313 mvn.w r3, r3, lsr #20 80230bc: ea6f 5303 mvn.w r3, r3, lsl #20 80230c0: 9307 str r3, [sp, #28] 80230c2: 9d0b ldr r5, [sp, #44] ; 0x2c 80230c4: 2d00 cmp r5, #0 80230c6: f000 80c8 beq.w 802325a <_strtod_r+0xcda> 80230ca: 2200 movs r2, #0 80230cc: 2300 movs r3, #0 80230ce: f6c3 1250 movt r2, #14672 ; 0x3950 80230d2: 9314 str r3, [sp, #80] ; 0x50 80230d4: 9215 str r2, [sp, #84] ; 0x54 80230d6: e9dd 0106 ldrd r0, r1, [sp, #24] 80230da: e9dd 2314 ldrd r2, r3, [sp, #80] ; 0x50 80230de: f7fd fa6f bl 80205c0 <__aeabi_dmul> 80230e2: e9cd 0106 strd r0, r1, [sp, #24] 80230e6: 468a mov sl, r1 80230e8: 9907 ldr r1, [sp, #28] 80230ea: 4681 mov r9, r0 80230ec: 2900 cmp r1, #0 80230ee: f47f aee4 bne.w 8022eba <_strtod_r+0x93a> 80230f2: 9a06 ldr r2, [sp, #24] 80230f4: 2a00 cmp r2, #0 80230f6: f47f aee0 bne.w 8022eba <_strtod_r+0x93a> 80230fa: e6fe b.n 8022efa <_strtod_r+0x97a> 80230fc: 9d0f ldr r5, [sp, #60] ; 0x3c 80230fe: 4654 mov r4, sl 8023100: f8dd 9024 ldr.w r9, [sp, #36] ; 0x24 8023104: f8dd a028 ldr.w sl, [sp, #40] ; 0x28 8023108: 2d00 cmp r5, #0 802310a: f000 80d3 beq.w 80232b4 <_strtod_r+0xd34> 802310e: 9b07 ldr r3, [sp, #28] 8023110: f64f 72ff movw r2, #65535 ; 0xffff 8023114: f2c0 020f movt r2, #15 8023118: f023 417f bic.w r1, r3, #4278190080 ; 0xff000000 802311c: f421 0170 bic.w r1, r1, #15728640 ; 0xf00000 8023120: 4291 cmp r1, r2 8023122: 9906 ldr r1, [sp, #24] 8023124: f000 8119 beq.w 802335a <_strtod_r+0xdda> 8023128: 07cb lsls r3, r1, #31 802312a: d5ca bpl.n 80230c2 <_strtod_r+0xb42> 802312c: 4648 mov r0, r9 802312e: 4651 mov r1, sl 8023130: f001 fe52 bl 8024dd8 <__ulp> 8023134: 4602 mov r2, r0 8023136: 460b mov r3, r1 8023138: 4648 mov r0, r9 802313a: 4651 mov r1, sl 802313c: f7fd f88e bl 802025c <__adddf3> 8023140: e9cd 0106 strd r0, r1, [sp, #24] 8023144: e7bd b.n 80230c2 <_strtod_r+0xb42> 8023146: 9814 ldr r0, [sp, #80] ; 0x50 8023148: 3001 adds r0, #1 802314a: f47f ae85 bne.w 8022e58 <_strtod_r+0x8d8> 802314e: 2000 movs r0, #0 8023150: 4654 mov r4, sl 8023152: 4601 mov r1, r0 8023154: 2322 movs r3, #34 ; 0x22 8023156: f6c7 71f0 movt r1, #32752 ; 0x7ff0 802315a: f8cb 3000 str.w r3, [fp] 802315e: 9107 str r1, [sp, #28] 8023160: 4681 mov r9, r0 8023162: 9006 str r0, [sp, #24] 8023164: 468a mov sl, r1 8023166: e6a8 b.n 8022eba <_strtod_r+0x93a> 8023168: 2300 movs r3, #0 802316a: 2500 movs r5, #0 802316c: 461c mov r4, r3 802316e: 9506 str r5, [sp, #24] 8023170: f6c7 74f0 movt r4, #32752 ; 0x7ff0 8023174: 2322 movs r3, #34 ; 0x22 8023176: 9407 str r4, [sp, #28] 8023178: 46a9 mov r9, r5 802317a: f8cb 3000 str.w r3, [fp] 802317e: 46a2 mov sl, r4 8023180: f7ff bb4b b.w 802281a <_strtod_r+0x29a> 8023184: f43f ac35 beq.w 80229f2 <_strtod_r+0x472> 8023188: 4264 negs r4, r4 802318a: f014 020f ands.w r2, r4, #15 802318e: d00d beq.n 80231ac <_strtod_r+0xc2c> 8023190: f645 4318 movw r3, #23576 ; 0x5c18 8023194: e9dd 0106 ldrd r0, r1, [sp, #24] 8023198: f6c0 0303 movt r3, #2051 ; 0x803 802319c: eb03 03c2 add.w r3, r3, r2, lsl #3 80231a0: e9d3 2300 ldrd r2, r3, [r3] 80231a4: f7fd fb36 bl 8020814 <__aeabi_ddiv> 80231a8: e9cd 0106 strd r0, r1, [sp, #24] 80231ac: 1124 asrs r4, r4, #4 80231ae: f43f ac20 beq.w 80229f2 <_strtod_r+0x472> 80231b2: 2c1f cmp r4, #31 80231b4: dc40 bgt.n 8023238 <_strtod_r+0xcb8> 80231b6: f014 0f10 tst.w r4, #16 80231ba: bf14 ite ne 80231bc: 256a movne r5, #106 ; 0x6a 80231be: 2500 moveq r5, #0 80231c0: 2c00 cmp r4, #0 80231c2: 950b str r5, [sp, #44] ; 0x2c 80231c4: dd17 ble.n 80231f6 <_strtod_r+0xc76> 80231c6: f645 35e0 movw r5, #23520 ; 0x5be0 80231ca: e9dd 2306 ldrd r2, r3, [sp, #24] 80231ce: f6c0 0503 movt r5, #2051 ; 0x803 80231d2: f014 0f01 tst.w r4, #1 80231d6: 4610 mov r0, r2 80231d8: 4619 mov r1, r3 80231da: d005 beq.n 80231e8 <_strtod_r+0xc68> 80231dc: e9d5 2300 ldrd r2, r3, [r5] 80231e0: f7fd f9ee bl 80205c0 <__aeabi_dmul> 80231e4: 4602 mov r2, r0 80231e6: 460b mov r3, r1 80231e8: 3508 adds r5, #8 80231ea: 1064 asrs r4, r4, #1 80231ec: d1f1 bne.n 80231d2 <_strtod_r+0xc52> 80231ee: 4610 mov r0, r2 80231f0: 4619 mov r1, r3 80231f2: e9cd 0106 strd r0, r1, [sp, #24] 80231f6: 9c0b ldr r4, [sp, #44] ; 0x2c 80231f8: b18c cbz r4, 802321e <_strtod_r+0xc9e> 80231fa: 9a07 ldr r2, [sp, #28] 80231fc: f3c2 530a ubfx r3, r2, #20, #11 8023200: f1c3 036b rsb r3, r3, #107 ; 0x6b 8023204: 2b00 cmp r3, #0 8023206: dd0a ble.n 802321e <_strtod_r+0xc9e> 8023208: 2b1f cmp r3, #31 802320a: f340 810a ble.w 8023422 <_strtod_r+0xea2> 802320e: 2100 movs r1, #0 8023210: 2b34 cmp r3, #52 ; 0x34 8023212: 9106 str r1, [sp, #24] 8023214: f340 810d ble.w 8023432 <_strtod_r+0xeb2> 8023218: f04f 725c mov.w r2, #57671680 ; 0x3700000 802321c: 9207 str r2, [sp, #28] 802321e: 9d06 ldr r5, [sp, #24] 8023220: 2200 movs r2, #0 8023222: 9c07 ldr r4, [sp, #28] 8023224: 2300 movs r3, #0 8023226: 4628 mov r0, r5 8023228: 46a9 mov r9, r5 802322a: 4621 mov r1, r4 802322c: 46a2 mov sl, r4 802322e: f7fd fc2f bl 8020a90 <__aeabi_dcmpeq> 8023232: 2800 cmp r0, #0 8023234: f43f abe2 beq.w 80229fc <_strtod_r+0x47c> 8023238: f04f 0900 mov.w r9, #0 802323c: 2322 movs r3, #34 ; 0x22 802323e: 46ca mov sl, r9 8023240: f8cb 3000 str.w r3, [fp] 8023244: f7ff bae9 b.w 802281a <_strtod_r+0x29a> 8023248: 9a0f ldr r2, [sp, #60] ; 0x3c 802324a: 2300 movs r3, #0 802324c: 4699 mov r9, r3 802324e: f6cb 73e0 movt r3, #49120 ; 0xbfe0 8023252: f6c3 79e0 movt r9, #16352 ; 0x3fe0 8023256: 920c str r2, [sp, #48] ; 0x30 8023258: e5bf b.n 8022dda <_strtod_r+0x85a> 802325a: f8dd 9018 ldr.w r9, [sp, #24] 802325e: f8dd a01c ldr.w sl, [sp, #28] 8023262: e62a b.n 8022eba <_strtod_r+0x93a> 8023264: f04f 0900 mov.w r9, #0 8023268: 3601 adds r6, #1 802326a: 46ca mov sl, r9 802326c: 9617 str r6, [sp, #92] ; 0x5c 802326e: f7ff bad4 b.w 802281a <_strtod_r+0x29a> 8023272: 9c09 ldr r4, [sp, #36] ; 0x24 8023274: f1c8 0325 rsb r3, r8, #37 ; 0x25 8023278: 429c cmp r4, r3 802327a: f73f ab9d bgt.w 80229b8 <_strtod_r+0x438> 802327e: f1c8 080f rsb r8, r8, #15 8023282: f645 4418 movw r4, #23576 ; 0x5c18 8023286: f6c0 0403 movt r4, #2051 ; 0x803 802328a: e9dd 2306 ldrd r2, r3, [sp, #24] 802328e: eb04 01c8 add.w r1, r4, r8, lsl #3 8023292: e9d1 0100 ldrd r0, r1, [r1] 8023296: f7fd f993 bl 80205c0 <__aeabi_dmul> 802329a: 9d09 ldr r5, [sp, #36] ; 0x24 802329c: ebc8 0805 rsb r8, r8, r5 80232a0: eb04 04c8 add.w r4, r4, r8, lsl #3 80232a4: e9d4 2300 ldrd r2, r3, [r4] 80232a8: f7fd f98a bl 80205c0 <__aeabi_dmul> 80232ac: 4681 mov r9, r0 80232ae: 468a mov sl, r1 80232b0: f7ff bab3 b.w 802281a <_strtod_r+0x29a> 80232b4: 9907 ldr r1, [sp, #28] 80232b6: f3c1 0313 ubfx r3, r1, #0, #20 80232ba: 2b00 cmp r3, #0 80232bc: d141 bne.n 8023342 <_strtod_r+0xdc2> 80232be: 9b06 ldr r3, [sp, #24] 80232c0: 2b00 cmp r3, #0 80232c2: f43f aeeb beq.w 802309c <_strtod_r+0xb1c> 80232c6: 07da lsls r2, r3, #31 80232c8: f57f aefb bpl.w 80230c2 <_strtod_r+0xb42> 80232cc: 4648 mov r0, r9 80232ce: 4651 mov r1, sl 80232d0: f001 fd82 bl 8024dd8 <__ulp> 80232d4: 4602 mov r2, r0 80232d6: 460b mov r3, r1 80232d8: 4648 mov r0, r9 80232da: 4651 mov r1, sl 80232dc: f7fc ffbc bl 8020258 <__aeabi_dsub> 80232e0: 4602 mov r2, r0 80232e2: 460b mov r3, r1 80232e4: e9cd 2306 strd r2, r3, [sp, #24] 80232e8: 2200 movs r2, #0 80232ea: 2300 movs r3, #0 80232ec: f7fd fbd0 bl 8020a90 <__aeabi_dcmpeq> 80232f0: 2800 cmp r0, #0 80232f2: f47f adff bne.w 8022ef4 <_strtod_r+0x974> 80232f6: e6e4 b.n 80230c2 <_strtod_r+0xb42> 80232f8: 9d09 ldr r5, [sp, #36] ; 0x24 80232fa: 426d negs r5, r5 80232fc: 950d str r5, [sp, #52] ; 0x34 80232fe: f7ff bb8b b.w 8022a18 <_strtod_r+0x498> 8023302: 9c09 ldr r4, [sp, #36] ; 0x24 8023304: f114 0f16 cmn.w r4, #22 8023308: f6ff ab56 blt.w 80229b8 <_strtod_r+0x438> 802330c: f645 4318 movw r3, #23576 ; 0x5c18 8023310: e9dd 0106 ldrd r0, r1, [sp, #24] 8023314: f6c0 0303 movt r3, #2051 ; 0x803 8023318: eba3 03c4 sub.w r3, r3, r4, lsl #3 802331c: e9d3 2300 ldrd r2, r3, [r3] 8023320: f7fd fa78 bl 8020814 <__aeabi_ddiv> 8023324: 4681 mov r9, r0 8023326: 468a mov sl, r1 8023328: f7ff ba77 b.w 802281a <_strtod_r+0x29a> 802332c: 2000 movs r0, #0 802332e: f1b8 0f10 cmp.w r8, #16 8023332: f73f ae8e bgt.w 8023052 <_strtod_r+0xad2> 8023336: eb0a 0a8a add.w sl, sl, sl, lsl #2 802333a: 2000 movs r0, #0 802333c: eb01 0a4a add.w sl, r1, sl, lsl #1 8023340: e687 b.n 8023052 <_strtod_r+0xad2> 8023342: 9b06 ldr r3, [sp, #24] 8023344: e7bf b.n 80232c6 <_strtod_r+0xd46> 8023346: f101 7154 add.w r1, r1, #55574528 ; 0x3500000 802334a: 2400 movs r4, #0 802334c: 9107 str r1, [sp, #28] 802334e: 468a mov sl, r1 8023350: 940b str r4, [sp, #44] ; 0x2c 8023352: f8dd 9018 ldr.w r9, [sp, #24] 8023356: f7ff bb51 b.w 80229fc <_strtod_r+0x47c> 802335a: 9d0b ldr r5, [sp, #44] ; 0x2c 802335c: b1d5 cbz r5, 8023394 <_strtod_r+0xe14> 802335e: 2200 movs r2, #0 8023360: f6c7 72f0 movt r2, #32752 ; 0x7ff0 8023364: 401a ands r2, r3 8023366: f1b2 6fd4 cmp.w r2, #111149056 ; 0x6a00000 802336a: d813 bhi.n 8023394 <_strtod_r+0xe14> 802336c: 0d12 lsrs r2, r2, #20 802336e: f04f 30ff mov.w r0, #4294967295 8023372: f1c2 026b rsb r2, r2, #107 ; 0x6b 8023376: fa00 f202 lsl.w r2, r0, r2 802337a: 4291 cmp r1, r2 802337c: f47f aed4 bne.w 8023128 <_strtod_r+0xba8> 8023380: 2200 movs r2, #0 8023382: 2000 movs r0, #0 8023384: f6c7 72f0 movt r2, #32752 ; 0x7ff0 8023388: 9006 str r0, [sp, #24] 802338a: 401a ands r2, r3 802338c: f502 1280 add.w r2, r2, #1048576 ; 0x100000 8023390: 9207 str r2, [sp, #28] 8023392: e696 b.n 80230c2 <_strtod_r+0xb42> 8023394: f04f 32ff mov.w r2, #4294967295 8023398: e7ef b.n 802337a <_strtod_r+0xdfa> 802339a: 4c2a ldr r4, [pc, #168] ; (8023444 <_strtod_r+0xec4>) 802339c: 4611 mov r1, r2 802339e: 9217 str r2, [sp, #92] ; 0x5c 80233a0: f814 0f01 ldrb.w r0, [r4, #1]! 80233a4: 460b mov r3, r1 80233a6: b310 cbz r0, 80233ee <_strtod_r+0xe6e> 80233a8: 785b ldrb r3, [r3, #1] 80233aa: 3101 adds r1, #1 80233ac: 2b40 cmp r3, #64 ; 0x40 80233ae: dd02 ble.n 80233b6 <_strtod_r+0xe36> 80233b0: 2b5a cmp r3, #90 ; 0x5a 80233b2: bfd8 it le 80233b4: 3320 addle r3, #32 80233b6: 4283 cmp r3, r0 80233b8: d0f2 beq.n 80233a0 <_strtod_r+0xe20> 80233ba: 3201 adds r2, #1 80233bc: 9217 str r2, [sp, #92] ; 0x5c 80233be: 2500 movs r5, #0 80233c0: 9506 str r5, [sp, #24] 80233c2: 4628 mov r0, r5 80233c4: f6c7 70f0 movt r0, #32752 ; 0x7ff0 80233c8: 9007 str r0, [sp, #28] 80233ca: f7ff baa9 b.w 8022920 <_strtod_r+0x3a0> 80233ce: 9907 ldr r1, [sp, #28] 80233d0: f021 4300 bic.w r3, r1, #2147483648 ; 0x80000000 80233d4: 0d1b lsrs r3, r3, #20 80233d6: 051b lsls r3, r3, #20 80233d8: f1b3 6fd6 cmp.w r3, #112197632 ; 0x6b00000 80233dc: f63f ae67 bhi.w 80230ae <_strtod_r+0xb2e> 80233e0: f1b3 7f5c cmp.w r3, #57671680 ; 0x3700000 80233e4: f63f ae71 bhi.w 80230ca <_strtod_r+0xb4a> 80233e8: e584 b.n 8022ef4 <_strtod_r+0x974> 80233ea: 4643 mov r3, r8 80233ec: e627 b.n 802303e <_strtod_r+0xabe> 80233ee: 3101 adds r1, #1 80233f0: 9117 str r1, [sp, #92] ; 0x5c 80233f2: e7e4 b.n 80233be <_strtod_r+0xe3e> 80233f4: f04f 0900 mov.w r9, #0 80233f8: f6c0 0a03 movt sl, #2051 ; 0x803 80233fc: e47f b.n 8022cfe <_strtod_r+0x77e> 80233fe: a817 add r0, sp, #92 ; 0x5c 8023400: 4911 ldr r1, [pc, #68] ; (8023448 <_strtod_r+0xec8>) 8023402: aa1a add r2, sp, #104 ; 0x68 8023404: f000 fd7e bl 8023f04 <__hexnan> 8023408: 2805 cmp r0, #5 802340a: f47f aa83 bne.w 8022914 <_strtod_r+0x394> 802340e: 9b1b ldr r3, [sp, #108] ; 0x6c 8023410: 9a1a ldr r2, [sp, #104] ; 0x68 8023412: f043 43ff orr.w r3, r3, #2139095040 ; 0x7f800000 8023416: f443 03e0 orr.w r3, r3, #7340032 ; 0x700000 802341a: 9307 str r3, [sp, #28] 802341c: 9206 str r2, [sp, #24] 802341e: f7ff ba7f b.w 8022920 <_strtod_r+0x3a0> 8023422: f04f 32ff mov.w r2, #4294967295 8023426: 9c06 ldr r4, [sp, #24] 8023428: fa02 f303 lsl.w r3, r2, r3 802342c: 401c ands r4, r3 802342e: 9406 str r4, [sp, #24] 8023430: e6f5 b.n 802321e <_strtod_r+0xc9e> 8023432: f04f 31ff mov.w r1, #4294967295 8023436: 3b20 subs r3, #32 8023438: fa01 f303 lsl.w r3, r1, r3 802343c: 4013 ands r3, r2 802343e: 9307 str r3, [sp, #28] 8023440: e6ed b.n 802321e <_strtod_r+0xc9e> 8023442: bf00 nop 8023444: 080409ab .word 0x080409ab 8023448: 20000018 .word 0x20000018 0802344c : 802344c: f240 032c movw r3, #44 ; 0x2c 8023450: 460a mov r2, r1 8023452: f2c2 0300 movt r3, #8192 ; 0x2000 8023456: 4601 mov r1, r0 8023458: 6818 ldr r0, [r3, #0] 802345a: f7ff b891 b.w 8022580 <_strtod_r> 802345e: bf00 nop 08023460 : 8023460: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 8023464: f240 062c movw r6, #44 ; 0x2c 8023468: f2c2 0600 movt r6, #8192 ; 0x2000 802346c: 460a mov r2, r1 802346e: 4601 mov r1, r0 8023470: f04f 0801 mov.w r8, #1 8023474: 6830 ldr r0, [r6, #0] 8023476: f7ff f883 bl 8022580 <_strtod_r> 802347a: 460d mov r5, r1 802347c: 4604 mov r4, r0 802347e: f7fd fb61 bl 8020b44 <__aeabi_d2f> 8023482: 2100 movs r1, #0 8023484: 4607 mov r7, r0 8023486: f7fd fcff bl 8020e88 <__aeabi_fcmpeq> 802348a: b908 cbnz r0, 8023490 802348c: f04f 0800 mov.w r8, #0 8023490: 4620 mov r0, r4 8023492: 4629 mov r1, r5 8023494: 2200 movs r2, #0 8023496: 2300 movs r3, #0 8023498: f04f 0901 mov.w r9, #1 802349c: f7fd faf8 bl 8020a90 <__aeabi_dcmpeq> 80234a0: b108 cbz r0, 80234a6 80234a2: f04f 0900 mov.w r9, #0 80234a6: ea08 0809 and.w r8, r8, r9 80234aa: f018 0fff tst.w r8, #255 ; 0xff 80234ae: d116 bne.n 80234de 80234b0: f64f 71ff movw r1, #65535 ; 0xffff 80234b4: 4638 mov r0, r7 80234b6: f6c7 717f movt r1, #32639 ; 0x7f7f 80234ba: f7fd fd0d bl 8020ed8 <__aeabi_fcmpgt> 80234be: b9a0 cbnz r0, 80234ea 80234c0: 4638 mov r0, r7 80234c2: f46f 0100 mvn.w r1, #8388608 ; 0x800000 80234c6: f7fd fce9 bl 8020e9c <__aeabi_fcmplt> 80234ca: b158 cbz r0, 80234e4 80234cc: 4620 mov r0, r4 80234ce: 4629 mov r1, r5 80234d0: f04f 32ff mov.w r2, #4294967295 80234d4: f46f 1380 mvn.w r3, #1048576 ; 0x100000 80234d8: f7fd fae4 bl 8020aa4 <__aeabi_dcmplt> 80234dc: b910 cbnz r0, 80234e4 80234de: 6833 ldr r3, [r6, #0] 80234e0: 2222 movs r2, #34 ; 0x22 80234e2: 601a str r2, [r3, #0] 80234e4: 4638 mov r0, r7 80234e6: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 80234ea: f64f 73ff movw r3, #65535 ; 0xffff 80234ee: 4620 mov r0, r4 80234f0: 4629 mov r1, r5 80234f2: f04f 32ff mov.w r2, #4294967295 80234f6: f6c7 73ef movt r3, #32751 ; 0x7fef 80234fa: f7fd faf1 bl 8020ae0 <__aeabi_dcmpgt> 80234fe: 2800 cmp r0, #0 8023500: d0ed beq.n 80234de 8023502: e7dd b.n 80234c0 8023504: f3af 8000 nop.w 08023508 <_strtol_r>: 8023508: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 802350c: f240 0400 movw r4, #0 8023510: f2c2 0400 movt r4, #8192 ; 0x2000 8023514: b085 sub sp, #20 8023516: 4699 mov r9, r3 8023518: 460b mov r3, r1 802351a: f8d4 8000 ldr.w r8, [r4] 802351e: 9102 str r1, [sp, #8] 8023520: 9003 str r0, [sp, #12] 8023522: 461c mov r4, r3 8023524: f814 5b01 ldrb.w r5, [r4], #1 8023528: eb08 0105 add.w r1, r8, r5 802352c: 4623 mov r3, r4 802352e: 7849 ldrb r1, [r1, #1] 8023530: f001 0108 and.w r1, r1, #8 8023534: b2c9 uxtb r1, r1 8023536: 2900 cmp r1, #0 8023538: d1f3 bne.n 8023522 <_strtol_r+0x1a> 802353a: 2d2d cmp r5, #45 ; 0x2d 802353c: d07b beq.n 8023636 <_strtol_r+0x12e> 802353e: 2d2b cmp r5, #43 ; 0x2b 8023540: bf05 ittet eq 8023542: 4624 moveq r4, r4 8023544: 460b moveq r3, r1 8023546: 460b movne r3, r1 8023548: f814 5b01 ldrbeq.w r5, [r4], #1 802354c: f039 0110 bics.w r1, r9, #16 8023550: d112 bne.n 8023578 <_strtol_r+0x70> 8023552: f1d9 0001 rsbs r0, r9, #1 8023556: bf38 it cc 8023558: 2000 movcc r0, #0 802355a: 2d30 cmp r5, #48 ; 0x30 802355c: d004 beq.n 8023568 <_strtol_r+0x60> 802355e: b158 cbz r0, 8023578 <_strtol_r+0x70> 8023560: f04f 090a mov.w r9, #10 8023564: 46cb mov fp, r9 8023566: e008 b.n 802357a <_strtol_r+0x72> 8023568: 7821 ldrb r1, [r4, #0] 802356a: f001 01df and.w r1, r1, #223 ; 0xdf 802356e: 2958 cmp r1, #88 ; 0x58 8023570: d065 beq.n 802363e <_strtol_r+0x136> 8023572: b108 cbz r0, 8023578 <_strtol_r+0x70> 8023574: f04f 0908 mov.w r9, #8 8023578: 46cb mov fp, r9 802357a: 2b00 cmp r3, #0 802357c: 4659 mov r1, fp 802357e: bf0c ite eq 8023580: f06f 4600 mvneq.w r6, #2147483648 ; 0x80000000 8023584: f04f 4600 movne.w r6, #2147483648 ; 0x80000000 8023588: e88d 000c stmia.w sp, {r2, r3} 802358c: 4630 mov r0, r6 802358e: 2700 movs r7, #0 8023590: f7fe f964 bl 802185c <__aeabi_uidivmod> 8023594: 4630 mov r0, r6 8023596: 468a mov sl, r1 8023598: 4659 mov r1, fp 802359a: f7fe f831 bl 8021600 <__aeabi_uidiv> 802359e: 46bc mov ip, r7 80235a0: e89d 000c ldmia.w sp, {r2, r3} 80235a4: e016 b.n 80235d4 <_strtol_r+0xcc> 80235a6: 3d30 subs r5, #48 ; 0x30 80235a8: 45a9 cmp r9, r5 80235aa: dd25 ble.n 80235f8 <_strtol_r+0xf0> 80235ac: 4584 cmp ip, r0 80235ae: bf94 ite ls 80235b0: 2100 movls r1, #0 80235b2: 2101 movhi r1, #1 80235b4: ea51 77d7 orrs.w r7, r1, r7, lsr #31 80235b8: d129 bne.n 802360e <_strtol_r+0x106> 80235ba: 4555 cmp r5, sl 80235bc: bfd4 ite le 80235be: 2100 movle r1, #0 80235c0: 2101 movgt r1, #1 80235c2: 4584 cmp ip, r0 80235c4: bf18 it ne 80235c6: 2100 movne r1, #0 80235c8: bb09 cbnz r1, 802360e <_strtol_r+0x106> 80235ca: fb0b 5c0c mla ip, fp, ip, r5 80235ce: 2701 movs r7, #1 80235d0: f814 5b01 ldrb.w r5, [r4], #1 80235d4: eb08 0105 add.w r1, r8, r5 80235d8: 7849 ldrb r1, [r1, #1] 80235da: f001 0604 and.w r6, r1, #4 80235de: b2f6 uxtb r6, r6 80235e0: 2e00 cmp r6, #0 80235e2: d1e0 bne.n 80235a6 <_strtol_r+0x9e> 80235e4: f011 0103 ands.w r1, r1, #3 80235e8: d006 beq.n 80235f8 <_strtol_r+0xf0> 80235ea: 2901 cmp r1, #1 80235ec: bf14 ite ne 80235ee: 2157 movne r1, #87 ; 0x57 80235f0: 2137 moveq r1, #55 ; 0x37 80235f2: 1a6d subs r5, r5, r1 80235f4: 45a9 cmp r9, r5 80235f6: dcd9 bgt.n 80235ac <_strtol_r+0xa4> 80235f8: 1c79 adds r1, r7, #1 80235fa: d00b beq.n 8023614 <_strtol_r+0x10c> 80235fc: b9c3 cbnz r3, 8023630 <_strtol_r+0x128> 80235fe: 4660 mov r0, ip 8023600: b112 cbz r2, 8023608 <_strtol_r+0x100> 8023602: b997 cbnz r7, 802362a <_strtol_r+0x122> 8023604: 9b02 ldr r3, [sp, #8] 8023606: 6013 str r3, [r2, #0] 8023608: b005 add sp, #20 802360a: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802360e: f04f 37ff mov.w r7, #4294967295 8023612: e7dd b.n 80235d0 <_strtol_r+0xc8> 8023614: 9903 ldr r1, [sp, #12] 8023616: 2b00 cmp r3, #0 8023618: bf0c ite eq 802361a: f06f 4000 mvneq.w r0, #2147483648 ; 0x80000000 802361e: f04f 4000 movne.w r0, #2147483648 ; 0x80000000 8023622: 2322 movs r3, #34 ; 0x22 8023624: 600b str r3, [r1, #0] 8023626: 2a00 cmp r2, #0 8023628: d0ee beq.n 8023608 <_strtol_r+0x100> 802362a: 3c01 subs r4, #1 802362c: 9402 str r4, [sp, #8] 802362e: e7e9 b.n 8023604 <_strtol_r+0xfc> 8023630: f1cc 0c00 rsb ip, ip, #0 8023634: e7e3 b.n 80235fe <_strtol_r+0xf6> 8023636: f814 5b01 ldrb.w r5, [r4], #1 802363a: 2301 movs r3, #1 802363c: e786 b.n 802354c <_strtol_r+0x44> 802363e: f04f 0910 mov.w r9, #16 8023642: 7865 ldrb r5, [r4, #1] 8023644: 46cb mov fp, r9 8023646: 3402 adds r4, #2 8023648: e797 b.n 802357a <_strtol_r+0x72> 802364a: bf00 nop 0802364c : 802364c: b430 push {r4, r5} 802364e: f240 042c movw r4, #44 ; 0x2c 8023652: f2c2 0400 movt r4, #8192 ; 0x2000 8023656: 460d mov r5, r1 8023658: 4613 mov r3, r2 802365a: 4601 mov r1, r0 802365c: 462a mov r2, r5 802365e: 6820 ldr r0, [r4, #0] 8023660: bc30 pop {r4, r5} 8023662: f7ff bf51 b.w 8023508 <_strtol_r> 8023666: bf00 nop 08023668 <_malloc_trim_r>: 8023668: b5f8 push {r3, r4, r5, r6, r7, lr} 802366a: f240 149c movw r4, #412 ; 0x19c 802366e: f2c2 0400 movt r4, #8192 ; 0x2000 8023672: 460f mov r7, r1 8023674: 4605 mov r5, r0 8023676: f001 f895 bl 80247a4 <__malloc_lock> 802367a: 68a3 ldr r3, [r4, #8] 802367c: 685e ldr r6, [r3, #4] 802367e: f026 0603 bic.w r6, r6, #3 8023682: f606 73ef addw r3, r6, #4079 ; 0xfef 8023686: 1bdf subs r7, r3, r7 8023688: 0b3f lsrs r7, r7, #12 802368a: 3f01 subs r7, #1 802368c: 033f lsls r7, r7, #12 802368e: f5b7 5f80 cmp.w r7, #4096 ; 0x1000 8023692: db07 blt.n 80236a4 <_malloc_trim_r+0x3c> 8023694: 2100 movs r1, #0 8023696: 4628 mov r0, r5 8023698: f001 fd10 bl 80250bc <_sbrk_r> 802369c: 68a3 ldr r3, [r4, #8] 802369e: 199b adds r3, r3, r6 80236a0: 4298 cmp r0, r3 80236a2: d004 beq.n 80236ae <_malloc_trim_r+0x46> 80236a4: 4628 mov r0, r5 80236a6: f001 f87f bl 80247a8 <__malloc_unlock> 80236aa: 2000 movs r0, #0 80236ac: bdf8 pop {r3, r4, r5, r6, r7, pc} 80236ae: 4279 negs r1, r7 80236b0: 4628 mov r0, r5 80236b2: f001 fd03 bl 80250bc <_sbrk_r> 80236b6: 3001 adds r0, #1 80236b8: d010 beq.n 80236dc <_malloc_trim_r+0x74> 80236ba: f641 1320 movw r3, #6432 ; 0x1920 80236be: 68a1 ldr r1, [r4, #8] 80236c0: f2c2 0300 movt r3, #8192 ; 0x2000 80236c4: 1bf6 subs r6, r6, r7 80236c6: 4628 mov r0, r5 80236c8: f046 0601 orr.w r6, r6, #1 80236cc: 681a ldr r2, [r3, #0] 80236ce: 604e str r6, [r1, #4] 80236d0: 1bd7 subs r7, r2, r7 80236d2: 601f str r7, [r3, #0] 80236d4: f001 f868 bl 80247a8 <__malloc_unlock> 80236d8: 2001 movs r0, #1 80236da: bdf8 pop {r3, r4, r5, r6, r7, pc} 80236dc: 2100 movs r1, #0 80236de: 4628 mov r0, r5 80236e0: f001 fcec bl 80250bc <_sbrk_r> 80236e4: 68a3 ldr r3, [r4, #8] 80236e6: 1ac2 subs r2, r0, r3 80236e8: 2a0f cmp r2, #15 80236ea: dddb ble.n 80236a4 <_malloc_trim_r+0x3c> 80236ec: f240 54a4 movw r4, #1444 ; 0x5a4 80236f0: f641 1120 movw r1, #6432 ; 0x1920 80236f4: f2c2 0400 movt r4, #8192 ; 0x2000 80236f8: f2c2 0100 movt r1, #8192 ; 0x2000 80236fc: f042 0201 orr.w r2, r2, #1 8023700: 605a str r2, [r3, #4] 8023702: 6823 ldr r3, [r4, #0] 8023704: 1ac0 subs r0, r0, r3 8023706: 6008 str r0, [r1, #0] 8023708: e7cc b.n 80236a4 <_malloc_trim_r+0x3c> 802370a: bf00 nop 0802370c <_free_r>: 802370c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8023710: 460e mov r6, r1 8023712: 4680 mov r8, r0 8023714: 2900 cmp r1, #0 8023716: d05c beq.n 80237d2 <_free_r+0xc6> 8023718: f001 f844 bl 80247a4 <__malloc_lock> 802371c: f240 159c movw r5, #412 ; 0x19c 8023720: f856 1c04 ldr.w r1, [r6, #-4] 8023724: f2c2 0500 movt r5, #8192 ; 0x2000 8023728: f1a6 0408 sub.w r4, r6, #8 802372c: f021 0301 bic.w r3, r1, #1 8023730: 68af ldr r7, [r5, #8] 8023732: 18e2 adds r2, r4, r3 8023734: 4297 cmp r7, r2 8023736: 6850 ldr r0, [r2, #4] 8023738: f020 0003 bic.w r0, r0, #3 802373c: d067 beq.n 802380e <_free_r+0x102> 802373e: f011 0101 ands.w r1, r1, #1 8023742: 6050 str r0, [r2, #4] 8023744: d035 beq.n 80237b2 <_free_r+0xa6> 8023746: 2100 movs r1, #0 8023748: 1816 adds r6, r2, r0 802374a: 6876 ldr r6, [r6, #4] 802374c: f016 0f01 tst.w r6, #1 8023750: d106 bne.n 8023760 <_free_r+0x54> 8023752: 181b adds r3, r3, r0 8023754: 6890 ldr r0, [r2, #8] 8023756: 2900 cmp r1, #0 8023758: d04d beq.n 80237f6 <_free_r+0xea> 802375a: 68d2 ldr r2, [r2, #12] 802375c: 60c2 str r2, [r0, #12] 802375e: 6090 str r0, [r2, #8] 8023760: f043 0201 orr.w r2, r3, #1 8023764: 50e3 str r3, [r4, r3] 8023766: 6062 str r2, [r4, #4] 8023768: b9f1 cbnz r1, 80237a8 <_free_r+0x9c> 802376a: f5b3 7f00 cmp.w r3, #512 ; 0x200 802376e: d332 bcc.n 80237d6 <_free_r+0xca> 8023770: 0a5a lsrs r2, r3, #9 8023772: 2a04 cmp r2, #4 8023774: d86c bhi.n 8023850 <_free_r+0x144> 8023776: 0998 lsrs r0, r3, #6 8023778: 3038 adds r0, #56 ; 0x38 802377a: 0041 lsls r1, r0, #1 802377c: eb05 0581 add.w r5, r5, r1, lsl #2 8023780: f240 119c movw r1, #412 ; 0x19c 8023784: f2c2 0100 movt r1, #8192 ; 0x2000 8023788: 68aa ldr r2, [r5, #8] 802378a: 42aa cmp r2, r5 802378c: d06b beq.n 8023866 <_free_r+0x15a> 802378e: 6851 ldr r1, [r2, #4] 8023790: f021 0103 bic.w r1, r1, #3 8023794: 428b cmp r3, r1 8023796: d202 bcs.n 802379e <_free_r+0x92> 8023798: 6892 ldr r2, [r2, #8] 802379a: 4295 cmp r5, r2 802379c: d1f7 bne.n 802378e <_free_r+0x82> 802379e: 68d3 ldr r3, [r2, #12] 80237a0: 60e3 str r3, [r4, #12] 80237a2: 60a2 str r2, [r4, #8] 80237a4: 60d4 str r4, [r2, #12] 80237a6: 609c str r4, [r3, #8] 80237a8: 4640 mov r0, r8 80237aa: e8bd 41f0 ldmia.w sp!, {r4, r5, r6, r7, r8, lr} 80237ae: f000 bffb b.w 80247a8 <__malloc_unlock> 80237b2: f856 6c08 ldr.w r6, [r6, #-8] 80237b6: f105 0c08 add.w ip, r5, #8 80237ba: 1ba4 subs r4, r4, r6 80237bc: 199b adds r3, r3, r6 80237be: 68a6 ldr r6, [r4, #8] 80237c0: 4566 cmp r6, ip 80237c2: d043 beq.n 802384c <_free_r+0x140> 80237c4: f8d4 c00c ldr.w ip, [r4, #12] 80237c8: f8c6 c00c str.w ip, [r6, #12] 80237cc: f8cc 6008 str.w r6, [ip, #8] 80237d0: e7ba b.n 8023748 <_free_r+0x3c> 80237d2: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 80237d6: 08db lsrs r3, r3, #3 80237d8: 2101 movs r1, #1 80237da: 6868 ldr r0, [r5, #4] 80237dc: eb05 02c3 add.w r2, r5, r3, lsl #3 80237e0: 109b asrs r3, r3, #2 80237e2: fa01 f303 lsl.w r3, r1, r3 80237e6: 60e2 str r2, [r4, #12] 80237e8: 6891 ldr r1, [r2, #8] 80237ea: 4318 orrs r0, r3 80237ec: 6068 str r0, [r5, #4] 80237ee: 60a1 str r1, [r4, #8] 80237f0: 60cc str r4, [r1, #12] 80237f2: 6094 str r4, [r2, #8] 80237f4: e7d8 b.n 80237a8 <_free_r+0x9c> 80237f6: 4e29 ldr r6, [pc, #164] ; (802389c <_free_r+0x190>) 80237f8: 42b0 cmp r0, r6 80237fa: d1ae bne.n 802375a <_free_r+0x4e> 80237fc: 616c str r4, [r5, #20] 80237fe: f043 0201 orr.w r2, r3, #1 8023802: 612c str r4, [r5, #16] 8023804: 60e0 str r0, [r4, #12] 8023806: 60a0 str r0, [r4, #8] 8023808: 6062 str r2, [r4, #4] 802380a: 50e3 str r3, [r4, r3] 802380c: e7cc b.n 80237a8 <_free_r+0x9c> 802380e: 18c0 adds r0, r0, r3 8023810: 07cb lsls r3, r1, #31 8023812: d407 bmi.n 8023824 <_free_r+0x118> 8023814: f856 3c08 ldr.w r3, [r6, #-8] 8023818: 1ae4 subs r4, r4, r3 802381a: 18c0 adds r0, r0, r3 802381c: 68a2 ldr r2, [r4, #8] 802381e: 68e3 ldr r3, [r4, #12] 8023820: 60d3 str r3, [r2, #12] 8023822: 609a str r2, [r3, #8] 8023824: f240 52a8 movw r2, #1448 ; 0x5a8 8023828: f040 0301 orr.w r3, r0, #1 802382c: f2c2 0200 movt r2, #8192 ; 0x2000 8023830: 6063 str r3, [r4, #4] 8023832: 60ac str r4, [r5, #8] 8023834: 6813 ldr r3, [r2, #0] 8023836: 4298 cmp r0, r3 8023838: d3b6 bcc.n 80237a8 <_free_r+0x9c> 802383a: f641 131c movw r3, #6428 ; 0x191c 802383e: 4640 mov r0, r8 8023840: f2c2 0300 movt r3, #8192 ; 0x2000 8023844: 6819 ldr r1, [r3, #0] 8023846: f7ff ff0f bl 8023668 <_malloc_trim_r> 802384a: e7ad b.n 80237a8 <_free_r+0x9c> 802384c: 2101 movs r1, #1 802384e: e77b b.n 8023748 <_free_r+0x3c> 8023850: f102 005b add.w r0, r2, #91 ; 0x5b 8023854: 0041 lsls r1, r0, #1 8023856: 2a14 cmp r2, #20 8023858: d990 bls.n 802377c <_free_r+0x70> 802385a: 2a54 cmp r2, #84 ; 0x54 802385c: d80c bhi.n 8023878 <_free_r+0x16c> 802385e: 0b18 lsrs r0, r3, #12 8023860: 306e adds r0, #110 ; 0x6e 8023862: 0041 lsls r1, r0, #1 8023864: e78a b.n 802377c <_free_r+0x70> 8023866: 2601 movs r6, #1 8023868: 684d ldr r5, [r1, #4] 802386a: 1080 asrs r0, r0, #2 802386c: 4613 mov r3, r2 802386e: fa06 f000 lsl.w r0, r6, r0 8023872: 4305 orrs r5, r0 8023874: 604d str r5, [r1, #4] 8023876: e793 b.n 80237a0 <_free_r+0x94> 8023878: f5b2 7faa cmp.w r2, #340 ; 0x154 802387c: d803 bhi.n 8023886 <_free_r+0x17a> 802387e: 0bd8 lsrs r0, r3, #15 8023880: 3077 adds r0, #119 ; 0x77 8023882: 0041 lsls r1, r0, #1 8023884: e77a b.n 802377c <_free_r+0x70> 8023886: f240 5154 movw r1, #1364 ; 0x554 802388a: 428a cmp r2, r1 802388c: d803 bhi.n 8023896 <_free_r+0x18a> 802388e: 0c98 lsrs r0, r3, #18 8023890: 307c adds r0, #124 ; 0x7c 8023892: 0041 lsls r1, r0, #1 8023894: e772 b.n 802377c <_free_r+0x70> 8023896: 21fc movs r1, #252 ; 0xfc 8023898: 207e movs r0, #126 ; 0x7e 802389a: e76f b.n 802377c <_free_r+0x70> 802389c: 200001a4 .word 0x200001a4 080238a0 : 80238a0: 6902 ldr r2, [r0, #16] 80238a2: 114b asrs r3, r1, #5 80238a4: e92d 01f0 stmdb sp!, {r4, r5, r6, r7, r8} 80238a8: 4293 cmp r3, r2 80238aa: f100 0714 add.w r7, r0, #20 80238ae: da2d bge.n 802390c 80238b0: 3304 adds r3, #4 80238b2: eb00 0282 add.w r2, r0, r2, lsl #2 80238b6: 3214 adds r2, #20 80238b8: f011 011f ands.w r1, r1, #31 80238bc: eb00 0383 add.w r3, r0, r3, lsl #2 80238c0: f103 0c04 add.w ip, r3, #4 80238c4: d029 beq.n 802391a 80238c6: 685c ldr r4, [r3, #4] 80238c8: f10c 0304 add.w r3, ip, #4 80238cc: 429a cmp r2, r3 80238ce: f1c1 0820 rsb r8, r1, #32 80238d2: fa24 f401 lsr.w r4, r4, r1 80238d6: d938 bls.n 802394a 80238d8: 463d mov r5, r7 80238da: 681e ldr r6, [r3, #0] 80238dc: fa06 f608 lsl.w r6, r6, r8 80238e0: 4334 orrs r4, r6 80238e2: f845 4b04 str.w r4, [r5], #4 80238e6: f853 4b04 ldr.w r4, [r3], #4 80238ea: 429a cmp r2, r3 80238ec: fa24 f401 lsr.w r4, r4, r1 80238f0: d8f3 bhi.n 80238da 80238f2: ebcc 0302 rsb r3, ip, r2 80238f6: 3b05 subs r3, #5 80238f8: f023 0303 bic.w r3, r3, #3 80238fc: 18c3 adds r3, r0, r3 80238fe: 3318 adds r3, #24 8023900: 601c str r4, [r3, #0] 8023902: b1e4 cbz r4, 802393e 8023904: 3304 adds r3, #4 8023906: 1bdf subs r7, r3, r7 8023908: 10bf asrs r7, r7, #2 802390a: e01a b.n 8023942 802390c: 2300 movs r3, #0 802390e: 6103 str r3, [r0, #16] 8023910: 2300 movs r3, #0 8023912: 6143 str r3, [r0, #20] 8023914: e8bd 01f0 ldmia.w sp!, {r4, r5, r6, r7, r8} 8023918: 4770 bx lr 802391a: 4562 cmp r2, ip 802391c: bf84 itt hi 802391e: 4663 movhi r3, ip 8023920: 4639 movhi r1, r7 8023922: d9f3 bls.n 802390c 8023924: f853 4b04 ldr.w r4, [r3], #4 8023928: 429a cmp r2, r3 802392a: f841 4b04 str.w r4, [r1], #4 802392e: d8f9 bhi.n 8023924 8023930: ea6f 030c mvn.w r3, ip 8023934: 189b adds r3, r3, r2 8023936: f023 0303 bic.w r3, r3, #3 802393a: 18c3 adds r3, r0, r3 802393c: 3318 adds r3, #24 802393e: 1bdf subs r7, r3, r7 8023940: 10bf asrs r7, r7, #2 8023942: 6107 str r7, [r0, #16] 8023944: 2f00 cmp r7, #0 8023946: d1e5 bne.n 8023914 8023948: e7e2 b.n 8023910 802394a: 463b mov r3, r7 802394c: e7d8 b.n 8023900 802394e: bf00 nop 08023950 <__hexdig_init>: 8023950: f640 10c8 movw r0, #2504 ; 0x9c8 8023954: f245 133c movw r3, #20796 ; 0x513c 8023958: f6c0 0004 movt r0, #2052 ; 0x804 802395c: 2110 movs r1, #16 802395e: 2230 movs r2, #48 ; 0x30 8023960: f2c2 0301 movt r3, #8193 ; 0x2001 8023964: 5499 strb r1, [r3, r2] 8023966: 3101 adds r1, #1 8023968: f810 2f01 ldrb.w r2, [r0, #1]! 802396c: b2c9 uxtb r1, r1 802396e: 2a00 cmp r2, #0 8023970: d1f8 bne.n 8023964 <__hexdig_init+0x14> 8023972: f640 10c0 movw r0, #2496 ; 0x9c0 8023976: 211a movs r1, #26 8023978: f6c0 0004 movt r0, #2052 ; 0x804 802397c: 2261 movs r2, #97 ; 0x61 802397e: 5499 strb r1, [r3, r2] 8023980: 3101 adds r1, #1 8023982: f810 2f01 ldrb.w r2, [r0, #1]! 8023986: b2c9 uxtb r1, r1 8023988: 2a00 cmp r2, #0 802398a: d1f8 bne.n 802397e <__hexdig_init+0x2e> 802398c: f640 10b8 movw r0, #2488 ; 0x9b8 8023990: 211a movs r1, #26 8023992: f6c0 0004 movt r0, #2052 ; 0x804 8023996: 2241 movs r2, #65 ; 0x41 8023998: 5499 strb r1, [r3, r2] 802399a: 3101 adds r1, #1 802399c: f810 2f01 ldrb.w r2, [r0, #1]! 80239a0: b2c9 uxtb r1, r1 80239a2: 2a00 cmp r2, #0 80239a4: d1f8 bne.n 8023998 <__hexdig_init+0x48> 80239a6: 4770 bx lr 080239a8 <__gethex>: 80239a8: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 80239ac: b08b sub sp, #44 ; 0x2c 80239ae: 4688 mov r8, r1 80239b0: f245 163c movw r6, #20796 ; 0x513c 80239b4: 9206 str r2, [sp, #24] 80239b6: f2c2 0601 movt r6, #8193 ; 0x2001 80239ba: 9309 str r3, [sp, #36] ; 0x24 80239bc: 9007 str r0, [sp, #28] 80239be: f000 fbb9 bl 8024134 <_localeconv_r> 80239c2: 6800 ldr r0, [r0, #0] 80239c4: 9002 str r0, [sp, #8] 80239c6: f7fe fa53 bl 8021e70 80239ca: 9b02 ldr r3, [sp, #8] 80239cc: 181a adds r2, r3, r0 80239ce: f896 3030 ldrb.w r3, [r6, #48] ; 0x30 80239d2: 9003 str r0, [sp, #12] 80239d4: f812 ac01 ldrb.w sl, [r2, #-1] 80239d8: 2b00 cmp r3, #0 80239da: f000 810e beq.w 8023bfa <__gethex+0x252> 80239de: f8d8 3000 ldr.w r3, [r8] 80239e2: 1c9d adds r5, r3, #2 80239e4: 789a ldrb r2, [r3, #2] 80239e6: 2a30 cmp r2, #48 ; 0x30 80239e8: f040 8200 bne.w 8023dec <__gethex+0x444> 80239ec: 3303 adds r3, #3 80239ee: 2700 movs r7, #0 80239f0: 461d mov r5, r3 80239f2: f813 2b01 ldrb.w r2, [r3], #1 80239f6: 3701 adds r7, #1 80239f8: 2a30 cmp r2, #48 ; 0x30 80239fa: d0f9 beq.n 80239f0 <__gethex+0x48> 80239fc: f816 b002 ldrb.w fp, [r6, r2] 8023a00: f245 193c movw r9, #20796 ; 0x513c 8023a04: f2c2 0901 movt r9, #8193 ; 0x2001 8023a08: f1bb 0f00 cmp.w fp, #0 8023a0c: f000 80f8 beq.w 8023c00 <__gethex+0x258> 8023a10: 782b ldrb r3, [r5, #0] 8023a12: f04f 0b00 mov.w fp, #0 8023a16: f819 4003 ldrb.w r4, [r9, r3] 8023a1a: 2c00 cmp r4, #0 8023a1c: f000 8200 beq.w 8023e20 <__gethex+0x478> 8023a20: 1c6a adds r2, r5, #1 8023a22: 4614 mov r4, r2 8023a24: 3201 adds r2, #1 8023a26: 7823 ldrb r3, [r4, #0] 8023a28: 5cf3 ldrb r3, [r6, r3] 8023a2a: 2b00 cmp r3, #0 8023a2c: d1f9 bne.n 8023a22 <__gethex+0x7a> 8023a2e: 4699 mov r9, r3 8023a30: 4620 mov r0, r4 8023a32: 9902 ldr r1, [sp, #8] 8023a34: 9a03 ldr r2, [sp, #12] 8023a36: f7fe fa7d bl 8021f34 8023a3a: b1e8 cbz r0, 8023a78 <__gethex+0xd0> 8023a3c: 7823 ldrb r3, [r4, #0] 8023a3e: f1bb 0f00 cmp.w fp, #0 8023a42: f000 81c1 beq.w 8023dc8 <__gethex+0x420> 8023a46: ebc4 0b0b rsb fp, r4, fp 8023a4a: ea4f 028b mov.w r2, fp, lsl #2 8023a4e: 9205 str r2, [sp, #20] 8023a50: 2b50 cmp r3, #80 ; 0x50 8023a52: f000 809b beq.w 8023b8c <__gethex+0x1e4> 8023a56: 2b70 cmp r3, #112 ; 0x70 8023a58: f000 8098 beq.w 8023b8c <__gethex+0x1e4> 8023a5c: 4622 mov r2, r4 8023a5e: f8c8 2000 str.w r2, [r8] 8023a62: f1b9 0f00 cmp.w r9, #0 8023a66: d00d beq.n 8023a84 <__gethex+0xdc> 8023a68: 2f00 cmp r7, #0 8023a6a: bf0c ite eq 8023a6c: 2706 moveq r7, #6 8023a6e: 2700 movne r7, #0 8023a70: 4638 mov r0, r7 8023a72: b00b add sp, #44 ; 0x2c 8023a74: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 8023a78: f1bb 0f00 cmp.w fp, #0 8023a7c: f000 81be beq.w 8023dfc <__gethex+0x454> 8023a80: 7823 ldrb r3, [r4, #0] 8023a82: e7e0 b.n 8023a46 <__gethex+0x9e> 8023a84: 1b63 subs r3, r4, r5 8023a86: 4649 mov r1, r9 8023a88: 3b01 subs r3, #1 8023a8a: 2b07 cmp r3, #7 8023a8c: dd03 ble.n 8023a96 <__gethex+0xee> 8023a8e: 105b asrs r3, r3, #1 8023a90: 3101 adds r1, #1 8023a92: 2b07 cmp r3, #7 8023a94: dcfb bgt.n 8023a8e <__gethex+0xe6> 8023a96: 9807 ldr r0, [sp, #28] 8023a98: f000 fe88 bl 80247ac <_Balloc> 8023a9c: 42a5 cmp r5, r4 8023a9e: f100 0314 add.w r3, r0, #20 8023aa2: 9004 str r0, [sp, #16] 8023aa4: 9308 str r3, [sp, #32] 8023aa6: f080 81db bcs.w 8023e60 <__gethex+0x4b8> 8023aaa: 469b mov fp, r3 8023aac: 9b03 ldr r3, [sp, #12] 8023aae: f04f 0800 mov.w r8, #0 8023ab2: 4647 mov r7, r8 8023ab4: f1c3 0c01 rsb ip, r3, #1 8023ab8: e00f b.n 8023ada <__gethex+0x132> 8023aba: 2f20 cmp r7, #32 8023abc: d05f beq.n 8023b7e <__gethex+0x1d6> 8023abe: 463a mov r2, r7 8023ac0: 3704 adds r7, #4 8023ac2: f814 3c01 ldrb.w r3, [r4, #-1] 8023ac6: 464c mov r4, r9 8023ac8: 42a5 cmp r5, r4 8023aca: 5cf3 ldrb r3, [r6, r3] 8023acc: f003 030f and.w r3, r3, #15 8023ad0: fa03 f302 lsl.w r3, r3, r2 8023ad4: ea48 0803 orr.w r8, r8, r3 8023ad8: d219 bcs.n 8023b0e <__gethex+0x166> 8023ada: f814 3c01 ldrb.w r3, [r4, #-1] 8023ade: f104 39ff add.w r9, r4, #4294967295 8023ae2: 4553 cmp r3, sl 8023ae4: d1e9 bne.n 8023aba <__gethex+0x112> 8023ae6: eb09 030c add.w r3, r9, ip 8023aea: 429d cmp r5, r3 8023aec: d8e5 bhi.n 8023aba <__gethex+0x112> 8023aee: 4618 mov r0, r3 8023af0: 9902 ldr r1, [sp, #8] 8023af2: 9a03 ldr r2, [sp, #12] 8023af4: 9301 str r3, [sp, #4] 8023af6: f8cd c000 str.w ip, [sp] 8023afa: f7fe fa1b bl 8021f34 8023afe: 9b01 ldr r3, [sp, #4] 8023b00: f8dd c000 ldr.w ip, [sp] 8023b04: 2800 cmp r0, #0 8023b06: d1d8 bne.n 8023aba <__gethex+0x112> 8023b08: 461c mov r4, r3 8023b0a: 42a5 cmp r5, r4 8023b0c: d3e5 bcc.n 8023ada <__gethex+0x132> 8023b0e: 9b08 ldr r3, [sp, #32] 8023b10: 4640 mov r0, r8 8023b12: f84b 8b04 str.w r8, [fp], #4 8023b16: 9904 ldr r1, [sp, #16] 8023b18: ebc3 0b0b rsb fp, r3, fp 8023b1c: ea4f 03ab mov.w r3, fp, asr #2 8023b20: 610b str r3, [r1, #16] 8023b22: 015d lsls r5, r3, #5 8023b24: f000 ff24 bl 8024970 <__hi0bits> 8023b28: 9a06 ldr r2, [sp, #24] 8023b2a: 6814 ldr r4, [r2, #0] 8023b2c: 1a28 subs r0, r5, r0 8023b2e: 42a0 cmp r0, r4 8023b30: f300 8125 bgt.w 8023d7e <__gethex+0x3d6> 8023b34: f2c0 814b blt.w 8023dce <__gethex+0x426> 8023b38: 2500 movs r5, #0 8023b3a: 9806 ldr r0, [sp, #24] 8023b3c: 9905 ldr r1, [sp, #20] 8023b3e: 6883 ldr r3, [r0, #8] 8023b40: 4299 cmp r1, r3 8023b42: f300 80f6 bgt.w 8023d32 <__gethex+0x38a> 8023b46: 9806 ldr r0, [sp, #24] 8023b48: 9905 ldr r1, [sp, #20] 8023b4a: 6843 ldr r3, [r0, #4] 8023b4c: 4299 cmp r1, r3 8023b4e: f280 8100 bge.w 8023d52 <__gethex+0x3aa> 8023b52: 1a5e subs r6, r3, r1 8023b54: 42b4 cmp r4, r6 8023b56: dc76 bgt.n 8023c46 <__gethex+0x29e> 8023b58: 68c2 ldr r2, [r0, #12] 8023b5a: 2a02 cmp r2, #2 8023b5c: f000 816f beq.w 8023e3e <__gethex+0x496> 8023b60: 2a03 cmp r2, #3 8023b62: f000 8198 beq.w 8023e96 <__gethex+0x4ee> 8023b66: 2a01 cmp r2, #1 8023b68: f000 8186 beq.w 8023e78 <__gethex+0x4d0> 8023b6c: 9807 ldr r0, [sp, #28] 8023b6e: 2750 movs r7, #80 ; 0x50 8023b70: 9904 ldr r1, [sp, #16] 8023b72: f000 fe51 bl 8024818 <_Bfree> 8023b76: 9814 ldr r0, [sp, #80] ; 0x50 8023b78: 2300 movs r3, #0 8023b7a: 6003 str r3, [r0, #0] 8023b7c: e778 b.n 8023a70 <__gethex+0xc8> 8023b7e: f84b 8b04 str.w r8, [fp], #4 8023b82: f04f 0800 mov.w r8, #0 8023b86: 2704 movs r7, #4 8023b88: 4642 mov r2, r8 8023b8a: e79a b.n 8023ac2 <__gethex+0x11a> 8023b8c: 7863 ldrb r3, [r4, #1] 8023b8e: 2b2b cmp r3, #43 ; 0x2b 8023b90: f000 80f2 beq.w 8023d78 <__gethex+0x3d0> 8023b94: 2b2d cmp r3, #45 ; 0x2d 8023b96: f000 80ea beq.w 8023d6e <__gethex+0x3c6> 8023b9a: 1c60 adds r0, r4, #1 8023b9c: f04f 0b00 mov.w fp, #0 8023ba0: 5cf1 ldrb r1, [r6, r3] 8023ba2: f245 133c movw r3, #20796 ; 0x513c 8023ba6: f2c2 0301 movt r3, #8193 ; 0x2001 8023baa: 2900 cmp r1, #0 8023bac: f43f af56 beq.w 8023a5c <__gethex+0xb4> 8023bb0: 2919 cmp r1, #25 8023bb2: f73f af53 bgt.w 8023a5c <__gethex+0xb4> 8023bb6: f890 c001 ldrb.w ip, [r0, #1] 8023bba: 3910 subs r1, #16 8023bbc: 1c42 adds r2, r0, #1 8023bbe: f813 300c ldrb.w r3, [r3, ip] 8023bc2: b193 cbz r3, 8023bea <__gethex+0x242> 8023bc4: 2b19 cmp r3, #25 8023bc6: dc10 bgt.n 8023bea <__gethex+0x242> 8023bc8: 3002 adds r0, #2 8023bca: e001 b.n 8023bd0 <__gethex+0x228> 8023bcc: 2b19 cmp r3, #25 8023bce: dc0c bgt.n 8023bea <__gethex+0x242> 8023bd0: 4602 mov r2, r0 8023bd2: eb01 0181 add.w r1, r1, r1, lsl #2 8023bd6: 3001 adds r0, #1 8023bd8: f892 c000 ldrb.w ip, [r2] 8023bdc: eb03 0141 add.w r1, r3, r1, lsl #1 8023be0: 3910 subs r1, #16 8023be2: f816 300c ldrb.w r3, [r6, ip] 8023be6: 2b00 cmp r3, #0 8023be8: d1f0 bne.n 8023bcc <__gethex+0x224> 8023bea: f1bb 0f00 cmp.w fp, #0 8023bee: d000 beq.n 8023bf2 <__gethex+0x24a> 8023bf0: 4249 negs r1, r1 8023bf2: 9b05 ldr r3, [sp, #20] 8023bf4: 185b adds r3, r3, r1 8023bf6: 9305 str r3, [sp, #20] 8023bf8: e731 b.n 8023a5e <__gethex+0xb6> 8023bfa: f7ff fea9 bl 8023950 <__hexdig_init> 8023bfe: e6ee b.n 80239de <__gethex+0x36> 8023c00: 4628 mov r0, r5 8023c02: 9902 ldr r1, [sp, #8] 8023c04: 9a03 ldr r2, [sp, #12] 8023c06: f7fe f995 bl 8021f34 8023c0a: 2800 cmp r0, #0 8023c0c: f040 809a bne.w 8023d44 <__gethex+0x39c> 8023c10: 9803 ldr r0, [sp, #12] 8023c12: 182c adds r4, r5, r0 8023c14: 5c2b ldrb r3, [r5, r0] 8023c16: f819 2003 ldrb.w r2, [r9, r3] 8023c1a: 2a00 cmp r2, #0 8023c1c: f000 80e8 beq.w 8023df0 <__gethex+0x448> 8023c20: 2b30 cmp r3, #48 ; 0x30 8023c22: f040 8108 bne.w 8023e36 <__gethex+0x48e> 8023c26: 1c63 adds r3, r4, #1 8023c28: 461d mov r5, r3 8023c2a: f813 2b01 ldrb.w r2, [r3], #1 8023c2e: 2a30 cmp r2, #48 ; 0x30 8023c30: d0fa beq.n 8023c28 <__gethex+0x280> 8023c32: 5cb3 ldrb r3, [r6, r2] 8023c34: 2b00 cmp r3, #0 8023c36: f040 80ff bne.w 8023e38 <__gethex+0x490> 8023c3a: f04f 0901 mov.w r9, #1 8023c3e: 46a3 mov fp, r4 8023c40: 464f mov r7, r9 8023c42: 462c mov r4, r5 8023c44: e6f4 b.n 8023a30 <__gethex+0x88> 8023c46: 1e77 subs r7, r6, #1 8023c48: 2d00 cmp r5, #0 8023c4a: f040 80e7 bne.w 8023e1c <__gethex+0x474> 8023c4e: 2f00 cmp r7, #0 8023c50: dd04 ble.n 8023c5c <__gethex+0x2b4> 8023c52: 9804 ldr r0, [sp, #16] 8023c54: 4639 mov r1, r7 8023c56: f001 fa05 bl 8025064 <__any_on> 8023c5a: 4605 mov r5, r0 8023c5c: 9908 ldr r1, [sp, #32] 8023c5e: 117b asrs r3, r7, #5 8023c60: 2201 movs r2, #1 8023c62: f007 071f and.w r7, r7, #31 8023c66: 9804 ldr r0, [sp, #16] 8023c68: 1ba4 subs r4, r4, r6 8023c6a: f851 3023 ldr.w r3, [r1, r3, lsl #2] 8023c6e: fa02 f207 lsl.w r2, r2, r7 8023c72: 4631 mov r1, r6 8023c74: 421a tst r2, r3 8023c76: bf18 it ne 8023c78: f045 0502 orrne.w r5, r5, #2 8023c7c: f7ff fe10 bl 80238a0 8023c80: 9b06 ldr r3, [sp, #24] 8023c82: 2702 movs r7, #2 8023c84: 685b ldr r3, [r3, #4] 8023c86: 9305 str r3, [sp, #20] 8023c88: 2d00 cmp r5, #0 8023c8a: d069 beq.n 8023d60 <__gethex+0x3b8> 8023c8c: 9806 ldr r0, [sp, #24] 8023c8e: 68c3 ldr r3, [r0, #12] 8023c90: 2b02 cmp r3, #2 8023c92: f000 80ea beq.w 8023e6a <__gethex+0x4c2> 8023c96: 2b03 cmp r3, #3 8023c98: d05d beq.n 8023d56 <__gethex+0x3ae> 8023c9a: 2b01 cmp r3, #1 8023c9c: d15e bne.n 8023d5c <__gethex+0x3b4> 8023c9e: 07aa lsls r2, r5, #30 8023ca0: d55c bpl.n 8023d5c <__gethex+0x3b4> 8023ca2: 9908 ldr r1, [sp, #32] 8023ca4: 680b ldr r3, [r1, #0] 8023ca6: 432b orrs r3, r5 8023ca8: 07db lsls r3, r3, #31 8023caa: d557 bpl.n 8023d5c <__gethex+0x3b4> 8023cac: 9b04 ldr r3, [sp, #16] 8023cae: 2600 movs r6, #0 8023cb0: 9904 ldr r1, [sp, #16] 8023cb2: 691d ldr r5, [r3, #16] 8023cb4: 9b08 ldr r3, [sp, #32] 8023cb6: eb01 0085 add.w r0, r1, r5, lsl #2 8023cba: 3014 adds r0, #20 8023cbc: 4619 mov r1, r3 8023cbe: f853 2b04 ldr.w r2, [r3], #4 8023cc2: f1b2 3fff cmp.w r2, #4294967295 8023cc6: f040 80eb bne.w 8023ea0 <__gethex+0x4f8> 8023cca: 4298 cmp r0, r3 8023ccc: f843 6c04 str.w r6, [r3, #-4] 8023cd0: d8f4 bhi.n 8023cbc <__gethex+0x314> 8023cd2: 9a04 ldr r2, [sp, #16] 8023cd4: 6893 ldr r3, [r2, #8] 8023cd6: 429d cmp r5, r3 8023cd8: bfb8 it lt 8023cda: 462b movlt r3, r5 8023cdc: f280 80f9 bge.w 8023ed2 <__gethex+0x52a> 8023ce0: 9904 ldr r1, [sp, #16] 8023ce2: eb01 0283 add.w r2, r1, r3, lsl #2 8023ce6: 3301 adds r3, #1 8023ce8: 610b str r3, [r1, #16] 8023cea: 2301 movs r3, #1 8023cec: 6153 str r3, [r2, #20] 8023cee: 2f02 cmp r7, #2 8023cf0: f000 80d9 beq.w 8023ea6 <__gethex+0x4fe> 8023cf4: 9904 ldr r1, [sp, #16] 8023cf6: 690b ldr r3, [r1, #16] 8023cf8: 429d cmp r5, r3 8023cfa: db0e blt.n 8023d1a <__gethex+0x372> 8023cfc: f014 041f ands.w r4, r4, #31 8023d00: f000 80ac beq.w 8023e5c <__gethex+0x4b4> 8023d04: 9b04 ldr r3, [sp, #16] 8023d06: eb03 0585 add.w r5, r3, r5, lsl #2 8023d0a: 6928 ldr r0, [r5, #16] 8023d0c: f000 fe30 bl 8024970 <__hi0bits> 8023d10: f1c4 0320 rsb r3, r4, #32 8023d14: 4298 cmp r0, r3 8023d16: f280 80a1 bge.w 8023e5c <__gethex+0x4b4> 8023d1a: 9804 ldr r0, [sp, #16] 8023d1c: 2101 movs r1, #1 8023d1e: f7ff fdbf bl 80238a0 8023d22: 9a06 ldr r2, [sp, #24] 8023d24: 9805 ldr r0, [sp, #20] 8023d26: 6893 ldr r3, [r2, #8] 8023d28: 3001 adds r0, #1 8023d2a: 9005 str r0, [sp, #20] 8023d2c: 4298 cmp r0, r3 8023d2e: f340 8095 ble.w 8023e5c <__gethex+0x4b4> 8023d32: 9807 ldr r0, [sp, #28] 8023d34: 27a3 movs r7, #163 ; 0xa3 8023d36: 9904 ldr r1, [sp, #16] 8023d38: f000 fd6e bl 8024818 <_Bfree> 8023d3c: 9a14 ldr r2, [sp, #80] ; 0x50 8023d3e: 2300 movs r3, #0 8023d40: 6013 str r3, [r2, #0] 8023d42: e695 b.n 8023a70 <__gethex+0xc8> 8023d44: 782b ldrb r3, [r5, #0] 8023d46: 462c mov r4, r5 8023d48: f8cd b014 str.w fp, [sp, #20] 8023d4c: f04f 0901 mov.w r9, #1 8023d50: e67e b.n 8023a50 <__gethex+0xa8> 8023d52: 2701 movs r7, #1 8023d54: e798 b.n 8023c88 <__gethex+0x2e0> 8023d56: 9b15 ldr r3, [sp, #84] ; 0x54 8023d58: 2b00 cmp r3, #0 8023d5a: d1a7 bne.n 8023cac <__gethex+0x304> 8023d5c: f047 0710 orr.w r7, r7, #16 8023d60: 9b04 ldr r3, [sp, #16] 8023d62: 9814 ldr r0, [sp, #80] ; 0x50 8023d64: 6003 str r3, [r0, #0] 8023d66: 9b05 ldr r3, [sp, #20] 8023d68: 9809 ldr r0, [sp, #36] ; 0x24 8023d6a: 6003 str r3, [r0, #0] 8023d6c: e680 b.n 8023a70 <__gethex+0xc8> 8023d6e: f04f 0b01 mov.w fp, #1 8023d72: 78a3 ldrb r3, [r4, #2] 8023d74: 1ca0 adds r0, r4, #2 8023d76: e713 b.n 8023ba0 <__gethex+0x1f8> 8023d78: f04f 0b00 mov.w fp, #0 8023d7c: e7f9 b.n 8023d72 <__gethex+0x3ca> 8023d7e: 1b06 subs r6, r0, r4 8023d80: 9804 ldr r0, [sp, #16] 8023d82: 4631 mov r1, r6 8023d84: f001 f96e bl 8025064 <__any_on> 8023d88: 4605 mov r5, r0 8023d8a: b1a8 cbz r0, 8023db8 <__gethex+0x410> 8023d8c: 1e73 subs r3, r6, #1 8023d8e: 9804 ldr r0, [sp, #16] 8023d90: 2501 movs r5, #1 8023d92: f003 011f and.w r1, r3, #31 8023d96: 115a asrs r2, r3, #5 8023d98: fa05 f101 lsl.w r1, r5, r1 8023d9c: eb00 0282 add.w r2, r0, r2, lsl #2 8023da0: 6952 ldr r2, [r2, #20] 8023da2: 4211 tst r1, r2 8023da4: d008 beq.n 8023db8 <__gethex+0x410> 8023da6: 42ab cmp r3, r5 8023da8: dd05 ble.n 8023db6 <__gethex+0x40e> 8023daa: 9804 ldr r0, [sp, #16] 8023dac: 1eb1 subs r1, r6, #2 8023dae: f001 f959 bl 8025064 <__any_on> 8023db2: 2503 movs r5, #3 8023db4: b900 cbnz r0, 8023db8 <__gethex+0x410> 8023db6: 2502 movs r5, #2 8023db8: 9804 ldr r0, [sp, #16] 8023dba: 4631 mov r1, r6 8023dbc: f7ff fd70 bl 80238a0 8023dc0: 9b05 ldr r3, [sp, #20] 8023dc2: 199b adds r3, r3, r6 8023dc4: 9305 str r3, [sp, #20] 8023dc6: e6b8 b.n 8023b3a <__gethex+0x192> 8023dc8: f8cd b014 str.w fp, [sp, #20] 8023dcc: e640 b.n 8023a50 <__gethex+0xa8> 8023dce: 1a25 subs r5, r4, r0 8023dd0: 9904 ldr r1, [sp, #16] 8023dd2: 462a mov r2, r5 8023dd4: 9807 ldr r0, [sp, #28] 8023dd6: f000 ff11 bl 8024bfc <__lshift> 8023dda: 9b05 ldr r3, [sp, #20] 8023ddc: 1b5b subs r3, r3, r5 8023dde: 2500 movs r5, #0 8023de0: 9305 str r3, [sp, #20] 8023de2: 9004 str r0, [sp, #16] 8023de4: f100 0314 add.w r3, r0, #20 8023de8: 9308 str r3, [sp, #32] 8023dea: e6a6 b.n 8023b3a <__gethex+0x192> 8023dec: 2700 movs r7, #0 8023dee: e605 b.n 80239fc <__gethex+0x54> 8023df0: 9205 str r2, [sp, #20] 8023df2: f04f 0901 mov.w r9, #1 8023df6: e62b b.n 8023a50 <__gethex+0xa8> 8023df8: 462c mov r4, r5 8023dfa: 4681 mov r9, r0 8023dfc: 9903 ldr r1, [sp, #12] 8023dfe: eb04 0b01 add.w fp, r4, r1 8023e02: 5c63 ldrb r3, [r4, r1] 8023e04: 5cf2 ldrb r2, [r6, r3] 8023e06: 2a00 cmp r2, #0 8023e08: d07a beq.n 8023f00 <__gethex+0x558> 8023e0a: f10b 0201 add.w r2, fp, #1 8023e0e: 4614 mov r4, r2 8023e10: f812 3b01 ldrb.w r3, [r2], #1 8023e14: 5cf1 ldrb r1, [r6, r3] 8023e16: 2900 cmp r1, #0 8023e18: d1f9 bne.n 8023e0e <__gethex+0x466> 8023e1a: e614 b.n 8023a46 <__gethex+0x9e> 8023e1c: 2501 movs r5, #1 8023e1e: e71d b.n 8023c5c <__gethex+0x2b4> 8023e20: 4628 mov r0, r5 8023e22: 9902 ldr r1, [sp, #8] 8023e24: 9a03 ldr r2, [sp, #12] 8023e26: f7fe f885 bl 8021f34 8023e2a: 2800 cmp r0, #0 8023e2c: d0e4 beq.n 8023df8 <__gethex+0x450> 8023e2e: 46a1 mov r9, r4 8023e30: 462c mov r4, r5 8023e32: 46cb mov fp, r9 8023e34: e602 b.n 8023a3c <__gethex+0x94> 8023e36: 4625 mov r5, r4 8023e38: 46a3 mov fp, r4 8023e3a: 2701 movs r7, #1 8023e3c: e5f0 b.n 8023a20 <__gethex+0x78> 8023e3e: 9815 ldr r0, [sp, #84] ; 0x54 8023e40: 2800 cmp r0, #0 8023e42: f47f ae93 bne.w 8023b6c <__gethex+0x1c4> 8023e46: 9a09 ldr r2, [sp, #36] ; 0x24 8023e48: 2762 movs r7, #98 ; 0x62 8023e4a: 9804 ldr r0, [sp, #16] 8023e4c: 9908 ldr r1, [sp, #32] 8023e4e: 6013 str r3, [r2, #0] 8023e50: 2301 movs r3, #1 8023e52: 9a14 ldr r2, [sp, #80] ; 0x50 8023e54: 6103 str r3, [r0, #16] 8023e56: 600b str r3, [r1, #0] 8023e58: 6010 str r0, [r2, #0] 8023e5a: e609 b.n 8023a70 <__gethex+0xc8> 8023e5c: 2721 movs r7, #33 ; 0x21 8023e5e: e77f b.n 8023d60 <__gethex+0x3b8> 8023e60: f8dd b020 ldr.w fp, [sp, #32] 8023e64: f04f 0800 mov.w r8, #0 8023e68: e651 b.n 8023b0e <__gethex+0x166> 8023e6a: 9a15 ldr r2, [sp, #84] ; 0x54 8023e6c: f1c2 0301 rsb r3, r2, #1 8023e70: 2b00 cmp r3, #0 8023e72: f43f af73 beq.w 8023d5c <__gethex+0x3b4> 8023e76: e719 b.n 8023cac <__gethex+0x304> 8023e78: 42a6 cmp r6, r4 8023e7a: f47f ae77 bne.w 8023b6c <__gethex+0x1c4> 8023e7e: 2c01 cmp r4, #1 8023e80: dde1 ble.n 8023e46 <__gethex+0x49e> 8023e82: 9804 ldr r0, [sp, #16] 8023e84: 1e61 subs r1, r4, #1 8023e86: f001 f8ed bl 8025064 <__any_on> 8023e8a: 2800 cmp r0, #0 8023e8c: f43f ae6e beq.w 8023b6c <__gethex+0x1c4> 8023e90: 9a06 ldr r2, [sp, #24] 8023e92: 6853 ldr r3, [r2, #4] 8023e94: e7d7 b.n 8023e46 <__gethex+0x49e> 8023e96: 9915 ldr r1, [sp, #84] ; 0x54 8023e98: 2900 cmp r1, #0 8023e9a: f43f ae67 beq.w 8023b6c <__gethex+0x1c4> 8023e9e: e7d2 b.n 8023e46 <__gethex+0x49e> 8023ea0: 3201 adds r2, #1 8023ea2: 600a str r2, [r1, #0] 8023ea4: e723 b.n 8023cee <__gethex+0x346> 8023ea6: 9a06 ldr r2, [sp, #24] 8023ea8: 2722 movs r7, #34 ; 0x22 8023eaa: 6813 ldr r3, [r2, #0] 8023eac: 3b01 subs r3, #1 8023eae: 42a3 cmp r3, r4 8023eb0: f47f af56 bne.w 8023d60 <__gethex+0x3b8> 8023eb4: 1163 asrs r3, r4, #5 8023eb6: 9804 ldr r0, [sp, #16] 8023eb8: 2201 movs r2, #1 8023eba: f004 041f and.w r4, r4, #31 8023ebe: eb00 0383 add.w r3, r0, r3, lsl #2 8023ec2: fa02 f204 lsl.w r2, r2, r4 8023ec6: 695b ldr r3, [r3, #20] 8023ec8: 421a tst r2, r3 8023eca: bf14 ite ne 8023ecc: 2721 movne r7, #33 ; 0x21 8023ece: 2722 moveq r7, #34 ; 0x22 8023ed0: e746 b.n 8023d60 <__gethex+0x3b8> 8023ed2: 6851 ldr r1, [r2, #4] 8023ed4: 9807 ldr r0, [sp, #28] 8023ed6: 3101 adds r1, #1 8023ed8: f000 fc68 bl 80247ac <_Balloc> 8023edc: 4606 mov r6, r0 8023ede: 9804 ldr r0, [sp, #16] 8023ee0: f100 010c add.w r1, r0, #12 8023ee4: 6903 ldr r3, [r0, #16] 8023ee6: f106 000c add.w r0, r6, #12 8023eea: 1c9a adds r2, r3, #2 8023eec: 0092 lsls r2, r2, #2 8023eee: f7fd fd2d bl 802194c 8023ef2: 9904 ldr r1, [sp, #16] 8023ef4: 9807 ldr r0, [sp, #28] 8023ef6: 9604 str r6, [sp, #16] 8023ef8: f000 fc8e bl 8024818 <_Bfree> 8023efc: 6933 ldr r3, [r6, #16] 8023efe: e6ef b.n 8023ce0 <__gethex+0x338> 8023f00: 465c mov r4, fp 8023f02: e5a0 b.n 8023a46 <__gethex+0x9e> 08023f04 <__hexnan>: 8023f04: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8023f08: f245 183c movw r8, #20796 ; 0x513c 8023f0c: f2c2 0801 movt r8, #8193 ; 0x2001 8023f10: b085 sub sp, #20 8023f12: 460c mov r4, r1 8023f14: 4692 mov sl, r2 8023f16: f898 3030 ldrb.w r3, [r8, #48] ; 0x30 8023f1a: 9002 str r0, [sp, #8] 8023f1c: 2b00 cmp r3, #0 8023f1e: f000 80ad beq.w 802407c <__hexnan+0x178> 8023f22: 6823 ldr r3, [r4, #0] 8023f24: 115a asrs r2, r3, #5 8023f26: f013 031f ands.w r3, r3, #31 8023f2a: 9303 str r3, [sp, #12] 8023f2c: eb0a 0282 add.w r2, sl, r2, lsl #2 8023f30: 9200 str r2, [sp, #0] 8023f32: d001 beq.n 8023f38 <__hexnan+0x34> 8023f34: 3204 adds r2, #4 8023f36: 9200 str r2, [sp, #0] 8023f38: 9a00 ldr r2, [sp, #0] 8023f3a: 2300 movs r3, #0 8023f3c: 4699 mov r9, r3 8023f3e: 9900 ldr r1, [sp, #0] 8023f40: 46cb mov fp, r9 8023f42: 464e mov r6, r9 8023f44: f842 3c04 str.w r3, [r2, #-4] 8023f48: 3904 subs r1, #4 8023f4a: 9b02 ldr r3, [sp, #8] 8023f4c: 9101 str r1, [sp, #4] 8023f4e: f8dd c004 ldr.w ip, [sp, #4] 8023f52: 6819 ldr r1, [r3, #0] 8023f54: 4664 mov r4, ip 8023f56: 784b ldrb r3, [r1, #1] 8023f58: 2b00 cmp r3, #0 8023f5a: d033 beq.n 8023fc4 <__hexnan+0xc0> 8023f5c: f818 2003 ldrb.w r2, [r8, r3] 8023f60: 2a00 cmp r2, #0 8023f62: d16f bne.n 8024044 <__hexnan+0x140> 8023f64: 2b20 cmp r3, #32 8023f66: f200 8083 bhi.w 8024070 <__hexnan+0x16c> 8023f6a: 455e cmp r6, fp 8023f6c: dd26 ble.n 8023fbc <__hexnan+0xb8> 8023f6e: f1b9 0f07 cmp.w r9, #7 8023f72: bfcc ite gt 8023f74: 2300 movgt r3, #0 8023f76: 2301 movle r3, #1 8023f78: 4564 cmp r4, ip 8023f7a: bf28 it cs 8023f7c: 2300 movcs r3, #0 8023f7e: b193 cbz r3, 8023fa6 <__hexnan+0xa2> 8023f80: f1c9 0908 rsb r9, r9, #8 8023f84: 6822 ldr r2, [r4, #0] 8023f86: 4623 mov r3, r4 8023f88: ea4f 0989 mov.w r9, r9, lsl #2 8023f8c: f1c9 0720 rsb r7, r9, #32 8023f90: 6858 ldr r0, [r3, #4] 8023f92: fa00 f507 lsl.w r5, r0, r7 8023f96: 4315 orrs r5, r2 8023f98: fa20 f209 lsr.w r2, r0, r9 8023f9c: 601d str r5, [r3, #0] 8023f9e: f843 2f04 str.w r2, [r3, #4]! 8023fa2: 459c cmp ip, r3 8023fa4: d8f4 bhi.n 8023f90 <__hexnan+0x8c> 8023fa6: 4554 cmp r4, sl 8023fa8: bf98 it ls 8023faa: f04f 0908 movls.w r9, #8 8023fae: d905 bls.n 8023fbc <__hexnan+0xb8> 8023fb0: 2200 movs r2, #0 8023fb2: 3c04 subs r4, #4 8023fb4: 6022 str r2, [r4, #0] 8023fb6: 46b3 mov fp, r6 8023fb8: 46a4 mov ip, r4 8023fba: 4691 mov r9, r2 8023fbc: 3101 adds r1, #1 8023fbe: 784b ldrb r3, [r1, #1] 8023fc0: 2b00 cmp r3, #0 8023fc2: d1cb bne.n 8023f5c <__hexnan+0x58> 8023fc4: 2e00 cmp r6, #0 8023fc6: d055 beq.n 8024074 <__hexnan+0x170> 8023fc8: f1b9 0f07 cmp.w r9, #7 8023fcc: bfcc ite gt 8023fce: 2300 movgt r3, #0 8023fd0: 2301 movle r3, #1 8023fd2: 4564 cmp r4, ip 8023fd4: bf28 it cs 8023fd6: 2300 movcs r3, #0 8023fd8: b193 cbz r3, 8024000 <__hexnan+0xfc> 8023fda: f1c9 0908 rsb r9, r9, #8 8023fde: 6822 ldr r2, [r4, #0] 8023fe0: 4623 mov r3, r4 8023fe2: ea4f 0989 mov.w r9, r9, lsl #2 8023fe6: f1c9 0520 rsb r5, r9, #32 8023fea: 6859 ldr r1, [r3, #4] 8023fec: fa01 f005 lsl.w r0, r1, r5 8023ff0: 4310 orrs r0, r2 8023ff2: fa21 f209 lsr.w r2, r1, r9 8023ff6: 6018 str r0, [r3, #0] 8023ff8: f843 2f04 str.w r2, [r3, #4]! 8023ffc: 4563 cmp r3, ip 8023ffe: d3f4 bcc.n 8023fea <__hexnan+0xe6> 8024000: 45a2 cmp sl, r4 8024002: d23e bcs.n 8024082 <__hexnan+0x17e> 8024004: 9801 ldr r0, [sp, #4] 8024006: 4652 mov r2, sl 8024008: f854 1b04 ldr.w r1, [r4], #4 802400c: 4613 mov r3, r2 802400e: 42a0 cmp r0, r4 8024010: f843 1b04 str.w r1, [r3], #4 8024014: 461a mov r2, r3 8024016: d2f7 bcs.n 8024008 <__hexnan+0x104> 8024018: 9901 ldr r1, [sp, #4] 802401a: 2200 movs r2, #0 802401c: f843 2b04 str.w r2, [r3], #4 8024020: 4299 cmp r1, r3 8024022: d2fb bcs.n 802401c <__hexnan+0x118> 8024024: 9900 ldr r1, [sp, #0] 8024026: f851 3c04 ldr.w r3, [r1, #-4] 802402a: b94b cbnz r3, 8024040 <__hexnan+0x13c> 802402c: 9b01 ldr r3, [sp, #4] 802402e: 459a cmp sl, r3 8024030: d102 bne.n 8024038 <__hexnan+0x134> 8024032: e038 b.n 80240a6 <__hexnan+0x1a2> 8024034: 459a cmp sl, r3 8024036: d037 beq.n 80240a8 <__hexnan+0x1a4> 8024038: f853 2d04 ldr.w r2, [r3, #-4]! 802403c: 2a00 cmp r2, #0 802403e: d0f9 beq.n 8024034 <__hexnan+0x130> 8024040: 2005 movs r0, #5 8024042: e018 b.n 8024076 <__hexnan+0x172> 8024044: f109 0901 add.w r9, r9, #1 8024048: 3601 adds r6, #1 802404a: f1b9 0f08 cmp.w r9, #8 802404e: dc07 bgt.n 8024060 <__hexnan+0x15c> 8024050: 6823 ldr r3, [r4, #0] 8024052: 011b lsls r3, r3, #4 8024054: f002 020f and.w r2, r2, #15 8024058: 3101 adds r1, #1 802405a: 431a orrs r2, r3 802405c: 6022 str r2, [r4, #0] 802405e: e7ae b.n 8023fbe <__hexnan+0xba> 8024060: 4554 cmp r4, sl 8024062: d9ab bls.n 8023fbc <__hexnan+0xb8> 8024064: 2300 movs r3, #0 8024066: 3c04 subs r4, #4 8024068: 6023 str r3, [r4, #0] 802406a: f04f 0901 mov.w r9, #1 802406e: e7f1 b.n 8024054 <__hexnan+0x150> 8024070: 2b29 cmp r3, #41 ; 0x29 8024072: d01d beq.n 80240b0 <__hexnan+0x1ac> 8024074: 2004 movs r0, #4 8024076: b005 add sp, #20 8024078: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802407c: f7ff fc68 bl 8023950 <__hexdig_init> 8024080: e74f b.n 8023f22 <__hexnan+0x1e> 8024082: 9a03 ldr r2, [sp, #12] 8024084: 2a00 cmp r2, #0 8024086: d0cd beq.n 8024024 <__hexnan+0x120> 8024088: 9a00 ldr r2, [sp, #0] 802408a: 9903 ldr r1, [sp, #12] 802408c: f852 3c04 ldr.w r3, [r2, #-4] 8024090: f1c1 0220 rsb r2, r1, #32 8024094: f04f 31ff mov.w r1, #4294967295 8024098: fa21 f202 lsr.w r2, r1, r2 802409c: 4013 ands r3, r2 802409e: 9a00 ldr r2, [sp, #0] 80240a0: f842 3c04 str.w r3, [r2, #-4] 80240a4: e7c1 b.n 802402a <__hexnan+0x126> 80240a6: 4653 mov r3, sl 80240a8: 2201 movs r2, #1 80240aa: 2005 movs r0, #5 80240ac: 601a str r2, [r3, #0] 80240ae: e7e2 b.n 8024076 <__hexnan+0x172> 80240b0: 9b02 ldr r3, [sp, #8] 80240b2: 3102 adds r1, #2 80240b4: 6019 str r1, [r3, #0] 80240b6: 2e00 cmp r6, #0 80240b8: d186 bne.n 8023fc8 <__hexnan+0xc4> 80240ba: e7db b.n 8024074 <__hexnan+0x170> 080240bc <_setlocale_r>: 80240bc: b510 push {r4, lr} 80240be: 4614 mov r4, r2 80240c0: b13a cbz r2, 80240d2 <_setlocale_r+0x16> 80240c2: f640 11d8 movw r1, #2520 ; 0x9d8 80240c6: 4610 mov r0, r2 80240c8: f6c0 0104 movt r1, #2052 ; 0x804 80240cc: f7fd fd84 bl 8021bd8 80240d0: b920 cbnz r0, 80240dc <_setlocale_r+0x20> 80240d2: f640 10d4 movw r0, #2516 ; 0x9d4 80240d6: f6c0 0004 movt r0, #2052 ; 0x804 80240da: bd10 pop {r4, pc} 80240dc: f640 11d4 movw r1, #2516 ; 0x9d4 80240e0: 4620 mov r0, r4 80240e2: f6c0 0104 movt r1, #2052 ; 0x804 80240e6: f7fd fd77 bl 8021bd8 80240ea: 2800 cmp r0, #0 80240ec: d0f1 beq.n 80240d2 <_setlocale_r+0x16> 80240ee: f640 11e0 movw r1, #2528 ; 0x9e0 80240f2: 4620 mov r0, r4 80240f4: f6c0 0104 movt r1, #2052 ; 0x804 80240f8: f7fd fd6e bl 8021bd8 80240fc: f640 13d4 movw r3, #2516 ; 0x9d4 8024100: f6c0 0304 movt r3, #2052 ; 0x804 8024104: 2800 cmp r0, #0 8024106: bf0c ite eq 8024108: 4618 moveq r0, r3 802410a: 2000 movne r0, #0 802410c: bd10 pop {r4, pc} 802410e: bf00 nop 08024110 <__locale_charset>: 8024110: f240 1020 movw r0, #288 ; 0x120 8024114: f2c2 0000 movt r0, #8192 ; 0x2000 8024118: 4770 bx lr 802411a: bf00 nop 0802411c <__locale_mb_cur_max>: 802411c: f240 1320 movw r3, #288 ; 0x120 8024120: f2c2 0300 movt r3, #8192 ; 0x2000 8024124: 6a18 ldr r0, [r3, #32] 8024126: 4770 bx lr 08024128 <__locale_msgcharset>: 8024128: 4800 ldr r0, [pc, #0] ; (802412c <__locale_msgcharset+0x4>) 802412a: 4770 bx lr 802412c: 20000144 .word 0x20000144 08024130 <__locale_cjk_lang>: 8024130: 2000 movs r0, #0 8024132: 4770 bx lr 08024134 <_localeconv_r>: 8024134: 4800 ldr r0, [pc, #0] ; (8024138 <_localeconv_r+0x4>) 8024136: 4770 bx lr 8024138: 20000164 .word 0x20000164 0802413c : 802413c: f240 032c movw r3, #44 ; 0x2c 8024140: 460a mov r2, r1 8024142: f2c2 0300 movt r3, #8192 ; 0x2000 8024146: 4601 mov r1, r0 8024148: 6818 ldr r0, [r3, #0] 802414a: f7ff bfb7 b.w 80240bc <_setlocale_r> 802414e: bf00 nop 08024150 : 8024150: 4800 ldr r0, [pc, #0] ; (8024154 ) 8024152: 4770 bx lr 8024154: 20000164 .word 0x20000164 08024158 : 8024158: f240 032c movw r3, #44 ; 0x2c 802415c: 4601 mov r1, r0 802415e: f2c2 0300 movt r3, #8192 ; 0x2000 8024162: 6818 ldr r0, [r3, #0] 8024164: f000 b808 b.w 8024178 <_malloc_r> 08024168 : 8024168: f240 032c movw r3, #44 ; 0x2c 802416c: 4601 mov r1, r0 802416e: f2c2 0300 movt r3, #8192 ; 0x2000 8024172: 6818 ldr r0, [r3, #0] 8024174: f7ff baca b.w 802370c <_free_r> 08024178 <_malloc_r>: 8024178: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 802417c: f101 040b add.w r4, r1, #11 8024180: 2c16 cmp r4, #22 8024182: b083 sub sp, #12 8024184: 4607 mov r7, r0 8024186: d930 bls.n 80241ea <_malloc_r+0x72> 8024188: f024 0407 bic.w r4, r4, #7 802418c: 0fe3 lsrs r3, r4, #31 802418e: 428c cmp r4, r1 8024190: bf2c ite cs 8024192: 4619 movcs r1, r3 8024194: f043 0101 orrcc.w r1, r3, #1 8024198: 2900 cmp r1, #0 802419a: d12f bne.n 80241fc <_malloc_r+0x84> 802419c: 4638 mov r0, r7 802419e: f000 fb01 bl 80247a4 <__malloc_lock> 80241a2: f5b4 7ffc cmp.w r4, #504 ; 0x1f8 80241a6: d22e bcs.n 8024206 <_malloc_r+0x8e> 80241a8: ea4f 0cd4 mov.w ip, r4, lsr #3 80241ac: f240 169c movw r6, #412 ; 0x19c 80241b0: f2c2 0600 movt r6, #8192 ; 0x2000 80241b4: eb06 02cc add.w r2, r6, ip, lsl #3 80241b8: 68d3 ldr r3, [r2, #12] 80241ba: 4293 cmp r3, r2 80241bc: f000 8211 beq.w 80245e2 <_malloc_r+0x46a> 80241c0: 6859 ldr r1, [r3, #4] 80241c2: f103 0808 add.w r8, r3, #8 80241c6: 68da ldr r2, [r3, #12] 80241c8: 4638 mov r0, r7 80241ca: f021 0403 bic.w r4, r1, #3 80241ce: 6899 ldr r1, [r3, #8] 80241d0: 191b adds r3, r3, r4 80241d2: 685c ldr r4, [r3, #4] 80241d4: 60ca str r2, [r1, #12] 80241d6: f044 0401 orr.w r4, r4, #1 80241da: 6091 str r1, [r2, #8] 80241dc: 605c str r4, [r3, #4] 80241de: f000 fae3 bl 80247a8 <__malloc_unlock> 80241e2: 4640 mov r0, r8 80241e4: b003 add sp, #12 80241e6: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 80241ea: 2300 movs r3, #0 80241ec: 2410 movs r4, #16 80241ee: 428c cmp r4, r1 80241f0: bf2c ite cs 80241f2: 4619 movcs r1, r3 80241f4: f043 0101 orrcc.w r1, r3, #1 80241f8: 2900 cmp r1, #0 80241fa: d0cf beq.n 802419c <_malloc_r+0x24> 80241fc: 230c movs r3, #12 80241fe: f04f 0800 mov.w r8, #0 8024202: 603b str r3, [r7, #0] 8024204: e7ed b.n 80241e2 <_malloc_r+0x6a> 8024206: ea5f 2c54 movs.w ip, r4, lsr #9 802420a: bf04 itt eq 802420c: ea4f 0cd4 moveq.w ip, r4, lsr #3 8024210: ea4f 054c moveq.w r5, ip, lsl #1 8024214: f040 808f bne.w 8024336 <_malloc_r+0x1be> 8024218: f240 169c movw r6, #412 ; 0x19c 802421c: f2c2 0600 movt r6, #8192 ; 0x2000 8024220: eb06 0585 add.w r5, r6, r5, lsl #2 8024224: 68eb ldr r3, [r5, #12] 8024226: 429d cmp r5, r3 8024228: d106 bne.n 8024238 <_malloc_r+0xc0> 802422a: e00d b.n 8024248 <_malloc_r+0xd0> 802422c: 2a00 cmp r2, #0 802422e: f280 8155 bge.w 80244dc <_malloc_r+0x364> 8024232: 68db ldr r3, [r3, #12] 8024234: 429d cmp r5, r3 8024236: d007 beq.n 8024248 <_malloc_r+0xd0> 8024238: 6859 ldr r1, [r3, #4] 802423a: f021 0103 bic.w r1, r1, #3 802423e: 1b0a subs r2, r1, r4 8024240: 2a0f cmp r2, #15 8024242: ddf3 ble.n 802422c <_malloc_r+0xb4> 8024244: f10c 3cff add.w ip, ip, #4294967295 8024248: f10c 0c01 add.w ip, ip, #1 802424c: f240 129c movw r2, #412 ; 0x19c 8024250: 6933 ldr r3, [r6, #16] 8024252: f2c2 0200 movt r2, #8192 ; 0x2000 8024256: f102 0e08 add.w lr, r2, #8 802425a: 4573 cmp r3, lr 802425c: bf08 it eq 802425e: f8d2 9004 ldreq.w r9, [r2, #4] 8024262: d022 beq.n 80242aa <_malloc_r+0x132> 8024264: 6858 ldr r0, [r3, #4] 8024266: f020 0003 bic.w r0, r0, #3 802426a: 1b01 subs r1, r0, r4 802426c: 290f cmp r1, #15 802426e: f300 8184 bgt.w 802457a <_malloc_r+0x402> 8024272: 2900 cmp r1, #0 8024274: f8c2 e014 str.w lr, [r2, #20] 8024278: f8c2 e010 str.w lr, [r2, #16] 802427c: da66 bge.n 802434c <_malloc_r+0x1d4> 802427e: f5b0 7f00 cmp.w r0, #512 ; 0x200 8024282: f080 814e bcs.w 8024522 <_malloc_r+0x3aa> 8024286: 08c1 lsrs r1, r0, #3 8024288: f04f 0801 mov.w r8, #1 802428c: eb02 00c1 add.w r0, r2, r1, lsl #3 8024290: 1089 asrs r1, r1, #2 8024292: fa08 f801 lsl.w r8, r8, r1 8024296: 6851 ldr r1, [r2, #4] 8024298: 6885 ldr r5, [r0, #8] 802429a: 60d8 str r0, [r3, #12] 802429c: ea48 0901 orr.w r9, r8, r1 80242a0: f8c2 9004 str.w r9, [r2, #4] 80242a4: 609d str r5, [r3, #8] 80242a6: 60eb str r3, [r5, #12] 80242a8: 6083 str r3, [r0, #8] 80242aa: 2201 movs r2, #1 80242ac: ea4f 03ac mov.w r3, ip, asr #2 80242b0: fa02 f303 lsl.w r3, r2, r3 80242b4: 454b cmp r3, r9 80242b6: d854 bhi.n 8024362 <_malloc_r+0x1ea> 80242b8: ea19 0f03 tst.w r9, r3 80242bc: d10d bne.n 80242da <_malloc_r+0x162> 80242be: 4093 lsls r3, r2 80242c0: f02c 0c03 bic.w ip, ip, #3 80242c4: ea19 0f03 tst.w r9, r3 80242c8: f10c 0c04 add.w ip, ip, #4 80242cc: d105 bne.n 80242da <_malloc_r+0x162> 80242ce: 005b lsls r3, r3, #1 80242d0: f10c 0c04 add.w ip, ip, #4 80242d4: ea19 0f03 tst.w r9, r3 80242d8: d0f9 beq.n 80242ce <_malloc_r+0x156> 80242da: eb06 09cc add.w r9, r6, ip, lsl #3 80242de: 46e0 mov r8, ip 80242e0: 4648 mov r0, r9 80242e2: 68c2 ldr r2, [r0, #12] 80242e4: 4290 cmp r0, r2 80242e6: d107 bne.n 80242f8 <_malloc_r+0x180> 80242e8: e15b b.n 80245a2 <_malloc_r+0x42a> 80242ea: 2900 cmp r1, #0 80242ec: f280 8183 bge.w 80245f6 <_malloc_r+0x47e> 80242f0: 68d2 ldr r2, [r2, #12] 80242f2: 4290 cmp r0, r2 80242f4: f000 8155 beq.w 80245a2 <_malloc_r+0x42a> 80242f8: 6855 ldr r5, [r2, #4] 80242fa: f025 0503 bic.w r5, r5, #3 80242fe: 1b29 subs r1, r5, r4 8024300: 290f cmp r1, #15 8024302: ddf2 ble.n 80242ea <_malloc_r+0x172> 8024304: 4690 mov r8, r2 8024306: 1913 adds r3, r2, r4 8024308: 68d5 ldr r5, [r2, #12] 802430a: f044 0001 orr.w r0, r4, #1 802430e: f858 4f08 ldr.w r4, [r8, #8]! 8024312: f041 0c01 orr.w ip, r1, #1 8024316: 6050 str r0, [r2, #4] 8024318: 4638 mov r0, r7 802431a: f8c3 c004 str.w ip, [r3, #4] 802431e: 60e5 str r5, [r4, #12] 8024320: 60ac str r4, [r5, #8] 8024322: 6173 str r3, [r6, #20] 8024324: 6133 str r3, [r6, #16] 8024326: f8c3 e00c str.w lr, [r3, #12] 802432a: f8c3 e008 str.w lr, [r3, #8] 802432e: 5059 str r1, [r3, r1] 8024330: f000 fa3a bl 80247a8 <__malloc_unlock> 8024334: e755 b.n 80241e2 <_malloc_r+0x6a> 8024336: f1bc 0f04 cmp.w ip, #4 802433a: f200 80de bhi.w 80244fa <_malloc_r+0x382> 802433e: ea4f 1c94 mov.w ip, r4, lsr #6 8024342: f10c 0c38 add.w ip, ip, #56 ; 0x38 8024346: ea4f 054c mov.w r5, ip, lsl #1 802434a: e765 b.n 8024218 <_malloc_r+0xa0> 802434c: 181a adds r2, r3, r0 802434e: f103 0808 add.w r8, r3, #8 8024352: 4638 mov r0, r7 8024354: 6853 ldr r3, [r2, #4] 8024356: f043 0301 orr.w r3, r3, #1 802435a: 6053 str r3, [r2, #4] 802435c: f000 fa24 bl 80247a8 <__malloc_unlock> 8024360: e73f b.n 80241e2 <_malloc_r+0x6a> 8024362: 68b5 ldr r5, [r6, #8] 8024364: 686b ldr r3, [r5, #4] 8024366: f023 0a03 bic.w sl, r3, #3 802436a: 4554 cmp r4, sl 802436c: d804 bhi.n 8024378 <_malloc_r+0x200> 802436e: ebc4 030a rsb r3, r4, sl 8024372: 2b0f cmp r3, #15 8024374: f300 80a4 bgt.w 80244c0 <_malloc_r+0x348> 8024378: f641 191c movw r9, #6428 ; 0x191c 802437c: f8d6 1408 ldr.w r1, [r6, #1032] ; 0x408 8024380: f2c2 0900 movt r9, #8192 ; 0x2000 8024384: eb05 020a add.w r2, r5, sl 8024388: 3101 adds r1, #1 802438a: f8d9 3000 ldr.w r3, [r9] 802438e: 4423 add r3, r4 8024390: bf08 it eq 8024392: f103 0b10 addeq.w fp, r3, #16 8024396: d006 beq.n 80243a6 <_malloc_r+0x22e> 8024398: f503 5380 add.w r3, r3, #4096 ; 0x1000 802439c: 330f adds r3, #15 802439e: f423 637f bic.w r3, r3, #4080 ; 0xff0 80243a2: f023 0b0f bic.w fp, r3, #15 80243a6: 4638 mov r0, r7 80243a8: 4659 mov r1, fp 80243aa: 9201 str r2, [sp, #4] 80243ac: f000 fe86 bl 80250bc <_sbrk_r> 80243b0: 9a01 ldr r2, [sp, #4] 80243b2: 1c41 adds r1, r0, #1 80243b4: 4680 mov r8, r0 80243b6: f000 8168 beq.w 802468a <_malloc_r+0x512> 80243ba: 4282 cmp r2, r0 80243bc: f200 8131 bhi.w 8024622 <_malloc_r+0x4aa> 80243c0: f8d9 3004 ldr.w r3, [r9, #4] 80243c4: 4542 cmp r2, r8 80243c6: 445b add r3, fp 80243c8: f8c9 3004 str.w r3, [r9, #4] 80243cc: f000 8166 beq.w 802469c <_malloc_r+0x524> 80243d0: f8d6 1408 ldr.w r1, [r6, #1032] ; 0x408 80243d4: f240 109c movw r0, #412 ; 0x19c 80243d8: f2c2 0000 movt r0, #8192 ; 0x2000 80243dc: 3101 adds r1, #1 80243de: bf17 itett ne 80243e0: ebc2 0208 rsbne r2, r2, r8 80243e4: f8c0 8408 streq.w r8, [r0, #1032] ; 0x408 80243e8: 189b addne r3, r3, r2 80243ea: f8c9 3004 strne.w r3, [r9, #4] 80243ee: f018 0307 ands.w r3, r8, #7 80243f2: 4638 mov r0, r7 80243f4: bf1f itttt ne 80243f6: f1c3 0208 rsbne r2, r3, #8 80243fa: f5c3 5380 rsbne r3, r3, #4096 ; 0x1000 80243fe: 4490 addne r8, r2 8024400: f103 0208 addne.w r2, r3, #8 8024404: eb08 030b add.w r3, r8, fp 8024408: bf08 it eq 802440a: f44f 5280 moveq.w r2, #4096 ; 0x1000 802440e: 051b lsls r3, r3, #20 8024410: 0d1b lsrs r3, r3, #20 8024412: ebc3 0b02 rsb fp, r3, r2 8024416: 4659 mov r1, fp 8024418: f000 fe50 bl 80250bc <_sbrk_r> 802441c: 1c43 adds r3, r0, #1 802441e: f000 8149 beq.w 80246b4 <_malloc_r+0x53c> 8024422: ebc8 0100 rsb r1, r8, r0 8024426: 4459 add r1, fp 8024428: f041 0101 orr.w r1, r1, #1 802442c: f8d9 3004 ldr.w r3, [r9, #4] 8024430: 42b5 cmp r5, r6 8024432: f641 121c movw r2, #6428 ; 0x191c 8024436: f8c6 8008 str.w r8, [r6, #8] 802443a: 445b add r3, fp 802443c: f2c2 0200 movt r2, #8192 ; 0x2000 8024440: f8c8 1004 str.w r1, [r8, #4] 8024444: f8c9 3004 str.w r3, [r9, #4] 8024448: d018 beq.n 802447c <_malloc_r+0x304> 802444a: f1ba 0f0f cmp.w sl, #15 802444e: f240 810b bls.w 8024668 <_malloc_r+0x4f0> 8024452: f1aa 000c sub.w r0, sl, #12 8024456: 6869 ldr r1, [r5, #4] 8024458: f020 0007 bic.w r0, r0, #7 802445c: f04f 0c05 mov.w ip, #5 8024460: eb05 0e00 add.w lr, r5, r0 8024464: 280f cmp r0, #15 8024466: f001 0101 and.w r1, r1, #1 802446a: ea40 0101 orr.w r1, r0, r1 802446e: 6069 str r1, [r5, #4] 8024470: f8ce c004 str.w ip, [lr, #4] 8024474: f8ce c008 str.w ip, [lr, #8] 8024478: f200 8120 bhi.w 80246bc <_malloc_r+0x544> 802447c: f641 121c movw r2, #6428 ; 0x191c 8024480: f8d9 102c ldr.w r1, [r9, #44] ; 0x2c 8024484: f2c2 0200 movt r2, #8192 ; 0x2000 8024488: 68b5 ldr r5, [r6, #8] 802448a: 428b cmp r3, r1 802448c: f8d9 1030 ldr.w r1, [r9, #48] ; 0x30 8024490: bf88 it hi 8024492: 62d3 strhi r3, [r2, #44] ; 0x2c 8024494: f641 121c movw r2, #6428 ; 0x191c 8024498: f2c2 0200 movt r2, #8192 ; 0x2000 802449c: 428b cmp r3, r1 802449e: bf88 it hi 80244a0: 6313 strhi r3, [r2, #48] ; 0x30 80244a2: 686a ldr r2, [r5, #4] 80244a4: f022 0203 bic.w r2, r2, #3 80244a8: 4294 cmp r4, r2 80244aa: ebc4 0302 rsb r3, r4, r2 80244ae: d801 bhi.n 80244b4 <_malloc_r+0x33c> 80244b0: 2b0f cmp r3, #15 80244b2: dc05 bgt.n 80244c0 <_malloc_r+0x348> 80244b4: 4638 mov r0, r7 80244b6: f04f 0800 mov.w r8, #0 80244ba: f000 f975 bl 80247a8 <__malloc_unlock> 80244be: e690 b.n 80241e2 <_malloc_r+0x6a> 80244c0: 192a adds r2, r5, r4 80244c2: f043 0301 orr.w r3, r3, #1 80244c6: f044 0401 orr.w r4, r4, #1 80244ca: 4638 mov r0, r7 80244cc: 606c str r4, [r5, #4] 80244ce: f105 0808 add.w r8, r5, #8 80244d2: 6053 str r3, [r2, #4] 80244d4: 60b2 str r2, [r6, #8] 80244d6: f000 f967 bl 80247a8 <__malloc_unlock> 80244da: e682 b.n 80241e2 <_malloc_r+0x6a> 80244dc: 1859 adds r1, r3, r1 80244de: 68da ldr r2, [r3, #12] 80244e0: 689c ldr r4, [r3, #8] 80244e2: 4638 mov r0, r7 80244e4: 684d ldr r5, [r1, #4] 80244e6: f103 0808 add.w r8, r3, #8 80244ea: f045 0501 orr.w r5, r5, #1 80244ee: 60e2 str r2, [r4, #12] 80244f0: 6094 str r4, [r2, #8] 80244f2: 604d str r5, [r1, #4] 80244f4: f000 f958 bl 80247a8 <__malloc_unlock> 80244f8: e673 b.n 80241e2 <_malloc_r+0x6a> 80244fa: f1bc 0f14 cmp.w ip, #20 80244fe: bf9c itt ls 8024500: f10c 0c5b addls.w ip, ip, #91 ; 0x5b 8024504: ea4f 054c movls.w r5, ip, lsl #1 8024508: f67f ae86 bls.w 8024218 <_malloc_r+0xa0> 802450c: f1bc 0f54 cmp.w ip, #84 ; 0x54 8024510: f200 8093 bhi.w 802463a <_malloc_r+0x4c2> 8024514: ea4f 3c14 mov.w ip, r4, lsr #12 8024518: f10c 0c6e add.w ip, ip, #110 ; 0x6e 802451c: ea4f 054c mov.w r5, ip, lsl #1 8024520: e67a b.n 8024218 <_malloc_r+0xa0> 8024522: 0a42 lsrs r2, r0, #9 8024524: 2a04 cmp r2, #4 8024526: d975 bls.n 8024614 <_malloc_r+0x49c> 8024528: 2a14 cmp r2, #20 802452a: bf9c itt ls 802452c: f102 095b addls.w r9, r2, #91 ; 0x5b 8024530: ea4f 0549 movls.w r5, r9, lsl #1 8024534: d908 bls.n 8024548 <_malloc_r+0x3d0> 8024536: 2a54 cmp r2, #84 ; 0x54 8024538: f200 80c9 bhi.w 80246ce <_malloc_r+0x556> 802453c: ea4f 3910 mov.w r9, r0, lsr #12 8024540: f109 096e add.w r9, r9, #110 ; 0x6e 8024544: ea4f 0549 mov.w r5, r9, lsl #1 8024548: eb06 0585 add.w r5, r6, r5, lsl #2 802454c: f240 189c movw r8, #412 ; 0x19c 8024550: f2c2 0800 movt r8, #8192 ; 0x2000 8024554: 68aa ldr r2, [r5, #8] 8024556: 42aa cmp r2, r5 8024558: d079 beq.n 802464e <_malloc_r+0x4d6> 802455a: 6851 ldr r1, [r2, #4] 802455c: f021 0103 bic.w r1, r1, #3 8024560: 4288 cmp r0, r1 8024562: d202 bcs.n 802456a <_malloc_r+0x3f2> 8024564: 6892 ldr r2, [r2, #8] 8024566: 4295 cmp r5, r2 8024568: d1f7 bne.n 802455a <_malloc_r+0x3e2> 802456a: 68d0 ldr r0, [r2, #12] 802456c: f8d6 9004 ldr.w r9, [r6, #4] 8024570: 60d8 str r0, [r3, #12] 8024572: 609a str r2, [r3, #8] 8024574: 60d3 str r3, [r2, #12] 8024576: 6083 str r3, [r0, #8] 8024578: e697 b.n 80242aa <_malloc_r+0x132> 802457a: 191d adds r5, r3, r4 802457c: f041 0601 orr.w r6, r1, #1 8024580: 6155 str r5, [r2, #20] 8024582: f044 0401 orr.w r4, r4, #1 8024586: 6115 str r5, [r2, #16] 8024588: 4638 mov r0, r7 802458a: 605c str r4, [r3, #4] 802458c: f103 0808 add.w r8, r3, #8 8024590: f8c5 e00c str.w lr, [r5, #12] 8024594: f8c5 e008 str.w lr, [r5, #8] 8024598: 606e str r6, [r5, #4] 802459a: 5069 str r1, [r5, r1] 802459c: f000 f904 bl 80247a8 <__malloc_unlock> 80245a0: e61f b.n 80241e2 <_malloc_r+0x6a> 80245a2: f108 0801 add.w r8, r8, #1 80245a6: 3008 adds r0, #8 80245a8: f018 0f03 tst.w r8, #3 80245ac: f47f ae99 bne.w 80242e2 <_malloc_r+0x16a> 80245b0: 464a mov r2, r9 80245b2: f01c 0f03 tst.w ip, #3 80245b6: f1a2 0108 sub.w r1, r2, #8 80245ba: f10c 3cff add.w ip, ip, #4294967295 80245be: f000 809e beq.w 80246fe <_malloc_r+0x586> 80245c2: 6812 ldr r2, [r2, #0] 80245c4: 428a cmp r2, r1 80245c6: d0f4 beq.n 80245b2 <_malloc_r+0x43a> 80245c8: 6872 ldr r2, [r6, #4] 80245ca: 005b lsls r3, r3, #1 80245cc: 4293 cmp r3, r2 80245ce: f63f aec8 bhi.w 8024362 <_malloc_r+0x1ea> 80245d2: 2b00 cmp r3, #0 80245d4: f43f aec5 beq.w 8024362 <_malloc_r+0x1ea> 80245d8: 421a tst r2, r3 80245da: f000 8095 beq.w 8024708 <_malloc_r+0x590> 80245de: 46c4 mov ip, r8 80245e0: e67b b.n 80242da <_malloc_r+0x162> 80245e2: f103 0208 add.w r2, r3, #8 80245e6: 695b ldr r3, [r3, #20] 80245e8: 429a cmp r2, r3 80245ea: bf08 it eq 80245ec: f10c 0c02 addeq.w ip, ip, #2 80245f0: f43f ae2c beq.w 802424c <_malloc_r+0xd4> 80245f4: e5e4 b.n 80241c0 <_malloc_r+0x48> 80245f6: 4690 mov r8, r2 80245f8: 1955 adds r5, r2, r5 80245fa: 68d3 ldr r3, [r2, #12] 80245fc: 4638 mov r0, r7 80245fe: f858 2f08 ldr.w r2, [r8, #8]! 8024602: 6869 ldr r1, [r5, #4] 8024604: 60d3 str r3, [r2, #12] 8024606: f041 0101 orr.w r1, r1, #1 802460a: 609a str r2, [r3, #8] 802460c: 6069 str r1, [r5, #4] 802460e: f000 f8cb bl 80247a8 <__malloc_unlock> 8024612: e5e6 b.n 80241e2 <_malloc_r+0x6a> 8024614: ea4f 1990 mov.w r9, r0, lsr #6 8024618: f109 0938 add.w r9, r9, #56 ; 0x38 802461c: ea4f 0549 mov.w r5, r9, lsl #1 8024620: e792 b.n 8024548 <_malloc_r+0x3d0> 8024622: 42b5 cmp r5, r6 8024624: f240 139c movw r3, #412 ; 0x19c 8024628: f2c2 0300 movt r3, #8192 ; 0x2000 802462c: f43f aec8 beq.w 80243c0 <_malloc_r+0x248> 8024630: 689d ldr r5, [r3, #8] 8024632: 686a ldr r2, [r5, #4] 8024634: f022 0203 bic.w r2, r2, #3 8024638: e736 b.n 80244a8 <_malloc_r+0x330> 802463a: f5bc 7faa cmp.w ip, #340 ; 0x154 802463e: d819 bhi.n 8024674 <_malloc_r+0x4fc> 8024640: ea4f 3cd4 mov.w ip, r4, lsr #15 8024644: f10c 0c77 add.w ip, ip, #119 ; 0x77 8024648: ea4f 054c mov.w r5, ip, lsl #1 802464c: e5e4 b.n 8024218 <_malloc_r+0xa0> 802464e: 2501 movs r5, #1 8024650: f8d8 1004 ldr.w r1, [r8, #4] 8024654: ea4f 09a9 mov.w r9, r9, asr #2 8024658: 4610 mov r0, r2 802465a: fa05 f509 lsl.w r5, r5, r9 802465e: ea45 0901 orr.w r9, r5, r1 8024662: f8c8 9004 str.w r9, [r8, #4] 8024666: e783 b.n 8024570 <_malloc_r+0x3f8> 8024668: 2301 movs r3, #1 802466a: 4645 mov r5, r8 802466c: f8c8 3004 str.w r3, [r8, #4] 8024670: 2200 movs r2, #0 8024672: e719 b.n 80244a8 <_malloc_r+0x330> 8024674: f240 5354 movw r3, #1364 ; 0x554 8024678: 459c cmp ip, r3 802467a: d80b bhi.n 8024694 <_malloc_r+0x51c> 802467c: ea4f 4c94 mov.w ip, r4, lsr #18 8024680: f10c 0c7c add.w ip, ip, #124 ; 0x7c 8024684: ea4f 054c mov.w r5, ip, lsl #1 8024688: e5c6 b.n 8024218 <_malloc_r+0xa0> 802468a: 68b5 ldr r5, [r6, #8] 802468c: 686a ldr r2, [r5, #4] 802468e: f022 0203 bic.w r2, r2, #3 8024692: e709 b.n 80244a8 <_malloc_r+0x330> 8024694: 25fc movs r5, #252 ; 0xfc 8024696: f04f 0c7e mov.w ip, #126 ; 0x7e 802469a: e5bd b.n 8024218 <_malloc_r+0xa0> 802469c: 0511 lsls r1, r2, #20 802469e: 0d09 lsrs r1, r1, #20 80246a0: 2900 cmp r1, #0 80246a2: f47f ae95 bne.w 80243d0 <_malloc_r+0x258> 80246a6: 68b2 ldr r2, [r6, #8] 80246a8: eb0b 010a add.w r1, fp, sl 80246ac: f041 0101 orr.w r1, r1, #1 80246b0: 6051 str r1, [r2, #4] 80246b2: e6e3 b.n 802447c <_malloc_r+0x304> 80246b4: 2101 movs r1, #1 80246b6: f04f 0b00 mov.w fp, #0 80246ba: e6b7 b.n 802442c <_malloc_r+0x2b4> 80246bc: 4638 mov r0, r7 80246be: f105 0108 add.w r1, r5, #8 80246c2: 9201 str r2, [sp, #4] 80246c4: f7ff f822 bl 802370c <_free_r> 80246c8: 9a01 ldr r2, [sp, #4] 80246ca: 6853 ldr r3, [r2, #4] 80246cc: e6d6 b.n 802447c <_malloc_r+0x304> 80246ce: f5b2 7faa cmp.w r2, #340 ; 0x154 80246d2: d806 bhi.n 80246e2 <_malloc_r+0x56a> 80246d4: ea4f 39d0 mov.w r9, r0, lsr #15 80246d8: f109 0977 add.w r9, r9, #119 ; 0x77 80246dc: ea4f 0549 mov.w r5, r9, lsl #1 80246e0: e732 b.n 8024548 <_malloc_r+0x3d0> 80246e2: f240 5154 movw r1, #1364 ; 0x554 80246e6: 25fc movs r5, #252 ; 0xfc 80246e8: 428a cmp r2, r1 80246ea: f04f 097e mov.w r9, #126 ; 0x7e 80246ee: bf9e ittt ls 80246f0: ea4f 4990 movls.w r9, r0, lsr #18 80246f4: f109 097c addls.w r9, r9, #124 ; 0x7c 80246f8: ea4f 0549 movls.w r5, r9, lsl #1 80246fc: e724 b.n 8024548 <_malloc_r+0x3d0> 80246fe: 6872 ldr r2, [r6, #4] 8024700: ea22 0203 bic.w r2, r2, r3 8024704: 6072 str r2, [r6, #4] 8024706: e760 b.n 80245ca <_malloc_r+0x452> 8024708: 005b lsls r3, r3, #1 802470a: f108 0804 add.w r8, r8, #4 802470e: e763 b.n 80245d8 <_malloc_r+0x460> 08024710 : 8024710: 0783 lsls r3, r0, #30 8024712: b2c9 uxtb r1, r1 8024714: b470 push {r4, r5, r6} 8024716: d040 beq.n 802479a 8024718: 1e54 subs r4, r2, #1 802471a: 2a00 cmp r2, #0 802471c: d03f beq.n 802479e 802471e: 7803 ldrb r3, [r0, #0] 8024720: 428b cmp r3, r1 8024722: d021 beq.n 8024768 8024724: 1c43 adds r3, r0, #1 8024726: e004 b.n 8024732 8024728: b304 cbz r4, 802476c 802472a: 7802 ldrb r2, [r0, #0] 802472c: 3c01 subs r4, #1 802472e: 428a cmp r2, r1 8024730: d01a beq.n 8024768 8024732: f013 0f03 tst.w r3, #3 8024736: 4618 mov r0, r3 8024738: f103 0301 add.w r3, r3, #1 802473c: d1f4 bne.n 8024728 802473e: 2c03 cmp r4, #3 8024740: d816 bhi.n 8024770 8024742: 1e65 subs r5, r4, #1 8024744: b194 cbz r4, 802476c 8024746: 7803 ldrb r3, [r0, #0] 8024748: 428b cmp r3, r1 802474a: d00d beq.n 8024768 802474c: 1c42 adds r2, r0, #1 802474e: 2300 movs r3, #0 8024750: e002 b.n 8024758 8024752: 7804 ldrb r4, [r0, #0] 8024754: 428c cmp r4, r1 8024756: d007 beq.n 8024768 8024758: 429d cmp r5, r3 802475a: 4610 mov r0, r2 802475c: f103 0301 add.w r3, r3, #1 8024760: f102 0201 add.w r2, r2, #1 8024764: d1f5 bne.n 8024752 8024766: 2000 movs r0, #0 8024768: bc70 pop {r4, r5, r6} 802476a: 4770 bx lr 802476c: 4620 mov r0, r4 802476e: e7fb b.n 8024768 8024770: ea41 2601 orr.w r6, r1, r1, lsl #8 8024774: ea46 4606 orr.w r6, r6, r6, lsl #16 8024778: 4602 mov r2, r0 802477a: 3004 adds r0, #4 802477c: 6813 ldr r3, [r2, #0] 802477e: 4073 eors r3, r6 8024780: f1a3 3501 sub.w r5, r3, #16843009 ; 0x1010101 8024784: ea25 0303 bic.w r3, r5, r3 8024788: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 802478c: d103 bne.n 8024796 802478e: 3c04 subs r4, #4 8024790: 2c03 cmp r4, #3 8024792: d8f1 bhi.n 8024778 8024794: e7d5 b.n 8024742 8024796: 4610 mov r0, r2 8024798: e7d3 b.n 8024742 802479a: 4614 mov r4, r2 802479c: e7cf b.n 802473e 802479e: 4610 mov r0, r2 80247a0: e7e2 b.n 8024768 80247a2: bf00 nop 080247a4 <__malloc_lock>: 80247a4: 4770 bx lr 80247a6: bf00 nop 080247a8 <__malloc_unlock>: 80247a8: 4770 bx lr 80247aa: bf00 nop 080247ac <_Balloc>: 80247ac: b570 push {r4, r5, r6, lr} 80247ae: 4606 mov r6, r0 80247b0: 6a44 ldr r4, [r0, #36] ; 0x24 80247b2: 460d mov r5, r1 80247b4: b15c cbz r4, 80247ce <_Balloc+0x22> 80247b6: 68e2 ldr r2, [r4, #12] 80247b8: b19a cbz r2, 80247e2 <_Balloc+0x36> 80247ba: f852 0025 ldr.w r0, [r2, r5, lsl #2] 80247be: b1e0 cbz r0, 80247fa <_Balloc+0x4e> 80247c0: 6801 ldr r1, [r0, #0] 80247c2: f842 1025 str.w r1, [r2, r5, lsl #2] 80247c6: 2200 movs r2, #0 80247c8: 6102 str r2, [r0, #16] 80247ca: 60c2 str r2, [r0, #12] 80247cc: bd70 pop {r4, r5, r6, pc} 80247ce: 2010 movs r0, #16 80247d0: f7ff fcc2 bl 8024158 80247d4: 2300 movs r3, #0 80247d6: 4604 mov r4, r0 80247d8: 6270 str r0, [r6, #36] ; 0x24 80247da: 6043 str r3, [r0, #4] 80247dc: 6083 str r3, [r0, #8] 80247de: 6003 str r3, [r0, #0] 80247e0: 60c3 str r3, [r0, #12] 80247e2: 2221 movs r2, #33 ; 0x21 80247e4: 4630 mov r0, r6 80247e6: 2104 movs r1, #4 80247e8: f000 fcfc bl 80251e4 <_calloc_r> 80247ec: 6a73 ldr r3, [r6, #36] ; 0x24 80247ee: 60e0 str r0, [r4, #12] 80247f0: 68da ldr r2, [r3, #12] 80247f2: 2a00 cmp r2, #0 80247f4: d1e1 bne.n 80247ba <_Balloc+0xe> 80247f6: 2000 movs r0, #0 80247f8: bd70 pop {r4, r5, r6, pc} 80247fa: 2301 movs r3, #1 80247fc: 4630 mov r0, r6 80247fe: 4619 mov r1, r3 8024800: fa03 f405 lsl.w r4, r3, r5 8024804: 1d62 adds r2, r4, #5 8024806: 0092 lsls r2, r2, #2 8024808: f000 fcec bl 80251e4 <_calloc_r> 802480c: 2800 cmp r0, #0 802480e: d0f2 beq.n 80247f6 <_Balloc+0x4a> 8024810: 6045 str r5, [r0, #4] 8024812: 6084 str r4, [r0, #8] 8024814: e7d7 b.n 80247c6 <_Balloc+0x1a> 8024816: bf00 nop 08024818 <_Bfree>: 8024818: b530 push {r4, r5, lr} 802481a: 4604 mov r4, r0 802481c: 6a45 ldr r5, [r0, #36] ; 0x24 802481e: b083 sub sp, #12 8024820: b155 cbz r5, 8024838 <_Bfree+0x20> 8024822: b139 cbz r1, 8024834 <_Bfree+0x1c> 8024824: 6a63 ldr r3, [r4, #36] ; 0x24 8024826: 684a ldr r2, [r1, #4] 8024828: 68db ldr r3, [r3, #12] 802482a: f853 0022 ldr.w r0, [r3, r2, lsl #2] 802482e: 6008 str r0, [r1, #0] 8024830: f843 1022 str.w r1, [r3, r2, lsl #2] 8024834: b003 add sp, #12 8024836: bd30 pop {r4, r5, pc} 8024838: 2010 movs r0, #16 802483a: 9101 str r1, [sp, #4] 802483c: f7ff fc8c bl 8024158 8024840: 9901 ldr r1, [sp, #4] 8024842: 6260 str r0, [r4, #36] ; 0x24 8024844: 6045 str r5, [r0, #4] 8024846: 6085 str r5, [r0, #8] 8024848: 6005 str r5, [r0, #0] 802484a: 60c5 str r5, [r0, #12] 802484c: e7e9 b.n 8024822 <_Bfree+0xa> 802484e: bf00 nop 08024850 <__multadd>: 8024850: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 8024854: 4688 mov r8, r1 8024856: f8d1 a010 ldr.w sl, [r1, #16] 802485a: b082 sub sp, #8 802485c: 4681 mov r9, r0 802485e: f101 0514 add.w r5, r1, #20 8024862: 2400 movs r4, #0 8024864: 682f ldr r7, [r5, #0] 8024866: 3401 adds r4, #1 8024868: b2be uxth r6, r7 802486a: 0c3f lsrs r7, r7, #16 802486c: fb02 3606 mla r6, r2, r6, r3 8024870: fb02 f307 mul.w r3, r2, r7 8024874: eb03 4316 add.w r3, r3, r6, lsr #16 8024878: b2b6 uxth r6, r6 802487a: eb06 4603 add.w r6, r6, r3, lsl #16 802487e: 0c1b lsrs r3, r3, #16 8024880: 45a2 cmp sl, r4 8024882: f845 6b04 str.w r6, [r5], #4 8024886: dced bgt.n 8024864 <__multadd+0x14> 8024888: b153 cbz r3, 80248a0 <__multadd+0x50> 802488a: f8d8 2008 ldr.w r2, [r8, #8] 802488e: 4592 cmp sl, r2 8024890: da0a bge.n 80248a8 <__multadd+0x58> 8024892: eb08 028a add.w r2, r8, sl, lsl #2 8024896: f10a 0101 add.w r1, sl, #1 802489a: f8c8 1010 str.w r1, [r8, #16] 802489e: 6153 str r3, [r2, #20] 80248a0: 4640 mov r0, r8 80248a2: b002 add sp, #8 80248a4: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 80248a8: f8d8 1004 ldr.w r1, [r8, #4] 80248ac: 4648 mov r0, r9 80248ae: 9301 str r3, [sp, #4] 80248b0: 3101 adds r1, #1 80248b2: f7ff ff7b bl 80247ac <_Balloc> 80248b6: f8d8 2010 ldr.w r2, [r8, #16] 80248ba: f108 010c add.w r1, r8, #12 80248be: 3202 adds r2, #2 80248c0: 0092 lsls r2, r2, #2 80248c2: 4604 mov r4, r0 80248c4: 300c adds r0, #12 80248c6: f7fd f841 bl 802194c 80248ca: 4641 mov r1, r8 80248cc: 4648 mov r0, r9 80248ce: 46a0 mov r8, r4 80248d0: f7ff ffa2 bl 8024818 <_Bfree> 80248d4: 9b01 ldr r3, [sp, #4] 80248d6: e7dc b.n 8024892 <__multadd+0x42> 080248d8 <__s2b>: 80248d8: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 80248dc: f648 6539 movw r5, #36409 ; 0x8e39 80248e0: 461f mov r7, r3 80248e2: f6c3 05e3 movt r5, #14563 ; 0x38e3 80248e6: 3308 adds r3, #8 80248e8: 4606 mov r6, r0 80248ea: 460c mov r4, r1 80248ec: 4690 mov r8, r2 80248ee: fb85 1003 smull r1, r0, r5, r3 80248f2: 17db asrs r3, r3, #31 80248f4: ebc3 0060 rsb r0, r3, r0, asr #1 80248f8: 2801 cmp r0, #1 80248fa: dd37 ble.n 802496c <__s2b+0x94> 80248fc: 2501 movs r5, #1 80248fe: 2100 movs r1, #0 8024900: 006d lsls r5, r5, #1 8024902: 3101 adds r1, #1 8024904: 42a8 cmp r0, r5 8024906: dcfb bgt.n 8024900 <__s2b+0x28> 8024908: 4630 mov r0, r6 802490a: f7ff ff4f bl 80247ac <_Balloc> 802490e: 9b08 ldr r3, [sp, #32] 8024910: 6143 str r3, [r0, #20] 8024912: 2301 movs r3, #1 8024914: f1b8 0f09 cmp.w r8, #9 8024918: 4601 mov r1, r0 802491a: 6103 str r3, [r0, #16] 802491c: dd22 ble.n 8024964 <__s2b+0x8c> 802491e: f104 0909 add.w r9, r4, #9 8024922: 4444 add r4, r8 8024924: 464d mov r5, r9 8024926: f815 3b01 ldrb.w r3, [r5], #1 802492a: 220a movs r2, #10 802492c: 4630 mov r0, r6 802492e: 3b30 subs r3, #48 ; 0x30 8024930: f7ff ff8e bl 8024850 <__multadd> 8024934: 42a5 cmp r5, r4 8024936: 4601 mov r1, r0 8024938: d1f5 bne.n 8024926 <__s2b+0x4e> 802493a: eb09 0408 add.w r4, r9, r8 802493e: 3c08 subs r4, #8 8024940: 4547 cmp r7, r8 8024942: dd0c ble.n 802495e <__s2b+0x86> 8024944: ebc8 0707 rsb r7, r8, r7 8024948: 19e7 adds r7, r4, r7 802494a: f814 3b01 ldrb.w r3, [r4], #1 802494e: 220a movs r2, #10 8024950: 4630 mov r0, r6 8024952: 3b30 subs r3, #48 ; 0x30 8024954: f7ff ff7c bl 8024850 <__multadd> 8024958: 42bc cmp r4, r7 802495a: 4601 mov r1, r0 802495c: d1f5 bne.n 802494a <__s2b+0x72> 802495e: 4608 mov r0, r1 8024960: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 8024964: 340a adds r4, #10 8024966: f04f 0809 mov.w r8, #9 802496a: e7e9 b.n 8024940 <__s2b+0x68> 802496c: 2100 movs r1, #0 802496e: e7cb b.n 8024908 <__s2b+0x30> 08024970 <__hi0bits>: 8024970: 4603 mov r3, r0 8024972: 2000 movs r0, #0 8024974: 0c1a lsrs r2, r3, #16 8024976: d101 bne.n 802497c <__hi0bits+0xc> 8024978: 041b lsls r3, r3, #16 802497a: 2010 movs r0, #16 802497c: f013 4f7f tst.w r3, #4278190080 ; 0xff000000 8024980: d101 bne.n 8024986 <__hi0bits+0x16> 8024982: 3008 adds r0, #8 8024984: 021b lsls r3, r3, #8 8024986: f013 4f70 tst.w r3, #4026531840 ; 0xf0000000 802498a: d101 bne.n 8024990 <__hi0bits+0x20> 802498c: 3004 adds r0, #4 802498e: 011b lsls r3, r3, #4 8024990: f013 4f40 tst.w r3, #3221225472 ; 0xc0000000 8024994: d101 bne.n 802499a <__hi0bits+0x2a> 8024996: 3002 adds r0, #2 8024998: 009b lsls r3, r3, #2 802499a: 2b00 cmp r3, #0 802499c: db02 blt.n 80249a4 <__hi0bits+0x34> 802499e: 005b lsls r3, r3, #1 80249a0: d401 bmi.n 80249a6 <__hi0bits+0x36> 80249a2: 2020 movs r0, #32 80249a4: 4770 bx lr 80249a6: 3001 adds r0, #1 80249a8: 4770 bx lr 80249aa: bf00 nop 080249ac <__lo0bits>: 80249ac: 6803 ldr r3, [r0, #0] 80249ae: 4602 mov r2, r0 80249b0: f013 0007 ands.w r0, r3, #7 80249b4: d007 beq.n 80249c6 <__lo0bits+0x1a> 80249b6: 07d9 lsls r1, r3, #31 80249b8: d41f bmi.n 80249fa <__lo0bits+0x4e> 80249ba: 0798 lsls r0, r3, #30 80249bc: d41f bmi.n 80249fe <__lo0bits+0x52> 80249be: 089b lsrs r3, r3, #2 80249c0: 2002 movs r0, #2 80249c2: 6013 str r3, [r2, #0] 80249c4: 4770 bx lr 80249c6: b299 uxth r1, r3 80249c8: b909 cbnz r1, 80249ce <__lo0bits+0x22> 80249ca: 0c1b lsrs r3, r3, #16 80249cc: 2010 movs r0, #16 80249ce: f013 0fff tst.w r3, #255 ; 0xff 80249d2: d101 bne.n 80249d8 <__lo0bits+0x2c> 80249d4: 3008 adds r0, #8 80249d6: 0a1b lsrs r3, r3, #8 80249d8: 0719 lsls r1, r3, #28 80249da: d101 bne.n 80249e0 <__lo0bits+0x34> 80249dc: 3004 adds r0, #4 80249de: 091b lsrs r3, r3, #4 80249e0: 0799 lsls r1, r3, #30 80249e2: d101 bne.n 80249e8 <__lo0bits+0x3c> 80249e4: 3002 adds r0, #2 80249e6: 089b lsrs r3, r3, #2 80249e8: 07d9 lsls r1, r3, #31 80249ea: d404 bmi.n 80249f6 <__lo0bits+0x4a> 80249ec: 085b lsrs r3, r3, #1 80249ee: d101 bne.n 80249f4 <__lo0bits+0x48> 80249f0: 2020 movs r0, #32 80249f2: 4770 bx lr 80249f4: 3001 adds r0, #1 80249f6: 6013 str r3, [r2, #0] 80249f8: 4770 bx lr 80249fa: 2000 movs r0, #0 80249fc: 4770 bx lr 80249fe: 085b lsrs r3, r3, #1 8024a00: 2001 movs r0, #1 8024a02: 6013 str r3, [r2, #0] 8024a04: 4770 bx lr 8024a06: bf00 nop 08024a08 <__i2b>: 8024a08: b510 push {r4, lr} 8024a0a: 460c mov r4, r1 8024a0c: 2101 movs r1, #1 8024a0e: f7ff fecd bl 80247ac <_Balloc> 8024a12: 2201 movs r2, #1 8024a14: 6144 str r4, [r0, #20] 8024a16: 6102 str r2, [r0, #16] 8024a18: bd10 pop {r4, pc} 8024a1a: bf00 nop 08024a1c <__multiply>: 8024a1c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8024a20: 460c mov r4, r1 8024a22: 690e ldr r6, [r1, #16] 8024a24: b085 sub sp, #20 8024a26: 6915 ldr r5, [r2, #16] 8024a28: 4617 mov r7, r2 8024a2a: 42ae cmp r6, r5 8024a2c: da04 bge.n 8024a38 <__multiply+0x1c> 8024a2e: 4632 mov r2, r6 8024a30: 463c mov r4, r7 8024a32: 462e mov r6, r5 8024a34: 460f mov r7, r1 8024a36: 4615 mov r5, r2 8024a38: 68a3 ldr r3, [r4, #8] 8024a3a: eb06 0805 add.w r8, r6, r5 8024a3e: 6861 ldr r1, [r4, #4] 8024a40: 4598 cmp r8, r3 8024a42: bfc8 it gt 8024a44: 3101 addgt r1, #1 8024a46: f7ff feb1 bl 80247ac <_Balloc> 8024a4a: eb00 0988 add.w r9, r0, r8, lsl #2 8024a4e: f100 0314 add.w r3, r0, #20 8024a52: f109 0914 add.w r9, r9, #20 8024a56: 9001 str r0, [sp, #4] 8024a58: 2000 movs r0, #0 8024a5a: 454b cmp r3, r9 8024a5c: d203 bcs.n 8024a66 <__multiply+0x4a> 8024a5e: f843 0b04 str.w r0, [r3], #4 8024a62: 4599 cmp r9, r3 8024a64: d8fb bhi.n 8024a5e <__multiply+0x42> 8024a66: eb07 0585 add.w r5, r7, r5, lsl #2 8024a6a: eb04 0686 add.w r6, r4, r6, lsl #2 8024a6e: 3714 adds r7, #20 8024a70: 3514 adds r5, #20 8024a72: 3414 adds r4, #20 8024a74: 3614 adds r6, #20 8024a76: 42af cmp r7, r5 8024a78: d257 bcs.n 8024b2a <__multiply+0x10e> 8024a7a: 9a01 ldr r2, [sp, #4] 8024a7c: f8cd 9008 str.w r9, [sp, #8] 8024a80: 46a9 mov r9, r5 8024a82: f8cd 800c str.w r8, [sp, #12] 8024a86: f102 0c18 add.w ip, r2, #24 8024a8a: 46a0 mov r8, r4 8024a8c: f857 4b04 ldr.w r4, [r7], #4 8024a90: b2a0 uxth r0, r4 8024a92: b1f0 cbz r0, 8024ad2 <__multiply+0xb6> 8024a94: 4642 mov r2, r8 8024a96: f1ac 0304 sub.w r3, ip, #4 8024a9a: 2400 movs r4, #0 8024a9c: f852 1b04 ldr.w r1, [r2], #4 8024aa0: 681d ldr r5, [r3, #0] 8024aa2: fa1f fa81 uxth.w sl, r1 8024aa6: 0c09 lsrs r1, r1, #16 8024aa8: fa1f fb85 uxth.w fp, r5 8024aac: 0c2d lsrs r5, r5, #16 8024aae: fb00 ba0a mla sl, r0, sl, fp 8024ab2: fb00 5101 mla r1, r0, r1, r5 8024ab6: 4454 add r4, sl 8024ab8: eb01 4114 add.w r1, r1, r4, lsr #16 8024abc: b2a4 uxth r4, r4 8024abe: ea44 4501 orr.w r5, r4, r1, lsl #16 8024ac2: 0c0c lsrs r4, r1, #16 8024ac4: 4296 cmp r6, r2 8024ac6: f843 5b04 str.w r5, [r3], #4 8024aca: d8e7 bhi.n 8024a9c <__multiply+0x80> 8024acc: 601c str r4, [r3, #0] 8024ace: f857 4c04 ldr.w r4, [r7, #-4] 8024ad2: 0c24 lsrs r4, r4, #16 8024ad4: d021 beq.n 8024b1a <__multiply+0xfe> 8024ad6: f85c 1c04 ldr.w r1, [ip, #-4] 8024ada: 4642 mov r2, r8 8024adc: 4663 mov r3, ip 8024ade: 2500 movs r5, #0 8024ae0: 4608 mov r0, r1 8024ae2: f8b2 a000 ldrh.w sl, [r2] 8024ae6: 0c00 lsrs r0, r0, #16 8024ae8: b289 uxth r1, r1 8024aea: 469b mov fp, r3 8024aec: fb04 000a mla r0, r4, sl, r0 8024af0: 1945 adds r5, r0, r5 8024af2: ea41 4105 orr.w r1, r1, r5, lsl #16 8024af6: f843 1c04 str.w r1, [r3, #-4] 8024afa: f853 0b04 ldr.w r0, [r3], #4 8024afe: f852 1b04 ldr.w r1, [r2], #4 8024b02: fa1f fa80 uxth.w sl, r0 8024b06: 0c09 lsrs r1, r1, #16 8024b08: fb04 a101 mla r1, r4, r1, sl 8024b0c: eb01 4115 add.w r1, r1, r5, lsr #16 8024b10: 0c0d lsrs r5, r1, #16 8024b12: 4296 cmp r6, r2 8024b14: d8e5 bhi.n 8024ae2 <__multiply+0xc6> 8024b16: f8cb 1000 str.w r1, [fp] 8024b1a: 45b9 cmp r9, r7 8024b1c: f10c 0c04 add.w ip, ip, #4 8024b20: d8b4 bhi.n 8024a8c <__multiply+0x70> 8024b22: f8dd 9008 ldr.w r9, [sp, #8] 8024b26: f8dd 800c ldr.w r8, [sp, #12] 8024b2a: f1b8 0f00 cmp.w r8, #0 8024b2e: dd0b ble.n 8024b48 <__multiply+0x12c> 8024b30: f859 3c04 ldr.w r3, [r9, #-4] 8024b34: f1a9 0904 sub.w r9, r9, #4 8024b38: b11b cbz r3, 8024b42 <__multiply+0x126> 8024b3a: e005 b.n 8024b48 <__multiply+0x12c> 8024b3c: f859 3d04 ldr.w r3, [r9, #-4]! 8024b40: b913 cbnz r3, 8024b48 <__multiply+0x12c> 8024b42: f1b8 0801 subs.w r8, r8, #1 8024b46: d1f9 bne.n 8024b3c <__multiply+0x120> 8024b48: 9b01 ldr r3, [sp, #4] 8024b4a: 4618 mov r0, r3 8024b4c: f8c3 8010 str.w r8, [r3, #16] 8024b50: b005 add sp, #20 8024b52: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 8024b56: bf00 nop 08024b58 <__pow5mult>: 8024b58: f012 0303 ands.w r3, r2, #3 8024b5c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8024b60: 4614 mov r4, r2 8024b62: 4680 mov r8, r0 8024b64: 460f mov r7, r1 8024b66: d128 bne.n 8024bba <__pow5mult+0x62> 8024b68: 10a4 asrs r4, r4, #2 8024b6a: d01a beq.n 8024ba2 <__pow5mult+0x4a> 8024b6c: f8d8 5024 ldr.w r5, [r8, #36] ; 0x24 8024b70: 2d00 cmp r5, #0 8024b72: d02e beq.n 8024bd2 <__pow5mult+0x7a> 8024b74: 68ae ldr r6, [r5, #8] 8024b76: b92e cbnz r6, 8024b84 <__pow5mult+0x2c> 8024b78: e036 b.n 8024be8 <__pow5mult+0x90> 8024b7a: 1064 asrs r4, r4, #1 8024b7c: d011 beq.n 8024ba2 <__pow5mult+0x4a> 8024b7e: 6835 ldr r5, [r6, #0] 8024b80: b195 cbz r5, 8024ba8 <__pow5mult+0x50> 8024b82: 462e mov r6, r5 8024b84: 07e0 lsls r0, r4, #31 8024b86: d5f8 bpl.n 8024b7a <__pow5mult+0x22> 8024b88: 4639 mov r1, r7 8024b8a: 4632 mov r2, r6 8024b8c: 4640 mov r0, r8 8024b8e: f7ff ff45 bl 8024a1c <__multiply> 8024b92: 4639 mov r1, r7 8024b94: 4605 mov r5, r0 8024b96: 4640 mov r0, r8 8024b98: f7ff fe3e bl 8024818 <_Bfree> 8024b9c: 1064 asrs r4, r4, #1 8024b9e: 462f mov r7, r5 8024ba0: d1ed bne.n 8024b7e <__pow5mult+0x26> 8024ba2: 4638 mov r0, r7 8024ba4: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8024ba8: 4631 mov r1, r6 8024baa: 4632 mov r2, r6 8024bac: 4640 mov r0, r8 8024bae: f7ff ff35 bl 8024a1c <__multiply> 8024bb2: 6030 str r0, [r6, #0] 8024bb4: 4606 mov r6, r0 8024bb6: 6005 str r5, [r0, #0] 8024bb8: e7e4 b.n 8024b84 <__pow5mult+0x2c> 8024bba: f645 4208 movw r2, #23560 ; 0x5c08 8024bbe: 1e5d subs r5, r3, #1 8024bc0: f6c0 0203 movt r2, #2051 ; 0x803 8024bc4: 2300 movs r3, #0 8024bc6: f852 2025 ldr.w r2, [r2, r5, lsl #2] 8024bca: f7ff fe41 bl 8024850 <__multadd> 8024bce: 4607 mov r7, r0 8024bd0: e7ca b.n 8024b68 <__pow5mult+0x10> 8024bd2: 2010 movs r0, #16 8024bd4: f7ff fac0 bl 8024158 8024bd8: 2300 movs r3, #0 8024bda: 4605 mov r5, r0 8024bdc: f8c8 0024 str.w r0, [r8, #36] ; 0x24 8024be0: 6043 str r3, [r0, #4] 8024be2: 6083 str r3, [r0, #8] 8024be4: 6003 str r3, [r0, #0] 8024be6: 60c3 str r3, [r0, #12] 8024be8: 4640 mov r0, r8 8024bea: f240 2171 movw r1, #625 ; 0x271 8024bee: f7ff ff0b bl 8024a08 <__i2b> 8024bf2: 2300 movs r3, #0 8024bf4: 60a8 str r0, [r5, #8] 8024bf6: 4606 mov r6, r0 8024bf8: 6003 str r3, [r0, #0] 8024bfa: e7c3 b.n 8024b84 <__pow5mult+0x2c> 08024bfc <__lshift>: 8024bfc: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} 8024c00: 4693 mov fp, r2 8024c02: 690a ldr r2, [r1, #16] 8024c04: 460f mov r7, r1 8024c06: ea4f 156b mov.w r5, fp, asr #5 8024c0a: 688b ldr r3, [r1, #8] 8024c0c: eb05 0a02 add.w sl, r5, r2 8024c10: 4681 mov r9, r0 8024c12: f10a 0601 add.w r6, sl, #1 8024c16: 6849 ldr r1, [r1, #4] 8024c18: 429e cmp r6, r3 8024c1a: dd03 ble.n 8024c24 <__lshift+0x28> 8024c1c: 005b lsls r3, r3, #1 8024c1e: 3101 adds r1, #1 8024c20: 429e cmp r6, r3 8024c22: dcfb bgt.n 8024c1c <__lshift+0x20> 8024c24: 4648 mov r0, r9 8024c26: f7ff fdc1 bl 80247ac <_Balloc> 8024c2a: 2d00 cmp r5, #0 8024c2c: 4680 mov r8, r0 8024c2e: f100 0414 add.w r4, r0, #20 8024c32: dd0a ble.n 8024c4a <__lshift+0x4e> 8024c34: 2300 movs r3, #0 8024c36: 461a mov r2, r3 8024c38: 3301 adds r3, #1 8024c3a: f844 2b04 str.w r2, [r4], #4 8024c3e: 42ab cmp r3, r5 8024c40: d1fa bne.n 8024c38 <__lshift+0x3c> 8024c42: eb08 0383 add.w r3, r8, r3, lsl #2 8024c46: f103 0414 add.w r4, r3, #20 8024c4a: 6938 ldr r0, [r7, #16] 8024c4c: f107 0514 add.w r5, r7, #20 8024c50: eb07 0080 add.w r0, r7, r0, lsl #2 8024c54: 3014 adds r0, #20 8024c56: f01b 0b1f ands.w fp, fp, #31 8024c5a: d01c beq.n 8024c96 <__lshift+0x9a> 8024c5c: f1cb 0320 rsb r3, fp, #32 8024c60: 2200 movs r2, #0 8024c62: 6829 ldr r1, [r5, #0] 8024c64: fa01 f10b lsl.w r1, r1, fp 8024c68: 430a orrs r2, r1 8024c6a: f844 2b04 str.w r2, [r4], #4 8024c6e: f855 2b04 ldr.w r2, [r5], #4 8024c72: 42a8 cmp r0, r5 8024c74: fa22 f203 lsr.w r2, r2, r3 8024c78: d8f3 bhi.n 8024c62 <__lshift+0x66> 8024c7a: 6022 str r2, [r4, #0] 8024c7c: b10a cbz r2, 8024c82 <__lshift+0x86> 8024c7e: f10a 0602 add.w r6, sl, #2 8024c82: 4648 mov r0, r9 8024c84: 3e01 subs r6, #1 8024c86: 4639 mov r1, r7 8024c88: f8c8 6010 str.w r6, [r8, #16] 8024c8c: f7ff fdc4 bl 8024818 <_Bfree> 8024c90: 4640 mov r0, r8 8024c92: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 8024c96: f855 3b04 ldr.w r3, [r5], #4 8024c9a: 42a8 cmp r0, r5 8024c9c: f844 3b04 str.w r3, [r4], #4 8024ca0: d9ef bls.n 8024c82 <__lshift+0x86> 8024ca2: f855 3b04 ldr.w r3, [r5], #4 8024ca6: 42a8 cmp r0, r5 8024ca8: f844 3b04 str.w r3, [r4], #4 8024cac: d8f3 bhi.n 8024c96 <__lshift+0x9a> 8024cae: e7e8 b.n 8024c82 <__lshift+0x86> 08024cb0 <__mcmp>: 8024cb0: 4603 mov r3, r0 8024cb2: 690a ldr r2, [r1, #16] 8024cb4: 6900 ldr r0, [r0, #16] 8024cb6: b430 push {r4, r5} 8024cb8: 1a80 subs r0, r0, r2 8024cba: d10f bne.n 8024cdc <__mcmp+0x2c> 8024cbc: 3204 adds r2, #4 8024cbe: f103 0514 add.w r5, r3, #20 8024cc2: 0092 lsls r2, r2, #2 8024cc4: 189b adds r3, r3, r2 8024cc6: 1889 adds r1, r1, r2 8024cc8: 3304 adds r3, #4 8024cca: 3104 adds r1, #4 8024ccc: f853 2d04 ldr.w r2, [r3, #-4]! 8024cd0: f851 4d04 ldr.w r4, [r1, #-4]! 8024cd4: 42a2 cmp r2, r4 8024cd6: d103 bne.n 8024ce0 <__mcmp+0x30> 8024cd8: 429d cmp r5, r3 8024cda: d3f7 bcc.n 8024ccc <__mcmp+0x1c> 8024cdc: bc30 pop {r4, r5} 8024cde: 4770 bx lr 8024ce0: 4294 cmp r4, r2 8024ce2: bf94 ite ls 8024ce4: 2001 movls r0, #1 8024ce6: f04f 30ff movhi.w r0, #4294967295 8024cea: e7f7 b.n 8024cdc <__mcmp+0x2c> 08024cec <__mdiff>: 8024cec: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} 8024cf0: 468b mov fp, r1 8024cf2: 4604 mov r4, r0 8024cf4: 4611 mov r1, r2 8024cf6: 4658 mov r0, fp 8024cf8: 4691 mov r9, r2 8024cfa: f7ff ffd9 bl 8024cb0 <__mcmp> 8024cfe: 1e05 subs r5, r0, #0 8024d00: d061 beq.n 8024dc6 <__mdiff+0xda> 8024d02: bfbc itt lt 8024d04: 465b movlt r3, fp 8024d06: 46cb movlt fp, r9 8024d08: 4620 mov r0, r4 8024d0a: bfb8 it lt 8024d0c: 4699 movlt r9, r3 8024d0e: f8db 1004 ldr.w r1, [fp, #4] 8024d12: bfac ite ge 8024d14: f04f 0800 movge.w r8, #0 8024d18: f04f 0801 movlt.w r8, #1 8024d1c: f7ff fd46 bl 80247ac <_Balloc> 8024d20: f8db 7010 ldr.w r7, [fp, #16] 8024d24: f109 0514 add.w r5, r9, #20 8024d28: f8d9 3010 ldr.w r3, [r9, #16] 8024d2c: f10b 0614 add.w r6, fp, #20 8024d30: 2400 movs r4, #0 8024d32: eb0b 0c87 add.w ip, fp, r7, lsl #2 8024d36: eb09 0983 add.w r9, r9, r3, lsl #2 8024d3a: f10c 0c14 add.w ip, ip, #20 8024d3e: f109 0914 add.w r9, r9, #20 8024d42: f100 0a14 add.w sl, r0, #20 8024d46: f8c0 800c str.w r8, [r0, #12] 8024d4a: f856 8b04 ldr.w r8, [r6], #4 8024d4e: 4653 mov r3, sl 8024d50: f855 ab04 ldr.w sl, [r5], #4 8024d54: 4632 mov r2, r6 8024d56: fa1f f188 uxth.w r1, r8 8024d5a: 1909 adds r1, r1, r4 8024d5c: fa1f fb8a uxth.w fp, sl 8024d60: ebcb 0101 rsb r1, fp, r1 8024d64: ea4f 441a mov.w r4, sl, lsr #16 8024d68: ebc4 4418 rsb r4, r4, r8, lsr #16 8024d6c: eb04 4421 add.w r4, r4, r1, asr #16 8024d70: b289 uxth r1, r1 8024d72: ea41 4104 orr.w r1, r1, r4, lsl #16 8024d76: 1424 asrs r4, r4, #16 8024d78: 45a9 cmp r9, r5 8024d7a: f843 1b04 str.w r1, [r3], #4 8024d7e: 469a mov sl, r3 8024d80: d8e3 bhi.n 8024d4a <__mdiff+0x5e> 8024d82: 45b4 cmp ip, r6 8024d84: 4698 mov r8, r3 8024d86: d914 bls.n 8024db2 <__mdiff+0xc6> 8024d88: f852 5b04 ldr.w r5, [r2], #4 8024d8c: b2a9 uxth r1, r5 8024d8e: 0c2d lsrs r5, r5, #16 8024d90: 190c adds r4, r1, r4 8024d92: eb05 4524 add.w r5, r5, r4, asr #16 8024d96: b2a4 uxth r4, r4 8024d98: ea44 4105 orr.w r1, r4, r5, lsl #16 8024d9c: 142c asrs r4, r5, #16 8024d9e: 4594 cmp ip, r2 8024da0: f843 1b04 str.w r1, [r3], #4 8024da4: d8f0 bhi.n 8024d88 <__mdiff+0x9c> 8024da6: 43f3 mvns r3, r6 8024da8: 4463 add r3, ip 8024daa: f023 0303 bic.w r3, r3, #3 8024dae: 3304 adds r3, #4 8024db0: 4443 add r3, r8 8024db2: 3b04 subs r3, #4 8024db4: b921 cbnz r1, 8024dc0 <__mdiff+0xd4> 8024db6: f853 2d04 ldr.w r2, [r3, #-4]! 8024dba: 3f01 subs r7, #1 8024dbc: 2a00 cmp r2, #0 8024dbe: d0fa beq.n 8024db6 <__mdiff+0xca> 8024dc0: 6107 str r7, [r0, #16] 8024dc2: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 8024dc6: 4620 mov r0, r4 8024dc8: 4629 mov r1, r5 8024dca: f7ff fcef bl 80247ac <_Balloc> 8024dce: 2301 movs r3, #1 8024dd0: 6145 str r5, [r0, #20] 8024dd2: 6103 str r3, [r0, #16] 8024dd4: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 08024dd8 <__ulp>: 8024dd8: 2300 movs r3, #0 8024dda: f6c7 73f0 movt r3, #32752 ; 0x7ff0 8024dde: 400b ands r3, r1 8024de0: f1a3 7350 sub.w r3, r3, #54525952 ; 0x3400000 8024de4: 2b00 cmp r3, #0 8024de6: dd02 ble.n 8024dee <__ulp+0x16> 8024de8: 4619 mov r1, r3 8024dea: 2000 movs r0, #0 8024dec: 4770 bx lr 8024dee: 425b negs r3, r3 8024df0: 2100 movs r1, #0 8024df2: 151b asrs r3, r3, #20 8024df4: 2b13 cmp r3, #19 8024df6: dd0b ble.n 8024e10 <__ulp+0x38> 8024df8: 2b32 cmp r3, #50 ; 0x32 8024dfa: dd02 ble.n 8024e02 <__ulp+0x2a> 8024dfc: 2301 movs r3, #1 8024dfe: 4618 mov r0, r3 8024e00: 4770 bx lr 8024e02: 2201 movs r2, #1 8024e04: f1c3 0333 rsb r3, r3, #51 ; 0x33 8024e08: fa02 f303 lsl.w r3, r2, r3 8024e0c: 4618 mov r0, r3 8024e0e: 4770 bx lr 8024e10: f44f 2200 mov.w r2, #524288 ; 0x80000 8024e14: 2000 movs r0, #0 8024e16: fa42 f103 asr.w r1, r2, r3 8024e1a: 4770 bx lr 08024e1c <__b2d>: 8024e1c: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 8024e20: f100 0814 add.w r8, r0, #20 8024e24: 6906 ldr r6, [r0, #16] 8024e26: 4689 mov r9, r1 8024e28: 3604 adds r6, #4 8024e2a: eb00 0686 add.w r6, r0, r6, lsl #2 8024e2e: 4634 mov r4, r6 8024e30: 4637 mov r7, r6 8024e32: f854 5b04 ldr.w r5, [r4], #4 8024e36: 4628 mov r0, r5 8024e38: f7ff fd9a bl 8024970 <__hi0bits> 8024e3c: 280a cmp r0, #10 8024e3e: f1c0 0320 rsb r3, r0, #32 8024e42: f8c9 3000 str.w r3, [r9] 8024e46: dc18 bgt.n 8024e7a <__b2d+0x5e> 8024e48: 45b0 cmp r8, r6 8024e4a: f1c0 010b rsb r1, r0, #11 8024e4e: fa25 f701 lsr.w r7, r5, r1 8024e52: bf38 it cc 8024e54: f854 4c08 ldrcc.w r4, [r4, #-8] 8024e58: f047 577f orr.w r7, r7, #1069547520 ; 0x3fc00000 8024e5c: f447 1340 orr.w r3, r7, #3145728 ; 0x300000 8024e60: bf34 ite cc 8024e62: fa24 f101 lsrcc.w r1, r4, r1 8024e66: 2100 movcs r1, #0 8024e68: 3015 adds r0, #21 8024e6a: fa05 f500 lsl.w r5, r5, r0 8024e6e: ea41 0205 orr.w r2, r1, r5 8024e72: 4610 mov r0, r2 8024e74: 4619 mov r1, r3 8024e76: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 8024e7a: 2100 movs r1, #0 8024e7c: 45b0 cmp r8, r6 8024e7e: d202 bcs.n 8024e86 <__b2d+0x6a> 8024e80: f854 1c08 ldr.w r1, [r4, #-8] 8024e84: 1f37 subs r7, r6, #4 8024e86: f1b0 040b subs.w r4, r0, #11 8024e8a: d018 beq.n 8024ebe <__b2d+0xa2> 8024e8c: fa05 f504 lsl.w r5, r5, r4 8024e90: f1c0 002b rsb r0, r0, #43 ; 0x2b 8024e94: 4547 cmp r7, r8 8024e96: f045 557f orr.w r5, r5, #1069547520 ; 0x3fc00000 8024e9a: fa21 f600 lsr.w r6, r1, r0 8024e9e: f445 1540 orr.w r5, r5, #3145728 ; 0x300000 8024ea2: ea45 0306 orr.w r3, r5, r6 8024ea6: bf88 it hi 8024ea8: f857 5c04 ldrhi.w r5, [r7, #-4] 8024eac: fa01 f104 lsl.w r1, r1, r4 8024eb0: bf8c ite hi 8024eb2: fa25 f000 lsrhi.w r0, r5, r0 8024eb6: 2000 movls r0, #0 8024eb8: ea40 0201 orr.w r2, r0, r1 8024ebc: e7d9 b.n 8024e72 <__b2d+0x56> 8024ebe: f045 557f orr.w r5, r5, #1069547520 ; 0x3fc00000 8024ec2: 460a mov r2, r1 8024ec4: f445 1340 orr.w r3, r5, #3145728 ; 0x300000 8024ec8: e7d3 b.n 8024e72 <__b2d+0x56> 8024eca: bf00 nop 08024ecc <__d2b>: 8024ecc: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} 8024ed0: b083 sub sp, #12 8024ed2: 2101 movs r1, #1 8024ed4: 461d mov r5, r3 8024ed6: 4614 mov r4, r2 8024ed8: 9f0a ldr r7, [sp, #40] ; 0x28 8024eda: f7ff fc67 bl 80247ac <_Balloc> 8024ede: f3c5 560a ubfx r6, r5, #20, #11 8024ee2: f025 437f bic.w r3, r5, #4278190080 ; 0xff000000 8024ee6: 46a9 mov r9, r5 8024ee8: f423 0370 bic.w r3, r3, #15728640 ; 0xf00000 8024eec: 4680 mov r8, r0 8024eee: b10e cbz r6, 8024ef4 <__d2b+0x28> 8024ef0: f443 1380 orr.w r3, r3, #1048576 ; 0x100000 8024ef4: 9301 str r3, [sp, #4] 8024ef6: 2c00 cmp r4, #0 8024ef8: d024 beq.n 8024f44 <__d2b+0x78> 8024efa: a802 add r0, sp, #8 8024efc: f840 4d08 str.w r4, [r0, #-8]! 8024f00: 4668 mov r0, sp 8024f02: f7ff fd53 bl 80249ac <__lo0bits> 8024f06: 9b01 ldr r3, [sp, #4] 8024f08: 2800 cmp r0, #0 8024f0a: d131 bne.n 8024f70 <__d2b+0xa4> 8024f0c: 9a00 ldr r2, [sp, #0] 8024f0e: f8c8 2014 str.w r2, [r8, #20] 8024f12: 2b00 cmp r3, #0 8024f14: bf0c ite eq 8024f16: 2401 moveq r4, #1 8024f18: 2402 movne r4, #2 8024f1a: f8c8 3018 str.w r3, [r8, #24] 8024f1e: f8c8 4010 str.w r4, [r8, #16] 8024f22: b9e6 cbnz r6, 8024f5e <__d2b+0x92> 8024f24: eb08 0384 add.w r3, r8, r4, lsl #2 8024f28: f2a0 4032 subw r0, r0, #1074 ; 0x432 8024f2c: 6038 str r0, [r7, #0] 8024f2e: 6918 ldr r0, [r3, #16] 8024f30: f7ff fd1e bl 8024970 <__hi0bits> 8024f34: 9b0b ldr r3, [sp, #44] ; 0x2c 8024f36: ebc0 1044 rsb r0, r0, r4, lsl #5 8024f3a: 6018 str r0, [r3, #0] 8024f3c: 4640 mov r0, r8 8024f3e: b003 add sp, #12 8024f40: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 8024f44: a801 add r0, sp, #4 8024f46: f7ff fd31 bl 80249ac <__lo0bits> 8024f4a: 2301 movs r3, #1 8024f4c: 461c mov r4, r3 8024f4e: f8c8 3010 str.w r3, [r8, #16] 8024f52: 9b01 ldr r3, [sp, #4] 8024f54: f8c8 3014 str.w r3, [r8, #20] 8024f58: 3020 adds r0, #32 8024f5a: 2e00 cmp r6, #0 8024f5c: d0e2 beq.n 8024f24 <__d2b+0x58> 8024f5e: 9a0b ldr r2, [sp, #44] ; 0x2c 8024f60: f2a6 4933 subw r9, r6, #1075 ; 0x433 8024f64: f1c0 0335 rsb r3, r0, #53 ; 0x35 8024f68: 4448 add r0, r9 8024f6a: 6038 str r0, [r7, #0] 8024f6c: 6013 str r3, [r2, #0] 8024f6e: e7e5 b.n 8024f3c <__d2b+0x70> 8024f70: f1c0 0120 rsb r1, r0, #32 8024f74: 9a00 ldr r2, [sp, #0] 8024f76: fa03 f101 lsl.w r1, r3, r1 8024f7a: fa23 f300 lsr.w r3, r3, r0 8024f7e: 430a orrs r2, r1 8024f80: 9301 str r3, [sp, #4] 8024f82: f8c8 2014 str.w r2, [r8, #20] 8024f86: e7c4 b.n 8024f12 <__d2b+0x46> 08024f88 <__ratio>: 8024f88: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} 8024f8c: b083 sub sp, #12 8024f8e: 4688 mov r8, r1 8024f90: 4669 mov r1, sp 8024f92: 4606 mov r6, r0 8024f94: f7ff ff42 bl 8024e1c <__b2d> 8024f98: 460d mov r5, r1 8024f9a: 4604 mov r4, r0 8024f9c: a901 add r1, sp, #4 8024f9e: 4640 mov r0, r8 8024fa0: f7ff ff3c bl 8024e1c <__b2d> 8024fa4: 462f mov r7, r5 8024fa6: 460b mov r3, r1 8024fa8: 4602 mov r2, r0 8024faa: f8d8 1010 ldr.w r1, [r8, #16] 8024fae: 4699 mov r9, r3 8024fb0: 6930 ldr r0, [r6, #16] 8024fb2: 4626 mov r6, r4 8024fb4: 4690 mov r8, r2 8024fb6: ebc1 0e00 rsb lr, r1, r0 8024fba: e89d 0003 ldmia.w sp, {r0, r1} 8024fbe: 1a40 subs r0, r0, r1 8024fc0: eb00 114e add.w r1, r0, lr, lsl #5 8024fc4: 2900 cmp r1, #0 8024fc6: bfc9 itett gt 8024fc8: eb05 5701 addgt.w r7, r5, r1, lsl #20 8024fcc: eba3 5901 suble.w r9, r3, r1, lsl #20 8024fd0: 4624 movgt r4, r4 8024fd2: 463d movgt r5, r7 8024fd4: bfdc itt le 8024fd6: 4612 movle r2, r2 8024fd8: 464b movle r3, r9 8024fda: 4620 mov r0, r4 8024fdc: 4629 mov r1, r5 8024fde: f7fb fc19 bl 8020814 <__aeabi_ddiv> 8024fe2: b003 add sp, #12 8024fe4: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 08024fe8 <_mprec_log10>: 8024fe8: 2817 cmp r0, #23 8024fea: b510 push {r4, lr} 8024fec: 4604 mov r4, r0 8024fee: dd0c ble.n 802500a <_mprec_log10+0x22> 8024ff0: 2100 movs r1, #0 8024ff2: 2000 movs r0, #0 8024ff4: f6c3 71f0 movt r1, #16368 ; 0x3ff0 8024ff8: 2300 movs r3, #0 8024ffa: 2200 movs r2, #0 8024ffc: f2c4 0324 movt r3, #16420 ; 0x4024 8025000: f7fb fade bl 80205c0 <__aeabi_dmul> 8025004: 3c01 subs r4, #1 8025006: d1f7 bne.n 8024ff8 <_mprec_log10+0x10> 8025008: bd10 pop {r4, pc} 802500a: f645 4308 movw r3, #23560 ; 0x5c08 802500e: f6c0 0303 movt r3, #2051 ; 0x803 8025012: eb03 03c0 add.w r3, r3, r0, lsl #3 8025016: e9d3 0104 ldrd r0, r1, [r3, #16] 802501a: bd10 pop {r4, pc} 0802501c <__copybits>: 802501c: b470 push {r4, r5, r6} 802501e: 3901 subs r1, #1 8025020: 6915 ldr r5, [r2, #16] 8025022: f102 0314 add.w r3, r2, #20 8025026: 114e asrs r6, r1, #5 8025028: 3601 adds r6, #1 802502a: eb02 0585 add.w r5, r2, r5, lsl #2 802502e: 3514 adds r5, #20 8025030: eb00 0686 add.w r6, r0, r6, lsl #2 8025034: 42ab cmp r3, r5 8025036: d20c bcs.n 8025052 <__copybits+0x36> 8025038: 4601 mov r1, r0 802503a: f853 4b04 ldr.w r4, [r3], #4 802503e: 429d cmp r5, r3 8025040: f841 4b04 str.w r4, [r1], #4 8025044: d8f9 bhi.n 802503a <__copybits+0x1e> 8025046: 1aab subs r3, r5, r2 8025048: 3b15 subs r3, #21 802504a: f023 0303 bic.w r3, r3, #3 802504e: 3304 adds r3, #4 8025050: 18c0 adds r0, r0, r3 8025052: 4286 cmp r6, r0 8025054: d904 bls.n 8025060 <__copybits+0x44> 8025056: 2300 movs r3, #0 8025058: f840 3b04 str.w r3, [r0], #4 802505c: 4286 cmp r6, r0 802505e: d8fb bhi.n 8025058 <__copybits+0x3c> 8025060: bc70 pop {r4, r5, r6} 8025062: 4770 bx lr 08025064 <__any_on>: 8025064: b430 push {r4, r5} 8025066: 114b asrs r3, r1, #5 8025068: 6904 ldr r4, [r0, #16] 802506a: f100 0214 add.w r2, r0, #20 802506e: 429c cmp r4, r3 8025070: bfb8 it lt 8025072: 4623 movlt r3, r4 8025074: db00 blt.n 8025078 <__any_on+0x14> 8025076: dc11 bgt.n 802509c <__any_on+0x38> 8025078: 3304 adds r3, #4 802507a: eb00 0083 add.w r0, r0, r3, lsl #2 802507e: 1d03 adds r3, r0, #4 8025080: 429a cmp r2, r3 8025082: d218 bcs.n 80250b6 <__any_on+0x52> 8025084: f853 3c04 ldr.w r3, [r3, #-4] 8025088: b92b cbnz r3, 8025096 <__any_on+0x32> 802508a: 4282 cmp r2, r0 802508c: d213 bcs.n 80250b6 <__any_on+0x52> 802508e: f850 3d04 ldr.w r3, [r0, #-4]! 8025092: 2b00 cmp r3, #0 8025094: d0f9 beq.n 802508a <__any_on+0x26> 8025096: 2001 movs r0, #1 8025098: bc30 pop {r4, r5} 802509a: 4770 bx lr 802509c: f011 011f ands.w r1, r1, #31 80250a0: d0ea beq.n 8025078 <__any_on+0x14> 80250a2: eb00 0483 add.w r4, r0, r3, lsl #2 80250a6: 6964 ldr r4, [r4, #20] 80250a8: fa24 f501 lsr.w r5, r4, r1 80250ac: fa05 f101 lsl.w r1, r5, r1 80250b0: 42a1 cmp r1, r4 80250b2: d1f0 bne.n 8025096 <__any_on+0x32> 80250b4: e7e0 b.n 8025078 <__any_on+0x14> 80250b6: 2000 movs r0, #0 80250b8: e7ee b.n 8025098 <__any_on+0x34> 80250ba: bf00 nop 080250bc <_sbrk_r>: 80250bc: b538 push {r3, r4, r5, lr} 80250be: f245 1438 movw r4, #20792 ; 0x5138 80250c2: f2c2 0401 movt r4, #8193 ; 0x2001 80250c6: 4605 mov r5, r0 80250c8: 4608 mov r0, r1 80250ca: 2300 movs r3, #0 80250cc: 6023 str r3, [r4, #0] 80250ce: f010 fcbf bl 8035a50 <_sbrk> 80250d2: 1c43 adds r3, r0, #1 80250d4: d000 beq.n 80250d8 <_sbrk_r+0x1c> 80250d6: bd38 pop {r3, r4, r5, pc} 80250d8: 6823 ldr r3, [r4, #0] 80250da: 2b00 cmp r3, #0 80250dc: d0fb beq.n 80250d6 <_sbrk_r+0x1a> 80250de: 602b str r3, [r5, #0] 80250e0: bd38 pop {r3, r4, r5, pc} 80250e2: bf00 nop 080250e4 : 80250e4: b2c9 uxtb r1, r1 80250e6: b4f0 push {r4, r5, r6, r7} 80250e8: 2900 cmp r1, #0 80250ea: d04b beq.n 8025184 80250ec: 0783 lsls r3, r0, #30 80250ee: d00f beq.n 8025110 80250f0: 7803 ldrb r3, [r0, #0] 80250f2: 2b00 cmp r3, #0 80250f4: d073 beq.n 80251de 80250f6: 4299 cmp r1, r3 80250f8: d042 beq.n 8025180 80250fa: 1c43 adds r3, r0, #1 80250fc: e005 b.n 802510a 80250fe: f813 2b01 ldrb.w r2, [r3], #1 8025102: 2a00 cmp r2, #0 8025104: d03b beq.n 802517e 8025106: 4291 cmp r1, r2 8025108: d03a beq.n 8025180 802510a: 079a lsls r2, r3, #30 802510c: 4618 mov r0, r3 802510e: d1f6 bne.n 80250fe 8025110: 6803 ldr r3, [r0, #0] 8025112: ea41 2701 orr.w r7, r1, r1, lsl #8 8025116: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 802511a: ea47 4707 orr.w r7, r7, r7, lsl #16 802511e: ea22 0203 bic.w r2, r2, r3 8025122: f012 3f80 tst.w r2, #2155905152 ; 0x80808080 8025126: d11c bne.n 8025162 8025128: 407b eors r3, r7 802512a: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 802512e: ea22 0303 bic.w r3, r2, r3 8025132: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 8025136: d114 bne.n 8025162 8025138: 1d02 adds r2, r0, #4 802513a: e002 b.n 8025142 802513c: f014 3f80 tst.w r4, #2155905152 ; 0x80808080 8025140: d10f bne.n 8025162 8025142: 4610 mov r0, r2 8025144: f852 3b04 ldr.w r3, [r2], #4 8025148: f1a3 3601 sub.w r6, r3, #16843009 ; 0x1010101 802514c: ea87 0403 eor.w r4, r7, r3 8025150: ea26 0303 bic.w r3, r6, r3 8025154: f1a4 3501 sub.w r5, r4, #16843009 ; 0x1010101 8025158: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 802515c: ea25 0404 bic.w r4, r5, r4 8025160: d0ec beq.n 802513c 8025162: 7803 ldrb r3, [r0, #0] 8025164: 2b00 cmp r3, #0 8025166: d03a beq.n 80251de 8025168: 4299 cmp r1, r3 802516a: d009 beq.n 8025180 802516c: 1c43 adds r3, r0, #1 802516e: e001 b.n 8025174 8025170: 4291 cmp r1, r2 8025172: d005 beq.n 8025180 8025174: 4618 mov r0, r3 8025176: f813 2b01 ldrb.w r2, [r3], #1 802517a: 2a00 cmp r2, #0 802517c: d1f8 bne.n 8025170 802517e: 4610 mov r0, r2 8025180: bcf0 pop {r4, r5, r6, r7} 8025182: 4770 bx lr 8025184: 0781 lsls r1, r0, #30 8025186: d00d beq.n 80251a4 8025188: 7803 ldrb r3, [r0, #0] 802518a: 2b00 cmp r3, #0 802518c: d0f8 beq.n 8025180 802518e: 1c43 adds r3, r0, #1 8025190: e002 b.n 8025198 8025192: 7802 ldrb r2, [r0, #0] 8025194: 2a00 cmp r2, #0 8025196: d0f3 beq.n 8025180 8025198: f013 0f03 tst.w r3, #3 802519c: 4618 mov r0, r3 802519e: f103 0301 add.w r3, r3, #1 80251a2: d1f6 bne.n 8025192 80251a4: 6803 ldr r3, [r0, #0] 80251a6: f1a3 3201 sub.w r2, r3, #16843009 ; 0x1010101 80251aa: ea22 0303 bic.w r3, r2, r3 80251ae: f013 3f80 tst.w r3, #2155905152 ; 0x80808080 80251b2: d10a bne.n 80251ca 80251b4: 1d02 adds r2, r0, #4 80251b6: 4610 mov r0, r2 80251b8: f852 1b04 ldr.w r1, [r2], #4 80251bc: f1a1 3401 sub.w r4, r1, #16843009 ; 0x1010101 80251c0: ea24 0101 bic.w r1, r4, r1 80251c4: f011 3f80 tst.w r1, #2155905152 ; 0x80808080 80251c8: d0f5 beq.n 80251b6 80251ca: 7803 ldrb r3, [r0, #0] 80251cc: 2b00 cmp r3, #0 80251ce: d0d7 beq.n 8025180 80251d0: 1c43 adds r3, r0, #1 80251d2: 4618 mov r0, r3 80251d4: 3301 adds r3, #1 80251d6: 7802 ldrb r2, [r0, #0] 80251d8: 2a00 cmp r2, #0 80251da: d1fa bne.n 80251d2 80251dc: e7d0 b.n 8025180 80251de: 4618 mov r0, r3 80251e0: e7ce b.n 8025180 80251e2: bf00 nop 080251e4 <_calloc_r>: 80251e4: b510 push {r4, lr} 80251e6: fb01 f102 mul.w r1, r1, r2 80251ea: f7fe ffc5 bl 8024178 <_malloc_r> 80251ee: 4604 mov r4, r0 80251f0: b170 cbz r0, 8025210 <_calloc_r+0x2c> 80251f2: f850 2c04 ldr.w r2, [r0, #-4] 80251f6: f022 0203 bic.w r2, r2, #3 80251fa: 3a04 subs r2, #4 80251fc: 2a24 cmp r2, #36 ; 0x24 80251fe: d81c bhi.n 802523a <_calloc_r+0x56> 8025200: 2a13 cmp r2, #19 8025202: bf98 it ls 8025204: 4603 movls r3, r0 8025206: d805 bhi.n 8025214 <_calloc_r+0x30> 8025208: 2200 movs r2, #0 802520a: 601a str r2, [r3, #0] 802520c: 605a str r2, [r3, #4] 802520e: 609a str r2, [r3, #8] 8025210: 4620 mov r0, r4 8025212: bd10 pop {r4, pc} 8025214: 2100 movs r1, #0 8025216: 2a1b cmp r2, #27 8025218: 6001 str r1, [r0, #0] 802521a: bf98 it ls 802521c: f100 0308 addls.w r3, r0, #8 8025220: 6041 str r1, [r0, #4] 8025222: d9f1 bls.n 8025208 <_calloc_r+0x24> 8025224: 2a24 cmp r2, #36 ; 0x24 8025226: 6081 str r1, [r0, #8] 8025228: 60c1 str r1, [r0, #12] 802522a: bf11 iteee ne 802522c: f100 0310 addne.w r3, r0, #16 8025230: 6101 streq r1, [r0, #16] 8025232: f100 0318 addeq.w r3, r0, #24 8025236: 6141 streq r1, [r0, #20] 8025238: e7e6 b.n 8025208 <_calloc_r+0x24> 802523a: 2100 movs r1, #0 802523c: f7fc fc40 bl 8021ac0 8025240: 4620 mov r0, r4 8025242: bd10 pop {r4, pc} 08025244 <__aeabi_d2uiz>: 8025244: 004a lsls r2, r1, #1 8025246: d211 bcs.n 802526c <__aeabi_d2uiz+0x28> 8025248: f512 1200 adds.w r2, r2, #2097152 ; 0x200000 802524c: d211 bcs.n 8025272 <__aeabi_d2uiz+0x2e> 802524e: d50d bpl.n 802526c <__aeabi_d2uiz+0x28> 8025250: f46f 7378 mvn.w r3, #992 ; 0x3e0 8025254: ebb3 5262 subs.w r2, r3, r2, asr #21 8025258: d40e bmi.n 8025278 <__aeabi_d2uiz+0x34> 802525a: ea4f 23c1 mov.w r3, r1, lsl #11 802525e: f043 4300 orr.w r3, r3, #2147483648 ; 0x80000000 8025262: ea43 5350 orr.w r3, r3, r0, lsr #21 8025266: fa23 f002 lsr.w r0, r3, r2 802526a: 4770 bx lr 802526c: f04f 0000 mov.w r0, #0 8025270: 4770 bx lr 8025272: ea50 3001 orrs.w r0, r0, r1, lsl #12 8025276: d102 bne.n 802527e <__aeabi_d2uiz+0x3a> 8025278: f04f 30ff mov.w r0, #4294967295 802527c: 4770 bx lr 802527e: f04f 0000 mov.w r0, #0 8025282: 4770 bx lr 08025284 : 8025284: f021 4100 bic.w r1, r1, #2147483648 ; 0x80000000 8025288: 4770 bx lr 802528a: bf00 nop 0802528c : { /* Check the parameters */ assert_param(IS_NVIC_PRIORITY_GROUP(NVIC_PriorityGroup)); /* Set the PRIGROUP[10:8] bits according to NVIC_PriorityGroup value */ SCB->AIRCR = AIRCR_VECTKEY_MASK | NVIC_PriorityGroup; 802528c: f040 60bf orr.w r0, r0, #100139008 ; 0x5f80000 8025290: 4b02 ldr r3, [pc, #8] ; (802529c ) 8025292: f440 3000 orr.w r0, r0, #131072 ; 0x20000 8025296: 60d8 str r0, [r3, #12] 8025298: 4770 bx lr 802529a: bf00 nop 802529c: e000ed00 .word 0xe000ed00 080252a0 : /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NVIC_InitStruct->NVIC_IRQChannelCmd)); assert_param(IS_NVIC_PREEMPTION_PRIORITY(NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority)); assert_param(IS_NVIC_SUB_PRIORITY(NVIC_InitStruct->NVIC_IRQChannelSubPriority)); if (NVIC_InitStruct->NVIC_IRQChannelCmd != DISABLE) 80252a0: 78c3 ldrb r3, [r0, #3] 80252a2: b30b cbz r3, 80252e8 { /* Compute the Corresponding IRQ Priority --------------------------------*/ tmppriority = (0x700 - ((SCB->AIRCR) & (uint32_t)0x700))>> 0x08; 80252a4: 4b16 ldr r3, [pc, #88] ; (8025300 ) tmppre = (0x4 - tmppriority); tmpsub = tmpsub >> tmppriority; tmppriority = NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority << tmppre; 80252a6: 7841 ldrb r1, [r0, #1] assert_param(IS_NVIC_SUB_PRIORITY(NVIC_InitStruct->NVIC_IRQChannelSubPriority)); if (NVIC_InitStruct->NVIC_IRQChannelCmd != DISABLE) { /* Compute the Corresponding IRQ Priority --------------------------------*/ tmppriority = (0x700 - ((SCB->AIRCR) & (uint32_t)0x700))>> 0x08; 80252a8: 68db ldr r3, [r3, #12] 80252aa: 43db mvns r3, r3 80252ac: f3c3 2302 ubfx r3, r3, #8, #3 tmppre = (0x4 - tmppriority); 80252b0: f1c3 0204 rsb r2, r3, #4 tmpsub = tmpsub >> tmppriority; tmppriority = NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority << tmppre; 80252b4: b2d2 uxtb r2, r2 80252b6: fa01 f202 lsl.w r2, r1, r2 if (NVIC_InitStruct->NVIC_IRQChannelCmd != DISABLE) { /* Compute the Corresponding IRQ Priority --------------------------------*/ tmppriority = (0x700 - ((SCB->AIRCR) & (uint32_t)0x700))>> 0x08; tmppre = (0x4 - tmppriority); tmpsub = tmpsub >> tmppriority; 80252ba: 210f movs r1, #15 80252bc: fa41 f303 asr.w r3, r1, r3 tmppriority = NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority << tmppre; tmppriority |= (uint8_t)(NVIC_InitStruct->NVIC_IRQChannelSubPriority & tmpsub); 80252c0: 7881 ldrb r1, [r0, #2] /* Compute the Corresponding IRQ Priority --------------------------------*/ tmppriority = (0x700 - ((SCB->AIRCR) & (uint32_t)0x700))>> 0x08; tmppre = (0x4 - tmppriority); tmpsub = tmpsub >> tmppriority; tmppriority = NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority << tmppre; 80252c2: b2d2 uxtb r2, r2 tmppriority |= (uint8_t)(NVIC_InitStruct->NVIC_IRQChannelSubPriority & tmpsub); 80252c4: 400b ands r3, r1 80252c6: 431a orrs r2, r3 tmppriority = tmppriority << 0x04; NVIC->IP[NVIC_InitStruct->NVIC_IRQChannel] = tmppriority; 80252c8: 7803 ldrb r3, [r0, #0] 80252ca: f103 4360 add.w r3, r3, #3758096384 ; 0xe0000000 80252ce: f503 4361 add.w r3, r3, #57600 ; 0xe100 tmpsub = tmpsub >> tmppriority; tmppriority = NVIC_InitStruct->NVIC_IRQChannelPreemptionPriority << tmppre; tmppriority |= (uint8_t)(NVIC_InitStruct->NVIC_IRQChannelSubPriority & tmpsub); tmppriority = tmppriority << 0x04; 80252d2: 0112 lsls r2, r2, #4 NVIC->IP[NVIC_InitStruct->NVIC_IRQChannel] = tmppriority; 80252d4: f883 2300 strb.w r2, [r3, #768] ; 0x300 /* Enable the Selected IRQ Channels --------------------------------------*/ NVIC->ISER[NVIC_InitStruct->NVIC_IRQChannel >> 0x05] = 80252d8: 7803 ldrb r3, [r0, #0] (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); 80252da: 2201 movs r2, #1 tmppriority = tmppriority << 0x04; NVIC->IP[NVIC_InitStruct->NVIC_IRQChannel] = tmppriority; /* Enable the Selected IRQ Channels --------------------------------------*/ NVIC->ISER[NVIC_InitStruct->NVIC_IRQChannel >> 0x05] = 80252dc: 0959 lsrs r1, r3, #5 (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); 80252de: f003 031f and.w r3, r3, #31 80252e2: fa02 f303 lsl.w r3, r2, r3 80252e6: e007 b.n 80252f8 } else { /* Disable the Selected IRQ Channels -------------------------------------*/ NVIC->ICER[NVIC_InitStruct->NVIC_IRQChannel >> 0x05] = 80252e8: 7803 ldrb r3, [r0, #0] (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); 80252ea: 2201 movs r2, #1 (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); } else { /* Disable the Selected IRQ Channels -------------------------------------*/ NVIC->ICER[NVIC_InitStruct->NVIC_IRQChannel >> 0x05] = 80252ec: 0959 lsrs r1, r3, #5 (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); 80252ee: f003 031f and.w r3, r3, #31 80252f2: fa02 f303 lsl.w r3, r2, r3 (uint32_t)0x01 << (NVIC_InitStruct->NVIC_IRQChannel & (uint8_t)0x1F); } else { /* Disable the Selected IRQ Channels -------------------------------------*/ NVIC->ICER[NVIC_InitStruct->NVIC_IRQChannel >> 0x05] = 80252f6: 3120 adds r1, #32 80252f8: 4a02 ldr r2, [pc, #8] ; (8025304 ) 80252fa: f842 3021 str.w r3, [r2, r1, lsl #2] 80252fe: 4770 bx lr 8025300: e000ed00 .word 0xe000ed00 8025304: e000e100 .word 0xe000e100 08025308 : { /* Check the parameters */ assert_param(IS_NVIC_VECTTAB(NVIC_VectTab)); assert_param(IS_NVIC_OFFSET(Offset)); SCB->VTOR = NVIC_VectTab | (Offset & (uint32_t)0x1FFFFF80); 8025308: f021 4160 bic.w r1, r1, #3758096384 ; 0xe0000000 802530c: f021 017f bic.w r1, r1, #127 ; 0x7f 8025310: 4b01 ldr r3, [pc, #4] ; (8025318 ) 8025312: 4308 orrs r0, r1 8025314: 6098 str r0, [r3, #8] 8025316: 4770 bx lr 8025318: e000ed00 .word 0xe000ed00 0802531c : * @retval None */ void CRC_ResetDR(void) { /* Reset CRC generator */ CRC->CR = CRC_CR_RESET; 802531c: 4b01 ldr r3, [pc, #4] ; (8025324 ) 802531e: 2201 movs r2, #1 8025320: 609a str r2, [r3, #8] 8025322: 4770 bx lr 8025324: 40023000 .word 0x40023000 08025328 : * @param pBuffer: pointer to the buffer containing the data to be computed * @param BufferLength: length of the buffer to be computed * @retval 32-bit CRC */ uint32_t CRC_CalcBlockCRC(uint32_t pBuffer[], uint32_t BufferLength) { 8025328: b510 push {r4, lr} uint32_t index = 0; for(index = 0; index < BufferLength; index++) 802532a: 2300 movs r3, #0 802532c: 4c05 ldr r4, [pc, #20] ; (8025344 ) 802532e: e003 b.n 8025338 { CRC->DR = pBuffer[index]; 8025330: f850 2023 ldr.w r2, [r0, r3, lsl #2] */ uint32_t CRC_CalcBlockCRC(uint32_t pBuffer[], uint32_t BufferLength) { uint32_t index = 0; for(index = 0; index < BufferLength; index++) 8025334: 3301 adds r3, #1 { CRC->DR = pBuffer[index]; 8025336: 6022 str r2, [r4, #0] */ uint32_t CRC_CalcBlockCRC(uint32_t pBuffer[], uint32_t BufferLength) { uint32_t index = 0; for(index = 0; index < BufferLength; index++) 8025338: 428b cmp r3, r1 802533a: d1f9 bne.n 8025330 { CRC->DR = pBuffer[index]; } return (CRC->DR); 802533c: 4b01 ldr r3, [pc, #4] ; (8025344 ) 802533e: 6818 ldr r0, [r3, #0] } 8025340: bd10 pop {r4, pc} 8025342: bf00 nop 8025344: 40023000 .word 0x40023000 08025348 : * @param None * @retval None */ void FLASH_Unlock(void) { if((FLASH->CR & FLASH_CR_LOCK) != RESET) 8025348: 4b04 ldr r3, [pc, #16] ; (802535c ) 802534a: 691a ldr r2, [r3, #16] 802534c: 2a00 cmp r2, #0 802534e: da04 bge.n 802535a { /* Authorize the FLASH Registers access */ FLASH->KEYR = FLASH_KEY1; 8025350: 4a03 ldr r2, [pc, #12] ; (8025360 ) 8025352: 605a str r2, [r3, #4] FLASH->KEYR = FLASH_KEY2; 8025354: f102 3288 add.w r2, r2, #2290649224 ; 0x88888888 8025358: 605a str r2, [r3, #4] 802535a: 4770 bx lr 802535c: 40023c00 .word 0x40023c00 8025360: 45670123 .word 0x45670123 08025364 : * @retval None */ void FLASH_Lock(void) { /* Set the LOCK Bit to lock the FLASH Registers access */ FLASH->CR |= FLASH_CR_LOCK; 8025364: 4b02 ldr r3, [pc, #8] ; (8025370 ) 8025366: 691a ldr r2, [r3, #16] 8025368: f042 4200 orr.w r2, r2, #2147483648 ; 0x80000000 802536c: 611a str r2, [r3, #16] 802536e: 4770 bx lr 8025370: 40023c00 .word 0x40023c00 08025374 : { /* Check the parameters */ assert_param(IS_FLASH_CLEAR_FLAG(FLASH_FLAG)); /* Clear the flags */ FLASH->SR = FLASH_FLAG; 8025374: 4b01 ldr r3, [pc, #4] ; (802537c ) 8025376: 60d8 str r0, [r3, #12] 8025378: 4770 bx lr 802537a: bf00 nop 802537c: 40023c00 .word 0x40023c00 08025380 : */ FLASH_Status FLASH_GetStatus(void) { FLASH_Status flashstatus = FLASH_COMPLETE; if((FLASH->SR & FLASH_FLAG_BSY) == FLASH_FLAG_BSY) 8025380: 4b0b ldr r3, [pc, #44] ; (80253b0 ) 8025382: 68da ldr r2, [r3, #12] 8025384: 03d0 lsls r0, r2, #15 8025386: d40d bmi.n 80253a4 { flashstatus = FLASH_BUSY; } else { if((FLASH->SR & FLASH_FLAG_WRPERR) != (uint32_t)0x00) 8025388: 68da ldr r2, [r3, #12] 802538a: 06d1 lsls r1, r2, #27 802538c: d40c bmi.n 80253a8 { flashstatus = FLASH_ERROR_WRP; } else { if((FLASH->SR & (uint32_t)0xEF) != (uint32_t)0x00) 802538e: 68da ldr r2, [r3, #12] 8025390: f012 0fef tst.w r2, #239 ; 0xef 8025394: d10a bne.n 80253ac { flashstatus = FLASH_ERROR_PROGRAM; } else { if((FLASH->SR & FLASH_FLAG_OPERR) != (uint32_t)0x00) 8025396: 68db ldr r3, [r3, #12] 8025398: f013 0f02 tst.w r3, #2 { flashstatus = FLASH_ERROR_OPERATION; 802539c: bf0c ite eq 802539e: 2008 moveq r0, #8 80253a0: 2007 movne r0, #7 80253a2: 4770 bx lr { FLASH_Status flashstatus = FLASH_COMPLETE; if((FLASH->SR & FLASH_FLAG_BSY) == FLASH_FLAG_BSY) { flashstatus = FLASH_BUSY; 80253a4: 2001 movs r0, #1 80253a6: 4770 bx lr } else { if((FLASH->SR & FLASH_FLAG_WRPERR) != (uint32_t)0x00) { flashstatus = FLASH_ERROR_WRP; 80253a8: 2005 movs r0, #5 80253aa: 4770 bx lr } else { if((FLASH->SR & (uint32_t)0xEF) != (uint32_t)0x00) { flashstatus = FLASH_ERROR_PROGRAM; 80253ac: 2006 movs r0, #6 } } } /* Return the FLASH Status */ return flashstatus; } 80253ae: 4770 bx lr 80253b0: 40023c00 .word 0x40023c00 080253b4 : * @param None * @retval FLASH Status: The returned value can be: FLASH_BUSY, FLASH_ERROR_PROGRAM, * FLASH_ERROR_WRP, FLASH_ERROR_OPERATION or FLASH_COMPLETE. */ FLASH_Status FLASH_WaitForLastOperation(void) { 80253b4: b507 push {r0, r1, r2, lr} __IO FLASH_Status status = FLASH_COMPLETE; 80253b6: 2308 movs r3, #8 80253b8: f88d 3007 strb.w r3, [sp, #7] /* Wait for the FLASH operation to complete by polling on BUSY flag to be reset. Even if the FLASH operation fails, the BUSY flag will be reset and an error flag will be set */ while(status == FLASH_BUSY) { status = FLASH_GetStatus(); 80253bc: f7ff ffe0 bl 8025380 80253c0: f88d 0007 strb.w r0, [sp, #7] status = FLASH_GetStatus(); /* Wait for the FLASH operation to complete by polling on BUSY flag to be reset. Even if the FLASH operation fails, the BUSY flag will be reset and an error flag will be set */ while(status == FLASH_BUSY) 80253c4: f89d 3007 ldrb.w r3, [sp, #7] 80253c8: 2b01 cmp r3, #1 80253ca: d0f7 beq.n 80253bc { status = FLASH_GetStatus(); } /* Return the operation status */ return status; 80253cc: f89d 0007 ldrb.w r0, [sp, #7] } 80253d0: bd0e pop {r1, r2, r3, pc} 80253d2: 0000 movs r0, r0 080253d4 : * @param Data: specifies the data to be programmed. * @retval FLASH Status: The returned value can be: FLASH_BUSY, FLASH_ERROR_PROGRAM, * FLASH_ERROR_WRP, FLASH_ERROR_OPERATION or FLASH_COMPLETE. */ FLASH_Status FLASH_ProgramByte(uint32_t Address, uint8_t Data) { 80253d4: b570 push {r4, r5, r6, lr} 80253d6: 4605 mov r5, r0 80253d8: 460e mov r6, r1 /* Check the parameters */ assert_param(IS_FLASH_ADDRESS(Address)); /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 80253da: f7ff ffeb bl 80253b4 if(status == FLASH_COMPLETE) 80253de: 2808 cmp r0, #8 80253e0: d111 bne.n 8025406 { /* if the previous operation is completed, proceed to program the new data */ FLASH->CR &= CR_PSIZE_MASK; 80253e2: 4c09 ldr r4, [pc, #36] ; (8025408 ) 80253e4: 6923 ldr r3, [r4, #16] 80253e6: f423 7340 bic.w r3, r3, #768 ; 0x300 80253ea: 6123 str r3, [r4, #16] FLASH->CR |= FLASH_PSIZE_BYTE; 80253ec: 6923 ldr r3, [r4, #16] 80253ee: 6123 str r3, [r4, #16] FLASH->CR |= FLASH_CR_PG; 80253f0: 6923 ldr r3, [r4, #16] 80253f2: f043 0301 orr.w r3, r3, #1 80253f6: 6123 str r3, [r4, #16] *(__IO uint8_t*)Address = Data; 80253f8: 702e strb r6, [r5, #0] /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 80253fa: f7ff ffdb bl 80253b4 /* if the program operation is completed, disable the PG Bit */ FLASH->CR &= (~FLASH_CR_PG); 80253fe: 6923 ldr r3, [r4, #16] 8025400: f023 0301 bic.w r3, r3, #1 8025404: 6123 str r3, [r4, #16] } /* Return the Program Status */ return status; } 8025406: bd70 pop {r4, r5, r6, pc} 8025408: 40023c00 .word 0x40023c00 0802540c : * @param Data: specifies the data to be programmed. * @retval FLASH Status: The returned value can be: FLASH_BUSY, FLASH_ERROR_PROGRAM, * FLASH_ERROR_WRP, FLASH_ERROR_OPERATION or FLASH_COMPLETE. */ FLASH_Status FLASH_ProgramWord(uint32_t Address, uint32_t Data) { 802540c: b570 push {r4, r5, r6, lr} 802540e: 4605 mov r5, r0 8025410: 460e mov r6, r1 /* Check the parameters */ assert_param(IS_FLASH_ADDRESS(Address)); /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 8025412: f7ff ffcf bl 80253b4 if(status == FLASH_COMPLETE) 8025416: 2808 cmp r0, #8 8025418: d113 bne.n 8025442 { /* if the previous operation is completed, proceed to program the new data */ FLASH->CR &= CR_PSIZE_MASK; 802541a: 4c0a ldr r4, [pc, #40] ; (8025444 ) 802541c: 6923 ldr r3, [r4, #16] 802541e: f423 7340 bic.w r3, r3, #768 ; 0x300 8025422: 6123 str r3, [r4, #16] FLASH->CR |= FLASH_PSIZE_WORD; 8025424: 6923 ldr r3, [r4, #16] 8025426: f443 7300 orr.w r3, r3, #512 ; 0x200 802542a: 6123 str r3, [r4, #16] FLASH->CR |= FLASH_CR_PG; 802542c: 6923 ldr r3, [r4, #16] 802542e: f043 0301 orr.w r3, r3, #1 8025432: 6123 str r3, [r4, #16] *(__IO uint32_t*)Address = Data; 8025434: 602e str r6, [r5, #0] /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 8025436: f7ff ffbd bl 80253b4 /* if the program operation is completed, disable the PG Bit */ FLASH->CR &= (~FLASH_CR_PG); 802543a: 6923 ldr r3, [r4, #16] 802543c: f023 0301 bic.w r3, r3, #1 8025440: 6123 str r3, [r4, #16] } /* Return the Program Status */ return status; } 8025442: bd70 pop {r4, r5, r6, pc} 8025444: 40023c00 .word 0x40023c00 08025448 : * * @retval FLASH Status: The returned value can be: FLASH_BUSY, FLASH_ERROR_PROGRAM, * FLASH_ERROR_WRP, FLASH_ERROR_OPERATION or FLASH_COMPLETE. */ FLASH_Status FLASH_EraseSector(uint32_t FLASH_Sector, uint8_t VoltageRange) { 8025448: b570 push {r4, r5, r6, lr} 802544a: 4606 mov r6, r0 /* Check the parameters */ assert_param(IS_FLASH_SECTOR(FLASH_Sector)); assert_param(IS_VOLTAGERANGE(VoltageRange)); if(VoltageRange == VoltageRange_1) 802544c: b141 cbz r1, 8025460 { tmp_psize = FLASH_PSIZE_BYTE; } else if(VoltageRange == VoltageRange_2) 802544e: 2901 cmp r1, #1 8025450: d008 beq.n 8025464 { tmp_psize = FLASH_PSIZE_HALF_WORD; } else if(VoltageRange == VoltageRange_3) { tmp_psize = FLASH_PSIZE_WORD; 8025452: 2902 cmp r1, #2 8025454: bf14 ite ne 8025456: f44f 7540 movne.w r5, #768 ; 0x300 802545a: f44f 7500 moveq.w r5, #512 ; 0x200 802545e: e003 b.n 8025468 assert_param(IS_FLASH_SECTOR(FLASH_Sector)); assert_param(IS_VOLTAGERANGE(VoltageRange)); if(VoltageRange == VoltageRange_1) { tmp_psize = FLASH_PSIZE_BYTE; 8025460: 460d mov r5, r1 8025462: e001 b.n 8025468 } else if(VoltageRange == VoltageRange_2) { tmp_psize = FLASH_PSIZE_HALF_WORD; 8025464: f44f 7580 mov.w r5, #256 ; 0x100 else { tmp_psize = FLASH_PSIZE_DOUBLE_WORD; } /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 8025468: f7ff ffa4 bl 80253b4 if(status == FLASH_COMPLETE) 802546c: 2808 cmp r0, #8 802546e: d11e bne.n 80254ae { /* if the previous operation is completed, proceed to erase the sector */ FLASH->CR &= CR_PSIZE_MASK; 8025470: 4c0f ldr r4, [pc, #60] ; (80254b0 ) 8025472: 6923 ldr r3, [r4, #16] 8025474: f423 7340 bic.w r3, r3, #768 ; 0x300 8025478: 6123 str r3, [r4, #16] FLASH->CR |= tmp_psize; 802547a: 6921 ldr r1, [r4, #16] 802547c: 430d orrs r5, r1 802547e: 6125 str r5, [r4, #16] FLASH->CR &= SECTOR_MASK; 8025480: 6923 ldr r3, [r4, #16] 8025482: f023 03f8 bic.w r3, r3, #248 ; 0xf8 8025486: 6123 str r3, [r4, #16] FLASH->CR |= FLASH_CR_SER | FLASH_Sector; 8025488: 6923 ldr r3, [r4, #16] 802548a: f043 0302 orr.w r3, r3, #2 802548e: 431e orrs r6, r3 8025490: 6126 str r6, [r4, #16] FLASH->CR |= FLASH_CR_STRT; 8025492: 6923 ldr r3, [r4, #16] 8025494: f443 3380 orr.w r3, r3, #65536 ; 0x10000 8025498: 6123 str r3, [r4, #16] /* Wait for last operation to be completed */ status = FLASH_WaitForLastOperation(); 802549a: f7ff ff8b bl 80253b4 /* if the erase operation is completed, disable the SER Bit */ FLASH->CR &= (~FLASH_CR_SER); 802549e: 6923 ldr r3, [r4, #16] 80254a0: f023 0302 bic.w r3, r3, #2 80254a4: 6123 str r3, [r4, #16] FLASH->CR &= SECTOR_MASK; 80254a6: 6923 ldr r3, [r4, #16] 80254a8: f023 03f8 bic.w r3, r3, #248 ; 0xf8 80254ac: 6123 str r3, [r4, #16] } /* Return the Erase Status */ return status; } 80254ae: bd70 pop {r4, r5, r6, pc} 80254b0: 40023c00 .word 0x40023c00 080254b4 : * @note By default, The GPIO pins are configured in input floating mode (except JTAG pins). * @param GPIOx: where x can be (A..I) to select the GPIO peripheral. * @retval None */ void GPIO_DeInit(GPIO_TypeDef* GPIOx) { 80254b4: b508 push {r3, lr} /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); if (GPIOx == GPIOA) 80254b6: 4b2c ldr r3, [pc, #176] ; (8025568 ) 80254b8: 4298 cmp r0, r3 80254ba: d105 bne.n 80254c8 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOA, ENABLE); 80254bc: 2001 movs r0, #1 80254be: 4601 mov r1, r0 80254c0: f000 f974 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOA, DISABLE); 80254c4: 2001 movs r0, #1 80254c6: e048 b.n 802555a } else if (GPIOx == GPIOB) 80254c8: 4b28 ldr r3, [pc, #160] ; (802556c ) 80254ca: 4298 cmp r0, r3 80254cc: d105 bne.n 80254da { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOB, ENABLE); 80254ce: 2002 movs r0, #2 80254d0: 2101 movs r1, #1 80254d2: f000 f96b bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOB, DISABLE); 80254d6: 2002 movs r0, #2 80254d8: e03f b.n 802555a } else if (GPIOx == GPIOC) 80254da: 4b25 ldr r3, [pc, #148] ; (8025570 ) 80254dc: 4298 cmp r0, r3 80254de: d105 bne.n 80254ec { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOC, ENABLE); 80254e0: 2004 movs r0, #4 80254e2: 2101 movs r1, #1 80254e4: f000 f962 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOC, DISABLE); 80254e8: 2004 movs r0, #4 80254ea: e036 b.n 802555a } else if (GPIOx == GPIOD) 80254ec: 4b21 ldr r3, [pc, #132] ; (8025574 ) 80254ee: 4298 cmp r0, r3 80254f0: d105 bne.n 80254fe { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOD, ENABLE); 80254f2: 2008 movs r0, #8 80254f4: 2101 movs r1, #1 80254f6: f000 f959 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOD, DISABLE); 80254fa: 2008 movs r0, #8 80254fc: e02d b.n 802555a } else if (GPIOx == GPIOE) 80254fe: 4b1e ldr r3, [pc, #120] ; (8025578 ) 8025500: 4298 cmp r0, r3 8025502: d105 bne.n 8025510 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOE, ENABLE); 8025504: 2010 movs r0, #16 8025506: 2101 movs r1, #1 8025508: f000 f950 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOE, DISABLE); 802550c: 2010 movs r0, #16 802550e: e024 b.n 802555a } else if (GPIOx == GPIOF) 8025510: 4b1a ldr r3, [pc, #104] ; (802557c ) 8025512: 4298 cmp r0, r3 8025514: d105 bne.n 8025522 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOF, ENABLE); 8025516: 2020 movs r0, #32 8025518: 2101 movs r1, #1 802551a: f000 f947 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOF, DISABLE); 802551e: 2020 movs r0, #32 8025520: e01b b.n 802555a } else if (GPIOx == GPIOG) 8025522: 4b17 ldr r3, [pc, #92] ; (8025580 ) 8025524: 4298 cmp r0, r3 8025526: d105 bne.n 8025534 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOG, ENABLE); 8025528: 2040 movs r0, #64 ; 0x40 802552a: 2101 movs r1, #1 802552c: f000 f93e bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOG, DISABLE); 8025530: 2040 movs r0, #64 ; 0x40 8025532: e012 b.n 802555a } else if (GPIOx == GPIOH) 8025534: 4b13 ldr r3, [pc, #76] ; (8025584 ) 8025536: 4298 cmp r0, r3 8025538: d105 bne.n 8025546 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOH, ENABLE); 802553a: 2080 movs r0, #128 ; 0x80 802553c: 2101 movs r1, #1 802553e: f000 f935 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOH, DISABLE); 8025542: 2080 movs r0, #128 ; 0x80 8025544: e009 b.n 802555a } else { if (GPIOx == GPIOI) 8025546: 4b10 ldr r3, [pc, #64] ; (8025588 ) 8025548: 4298 cmp r0, r3 802554a: d10b bne.n 8025564 { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOI, ENABLE); 802554c: f44f 7080 mov.w r0, #256 ; 0x100 8025550: 2101 movs r1, #1 8025552: f000 f92b bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOI, DISABLE); 8025556: f44f 7080 mov.w r0, #256 ; 0x100 802555a: 2100 movs r1, #0 } } } 802555c: e8bd 4008 ldmia.w sp!, {r3, lr} else { if (GPIOx == GPIOI) { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOI, ENABLE); RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_GPIOI, DISABLE); 8025560: f000 b924 b.w 80257ac 8025564: bd08 pop {r3, pc} 8025566: bf00 nop 8025568: 40020000 .word 0x40020000 802556c: 40020400 .word 0x40020400 8025570: 40020800 .word 0x40020800 8025574: 40020c00 .word 0x40020c00 8025578: 40021000 .word 0x40021000 802557c: 40021400 .word 0x40021400 8025580: 40021800 .word 0x40021800 8025584: 40021c00 .word 0x40021c00 8025588: 40022000 .word 0x40022000 0802558c : * @param GPIO_InitStruct: pointer to a GPIO_InitTypeDef structure that contains * the configuration information for the specified GPIO peripheral. * @retval None */ void GPIO_Init(GPIO_TypeDef* GPIOx, GPIO_InitTypeDef* GPIO_InitStruct) { 802558c: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} /*-- GPIO Mode Configuration --*/ for (pinpos = 0x00; pinpos < 0x10; pinpos++) { pos = ((uint32_t)0x01) << pinpos; /* Get the port pins position */ currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; 8025590: 680f ldr r7, [r1, #0] assert_param(IS_GPIO_MODE(GPIO_InitStruct->GPIO_Mode)); assert_param(IS_GPIO_PUPD(GPIO_InitStruct->GPIO_PuPd)); /* -------------------------Configure the port pins---------------- */ /*-- GPIO Mode Configuration --*/ for (pinpos = 0x00; pinpos < 0x10; pinpos++) 8025592: 2300 movs r3, #0 { pos = ((uint32_t)0x01) << pinpos; 8025594: f04f 0c01 mov.w ip, #1 /* Get the port pins position */ currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; if (currentpin == pos) { GPIOx->MODER &= ~(GPIO_MODER_MODER0 << (pinpos * 2)); 8025598: f04f 0803 mov.w r8, #3 /* -------------------------Configure the port pins---------------- */ /*-- GPIO Mode Configuration --*/ for (pinpos = 0x00; pinpos < 0x10; pinpos++) { pos = ((uint32_t)0x01) << pinpos; 802559c: fa0c f203 lsl.w r2, ip, r3 /* Get the port pins position */ currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; 80255a0: ea02 0507 and.w r5, r2, r7 if (currentpin == pos) 80255a4: 4295 cmp r5, r2 80255a6: d131 bne.n 802560c * @param GPIOx: where x can be (A..I) to select the GPIO peripheral. * @param GPIO_InitStruct: pointer to a GPIO_InitTypeDef structure that contains * the configuration information for the specified GPIO peripheral. * @retval None */ void GPIO_Init(GPIO_TypeDef* GPIOx, GPIO_InitTypeDef* GPIO_InitStruct) 80255a8: 005a lsls r2, r3, #1 /* Get the port pins position */ currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; if (currentpin == pos) { GPIOx->MODER &= ~(GPIO_MODER_MODER0 << (pinpos * 2)); 80255aa: 6806 ldr r6, [r0, #0] 80255ac: fa08 f402 lsl.w r4, r8, r2 80255b0: 43e4 mvns r4, r4 80255b2: 4026 ands r6, r4 80255b4: 6006 str r6, [r0, #0] GPIOx->MODER |= (((uint32_t)GPIO_InitStruct->GPIO_Mode) << (pinpos * 2)); 80255b6: 790e ldrb r6, [r1, #4] 80255b8: f8d0 9000 ldr.w r9, [r0] 80255bc: fa06 fa02 lsl.w sl, r6, r2 if ((GPIO_InitStruct->GPIO_Mode == GPIO_Mode_OUT) || (GPIO_InitStruct->GPIO_Mode == GPIO_Mode_AF)) 80255c0: 3e01 subs r6, #1 currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; if (currentpin == pos) { GPIOx->MODER &= ~(GPIO_MODER_MODER0 << (pinpos * 2)); GPIOx->MODER |= (((uint32_t)GPIO_InitStruct->GPIO_Mode) << (pinpos * 2)); 80255c2: ea4a 0909 orr.w r9, sl, r9 if ((GPIO_InitStruct->GPIO_Mode == GPIO_Mode_OUT) || (GPIO_InitStruct->GPIO_Mode == GPIO_Mode_AF)) 80255c6: 2e01 cmp r6, #1 currentpin = (GPIO_InitStruct->GPIO_Pin) & pos; if (currentpin == pos) { GPIOx->MODER &= ~(GPIO_MODER_MODER0 << (pinpos * 2)); GPIOx->MODER |= (((uint32_t)GPIO_InitStruct->GPIO_Mode) << (pinpos * 2)); 80255c8: f8c0 9000 str.w r9, [r0] if ((GPIO_InitStruct->GPIO_Mode == GPIO_Mode_OUT) || (GPIO_InitStruct->GPIO_Mode == GPIO_Mode_AF)) 80255cc: d815 bhi.n 80255fa { /* Check Speed mode parameters */ assert_param(IS_GPIO_SPEED(GPIO_InitStruct->GPIO_Speed)); /* Speed mode configuration */ GPIOx->OSPEEDR &= ~(GPIO_OSPEEDER_OSPEEDR0 << (pinpos * 2)); 80255ce: 6886 ldr r6, [r0, #8] GPIOx->OSPEEDR |= ((uint32_t)(GPIO_InitStruct->GPIO_Speed) << (pinpos * 2)); 80255d0: f891 9005 ldrb.w r9, [r1, #5] { /* Check Speed mode parameters */ assert_param(IS_GPIO_SPEED(GPIO_InitStruct->GPIO_Speed)); /* Speed mode configuration */ GPIOx->OSPEEDR &= ~(GPIO_OSPEEDER_OSPEEDR0 << (pinpos * 2)); 80255d4: 4026 ands r6, r4 80255d6: 6086 str r6, [r0, #8] GPIOx->OSPEEDR |= ((uint32_t)(GPIO_InitStruct->GPIO_Speed) << (pinpos * 2)); 80255d8: 6886 ldr r6, [r0, #8] 80255da: fa09 f902 lsl.w r9, r9, r2 80255de: ea49 0606 orr.w r6, r9, r6 80255e2: 6086 str r6, [r0, #8] /* Check Output mode parameters */ assert_param(IS_GPIO_OTYPE(GPIO_InitStruct->GPIO_OType)); /* Output mode configuration*/ GPIOx->OTYPER &= ~((GPIO_OTYPER_OT_0) << ((uint16_t)pinpos)) ; 80255e4: 6846 ldr r6, [r0, #4] 80255e6: ea26 0505 bic.w r5, r6, r5 80255ea: 6045 str r5, [r0, #4] GPIOx->OTYPER |= (uint16_t)(((uint16_t)GPIO_InitStruct->GPIO_OType) << ((uint16_t)pinpos)); 80255ec: 798d ldrb r5, [r1, #6] 80255ee: 6846 ldr r6, [r0, #4] 80255f0: fa05 f503 lsl.w r5, r5, r3 temp = ((uint32_t)(GPIO_AF) << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; GPIOx->AFR[GPIO_PinSource >> 0x03] &= ~((uint32_t)0xF << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; temp_2 = GPIOx->AFR[GPIO_PinSource >> 0x03] | temp; GPIOx->AFR[GPIO_PinSource >> 0x03] = temp_2; } 80255f4: b2ad uxth r5, r5 /* Check Output mode parameters */ assert_param(IS_GPIO_OTYPE(GPIO_InitStruct->GPIO_OType)); /* Output mode configuration*/ GPIOx->OTYPER &= ~((GPIO_OTYPER_OT_0) << ((uint16_t)pinpos)) ; GPIOx->OTYPER |= (uint16_t)(((uint16_t)GPIO_InitStruct->GPIO_OType) << ((uint16_t)pinpos)); 80255f6: 4335 orrs r5, r6 80255f8: 6045 str r5, [r0, #4] } /* Pull-up Pull down resistor configuration*/ GPIOx->PUPDR &= ~(GPIO_PUPDR_PUPDR0 << ((uint16_t)pinpos * 2)); 80255fa: 68c5 ldr r5, [r0, #12] 80255fc: 402c ands r4, r5 80255fe: 60c4 str r4, [r0, #12] GPIOx->PUPDR |= (((uint32_t)GPIO_InitStruct->GPIO_PuPd) << (pinpos * 2)); 8025600: 79cd ldrb r5, [r1, #7] 8025602: 68c4 ldr r4, [r0, #12] 8025604: fa05 f202 lsl.w r2, r5, r2 8025608: 4322 orrs r2, r4 802560a: 60c2 str r2, [r0, #12] assert_param(IS_GPIO_MODE(GPIO_InitStruct->GPIO_Mode)); assert_param(IS_GPIO_PUPD(GPIO_InitStruct->GPIO_PuPd)); /* -------------------------Configure the port pins---------------- */ /*-- GPIO Mode Configuration --*/ for (pinpos = 0x00; pinpos < 0x10; pinpos++) 802560c: 3301 adds r3, #1 802560e: 2b10 cmp r3, #16 8025610: d1c4 bne.n 802559c /* Pull-up Pull down resistor configuration*/ GPIOx->PUPDR &= ~(GPIO_PUPDR_PUPDR0 << ((uint16_t)pinpos * 2)); GPIOx->PUPDR |= (((uint32_t)GPIO_InitStruct->GPIO_PuPd) << (pinpos * 2)); } } } 8025612: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 08025616 : { /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); assert_param(IS_GPIO_PIN(GPIO_Pin)); GPIOx->BSRRL = GPIO_Pin; 8025616: 8301 strh r1, [r0, #24] 8025618: 4770 bx lr 0802561a : { /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); assert_param(IS_GPIO_PIN(GPIO_Pin)); GPIOx->BSRRH = GPIO_Pin; 802561a: 8341 strh r1, [r0, #26] 802561c: 4770 bx lr 0802561e : /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); assert_param(IS_GPIO_PIN_SOURCE(GPIO_PinSource)); assert_param(IS_GPIO_AF(GPIO_AF)); temp = ((uint32_t)(GPIO_AF) << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; 802561e: f001 0307 and.w r3, r1, #7 GPIOx->AFR[GPIO_PinSource >> 0x03] &= ~((uint32_t)0xF << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; 8025622: 08c9 lsrs r1, r1, #3 8025624: 3108 adds r1, #8 * @arg GPIO_AF_DCMI: Connect DCMI pins to AF13 * @arg GPIO_AF_EVENTOUT: Connect EVENTOUT pins to AF15 * @retval None */ void GPIO_PinAFConfig(GPIO_TypeDef* GPIOx, uint16_t GPIO_PinSource, uint8_t GPIO_AF) { 8025626: b530 push {r4, r5, lr} /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); assert_param(IS_GPIO_PIN_SOURCE(GPIO_PinSource)); assert_param(IS_GPIO_AF(GPIO_AF)); temp = ((uint32_t)(GPIO_AF) << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; 8025628: 009b lsls r3, r3, #2 GPIOx->AFR[GPIO_PinSource >> 0x03] &= ~((uint32_t)0xF << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; 802562a: f850 5021 ldr.w r5, [r0, r1, lsl #2] 802562e: 240f movs r4, #15 8025630: fa04 f403 lsl.w r4, r4, r3 8025634: ea25 0404 bic.w r4, r5, r4 8025638: f840 4021 str.w r4, [r0, r1, lsl #2] temp_2 = GPIOx->AFR[GPIO_PinSource >> 0x03] | temp; 802563c: f850 4021 ldr.w r4, [r0, r1, lsl #2] /* Check the parameters */ assert_param(IS_GPIO_ALL_PERIPH(GPIOx)); assert_param(IS_GPIO_PIN_SOURCE(GPIO_PinSource)); assert_param(IS_GPIO_AF(GPIO_AF)); temp = ((uint32_t)(GPIO_AF) << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; 8025640: fa02 f203 lsl.w r2, r2, r3 GPIOx->AFR[GPIO_PinSource >> 0x03] &= ~((uint32_t)0xF << ((uint32_t)((uint32_t)GPIO_PinSource & (uint32_t)0x07) * 4)) ; temp_2 = GPIOx->AFR[GPIO_PinSource >> 0x03] | temp; 8025644: 4314 orrs r4, r2 GPIOx->AFR[GPIO_PinSource >> 0x03] = temp_2; 8025646: f840 4021 str.w r4, [r0, r1, lsl #2] 802564a: bd30 pop {r4, r5, pc} 0802564c : void PWR_BackupAccessCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); *(__IO uint32_t *) CR_DBP_BB = (uint32_t)NewState; 802564c: 4b01 ldr r3, [pc, #4] ; (8025654 ) 802564e: 6018 str r0, [r3, #0] 8025650: 4770 bx lr 8025652: bf00 nop 8025654: 420e0020 .word 0x420e0020 08025658 : /* Check the parameters */ assert_param(IS_RCC_LSE(RCC_LSE)); /* Reset LSEON and LSEBYP bits before configuring the LSE ------------------*/ /* Reset LSEON bit */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_OFF; 8025658: 4b06 ldr r3, [pc, #24] ; (8025674 ) 802565a: 2200 movs r2, #0 /* Reset LSEBYP bit */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_OFF; /* Configure LSE (RCC_LSE_OFF is already covered by the code section above) */ switch (RCC_LSE) 802565c: 2801 cmp r0, #1 /* Check the parameters */ assert_param(IS_RCC_LSE(RCC_LSE)); /* Reset LSEON and LSEBYP bits before configuring the LSE ------------------*/ /* Reset LSEON bit */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_OFF; 802565e: 701a strb r2, [r3, #0] /* Reset LSEBYP bit */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_OFF; 8025660: 701a strb r2, [r3, #0] /* Configure LSE (RCC_LSE_OFF is already covered by the code section above) */ switch (RCC_LSE) 8025662: d002 beq.n 802566a 8025664: 2804 cmp r0, #4 8025666: d104 bne.n 8025672 8025668: e001 b.n 802566e { case RCC_LSE_ON: /* Set LSEON bit */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_ON; 802566a: 7018 strb r0, [r3, #0] break; 802566c: 4770 bx lr case RCC_LSE_Bypass: /* Set LSEBYP and LSEON bits */ *(__IO uint8_t *) BDCR_ADDRESS = RCC_LSE_Bypass | RCC_LSE_ON; 802566e: 2205 movs r2, #5 8025670: 701a strb r2, [r3, #0] 8025672: 4770 bx lr 8025674: 40023870 .word 0x40023870 08025678 : void RCC_LSICmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); *(__IO uint32_t *) CSR_LSION_BB = (uint32_t)NewState; 8025678: 4b01 ldr r3, [pc, #4] ; (8025680 ) 802567a: 6018 str r0, [r3, #0] 802567c: 4770 bx lr 802567e: bf00 nop 8025680: 42470e80 .word 0x42470e80 08025684 : void RCC_GetClocksFreq(RCC_ClocksTypeDef* RCC_Clocks) { uint32_t tmp = 0, presc = 0, pllvco = 0, pllp = 2, pllsource = 0, pllm = 2; /* Get SYSCLK source -------------------------------------------------------*/ tmp = RCC->CFGR & RCC_CFGR_SWS; 8025684: 4b1e ldr r3, [pc, #120] ; (8025700 ) 8025686: 689a ldr r2, [r3, #8] 8025688: f002 020c and.w r2, r2, #12 switch (tmp) 802568c: 2a04 cmp r2, #4 * configuration based on this function will be incorrect. * * @retval None */ void RCC_GetClocksFreq(RCC_ClocksTypeDef* RCC_Clocks) { 802568e: b510 push {r4, lr} uint32_t tmp = 0, presc = 0, pllvco = 0, pllp = 2, pllsource = 0, pllm = 2; /* Get SYSCLK source -------------------------------------------------------*/ tmp = RCC->CFGR & RCC_CFGR_SWS; switch (tmp) 8025690: d003 beq.n 802569a 8025692: 2a08 cmp r2, #8 8025694: d003 beq.n 802569e 8025696: 4b1b ldr r3, [pc, #108] ; (8025704 ) 8025698: e018 b.n 80256cc { case 0x00: /* HSI used as system clock source */ RCC_Clocks->SYSCLK_Frequency = HSI_VALUE; break; case 0x04: /* HSE used as system clock source */ RCC_Clocks->SYSCLK_Frequency = HSE_VALUE; 802569a: 4b1b ldr r3, [pc, #108] ; (8025708 ) 802569c: e016 b.n 80256cc case 0x08: /* PLL used as system clock source */ /* PLL_VCO = (HSE_VALUE or HSI_VALUE / PLLM) * PLLN SYSCLK = PLL_VCO / PLLP */ pllsource = (RCC->PLLCFGR & RCC_PLLCFGR_PLLSRC) >> 22; 802569e: 6859 ldr r1, [r3, #4] pllm = RCC->PLLCFGR & RCC_PLLCFGR_PLLM; 80256a0: 685a ldr r2, [r3, #4] if (pllsource != 0) 80256a2: f411 0f80 tst.w r1, #4194304 ; 0x400000 { /* HSE used as PLL clock source */ pllvco = (HSE_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); 80256a6: 6859 ldr r1, [r3, #4] 80256a8: bf14 ite ne 80256aa: 4b17 ldrne r3, [pc, #92] ; (8025708 ) } else { /* HSI used as PLL clock source */ pllvco = (HSI_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); 80256ac: 4b15 ldreq r3, [pc, #84] ; (8025704 ) /* PLL_VCO = (HSE_VALUE or HSI_VALUE / PLLM) * PLLN SYSCLK = PLL_VCO / PLLP */ pllsource = (RCC->PLLCFGR & RCC_PLLCFGR_PLLSRC) >> 22; pllm = RCC->PLLCFGR & RCC_PLLCFGR_PLLM; 80256ae: f002 023f and.w r2, r2, #63 ; 0x3f pllvco = (HSE_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); } else { /* HSI used as PLL clock source */ pllvco = (HSI_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); 80256b2: fbb3 f3f2 udiv r3, r3, r2 } pllp = (((RCC->PLLCFGR & RCC_PLLCFGR_PLLP) >>16) + 1 ) *2; 80256b6: 4a12 ldr r2, [pc, #72] ; (8025700 ) 80256b8: 6852 ldr r2, [r2, #4] 80256ba: f3c2 4201 ubfx r2, r2, #16, #2 pllm = RCC->PLLCFGR & RCC_PLLCFGR_PLLM; if (pllsource != 0) { /* HSE used as PLL clock source */ pllvco = (HSE_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); 80256be: f3c1 1188 ubfx r1, r1, #6, #9 { /* HSI used as PLL clock source */ pllvco = (HSI_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); } pllp = (((RCC->PLLCFGR & RCC_PLLCFGR_PLLP) >>16) + 1 ) *2; 80256c2: 3201 adds r2, #1 pllvco = (HSE_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); } else { /* HSI used as PLL clock source */ pllvco = (HSI_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); 80256c4: 434b muls r3, r1 } pllp = (((RCC->PLLCFGR & RCC_PLLCFGR_PLLP) >>16) + 1 ) *2; 80256c6: 0052 lsls r2, r2, #1 RCC_Clocks->SYSCLK_Frequency = pllvco/pllp; 80256c8: fbb3 f3f2 udiv r3, r3, r2 break; } /* Compute HCLK, PCLK1 and PCLK2 clocks frequencies ------------------------*/ /* Get HCLK prescaler */ tmp = RCC->CFGR & RCC_CFGR_HPRE; 80256cc: 490c ldr r1, [pc, #48] ; (8025700 ) /* HSI used as PLL clock source */ pllvco = (HSI_VALUE / pllm) * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 6); } pllp = (((RCC->PLLCFGR & RCC_PLLCFGR_PLLP) >>16) + 1 ) *2; RCC_Clocks->SYSCLK_Frequency = pllvco/pllp; 80256ce: 6003 str r3, [r0, #0] break; } /* Compute HCLK, PCLK1 and PCLK2 clocks frequencies ------------------------*/ /* Get HCLK prescaler */ tmp = RCC->CFGR & RCC_CFGR_HPRE; 80256d0: 688b ldr r3, [r1, #8] tmp = tmp >> 4; presc = APBAHBPrescTable[tmp]; 80256d2: 4a0e ldr r2, [pc, #56] ; (802570c ) } /* Compute HCLK, PCLK1 and PCLK2 clocks frequencies ------------------------*/ /* Get HCLK prescaler */ tmp = RCC->CFGR & RCC_CFGR_HPRE; tmp = tmp >> 4; 80256d4: f3c3 1303 ubfx r3, r3, #4, #4 presc = APBAHBPrescTable[tmp]; 80256d8: 5cd4 ldrb r4, [r2, r3] /* HCLK clock frequency */ RCC_Clocks->HCLK_Frequency = RCC_Clocks->SYSCLK_Frequency >> presc; 80256da: 6803 ldr r3, [r0, #0] 80256dc: fa23 f304 lsr.w r3, r3, r4 80256e0: 6043 str r3, [r0, #4] /* Get PCLK1 prescaler */ tmp = RCC->CFGR & RCC_CFGR_PPRE1; 80256e2: 688c ldr r4, [r1, #8] tmp = tmp >> 10; 80256e4: f3c4 2482 ubfx r4, r4, #10, #3 presc = APBAHBPrescTable[tmp]; 80256e8: 5d14 ldrb r4, [r2, r4] /* PCLK1 clock frequency */ RCC_Clocks->PCLK1_Frequency = RCC_Clocks->HCLK_Frequency >> presc; 80256ea: fa23 f404 lsr.w r4, r3, r4 80256ee: 6084 str r4, [r0, #8] /* Get PCLK2 prescaler */ tmp = RCC->CFGR & RCC_CFGR_PPRE2; 80256f0: 6889 ldr r1, [r1, #8] tmp = tmp >> 13; 80256f2: f3c1 3142 ubfx r1, r1, #13, #3 presc = APBAHBPrescTable[tmp]; 80256f6: 5c52 ldrb r2, [r2, r1] /* PCLK2 clock frequency */ RCC_Clocks->PCLK2_Frequency = RCC_Clocks->HCLK_Frequency >> presc; 80256f8: fa23 f302 lsr.w r3, r3, r2 80256fc: 60c3 str r3, [r0, #12] 80256fe: bd10 pop {r4, pc} 8025700: 40023800 .word 0x40023800 8025704: 00f42400 .word 0x00f42400 8025708: 017d7840 .word 0x017d7840 802570c: 200005ac .word 0x200005ac 08025710 : uint32_t tmpreg = 0; /* Check the parameters */ assert_param(IS_RCC_RTCCLK_SOURCE(RCC_RTCCLKSource)); if ((RCC_RTCCLKSource & 0x00000300) == 0x00000300) 8025710: f400 7340 and.w r3, r0, #768 ; 0x300 8025714: f5b3 7f40 cmp.w r3, #768 ; 0x300 8025718: 4b08 ldr r3, [pc, #32] ; (802573c ) 802571a: d108 bne.n 802572e { /* If HSE is selected as RTC clock source, configure HSE division factor for RTC clock */ tmpreg = RCC->CFGR; 802571c: 6899 ldr r1, [r3, #8] /* Clear RTCPRE[4:0] bits */ tmpreg &= ~RCC_CFGR_RTCPRE; /* Configure HSE division factor for RTC clock */ tmpreg |= (RCC_RTCCLKSource & 0xFFFFCFF); 802571e: f020 4270 bic.w r2, r0, #4026531840 ; 0xf0000000 if ((RCC_RTCCLKSource & 0x00000300) == 0x00000300) { /* If HSE is selected as RTC clock source, configure HSE division factor for RTC clock */ tmpreg = RCC->CFGR; /* Clear RTCPRE[4:0] bits */ tmpreg &= ~RCC_CFGR_RTCPRE; 8025722: f421 11f8 bic.w r1, r1, #2031616 ; 0x1f0000 /* Configure HSE division factor for RTC clock */ tmpreg |= (RCC_RTCCLKSource & 0xFFFFCFF); 8025726: f422 7240 bic.w r2, r2, #768 ; 0x300 802572a: 430a orrs r2, r1 /* Store the new value */ RCC->CFGR = tmpreg; 802572c: 609a str r2, [r3, #8] } /* Select the RTC clock source */ RCC->BDCR |= (RCC_RTCCLKSource & 0x00000FFF); 802572e: 6f1a ldr r2, [r3, #112] ; 0x70 8025730: 0500 lsls r0, r0, #20 8025732: ea42 5010 orr.w r0, r2, r0, lsr #20 8025736: 6718 str r0, [r3, #112] ; 0x70 8025738: 4770 bx lr 802573a: bf00 nop 802573c: 40023800 .word 0x40023800 08025740 : void RCC_RTCCLKCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); *(__IO uint32_t *) BDCR_RTCEN_BB = (uint32_t)NewState; 8025740: 4b01 ldr r3, [pc, #4] ; (8025748 ) 8025742: 6018 str r0, [r3, #0] 8025744: 4770 bx lr 8025746: bf00 nop 8025748: 42470e3c .word 0x42470e3c 0802574c : * @param NewState: new state of the specified peripheral clock. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_AHB1PeriphClockCmd(uint32_t RCC_AHB1Periph, FunctionalState NewState) { 802574c: 4b04 ldr r3, [pc, #16] ; (8025760 ) assert_param(IS_RCC_AHB1_CLOCK_PERIPH(RCC_AHB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->AHB1ENR |= RCC_AHB1Periph; 802574e: 6b1a ldr r2, [r3, #48] ; 0x30 { /* Check the parameters */ assert_param(IS_RCC_AHB1_CLOCK_PERIPH(RCC_AHB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025750: b109 cbz r1, 8025756 { RCC->AHB1ENR |= RCC_AHB1Periph; 8025752: 4310 orrs r0, r2 8025754: e001 b.n 802575a } else { RCC->AHB1ENR &= ~RCC_AHB1Periph; 8025756: ea22 0000 bic.w r0, r2, r0 802575a: 6318 str r0, [r3, #48] ; 0x30 802575c: 4770 bx lr 802575e: bf00 nop 8025760: 40023800 .word 0x40023800 08025764 : * @param NewState: new state of the specified peripheral clock. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_AHB2PeriphClockCmd(uint32_t RCC_AHB2Periph, FunctionalState NewState) { 8025764: 4b04 ldr r3, [pc, #16] ; (8025778 ) assert_param(IS_RCC_AHB2_PERIPH(RCC_AHB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->AHB2ENR |= RCC_AHB2Periph; 8025766: 6b5a ldr r2, [r3, #52] ; 0x34 { /* Check the parameters */ assert_param(IS_RCC_AHB2_PERIPH(RCC_AHB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025768: b109 cbz r1, 802576e { RCC->AHB2ENR |= RCC_AHB2Periph; 802576a: 4310 orrs r0, r2 802576c: e001 b.n 8025772 } else { RCC->AHB2ENR &= ~RCC_AHB2Periph; 802576e: ea22 0000 bic.w r0, r2, r0 8025772: 6358 str r0, [r3, #52] ; 0x34 8025774: 4770 bx lr 8025776: bf00 nop 8025778: 40023800 .word 0x40023800 0802577c : * @param NewState: new state of the specified peripheral clock. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_APB1PeriphClockCmd(uint32_t RCC_APB1Periph, FunctionalState NewState) { 802577c: 4b04 ldr r3, [pc, #16] ; (8025790 ) assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->APB1ENR |= RCC_APB1Periph; 802577e: 6c1a ldr r2, [r3, #64] ; 0x40 { /* Check the parameters */ assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025780: b109 cbz r1, 8025786 { RCC->APB1ENR |= RCC_APB1Periph; 8025782: 4310 orrs r0, r2 8025784: e001 b.n 802578a } else { RCC->APB1ENR &= ~RCC_APB1Periph; 8025786: ea22 0000 bic.w r0, r2, r0 802578a: 6418 str r0, [r3, #64] ; 0x40 802578c: 4770 bx lr 802578e: bf00 nop 8025790: 40023800 .word 0x40023800 08025794 : * @param NewState: new state of the specified peripheral clock. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_APB2PeriphClockCmd(uint32_t RCC_APB2Periph, FunctionalState NewState) { 8025794: 4b04 ldr r3, [pc, #16] ; (80257a8 ) assert_param(IS_RCC_APB2_PERIPH(RCC_APB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->APB2ENR |= RCC_APB2Periph; 8025796: 6c5a ldr r2, [r3, #68] ; 0x44 { /* Check the parameters */ assert_param(IS_RCC_APB2_PERIPH(RCC_APB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025798: b109 cbz r1, 802579e { RCC->APB2ENR |= RCC_APB2Periph; 802579a: 4310 orrs r0, r2 802579c: e001 b.n 80257a2 } else { RCC->APB2ENR &= ~RCC_APB2Periph; 802579e: ea22 0000 bic.w r0, r2, r0 80257a2: 6458 str r0, [r3, #68] ; 0x44 80257a4: 4770 bx lr 80257a6: bf00 nop 80257a8: 40023800 .word 0x40023800 080257ac : * @param NewState: new state of the specified peripheral reset. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_AHB1PeriphResetCmd(uint32_t RCC_AHB1Periph, FunctionalState NewState) { 80257ac: 4b04 ldr r3, [pc, #16] ; (80257c0 ) assert_param(IS_RCC_AHB1_RESET_PERIPH(RCC_AHB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->AHB1RSTR |= RCC_AHB1Periph; 80257ae: 691a ldr r2, [r3, #16] { /* Check the parameters */ assert_param(IS_RCC_AHB1_RESET_PERIPH(RCC_AHB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80257b0: b109 cbz r1, 80257b6 { RCC->AHB1RSTR |= RCC_AHB1Periph; 80257b2: 4310 orrs r0, r2 80257b4: e001 b.n 80257ba } else { RCC->AHB1RSTR &= ~RCC_AHB1Periph; 80257b6: ea22 0000 bic.w r0, r2, r0 80257ba: 6118 str r0, [r3, #16] 80257bc: 4770 bx lr 80257be: bf00 nop 80257c0: 40023800 .word 0x40023800 080257c4 : * @param NewState: new state of the specified peripheral reset. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_APB1PeriphResetCmd(uint32_t RCC_APB1Periph, FunctionalState NewState) { 80257c4: 4b04 ldr r3, [pc, #16] ; (80257d8 ) /* Check the parameters */ assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->APB1RSTR |= RCC_APB1Periph; 80257c6: 6a1a ldr r2, [r3, #32] void RCC_APB1PeriphResetCmd(uint32_t RCC_APB1Periph, FunctionalState NewState) { /* Check the parameters */ assert_param(IS_RCC_APB1_PERIPH(RCC_APB1Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80257c8: b109 cbz r1, 80257ce { RCC->APB1RSTR |= RCC_APB1Periph; 80257ca: 4310 orrs r0, r2 80257cc: e001 b.n 80257d2 } else { RCC->APB1RSTR &= ~RCC_APB1Periph; 80257ce: ea22 0000 bic.w r0, r2, r0 80257d2: 6218 str r0, [r3, #32] 80257d4: 4770 bx lr 80257d6: bf00 nop 80257d8: 40023800 .word 0x40023800 080257dc : * @param NewState: new state of the specified peripheral reset. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RCC_APB2PeriphResetCmd(uint32_t RCC_APB2Periph, FunctionalState NewState) { 80257dc: 4b04 ldr r3, [pc, #16] ; (80257f0 ) /* Check the parameters */ assert_param(IS_RCC_APB2_RESET_PERIPH(RCC_APB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { RCC->APB2RSTR |= RCC_APB2Periph; 80257de: 6a5a ldr r2, [r3, #36] ; 0x24 void RCC_APB2PeriphResetCmd(uint32_t RCC_APB2Periph, FunctionalState NewState) { /* Check the parameters */ assert_param(IS_RCC_APB2_RESET_PERIPH(RCC_APB2Periph)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80257e0: b109 cbz r1, 80257e6 { RCC->APB2RSTR |= RCC_APB2Periph; 80257e2: 4310 orrs r0, r2 80257e4: e001 b.n 80257ea } else { RCC->APB2RSTR &= ~RCC_APB2Periph; 80257e6: ea22 0000 bic.w r0, r2, r0 80257ea: 6258 str r0, [r3, #36] ; 0x24 80257ec: 4770 bx lr 80257ee: bf00 nop 80257f0: 40023800 .word 0x40023800 080257f4 : /* Check the parameters */ assert_param(IS_RCC_FLAG(RCC_FLAG)); /* Get the RCC register index */ tmp = RCC_FLAG >> 5; 80257f4: 0943 lsrs r3, r0, #5 if (tmp == 1) /* The flag to check is in CR register */ 80257f6: 2b01 cmp r3, #1 80257f8: 4a07 ldr r2, [pc, #28] ; (8025818 ) 80257fa: d101 bne.n 8025800 { statusreg = RCC->CR; 80257fc: 6813 ldr r3, [r2, #0] 80257fe: e003 b.n 8025808 } else if (tmp == 2) /* The flag to check is in BDCR register */ 8025800: 2b02 cmp r3, #2 { statusreg = RCC->BDCR; 8025802: bf0c ite eq 8025804: 6f13 ldreq r3, [r2, #112] ; 0x70 } else /* The flag to check is in CSR register */ { statusreg = RCC->CSR; 8025806: 6f53 ldrne r3, [r2, #116] ; 0x74 } /* Get the flag position */ tmp = RCC_FLAG & FLAG_MASK; if ((statusreg & ((uint32_t)1 << tmp)) != (uint32_t)RESET) 8025808: f000 001f and.w r0, r0, #31 802580c: fa23 f000 lsr.w r0, r3, r0 { bitstatus = RESET; } /* Return the flag status */ return bitstatus; } 8025810: f000 0001 and.w r0, r0, #1 8025814: 4770 bx lr 8025816: bf00 nop 8025818: 40023800 .word 0x40023800 0802581c : * @param NewState: new state of the RNG peripheral. * This parameter can be: ENABLE or DISABLE. * @retval None */ void RNG_Cmd(FunctionalState NewState) { 802581c: 4b04 ldr r3, [pc, #16] ; (8025830 ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the RNG */ RNG->CR |= RNG_CR_RNGEN; 802581e: 681a ldr r2, [r3, #0] void RNG_Cmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025820: b110 cbz r0, 8025828 { /* Enable the RNG */ RNG->CR |= RNG_CR_RNGEN; 8025822: f042 0204 orr.w r2, r2, #4 8025826: e001 b.n 802582c } else { /* Disable the RNG */ RNG->CR &= ~RNG_CR_RNGEN; 8025828: f022 0204 bic.w r2, r2, #4 802582c: 601a str r2, [r3, #0] 802582e: 4770 bx lr 8025830: 50060800 .word 0x50060800 08025834 : * @retval 32-bit random number. */ uint32_t RNG_GetRandomNumber(void) { /* Return the 32 bit random number from the DR register */ return RNG->DR; 8025834: 4b01 ldr r3, [pc, #4] ; (802583c ) 8025836: 6898 ldr r0, [r3, #8] } 8025838: 4770 bx lr 802583a: bf00 nop 802583c: 50060800 .word 0x50060800 08025840 : * @param Value: Byte to be converted. * @retval Converted byte */ static uint8_t RTC_ByteToBcd2(uint8_t Value) { uint8_t bcdhigh = 0; 8025840: 2300 movs r3, #0 while (Value >= 10) 8025842: e003 b.n 802584c { bcdhigh++; 8025844: 3301 adds r3, #1 Value -= 10; 8025846: 380a subs r0, #10 { uint8_t bcdhigh = 0; while (Value >= 10) { bcdhigh++; 8025848: b2db uxtb r3, r3 Value -= 10; 802584a: b2c0 uxtb r0, r0 */ static uint8_t RTC_ByteToBcd2(uint8_t Value) { uint8_t bcdhigh = 0; while (Value >= 10) 802584c: 2809 cmp r0, #9 802584e: d8f9 bhi.n 8025844 { bcdhigh++; Value -= 10; } return ((uint8_t)(bcdhigh << 4) | Value); 8025850: ea40 1003 orr.w r0, r0, r3, lsl #4 } 8025854: b2c0 uxtb r0, r0 8025856: 4770 bx lr 08025858 : * @retval Converted word */ static uint8_t RTC_Bcd2ToByte(uint8_t Value) { uint8_t tmp = 0; tmp = ((uint8_t)(Value & (uint8_t)0xF0) >> (uint8_t)0x4) * 10; 8025858: 0902 lsrs r2, r0, #4 return (tmp + (Value & (uint8_t)0x0F)); 802585a: f000 030f and.w r3, r0, #15 802585e: 200a movs r0, #10 8025860: fb00 3002 mla r0, r0, r2, r3 } 8025864: b2c0 uxtb r0, r0 8025866: 4770 bx lr 08025868 : * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC is in Init mode * - ERROR: RTC is not in Init mode */ ErrorStatus RTC_EnterInitMode(void) { 8025868: b082 sub sp, #8 __IO uint32_t initcounter = 0x00; 802586a: 2300 movs r3, #0 802586c: 9301 str r3, [sp, #4] ErrorStatus status = ERROR; uint32_t initstatus = 0x00; /* Check if the Initialization mode is set */ if ((RTC->ISR & RTC_ISR_INITF) == (uint32_t)RESET) 802586e: 4b0d ldr r3, [pc, #52] ; (80258a4 ) 8025870: 68da ldr r2, [r3, #12] 8025872: 0650 lsls r0, r2, #25 8025874: d413 bmi.n 802589e { /* Set the Initialization mode */ RTC->ISR = (uint32_t)RTC_INIT_MASK; 8025876: f04f 32ff mov.w r2, #4294967295 802587a: 60da str r2, [r3, #12] /* Wait till RTC is in INIT state and if Time out is reached exit */ do { initstatus = RTC->ISR & RTC_ISR_INITF; 802587c: 68da ldr r2, [r3, #12] initcounter++; 802587e: 9901 ldr r1, [sp, #4] 8025880: 3101 adds r1, #1 8025882: 9101 str r1, [sp, #4] } while((initcounter != INITMODE_TIMEOUT) && (initstatus == 0x00)); 8025884: 9901 ldr r1, [sp, #4] 8025886: f5b1 3f80 cmp.w r1, #65536 ; 0x10000 RTC->ISR = (uint32_t)RTC_INIT_MASK; /* Wait till RTC is in INIT state and if Time out is reached exit */ do { initstatus = RTC->ISR & RTC_ISR_INITF; 802588a: f002 0240 and.w r2, r2, #64 ; 0x40 initcounter++; } while((initcounter != INITMODE_TIMEOUT) && (initstatus == 0x00)); 802588e: d001 beq.n 8025894 8025890: 2a00 cmp r2, #0 8025892: d0f3 beq.n 802587c if ((RTC->ISR & RTC_ISR_INITF) != RESET) 8025894: 4b03 ldr r3, [pc, #12] ; (80258a4 ) 8025896: 68d8 ldr r0, [r3, #12] { status = SUCCESS; 8025898: f3c0 1080 ubfx r0, r0, #6, #1 802589c: e000 b.n 80258a0 status = ERROR; } } else { status = SUCCESS; 802589e: 2001 movs r0, #1 } return (status); } 80258a0: b002 add sp, #8 80258a2: 4770 bx lr 80258a4: 40002800 .word 0x40002800 080258a8 : * @retval None */ void RTC_ExitInitMode(void) { /* Exit Initialization mode */ RTC->ISR &= (uint32_t)~RTC_ISR_INIT; 80258a8: 4b02 ldr r3, [pc, #8] ; (80258b4 ) 80258aa: 68da ldr r2, [r3, #12] 80258ac: f022 0280 bic.w r2, r2, #128 ; 0x80 80258b0: 60da str r2, [r3, #12] 80258b2: 4770 bx lr 80258b4: 40002800 .word 0x40002800 080258b8 : * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC registers are initialized * - ERROR: RTC registers are not initialized */ ErrorStatus RTC_Init(RTC_InitTypeDef* RTC_InitStruct) { 80258b8: b538 push {r3, r4, r5, lr} assert_param(IS_RTC_HOUR_FORMAT(RTC_InitStruct->RTC_HourFormat)); assert_param(IS_RTC_ASYNCH_PREDIV(RTC_InitStruct->RTC_AsynchPrediv)); assert_param(IS_RTC_SYNCH_PREDIV(RTC_InitStruct->RTC_SynchPrediv)); /* Disable the write protection for RTC registers */ RTC->WPR = 0xCA; 80258ba: 4c0f ldr r4, [pc, #60] ; (80258f8 ) 80258bc: 23ca movs r3, #202 ; 0xca 80258be: 6263 str r3, [r4, #36] ; 0x24 RTC->WPR = 0x53; 80258c0: 2353 movs r3, #83 ; 0x53 80258c2: 6263 str r3, [r4, #36] ; 0x24 * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC registers are initialized * - ERROR: RTC registers are not initialized */ ErrorStatus RTC_Init(RTC_InitTypeDef* RTC_InitStruct) { 80258c4: 4605 mov r5, r0 /* Disable the write protection for RTC registers */ RTC->WPR = 0xCA; RTC->WPR = 0x53; /* Set Initialization mode */ if (RTC_EnterInitMode() == ERROR) 80258c6: f7ff ffcf bl 8025868 80258ca: b188 cbz r0, 80258f0 status = ERROR; } else { /* Clear RTC CR FMT Bit */ RTC->CR &= ((uint32_t)~(RTC_CR_FMT)); 80258cc: 68a3 ldr r3, [r4, #8] 80258ce: f023 0340 bic.w r3, r3, #64 ; 0x40 80258d2: 60a3 str r3, [r4, #8] /* Set RTC_CR register */ RTC->CR |= ((uint32_t)(RTC_InitStruct->RTC_HourFormat)); 80258d4: 68a2 ldr r2, [r4, #8] 80258d6: 682b ldr r3, [r5, #0] 80258d8: 4313 orrs r3, r2 80258da: 60a3 str r3, [r4, #8] /* Configure the RTC PRER */ RTC->PRER = (uint32_t)(RTC_InitStruct->RTC_SynchPrediv); 80258dc: 68ab ldr r3, [r5, #8] 80258de: 6123 str r3, [r4, #16] RTC->PRER |= (uint32_t)(RTC_InitStruct->RTC_AsynchPrediv << 16); 80258e0: 6923 ldr r3, [r4, #16] 80258e2: 686a ldr r2, [r5, #4] 80258e4: ea43 4302 orr.w r3, r3, r2, lsl #16 80258e8: 6123 str r3, [r4, #16] /* Exit Initialization mode */ RTC_ExitInitMode(); 80258ea: f7ff ffdd bl 80258a8 status = SUCCESS; 80258ee: 2001 movs r0, #1 } /* Enable the write protection for RTC registers */ RTC->WPR = 0xFF; 80258f0: 4b01 ldr r3, [pc, #4] ; (80258f8 ) 80258f2: 22ff movs r2, #255 ; 0xff 80258f4: 625a str r2, [r3, #36] ; 0x24 return status; } 80258f6: bd38 pop {r3, r4, r5, pc} 80258f8: 40002800 .word 0x40002800 080258fc : * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC registers are synchronised * - ERROR: RTC registers are not synchronised */ ErrorStatus RTC_WaitForSynchro(void) { 80258fc: b082 sub sp, #8 __IO uint32_t synchrocounter = 0; 80258fe: 2300 movs r3, #0 8025900: 9301 str r3, [sp, #4] ErrorStatus status = ERROR; uint32_t synchrostatus = 0x00; /* Disable the write protection for RTC registers */ RTC->WPR = 0xCA; 8025902: 4b0e ldr r3, [pc, #56] ; (802593c ) 8025904: 22ca movs r2, #202 ; 0xca 8025906: 625a str r2, [r3, #36] ; 0x24 RTC->WPR = 0x53; 8025908: 2253 movs r2, #83 ; 0x53 802590a: 625a str r2, [r3, #36] ; 0x24 /* Clear RSF flag */ RTC->ISR &= (uint32_t)RTC_RSF_MASK; 802590c: 68da ldr r2, [r3, #12] 802590e: f022 02a0 bic.w r2, r2, #160 ; 0xa0 8025912: 60da str r2, [r3, #12] /* Wait the registers to be synchronised */ do { synchrostatus = RTC->ISR & RTC_ISR_RSF; 8025914: 68d9 ldr r1, [r3, #12] synchrocounter++; 8025916: 9a01 ldr r2, [sp, #4] 8025918: 3201 adds r2, #1 802591a: 9201 str r2, [sp, #4] } while((synchrocounter != SYNCHRO_TIMEOUT) && (synchrostatus == 0x00)); 802591c: 9a01 ldr r2, [sp, #4] 802591e: f5b2 3f00 cmp.w r2, #131072 ; 0x20000 RTC->ISR &= (uint32_t)RTC_RSF_MASK; /* Wait the registers to be synchronised */ do { synchrostatus = RTC->ISR & RTC_ISR_RSF; 8025922: f001 0120 and.w r1, r1, #32 8025926: 4a05 ldr r2, [pc, #20] ; (802593c ) synchrocounter++; } while((synchrocounter != SYNCHRO_TIMEOUT) && (synchrostatus == 0x00)); 8025928: d001 beq.n 802592e 802592a: 2900 cmp r1, #0 802592c: d0f2 beq.n 8025914 if ((RTC->ISR & RTC_ISR_RSF) != RESET) 802592e: 68d0 ldr r0, [r2, #12] { status = ERROR; } /* Enable the write protection for RTC registers */ RTC->WPR = 0xFF; 8025930: 23ff movs r3, #255 ; 0xff 8025932: 6253 str r3, [r2, #36] ; 0x24 return (status); } 8025934: f3c0 1040 ubfx r0, r0, #5, #1 8025938: b002 add sp, #8 802593a: 4770 bx lr 802593c: 40002800 .word 0x40002800 08025940 : * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC Time register is configured * - ERROR: RTC Time register is not configured */ ErrorStatus RTC_SetTime(uint32_t RTC_Format, RTC_TimeTypeDef* RTC_TimeStruct) { 8025940: b5f8 push {r3, r4, r5, r6, r7, lr} 8025942: 4b24 ldr r3, [pc, #144] ; (80259d4 ) 8025944: 460c mov r4, r1 /* Check the parameters */ assert_param(IS_RTC_FORMAT(RTC_Format)); if (RTC_Format == RTC_Format_BIN) { if ((RTC->CR & RTC_CR_FMT) != (uint32_t)RESET) 8025946: 689b ldr r3, [r3, #8] ErrorStatus status = ERROR; /* Check the parameters */ assert_param(IS_RTC_FORMAT(RTC_Format)); if (RTC_Format == RTC_Format_BIN) 8025948: b920 cbnz r0, 8025954 { if ((RTC->CR & RTC_CR_FMT) != (uint32_t)RESET) 802594a: f013 0340 ands.w r3, r3, #64 ; 0x40 802594e: d12e bne.n 80259ae assert_param(IS_RTC_HOUR12(RTC_TimeStruct->RTC_Hours)); assert_param(IS_RTC_H12(RTC_TimeStruct->RTC_H12)); } else { RTC_TimeStruct->RTC_H12 = 0x00; 8025950: 70cb strb r3, [r1, #3] 8025952: e02c b.n 80259ae assert_param(IS_RTC_MINUTES(RTC_TimeStruct->RTC_Minutes)); assert_param(IS_RTC_SECONDS(RTC_TimeStruct->RTC_Seconds)); } else { if ((RTC->CR & RTC_CR_FMT) != (uint32_t)RESET) 8025954: f013 0340 ands.w r3, r3, #64 ; 0x40 8025958: d11e bne.n 8025998 assert_param(IS_RTC_HOUR12(tmpreg)); assert_param(IS_RTC_H12(RTC_TimeStruct->RTC_H12)); } else { RTC_TimeStruct->RTC_H12 = 0x00; 802595a: 70cb strb r3, [r1, #3] 802595c: e01c b.n 8025998 ((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Seconds)) | \ (((uint32_t)RTC_TimeStruct->RTC_H12) << 16)); } /* Disable the write protection for RTC registers */ RTC->WPR = 0xCA; 802595e: 4c1d ldr r4, [pc, #116] ; (80259d4 ) 8025960: 23ca movs r3, #202 ; 0xca 8025962: 6263 str r3, [r4, #36] ; 0x24 RTC->WPR = 0x53; 8025964: 2353 movs r3, #83 ; 0x53 8025966: 6263 str r3, [r4, #36] ; 0x24 /* Set Initialization mode */ if (RTC_EnterInitMode() == ERROR) 8025968: f7ff ff7e bl 8025868 802596c: b180 cbz r0, 8025990 status = ERROR; } else { /* Set the RTC_TR register */ RTC->TR = (uint32_t)(tmpreg & RTC_TR_RESERVED_MASK); 802596e: f005 357f and.w r5, r5, #2139062143 ; 0x7f7f7f7f 8025972: f025 45fe bic.w r5, r5, #2130706432 ; 0x7f000000 8025976: 6025 str r5, [r4, #0] /* Exit Initialization mode */ RTC_ExitInitMode(); 8025978: f7ff ff96 bl 80258a8 /* If RTC_CR_BYPSHAD bit = 0, wait for synchro else this check is not needed */ if ((RTC->CR & RTC_CR_BYPSHAD) == RESET) 802597c: 68a3 ldr r3, [r4, #8] 802597e: 0699 lsls r1, r3, #26 8025980: d405 bmi.n 802598e { if (RTC_WaitForSynchro() == ERROR) 8025982: f7ff ffbb bl 80258fc RTC->WPR = 0x53; /* Set Initialization mode */ if (RTC_EnterInitMode() == ERROR) { status = ERROR; 8025986: 3000 adds r0, #0 8025988: bf18 it ne 802598a: 2001 movne r0, #1 802598c: e000 b.n 8025990 status = SUCCESS; } } else { status = SUCCESS; 802598e: 2001 movs r0, #1 } } /* Enable the write protection for RTC registers */ RTC->WPR = 0xFF; 8025990: 4b10 ldr r3, [pc, #64] ; (80259d4 ) 8025992: 22ff movs r2, #255 ; 0xff 8025994: 625a str r2, [r3, #36] ; 0x24 8025996: bdf8 pop {r3, r4, r5, r6, r7, pc} /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = (((uint32_t)(RTC_TimeStruct->RTC_Hours) << 16) | \ ((uint32_t)(RTC_TimeStruct->RTC_Minutes) << 8) | \ 8025998: 7865 ldrb r5, [r4, #1] } /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = (((uint32_t)(RTC_TimeStruct->RTC_Hours) << 16) | \ 802599a: 7823 ldrb r3, [r4, #0] ((uint32_t)(RTC_TimeStruct->RTC_Minutes) << 8) | \ 802599c: 022d lsls r5, r5, #8 } /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = (((uint32_t)(RTC_TimeStruct->RTC_Hours) << 16) | \ 802599e: ea45 4503 orr.w r5, r5, r3, lsl #16 ((uint32_t)(RTC_TimeStruct->RTC_Minutes) << 8) | \ ((uint32_t)RTC_TimeStruct->RTC_Seconds) | \ 80259a2: 78a3 ldrb r3, [r4, #2] /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = (((uint32_t)(RTC_TimeStruct->RTC_Hours) << 16) | \ ((uint32_t)(RTC_TimeStruct->RTC_Minutes) << 8) | \ 80259a4: 431d orrs r5, r3 ((uint32_t)RTC_TimeStruct->RTC_Seconds) | \ ((uint32_t)(RTC_TimeStruct->RTC_H12) << 16)); 80259a6: 78e3 ldrb r3, [r4, #3] } /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = (((uint32_t)(RTC_TimeStruct->RTC_Hours) << 16) | \ 80259a8: ea45 4503 orr.w r5, r5, r3, lsl #16 80259ac: e7d7 b.n 802595e ((uint32_t)RTC_TimeStruct->RTC_Seconds) | \ ((uint32_t)(RTC_TimeStruct->RTC_H12) << 16)); } else { tmpreg = (uint32_t)(((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Hours) << 16) | \ 80259ae: 7820 ldrb r0, [r4, #0] 80259b0: f7ff ff46 bl 8025840 80259b4: 4607 mov r7, r0 ((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Minutes) << 8) | \ 80259b6: 7860 ldrb r0, [r4, #1] 80259b8: f7ff ff42 bl 8025840 80259bc: 4606 mov r6, r0 ((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Seconds)) | \ 80259be: 78a0 ldrb r0, [r4, #2] 80259c0: f7ff ff3e bl 8025840 (((uint32_t)RTC_TimeStruct->RTC_H12) << 16)); 80259c4: 78e5 ldrb r5, [r4, #3] ((uint32_t)RTC_TimeStruct->RTC_Seconds) | \ ((uint32_t)(RTC_TimeStruct->RTC_H12) << 16)); } else { tmpreg = (uint32_t)(((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Hours) << 16) | \ 80259c6: ea40 4005 orr.w r0, r0, r5, lsl #16 ((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Minutes) << 8) | \ 80259ca: ea40 4507 orr.w r5, r0, r7, lsl #16 ((uint32_t)RTC_TimeStruct->RTC_Seconds) | \ ((uint32_t)(RTC_TimeStruct->RTC_H12) << 16)); } else { tmpreg = (uint32_t)(((uint32_t)RTC_ByteToBcd2(RTC_TimeStruct->RTC_Hours) << 16) | \ 80259ce: ea45 2506 orr.w r5, r5, r6, lsl #8 80259d2: e7c4 b.n 802595e 80259d4: 40002800 .word 0x40002800 080259d8 : /* Check the parameters */ assert_param(IS_RTC_FORMAT(RTC_Format)); /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->TR & RTC_TR_RESERVED_MASK); 80259d8: 4b0f ldr r3, [pc, #60] ; (8025a18 ) 80259da: 681b ldr r3, [r3, #0] * @param RTC_TimeStruct: pointer to a RTC_TimeTypeDef structure that will * contain the returned current time configuration. * @retval None */ void RTC_GetTime(uint32_t RTC_Format, RTC_TimeTypeDef* RTC_TimeStruct) { 80259dc: b570 push {r4, r5, r6, lr} /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->TR & RTC_TR_RESERVED_MASK); /* Fill the structure fields with the read parameters */ RTC_TimeStruct->RTC_Hours = (uint8_t)((tmpreg & (RTC_TR_HT | RTC_TR_HU)) >> 16); 80259de: f3c3 4205 ubfx r2, r3, #16, #6 RTC_TimeStruct->RTC_Minutes = (uint8_t)((tmpreg & (RTC_TR_MNT | RTC_TR_MNU)) >>8); 80259e2: f3c3 2606 ubfx r6, r3, #8, #7 RTC_TimeStruct->RTC_Seconds = (uint8_t)(tmpreg & (RTC_TR_ST | RTC_TR_SU)); 80259e6: f003 057f and.w r5, r3, #127 ; 0x7f RTC_TimeStruct->RTC_H12 = (uint8_t)((tmpreg & (RTC_TR_PM)) >> 16); 80259ea: f403 0380 and.w r3, r3, #4194304 ; 0x400000 80259ee: 0c1b lsrs r3, r3, #16 * @param RTC_TimeStruct: pointer to a RTC_TimeTypeDef structure that will * contain the returned current time configuration. * @retval None */ void RTC_GetTime(uint32_t RTC_Format, RTC_TimeTypeDef* RTC_TimeStruct) { 80259f0: 460c mov r4, r1 /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->TR & RTC_TR_RESERVED_MASK); /* Fill the structure fields with the read parameters */ RTC_TimeStruct->RTC_Hours = (uint8_t)((tmpreg & (RTC_TR_HT | RTC_TR_HU)) >> 16); 80259f2: 700a strb r2, [r1, #0] RTC_TimeStruct->RTC_Minutes = (uint8_t)((tmpreg & (RTC_TR_MNT | RTC_TR_MNU)) >>8); 80259f4: 704e strb r6, [r1, #1] RTC_TimeStruct->RTC_Seconds = (uint8_t)(tmpreg & (RTC_TR_ST | RTC_TR_SU)); 80259f6: 708d strb r5, [r1, #2] RTC_TimeStruct->RTC_H12 = (uint8_t)((tmpreg & (RTC_TR_PM)) >> 16); 80259f8: 70cb strb r3, [r1, #3] /* Check the input parameters format */ if (RTC_Format == RTC_Format_BIN) 80259fa: b958 cbnz r0, 8025a14 { /* Convert the structure parameters to Binary format */ RTC_TimeStruct->RTC_Hours = (uint8_t)RTC_Bcd2ToByte(RTC_TimeStruct->RTC_Hours); 80259fc: 4610 mov r0, r2 80259fe: f7ff ff2b bl 8025858 8025a02: 7020 strb r0, [r4, #0] RTC_TimeStruct->RTC_Minutes = (uint8_t)RTC_Bcd2ToByte(RTC_TimeStruct->RTC_Minutes); 8025a04: 4630 mov r0, r6 8025a06: f7ff ff27 bl 8025858 8025a0a: 7060 strb r0, [r4, #1] RTC_TimeStruct->RTC_Seconds = (uint8_t)RTC_Bcd2ToByte(RTC_TimeStruct->RTC_Seconds); 8025a0c: 4628 mov r0, r5 8025a0e: f7ff ff23 bl 8025858 8025a12: 70a0 strb r0, [r4, #2] 8025a14: bd70 pop {r4, r5, r6, pc} 8025a16: bf00 nop 8025a18: 40002800 .word 0x40002800 08025a1c : * @retval An ErrorStatus enumeration value: * - SUCCESS: RTC Date register is configured * - ERROR: RTC Date register is not configured */ ErrorStatus RTC_SetDate(uint32_t RTC_Format, RTC_DateTypeDef* RTC_DateStruct) { 8025a1c: b5f8 push {r3, r4, r5, r6, r7, lr} 8025a1e: 460c mov r4, r1 8025a20: 784b ldrb r3, [r1, #1] ErrorStatus status = ERROR; /* Check the parameters */ assert_param(IS_RTC_FORMAT(RTC_Format)); if ((RTC_Format == RTC_Format_BIN) && ((RTC_DateStruct->RTC_Month & 0x10) == 0x10)) 8025a22: 2800 cmp r0, #0 8025a24: d138 bne.n 8025a98 8025a26: f003 0210 and.w r2, r3, #16 8025a2a: b2d2 uxtb r2, r2 8025a2c: b30a cbz r2, 8025a72 { RTC_DateStruct->RTC_Month = (RTC_DateStruct->RTC_Month & (uint32_t)~(0x10)) + 0x0A; 8025a2e: f023 0310 bic.w r3, r3, #16 8025a32: 330a adds r3, #10 8025a34: 704b strb r3, [r1, #1] 8025a36: e01c b.n 8025a72 ((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Date)) | \ ((uint32_t)RTC_DateStruct->RTC_WeekDay << 13)); } /* Disable the write protection for RTC registers */ RTC->WPR = 0xCA; 8025a38: 4c1c ldr r4, [pc, #112] ; (8025aac ) 8025a3a: 23ca movs r3, #202 ; 0xca 8025a3c: 6263 str r3, [r4, #36] ; 0x24 RTC->WPR = 0x53; 8025a3e: 2353 movs r3, #83 ; 0x53 8025a40: 6263 str r3, [r4, #36] ; 0x24 /* Set Initialization mode */ if (RTC_EnterInitMode() == ERROR) 8025a42: f7ff ff11 bl 8025868 8025a46: b180 cbz r0, 8025a6a status = ERROR; } else { /* Set the RTC_DR register */ RTC->DR = (uint32_t)(tmpreg & RTC_DR_RESERVED_MASK); 8025a48: f025 457f bic.w r5, r5, #4278190080 ; 0xff000000 8025a4c: f025 05c0 bic.w r5, r5, #192 ; 0xc0 8025a50: 6065 str r5, [r4, #4] /* Exit Initialization mode */ RTC_ExitInitMode(); 8025a52: f7ff ff29 bl 80258a8 /* If RTC_CR_BYPSHAD bit = 0, wait for synchro else this check is not needed */ if ((RTC->CR & RTC_CR_BYPSHAD) == RESET) 8025a56: 68a3 ldr r3, [r4, #8] 8025a58: 0698 lsls r0, r3, #26 8025a5a: d405 bmi.n 8025a68 { if (RTC_WaitForSynchro() == ERROR) 8025a5c: f7ff ff4e bl 80258fc RTC->WPR = 0x53; /* Set Initialization mode */ if (RTC_EnterInitMode() == ERROR) { status = ERROR; 8025a60: 3000 adds r0, #0 8025a62: bf18 it ne 8025a64: 2001 movne r0, #1 8025a66: e000 b.n 8025a6a status = SUCCESS; } } else { status = SUCCESS; 8025a68: 2001 movs r0, #1 } } /* Enable the write protection for RTC registers */ RTC->WPR = 0xFF; 8025a6a: 4b10 ldr r3, [pc, #64] ; (8025aac ) 8025a6c: 22ff movs r2, #255 ; 0xff 8025a6e: 625a str r2, [r3, #36] ; 0x24 8025a70: bdf8 pop {r3, r4, r5, r6, r7, pc} ((uint32_t)RTC_DateStruct->RTC_Date) | \ (((uint32_t)RTC_DateStruct->RTC_WeekDay) << 13)); } else { tmpreg = (((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Year) << 16) | \ 8025a72: 78e0 ldrb r0, [r4, #3] 8025a74: f7ff fee4 bl 8025840 8025a78: 4607 mov r7, r0 ((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Month) << 8) | \ 8025a7a: 7860 ldrb r0, [r4, #1] 8025a7c: f7ff fee0 bl 8025840 8025a80: 4606 mov r6, r0 ((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Date)) | \ 8025a82: 78a0 ldrb r0, [r4, #2] 8025a84: f7ff fedc bl 8025840 ((uint32_t)RTC_DateStruct->RTC_WeekDay << 13)); 8025a88: 7825 ldrb r5, [r4, #0] ((uint32_t)RTC_DateStruct->RTC_Date) | \ (((uint32_t)RTC_DateStruct->RTC_WeekDay) << 13)); } else { tmpreg = (((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Year) << 16) | \ 8025a8a: ea40 3045 orr.w r0, r0, r5, lsl #13 ((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Month) << 8) | \ 8025a8e: ea40 4507 orr.w r5, r0, r7, lsl #16 ((uint32_t)RTC_DateStruct->RTC_Date) | \ (((uint32_t)RTC_DateStruct->RTC_WeekDay) << 13)); } else { tmpreg = (((uint32_t)RTC_ByteToBcd2(RTC_DateStruct->RTC_Year) << 16) | \ 8025a92: ea45 2506 orr.w r5, r5, r6, lsl #8 8025a96: e7cf b.n 8025a38 assert_param(IS_RTC_WEEKDAY(RTC_DateStruct->RTC_WeekDay)); /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = ((((uint32_t)RTC_DateStruct->RTC_Year) << 16) | \ 8025a98: 78cd ldrb r5, [r1, #3] (((uint32_t)RTC_DateStruct->RTC_Month) << 8) | \ ((uint32_t)RTC_DateStruct->RTC_Date) | \ 8025a9a: 788a ldrb r2, [r1, #2] /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = ((((uint32_t)RTC_DateStruct->RTC_Year) << 16) | \ (((uint32_t)RTC_DateStruct->RTC_Month) << 8) | \ 8025a9c: 021b lsls r3, r3, #8 assert_param(IS_RTC_WEEKDAY(RTC_DateStruct->RTC_WeekDay)); /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = ((((uint32_t)RTC_DateStruct->RTC_Year) << 16) | \ 8025a9e: ea43 4505 orr.w r5, r3, r5, lsl #16 (((uint32_t)RTC_DateStruct->RTC_Month) << 8) | \ ((uint32_t)RTC_DateStruct->RTC_Date) | \ (((uint32_t)RTC_DateStruct->RTC_WeekDay) << 13)); 8025aa2: 780b ldrb r3, [r1, #0] /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = ((((uint32_t)RTC_DateStruct->RTC_Year) << 16) | \ (((uint32_t)RTC_DateStruct->RTC_Month) << 8) | \ 8025aa4: 4315 orrs r5, r2 assert_param(IS_RTC_WEEKDAY(RTC_DateStruct->RTC_WeekDay)); /* Check the input parameters format */ if (RTC_Format != RTC_Format_BIN) { tmpreg = ((((uint32_t)RTC_DateStruct->RTC_Year) << 16) | \ 8025aa6: ea45 3543 orr.w r5, r5, r3, lsl #13 8025aaa: e7c5 b.n 8025a38 8025aac: 40002800 .word 0x40002800 08025ab0 : /* Check the parameters */ assert_param(IS_RTC_FORMAT(RTC_Format)); /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->DR & RTC_DR_RESERVED_MASK); 8025ab0: 4b0e ldr r3, [pc, #56] ; (8025aec ) 8025ab2: 685b ldr r3, [r3, #4] * @param RTC_DateStruct: pointer to a RTC_DateTypeDef structure that will * contain the returned current date configuration. * @retval None */ void RTC_GetDate(uint32_t RTC_Format, RTC_DateTypeDef* RTC_DateStruct) { 8025ab4: b570 push {r4, r5, r6, lr} /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->DR & RTC_DR_RESERVED_MASK); /* Fill the structure fields with the read parameters */ RTC_DateStruct->RTC_Year = (uint8_t)((tmpreg & (RTC_DR_YT | RTC_DR_YU)) >> 16); 8025ab6: f3c3 4207 ubfx r2, r3, #16, #8 RTC_DateStruct->RTC_Month = (uint8_t)((tmpreg & (RTC_DR_MT | RTC_DR_MU)) >> 8); 8025aba: f3c3 2604 ubfx r6, r3, #8, #5 RTC_DateStruct->RTC_Date = (uint8_t)(tmpreg & (RTC_DR_DT | RTC_DR_DU)); 8025abe: f003 053f and.w r5, r3, #63 ; 0x3f RTC_DateStruct->RTC_WeekDay = (uint8_t)((tmpreg & (RTC_DR_WDU)) >> 13); 8025ac2: f3c3 3342 ubfx r3, r3, #13, #3 * @param RTC_DateStruct: pointer to a RTC_DateTypeDef structure that will * contain the returned current date configuration. * @retval None */ void RTC_GetDate(uint32_t RTC_Format, RTC_DateTypeDef* RTC_DateStruct) { 8025ac6: 460c mov r4, r1 /* Get the RTC_TR register */ tmpreg = (uint32_t)(RTC->DR & RTC_DR_RESERVED_MASK); /* Fill the structure fields with the read parameters */ RTC_DateStruct->RTC_Year = (uint8_t)((tmpreg & (RTC_DR_YT | RTC_DR_YU)) >> 16); 8025ac8: 70ca strb r2, [r1, #3] RTC_DateStruct->RTC_Month = (uint8_t)((tmpreg & (RTC_DR_MT | RTC_DR_MU)) >> 8); 8025aca: 704e strb r6, [r1, #1] RTC_DateStruct->RTC_Date = (uint8_t)(tmpreg & (RTC_DR_DT | RTC_DR_DU)); 8025acc: 708d strb r5, [r1, #2] RTC_DateStruct->RTC_WeekDay = (uint8_t)((tmpreg & (RTC_DR_WDU)) >> 13); 8025ace: 700b strb r3, [r1, #0] /* Check the input parameters format */ if (RTC_Format == RTC_Format_BIN) 8025ad0: b958 cbnz r0, 8025aea { /* Convert the structure parameters to Binary format */ RTC_DateStruct->RTC_Year = (uint8_t)RTC_Bcd2ToByte(RTC_DateStruct->RTC_Year); 8025ad2: 4610 mov r0, r2 8025ad4: f7ff fec0 bl 8025858 8025ad8: 70e0 strb r0, [r4, #3] RTC_DateStruct->RTC_Month = (uint8_t)RTC_Bcd2ToByte(RTC_DateStruct->RTC_Month); 8025ada: 4630 mov r0, r6 8025adc: f7ff febc bl 8025858 8025ae0: 7060 strb r0, [r4, #1] RTC_DateStruct->RTC_Date = (uint8_t)RTC_Bcd2ToByte(RTC_DateStruct->RTC_Date); 8025ae2: 4628 mov r0, r5 8025ae4: f7ff feb8 bl 8025858 8025ae8: 70a0 strb r0, [r4, #2] 8025aea: bd70 pop {r4, r5, r6, pc} 8025aec: 40002800 .word 0x40002800 08025af0 : * specify the register. * @param Data: Data to be written in the specified RTC Backup data register. * @retval None */ void RTC_WriteBackupRegister(uint32_t RTC_BKP_DR, uint32_t Data) { 8025af0: b082 sub sp, #8 __IO uint32_t tmp = 0; 8025af2: 2300 movs r3, #0 8025af4: 9301 str r3, [sp, #4] /* Check the parameters */ assert_param(IS_RTC_BKP(RTC_BKP_DR)); tmp = RTC_BASE + 0x50; 8025af6: 4b05 ldr r3, [pc, #20] ; (8025b0c ) 8025af8: 9301 str r3, [sp, #4] tmp += (RTC_BKP_DR * 4); 8025afa: 9b01 ldr r3, [sp, #4] 8025afc: eb03 0080 add.w r0, r3, r0, lsl #2 8025b00: 9001 str r0, [sp, #4] /* Write the specified register */ *(__IO uint32_t *)tmp = (uint32_t)Data; 8025b02: 9b01 ldr r3, [sp, #4] 8025b04: 6019 str r1, [r3, #0] } 8025b06: b002 add sp, #8 8025b08: 4770 bx lr 8025b0a: bf00 nop 8025b0c: 40002850 .word 0x40002850 08025b10 : * This parameter can be: RTC_BKP_DRx where x can be from 0 to 19 to * specify the register. * @retval None */ uint32_t RTC_ReadBackupRegister(uint32_t RTC_BKP_DR) { 8025b10: b082 sub sp, #8 __IO uint32_t tmp = 0; 8025b12: 2300 movs r3, #0 8025b14: 9301 str r3, [sp, #4] /* Check the parameters */ assert_param(IS_RTC_BKP(RTC_BKP_DR)); tmp = RTC_BASE + 0x50; 8025b16: 4b05 ldr r3, [pc, #20] ; (8025b2c ) 8025b18: 9301 str r3, [sp, #4] tmp += (RTC_BKP_DR * 4); 8025b1a: 9b01 ldr r3, [sp, #4] 8025b1c: eb03 0080 add.w r0, r3, r0, lsl #2 8025b20: 9001 str r0, [sp, #4] /* Read the specified register */ return (*(__IO uint32_t *)tmp); 8025b22: 9b01 ldr r3, [sp, #4] 8025b24: 6818 ldr r0, [r3, #0] } 8025b26: b002 add sp, #8 8025b28: 4770 bx lr 8025b2a: bf00 nop 8025b2c: 40002850 .word 0x40002850 08025b30 : /* Check the parameters */ assert_param(IS_RTC_GET_IT(RTC_IT)); /* Get the TAMPER Interrupt enable bit and pending bit */ tmpreg = (uint32_t)(RTC->TAFCR & (RTC_TAFCR_TAMPIE)); 8025b30: 4b0a ldr r3, [pc, #40] ; (8025b5c ) 8025b32: 6c1a ldr r2, [r3, #64] ; 0x40 * @arg RTC_IT_ALRA: Alarm A interrupt * @arg RTC_IT_TAMP1: Tamper 1 event interrupt * @retval The new state of RTC_IT (SET or RESET). */ ITStatus RTC_GetITStatus(uint32_t RTC_IT) { 8025b34: b510 push {r4, lr} /* Get the TAMPER Interrupt enable bit and pending bit */ tmpreg = (uint32_t)(RTC->TAFCR & (RTC_TAFCR_TAMPIE)); /* Get the Interrupt enable Status */ enablestatus = (uint32_t)((RTC->CR & RTC_IT) | (tmpreg & (RTC_IT >> 15))); 8025b36: 689c ldr r4, [r3, #8] /* Get the Interrupt pending bit */ tmpreg = (uint32_t)((RTC->ISR & (uint32_t)(RTC_IT >> 4))); 8025b38: 68d9 ldr r1, [r3, #12] /* Check the parameters */ assert_param(IS_RTC_GET_IT(RTC_IT)); /* Get the TAMPER Interrupt enable bit and pending bit */ tmpreg = (uint32_t)(RTC->TAFCR & (RTC_TAFCR_TAMPIE)); 8025b3a: f002 0204 and.w r2, r2, #4 /* Get the Interrupt enable Status */ enablestatus = (uint32_t)((RTC->CR & RTC_IT) | (tmpreg & (RTC_IT >> 15))); 8025b3e: ea02 32d0 and.w r2, r2, r0, lsr #15 8025b42: ea00 0304 and.w r3, r0, r4 /* Get the Interrupt pending bit */ tmpreg = (uint32_t)((RTC->ISR & (uint32_t)(RTC_IT >> 4))); /* Get the status of the Interrupt */ if ((enablestatus != (uint32_t)RESET) && ((tmpreg & 0x0000FFFF) != (uint32_t)RESET)) 8025b46: 4313 orrs r3, r2 8025b48: d006 beq.n 8025b58 /* Get the Interrupt enable Status */ enablestatus = (uint32_t)((RTC->CR & RTC_IT) | (tmpreg & (RTC_IT >> 15))); /* Get the Interrupt pending bit */ tmpreg = (uint32_t)((RTC->ISR & (uint32_t)(RTC_IT >> 4))); 8025b4a: b28b uxth r3, r1 /* Get the status of the Interrupt */ if ((enablestatus != (uint32_t)RESET) && ((tmpreg & 0x0000FFFF) != (uint32_t)RESET)) 8025b4c: ea13 1310 ands.w r3, r3, r0, lsr #4 { bitstatus = SET; 8025b50: bf0c ite eq 8025b52: 2000 moveq r0, #0 8025b54: 2001 movne r0, #1 8025b56: bd10 pop {r4, pc} } else { bitstatus = RESET; 8025b58: 4618 mov r0, r3 } return bitstatus; } 8025b5a: bd10 pop {r4, pc} 8025b5c: 40002800 .word 0x40002800 08025b60 : /* Get the RTC_ISR Interrupt pending bits mask */ tmpreg = (uint32_t)(RTC_IT >> 4); /* Clear the interrupt pending bits in the RTC_ISR register */ RTC->ISR = (uint32_t)((uint32_t)(~((tmpreg | RTC_ISR_INIT)& 0x0000FFFF) | (uint32_t)(RTC->ISR & RTC_ISR_INIT))); 8025b60: 4b05 ldr r3, [pc, #20] ; (8025b78 ) 8025b62: 68da ldr r2, [r3, #12] 8025b64: f3c0 100f ubfx r0, r0, #4, #16 8025b68: f040 0080 orr.w r0, r0, #128 ; 0x80 8025b6c: f002 0280 and.w r2, r2, #128 ; 0x80 8025b70: ea62 0200 orn r2, r2, r0 8025b74: 60da str r2, [r3, #12] 8025b76: 4770 bx lr 8025b78: 40002800 .word 0x40002800 08025b7c : */ void SYSCFG_ETH_MediaInterfaceConfig(uint32_t SYSCFG_ETH_MediaInterface) { assert_param(IS_SYSCFG_ETH_MEDIA_INTERFACE(SYSCFG_ETH_MediaInterface)); /* Configure MII_RMII selection bit */ *(__IO uint32_t *) PMC_MII_RMII_SEL_BB = SYSCFG_ETH_MediaInterface; 8025b7c: 4b01 ldr r3, [pc, #4] ; (8025b84 ) 8025b7e: 6018 str r0, [r3, #0] 8025b80: 4770 bx lr 8025b82: bf00 nop 8025b84: 422700dc .word 0x422700dc 08025b88 : { /* Check the parameters */ assert_param(IS_TIM_ALL_PERIPH(TIMx)); /* Clear the IT pending Bit */ TIMx->SR = (uint16_t)~TIM_IT; 8025b88: 43c9 mvns r1, r1 8025b8a: 8201 strh r1, [r0, #16] 8025b8c: 4770 bx lr 8025b8e: 0000 movs r0, r0 08025b90 : * @param USARTx: where x can be 1, 2, 3, 4, 5 or 6 to select the USART or * UART peripheral. * @retval None */ void USART_DeInit(USART_TypeDef* USARTx) { 8025b90: b508 push {r3, lr} /* Check the parameters */ assert_param(IS_USART_ALL_PERIPH(USARTx)); if (USARTx == USART1) 8025b92: 4b23 ldr r3, [pc, #140] ; (8025c20 ) 8025b94: 4298 cmp r0, r3 8025b96: d105 bne.n 8025ba4 { RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART1, ENABLE); 8025b98: 2010 movs r0, #16 8025b9a: 2101 movs r1, #1 8025b9c: f7ff fe1e bl 80257dc RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART1, DISABLE); 8025ba0: 2010 movs r0, #16 8025ba2: e037 b.n 8025c14 } else if (USARTx == USART2) 8025ba4: 4b1f ldr r3, [pc, #124] ; (8025c24 ) 8025ba6: 4298 cmp r0, r3 8025ba8: d107 bne.n 8025bba { RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART2, ENABLE); 8025baa: f44f 3000 mov.w r0, #131072 ; 0x20000 8025bae: 2101 movs r1, #1 8025bb0: f7ff fe08 bl 80257c4 RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART2, DISABLE); 8025bb4: f44f 3000 mov.w r0, #131072 ; 0x20000 8025bb8: e009 b.n 8025bce } else if (USARTx == USART3) 8025bba: 4b1b ldr r3, [pc, #108] ; (8025c28 ) 8025bbc: 4298 cmp r0, r3 8025bbe: d10b bne.n 8025bd8 { RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART3, ENABLE); 8025bc0: f44f 2080 mov.w r0, #262144 ; 0x40000 8025bc4: 2101 movs r1, #1 8025bc6: f7ff fdfd bl 80257c4 RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART3, DISABLE); 8025bca: f44f 2080 mov.w r0, #262144 ; 0x40000 8025bce: 2100 movs r1, #0 { RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, ENABLE); RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, DISABLE); } } } 8025bd0: e8bd 4008 ldmia.w sp!, {r3, lr} RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART2, DISABLE); } else if (USARTx == USART3) { RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART3, ENABLE); RCC_APB1PeriphResetCmd(RCC_APB1Periph_USART3, DISABLE); 8025bd4: f7ff bdf6 b.w 80257c4 } else if (USARTx == UART4) 8025bd8: 4b14 ldr r3, [pc, #80] ; (8025c2c ) 8025bda: 4298 cmp r0, r3 8025bdc: d107 bne.n 8025bee { RCC_APB1PeriphResetCmd(RCC_APB1Periph_UART4, ENABLE); 8025bde: f44f 2000 mov.w r0, #524288 ; 0x80000 8025be2: 2101 movs r1, #1 8025be4: f7ff fdee bl 80257c4 RCC_APB1PeriphResetCmd(RCC_APB1Periph_UART4, DISABLE); 8025be8: f44f 2000 mov.w r0, #524288 ; 0x80000 8025bec: e7ef b.n 8025bce } else if (USARTx == UART5) 8025bee: 4b10 ldr r3, [pc, #64] ; (8025c30 ) 8025bf0: 4298 cmp r0, r3 8025bf2: d107 bne.n 8025c04 { RCC_APB1PeriphResetCmd(RCC_APB1Periph_UART5, ENABLE); 8025bf4: f44f 1080 mov.w r0, #1048576 ; 0x100000 8025bf8: 2101 movs r1, #1 8025bfa: f7ff fde3 bl 80257c4 RCC_APB1PeriphResetCmd(RCC_APB1Periph_UART5, DISABLE); 8025bfe: f44f 1080 mov.w r0, #1048576 ; 0x100000 8025c02: e7e4 b.n 8025bce } else { if (USARTx == USART6) 8025c04: 4b0b ldr r3, [pc, #44] ; (8025c34 ) 8025c06: 4298 cmp r0, r3 8025c08: d109 bne.n 8025c1e { RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, ENABLE); 8025c0a: 2020 movs r0, #32 8025c0c: 2101 movs r1, #1 8025c0e: f7ff fde5 bl 80257dc RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, DISABLE); 8025c12: 2020 movs r0, #32 8025c14: 2100 movs r1, #0 } } } 8025c16: e8bd 4008 ldmia.w sp!, {r3, lr} else { if (USARTx == USART6) { RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, ENABLE); RCC_APB2PeriphResetCmd(RCC_APB2Periph_USART6, DISABLE); 8025c1a: f7ff bddf b.w 80257dc 8025c1e: bd08 pop {r3, pc} 8025c20: 40011000 .word 0x40011000 8025c24: 40004400 .word 0x40004400 8025c28: 40004800 .word 0x40004800 8025c2c: 40004c00 .word 0x40004c00 8025c30: 40005000 .word 0x40005000 8025c34: 40011400 .word 0x40011400 08025c38 : { assert_param(IS_USART_1236_PERIPH(USARTx)); } /*---------------------------- USART CR2 Configuration -----------------------*/ tmpreg = USARTx->CR2; 8025c38: 8a03 ldrh r3, [r0, #16] /* Clear STOP[13:12] bits */ tmpreg &= (uint32_t)~((uint32_t)USART_CR2_STOP); /* Configure the USART Stop Bits, Clock, CPOL, CPHA and LastBit : Set STOP[13:12] bits according to USART_StopBits value */ tmpreg |= (uint32_t)USART_InitStruct->USART_StopBits; 8025c3a: 88ca ldrh r2, [r1, #6] { assert_param(IS_USART_1236_PERIPH(USARTx)); } /*---------------------------- USART CR2 Configuration -----------------------*/ tmpreg = USARTx->CR2; 8025c3c: b29b uxth r3, r3 /* Clear STOP[13:12] bits */ tmpreg &= (uint32_t)~((uint32_t)USART_CR2_STOP); 8025c3e: f423 5340 bic.w r3, r3, #12288 ; 0x3000 * @param USART_InitStruct: pointer to a USART_InitTypeDef structure that contains * the configuration information for the specified USART peripheral. * @retval None */ void USART_Init(USART_TypeDef* USARTx, USART_InitTypeDef* USART_InitStruct) { 8025c42: b530 push {r4, r5, lr} /* Configure the USART Stop Bits, Clock, CPOL, CPHA and LastBit : Set STOP[13:12] bits according to USART_StopBits value */ tmpreg |= (uint32_t)USART_InitStruct->USART_StopBits; /* Write to USART CR2 */ USARTx->CR2 = (uint16_t)tmpreg; 8025c44: 4313 orrs r3, r2 * @param USART_InitStruct: pointer to a USART_InitTypeDef structure that contains * the configuration information for the specified USART peripheral. * @retval None */ void USART_Init(USART_TypeDef* USARTx, USART_InitTypeDef* USART_InitStruct) { 8025c46: 460d mov r5, r1 /* Configure the USART Stop Bits, Clock, CPOL, CPHA and LastBit : Set STOP[13:12] bits according to USART_StopBits value */ tmpreg |= (uint32_t)USART_InitStruct->USART_StopBits; /* Write to USART CR2 */ USARTx->CR2 = (uint16_t)tmpreg; 8025c48: 8203 strh r3, [r0, #16] /*---------------------------- USART CR1 Configuration -----------------------*/ tmpreg = USARTx->CR1; 8025c4a: 8983 ldrh r3, [r0, #12] /* Configure the USART Word Length, Parity and mode: Set the M bits according to USART_WordLength value Set PCE and PS bits according to USART_Parity value Set TE and RE bits according to USART_Mode value */ tmpreg |= (uint32_t)USART_InitStruct->USART_WordLength | USART_InitStruct->USART_Parity | 8025c4c: 8909 ldrh r1, [r1, #8] 8025c4e: 88aa ldrh r2, [r5, #4] /*---------------------------- USART CR1 Configuration -----------------------*/ tmpreg = USARTx->CR1; /* Clear M, PCE, PS, TE and RE bits */ tmpreg &= (uint32_t)~((uint32_t)CR1_CLEAR_MASK); 8025c50: f423 53b0 bic.w r3, r3, #5632 ; 0x1600 /* Configure the USART Word Length, Parity and mode: Set the M bits according to USART_WordLength value Set PCE and PS bits according to USART_Parity value Set TE and RE bits according to USART_Mode value */ tmpreg |= (uint32_t)USART_InitStruct->USART_WordLength | USART_InitStruct->USART_Parity | 8025c54: 430a orrs r2, r1 8025c56: 8969 ldrh r1, [r5, #10] /*---------------------------- USART CR1 Configuration -----------------------*/ tmpreg = USARTx->CR1; /* Clear M, PCE, PS, TE and RE bits */ tmpreg &= (uint32_t)~((uint32_t)CR1_CLEAR_MASK); 8025c58: f023 030c bic.w r3, r3, #12 8025c5c: 041b lsls r3, r3, #16 /* Configure the USART Word Length, Parity and mode: Set the M bits according to USART_WordLength value Set PCE and PS bits according to USART_Parity value Set TE and RE bits according to USART_Mode value */ tmpreg |= (uint32_t)USART_InitStruct->USART_WordLength | USART_InitStruct->USART_Parity | 8025c5e: 430a orrs r2, r1 /*---------------------------- USART CR1 Configuration -----------------------*/ tmpreg = USARTx->CR1; /* Clear M, PCE, PS, TE and RE bits */ tmpreg &= (uint32_t)~((uint32_t)CR1_CLEAR_MASK); 8025c60: 0c1b lsrs r3, r3, #16 /* Configure the USART Word Length, Parity and mode: Set the M bits according to USART_WordLength value Set PCE and PS bits according to USART_Parity value Set TE and RE bits according to USART_Mode value */ tmpreg |= (uint32_t)USART_InitStruct->USART_WordLength | USART_InitStruct->USART_Parity | 8025c62: b292 uxth r2, r2 USART_InitStruct->USART_Mode; /* Write to USART CR1 */ USARTx->CR1 = (uint16_t)tmpreg; 8025c64: 4313 orrs r3, r2 8025c66: 8183 strh r3, [r0, #12] /*---------------------------- USART CR3 Configuration -----------------------*/ tmpreg = USARTx->CR3; 8025c68: 8a83 ldrh r3, [r0, #20] /* Clear CTSE and RTSE bits */ tmpreg &= (uint32_t)~((uint32_t)CR3_CLEAR_MASK); /* Configure the USART HFC : Set CTSE and RTSE bits according to USART_HardwareFlowControl value */ tmpreg |= USART_InitStruct->USART_HardwareFlowControl; 8025c6a: 89aa ldrh r2, [r5, #12] /* Write to USART CR1 */ USARTx->CR1 = (uint16_t)tmpreg; /*---------------------------- USART CR3 Configuration -----------------------*/ tmpreg = USARTx->CR3; 8025c6c: b29b uxth r3, r3 /* Clear CTSE and RTSE bits */ tmpreg &= (uint32_t)~((uint32_t)CR3_CLEAR_MASK); 8025c6e: f423 7340 bic.w r3, r3, #768 ; 0x300 /* Configure the USART HFC : Set CTSE and RTSE bits according to USART_HardwareFlowControl value */ tmpreg |= USART_InitStruct->USART_HardwareFlowControl; /* Write to USART CR3 */ USARTx->CR3 = (uint16_t)tmpreg; 8025c72: 4313 orrs r3, r2 * @param USART_InitStruct: pointer to a USART_InitTypeDef structure that contains * the configuration information for the specified USART peripheral. * @retval None */ void USART_Init(USART_TypeDef* USARTx, USART_InitTypeDef* USART_InitStruct) { 8025c74: b085 sub sp, #20 /* Configure the USART HFC : Set CTSE and RTSE bits according to USART_HardwareFlowControl value */ tmpreg |= USART_InitStruct->USART_HardwareFlowControl; /* Write to USART CR3 */ USARTx->CR3 = (uint16_t)tmpreg; 8025c76: 8283 strh r3, [r0, #20] * @param USART_InitStruct: pointer to a USART_InitTypeDef structure that contains * the configuration information for the specified USART peripheral. * @retval None */ void USART_Init(USART_TypeDef* USARTx, USART_InitTypeDef* USART_InitStruct) { 8025c78: 4604 mov r4, r0 /* Write to USART CR3 */ USARTx->CR3 = (uint16_t)tmpreg; /*---------------------------- USART BRR Configuration -----------------------*/ /* Configure the USART Baud Rate */ RCC_GetClocksFreq(&RCC_ClocksStatus); 8025c7a: 4668 mov r0, sp 8025c7c: f7ff fd02 bl 8025684 if ((USARTx == USART1) || (USARTx == USART6)) 8025c80: 4b19 ldr r3, [pc, #100] ; (8025ce8 ) 8025c82: 429c cmp r4, r3 8025c84: d003 beq.n 8025c8e 8025c86: f503 6380 add.w r3, r3, #1024 ; 0x400 8025c8a: 429c cmp r4, r3 8025c8c: d101 bne.n 8025c92 { apbclock = RCC_ClocksStatus.PCLK2_Frequency; 8025c8e: 9b03 ldr r3, [sp, #12] 8025c90: e000 b.n 8025c94 } else { apbclock = RCC_ClocksStatus.PCLK1_Frequency; 8025c92: 9b02 ldr r3, [sp, #8] } /* Determine the integer part */ if ((USARTx->CR1 & USART_CR1_OVER8) != 0) 8025c94: 89a2 ldrh r2, [r4, #12] 8025c96: b212 sxth r2, r2 8025c98: 2a00 cmp r2, #0 8025c9a: f04f 0119 mov.w r1, #25 8025c9e: 682a ldr r2, [r5, #0] { /* Integer part computing in case Oversampling mode is 8 Samples */ integerdivider = ((25 * apbclock) / (2 * (USART_InitStruct->USART_BaudRate))); 8025ca0: fb01 f103 mul.w r1, r1, r3 { apbclock = RCC_ClocksStatus.PCLK1_Frequency; } /* Determine the integer part */ if ((USARTx->CR1 & USART_CR1_OVER8) != 0) 8025ca4: da01 bge.n 8025caa { /* Integer part computing in case Oversampling mode is 8 Samples */ integerdivider = ((25 * apbclock) / (2 * (USART_InitStruct->USART_BaudRate))); 8025ca6: 0052 lsls r2, r2, #1 8025ca8: e000 b.n 8025cac } else /* if ((USARTx->CR1 & USART_CR1_OVER8) == 0) */ { /* Integer part computing in case Oversampling mode is 16 Samples */ integerdivider = ((25 * apbclock) / (4 * (USART_InitStruct->USART_BaudRate))); 8025caa: 0092 lsls r2, r2, #2 } tmpreg = (integerdivider / 100) << 4; 8025cac: 2364 movs r3, #100 ; 0x64 integerdivider = ((25 * apbclock) / (2 * (USART_InitStruct->USART_BaudRate))); } else /* if ((USARTx->CR1 & USART_CR1_OVER8) == 0) */ { /* Integer part computing in case Oversampling mode is 16 Samples */ integerdivider = ((25 * apbclock) / (4 * (USART_InitStruct->USART_BaudRate))); 8025cae: fbb1 f1f2 udiv r1, r1, r2 } tmpreg = (integerdivider / 100) << 4; 8025cb2: fbb1 f2f3 udiv r2, r1, r3 8025cb6: 0112 lsls r2, r2, #4 /* Determine the fractional part */ fractionaldivider = integerdivider - (100 * (tmpreg >> 4)); 8025cb8: 0910 lsrs r0, r2, #4 8025cba: fb03 1110 mls r1, r3, r0, r1 /* Implement the fractional part in the register */ if ((USARTx->CR1 & USART_CR1_OVER8) != 0) 8025cbe: 89a0 ldrh r0, [r4, #12] 8025cc0: b200 sxth r0, r0 8025cc2: 2800 cmp r0, #0 8025cc4: da06 bge.n 8025cd4 { tmpreg |= ((((fractionaldivider * 8) + 50) / 100)) & ((uint8_t)0x07); 8025cc6: 00c9 lsls r1, r1, #3 8025cc8: 3132 adds r1, #50 ; 0x32 8025cca: fbb1 f3f3 udiv r3, r1, r3 8025cce: f003 0307 and.w r3, r3, #7 8025cd2: e005 b.n 8025ce0 } else /* if ((USARTx->CR1 & USART_CR1_OVER8) == 0) */ { tmpreg |= ((((fractionaldivider * 16) + 50) / 100)) & ((uint8_t)0x0F); 8025cd4: 0109 lsls r1, r1, #4 8025cd6: 3132 adds r1, #50 ; 0x32 8025cd8: fbb1 f3f3 udiv r3, r1, r3 8025cdc: f003 030f and.w r3, r3, #15 8025ce0: 431a orrs r2, r3 } /* Write to USART BRR register */ USARTx->BRR = (uint16_t)tmpreg; 8025ce2: 8122 strh r2, [r4, #8] } 8025ce4: b005 add sp, #20 8025ce6: bd30 pop {r4, r5, pc} 8025ce8: 40011000 .word 0x40011000 08025cec : assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the selected USART by setting the UE bit in the CR1 register */ USARTx->CR1 |= USART_CR1_UE; 8025cec: 8983 ldrh r3, [r0, #12] { /* Check the parameters */ assert_param(IS_USART_ALL_PERIPH(USARTx)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8025cee: b119 cbz r1, 8025cf8 { /* Enable the selected USART by setting the UE bit in the CR1 register */ USARTx->CR1 |= USART_CR1_UE; 8025cf0: b29b uxth r3, r3 8025cf2: f443 5300 orr.w r3, r3, #8192 ; 0x2000 8025cf6: e003 b.n 8025d00 } else { /* Disable the selected USART by clearing the UE bit in the CR1 register */ USARTx->CR1 &= (uint16_t)~((uint16_t)USART_CR1_UE); 8025cf8: f423 5300 bic.w r3, r3, #8192 ; 0x2000 8025cfc: 041b lsls r3, r3, #16 8025cfe: 0c1b lsrs r3, r3, #16 8025d00: 8183 strh r3, [r0, #12] 8025d02: 4770 bx lr 08025d04 : } usartxbase = (uint32_t)USARTx; /* Get the USART register index */ usartreg = (((uint8_t)USART_IT) >> 0x05); 8025d04: f3c1 1342 ubfx r3, r1, #5, #3 * @param NewState: new state of the specified USARTx interrupts. * This parameter can be: ENABLE or DISABLE. * @retval None */ void USART_ITConfig(USART_TypeDef* USARTx, uint16_t USART_IT, FunctionalState NewState) { 8025d08: b510 push {r4, lr} /* Get the USART register index */ usartreg = (((uint8_t)USART_IT) >> 0x05); /* Get the interrupt position */ itpos = USART_IT & IT_MASK; itmask = (((uint32_t)0x01) << itpos); 8025d0a: 2401 movs r4, #1 8025d0c: f001 011f and.w r1, r1, #31 if (usartreg == 0x01) /* The IT is in CR1 register */ 8025d10: 42a3 cmp r3, r4 /* Get the USART register index */ usartreg = (((uint8_t)USART_IT) >> 0x05); /* Get the interrupt position */ itpos = USART_IT & IT_MASK; itmask = (((uint32_t)0x01) << itpos); 8025d12: fa04 f101 lsl.w r1, r4, r1 if (usartreg == 0x01) /* The IT is in CR1 register */ 8025d16: d101 bne.n 8025d1c { usartxbase += 0x0C; 8025d18: 300c adds r0, #12 8025d1a: e004 b.n 8025d26 } else if (usartreg == 0x02) /* The IT is in CR2 register */ 8025d1c: 2b02 cmp r3, #2 8025d1e: d101 bne.n 8025d24 { usartxbase += 0x10; 8025d20: 3010 adds r0, #16 8025d22: e000 b.n 8025d26 } else /* The IT is in CR3 register */ { usartxbase += 0x14; 8025d24: 3014 adds r0, #20 } if (NewState != DISABLE) { *(__IO uint32_t*)usartxbase |= itmask; 8025d26: 6803 ldr r3, [r0, #0] } else /* The IT is in CR3 register */ { usartxbase += 0x14; } if (NewState != DISABLE) 8025d28: b10a cbz r2, 8025d2e { *(__IO uint32_t*)usartxbase |= itmask; 8025d2a: 4319 orrs r1, r3 8025d2c: e001 b.n 8025d32 } else { *(__IO uint32_t*)usartxbase &= ~itmask; 8025d2e: ea23 0101 bic.w r1, r3, r1 8025d32: 6001 str r1, [r0, #0] 8025d34: bd10 pop {r4, pc} 08025d36 : * @arg USART_IT_FE: Framing Error interrupt * @arg USART_IT_PE: Parity Error interrupt * @retval The new state of USART_IT (SET or RESET). */ ITStatus USART_GetITStatus(USART_TypeDef* USARTx, uint16_t USART_IT) { 8025d36: b510 push {r4, lr} { assert_param(IS_USART_1236_PERIPH(USARTx)); } /* Get the USART register index */ usartreg = (((uint8_t)USART_IT) >> 0x05); 8025d38: f3c1 1442 ubfx r4, r1, #5, #3 /* Get the interrupt position */ itmask = USART_IT & IT_MASK; itmask = (uint32_t)0x01 << itmask; 8025d3c: 2201 movs r2, #1 8025d3e: f001 031f and.w r3, r1, #31 if (usartreg == 0x01) /* The IT is in CR1 register */ 8025d42: 2c01 cmp r4, #1 /* Get the USART register index */ usartreg = (((uint8_t)USART_IT) >> 0x05); /* Get the interrupt position */ itmask = USART_IT & IT_MASK; itmask = (uint32_t)0x01 << itmask; 8025d44: fa02 f203 lsl.w r2, r2, r3 if (usartreg == 0x01) /* The IT is in CR1 register */ 8025d48: d101 bne.n 8025d4e { itmask &= USARTx->CR1; 8025d4a: 8983 ldrh r3, [r0, #12] 8025d4c: e003 b.n 8025d56 } else if (usartreg == 0x02) /* The IT is in CR2 register */ 8025d4e: 2c02 cmp r4, #2 { itmask &= USARTx->CR2; 8025d50: bf0c ite eq 8025d52: 8a03 ldrheq r3, [r0, #16] } else /* The IT is in CR3 register */ { itmask &= USARTx->CR3; 8025d54: 8a83 ldrhne r3, [r0, #20] 8025d56: b29b uxth r3, r3 8025d58: 4013 ands r3, r2 } bitpos = USART_IT >> 0x08; bitpos = (uint32_t)0x01 << bitpos; bitpos &= USARTx->SR; 8025d5a: 8802 ldrh r2, [r0, #0] 8025d5c: b292 uxth r2, r2 if ((itmask != (uint16_t)RESET)&&(bitpos != (uint16_t)RESET)) 8025d5e: b143 cbz r3, 8025d72 { itmask &= USARTx->CR3; } bitpos = USART_IT >> 0x08; bitpos = (uint32_t)0x01 << bitpos; 8025d60: 2301 movs r3, #1 8025d62: 0a09 lsrs r1, r1, #8 8025d64: fa03 f101 lsl.w r1, r3, r1 bitpos &= USARTx->SR; if ((itmask != (uint16_t)RESET)&&(bitpos != (uint16_t)RESET)) 8025d68: 4211 tst r1, r2 { bitstatus = SET; 8025d6a: bf0c ite eq 8025d6c: 2000 moveq r0, #0 8025d6e: 2001 movne r0, #1 8025d70: bd10 pop {r4, pc} } else { bitstatus = RESET; 8025d72: 4618 mov r0, r3 } return bitstatus; } 8025d74: bd10 pop {r4, pc} 08025d76 : { assert_param(IS_USART_1236_PERIPH(USARTx)); } bitpos = USART_IT >> 0x08; itmask = ((uint16_t)0x01 << (uint16_t)bitpos); 8025d76: 0a09 lsrs r1, r1, #8 8025d78: 2301 movs r3, #1 8025d7a: fa03 f301 lsl.w r3, r3, r1 USARTx->SR = (uint16_t)~itmask; 8025d7e: 43db mvns r3, r3 8025d80: 8003 strh r3, [r0, #0] 8025d82: 4770 bx lr 08025d84 : SCB->CPACR |= ((3UL << 10*2)|(3UL << 11*2)); /* set CP10 and CP11 Full Access */ #endif /* Reset the RCC clock configuration to the default reset state ------------*/ /* Set HSION bit */ RCC->CR |= (uint32_t)0x00000001; 8025d84: 4b35 ldr r3, [pc, #212] ; (8025e5c ) 8025d86: 681a ldr r2, [r3, #0] 8025d88: f042 0201 orr.w r2, r2, #1 8025d8c: 601a str r2, [r3, #0] /* Reset CFGR register */ RCC->CFGR = 0x00000000; 8025d8e: 2200 movs r2, #0 8025d90: 609a str r2, [r3, #8] /* Reset HSEON, CSSON and PLLON bits */ RCC->CR &= (uint32_t)0xFEF6FFFF; 8025d92: 6819 ldr r1, [r3, #0] 8025d94: f021 7184 bic.w r1, r1, #17301504 ; 0x1080000 8025d98: f421 3180 bic.w r1, r1, #65536 ; 0x10000 8025d9c: 6019 str r1, [r3, #0] /* Reset PLLCFGR register */ RCC->PLLCFGR = 0x24003010; 8025d9e: 4930 ldr r1, [pc, #192] ; (8025e60 ) 8025da0: 6059 str r1, [r3, #4] /* Reset HSEBYP bit */ RCC->CR &= (uint32_t)0xFFFBFFFF; 8025da2: 6819 ldr r1, [r3, #0] * SystemFrequency variable. * @param None * @retval None */ void SystemInit(void) { 8025da4: b082 sub sp, #8 /* Reset PLLCFGR register */ RCC->PLLCFGR = 0x24003010; /* Reset HSEBYP bit */ RCC->CR &= (uint32_t)0xFFFBFFFF; 8025da6: f421 2180 bic.w r1, r1, #262144 ; 0x40000 8025daa: 6019 str r1, [r3, #0] /* Disable all interrupts */ RCC->CIR = 0x00000000; 8025dac: 60da str r2, [r3, #12] static void SetSysClock(void) { /******************************************************************************/ /* PLL (clocked by HSE) used as System clock source */ /******************************************************************************/ __IO uint32_t StartUpCounter = 0, HSEStatus = 0; 8025dae: 9200 str r2, [sp, #0] 8025db0: 9201 str r2, [sp, #4] /* Enable HSE */ RCC->CR |= ((uint32_t)RCC_CR_HSEON); 8025db2: 681a ldr r2, [r3, #0] 8025db4: f442 3280 orr.w r2, r2, #65536 ; 0x10000 8025db8: 601a str r2, [r3, #0] /* Wait till HSE is ready and if Time out is reached exit */ do { HSEStatus = RCC->CR & RCC_CR_HSERDY; 8025dba: 681a ldr r2, [r3, #0] 8025dbc: f402 3200 and.w r2, r2, #131072 ; 0x20000 8025dc0: 9201 str r2, [sp, #4] StartUpCounter++; 8025dc2: 9a00 ldr r2, [sp, #0] 8025dc4: 3201 adds r2, #1 8025dc6: 9200 str r2, [sp, #0] } while((HSEStatus == 0) && (StartUpCounter != HSE_STARTUP_TIMEOUT)); 8025dc8: 9a01 ldr r2, [sp, #4] 8025dca: b91a cbnz r2, 8025dd4 8025dcc: 9a00 ldr r2, [sp, #0] 8025dce: f5b2 6fa0 cmp.w r2, #1280 ; 0x500 8025dd2: d1f2 bne.n 8025dba if ((RCC->CR & RCC_CR_HSERDY) != RESET) 8025dd4: 4b21 ldr r3, [pc, #132] ; (8025e5c ) 8025dd6: 681b ldr r3, [r3, #0] 8025dd8: f413 3300 ands.w r3, r3, #131072 ; 0x20000 { HSEStatus = (uint32_t)0x01; 8025ddc: bf18 it ne 8025dde: 2301 movne r3, #1 } else { HSEStatus = (uint32_t)0x00; 8025de0: 9301 str r3, [sp, #4] } if (HSEStatus == (uint32_t)0x01) 8025de2: 9b01 ldr r3, [sp, #4] 8025de4: 2b01 cmp r3, #1 8025de6: d133 bne.n 8025e50 { /* Select regulator voltage output Scale 1 mode, System frequency up to 168 MHz */ RCC->APB1ENR |= RCC_APB1ENR_PWREN; 8025de8: 4b1c ldr r3, [pc, #112] ; (8025e5c ) 8025dea: 6c1a ldr r2, [r3, #64] ; 0x40 8025dec: f042 5280 orr.w r2, r2, #268435456 ; 0x10000000 8025df0: 641a str r2, [r3, #64] ; 0x40 PWR->CR |= PWR_CR_VOS; 8025df2: 4a1c ldr r2, [pc, #112] ; (8025e64 ) 8025df4: 6811 ldr r1, [r2, #0] 8025df6: f441 4180 orr.w r1, r1, #16384 ; 0x4000 8025dfa: 6011 str r1, [r2, #0] /* HCLK = SYSCLK / 1*/ RCC->CFGR |= RCC_CFGR_HPRE_DIV1; 8025dfc: 689a ldr r2, [r3, #8] 8025dfe: 609a str r2, [r3, #8] /* PCLK2 = HCLK / 2*/ RCC->CFGR |= RCC_CFGR_PPRE2_DIV2; 8025e00: 689a ldr r2, [r3, #8] 8025e02: f442 4200 orr.w r2, r2, #32768 ; 0x8000 8025e06: 609a str r2, [r3, #8] /* PCLK1 = HCLK / 4*/ RCC->CFGR |= RCC_CFGR_PPRE1_DIV4; 8025e08: 689a ldr r2, [r3, #8] 8025e0a: f442 52a0 orr.w r2, r2, #5120 ; 0x1400 8025e0e: 609a str r2, [r3, #8] /* Configure the main PLL */ RCC->PLLCFGR = PLL_M | (PLL_N << 6) | (((PLL_P >> 1) -1) << 16) | 8025e10: 4a15 ldr r2, [pc, #84] ; (8025e68 ) 8025e12: 605a str r2, [r3, #4] (RCC_PLLCFGR_PLLSRC_HSE) | (PLL_Q << 24); /* Enable the main PLL */ RCC->CR |= RCC_CR_PLLON; 8025e14: 681a ldr r2, [r3, #0] 8025e16: f042 7280 orr.w r2, r2, #16777216 ; 0x1000000 8025e1a: 601a str r2, [r3, #0] /* Wait till the main PLL is ready */ while((RCC->CR & RCC_CR_PLLRDY) == 0) 8025e1c: 6819 ldr r1, [r3, #0] 8025e1e: 4a0f ldr r2, [pc, #60] ; (8025e5c ) 8025e20: 0189 lsls r1, r1, #6 8025e22: d5fb bpl.n 8025e1c { } /* Configure Flash prefetch, Instruction cache, Data cache and wait state */ FLASH->ACR = FLASH_ACR_ICEN |FLASH_ACR_DCEN |FLASH_ACR_LATENCY_5WS; 8025e24: 4b11 ldr r3, [pc, #68] ; (8025e6c ) 8025e26: f240 6105 movw r1, #1541 ; 0x605 8025e2a: 6019 str r1, [r3, #0] /* Select the main PLL as system clock source */ RCC->CFGR &= (uint32_t)((uint32_t)~(RCC_CFGR_SW)); 8025e2c: 6893 ldr r3, [r2, #8] 8025e2e: f023 0303 bic.w r3, r3, #3 8025e32: 6093 str r3, [r2, #8] RCC->CFGR |= RCC_CFGR_SW_PLL; 8025e34: 6893 ldr r3, [r2, #8] 8025e36: f043 0302 orr.w r3, r3, #2 8025e3a: 6093 str r3, [r2, #8] /* Wait till the main PLL is used as system clock source */ while ((RCC->CFGR & (uint32_t)RCC_CFGR_SWS ) != RCC_CFGR_SWS_PLL); 8025e3c: 6891 ldr r1, [r2, #8] 8025e3e: 4b07 ldr r3, [pc, #28] ; (8025e5c ) 8025e40: f001 010c and.w r1, r1, #12 8025e44: 2908 cmp r1, #8 8025e46: d1f9 bne.n 8025e3c { } /* Добавил переход на внутренний генератор в случае отказа HSE */ RCC->CR|=RCC_CR_CSSON; 8025e48: 681a ldr r2, [r3, #0] 8025e4a: f442 2200 orr.w r2, r2, #524288 ; 0x80000 8025e4e: 601a str r2, [r3, #0] /* Configure the Vector Table location add offset address ------------------*/ #ifdef VECT_TAB_SRAM SCB->VTOR = SRAM_BASE | VECT_TAB_OFFSET; /* Vector Table Relocation in Internal SRAM */ #else SCB->VTOR = FLASH_BASE | VECT_TAB_OFFSET; /* Vector Table Relocation in Internal FLASH */ 8025e50: 4b07 ldr r3, [pc, #28] ; (8025e70 ) 8025e52: f04f 6200 mov.w r2, #134217728 ; 0x8000000 8025e56: 609a str r2, [r3, #8] #endif } 8025e58: b002 add sp, #8 8025e5a: 4770 bx lr 8025e5c: 40023800 .word 0x40023800 8025e60: 24003010 .word 0x24003010 8025e64: 40007000 .word 0x40007000 8025e68: 07405419 .word 0x07405419 8025e6c: 40023c00 .word 0x40023c00 8025e70: e000ed00 .word 0xe000ed00 08025e74 : GPIO_TABLE(EXPAND_AS_DEFS) }; void gpio_hw_config_pin(GPIO_TypeDef *port, uint8_t pin, uint16_t conf) { uint8_t shift; shift = pin * 2; 8025e74: 004b lsls r3, r1, #1 port->MODER &= ~(GPIO_MODER_MASK << shift); 8025e76: b2db uxtb r3, r3 gpio_pindef_t gpio_pins[] = { GPIO_TABLE(EXPAND_AS_DEFS) }; void gpio_hw_config_pin(GPIO_TypeDef *port, uint8_t pin, uint16_t conf) { 8025e78: b570 push {r4, r5, r6, lr} uint8_t shift; shift = pin * 2; port->MODER &= ~(GPIO_MODER_MASK << shift); 8025e7a: 2403 movs r4, #3 8025e7c: 6805 ldr r5, [r0, #0] 8025e7e: fa04 f403 lsl.w r4, r4, r3 8025e82: 43e4 mvns r4, r4 8025e84: 4025 ands r5, r4 8025e86: 6005 str r5, [r0, #0] port->MODER |= (uint32_t)((conf >> GPIO_MODE_CFG_SHIFT) & GPIO_MODER_MASK) << shift; 8025e88: 6806 ldr r6, [r0, #0] 8025e8a: f002 0503 and.w r5, r2, #3 8025e8e: fa05 f503 lsl.w r5, r5, r3 8025e92: 4335 orrs r5, r6 8025e94: 6005 str r5, [r0, #0] port->OTYPER &= ~(GPIO_TYPER_MASK << pin); 8025e96: 6846 ldr r6, [r0, #4] 8025e98: 2501 movs r5, #1 8025e9a: fa05 f501 lsl.w r5, r5, r1 8025e9e: ea26 0505 bic.w r5, r6, r5 8025ea2: 6045 str r5, [r0, #4] port->OTYPER |= (uint32_t)((conf >> GPIO_TYPE_CFG_SHIFT) & GPIO_TYPER_MASK) << pin; 8025ea4: 6845 ldr r5, [r0, #4] 8025ea6: f3c2 0680 ubfx r6, r2, #2, #1 8025eaa: fa06 f101 lsl.w r1, r6, r1 8025eae: 4329 orrs r1, r5 8025eb0: 6041 str r1, [r0, #4] port->OSPEEDR &= ~(GPIO_SPEEDR_MASK << shift); 8025eb2: 6881 ldr r1, [r0, #8] 8025eb4: 4021 ands r1, r4 8025eb6: 6081 str r1, [r0, #8] port->OSPEEDR |= (uint32_t)((conf >> GPIO_SPEED_CFG_SHIFT) & GPIO_SPEEDR_MASK) << shift; 8025eb8: 6885 ldr r5, [r0, #8] 8025eba: f3c2 1101 ubfx r1, r2, #4, #2 8025ebe: fa01 f103 lsl.w r1, r1, r3 8025ec2: 4329 orrs r1, r5 8025ec4: 6081 str r1, [r0, #8] port->PUPDR &= ~(GPIO_PUPDR_MASK << shift); 8025ec6: 68c1 ldr r1, [r0, #12] 8025ec8: 400c ands r4, r1 8025eca: 60c4 str r4, [r0, #12] port->PUPDR |= (uint32_t)((conf >> GPIO_PUPD_CFG_SHIFT) & GPIO_PUPDR_MASK) << shift; 8025ecc: 68c1 ldr r1, [r0, #12] 8025ece: f3c2 1281 ubfx r2, r2, #6, #2 8025ed2: fa02 f303 lsl.w r3, r2, r3 8025ed6: 430b orrs r3, r1 8025ed8: 60c3 str r3, [r0, #12] 8025eda: bd70 pop {r4, r5, r6, pc} 08025edc : } void gpio_connect_af(gpio_t id, uint8_t af_n) { 8025edc: b510 push {r4, lr} gpio_pindef_t *pin = &gpio_pins[id]; 8025ede: 4b13 ldr r3, [pc, #76] ; (8025f2c ) 8025ee0: eb03 02c0 add.w r2, r3, r0, lsl #3 uint8_t shift; if (pin->pin < 8) { shift = pin->pin * 4; pin->port->AFR[0] &= ~((uint32_t)GPIO_AFR_MASK << shift); 8025ee4: f853 3030 ldr.w r3, [r3, r0, lsl #3] } void gpio_connect_af(gpio_t id, uint8_t af_n) { gpio_pindef_t *pin = &gpio_pins[id]; uint8_t shift; if (pin->pin < 8) { 8025ee8: 7912 ldrb r2, [r2, #4] 8025eea: 2a07 cmp r2, #7 8025eec: d80e bhi.n 8025f0c shift = pin->pin * 4; 8025eee: 0092 lsls r2, r2, #2 pin->port->AFR[0] &= ~((uint32_t)GPIO_AFR_MASK << shift); 8025ef0: 6a1c ldr r4, [r3, #32] 8025ef2: b2d2 uxtb r2, r2 8025ef4: 200f movs r0, #15 8025ef6: fa00 f002 lsl.w r0, r0, r2 8025efa: ea24 0000 bic.w r0, r4, r0 8025efe: 6218 str r0, [r3, #32] pin->port->AFR[0] |= af_n << shift; 8025f00: 6a18 ldr r0, [r3, #32] 8025f02: fa01 f202 lsl.w r2, r1, r2 8025f06: 4302 orrs r2, r0 8025f08: 621a str r2, [r3, #32] 8025f0a: bd10 pop {r4, pc} } else { shift = (pin->pin - 8) * 4; 8025f0c: 3a08 subs r2, #8 8025f0e: 0092 lsls r2, r2, #2 pin->port->AFR[1] &= ~((uint32_t)GPIO_AFR_MASK << shift); 8025f10: 6a5c ldr r4, [r3, #36] ; 0x24 8025f12: b2d2 uxtb r2, r2 8025f14: 200f movs r0, #15 8025f16: fa00 f002 lsl.w r0, r0, r2 8025f1a: ea24 0000 bic.w r0, r4, r0 8025f1e: 6258 str r0, [r3, #36] ; 0x24 pin->port->AFR[1] |= af_n << shift; 8025f20: 6a58 ldr r0, [r3, #36] ; 0x24 8025f22: fa01 f202 lsl.w r2, r1, r2 8025f26: 4302 orrs r2, r0 8025f28: 625a str r2, [r3, #36] ; 0x24 8025f2a: bd10 pop {r4, pc} 8025f2c: 200005c0 .word 0x200005c0 08025f30 : } } } void gpio_set(gpio_t pin, bool value) { if (gpio_pins[pin].flags & GPIO_INV) 8025f30: 4b0e ldr r3, [pc, #56] ; (8025f6c ) 8025f32: eb03 02c0 add.w r2, r3, r0, lsl #3 8025f36: 88d2 ldrh r2, [r2, #6] 8025f38: f002 0210 and.w r2, r2, #16 8025f3c: b292 uxth r2, r2 8025f3e: b10a cbz r2, 8025f44 value = !value; 8025f40: f081 0101 eor.w r1, r1, #1 8025f44: 00c2 lsls r2, r0, #3 if (value) 8025f46: b141 cbz r1, 8025f5a gpio_pins[pin].port->BSRRL = 1 << gpio_pins[pin].pin; 8025f48: f853 1030 ldr.w r1, [r3, r0, lsl #3] 8025f4c: 189b adds r3, r3, r2 8025f4e: 2201 movs r2, #1 8025f50: 791b ldrb r3, [r3, #4] 8025f52: fa02 f303 lsl.w r3, r2, r3 8025f56: 830b strh r3, [r1, #24] 8025f58: 4770 bx lr else gpio_pins[pin].port->BSRRH = 1 << gpio_pins[pin].pin; 8025f5a: f853 1030 ldr.w r1, [r3, r0, lsl #3] 8025f5e: 189b adds r3, r3, r2 8025f60: 2201 movs r2, #1 8025f62: 791b ldrb r3, [r3, #4] 8025f64: fa02 f303 lsl.w r3, r2, r3 8025f68: 834b strh r3, [r1, #26] 8025f6a: 4770 bx lr 8025f6c: 200005c0 .word 0x200005c0 08025f70 : } /* * TODO add analog flag and setup ADC pins in a proper way */ static void gpio_set_config(gpio_t id) { 8025f70: b570 push {r4, r5, r6, lr} gpio_pindef_t *pin = &gpio_pins[id]; 8025f72: 4e1e ldr r6, [pc, #120] ; (8025fec ) 8025f74: eb06 05c0 add.w r5, r6, r0, lsl #3 } /* * TODO add analog flag and setup ADC pins in a proper way */ static void gpio_set_config(gpio_t id) { 8025f78: 4604 mov r4, r0 gpio_pindef_t *pin = &gpio_pins[id]; if (pin->flags & GPIO_AF) { 8025f7a: 88e9 ldrh r1, [r5, #6] 8025f7c: f401 7300 and.w r3, r1, #512 ; 0x200 8025f80: b29b uxth r3, r3 8025f82: b13b cbz r3, 8025f94 uint8_t af_n = (uint8_t)(pin->flags >> _GPIO_AF_SHIFT); gpio_connect_af(id, af_n); 8025f84: 0a89 lsrs r1, r1, #10 8025f86: f7ff ffa9 bl 8025edc gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_AF_CFG | 8025f8a: f856 0034 ldr.w r0, [r6, r4, lsl #3] 8025f8e: 7929 ldrb r1, [r5, #4] 8025f90: 2232 movs r2, #50 ; 0x32 8025f92: e005 b.n 8025fa0 GPIO_SPEED_HIGH_CFG); } else if (pin->flags & GPIO_IN) 8025f94: 07cb lsls r3, r1, #31 8025f96: d507 bpl.n 8025fa8 gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_IN_CFG | 8025f98: f856 0030 ldr.w r0, [r6, r0, lsl #3] 8025f9c: 7929 ldrb r1, [r5, #4] 8025f9e: 2230 movs r2, #48 ; 0x30 ((pin->flags & GPIO_OD) ? GPIO_TYPE_OD_CFG : GPIO_TYPE_PP_CFG) | GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); } } 8025fa0: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} gpio_connect_af(id, af_n); gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_AF_CFG | GPIO_SPEED_HIGH_CFG); } else if (pin->flags & GPIO_IN) gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_IN_CFG | 8025fa4: f7ff bf66 b.w 8025e74 GPIO_SPEED_HIGH_CFG); else if (pin->flags & GPIO_IN_PU) { 8025fa8: f001 0302 and.w r3, r1, #2 8025fac: b29b uxth r3, r3 8025fae: b123 cbz r3, 8025fba gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_IN_CFG | GPIO_PU_CFG | 8025fb0: f856 0030 ldr.w r0, [r6, r0, lsl #3] 8025fb4: 7929 ldrb r1, [r5, #4] 8025fb6: 2270 movs r2, #112 ; 0x70 8025fb8: e00d b.n 8025fd6 GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); } else if (pin->flags & GPIO_OUT) { 8025fba: f001 0304 and.w r3, r1, #4 8025fbe: b29b uxth r3, r3 8025fc0: b19b cbz r3, 8025fea gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_OUT_CFG | 8025fc2: f001 0120 and.w r1, r1, #32 8025fc6: b28a uxth r2, r1 8025fc8: f856 0030 ldr.w r0, [r6, r0, lsl #3] 8025fcc: 7929 ldrb r1, [r5, #4] 8025fce: 2a00 cmp r2, #0 8025fd0: bf0c ite eq 8025fd2: 2231 moveq r2, #49 ; 0x31 8025fd4: 2235 movne r2, #53 ; 0x35 8025fd6: f7ff ff4d bl 8025e74 ((pin->flags & GPIO_OD) ? GPIO_TYPE_OD_CFG : GPIO_TYPE_PP_CFG) | GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); 8025fda: 88e9 ldrh r1, [r5, #6] 8025fdc: 4620 mov r0, r4 8025fde: f3c1 01c0 ubfx r1, r1, #3, #1 } } 8025fe2: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} else if (pin->flags & GPIO_OUT) { gpio_hw_config_pin(pin->port, pin->pin, GPIO_MODE_OUT_CFG | ((pin->flags & GPIO_OD) ? GPIO_TYPE_OD_CFG : GPIO_TYPE_PP_CFG) | GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); 8025fe6: f7ff bfa3 b.w 8025f30 8025fea: bd70 pop {r4, r5, r6, pc} 8025fec: 200005c0 .word 0x200005c0 08025ff0 : } } void gpio_init(void) { 8025ff0: b538 push {r3, r4, r5, lr} uint32_t i; GPIO_DeInit(GPIOA); 8025ff2: 4812 ldr r0, [pc, #72] ; (802603c ) GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); } } void gpio_init(void) { 8025ff4: 4d12 ldr r5, [pc, #72] ; (8026040 ) uint32_t i; GPIO_DeInit(GPIOA); 8025ff6: f7ff fa5d bl 80254b4 GPIO_DeInit(GPIOB); 8025ffa: 4812 ldr r0, [pc, #72] ; (8026044 ) 8025ffc: f7ff fa5a bl 80254b4 GPIO_DeInit(GPIOC); 8026000: 4811 ldr r0, [pc, #68] ; (8026048 ) 8026002: f7ff fa57 bl 80254b4 GPIO_DeInit(GPIOD); 8026006: 4811 ldr r0, [pc, #68] ; (802604c ) 8026008: f7ff fa54 bl 80254b4 GPIO_DeInit(GPIOE); 802600c: 4810 ldr r0, [pc, #64] ; (8026050 ) 802600e: f7ff fa51 bl 80254b4 // configure clocks RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN | RCC_AHB1ENR_GPIOBEN | 8026012: 4b10 ldr r3, [pc, #64] ; (8026054 ) 8026014: 6b1a ldr r2, [r3, #48] ; 0x30 8026016: f042 021f orr.w r2, r2, #31 802601a: 631a str r2, [r3, #48] ; 0x30 RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIODEN | RCC_AHB1ENR_GPIOEEN; // configure gpios for (i = 0; i < GPIO_TOTAL_COUNT; i++) { 802601c: 2400 movs r4, #0 GPIO_SPEED_HIGH_CFG); gpio_set(id, pin->flags & GPIO_SET); } } void gpio_init(void) { 802601e: eb05 03c4 add.w r3, r5, r4, lsl #3 RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIODEN | RCC_AHB1ENR_GPIOEEN; // configure gpios for (i = 0; i < GPIO_TOTAL_COUNT; i++) { if (gpio_pins[i].flags & GPIO_NOINIT) 8026022: 88db ldrh r3, [r3, #6] 8026024: f003 0380 and.w r3, r3, #128 ; 0x80 8026028: b29b uxth r3, r3 802602a: b913 cbnz r3, 8026032 continue; else { gpio_set_config(i); 802602c: b2e0 uxtb r0, r4 802602e: f7ff ff9f bl 8025f70 RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN | RCC_AHB1ENR_GPIOBEN | RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIODEN | RCC_AHB1ENR_GPIOEEN; // configure gpios for (i = 0; i < GPIO_TOTAL_COUNT; i++) { 8026032: 3401 adds r4, #1 8026034: 2c11 cmp r4, #17 8026036: d1f2 bne.n 802601e continue; else { gpio_set_config(i); } } } 8026038: bd38 pop {r3, r4, r5, pc} 802603a: bf00 nop 802603c: 40020000 .word 0x40020000 8026040: 200005c0 .word 0x200005c0 8026044: 40020400 .word 0x40020400 8026048: 40020800 .word 0x40020800 802604c: 40020c00 .word 0x40020c00 8026050: 40021000 .word 0x40021000 8026054: 40023800 .word 0x40023800 08026058 : gpio_pins[pin].port->BSRRH = 1 << gpio_pins[pin].pin; } void gpio_invert_output(gpio_t pin) { gpio_pins[pin].port->ODR ^= 1 << gpio_pins[pin].pin; 8026058: 4a06 ldr r2, [pc, #24] ; (8026074 ) 802605a: f852 3030 ldr.w r3, [r2, r0, lsl #3] 802605e: eb02 02c0 add.w r2, r2, r0, lsl #3 8026062: 6959 ldr r1, [r3, #20] 8026064: 7912 ldrb r2, [r2, #4] 8026066: 2001 movs r0, #1 8026068: fa00 f202 lsl.w r2, r0, r2 802606c: 404a eors r2, r1 802606e: 615a str r2, [r3, #20] 8026070: 4770 bx lr 8026072: bf00 nop 8026074: 200005c0 .word 0x200005c0 08026078 : } bool gpio_get(gpio_t pin) { bool value; if (gpio_pins[pin].flags & GPIO_NOINIT) { 8026078: 490e ldr r1, [pc, #56] ; (80260b4 ) 802607a: eb01 02c0 add.w r2, r1, r0, lsl #3 void gpio_invert_output(gpio_t pin) { gpio_pins[pin].port->ODR ^= 1 << gpio_pins[pin].pin; } bool gpio_get(gpio_t pin) { 802607e: b510 push {r4, lr} bool value; if (gpio_pins[pin].flags & GPIO_NOINIT) { 8026080: 88d3 ldrh r3, [r2, #6] 8026082: f003 0480 and.w r4, r3, #128 ; 0x80 8026086: b2a4 uxth r4, r4 8026088: b994 cbnz r4, 80260b0 return false; } else { value = (gpio_pins[pin].port->IDR & (1 << gpio_pins[pin].pin)) >> gpio_pins[pin].pin; 802608a: f851 1030 ldr.w r1, [r1, r0, lsl #3] 802608e: 7912 ldrb r2, [r2, #4] 8026090: 6908 ldr r0, [r1, #16] 8026092: 2101 movs r1, #1 8026094: fa01 f102 lsl.w r1, r1, r2 8026098: 4001 ands r1, r0 return (gpio_pins[pin].flags & GPIO_INV) ? !value : value; 802609a: f003 0310 and.w r3, r3, #16 bool value; if (gpio_pins[pin].flags & GPIO_NOINIT) { return false; } else { value = (gpio_pins[pin].port->IDR & (1 << gpio_pins[pin].pin)) >> gpio_pins[pin].pin; 802609e: 40d1 lsrs r1, r2 return (gpio_pins[pin].flags & GPIO_INV) ? !value : value; 80260a0: b29b uxth r3, r3 bool value; if (gpio_pins[pin].flags & GPIO_NOINIT) { return false; } else { value = (gpio_pins[pin].port->IDR & (1 << gpio_pins[pin].pin)) >> gpio_pins[pin].pin; 80260a2: bf0c ite eq 80260a4: 2000 moveq r0, #0 80260a6: 2001 movne r0, #1 return (gpio_pins[pin].flags & GPIO_INV) ? !value : value; 80260a8: b11b cbz r3, 80260b2 80260aa: f080 0001 eor.w r0, r0, #1 80260ae: bd10 pop {r4, pc} } bool gpio_get(gpio_t pin) { bool value; if (gpio_pins[pin].flags & GPIO_NOINIT) { return false; 80260b0: 2000 movs r0, #0 } else { value = (gpio_pins[pin].port->IDR & (1 << gpio_pins[pin].pin)) >> gpio_pins[pin].pin; return (gpio_pins[pin].flags & GPIO_INV) ? !value : value; } } 80260b2: bd10 pop {r4, pc} 80260b4: 200005c0 .word 0x200005c0 080260b8 : #include "rng.h" #include "stm32f4xx.h" void RNG_Init(void) { 80260b8: b508 push {r3, lr} RCC_AHB2PeriphClockCmd(RCC_AHB2Periph_RNG,ENABLE); 80260ba: 2040 movs r0, #64 ; 0x40 80260bc: 2101 movs r1, #1 80260be: f7ff fb51 bl 8025764 RNG_Cmd(ENABLE); 80260c2: 2001 movs r0, #1 } 80260c4: e8bd 4008 ldmia.w sp!, {r3, lr} void RNG_Init(void) { RCC_AHB2PeriphClockCmd(RCC_AHB2Periph_RNG,ENABLE); RNG_Cmd(ENABLE); 80260c8: f7ff bba8 b.w 802581c 080260cc : } uint32_t GetRandomNumber(void) { return RNG_GetRandomNumber();; 80260cc: f7ff bbb2 b.w 8025834 080260d0 : /* Устанавливаем новое время */ TM_RTC_GetDateTimeFromUnix(&newData, unixTime); TM_RTC_SetDateTime(&newData, TM_RTC_Format_BIN); } TM_RTC_Result_t TM_RTC_SetDateTime(TM_RTC_t* data, TM_RTC_Format_t format) { 80260d0: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} TM_RTC_t tmp; /* Check date and time validation */ if (format == TM_RTC_Format_BCD) { 80260d4: 2901 cmp r1, #1 /* Устанавливаем новое время */ TM_RTC_GetDateTimeFromUnix(&newData, unixTime); TM_RTC_SetDateTime(&newData, TM_RTC_Format_BIN); } TM_RTC_Result_t TM_RTC_SetDateTime(TM_RTC_t* data, TM_RTC_Format_t format) { 80260d6: 4603 mov r3, r0 80260d8: 460e mov r6, r1 80260da: 79c0 ldrb r0, [r0, #7] TM_RTC_t tmp; /* Check date and time validation */ if (format == TM_RTC_Format_BCD) { 80260dc: d137 bne.n 802614e tmp.date = TM_RTC_BCD2BIN(data->date); tmp.month = TM_RTC_BCD2BIN(data->month); 80260de: 7a1c ldrb r4, [r3, #8] tmp.year = TM_RTC_BCD2BIN(data->year); 80260e0: 7a5d ldrb r5, [r3, #9] tmp.hours = TM_RTC_BCD2BIN(data->hours); tmp.minutes = TM_RTC_BCD2BIN(data->minutes); tmp.seconds = TM_RTC_BCD2BIN(data->seconds); 80260e2: f893 8000 ldrb.w r8, [r3] TM_RTC_Result_t TM_RTC_SetDateTime(TM_RTC_t* data, TM_RTC_Format_t format) { TM_RTC_t tmp; /* Check date and time validation */ if (format == TM_RTC_Format_BCD) { tmp.date = TM_RTC_BCD2BIN(data->date); 80260e6: 220a movs r2, #10 80260e8: 0901 lsrs r1, r0, #4 80260ea: f000 000f and.w r0, r0, #15 80260ee: fb02 0001 mla r0, r2, r1, r0 tmp.month = TM_RTC_BCD2BIN(data->month); 80260f2: 0921 lsrs r1, r4, #4 80260f4: f004 040f and.w r4, r4, #15 80260f8: fb02 4101 mla r1, r2, r1, r4 tmp.year = TM_RTC_BCD2BIN(data->year); 80260fc: 092c lsrs r4, r5, #4 80260fe: f005 050f and.w r5, r5, #15 8026102: fb02 5404 mla r4, r2, r4, r5 tmp.hours = TM_RTC_BCD2BIN(data->hours); 8026106: 795d ldrb r5, [r3, #5] 8026108: ea4f 1c15 mov.w ip, r5, lsr #4 802610c: f005 050f and.w r5, r5, #15 8026110: fb02 5c0c mla ip, r2, ip, r5 tmp.minutes = TM_RTC_BCD2BIN(data->minutes); 8026114: 791d ldrb r5, [r3, #4] 8026116: 092f lsrs r7, r5, #4 8026118: f005 050f and.w r5, r5, #15 802611c: fb02 5707 mla r7, r2, r7, r5 tmp.seconds = TM_RTC_BCD2BIN(data->seconds); 8026120: ea4f 1518 mov.w r5, r8, lsr #4 8026124: f008 080f and.w r8, r8, #15 8026128: fb02 8505 mla r5, r2, r5, r8 tmp.day = TM_RTC_BCD2BIN(data->day); 802612c: f893 8006 ldrb.w r8, [r3, #6] 8026130: ea4f 1918 mov.w r9, r8, lsr #4 8026134: f008 080f and.w r8, r8, #15 8026138: fb02 8209 mla r2, r2, r9, r8 TM_RTC_Result_t TM_RTC_SetDateTime(TM_RTC_t* data, TM_RTC_Format_t format) { TM_RTC_t tmp; /* Check date and time validation */ if (format == TM_RTC_Format_BCD) { tmp.date = TM_RTC_BCD2BIN(data->date); 802613c: b2c0 uxtb r0, r0 tmp.month = TM_RTC_BCD2BIN(data->month); 802613e: b2c9 uxtb r1, r1 tmp.year = TM_RTC_BCD2BIN(data->year); 8026140: b2e4 uxtb r4, r4 tmp.hours = TM_RTC_BCD2BIN(data->hours); 8026142: fa5f fc8c uxtb.w ip, ip tmp.minutes = TM_RTC_BCD2BIN(data->minutes); 8026146: b2ff uxtb r7, r7 tmp.seconds = TM_RTC_BCD2BIN(data->seconds); 8026148: b2ed uxtb r5, r5 tmp.day = TM_RTC_BCD2BIN(data->day); 802614a: b2d2 uxtb r2, r2 802614c: e006 b.n 802615c } else { tmp.date = data->date; tmp.month = data->month; 802614e: 7a19 ldrb r1, [r3, #8] tmp.year = data->year; 8026150: 7a5c ldrb r4, [r3, #9] tmp.hours = data->hours; 8026152: f893 c005 ldrb.w ip, [r3, #5] tmp.minutes = data->minutes; 8026156: 791f ldrb r7, [r3, #4] tmp.seconds = data->seconds; 8026158: 781d ldrb r5, [r3, #0] tmp.day = data->day; 802615a: 799a ldrb r2, [r3, #6] } /* Check year and month */ if ( 802615c: 2c63 cmp r4, #99 ; 0x63 802615e: d86c bhi.n 802623a tmp.year > 99 || 8026160: 2900 cmp r1, #0 8026162: d06a beq.n 802623a tmp.month == 0 || 8026164: 290c cmp r1, #12 8026166: d868 bhi.n 802623a tmp.month > 12 || 8026168: 2800 cmp r0, #0 802616a: d066 beq.n 802623a tmp.date == 0 || tmp.date > TM_RTC_Months[TM_RTC_LEAP_YEAR(2000 + tmp.year) ? 1 : 0][tmp.month - 1] || 802616c: f014 0f03 tst.w r4, #3 8026170: d10a bne.n 8026188 8026172: f504 69fa add.w r9, r4, #2000 ; 0x7d0 8026176: f04f 0864 mov.w r8, #100 ; 0x64 802617a: fb99 faf8 sdiv sl, r9, r8 802617e: fb08 981a mls r8, r8, sl, r9 8026182: f1b8 0f00 cmp.w r8, #0 8026186: d10c bne.n 80261a2 8026188: f504 64fa add.w r4, r4, #2000 ; 0x7d0 802618c: f44f 78c8 mov.w r8, #400 ; 0x190 8026190: fb94 f9f8 sdiv r9, r4, r8 8026194: fb08 4419 mls r4, r8, r9, r4 8026198: f1d4 0401 rsbs r4, r4, #1 802619c: bf38 it cc 802619e: 2400 movcc r4, #0 80261a0: e000 b.n 80261a4 80261a2: 2401 movs r4, #1 80261a4: f8df 80a8 ldr.w r8, [pc, #168] ; 8026250 80261a8: f04f 090c mov.w r9, #12 80261ac: fb09 8404 mla r4, r9, r4, r8 80261b0: 1861 adds r1, r4, r1 /* Check year and month */ if ( tmp.year > 99 || tmp.month == 0 || tmp.month > 12 || tmp.date == 0 || 80261b2: f811 1c01 ldrb.w r1, [r1, #-1] 80261b6: 4281 cmp r1, r0 80261b8: d33f bcc.n 802623a tmp.date > TM_RTC_Months[TM_RTC_LEAP_YEAR(2000 + tmp.year) ? 1 : 0][tmp.month - 1] || 80261ba: f1bc 0f17 cmp.w ip, #23 80261be: d83c bhi.n 802623a tmp.hours > 23 || 80261c0: 2f3b cmp r7, #59 ; 0x3b 80261c2: d83a bhi.n 802623a tmp.minutes > 59 || 80261c4: 2d3b cmp r5, #59 ; 0x3b 80261c6: d838 bhi.n 802623a tmp.seconds > 59 || 80261c8: 2a00 cmp r2, #0 80261ca: d036 beq.n 802623a tmp.day == 0 || 80261cc: 2a07 cmp r2, #7 80261ce: d834 bhi.n 802623a /* Invalid date */ return TM_RTC_Result_Error; } /* Fill time */ RTC_TimeStruct.RTC_Hours = data->hours; 80261d0: 795a ldrb r2, [r3, #5] 80261d2: 4d1b ldr r5, [pc, #108] ; (8026240 ) RTC_TimeStruct.RTC_Minutes = data->minutes; RTC_TimeStruct.RTC_Seconds = data->seconds; /* Fill date */ RTC_DateStruct.RTC_Date = data->date; 80261d4: 4c1b ldr r4, [pc, #108] ; (8026244 ) /* Invalid date */ return TM_RTC_Result_Error; } /* Fill time */ RTC_TimeStruct.RTC_Hours = data->hours; 80261d6: 702a strb r2, [r5, #0] RTC_TimeStruct.RTC_Minutes = data->minutes; 80261d8: 791a ldrb r2, [r3, #4] RTC_DateStruct.RTC_Month = data->month; RTC_DateStruct.RTC_Year = data->year; RTC_DateStruct.RTC_WeekDay = data->day; /* Set the RTC time base to 1s and hours format to 24h */ RTC_InitStruct.RTC_HourFormat = RTC_HourFormat_24; 80261da: 481b ldr r0, [pc, #108] ; (8026248 ) return TM_RTC_Result_Error; } /* Fill time */ RTC_TimeStruct.RTC_Hours = data->hours; RTC_TimeStruct.RTC_Minutes = data->minutes; 80261dc: 706a strb r2, [r5, #1] RTC_TimeStruct.RTC_Seconds = data->seconds; 80261de: 781a ldrb r2, [r3, #0] 80261e0: 70aa strb r2, [r5, #2] /* Fill date */ RTC_DateStruct.RTC_Date = data->date; 80261e2: 79da ldrb r2, [r3, #7] 80261e4: 70a2 strb r2, [r4, #2] RTC_DateStruct.RTC_Month = data->month; 80261e6: 7a1a ldrb r2, [r3, #8] 80261e8: 7062 strb r2, [r4, #1] RTC_DateStruct.RTC_Year = data->year; 80261ea: 7a5a ldrb r2, [r3, #9] RTC_DateStruct.RTC_WeekDay = data->day; 80261ec: 799b ldrb r3, [r3, #6] RTC_TimeStruct.RTC_Minutes = data->minutes; RTC_TimeStruct.RTC_Seconds = data->seconds; /* Fill date */ RTC_DateStruct.RTC_Date = data->date; RTC_DateStruct.RTC_Month = data->month; RTC_DateStruct.RTC_Year = data->year; 80261ee: 70e2 strb r2, [r4, #3] RTC_DateStruct.RTC_WeekDay = data->day; /* Set the RTC time base to 1s and hours format to 24h */ RTC_InitStruct.RTC_HourFormat = RTC_HourFormat_24; RTC_InitStruct.RTC_AsynchPrediv = RTC_ASYNC_PREDIV; 80261f0: 221f movs r2, #31 RTC_DateStruct.RTC_Month = data->month; RTC_DateStruct.RTC_Year = data->year; RTC_DateStruct.RTC_WeekDay = data->day; /* Set the RTC time base to 1s and hours format to 24h */ RTC_InitStruct.RTC_HourFormat = RTC_HourFormat_24; 80261f2: 2700 movs r7, #0 RTC_InitStruct.RTC_AsynchPrediv = RTC_ASYNC_PREDIV; 80261f4: 6042 str r2, [r0, #4] RTC_InitStruct.RTC_SynchPrediv = RTC_SYNC_PREDIV; 80261f6: f502 7278 add.w r2, r2, #992 ; 0x3e0 RTC_TimeStruct.RTC_Seconds = data->seconds; /* Fill date */ RTC_DateStruct.RTC_Date = data->date; RTC_DateStruct.RTC_Month = data->month; RTC_DateStruct.RTC_Year = data->year; RTC_DateStruct.RTC_WeekDay = data->day; 80261fa: 7023 strb r3, [r4, #0] /* Set the RTC time base to 1s and hours format to 24h */ RTC_InitStruct.RTC_HourFormat = RTC_HourFormat_24; 80261fc: 6007 str r7, [r0, #0] RTC_InitStruct.RTC_AsynchPrediv = RTC_ASYNC_PREDIV; RTC_InitStruct.RTC_SynchPrediv = RTC_SYNC_PREDIV; 80261fe: 6082 str r2, [r0, #8] RTC_Init(&RTC_InitStruct); 8026200: f7ff fb5a bl 80258b8 /* Set time */ if (format == TM_RTC_Format_BCD) { 8026204: 2e01 cmp r6, #1 8026206: d105 bne.n 8026214 RTC_SetTime(RTC_Format_BCD, &RTC_TimeStruct); 8026208: 4630 mov r0, r6 802620a: 4629 mov r1, r5 802620c: f7ff fb98 bl 8025940 RTC_SetTime(RTC_Format_BIN, &RTC_TimeStruct); } /* Set date */ if (format == TM_RTC_Format_BCD) { RTC_SetDate(RTC_Format_BCD, &RTC_DateStruct); 8026210: 4630 mov r0, r6 8026212: e004 b.n 802621e /* Set time */ if (format == TM_RTC_Format_BCD) { RTC_SetTime(RTC_Format_BCD, &RTC_TimeStruct); } else { RTC_SetTime(RTC_Format_BIN, &RTC_TimeStruct); 8026214: 4638 mov r0, r7 8026216: 4629 mov r1, r5 8026218: f7ff fb92 bl 8025940 /* Set date */ if (format == TM_RTC_Format_BCD) { RTC_SetDate(RTC_Format_BCD, &RTC_DateStruct); } else { RTC_SetDate(RTC_Format_BIN, &RTC_DateStruct); 802621c: 4638 mov r0, r7 802621e: 4621 mov r1, r4 8026220: f7ff fbfc bl 8025a1c } if (TM_RTC_Status != RTC_STATUS_ZERO) { 8026224: 4b09 ldr r3, [pc, #36] ; (802624c ) 8026226: 6818 ldr r0, [r3, #0] 8026228: b140 cbz r0, 802623c /* Write backup registers */ RTC_WriteBackupRegister(RTC_STATUS_REG, RTC_STATUS_TIME_OK); 802622a: 2013 movs r0, #19 802622c: f244 3121 movw r1, #17185 ; 0x4321 8026230: f7ff fc5e bl 8025af0 } /* Return OK */ return TM_RTC_Result_Ok; 8026234: 2000 movs r0, #0 8026236: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} tmp.seconds > 59 || tmp.day == 0 || tmp.day > 7 ) { /* Invalid date */ return TM_RTC_Result_Error; 802623a: 2001 movs r0, #1 RTC_WriteBackupRegister(RTC_STATUS_REG, RTC_STATUS_TIME_OK); } /* Return OK */ return TM_RTC_Result_Ok; } 802623c: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 8026240: 2000e51c .word 0x2000e51c 8026244: 2000e52c .word 0x2000e52c 8026248: 2000e520 .word 0x2000e520 802624c: 20001950 .word 0x20001950 8026250: 20000648 .word 0x20000648 08026254 : TM_RTC_Result_t TM_RTC_SetDateTimeString(char* str) { 8026254: b530 push {r4, r5, lr} TM_RTC_t tmp; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026256: 2200 movs r2, #0 /* Return OK */ return TM_RTC_Result_Ok; } TM_RTC_Result_t TM_RTC_SetDateTimeString(char* str) { 8026258: b085 sub sp, #20 TM_RTC_t tmp; uint8_t i = 0; 802625a: 4613 mov r3, r2 /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802625c: 250a movs r5, #10 TM_RTC_t tmp; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802625e: e006 b.n 802626e tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026260: fb05 1202 mla r2, r5, r2, r1 8026264: 3a30 subs r2, #48 ; 0x30 i++; 8026266: 3301 adds r3, #1 uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026268: f002 02ff and.w r2, r2, #255 ; 0xff i++; 802626c: b2db uxtb r3, r3 TM_RTC_t tmp; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802626e: 5cc1 ldrb r1, [r0, r3] 8026270: f1a1 0430 sub.w r4, r1, #48 ; 0x30 8026274: 2c09 cmp r4, #9 8026276: d9f3 bls.n 8026260 tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 8026278: 3301 adds r3, #1 802627a: f88d 2007 strb.w r2, [sp, #7] 802627e: b2db uxtb r3, r3 /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026280: 2200 movs r2, #0 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026282: 250a movs r5, #10 } i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026284: e006 b.n 8026294 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026286: fb05 1202 mla r2, r5, r2, r1 802628a: 3a30 subs r2, #48 ; 0x30 i++; 802628c: 3301 adds r3, #1 i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802628e: f002 02ff and.w r2, r2, #255 ; 0xff i++; 8026292: b2db uxtb r3, r3 } i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026294: 5cc1 ldrb r1, [r0, r3] 8026296: f1a1 0430 sub.w r4, r1, #48 ; 0x30 802629a: 2c09 cmp r4, #9 802629c: d9f3 bls.n 8026286 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 802629e: 3301 adds r3, #1 80262a0: f88d 2008 strb.w r2, [sp, #8] 80262a4: b2db uxtb r3, r3 /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262a6: 2200 movs r2, #0 tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262a8: 250a movs r5, #10 } i++; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262aa: e006 b.n 80262ba tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262ac: fb05 1202 mla r2, r5, r2, r1 80262b0: 3a30 subs r2, #48 ; 0x30 i++; 80262b2: 3301 adds r3, #1 i++; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262b4: f002 02ff and.w r2, r2, #255 ; 0xff i++; 80262b8: b2db uxtb r3, r3 } i++; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262ba: 5cc1 ldrb r1, [r0, r3] 80262bc: f1a1 0430 sub.w r4, r1, #48 ; 0x30 80262c0: 2c09 cmp r4, #9 80262c2: d9f3 bls.n 80262ac tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 80262c4: 3301 adds r3, #1 80262c6: f88d 2009 strb.w r2, [sp, #9] 80262ca: b2db uxtb r3, r3 /* Get day in a week */ tmp.day = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262cc: 2200 movs r2, #0 tmp.day = tmp.day * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262ce: 250a movs r5, #10 } i++; /* Get day in a week */ tmp.day = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262d0: e006 b.n 80262e0 tmp.day = tmp.day * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262d2: fb05 1202 mla r2, r5, r2, r1 80262d6: 3a30 subs r2, #48 ; 0x30 i++; 80262d8: 3301 adds r3, #1 i++; /* Get day in a week */ tmp.day = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.day = tmp.day * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262da: f002 02ff and.w r2, r2, #255 ; 0xff i++; 80262de: b2db uxtb r3, r3 } i++; /* Get day in a week */ tmp.day = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262e0: 5cc1 ldrb r1, [r0, r3] 80262e2: f1a1 0430 sub.w r4, r1, #48 ; 0x30 80262e6: 2c09 cmp r4, #9 80262e8: d9f3 bls.n 80262d2 tmp.day = tmp.day * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 80262ea: 3301 adds r3, #1 80262ec: f88d 2006 strb.w r2, [sp, #6] 80262f0: b2db uxtb r3, r3 /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262f2: 2200 movs r2, #0 tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262f4: 250a movs r5, #10 } i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80262f6: e006 b.n 8026306 tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80262f8: fb05 1202 mla r2, r5, r2, r1 80262fc: 3a30 subs r2, #48 ; 0x30 i++; 80262fe: 3301 adds r3, #1 i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026300: f002 02ff and.w r2, r2, #255 ; 0xff i++; 8026304: b2db uxtb r3, r3 } i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026306: 5cc1 ldrb r1, [r0, r3] 8026308: f1a1 0430 sub.w r4, r1, #48 ; 0x30 802630c: 2c09 cmp r4, #9 802630e: d9f3 bls.n 80262f8 tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 8026310: 3301 adds r3, #1 8026312: f88d 2005 strb.w r2, [sp, #5] 8026316: b2db uxtb r3, r3 /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026318: 2200 movs r2, #0 tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802631a: 250a movs r5, #10 } i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802631c: e006 b.n 802632c tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802631e: fb05 1202 mla r2, r5, r2, r1 8026322: 3a30 subs r2, #48 ; 0x30 i++; 8026324: 3301 adds r3, #1 i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026326: f002 02ff and.w r2, r2, #255 ; 0xff i++; 802632a: b2db uxtb r3, r3 } i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802632c: 5cc1 ldrb r1, [r0, r3] 802632e: f1a1 0430 sub.w r4, r1, #48 ; 0x30 8026332: 2c09 cmp r4, #9 8026334: d9f3 bls.n 802631e tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 8026336: 3301 adds r3, #1 8026338: f88d 2004 strb.w r2, [sp, #4] 802633c: b2db uxtb r3, r3 /* Get seconds */ tmp.seconds = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802633e: 2200 movs r2, #0 tmp.seconds = tmp.seconds * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026340: 250a movs r5, #10 } i++; /* Get seconds */ tmp.seconds = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026342: e006 b.n 8026352 tmp.seconds = tmp.seconds * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026344: fb05 1202 mla r2, r5, r2, r1 8026348: 3a30 subs r2, #48 ; 0x30 i++; 802634a: 3301 adds r3, #1 i++; /* Get seconds */ tmp.seconds = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.seconds = tmp.seconds * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802634c: f002 02ff and.w r2, r2, #255 ; 0xff i++; 8026350: b2db uxtb r3, r3 } i++; /* Get seconds */ tmp.seconds = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026352: 5cc1 ldrb r1, [r0, r3] 8026354: f1a1 0430 sub.w r4, r1, #48 ; 0x30 8026358: 2c09 cmp r4, #9 802635a: d9f3 bls.n 8026344 802635c: a804 add r0, sp, #16 i++; } i++; /* Return status from set date time function */ return TM_RTC_SetDateTime(&tmp, TM_RTC_Format_BIN); 802635e: 2100 movs r1, #0 8026360: f800 2d10 strb.w r2, [r0, #-16]! 8026364: 4668 mov r0, sp 8026366: f7ff feb3 bl 80260d0 } 802636a: b005 add sp, #20 802636c: bd30 pop {r4, r5, pc} 0802636e : uint16_t TM_RTC_GetDaysInYear(uint8_t year) { /* Return days in year */ return TM_RTC_DAYS_IN_YEAR(2000 + year); } void TM_RTC_Config(TM_RTC_ClockSource_t source) { 802636e: b508 push {r3, lr} if (source == TM_RTC_ClockSource_Internal) { 8026370: b950 cbnz r0, 8026388 /* Enable the LSI OSC */ RCC_LSICmd(ENABLE); 8026372: 2001 movs r0, #1 8026374: f7ff f980 bl 8025678 /* Wait till LSI is ready */ while (RCC_GetFlagStatus(RCC_FLAG_LSIRDY) == RESET); 8026378: 2061 movs r0, #97 ; 0x61 802637a: f7ff fa3b bl 80257f4 802637e: 2800 cmp r0, #0 8026380: d0fa beq.n 8026378 /* Select the RTC Clock Source */ RCC_RTCCLKConfig(RCC_RTCCLKSource_LSI); 8026382: f44f 7000 mov.w r0, #512 ; 0x200 8026386: e00a b.n 802639e } else if (source == TM_RTC_ClockSource_External) { 8026388: 2801 cmp r0, #1 802638a: d10a bne.n 80263a2 /* Enable the LSE OSC */ RCC_LSEConfig(RCC_LSE_ON); 802638c: f7ff f964 bl 8025658 /* Wait till LSE is ready */ while (RCC_GetFlagStatus(RCC_FLAG_LSERDY) == RESET); 8026390: 2041 movs r0, #65 ; 0x41 8026392: f7ff fa2f bl 80257f4 8026396: 2800 cmp r0, #0 8026398: d0fa beq.n 8026390 /* Select the RTC Clock Source */ RCC_RTCCLKConfig(RCC_RTCCLKSource_LSE); 802639a: f44f 7080 mov.w r0, #256 ; 0x100 802639e: f7ff f9b7 bl 8025710 } /* Enable the RTC Clock */ RCC_RTCCLKCmd(ENABLE); 80263a2: 2001 movs r0, #1 80263a4: f7ff f9cc bl 8025740 /* Wait for register synchronization */ RTC_WaitForSynchro(); 80263a8: f7ff faa8 bl 80258fc /* Write status */ RTC_WriteBackupRegister(RTC_STATUS_REG, RTC_STATUS_INIT_OK); 80263ac: 2013 movs r0, #19 80263ae: f241 2134 movw r1, #4660 ; 0x1234 } 80263b2: e8bd 4008 ldmia.w sp!, {r3, lr} /* Wait for register synchronization */ RTC_WaitForSynchro(); /* Write status */ RTC_WriteBackupRegister(RTC_STATUS_REG, RTC_STATUS_INIT_OK); 80263b6: f7ff bb9b b.w 8025af0 80263ba: 0000 movs r0, r0 080263bc : /* Enable wakeup command */ RTC_WakeUpCmd(ENABLE); } } uint32_t TM_RTC_GetUnixTimeStamp(TM_RTC_t* data) { 80263bc: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} uint32_t days = 0, seconds = 0; uint16_t i; uint16_t year = (uint16_t) (data->year + 2000); 80263c0: 7a42 ldrb r2, [r0, #9] 80263c2: f240 73b2 movw r3, #1970 ; 0x7b2 80263c6: f502 62fa add.w r2, r2, #2000 ; 0x7d0 80263ca: 2100 movs r1, #0 if (year < TM_RTC_OFFSET_YEAR) { return 0; } /* Days in back years */ for (i = TM_RTC_OFFSET_YEAR; i < year; i++) { days += TM_RTC_DAYS_IN_YEAR(i); 80263cc: f44f 75c8 mov.w r5, #400 ; 0x190 80263d0: 2664 movs r6, #100 ; 0x64 80263d2: 079c lsls r4, r3, #30 80263d4: d108 bne.n 80263e8 80263d6: fbb3 f4f6 udiv r4, r3, r6 80263da: fb06 3414 mls r4, r6, r4, r3 80263de: b2a4 uxth r4, r4 80263e0: b114 cbz r4, 80263e8 80263e2: f44f 74b7 mov.w r4, #366 ; 0x16e 80263e6: e008 b.n 80263fa 80263e8: fbb3 f4f5 udiv r4, r3, r5 80263ec: fb05 3414 mls r4, r5, r4, r3 80263f0: b2a4 uxth r4, r4 80263f2: 2c00 cmp r4, #0 80263f4: d0f5 beq.n 80263e2 80263f6: f240 146d movw r4, #365 ; 0x16d /* Year is below offset year */ if (year < TM_RTC_OFFSET_YEAR) { return 0; } /* Days in back years */ for (i = TM_RTC_OFFSET_YEAR; i < year; i++) { 80263fa: 3301 adds r3, #1 80263fc: b29b uxth r3, r3 80263fe: 4293 cmp r3, r2 days += TM_RTC_DAYS_IN_YEAR(i); 8026400: 4421 add r1, r4 /* Year is below offset year */ if (year < TM_RTC_OFFSET_YEAR) { return 0; } /* Days in back years */ for (i = TM_RTC_OFFSET_YEAR; i < year; i++) { 8026402: d3e6 bcc.n 80263d2 days += TM_RTC_DAYS_IN_YEAR(i); } /* Days in current year */ for (i = 1; i < data->month; i++) { days += TM_RTC_Months[TM_RTC_LEAP_YEAR(year)][i - 1]; 8026404: 2364 movs r3, #100 ; 0x64 8026406: fbb2 f7f3 udiv r7, r2, r3 802640a: fb03 2317 mls r3, r3, r7, r2 802640e: b29f uxth r7, r3 8026410: f44f 73c8 mov.w r3, #400 ; 0x190 8026414: fbb2 f4f3 udiv r4, r2, r3 8026418: fb03 2414 mls r4, r3, r4, r2 802641c: b2a4 uxth r4, r4 802641e: f1d4 0401 rsbs r4, r4, #1 8026422: bf38 it cc 8026424: 2400 movcc r4, #0 /* Days in back years */ for (i = TM_RTC_OFFSET_YEAR; i < year; i++) { days += TM_RTC_DAYS_IN_YEAR(i); } /* Days in current year */ for (i = 1; i < data->month; i++) { 8026426: 7a06 ldrb r6, [r0, #8] days += TM_RTC_Months[TM_RTC_LEAP_YEAR(year)][i - 1]; 8026428: f8df c058 ldr.w ip, [pc, #88] ; 8026484 802642c: 2300 movs r3, #0 802642e: f002 0203 and.w r2, r2, #3 8026432: f04f 080c mov.w r8, #12 8026436: e00c b.n 8026452 8026438: b922 cbnz r2, 8026444 802643a: 2f00 cmp r7, #0 802643c: bf0c ite eq 802643e: 4625 moveq r5, r4 8026440: 2501 movne r5, #1 8026442: e000 b.n 8026446 8026444: 4625 mov r5, r4 8026446: fb08 3505 mla r5, r8, r5, r3 802644a: 3301 adds r3, #1 802644c: f81c 5005 ldrb.w r5, [ip, r5] 8026450: 1949 adds r1, r1, r5 /* Days in back years */ for (i = TM_RTC_OFFSET_YEAR; i < year; i++) { days += TM_RTC_DAYS_IN_YEAR(i); } /* Days in current year */ for (i = 1; i < data->month; i++) { 8026452: 1c5d adds r5, r3, #1 8026454: b2ad uxth r5, r5 8026456: 42b5 cmp r5, r6 8026458: d3ee bcc.n 8026438 days += TM_RTC_Months[TM_RTC_LEAP_YEAR(year)][i - 1]; } /* Day starts with 1 */ days += data->date - 1; 802645a: 79c3 ldrb r3, [r0, #7] seconds = days * TM_RTC_SECONDS_PER_DAY; seconds += data->hours * TM_RTC_SECONDS_PER_HOUR; 802645c: 7944 ldrb r4, [r0, #5] /* Days in current year */ for (i = 1; i < data->month; i++) { days += TM_RTC_Months[TM_RTC_LEAP_YEAR(year)][i - 1]; } /* Day starts with 1 */ days += data->date - 1; 802645e: 3b01 subs r3, #1 8026460: 1859 adds r1, r3, r1 seconds = days * TM_RTC_SECONDS_PER_DAY; seconds += data->hours * TM_RTC_SECONDS_PER_HOUR; seconds += data->minutes * TM_RTC_SECONDS_PER_MINUTE; 8026462: 7903 ldrb r3, [r0, #4] 8026464: 009a lsls r2, r3, #2 8026466: 019b lsls r3, r3, #6 8026468: 1a9a subs r2, r3, r2 days += TM_RTC_Months[TM_RTC_LEAP_YEAR(year)][i - 1]; } /* Day starts with 1 */ days += data->date - 1; seconds = days * TM_RTC_SECONDS_PER_DAY; seconds += data->hours * TM_RTC_SECONDS_PER_HOUR; 802646a: f44f 6361 mov.w r3, #3600 ; 0xe10 802646e: fb03 2304 mla r3, r3, r4, r2 seconds += data->minutes * TM_RTC_SECONDS_PER_MINUTE; seconds += data->seconds; 8026472: 7802 ldrb r2, [r0, #0] /* seconds = days * 86400; */ return seconds; } 8026474: 4802 ldr r0, [pc, #8] ; (8026480 ) } /* Day starts with 1 */ days += data->date - 1; seconds = days * TM_RTC_SECONDS_PER_DAY; seconds += data->hours * TM_RTC_SECONDS_PER_HOUR; seconds += data->minutes * TM_RTC_SECONDS_PER_MINUTE; 8026476: 189b adds r3, r3, r2 seconds += data->seconds; /* seconds = days * 86400; */ return seconds; } 8026478: fb00 3001 mla r0, r0, r1, r3 802647c: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8026480: 00015180 .word 0x00015180 8026484: 20000648 .word 0x20000648 08026488 : /* Return status from set date time function */ return TM_RTC_SetDateTime(&tmp, TM_RTC_Format_BIN); } void TM_RTC_GetDateTime(TM_RTC_t* data, TM_RTC_Format_t format) { 8026488: b538 push {r3, r4, r5, lr} 802648a: 4604 mov r4, r0 uint32_t unix; /* Get time */ if (format == TM_RTC_Format_BIN) { 802648c: 460d mov r5, r1 802648e: b909 cbnz r1, 8026494 RTC_GetTime(RTC_Format_BIN, &RTC_TimeStruct); 8026490: 4608 mov r0, r1 8026492: e000 b.n 8026496 } else { RTC_GetTime(RTC_Format_BCD, &RTC_TimeStruct); 8026494: 2001 movs r0, #1 8026496: 4911 ldr r1, [pc, #68] ; (80264dc ) 8026498: f7ff fa9e bl 80259d8 } /* Format hours */ data->hours = RTC_TimeStruct.RTC_Hours; 802649c: 4b0f ldr r3, [pc, #60] ; (80264dc ) 802649e: 781a ldrb r2, [r3, #0] 80264a0: 7162 strb r2, [r4, #5] data->minutes = RTC_TimeStruct.RTC_Minutes; 80264a2: 785a ldrb r2, [r3, #1] data->seconds = RTC_TimeStruct.RTC_Seconds; 80264a4: 789b ldrb r3, [r3, #2] RTC_GetTime(RTC_Format_BCD, &RTC_TimeStruct); } /* Format hours */ data->hours = RTC_TimeStruct.RTC_Hours; data->minutes = RTC_TimeStruct.RTC_Minutes; 80264a6: 7122 strb r2, [r4, #4] data->seconds = RTC_TimeStruct.RTC_Seconds; 80264a8: 7023 strb r3, [r4, #0] /* Get subseconds */ data->subseconds = RTC->SSR; 80264aa: 4b0d ldr r3, [pc, #52] ; (80264e0 ) 80264ac: 6a9b ldr r3, [r3, #40] ; 0x28 80264ae: 8063 strh r3, [r4, #2] /* Get date */ if (format == TM_RTC_Format_BIN) { 80264b0: b90d cbnz r5, 80264b6 RTC_GetDate(RTC_Format_BIN, &RTC_DateStruct); 80264b2: 4628 mov r0, r5 80264b4: e000 b.n 80264b8 } else { RTC_GetDate(RTC_Format_BCD, &RTC_DateStruct); 80264b6: 2001 movs r0, #1 80264b8: 490a ldr r1, [pc, #40] ; (80264e4 ) 80264ba: f7ff faf9 bl 8025ab0 } /* Format date */ data->year = RTC_DateStruct.RTC_Year; 80264be: 4b09 ldr r3, [pc, #36] ; (80264e4 ) 80264c0: 78da ldrb r2, [r3, #3] 80264c2: 7262 strb r2, [r4, #9] data->month = RTC_DateStruct.RTC_Month; 80264c4: 785a ldrb r2, [r3, #1] 80264c6: 7222 strb r2, [r4, #8] data->date = RTC_DateStruct.RTC_Date; 80264c8: 789a ldrb r2, [r3, #2] data->day = RTC_DateStruct.RTC_WeekDay; 80264ca: 781b ldrb r3, [r3, #0] } /* Format date */ data->year = RTC_DateStruct.RTC_Year; data->month = RTC_DateStruct.RTC_Month; data->date = RTC_DateStruct.RTC_Date; 80264cc: 71e2 strb r2, [r4, #7] data->day = RTC_DateStruct.RTC_WeekDay; 80264ce: 71a3 strb r3, [r4, #6] /* Calculate unix offset */ unix = TM_RTC_GetUnixTimeStamp(data); 80264d0: 4620 mov r0, r4 80264d2: f7ff ff73 bl 80263bc data->unix = unix; 80264d6: 60e0 str r0, [r4, #12] 80264d8: bd38 pop {r3, r4, r5, pc} 80264da: bf00 nop 80264dc: 2000e51c .word 0x2000e51c 80264e0: 40002800 .word 0x40002800 80264e4: 2000e52c .word 0x2000e52c 080264e8 : } } uint32_t TM_RTC_Init(TM_RTC_ClockSource_t source) { 80264e8: b5f0 push {r4, r5, r6, r7, lr} uint32_t status; uint8_t stat = 1; TM_RTC_t datatime; /* Enable PWR peripheral clock */ RCC_APB1PeriphClockCmd(RCC_APB1Periph_PWR, ENABLE); 80264ea: 2101 movs r1, #1 } } uint32_t TM_RTC_Init(TM_RTC_ClockSource_t source) { 80264ec: b085 sub sp, #20 80264ee: 4605 mov r5, r0 uint32_t status; uint8_t stat = 1; TM_RTC_t datatime; /* Enable PWR peripheral clock */ RCC_APB1PeriphClockCmd(RCC_APB1Periph_PWR, ENABLE); 80264f0: f04f 5080 mov.w r0, #268435456 ; 0x10000000 80264f4: f7ff f942 bl 802577c /* Allow access to BKP Domain */ PWR_BackupAccessCmd(ENABLE); 80264f8: 2001 movs r0, #1 80264fa: f7ff f8a7 bl 802564c /* Get RTC status */ status = RTC_ReadBackupRegister(RTC_STATUS_REG); 80264fe: 2013 movs r0, #19 8026500: f7ff fb06 bl 8025b10 if (status == RTC_STATUS_TIME_OK) 8026504: f244 3321 movw r3, #17185 ; 0x4321 8026508: 4298 cmp r0, r3 802650a: 4e25 ldr r6, [pc, #148] ; (80265a0 ) 802650c: d113 bne.n 8026536 { TM_RTC_Status = RTC_STATUS_TIME_OK; 802650e: 6030 str r0, [r6, #0] /* Start internal clock if we choose internal clock */ if (source == TM_RTC_ClockSource_Internal) 8026510: b915 cbnz r5, 8026518 TM_RTC_Config(TM_RTC_ClockSource_Internal); 8026512: 4628 mov r0, r5 8026514: f7ff ff2b bl 802636e /* Wait for RTC APB registers synchronisation (needed after start-up from Reset) */ RTC_WaitForSynchro(); 8026518: f7ff f9f0 bl 80258fc /* Clear interrupt flags */ RTC_ClearITPendingBit(RTC_IT_WUT); 802651c: f44f 4080 mov.w r0, #16384 ; 0x4000 8026520: f7ff fb1e bl 8025b60 EXTI->PR = 0x00400000; 8026524: 4b1f ldr r3, [pc, #124] ; (80265a4 ) 8026526: f44f 0280 mov.w r2, #4194304 ; 0x400000 802652a: 615a str r2, [r3, #20] /* Get date and time */ TM_RTC_GetDateTime(&datatime, TM_RTC_Format_BIN); 802652c: 4668 mov r0, sp 802652e: 2100 movs r1, #0 8026530: f7ff ffaa bl 8026488 8026534: e02f b.n 8026596 } else if (status == RTC_STATUS_INIT_OK) 8026536: f241 2734 movw r7, #4660 ; 0x1234 802653a: 42b8 cmp r0, r7 802653c: d10f bne.n 802655e { TM_RTC_Status = RTC_STATUS_INIT_OK; 802653e: 6030 str r0, [r6, #0] /* Start internal clock if we choose internal clock */ if (source == TM_RTC_ClockSource_Internal) 8026540: b915 cbnz r5, 8026548 TM_RTC_Config(TM_RTC_ClockSource_Internal); 8026542: 4628 mov r0, r5 8026544: f7ff ff13 bl 802636e /* Wait for RTC APB registers synchronisation (needed after start-up from Reset) */ RTC_WaitForSynchro(); 8026548: f7ff f9d8 bl 80258fc /* Clear interrupt flags */ RTC_ClearITPendingBit(RTC_IT_WUT); 802654c: f44f 4080 mov.w r0, #16384 ; 0x4000 8026550: f7ff fb06 bl 8025b60 EXTI->PR = 0x00400000; 8026554: 4b13 ldr r3, [pc, #76] ; (80265a4 ) 8026556: f44f 0280 mov.w r2, #4194304 ; 0x400000 802655a: 615a str r2, [r3, #20] 802655c: e01b b.n 8026596 /* Get date and time */ //TM_RTC_GetDateTime(&datatime, TM_RTC_Format_BIN); } else { TM_RTC_Status = RTC_STATUS_ZERO; 802655e: 2400 movs r4, #0 /* Return status = 0 -> RTC Never initialized before */ stat = RTC_STATUS_ZERO; /* Config RTC */ TM_RTC_Config(source); 8026560: 4628 mov r0, r5 /* Get date and time */ //TM_RTC_GetDateTime(&datatime, TM_RTC_Format_BIN); } else { TM_RTC_Status = RTC_STATUS_ZERO; 8026562: 6034 str r4, [r6, #0] /* Return status = 0 -> RTC Never initialized before */ stat = RTC_STATUS_ZERO; /* Config RTC */ TM_RTC_Config(source); 8026564: f7ff ff03 bl 802636e datatime.day = 1; datatime.month = 1; datatime.year = 0; datatime.hours = 0; datatime.minutes = 0; datatime.seconds = 0; 8026568: a804 add r0, sp, #16 stat = RTC_STATUS_ZERO; /* Config RTC */ TM_RTC_Config(source); /* Set date and time */ datatime.date = 1; 802656a: 2301 movs r3, #1 datatime.day = 1; datatime.month = 1; datatime.year = 0; datatime.hours = 0; datatime.minutes = 0; datatime.seconds = 0; 802656c: f800 4d10 strb.w r4, [r0, #-16]! /* Set date and time */ TM_RTC_SetDateTime(&datatime, TM_RTC_Format_BIN); 8026570: 4621 mov r1, r4 8026572: 4668 mov r0, sp stat = RTC_STATUS_ZERO; /* Config RTC */ TM_RTC_Config(source); /* Set date and time */ datatime.date = 1; 8026574: f88d 3007 strb.w r3, [sp, #7] datatime.day = 1; 8026578: f88d 3006 strb.w r3, [sp, #6] datatime.month = 1; 802657c: f88d 3008 strb.w r3, [sp, #8] datatime.year = 0; 8026580: f88d 4009 strb.w r4, [sp, #9] datatime.hours = 0; 8026584: f88d 4005 strb.w r4, [sp, #5] datatime.minutes = 0; 8026588: f88d 4004 strb.w r4, [sp, #4] datatime.seconds = 0; /* Set date and time */ TM_RTC_SetDateTime(&datatime, TM_RTC_Format_BIN); 802658c: f7ff fda0 bl 80260d0 /* Initialized OK */ TM_RTC_Status = RTC_STATUS_INIT_OK; 8026590: 6037 str r7, [r6, #0] } /* If first time initialized */ if (stat == RTC_STATUS_ZERO) return 0; 8026592: 4620 mov r0, r4 8026594: e001 b.n 802659a return TM_RTC_Status; 8026596: 4b02 ldr r3, [pc, #8] ; (80265a0 ) 8026598: 6818 ldr r0, [r3, #0] } 802659a: b005 add sp, #20 802659c: bdf0 pop {r4, r5, r6, r7, pc} 802659e: bf00 nop 80265a0: 20001950 .word 0x20001950 80265a4: 40013c00 .word 0x40013c00 080265a8 : uint16_t year; /* Store unix time to unix in struct */ data->unix = unix; /* Get seconds from unix */ data->seconds = unix % 60; 80265a8: 233c movs r3, #60 ; 0x3c /* seconds = days * 86400; */ return seconds; } void TM_RTC_GetDateTimeFromUnix(TM_RTC_t* data, uint32_t unix) { 80265aa: b5f0 push {r4, r5, r6, r7, lr} uint16_t year; /* Store unix time to unix in struct */ data->unix = unix; /* Get seconds from unix */ data->seconds = unix % 60; 80265ac: fbb1 f4f3 udiv r4, r1, r3 /* Go to minutes */ unix /= 60; /* Get minutes */ data->minutes = unix % 60; 80265b0: fbb4 f2f3 udiv r2, r4, r3 void TM_RTC_GetDateTimeFromUnix(TM_RTC_t* data, uint32_t unix) { uint16_t year; /* Store unix time to unix in struct */ data->unix = unix; 80265b4: 60c1 str r1, [r0, #12] /* Get seconds from unix */ data->seconds = unix % 60; 80265b6: fb03 1114 mls r1, r3, r4, r1 80265ba: 7001 strb r1, [r0, #0] /* Go to minutes */ unix /= 60; /* Get minutes */ data->minutes = unix % 60; 80265bc: fb03 4312 mls r3, r3, r2, r4 /* Go to hours */ unix /= 60; /* Get hours */ data->hours = unix % 24; 80265c0: 2118 movs r1, #24 /* Get seconds from unix */ data->seconds = unix % 60; /* Go to minutes */ unix /= 60; /* Get minutes */ data->minutes = unix % 60; 80265c2: 7103 strb r3, [r0, #4] /* Go to hours */ unix /= 60; /* Get hours */ data->hours = unix % 24; 80265c4: fbb2 f3f1 udiv r3, r2, r1 80265c8: fb01 2213 mls r2, r1, r3, r2 80265cc: 7142 strb r2, [r0, #5] /* Go to days */ unix /= 24; /* Get week day */ /* Monday is day one */ data->day = (unix + 3) % 7 + 1; 80265ce: 1cd9 adds r1, r3, #3 80265d0: 2207 movs r2, #7 80265d2: fbb1 f4f2 udiv r4, r1, r2 80265d6: fb02 1214 mls r2, r2, r4, r1 80265da: 3201 adds r2, #1 80265dc: 7182 strb r2, [r0, #6] /* Get year */ year = 1970; while (1) { if (TM_RTC_LEAP_YEAR(year)) { if (unix >= 366) { 80265de: f240 156d movw r5, #365 ; 0x16d /* Get week day */ /* Monday is day one */ data->day = (unix + 3) % 7 + 1; /* Get year */ year = 1970; 80265e2: f240 72b2 movw r2, #1970 ; 0x7b2 while (1) { if (TM_RTC_LEAP_YEAR(year)) { 80265e6: f44f 71c8 mov.w r1, #400 ; 0x190 80265ea: 2464 movs r4, #100 ; 0x64 80265ec: f012 0603 ands.w r6, r2, #3 80265f0: d105 bne.n 80265fe 80265f2: fbb2 f7f4 udiv r7, r2, r4 80265f6: fb04 2717 mls r7, r4, r7, r2 80265fa: b2bf uxth r7, r7 80265fc: b92f cbnz r7, 802660a 80265fe: fbb2 f7f1 udiv r7, r2, r1 8026602: fb01 2717 mls r7, r1, r7, r2 8026606: b2bf uxth r7, r7 8026608: b927 cbnz r7, 8026614 if (unix >= 366) { 802660a: 42ab cmp r3, r5 802660c: d90b bls.n 8026626 unix -= 366; 802660e: f5a3 73b7 sub.w r3, r3, #366 ; 0x16e /* Get year */ year = 1970; while (1) { if (TM_RTC_LEAP_YEAR(year)) { if (unix >= 366) { 8026612: e005 b.n 8026620 unix -= 366; } else { break; } } else if (unix >= 365) { 8026614: f5b3 7fb6 cmp.w r3, #364 ; 0x16c 8026618: d905 bls.n 8026626 unix -= 365; 802661a: f46f 76b6 mvn.w r6, #364 ; 0x16c 802661e: 199b adds r3, r3, r6 } else { break; } year++; 8026620: 3201 adds r2, #1 8026622: b292 uxth r2, r2 } 8026624: e7e2 b.n 80265ec /* Get year in xx format */ data->year = (uint8_t) (year - 2000); 8026626: f102 0130 add.w r1, r2, #48 ; 0x30 802662a: 7241 strb r1, [r0, #9] /* Get month */ for (data->month = 0; data->month < 12; data->month++) { 802662c: 2100 movs r1, #0 802662e: 7201 strb r1, [r0, #8] if (TM_RTC_LEAP_YEAR(year) && unix >= (uint32_t)TM_RTC_Months[1][data->month]) { 8026630: 2164 movs r1, #100 ; 0x64 8026632: fbb2 f7f1 udiv r7, r2, r1 8026636: fb01 2117 mls r1, r1, r7, r2 802663a: b28f uxth r7, r1 802663c: f44f 71c8 mov.w r1, #400 ; 0x190 8026640: fbb2 f4f1 udiv r4, r2, r1 8026644: fb01 2214 mls r2, r1, r4, r2 8026648: b292 uxth r2, r2 unix -= TM_RTC_Months[1][data->month]; } else if (unix >= (uint32_t)TM_RTC_Months[0][data->month]) { 802664a: 4c0c ldr r4, [pc, #48] ; (802667c ) year++; } /* Get year in xx format */ data->year = (uint8_t) (year - 2000); /* Get month */ for (data->month = 0; data->month < 12; data->month++) { 802664c: e012 b.n 8026674 if (TM_RTC_LEAP_YEAR(year) && unix >= (uint32_t)TM_RTC_Months[1][data->month]) { 802664e: b906 cbnz r6, 8026652 8026650: b907 cbnz r7, 8026654 8026652: b922 cbnz r2, 802665e 8026654: 1865 adds r5, r4, r1 8026656: 7b2d ldrb r5, [r5, #12] 8026658: 42ab cmp r3, r5 802665a: d300 bcc.n 802665e 802665c: e007 b.n 802666e unix -= TM_RTC_Months[1][data->month]; } else if (unix >= (uint32_t)TM_RTC_Months[0][data->month]) { 802665e: 5c65 ldrb r5, [r4, r1] 8026660: 42ab cmp r3, r5 8026662: d204 bcs.n 802666e break; } } /* Get month */ /* Month starts with 1 */ data->month++; 8026664: 3101 adds r1, #1 /* Get date */ /* Date starts with 1 */ data->date = unix + 1; 8026666: 3301 adds r3, #1 break; } } /* Get month */ /* Month starts with 1 */ data->month++; 8026668: 7201 strb r1, [r0, #8] /* Get date */ /* Date starts with 1 */ data->date = unix + 1; 802666a: 71c3 strb r3, [r0, #7] 802666c: bdf0 pop {r4, r5, r6, r7, pc} year++; } /* Get year in xx format */ data->year = (uint8_t) (year - 2000); /* Get month */ for (data->month = 0; data->month < 12; data->month++) { 802666e: 3101 adds r1, #1 if (TM_RTC_LEAP_YEAR(year) && unix >= (uint32_t)TM_RTC_Months[1][data->month]) { unix -= TM_RTC_Months[1][data->month]; } else if (unix >= (uint32_t)TM_RTC_Months[0][data->month]) { unix -= TM_RTC_Months[0][data->month]; 8026670: 1b5b subs r3, r3, r5 year++; } /* Get year in xx format */ data->year = (uint8_t) (year - 2000); /* Get month */ for (data->month = 0; data->month < 12; data->month++) { 8026672: 7201 strb r1, [r0, #8] 8026674: 7a01 ldrb r1, [r0, #8] 8026676: 290b cmp r1, #11 8026678: d9e9 bls.n 802664e 802667a: e7f3 b.n 8026664 802667c: 20000648 .word 0x20000648 08026680 : * @brief Кореектировака времени. * @param Часовой пояс * @retval */ void TM_RTC_Correction(float utc) { 8026680: b510 push {r4, lr} 8026682: b088 sub sp, #32 8026684: 4604 mov r4, r0 TM_RTC_t newData; int utcSec; uint32_t unixTime; /* Получаем текущее время */ TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 8026686: 2100 movs r1, #0 8026688: 4668 mov r0, sp 802668a: f7ff fefd bl 8026488 /* Рассчитываем поправку */ utcSec = (int)(3600.0*utc); 802668e: 4620 mov r0, r4 8026690: f7f9 ff42 bl 8020518 <__aeabi_f2d> 8026694: a308 add r3, pc, #32 ; (adr r3, 80266b8 ) 8026696: e9d3 2300 ldrd r2, r3, [r3] 802669a: f7f9 ff91 bl 80205c0 <__aeabi_dmul> 802669e: f7fa fa29 bl 8020af4 <__aeabi_d2iz> unixTime = data.unix + utcSec; 80266a2: 9903 ldr r1, [sp, #12] 80266a4: 1841 adds r1, r0, r1 /* Устанавливаем новое время */ TM_RTC_GetDateTimeFromUnix(&newData, unixTime); 80266a6: a804 add r0, sp, #16 80266a8: f7ff ff7e bl 80265a8 TM_RTC_SetDateTime(&newData, TM_RTC_Format_BIN); 80266ac: a804 add r0, sp, #16 80266ae: 2100 movs r1, #0 80266b0: f7ff fd0e bl 80260d0 } 80266b4: b008 add sp, #32 80266b6: bd10 pop {r4, pc} 80266b8: 00000000 .word 0x00000000 80266bc: 40ac2000 .word 0x40ac2000 080266c0 : return TM_RTC_Status; } void TM_RTC_SetDataTimeUnix(uint32_t unixTime) { 80266c0: b51f push {r0, r1, r2, r3, r4, lr} 80266c2: 4601 mov r1, r0 TM_RTC_t data; TM_RTC_GetDateTimeFromUnix(&data, unixTime); 80266c4: 4668 mov r0, sp 80266c6: f7ff ff6f bl 80265a8 TM_RTC_SetDateTime(&data, TM_RTC_Format_BIN); 80266ca: 4668 mov r0, sp 80266cc: 2100 movs r1, #0 80266ce: f7ff fcff bl 80260d0 } 80266d2: b005 add sp, #20 80266d4: bd00 pop {pc} 080266d6 : /* Read data from backup register */ return *(uint32_t *)((&RTC->BKP0R) + 4 * location); } /* Callbacks */ __weak void TM_RTC_RequestHandler(void) { 80266d6: 4770 bx lr 080266d8 : /* If user needs this function, then they should be defined separatelly in your project */ } __weak void TM_RTC_AlarmAHandler(void) { 80266d8: 4770 bx lr 080266da : /* If user needs this function, then they should be defined separatelly in your project */ } __weak void TM_RTC_AlarmBHandler(void) { 80266da: 4770 bx lr 080266dc : /* If user needs this function, then they should be defined separatelly in your project */ } /* Private RTC IRQ handlers */ void RTC_WKUP_IRQHandler(void) { 80266dc: b508 push {r3, lr} /* Check for RTC interrupt */ if (RTC_GetITStatus(RTC_IT_WUT) != RESET) { 80266de: f44f 4080 mov.w r0, #16384 ; 0x4000 80266e2: f7ff fa25 bl 8025b30 80266e6: b128 cbz r0, 80266f4 /* Clear interrupt flags */ RTC_ClearITPendingBit(RTC_IT_WUT); 80266e8: f44f 4080 mov.w r0, #16384 ; 0x4000 80266ec: f7ff fa38 bl 8025b60 /* Call user function */ TM_RTC_RequestHandler(); 80266f0: f7ff fff1 bl 80266d6 } /* Clear EXTI line 22 bit */ EXTI->PR = 0x00400000; 80266f4: 4b02 ldr r3, [pc, #8] ; (8026700 ) 80266f6: f44f 0280 mov.w r2, #4194304 ; 0x400000 80266fa: 615a str r2, [r3, #20] 80266fc: bd08 pop {r3, pc} 80266fe: bf00 nop 8026700: 40013c00 .word 0x40013c00 08026704 : } void RTC_Alarm_IRQHandler(void) { 8026704: b508 push {r3, lr} /* RTC Alarm A check */ if (RTC_GetITStatus(RTC_IT_ALRA) != RESET) { 8026706: f44f 5080 mov.w r0, #4096 ; 0x1000 802670a: f7ff fa11 bl 8025b30 802670e: b128 cbz r0, 802671c /* Clear RTC Alarm A interrupt flag */ RTC_ClearITPendingBit(RTC_IT_ALRA); 8026710: f44f 5080 mov.w r0, #4096 ; 0x1000 8026714: f7ff fa24 bl 8025b60 /* Call user function for Alarm A */ TM_RTC_AlarmAHandler(); 8026718: f7ff ffde bl 80266d8 } /* RTC Alarm B check */ if (RTC_GetITStatus(RTC_IT_ALRB) != RESET) { 802671c: f44f 5000 mov.w r0, #8192 ; 0x2000 8026720: f7ff fa06 bl 8025b30 8026724: b128 cbz r0, 8026732 /* Clear RTC Alarm A interrupt flag */ RTC_ClearITPendingBit(RTC_IT_ALRB); 8026726: f44f 5000 mov.w r0, #8192 ; 0x2000 802672a: f7ff fa19 bl 8025b60 /* Call user function for Alarm B */ TM_RTC_AlarmBHandler(); 802672e: f7ff ffd4 bl 80266da } /* Clear EXTI line 17 bit */ EXTI->PR = 0x00020000; 8026732: 4b02 ldr r3, [pc, #8] ; (802673c ) 8026734: f44f 3200 mov.w r2, #131072 ; 0x20000 8026738: 615a str r2, [r3, #20] 802673a: bd08 pop {r3, pc} 802673c: 40013c00 .word 0x40013c00 08026740 : /** * @brief Установливает время срабатывания профилактики сульфатации */ void RTC_SetProfTime(char *str) { 8026740: b530 push {r4, r5, lr} uint32_t unixTime; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026742: 2200 movs r2, #0 /** * @brief Установливает время срабатывания профилактики сульфатации */ void RTC_SetProfTime(char *str) { 8026744: b085 sub sp, #20 TM_RTC_t tmp; uint32_t unixTime; uint8_t i = 0; 8026746: 4613 mov r3, r2 /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026748: 250a movs r5, #10 uint32_t unixTime; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802674a: e006 b.n 802675a tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802674c: fb05 1202 mla r2, r5, r2, r1 8026750: 3a30 subs r2, #48 ; 0x30 i++; 8026752: 3301 adds r3, #1 uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026754: f002 02ff and.w r2, r2, #255 ; 0xff i++; 8026758: b2db uxtb r3, r3 uint32_t unixTime; uint8_t i = 0; /* Get date */ tmp.date = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802675a: 5cc1 ldrb r1, [r0, r3] 802675c: f1a1 0430 sub.w r4, r1, #48 ; 0x30 8026760: 2c09 cmp r4, #9 8026762: d9f3 bls.n 802674c tmp.date = tmp.date * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 8026764: 3301 adds r3, #1 8026766: f88d 2007 strb.w r2, [sp, #7] 802676a: b2db uxtb r3, r3 /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 802676c: 2200 movs r2, #0 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802676e: 250a movs r5, #10 } i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026770: e006 b.n 8026780 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026772: fb05 1202 mla r2, r5, r2, r1 8026776: 3a30 subs r2, #48 ; 0x30 i++; 8026778: 3301 adds r3, #1 i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); 802677a: f002 02ff and.w r2, r2, #255 ; 0xff i++; 802677e: b2db uxtb r3, r3 } i++; /* Get month */ tmp.month = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026780: 5cc1 ldrb r1, [r0, r3] 8026782: f1a1 0430 sub.w r4, r1, #48 ; 0x30 8026786: 2c09 cmp r4, #9 8026788: d9f3 bls.n 8026772 tmp.month = tmp.month * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } //i++; i+=3; 802678a: 3303 adds r3, #3 802678c: f88d 2008 strb.w r2, [sp, #8] 8026790: b2db uxtb r3, r3 /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026792: 2200 movs r2, #0 tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026794: 250a movs r5, #10 //i++; i+=3; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 8026796: e006 b.n 80267a6 tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 8026798: fb05 1202 mla r2, r5, r2, r1 802679c: 3a30 subs r2, #48 ; 0x30 i++; 802679e: 3301 adds r3, #1 i+=3; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267a0: f002 02ff and.w r2, r2, #255 ; 0xff i++; 80267a4: b2db uxtb r3, r3 //i++; i+=3; /* Get year */ tmp.year = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267a6: 5cc1 ldrb r1, [r0, r3] 80267a8: f1a1 0430 sub.w r4, r1, #48 ; 0x30 80267ac: 2c09 cmp r4, #9 80267ae: d9f3 bls.n 8026798 tmp.year = tmp.year * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; i++; 80267b0: 3302 adds r3, #2 80267b2: f88d 2009 strb.w r2, [sp, #9] 80267b6: b2db uxtb r3, r3 /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267b8: 2200 movs r2, #0 tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267ba: 250a movs r5, #10 i++; i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267bc: e006 b.n 80267cc tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267be: fb05 1202 mla r2, r5, r2, r1 80267c2: 3a30 subs r2, #48 ; 0x30 i++; 80267c4: 3301 adds r3, #1 i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267c6: f002 02ff and.w r2, r2, #255 ; 0xff i++; 80267ca: b2db uxtb r3, r3 i++; i++; /* Get hours */ tmp.hours = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267cc: 5cc1 ldrb r1, [r0, r3] 80267ce: f1a1 0430 sub.w r4, r1, #48 ; 0x30 80267d2: 2c09 cmp r4, #9 80267d4: d9f3 bls.n 80267be tmp.hours = tmp.hours * 10 + TM_RTC_CHAR2NUM(*(str + i)); i++; } i++; 80267d6: 3301 adds r3, #1 80267d8: f88d 2005 strb.w r2, [sp, #5] 80267dc: b2db uxtb r3, r3 /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267de: 2200 movs r2, #0 tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267e0: 250a movs r5, #10 } i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267e2: e006 b.n 80267f2 tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267e4: fb05 1202 mla r2, r5, r2, r1 80267e8: 3a30 subs r2, #48 ; 0x30 i++; 80267ea: 3301 adds r3, #1 i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { tmp.minutes = tmp.minutes * 10 + TM_RTC_CHAR2NUM(*(str + i)); 80267ec: f002 02ff and.w r2, r2, #255 ; 0xff i++; 80267f0: b2db uxtb r3, r3 } i++; /* Get minutes */ tmp.minutes = 0; while (TM_RTC_CHARISNUM(*(str + i))) { 80267f2: 5cc1 ldrb r1, [r0, r3] 80267f4: f1a1 0430 sub.w r4, r1, #48 ; 0x30 80267f8: 2c09 cmp r4, #9 80267fa: d9f3 bls.n 80267e4 i++; } i++; /* Get seconds */ tmp.seconds = 0; 80267fc: 2300 movs r3, #0 80267fe: f88d 3000 strb.w r3, [sp] /* Устанавливаем +1 для профилактики */ tmp.year += 1; 8026802: f89d 3009 ldrb.w r3, [sp, #9] 8026806: f88d 2004 strb.w r2, [sp, #4] 802680a: 3301 adds r3, #1 unixTime = TM_RTC_GetUnixTimeStamp(&tmp); 802680c: 4668 mov r0, sp /* Get seconds */ tmp.seconds = 0; /* Устанавливаем +1 для профилактики */ tmp.year += 1; 802680e: f88d 3009 strb.w r3, [sp, #9] unixTime = TM_RTC_GetUnixTimeStamp(&tmp); 8026812: f7ff fdd3 bl 80263bc if (location > 18) { return; } /* Write data to backup register */ *(uint32_t *)((&RTC->BKP0R) + 4 * location) = value; 8026816: 4b02 ldr r3, [pc, #8] ; (8026820 ) 8026818: 6018 str r0, [r3, #0] /* Устанавливаем +1 для профилактики */ tmp.year += 1; unixTime = TM_RTC_GetUnixTimeStamp(&tmp); TM_RTC_WriteBackupRegister(RTC_BKP_DR0, unixTime); 802681a: b005 add sp, #20 802681c: bd30 pop {r4, r5, pc} 802681e: bf00 nop 8026820: 40002850 .word 0x40002850 08026824 : //static TN_MUTEX spi_mutex; static uint8_t spi_tx_rx(uint8_t byte) { while (!(SPI2->SR & SPI_SR_TXE)) {} 8026824: 4907 ldr r1, [pc, #28] ; (8026844 ) 8026826: 890a ldrh r2, [r1, #8] 8026828: 4b06 ldr r3, [pc, #24] ; (8026844 ) 802682a: f002 0202 and.w r2, r2, #2 802682e: b292 uxth r2, r2 8026830: 2a00 cmp r2, #0 8026832: d0f8 beq.n 8026826 SPI2->DR = byte; 8026834: 8198 strh r0, [r3, #12] while (!(SPI2->SR & SPI_SR_RXNE)) {} 8026836: 891a ldrh r2, [r3, #8] 8026838: 07d2 lsls r2, r2, #31 802683a: d5fc bpl.n 8026836 return SPI2->DR; 802683c: 4b01 ldr r3, [pc, #4] ; (8026844 ) 802683e: 8998 ldrh r0, [r3, #12] } 8026840: b2c0 uxtb r0, r0 8026842: 4770 bx lr 8026844: 40003800 .word 0x40003800 08026848 : status = spi_tx_rx(0); } while (status & SR_WIP); SPI_FLASH_CS_H(); } static inline void send_addr(int addr) { 8026848: b510 push {r4, lr} 802684a: 4604 mov r4, r0 spi_tx_rx((addr >> 16) & 0xFF); 802684c: f3c0 4007 ubfx r0, r0, #16, #8 8026850: f7ff ffe8 bl 8026824 spi_tx_rx((addr >> 8) & 0xFF); 8026854: f3c4 2007 ubfx r0, r4, #8, #8 8026858: f7ff ffe4 bl 8026824 spi_tx_rx(addr & 0xFF); 802685c: b2e0 uxtb r0, r4 } 802685e: e8bd 4010 ldmia.w sp!, {r4, lr} } static inline void send_addr(int addr) { spi_tx_rx((addr >> 16) & 0xFF); spi_tx_rx((addr >> 8) & 0xFF); spi_tx_rx(addr & 0xFF); 8026862: f7ff bfdf b.w 8026824 08026866 : spi_flash_desc_t spi_flash_desc; static inline void wait_write_enable(void) { uint8_t status; // spi_cs_down(); SPI_FLASH_CS_L(); 8026866: 2005 movs r0, #5 #define SR_WEL (1 << 1) #define SR_SRWD (1 << 7) spi_flash_desc_t spi_flash_desc; static inline void wait_write_enable(void) { 8026868: b508 push {r3, lr} uint8_t status; // spi_cs_down(); SPI_FLASH_CS_L(); 802686a: 2100 movs r1, #0 802686c: f7ff fb60 bl 8025f30 spi_tx_rx(CMD_RDSR); 8026870: 2005 movs r0, #5 8026872: f7ff ffd7 bl 8026824 do { status = spi_tx_rx(0); 8026876: 2000 movs r0, #0 8026878: f7ff ffd4 bl 8026824 } while (!(status & SR_WEL)); 802687c: f000 0002 and.w r0, r0, #2 8026880: b2c0 uxtb r0, r0 8026882: 2800 cmp r0, #0 8026884: d0f7 beq.n 8026876 // spi_cs_up(); SPI_FLASH_CS_H(); 8026886: 2005 movs r0, #5 8026888: 2101 movs r1, #1 } 802688a: e8bd 4008 ldmia.w sp!, {r3, lr} spi_tx_rx(CMD_RDSR); do { status = spi_tx_rx(0); } while (!(status & SR_WEL)); // spi_cs_up(); SPI_FLASH_CS_H(); 802688e: f7ff bb4f b.w 8025f30 08026892 : } static inline void wait_write_end(void) { uint8_t status; SPI_FLASH_CS_L(); 8026892: 2005 movs r0, #5 } while (!(status & SR_WEL)); // spi_cs_up(); SPI_FLASH_CS_H(); } static inline void wait_write_end(void) { 8026894: b508 push {r3, lr} uint8_t status; SPI_FLASH_CS_L(); 8026896: 2100 movs r1, #0 8026898: f7ff fb4a bl 8025f30 spi_tx_rx(CMD_RDSR); 802689c: 2005 movs r0, #5 802689e: f7ff ffc1 bl 8026824 do { status = spi_tx_rx(0); 80268a2: 2000 movs r0, #0 80268a4: f7ff ffbe bl 8026824 } while (status & SR_WIP); 80268a8: 07c1 lsls r1, r0, #31 80268aa: d4fa bmi.n 80268a2 SPI_FLASH_CS_H(); 80268ac: 2005 movs r0, #5 80268ae: 2101 movs r1, #1 } 80268b0: e8bd 4008 ldmia.w sp!, {r3, lr} SPI_FLASH_CS_L(); spi_tx_rx(CMD_RDSR); do { status = spi_tx_rx(0); } while (status & SR_WIP); SPI_FLASH_CS_H(); 80268b4: f7ff bb3c b.w 8025f30 080268b8 : *((uint8_t *)buf++) = spi_tx_rx(0); SPI_FLASH_CS_H(); return 0; } ssize_t spi_flash_read(int addr, void *buf, size_t len, uint32_t timeout) { 80268b8: b570 push {r4, r5, r6, lr} 80268ba: 4605 mov r5, r0 80268bc: 460c mov r4, r1 ssize_t ret = 0; // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; SPI_FLASH_CS_L(); 80268be: 2005 movs r0, #5 80268c0: 2100 movs r1, #0 *((uint8_t *)buf++) = spi_tx_rx(0); SPI_FLASH_CS_H(); return 0; } ssize_t spi_flash_read(int addr, void *buf, size_t len, uint32_t timeout) { 80268c2: 4616 mov r6, r2 ssize_t ret = 0; // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; SPI_FLASH_CS_L(); 80268c4: f7ff fb34 bl 8025f30 spi_tx_rx(CMD_READ); 80268c8: 2003 movs r0, #3 80268ca: f7ff ffab bl 8026824 send_addr(addr); 80268ce: 4628 mov r0, r5 80268d0: f7ff ffba bl 8026848 *((uint8_t *)buf++) = spi_tx_rx(0); SPI_FLASH_CS_H(); return 0; } ssize_t spi_flash_read(int addr, void *buf, size_t len, uint32_t timeout) { 80268d4: 19a6 adds r6, r4, r6 // return ret; SPI_FLASH_CS_L(); spi_tx_rx(CMD_READ); send_addr(addr); while (len--) 80268d6: e004 b.n 80268e2 *((uint8_t *)buf++) = spi_tx_rx(0); 80268d8: 2000 movs r0, #0 80268da: f7ff ffa3 bl 8026824 80268de: f804 0b01 strb.w r0, [r4], #1 // return ret; SPI_FLASH_CS_L(); spi_tx_rx(CMD_READ); send_addr(addr); while (len--) 80268e2: 42b4 cmp r4, r6 80268e4: d1f8 bne.n 80268d8 *((uint8_t *)buf++) = spi_tx_rx(0); SPI_FLASH_CS_H(); 80268e6: 2005 movs r0, #5 80268e8: 2101 movs r1, #1 80268ea: f7ff fb21 bl 8025f30 // tn_mutex_unlock(&spi_mutex); return len; } 80268ee: f04f 30ff mov.w r0, #4294967295 80268f2: bd70 pop {r4, r5, r6, pc} 080268f4 : // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; // don't allow page wrapping ssize_t ret = 0; if ((addr & 0xFF) + len > 0xFF) 80268f4: b2c3 uxtb r3, r0 return len; } #define TIMEOUT 10000 uint16_t spi_flash_pp(int addr, const void *buf, size_t len, uint32_t timeout) { 80268f6: b570 push {r4, r5, r6, lr} 80268f8: 4615 mov r5, r2 // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; // don't allow page wrapping ssize_t ret = 0; if ((addr & 0xFF) + len > 0xFF) 80268fa: 18d2 adds r2, r2, r3 80268fc: 2aff cmp r2, #255 ; 0xff len = 0x100 - (addr & 0xFF); 80268fe: bf88 it hi 8026900: f5c3 7580 rsbhi r5, r3, #256 ; 0x100 return len; } #define TIMEOUT 10000 uint16_t spi_flash_pp(int addr, const void *buf, size_t len, uint32_t timeout) { 8026904: 4604 mov r4, r0 8026906: 460e mov r6, r1 ssize_t ret = 0; if ((addr & 0xFF) + len > 0xFF) len = 0x100 - (addr & 0xFF); ret = len; SPI_FLASH_CS_L(); 8026908: 2005 movs r0, #5 802690a: 2100 movs r1, #0 802690c: f7ff fb10 bl 8025f30 spi_tx_rx(CMD_WREN); 8026910: 2006 movs r0, #6 8026912: f7ff ff87 bl 8026824 SPI_FLASH_CS_H(); 8026916: 2005 movs r0, #5 8026918: 2101 movs r1, #1 802691a: f7ff fb09 bl 8025f30 wait_write_enable(); 802691e: f7ff ffa2 bl 8026866 SPI_FLASH_CS_L(); 8026922: 2100 movs r1, #0 8026924: 2005 movs r0, #5 8026926: f7ff fb03 bl 8025f30 spi_tx_rx(CMD_PP); 802692a: 2002 movs r0, #2 802692c: f7ff ff7a bl 8026824 send_addr(addr); 8026930: 4620 mov r0, r4 8026932: f7ff ff89 bl 8026848 while (len--) 8026936: 2400 movs r4, #0 8026938: e003 b.n 8026942 spi_tx_rx(*((uint8_t *)buf++)); 802693a: 5d30 ldrb r0, [r6, r4] 802693c: f7ff ff72 bl 8026824 8026940: 3401 adds r4, #1 wait_write_enable(); SPI_FLASH_CS_L(); spi_tx_rx(CMD_PP); send_addr(addr); while (len--) 8026942: 42ac cmp r4, r5 8026944: d1f9 bne.n 802693a spi_tx_rx(*((uint8_t *)buf++)); SPI_FLASH_CS_H(); 8026946: 2005 movs r0, #5 8026948: 2101 movs r1, #1 802694a: f7ff faf1 bl 8025f30 wait_write_end(); 802694e: f7ff ffa0 bl 8026892 // tn_mutex_unlock(&spi_mutex); return ret; } 8026952: b2a0 uxth r0, r4 8026954: bd70 pop {r4, r5, r6, pc} 08026956 : ssize_t spi_flash_write(int addr, const void *buf, size_t len, uint32_t timeout) { 8026956: b5f8 push {r3, r4, r5, r6, r7, lr} 8026958: 4607 mov r7, r0 802695a: 460e mov r6, r1 802695c: 4615 mov r5, r2 int ret = 0, offset = 0; 802695e: 2400 movs r4, #0 do { ret = spi_flash_pp(addr + offset, buf + offset, len - offset, 0); 8026960: 1938 adds r0, r7, r4 8026962: 1931 adds r1, r6, r4 8026964: 1b2a subs r2, r5, r4 8026966: 2300 movs r3, #0 8026968: f7ff ffc4 bl 80268f4 offset += ret; 802696c: 1824 adds r4, r4, r0 } while (len - offset); 802696e: 42a5 cmp r5, r4 8026970: d1f6 bne.n 8026960 return 0; } 8026972: 2000 movs r0, #0 8026974: bdf8 pop {r3, r4, r5, r6, r7, pc} 08026976 : wait_write_end(); return 0; } int spi_flash_erase_sector(int addr, uint32_t timeout) { 8026976: b510 push {r4, lr} int ret = 0; // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; SPI_FLASH_CS_L(); 8026978: 2100 movs r1, #0 wait_write_end(); return 0; } int spi_flash_erase_sector(int addr, uint32_t timeout) { 802697a: 4604 mov r4, r0 int ret = 0; // ret = tn_mutex_lock(&spi_mutex, timeout); // if (ret != TERR_NO_ERR) // return ret; SPI_FLASH_CS_L(); 802697c: 2005 movs r0, #5 802697e: f7ff fad7 bl 8025f30 spi_tx_rx(CMD_WREN); 8026982: 2006 movs r0, #6 8026984: f7ff ff4e bl 8026824 SPI_FLASH_CS_H(); 8026988: 2005 movs r0, #5 802698a: 2101 movs r1, #1 802698c: f7ff fad0 bl 8025f30 wait_write_enable(); 8026990: f7ff ff69 bl 8026866 SPI_FLASH_CS_L(); 8026994: 2100 movs r1, #0 8026996: 2005 movs r0, #5 8026998: f7ff faca bl 8025f30 spi_tx_rx(CMD_SE); 802699c: 2020 movs r0, #32 802699e: f7ff ff41 bl 8026824 send_addr(addr); 80269a2: 4620 mov r0, r4 80269a4: f7ff ff50 bl 8026848 SPI_FLASH_CS_H(); 80269a8: 2005 movs r0, #5 80269aa: 2101 movs r1, #1 80269ac: f7ff fac0 bl 8025f30 wait_write_end(); 80269b0: f7ff ff6f bl 8026892 // tn_mutex_unlock(&spi_mutex); return 0; } 80269b4: 2000 movs r0, #0 80269b6: bd10 pop {r4, pc} 080269b8 : bool spi_flash_init(void) { uint32_t i, ptable, bitsize = 0; uint8_t tmp[4]; spi_flash_desc.present = false; 80269b8: 4b28 ldr r3, [pc, #160] ; (8026a5c ) // tn_mutex_unlock(&spi_mutex); return 0; } bool spi_flash_init(void) { 80269ba: b513 push {r0, r1, r4, lr} uint32_t i, ptable, bitsize = 0; uint8_t tmp[4]; spi_flash_desc.present = false; 80269bc: 2400 movs r4, #0 80269be: 701c strb r4, [r3, #0] static void spi_init_(void) { // tn_mutex_create(&spi_mutex, TN_MUTEX_ATTR_INHERIT, 0); //tn_sem_create(&xact.ready, 0, 1); RCC->APB1ENR |= RCC_APB1ENR_SPI2EN; 80269c0: 4b27 ldr r3, [pc, #156] ; (8026a60 ) 80269c2: 6c1a ldr r2, [r3, #64] ; 0x40 80269c4: f442 4280 orr.w r2, r2, #16384 ; 0x4000 80269c8: 641a str r2, [r3, #64] ; 0x40 RCC->APB1RSTR |= RCC_APB1RSTR_SPI2RST; 80269ca: 6a1a ldr r2, [r3, #32] 80269cc: f442 4200 orr.w r2, r2, #32768 ; 0x8000 80269d0: 621a str r2, [r3, #32] RCC->APB1RSTR &= ~RCC_APB1RSTR_SPI2RST; 80269d2: 6a1a ldr r2, [r3, #32] 80269d4: f422 4200 bic.w r2, r2, #32768 ; 0x8000 80269d8: 621a str r2, [r3, #32] SPI2->CR1 &= ~SPI_CR1_SPE; 80269da: f5a3 3300 sub.w r3, r3, #131072 ; 0x20000 spi_tx_rx((addr >> 8) & 0xFF); spi_tx_rx(addr & 0xFF); } static int spi_flash_read_sfdp(int addr, void *buf, size_t len) { SPI_FLASH_CS_L(); 80269de: 4621 mov r1, r4 RCC->APB1ENR |= RCC_APB1ENR_SPI2EN; RCC->APB1RSTR |= RCC_APB1RSTR_SPI2RST; RCC->APB1RSTR &= ~RCC_APB1RSTR_SPI2RST; SPI2->CR1 &= ~SPI_CR1_SPE; 80269e0: 881a ldrh r2, [r3, #0] 80269e2: f022 0240 bic.w r2, r2, #64 ; 0x40 80269e6: 0412 lsls r2, r2, #16 80269e8: 0c12 lsrs r2, r2, #16 80269ea: 801a strh r2, [r3, #0] //SPI2->CR1 = SPI_CR1_MSTR | SPI_CR1_BR_1 | SPI_CR1_SSM | SPI_CR1_SSI; SPI2->CR1 = SPI_CR1_MSTR | SPI_CR1_SSM | SPI_CR1_SSI; 80269ec: f44f 7241 mov.w r2, #772 ; 0x304 80269f0: 801a strh r2, [r3, #0] SPI2->CR2 = 0;//SPI_CR2_SSOE; 80269f2: 809c strh r4, [r3, #4] SPI2->CR1 |= SPI_CR1_SPE; 80269f4: 881a ldrh r2, [r3, #0] 80269f6: b292 uxth r2, r2 80269f8: f042 0240 orr.w r2, r2, #64 ; 0x40 80269fc: 801a strh r2, [r3, #0] spi_tx_rx((addr >> 8) & 0xFF); spi_tx_rx(addr & 0xFF); } static int spi_flash_read_sfdp(int addr, void *buf, size_t len) { SPI_FLASH_CS_L(); 80269fe: 2005 movs r0, #5 8026a00: f7ff fa96 bl 8025f30 spi_tx_rx(CMD_RDSFDP); 8026a04: 205a movs r0, #90 ; 0x5a 8026a06: f7ff ff0d bl 8026824 send_addr(addr); 8026a0a: 4620 mov r0, r4 8026a0c: f7ff ff1c bl 8026848 spi_tx_rx(0); 8026a10: 4620 mov r0, r4 8026a12: f7ff ff07 bl 8026824 while (len--) *((uint8_t *)buf++) = spi_tx_rx(0); 8026a16: 2000 movs r0, #0 8026a18: f7ff ff04 bl 8026824 8026a1c: ab01 add r3, sp, #4 8026a1e: 5518 strb r0, [r3, r4] 8026a20: 3401 adds r4, #1 static int spi_flash_read_sfdp(int addr, void *buf, size_t len) { SPI_FLASH_CS_L(); spi_tx_rx(CMD_RDSFDP); send_addr(addr); spi_tx_rx(0); while (len--) 8026a22: 2c04 cmp r4, #4 8026a24: d1f7 bne.n 8026a16 *((uint8_t *)buf++) = spi_tx_rx(0); SPI_FLASH_CS_H(); 8026a26: 2005 movs r0, #5 8026a28: 2101 movs r1, #1 8026a2a: f7ff fa81 bl 8025f30 spi_init_(); // check SFDP magic spi_flash_read_sfdp(0, tmp, 4); if (!(tmp[0] == 0x53 && tmp[1] == 0x46 && 8026a2e: f89d 3004 ldrb.w r3, [sp, #4] 8026a32: 2b53 cmp r3, #83 ; 0x53 8026a34: d110 bne.n 8026a58 8026a36: f89d 3005 ldrb.w r3, [sp, #5] 8026a3a: 2b46 cmp r3, #70 ; 0x46 8026a3c: d10c bne.n 8026a58 8026a3e: f89d 3006 ldrb.w r3, [sp, #6] 8026a42: 2b44 cmp r3, #68 ; 0x44 8026a44: d108 bne.n 8026a58 8026a46: f89d 0007 ldrb.w r0, [sp, #7] 8026a4a: f1b0 0c50 subs.w ip, r0, #80 ; 0x50 8026a4e: f1dc 0000 rsbs r0, ip, #0 8026a52: eb50 000c adcs.w r0, r0, ip 8026a56: e000 b.n 8026a5a tmp[2] == 0x44 && tmp[3] == 0x50)) return 0; 8026a58: 2000 movs r0, #0 if (!spi_flash_desc.sector_size) return; spi_flash_desc.present = true; */ } 8026a5a: bd1c pop {r2, r3, r4, pc} 8026a5c: 2000e54c .word 0x2000e54c 8026a60: 40023800 .word 0x40023800 08026a64 : #define bufsize2 (countof(txbuf2)-1) uint8_t rxbuf1[bufsize1] = {0}; uint8_t rxbuf2[bufsize2] = {0}; void spi_flash_test(void) { 8026a64: b510 push {r4, lr} if (!spi_flash_init()) 8026a66: f7ff ffa7 bl 80269b8 8026a6a: 2800 cmp r0, #0 8026a6c: d04a beq.n 8026b04 return; int ret = 0, addr = 0, offset = 0; spi_flash_read(0, rxbuf1, bufsize1, 0); 8026a6e: 2000 movs r0, #0 8026a70: f640 62f9 movw r2, #3833 ; 0xef9 8026a74: 4603 mov r3, r0 8026a76: 4924 ldr r1, [pc, #144] ; (8026b08 ) 8026a78: f7ff ff1e bl 80268b8 spi_flash_erase_sector(0,0); 8026a7c: 2000 movs r0, #0 8026a7e: 4601 mov r1, r0 8026a80: f7ff ff79 bl 8026976 spi_flash_read(0, rxbuf1, bufsize1, 0); 8026a84: 2000 movs r0, #0 8026a86: 4920 ldr r1, [pc, #128] ; (8026b08 ) 8026a88: f640 62f9 movw r2, #3833 ; 0xef9 8026a8c: 4603 mov r3, r0 8026a8e: f7ff ff13 bl 80268b8 spi_flash_write(addr, txbuf1, bufsize1, 0); 8026a92: 2000 movs r0, #0 8026a94: 4603 mov r3, r0 8026a96: 491d ldr r1, [pc, #116] ; (8026b0c ) 8026a98: f640 62f9 movw r2, #3833 ; 0xef9 8026a9c: f7ff ff5b bl 8026956 memset(rxbuf1, 0, bufsize1); 8026aa0: 2100 movs r1, #0 8026aa2: f640 62f9 movw r2, #3833 ; 0xef9 8026aa6: 4818 ldr r0, [pc, #96] ; (8026b08 ) 8026aa8: f7fb f80a bl 8021ac0 spi_flash_read(0, rxbuf1, bufsize1, 0); 8026aac: 2000 movs r0, #0 8026aae: 4916 ldr r1, [pc, #88] ; (8026b08 ) 8026ab0: f640 62f9 movw r2, #3833 ; 0xef9 8026ab4: 4603 mov r3, r0 8026ab6: f7ff feff bl 80268b8 if (memcmp(txbuf1, rxbuf1, bufsize1) != 0) 8026aba: 4814 ldr r0, [pc, #80] ; (8026b0c ) 8026abc: 4912 ldr r1, [pc, #72] ; (8026b08 ) 8026abe: f640 62f9 movw r2, #3833 ; 0xef9 8026ac2: f7fa ff11 bl 80218e8 8026ac6: 4604 mov r4, r0 8026ac8: b9e0 cbnz r0, 8026b04 return; spi_flash_erase_sector(0,0); 8026aca: 4601 mov r1, r0 8026acc: f7ff ff53 bl 8026976 spi_flash_read(0, rxbuf1, bufsize1, 0); 8026ad0: 4623 mov r3, r4 8026ad2: 4620 mov r0, r4 8026ad4: 490c ldr r1, [pc, #48] ; (8026b08 ) 8026ad6: f640 62f9 movw r2, #3833 ; 0xef9 8026ada: f7ff feed bl 80268b8 spi_flash_write(0, txbuf2, bufsize2, 0); 8026ade: 4623 mov r3, r4 8026ae0: 224e movs r2, #78 ; 0x4e 8026ae2: 4620 mov r0, r4 8026ae4: 490a ldr r1, [pc, #40] ; (8026b10 ) 8026ae6: f7ff ff36 bl 8026956 memset(rxbuf2, 0, bufsize2); 8026aea: 4621 mov r1, r4 8026aec: 224e movs r2, #78 ; 0x4e 8026aee: 4809 ldr r0, [pc, #36] ; (8026b14 ) 8026af0: f7fa ffe6 bl 8021ac0 spi_flash_read(0, rxbuf2, bufsize2, 0); 8026af4: 4907 ldr r1, [pc, #28] ; (8026b14 ) 8026af6: 4620 mov r0, r4 8026af8: 224e movs r2, #78 ; 0x4e 8026afa: 4623 mov r3, r4 spi_flash_desc.sector_size, spi_flash_desc.sector_size * spi_flash_desc.sector_count); return 0; */ } 8026afc: e8bd 4010 ldmia.w sp!, {r4, lr} spi_flash_read(0, rxbuf1, bufsize1, 0); spi_flash_write(0, txbuf2, bufsize2, 0); memset(rxbuf2, 0, bufsize2); spi_flash_read(0, rxbuf2, bufsize2, 0); 8026b00: f7ff beda b.w 80268b8 8026b04: bd10 pop {r4, pc} 8026b06: bf00 nop 8026b08: 20001954 .word 0x20001954 8026b0c: 200006af .word 0x200006af 8026b10: 20000660 .word 0x20000660 8026b14: 2000284d .word 0x2000284d 08026b18 : \param [in] SubPriority Subpriority value (starting from 0). \return Encoded priority. Value can be used in the function \ref NVIC_SetPriority(). */ __STATIC_INLINE uint32_t NVIC_EncodePriority (uint32_t PriorityGroup, uint32_t PreemptPriority, uint32_t SubPriority) { uint32_t PriorityGroupTmp = (PriorityGroup & 0x07); /* only values 0..7 are used */ 8026b18: f000 0007 and.w r0, r0, #7 uint32_t PreemptPriorityBits; uint32_t SubPriorityBits; PreemptPriorityBits = ((7 - PriorityGroupTmp) > __NVIC_PRIO_BITS) ? __NVIC_PRIO_BITS : 7 - PriorityGroupTmp; 8026b1c: f1c0 0307 rsb r3, r0, #7 SubPriorityBits = ((PriorityGroupTmp + __NVIC_PRIO_BITS) < 7) ? 0 : PriorityGroupTmp - 7 + __NVIC_PRIO_BITS; 8026b20: 1d02 adds r2, r0, #4 { uint32_t PriorityGroupTmp = (PriorityGroup & 0x07); /* only values 0..7 are used */ uint32_t PreemptPriorityBits; uint32_t SubPriorityBits; PreemptPriorityBits = ((7 - PriorityGroupTmp) > __NVIC_PRIO_BITS) ? __NVIC_PRIO_BITS : 7 - PriorityGroupTmp; 8026b22: 2b04 cmp r3, #4 8026b24: bf28 it cs 8026b26: 2304 movcs r3, #4 SubPriorityBits = ((PriorityGroupTmp + __NVIC_PRIO_BITS) < 7) ? 0 : PriorityGroupTmp - 7 + __NVIC_PRIO_BITS; 8026b28: 2a06 cmp r2, #6 8026b2a: d901 bls.n 8026b30 8026b2c: 3803 subs r0, #3 8026b2e: e000 b.n 8026b32 8026b30: 2000 movs r0, #0 return ( ((PreemptPriority & ((1 << (PreemptPriorityBits)) - 1)) << SubPriorityBits) | 8026b32: 2201 movs r2, #1 8026b34: fa02 f303 lsl.w r3, r2, r3 8026b38: 3b01 subs r3, #1 8026b3a: f003 0305 and.w r3, r3, #5 ((SubPriority & ((1 << (SubPriorityBits )) - 1))) ); } 8026b3e: fa03 f000 lsl.w r0, r3, r0 8026b42: 4770 bx lr 08026b44 : uint32_t ups_tx_fifo[UPS_RBUF_SIZE]; SemaphoreHandle_t xSem_rx_buf; USART_InitTypeDef USART_InitStructure; void uart_hw_init(USART_TypeDef *uart, uint32_t baud, uint16_t wordlen, uint16_t parity, uint16_t stop) { 8026b44: b570 push {r4, r5, r6, lr} if (wordlen == 8) wordlen_tmp = USART_WordLength_8b; if (wordlen == 9) wordlen_tmp = USART_WordLength_9b; USART_InitStructure.USART_BaudRate = baud; 8026b46: 4d34 ldr r5, [pc, #208] ; (8026c18 ) uint32_t ups_tx_fifo[UPS_RBUF_SIZE]; SemaphoreHandle_t xSem_rx_buf; USART_InitTypeDef USART_InitStructure; void uart_hw_init(USART_TypeDef *uart, uint32_t baud, uint16_t wordlen, uint16_t parity, uint16_t stop) { 8026b48: f8bd 6010 ldrh.w r6, [sp, #16] wordlen_tmp = USART_WordLength_9b; USART_InitStructure.USART_BaudRate = baud; USART_InitStructure.USART_WordLength = wordlen_tmp; USART_InitStructure.USART_StopBits = stop; USART_InitStructure.USART_Parity = parity; 8026b4c: 812b strh r3, [r5, #8] void uart_hw_init(USART_TypeDef *uart, uint32_t baud, uint16_t wordlen, uint16_t parity, uint16_t stop) { uint16_t wordlen_tmp; if (wordlen == 8) wordlen_tmp = USART_WordLength_8b; if (wordlen == 9) 8026b4e: 2a09 cmp r2, #9 8026b50: bf0c ite eq 8026b52: f44f 5280 moveq.w r2, #4096 ; 0x1000 8026b56: 2200 movne r2, #0 USART_InitStructure.USART_BaudRate = baud; USART_InitStructure.USART_WordLength = wordlen_tmp; USART_InitStructure.USART_StopBits = stop; USART_InitStructure.USART_Parity = parity; USART_InitStructure.USART_HardwareFlowControl = USART_HardwareFlowControl_None; USART_InitStructure.USART_Mode = USART_Mode_Rx | USART_Mode_Tx; 8026b58: 230c movs r3, #12 if (wordlen == 9) wordlen_tmp = USART_WordLength_9b; USART_InitStructure.USART_BaudRate = baud; USART_InitStructure.USART_WordLength = wordlen_tmp; USART_InitStructure.USART_StopBits = stop; 8026b5a: 80ee strh r6, [r5, #6] USART_InitStructure.USART_Parity = parity; USART_InitStructure.USART_HardwareFlowControl = USART_HardwareFlowControl_None; 8026b5c: 2600 movs r6, #0 uint32_t ups_tx_fifo[UPS_RBUF_SIZE]; SemaphoreHandle_t xSem_rx_buf; USART_InitTypeDef USART_InitStructure; void uart_hw_init(USART_TypeDef *uart, uint32_t baud, uint16_t wordlen, uint16_t parity, uint16_t stop) { 8026b5e: 4604 mov r4, r0 USART_InitStructure.USART_BaudRate = baud; USART_InitStructure.USART_WordLength = wordlen_tmp; USART_InitStructure.USART_StopBits = stop; USART_InitStructure.USART_Parity = parity; USART_InitStructure.USART_HardwareFlowControl = USART_HardwareFlowControl_None; USART_InitStructure.USART_Mode = USART_Mode_Rx | USART_Mode_Tx; 8026b60: 816b strh r3, [r5, #10] if (wordlen == 8) wordlen_tmp = USART_WordLength_8b; if (wordlen == 9) wordlen_tmp = USART_WordLength_9b; USART_InitStructure.USART_BaudRate = baud; 8026b62: 6029 str r1, [r5, #0] USART_InitStructure.USART_WordLength = wordlen_tmp; 8026b64: 80aa strh r2, [r5, #4] USART_InitStructure.USART_StopBits = stop; USART_InitStructure.USART_Parity = parity; USART_InitStructure.USART_HardwareFlowControl = USART_HardwareFlowControl_None; 8026b66: 81ae strh r6, [r5, #12] USART_InitStructure.USART_Mode = USART_Mode_Rx | USART_Mode_Tx; USART_DeInit(uart); 8026b68: f7ff f812 bl 8025b90 if (uart == USART1) { 8026b6c: 4b2b ldr r3, [pc, #172] ; (8026c1c ) 8026b6e: 429c cmp r4, r3 8026b70: d111 bne.n 8026b96 RCC->APB2ENR |= RCC_APB2Periph_USART1; 8026b72: f503 3394 add.w r3, r3, #75776 ; 0x12800 8026b76: 6c5a ldr r2, [r3, #68] ; 0x44 8026b78: f042 0210 orr.w r2, r2, #16 8026b7c: 645a str r2, [r3, #68] ; 0x44 \return Priority grouping field (SCB->AIRCR [10:8] PRIGROUP field). */ __STATIC_INLINE uint32_t NVIC_GetPriorityGrouping(void) { return ((SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) >> SCB_AIRCR_PRIGROUP_Pos); /* read priority grouping field */ 8026b7e: 4b28 ldr r3, [pc, #160] ; (8026c20 ) 8026b80: 68d8 ldr r0, [r3, #12] NVIC_SetPriority(USART1_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 0x05, 0)); 8026b82: f3c0 2002 ubfx r0, r0, #8, #3 8026b86: f7ff ffc7 bl 8026b18 __STATIC_INLINE void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority) { if(IRQn < 0) { SCB->SHP[((uint32_t)(IRQn) & 0xF)-4] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for Cortex-M System Interrupts */ else { NVIC->IP[(uint32_t)(IRQn)] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for device specific Interrupts */ 8026b8a: 4b26 ldr r3, [pc, #152] ; (8026c24 ) 8026b8c: 0100 lsls r0, r0, #4 8026b8e: f883 0325 strb.w r0, [r3, #805] ; 0x325 \param [in] IRQn External interrupt number. Value cannot be negative. */ __STATIC_INLINE void NVIC_EnableIRQ(IRQn_Type IRQn) { /* NVIC->ISER[((uint32_t)(IRQn) >> 5)] = (1 << ((uint32_t)(IRQn) & 0x1F)); enable interrupt */ NVIC->ISER[(uint32_t)((int32_t)IRQn) >> 5] = (uint32_t)(1 << ((uint32_t)((int32_t)IRQn) & (uint32_t)0x1F)); /* enable interrupt */ 8026b92: 2220 movs r2, #32 8026b94: e028 b.n 8026be8 USART_Cmd(USART1, ENABLE); USART_ITConfig(USART1, USART_IT_RXNE, ENABLE); USART_ITConfig(USART1, USART_IT_TXE, DISABLE); } if (uart == USART2) { 8026b96: 4b24 ldr r3, [pc, #144] ; (8026c28 ) 8026b98: 429c cmp r4, r3 8026b9a: d111 bne.n 8026bc0 RCC->APB1ENR |= RCC_APB1Periph_USART2; 8026b9c: f503 33fa add.w r3, r3, #128000 ; 0x1f400 8026ba0: 6c1a ldr r2, [r3, #64] ; 0x40 8026ba2: f442 3200 orr.w r2, r2, #131072 ; 0x20000 8026ba6: 641a str r2, [r3, #64] ; 0x40 \return Priority grouping field (SCB->AIRCR [10:8] PRIGROUP field). */ __STATIC_INLINE uint32_t NVIC_GetPriorityGrouping(void) { return ((SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) >> SCB_AIRCR_PRIGROUP_Pos); /* read priority grouping field */ 8026ba8: 4b1d ldr r3, [pc, #116] ; (8026c20 ) 8026baa: 68d8 ldr r0, [r3, #12] NVIC_SetPriority(USART2_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 0x05, 0)); 8026bac: f3c0 2002 ubfx r0, r0, #8, #3 8026bb0: f7ff ffb2 bl 8026b18 __STATIC_INLINE void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority) { if(IRQn < 0) { SCB->SHP[((uint32_t)(IRQn) & 0xF)-4] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for Cortex-M System Interrupts */ else { NVIC->IP[(uint32_t)(IRQn)] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for device specific Interrupts */ 8026bb4: 4b1b ldr r3, [pc, #108] ; (8026c24 ) 8026bb6: 0100 lsls r0, r0, #4 8026bb8: f883 0326 strb.w r0, [r3, #806] ; 0x326 \param [in] IRQn External interrupt number. Value cannot be negative. */ __STATIC_INLINE void NVIC_EnableIRQ(IRQn_Type IRQn) { /* NVIC->ISER[((uint32_t)(IRQn) >> 5)] = (1 << ((uint32_t)(IRQn) & 0x1F)); enable interrupt */ NVIC->ISER[(uint32_t)((int32_t)IRQn) >> 5] = (uint32_t)(1 << ((uint32_t)((int32_t)IRQn) & (uint32_t)0x1F)); /* enable interrupt */ 8026bbc: 2240 movs r2, #64 ; 0x40 8026bbe: e013 b.n 8026be8 USART_Cmd(USART2, ENABLE); USART_ITConfig(USART2, USART_IT_RXNE, ENABLE); USART_ITConfig(USART2, USART_IT_TXE, DISABLE); } if (uart == USART3) { 8026bc0: 4b1a ldr r3, [pc, #104] ; (8026c2c ) 8026bc2: 429c cmp r4, r3 8026bc4: d127 bne.n 8026c16 RCC->APB1ENR |= RCC_APB1Periph_USART3; 8026bc6: f503 33f8 add.w r3, r3, #126976 ; 0x1f000 8026bca: 6c1a ldr r2, [r3, #64] ; 0x40 8026bcc: f442 2280 orr.w r2, r2, #262144 ; 0x40000 8026bd0: 641a str r2, [r3, #64] ; 0x40 \return Priority grouping field (SCB->AIRCR [10:8] PRIGROUP field). */ __STATIC_INLINE uint32_t NVIC_GetPriorityGrouping(void) { return ((SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) >> SCB_AIRCR_PRIGROUP_Pos); /* read priority grouping field */ 8026bd2: 4b13 ldr r3, [pc, #76] ; (8026c20 ) 8026bd4: 68d8 ldr r0, [r3, #12] NVIC_SetPriority(USART3_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 0x05, 0)); 8026bd6: f3c0 2002 ubfx r0, r0, #8, #3 8026bda: f7ff ff9d bl 8026b18 __STATIC_INLINE void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority) { if(IRQn < 0) { SCB->SHP[((uint32_t)(IRQn) & 0xF)-4] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for Cortex-M System Interrupts */ else { NVIC->IP[(uint32_t)(IRQn)] = ((priority << (8 - __NVIC_PRIO_BITS)) & 0xff); } /* set Priority for device specific Interrupts */ 8026bde: 4b11 ldr r3, [pc, #68] ; (8026c24 ) 8026be0: 0100 lsls r0, r0, #4 8026be2: f883 0327 strb.w r0, [r3, #807] ; 0x327 \param [in] IRQn External interrupt number. Value cannot be negative. */ __STATIC_INLINE void NVIC_EnableIRQ(IRQn_Type IRQn) { /* NVIC->ISER[((uint32_t)(IRQn) >> 5)] = (1 << ((uint32_t)(IRQn) & 0x1F)); enable interrupt */ NVIC->ISER[(uint32_t)((int32_t)IRQn) >> 5] = (uint32_t)(1 << ((uint32_t)((int32_t)IRQn) & (uint32_t)0x1F)); /* enable interrupt */ 8026be6: 2280 movs r2, #128 ; 0x80 8026be8: 605a str r2, [r3, #4] NVIC_EnableIRQ(USART3_IRQn); USART_Init(USART3, &USART_InitStructure); 8026bea: 4620 mov r0, r4 8026bec: 4629 mov r1, r5 8026bee: f7ff f823 bl 8025c38 USART_Cmd(USART3, ENABLE); 8026bf2: 4620 mov r0, r4 8026bf4: 2101 movs r1, #1 8026bf6: f7ff f879 bl 8025cec USART_ITConfig(USART3, USART_IT_RXNE, ENABLE); 8026bfa: 4620 mov r0, r4 8026bfc: 2201 movs r2, #1 8026bfe: f240 5125 movw r1, #1317 ; 0x525 8026c02: f7ff f87f bl 8025d04 USART_ITConfig(USART3, USART_IT_TXE, DISABLE); 8026c06: 4620 mov r0, r4 8026c08: f240 7127 movw r1, #1831 ; 0x727 8026c0c: 4632 mov r2, r6 } } 8026c0e: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} NVIC_SetPriority(USART3_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 0x05, 0)); NVIC_EnableIRQ(USART3_IRQn); USART_Init(USART3, &USART_InitStructure); USART_Cmd(USART3, ENABLE); USART_ITConfig(USART3, USART_IT_RXNE, ENABLE); USART_ITConfig(USART3, USART_IT_TXE, DISABLE); 8026c12: f7ff b877 b.w 8025d04 8026c16: bd70 pop {r4, r5, r6, pc} 8026c18: 2000e898 .word 0x2000e898 8026c1c: 40011000 .word 0x40011000 8026c20: e000ed00 .word 0xe000ed00 8026c24: e000e100 .word 0xe000e100 8026c28: 40004400 .word 0x40004400 8026c2c: 40004800 .word 0x40004800 08026c30 : } } void InitUSART(void) { 8026c30: b507 push {r0, r1, r2, lr} xSem_rx_buf = xSemaphoreCreateCounting( UPS_RBUF_SIZE, 0 ); 8026c32: 2100 movs r1, #0 8026c34: 2064 movs r0, #100 ; 0x64 8026c36: f002 f943 bl 8028ec0 8026c3a: 4b0a ldr r3, [pc, #40] ; (8026c64 ) rbuf32_init(&ups_tx_rbuf, ups_tx_fifo, UPS_RBUF_SIZE); 8026c3c: 490a ldr r1, [pc, #40] ; (8026c68 ) USART_ITConfig(USART3, USART_IT_TXE, DISABLE); } } void InitUSART(void) { xSem_rx_buf = xSemaphoreCreateCounting( UPS_RBUF_SIZE, 0 ); 8026c3e: 6018 str r0, [r3, #0] rbuf32_init(&ups_tx_rbuf, ups_tx_fifo, UPS_RBUF_SIZE); 8026c40: 2264 movs r2, #100 ; 0x64 8026c42: 480a ldr r0, [pc, #40] ; (8026c6c ) 8026c44: f001 ffe8 bl 8028c18 rbuf32_init(&ups_rx_rbuf, ups_rx_fifo, UPS_RBUF_SIZE); 8026c48: 2264 movs r2, #100 ; 0x64 8026c4a: 4809 ldr r0, [pc, #36] ; (8026c70 ) 8026c4c: 4909 ldr r1, [pc, #36] ; (8026c74 ) 8026c4e: f001 ffe3 bl 8028c18 uart_hw_init(UPS_USART, UPS_USART_BAUD, UPS_USART_WORD_LEN, UPS_USART_PARITY, UPS_USART_STOP_BIT); 8026c52: 2300 movs r3, #0 8026c54: 9300 str r3, [sp, #0] 8026c56: 4808 ldr r0, [pc, #32] ; (8026c78 ) 8026c58: f44f 6116 mov.w r1, #2400 ; 0x960 8026c5c: 2208 movs r2, #8 8026c5e: f7ff ff71 bl 8026b44 } 8026c62: bd0e pop {r1, r2, r3, pc} 8026c64: 2000e8a8 .word 0x2000e8a8 8026c68: 2000e568 .word 0x2000e568 8026c6c: 2000e888 .word 0x2000e888 8026c70: 2000e558 .word 0x2000e558 8026c74: 2000e6f8 .word 0x2000e6f8 8026c78: 40004400 .word 0x40004400 08026c7c : } int ups_send_block(void *data, uint8_t len) { int i = 0; uint32_t s_temp = 0; UPS_USART->CR1 &= ~USART_CR1_TXEIE; 8026c7c: 4a0f ldr r2, [pc, #60] ; (8026cbc ) 8026c7e: 8993 ldrh r3, [r2, #12] 8026c80: f023 0380 bic.w r3, r3, #128 ; 0x80 8026c84: 041b lsls r3, r3, #16 8026c86: 0c1b lsrs r3, r3, #16 rbuf32_put(&ups_tx_rbuf, (uint32_t)(byte)); } UPS_USART->CR1 |= USART_CR1_TXEIE; } int ups_send_block(void *data, uint8_t len) { 8026c88: b570 push {r4, r5, r6, lr} 8026c8a: 4606 mov r6, r0 8026c8c: 460d mov r5, r1 int i = 0; uint32_t s_temp = 0; UPS_USART->CR1 &= ~USART_CR1_TXEIE; 8026c8e: 8193 strh r3, [r2, #12] } UPS_USART->CR1 |= USART_CR1_TXEIE; } int ups_send_block(void *data, uint8_t len) { int i = 0; 8026c90: 2400 movs r4, #0 uint32_t s_temp = 0; UPS_USART->CR1 &= ~USART_CR1_TXEIE; //DBG printf("STOP \r\n"); while (i < len) { 8026c92: e008 b.n 8026ca6 if (!rbuf_isfull(&ups_tx_rbuf)) { 8026c94: 480a ldr r0, [pc, #40] ; (8026cc0 ) 8026c96: f001 ffc5 bl 8028c24 8026c9a: b930 cbnz r0, 8026caa s_temp = ((uint8_t *)data)[i++]; 8026c9c: 5d31 ldrb r1, [r6, r4] rbuf32_put(&ups_tx_rbuf, s_temp); 8026c9e: 4808 ldr r0, [pc, #32] ; (8026cc0 ) uint32_t s_temp = 0; UPS_USART->CR1 &= ~USART_CR1_TXEIE; //DBG printf("STOP \r\n"); while (i < len) { if (!rbuf_isfull(&ups_tx_rbuf)) { s_temp = ((uint8_t *)data)[i++]; 8026ca0: 3401 adds r4, #1 rbuf32_put(&ups_tx_rbuf, s_temp); 8026ca2: f001 ffe0 bl 8028c66 int ups_send_block(void *data, uint8_t len) { int i = 0; uint32_t s_temp = 0; UPS_USART->CR1 &= ~USART_CR1_TXEIE; //DBG printf("STOP \r\n"); while (i < len) { 8026ca6: 42ac cmp r4, r5 8026ca8: dbf4 blt.n 8026c94 rbuf32_put(&ups_tx_rbuf, s_temp); } else break; } UPS_USART->CR1 |= USART_CR1_TXEIE; 8026caa: 4b04 ldr r3, [pc, #16] ; (8026cbc ) 8026cac: 899a ldrh r2, [r3, #12] 8026cae: b292 uxth r2, r2 8026cb0: f042 0280 orr.w r2, r2, #128 ; 0x80 8026cb4: 819a strh r2, [r3, #12] return i; } 8026cb6: 4620 mov r0, r4 8026cb8: bd70 pop {r4, r5, r6, pc} 8026cba: bf00 nop 8026cbc: 40004400 .word 0x40004400 8026cc0: 2000e888 .word 0x2000e888 08026cc4 : int ups_getchar(unsigned int timeout) { int res; res = xSemaphoreTake( xSem_rx_buf, (TickType_t)timeout ); 8026cc4: 4b09 ldr r3, [pc, #36] ; (8026cec ) } UPS_USART->CR1 |= USART_CR1_TXEIE; return i; } int ups_getchar(unsigned int timeout) { 8026cc6: b507 push {r0, r1, r2, lr} int res; res = xSemaphoreTake( xSem_rx_buf, (TickType_t)timeout ); 8026cc8: 2100 movs r1, #0 } UPS_USART->CR1 |= USART_CR1_TXEIE; return i; } int ups_getchar(unsigned int timeout) { 8026cca: 4602 mov r2, r0 int res; res = xSemaphoreTake( xSem_rx_buf, (TickType_t)timeout ); 8026ccc: 6818 ldr r0, [r3, #0] 8026cce: 460b mov r3, r1 8026cd0: f002 fa4c bl 802916c 8026cd4: 9001 str r0, [sp, #4] if (res == pdFALSE) { 8026cd6: b128 cbz r0, 8026ce4 return -1; } rbuf32_get(&ups_rx_rbuf, &res); 8026cd8: 4805 ldr r0, [pc, #20] ; (8026cf0 ) 8026cda: a901 add r1, sp, #4 8026cdc: f001 ffae bl 8028c3c // DBG printf("STOP \r\n"); // DBG printf("wr: %d 0x%x\r\n", rs485_rx_rbuf.read_index,res); return res; 8026ce0: 9801 ldr r0, [sp, #4] 8026ce2: e001 b.n 8026ce8 int ups_getchar(unsigned int timeout) { int res; res = xSemaphoreTake( xSem_rx_buf, (TickType_t)timeout ); if (res == pdFALSE) { return -1; 8026ce4: f04f 30ff mov.w r0, #4294967295 } rbuf32_get(&ups_rx_rbuf, &res); // DBG printf("STOP \r\n"); // DBG printf("wr: %d 0x%x\r\n", rs485_rx_rbuf.read_index,res); return res; } 8026ce8: bd0e pop {r1, r2, r3, pc} 8026cea: bf00 nop 8026cec: 2000e8a8 .word 0x2000e8a8 8026cf0: 2000e558 .word 0x2000e558 08026cf4 : portYIELD_FROM_ISR(xHigherPriorityTaskWoken); } } void USART1_IRQHandler(void) { 8026cf4: 4770 bx lr 8026cf6: 0000 movs r0, r0 08026cf8 : } void USART2_IRQHandler(void) { 8026cf8: b513 push {r0, r1, r4, lr} inline void rs232_irq_handler(void) { uint32_t c = 0; 8026cfa: 2300 movs r3, #0 8026cfc: 9301 str r3, [sp, #4] static BaseType_t xHigherPriorityTaskWoken = pdFALSE; if ((UPS_USART->SR & USART_SR_ORE)) { 8026cfe: 4b26 ldr r3, [pc, #152] ; (8026d98 ) 8026d00: 881a ldrh r2, [r3, #0] 8026d02: f002 0208 and.w r2, r2, #8 8026d06: b292 uxth r2, r2 8026d08: b112 cbz r2, 8026d10 c = (uint32_t)UPS_USART->DR; 8026d0a: 889b ldrh r3, [r3, #4] 8026d0c: b29b uxth r3, r3 8026d0e: 9301 str r3, [sp, #4] //DBG printf("overrunRS485\r\n"); } if (USART_GetITStatus(UPS_USART, USART_IT_TXE) != RESET) { 8026d10: 4c21 ldr r4, [pc, #132] ; (8026d98 ) 8026d12: f240 7127 movw r1, #1831 ; 0x727 8026d16: 4620 mov r0, r4 8026d18: f7ff f80d bl 8025d36 8026d1c: b1c0 cbz r0, 8026d50 if(rbuf32_get(&ups_tx_rbuf, &c)) { 8026d1e: 481f ldr r0, [pc, #124] ; (8026d9c ) 8026d20: a901 add r1, sp, #4 8026d22: f001 ff8b bl 8028c3c 8026d26: b118 cbz r0, 8026d30 UPS_USART->DR = (uint16_t)c; 8026d28: f8bd 3004 ldrh.w r3, [sp, #4] 8026d2c: 80a3 strh r3, [r4, #4] 8026d2e: e00a b.n 8026d46 //DBG printf("wr: %d 0x%x\r\n", rs485_tx_rbuf.read_index,c); } else { UPS_USART->CR1 &= ~USART_CR1_TXEIE; 8026d30: 89a3 ldrh r3, [r4, #12] 8026d32: f023 0380 bic.w r3, r3, #128 ; 0x80 8026d36: 041b lsls r3, r3, #16 8026d38: 0c1b lsrs r3, r3, #16 8026d3a: 81a3 strh r3, [r4, #12] UPS_USART->CR1 |= USART_CR1_RXNEIE; 8026d3c: 89a3 ldrh r3, [r4, #12] 8026d3e: b29b uxth r3, r3 8026d40: f043 0320 orr.w r3, r3, #32 8026d44: 81a3 strh r3, [r4, #12] } USART_ClearITPendingBit(UPS_USART, USART_IT_TXE); 8026d46: 4814 ldr r0, [pc, #80] ; (8026d98 ) 8026d48: f240 7127 movw r1, #1831 ; 0x727 8026d4c: f7ff f813 bl 8025d76 } if(USART_GetITStatus(UPS_USART, USART_IT_RXNE) != RESET) 8026d50: 4c11 ldr r4, [pc, #68] ; (8026d98 ) 8026d52: f240 5125 movw r1, #1317 ; 0x525 8026d56: 4620 mov r0, r4 8026d58: f7fe ffed bl 8025d36 8026d5c: b1d8 cbz r0, 8026d96 { c = (uint32_t)UPS_USART->DR; 8026d5e: 88a3 ldrh r3, [r4, #4] //DBG printf("read: %d 0x%x\r\n", rs485_rx_rbuf.write_index,c); if (!rbuf_isfull(&ups_rx_rbuf)) 8026d60: 480f ldr r0, [pc, #60] ; (8026da0 ) } USART_ClearITPendingBit(UPS_USART, USART_IT_TXE); } if(USART_GetITStatus(UPS_USART, USART_IT_RXNE) != RESET) { c = (uint32_t)UPS_USART->DR; 8026d62: b29b uxth r3, r3 8026d64: 9301 str r3, [sp, #4] //DBG printf("read: %d 0x%x\r\n", rs485_rx_rbuf.write_index,c); if (!rbuf_isfull(&ups_rx_rbuf)) 8026d66: f001 ff5d bl 8028c24 8026d6a: b918 cbnz r0, 8026d74 rbuf32_put(&ups_rx_rbuf, c); 8026d6c: 480c ldr r0, [pc, #48] ; (8026da0 ) 8026d6e: 9901 ldr r1, [sp, #4] 8026d70: f001 ff79 bl 8028c66 USART_ClearITPendingBit(UPS_USART, USART_IT_RXNE); 8026d74: 4808 ldr r0, [pc, #32] ; (8026d98 ) xSemaphoreGiveFromISR(xSem_rx_buf, &xHigherPriorityTaskWoken); 8026d76: 4c0b ldr r4, [pc, #44] ; (8026da4 ) { c = (uint32_t)UPS_USART->DR; //DBG printf("read: %d 0x%x\r\n", rs485_rx_rbuf.write_index,c); if (!rbuf_isfull(&ups_rx_rbuf)) rbuf32_put(&ups_rx_rbuf, c); USART_ClearITPendingBit(UPS_USART, USART_IT_RXNE); 8026d78: f240 5125 movw r1, #1317 ; 0x525 8026d7c: f7fe fffb bl 8025d76 xSemaphoreGiveFromISR(xSem_rx_buf, &xHigherPriorityTaskWoken); 8026d80: 4b09 ldr r3, [pc, #36] ; (8026da8 ) 8026d82: 4621 mov r1, r4 8026d84: 6818 ldr r0, [r3, #0] 8026d86: f002 f9bf bl 8029108 portYIELD_FROM_ISR(xHigherPriorityTaskWoken); 8026d8a: 6823 ldr r3, [r4, #0] 8026d8c: b11b cbz r3, 8026d96 8026d8e: 4b07 ldr r3, [pc, #28] ; (8026dac ) 8026d90: f04f 5280 mov.w r2, #268435456 ; 0x10000000 8026d94: 601a str r2, [r3, #0] } void USART2_IRQHandler(void) { rs232_irq_handler(); } 8026d96: bd1c pop {r2, r3, r4, pc} 8026d98: 40004400 .word 0x40004400 8026d9c: 2000e888 .word 0x2000e888 8026da0: 2000e558 .word 0x2000e558 8026da4: 2000289c .word 0x2000289c 8026da8: 2000e8a8 .word 0x2000e8a8 8026dac: e000ed04 .word 0xe000ed04 08026db0 : void USART3_IRQHandler(void) { 8026db0: 4770 bx lr 8026db2: 0000 movs r0, r0 08026db4 : /** * @brief Задача инициализации. Запускает основные задачи девайса и умирает. * @retval */ void InitTask(void *params) { 8026db4: b51f push {r0, r1, r2, r3, r4, lr} // ----------------------------------------------------------------------------- #ifdef LED_ENABLE LED_Init(); /* Простая мигалка для подтверждения живучести контроллера */ xTaskCreate(vTaskLedBlink, "LED_Blink", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL);//&xTaskToKill 8026db6: 2400 movs r4, #0 void InitTask(void *params) { // ----------------------------------------------------------------------------- // xTaskCreate(vTaskWdt, "WDT", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL); // ----------------------------------------------------------------------------- InitUSART(); 8026db8: f7ff ff3a bl 8026c30 ups_megatec_init(); 8026dbc: f001 ff18 bl 8028bf0 // ----------------------------------------------------------------------------- // RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_CRC, ENABLE); /* SETTINGS_SetDefaultDebug(); SETTINGS_Save();*/ SETTINGS_Load(); 8026dc0: f001 fc74 bl 80286ac set_mode_jumper(); 8026dc4: f001 fda0 bl 8028908 #endif // ----------------------------------------------------------------------------- // ----------------------------------------------------------------------------- #ifdef LED_ENABLE LED_Init(); 8026dc8: f001 fd1d bl 8028806 /* Простая мигалка для подтверждения живучести контроллера */ xTaskCreate(vTaskLedBlink, "LED_Blink", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL);//&xTaskToKill 8026dcc: 2280 movs r2, #128 ; 0x80 8026dce: 4623 mov r3, r4 8026dd0: 4921 ldr r1, [pc, #132] ; (8026e58 ) 8026dd2: 9400 str r4, [sp, #0] 8026dd4: 9401 str r4, [sp, #4] 8026dd6: 9402 str r4, [sp, #8] 8026dd8: 9403 str r4, [sp, #12] 8026dda: 4820 ldr r0, [pc, #128] ; (8026e5c ) 8026ddc: f002 fad0 bl 8029380 #endif // ----------------------------------------------------------------------------- // ----------------------------------------------------------------------------- #ifdef BUTTON_ENABLE BUTTON_Init(); 8026de0: f001 fd4a bl 8028878 xTaskCreate(vTaskButtons, "Buttons", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL); 8026de4: 2280 movs r2, #128 ; 0x80 8026de6: 4623 mov r3, r4 8026de8: 491d ldr r1, [pc, #116] ; (8026e60 ) 8026dea: 9400 str r4, [sp, #0] 8026dec: 9401 str r4, [sp, #4] 8026dee: 9402 str r4, [sp, #8] 8026df0: 9403 str r4, [sp, #12] 8026df2: 481c ldr r0, [pc, #112] ; (8026e64 ) 8026df4: f002 fac4 bl 8029380 //xTaskCreate( d_inouts_task, "inouts_task", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL); // xTaskCreate( d_inouts_test, "d_inouts_test", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL); // ----------------------------------------------------------------------------- #ifdef RTC_ENABLE TM_RTC_Init(TM_RTC_ClockSource_External); // Так было 8026df8: 2001 movs r0, #1 8026dfa: f7ff fb75 bl 80264e8 xTaskCreate(UPS_TaskState, "UPS_State", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL); xTaskCreate(UPS_Monitor, "UPS_Monitor", configMINIMAL_STACK_SIZE, NULL, tskIDLE_PRIORITY, NULL);*/ #endif // ----------------------------------------------------------------------------- /* Random number generator */ RNG_Init(); 8026dfe: f7ff f95b bl 80260b8 // ----------------------------------------------------------------------------- #ifdef NET_ENABLE ETH_BSP_Config(); 8026e02: f00e f9a5 bl 8035150 LwIP_Init(); 8026e06: f00d fea3 bl 8034b50 #ifdef WEB_SERVER_ENABLE HTTP_Init(); 8026e0a: f003 fb89 bl 802a520 #endif #endif // ----------------------------------------------------------------------------- /* SNTP */ SNTP_Init(); 8026e0e: f00e f925 bl 803505c xTaskCreate(vTaskOnceSynchro, "sntpOnceSinhro", 2*configMINIMAL_STACK_SIZE, 8026e12: 4b15 ldr r3, [pc, #84] ; (8026e68 ) 8026e14: 9400 str r4, [sp, #0] 8026e16: 9301 str r3, [sp, #4] 8026e18: 9402 str r4, [sp, #8] 8026e1a: 4623 mov r3, r4 8026e1c: 9403 str r4, [sp, #12] 8026e1e: 4913 ldr r1, [pc, #76] ; (8026e6c ) 8026e20: 4813 ldr r0, [pc, #76] ; (8026e70 ) 8026e22: f44f 7280 mov.w r2, #256 ; 0x100 8026e26: f002 faab bl 8029380 NULL, tskIDLE_PRIORITY, &xHandleSntpOnceSinhro); xTaskCreate(vTaskPeriodicSynchro, "sntpPeriodicSinhro", 2*configMINIMAL_STACK_SIZE, 8026e2a: 4912 ldr r1, [pc, #72] ; (8026e74 ) 8026e2c: 9400 str r4, [sp, #0] 8026e2e: f44f 7280 mov.w r2, #256 ; 0x100 8026e32: 4623 mov r3, r4 8026e34: 9401 str r4, [sp, #4] 8026e36: 9402 str r4, [sp, #8] 8026e38: 9403 str r4, [sp, #12] 8026e3a: 480f ldr r0, [pc, #60] ; (8026e78 ) 8026e3c: f002 faa0 bl 8029380 //TEST_IO(); /* Контроль успешной загрузки. Сброс флага bootry */ /* Сброс флага и сохранение нового значения во флеш памяти происходт после некоторой задержки для запуска всех задач */ vTaskDelay(4000); 8026e40: f44f 607a mov.w r0, #4000 ; 0xfa0 8026e44: f002 fd36 bl 80298b4 /* if (!dhcp) SNMP_SendUserTrap(DEVICE_REBOOTED); printf("Hello world\r\n");*/ vTaskDelete(NULL); 8026e48: 4620 mov r0, r4 8026e4a: f002 fb71 bl 8029530 taskYIELD(); } 8026e4e: b004 add sp, #16 8026e50: e8bd 4010 ldmia.w sp!, {r4, lr} SNMP_SendUserTrap(DEVICE_REBOOTED); printf("Hello world\r\n");*/ vTaskDelete(NULL); taskYIELD(); 8026e54: f003 b8e4 b.w 802a020 8026e58: 08035d30 .word 0x08035d30 8026e5c: 080287e9 .word 0x080287e9 8026e60: 08035d3a .word 0x08035d3a 8026e64: 080288f5 .word 0x080288f5 8026e68: 200028a0 .word 0x200028a0 8026e6c: 08035d42 .word 0x08035d42 8026e70: 08035129 .word 0x08035129 8026e74: 08035d51 .word 0x08035d51 8026e78: 080350e1 .word 0x080350e1 08026e7c
: void vApplicationTickHook(void) { } int main() { 8026e7c: b51f push {r0, r1, r2, r3, r4, lr} This function disables IRQ interrupts by setting the I-bit in the CPSR. Can only be executed in Privileged modes. */ __attribute__( ( always_inline ) ) __STATIC_INLINE void __disable_irq(void) { __ASM volatile ("cpsid i" : : : "memory"); 8026e7e: b672 cpsid i //TIM_Cmd(TIM13, DISABLE); //TIM_ClearITPendingBit(TIM13, TIM_IT_Update); __disable_irq(); NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0x20000); 8026e80: f04f 6000 mov.w r0, #134217728 ; 0x8000000 8026e84: f44f 3100 mov.w r1, #131072 ; 0x20000 8026e88: f7fe fa3e bl 8025308 __STATIC_INLINE void NVIC_SetPriorityGrouping(uint32_t PriorityGroup) { uint32_t reg_value; uint32_t PriorityGroupTmp = (PriorityGroup & (uint32_t)0x07); /* only values 0..7 are used */ reg_value = SCB->AIRCR; /* read old register configuration */ 8026e8c: 4a17 ldr r2, [pc, #92] ; (8026eec ) 8026e8e: 68d1 ldr r1, [r2, #12] reg_value &= ~(SCB_AIRCR_VECTKEY_Msk | SCB_AIRCR_PRIGROUP_Msk); /* clear bits to change */ 8026e90: f64f 03ff movw r3, #63743 ; 0xf8ff 8026e94: 400b ands r3, r1 reg_value = (reg_value | 8026e96: f043 63bf orr.w r3, r3, #100139008 ; 0x5f80000 8026e9a: f443 3300 orr.w r3, r3, #131072 ; 0x20000 ((uint32_t)0x5FA << SCB_AIRCR_VECTKEY_Pos) | (PriorityGroupTmp << 8)); /* Insert write key and priorty group */ SCB->AIRCR = reg_value; 8026e9e: 60d3 str r3, [r2, #12] NVIC_SetPriorityGrouping(0); NVIC_PriorityGroupConfig( NVIC_PriorityGroup_4 ); 8026ea0: f44f 7040 mov.w r0, #768 ; 0x300 8026ea4: f7fe f9f2 bl 802528c This function enables IRQ interrupts by clearing the I-bit in the CPSR. Can only be executed in Privileged modes. */ __attribute__( ( always_inline ) ) __STATIC_INLINE void __enable_irq(void) { __ASM volatile ("cpsie i" : : : "memory"); 8026ea8: b662 cpsie i __enable_irq(); //WDG_Init(); RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_CRC, ENABLE); 8026eaa: 2101 movs r1, #1 8026eac: f44f 5080 mov.w r0, #4096 ; 0x1000 8026eb0: f7fe fc4c bl 802574c /* Clear flash error flags if were set */ FLASH_ClearFlag(FLASH_FLAG_PGPERR); 8026eb4: 2040 movs r0, #64 ; 0x40 gpio_init(); spi_flash_test(); // NVIC_PriorityGroupConfig(NVIC_PriorityGroup_4); xTaskCreate( InitTask, "InitTask", 1000, NULL, tskIDLE_PRIORITY, NULL); 8026eb6: 2400 movs r4, #0 //WDG_Init(); RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_CRC, ENABLE); /* Clear flash error flags if were set */ FLASH_ClearFlag(FLASH_FLAG_PGPERR); 8026eb8: f7fe fa5c bl 8025374 FLASH_ClearFlag(FLASH_FLAG_PGSERR); 8026ebc: 2080 movs r0, #128 ; 0x80 8026ebe: f7fe fa59 bl 8025374 gpio_init(); 8026ec2: f7ff f895 bl 8025ff0 spi_flash_test(); 8026ec6: f7ff fdcd bl 8026a64 // NVIC_PriorityGroupConfig(NVIC_PriorityGroup_4); xTaskCreate( InitTask, "InitTask", 1000, NULL, tskIDLE_PRIORITY, NULL); 8026eca: 4909 ldr r1, [pc, #36] ; (8026ef0 ) 8026ecc: 9400 str r4, [sp, #0] 8026ece: f44f 727a mov.w r2, #1000 ; 0x3e8 8026ed2: 4623 mov r3, r4 8026ed4: 9401 str r4, [sp, #4] 8026ed6: 9402 str r4, [sp, #8] 8026ed8: 9403 str r4, [sp, #12] 8026eda: 4806 ldr r0, [pc, #24] ; (8026ef4 ) 8026edc: f002 fa50 bl 8029380 vTaskStartScheduler(); 8026ee0: f002 fb80 bl 80295e4 /*while(1) { }*/ } 8026ee4: 4620 mov r0, r4 8026ee6: b004 add sp, #16 8026ee8: bd10 pop {r4, pc} 8026eea: bf00 nop 8026eec: e000ed00 .word 0xe000ed00 8026ef0: 08035d64 .word 0x08035d64 8026ef4: 08026db5 .word 0x08026db5 08026ef8 : * @brief This function handles NMI exception. * @param None * @retval None */ void NMI_Handler(void) { 8026ef8: 4770 bx lr 8026efa: 0000 movs r0, r0 08026efc : } void HardFault_Output(uint32_t *sp) { 8026efc: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} uint32_t r0 = sp[0]; uint32_t r1 = sp[1]; 8026f00: e890 0808 ldmia.w r0, {r3, fp} uint32_t r2 = sp[2]; 8026f04: f8d0 a008 ldr.w sl, [r0, #8] uint32_t r3 = sp[3]; 8026f08: f8d0 900c ldr.w r9, [r0, #12] uint32_t r12 = sp[4]; 8026f0c: f8d0 8010 ldr.w r8, [r0, #16] uint32_t lr = sp[5]; 8026f10: 6947 ldr r7, [r0, #20] uint32_t pc = sp[6]; 8026f12: 6986 ldr r6, [r0, #24] uint32_t psr = sp[7]; 8026f14: 69c5 ldr r5, [r0, #28] printf("HardFault:\n\r"); 8026f16: 9301 str r3, [sp, #4] void NMI_Handler(void) { } void HardFault_Output(uint32_t *sp) { 8026f18: 4604 mov r4, r0 uint32_t r12 = sp[4]; uint32_t lr = sp[5]; uint32_t pc = sp[6]; uint32_t psr = sp[7]; printf("HardFault:\n\r"); 8026f1a: 4816 ldr r0, [pc, #88] ; (8026f74 ) 8026f1c: f000 fbc6 bl 80276ac /* Print CFSR register */ /* Print CPU registers */ printf("\n\rRegisters:\n\r"); 8026f20: 4815 ldr r0, [pc, #84] ; (8026f78 ) 8026f22: f000 fbc3 bl 80276ac printf("SP 0x%08lx\n\r", (uint32_t)sp); 8026f26: 4815 ldr r0, [pc, #84] ; (8026f7c ) 8026f28: 4621 mov r1, r4 8026f2a: f000 fbbf bl 80276ac printf("R0 0x%08lx\n\r", r0); 8026f2e: 9b01 ldr r3, [sp, #4] 8026f30: 4813 ldr r0, [pc, #76] ; (8026f80 ) 8026f32: 4619 mov r1, r3 8026f34: f000 fbba bl 80276ac printf("R1 0x%08lx\n\r", r1); 8026f38: 4812 ldr r0, [pc, #72] ; (8026f84 ) 8026f3a: 4659 mov r1, fp 8026f3c: f000 fbb6 bl 80276ac printf("R2 0x%08lx\n\r", r2); 8026f40: 4811 ldr r0, [pc, #68] ; (8026f88 ) 8026f42: 4651 mov r1, sl 8026f44: f000 fbb2 bl 80276ac printf("R3 0x%08lx\n\r", r3); 8026f48: 4810 ldr r0, [pc, #64] ; (8026f8c ) 8026f4a: 4649 mov r1, r9 8026f4c: f000 fbae bl 80276ac printf("R12 0x%08lx\n\r", r12); 8026f50: 480f ldr r0, [pc, #60] ; (8026f90 ) 8026f52: 4641 mov r1, r8 8026f54: f000 fbaa bl 80276ac printf("LR 0x%08lx\n\r", lr); 8026f58: 480e ldr r0, [pc, #56] ; (8026f94 ) 8026f5a: 4639 mov r1, r7 8026f5c: f000 fba6 bl 80276ac printf("PC 0x%08lx\n\r", pc); 8026f60: 480d ldr r0, [pc, #52] ; (8026f98 ) 8026f62: 4631 mov r1, r6 8026f64: f000 fba2 bl 80276ac printf("PSR 0x%08lx\n\r", psr); 8026f68: 480c ldr r0, [pc, #48] ; (8026f9c ) 8026f6a: 4629 mov r1, r5 8026f6c: f000 fb9e bl 80276ac 8026f70: e7fe b.n 8026f70 8026f72: bf00 nop 8026f74: 08035d6d .word 0x08035d6d 8026f78: 08035d7a .word 0x08035d7a 8026f7c: 08035d89 .word 0x08035d89 8026f80: 08035d9f .word 0x08035d9f 8026f84: 08035db5 .word 0x08035db5 8026f88: 08035dcb .word 0x08035dcb 8026f8c: 08035de1 .word 0x08035de1 8026f90: 08035df7 .word 0x08035df7 8026f94: 08035e0d .word 0x08035e0d 8026f98: 08035e23 .word 0x08035e23 8026f9c: 08035e39 .word 0x08035e39 08026fa0 : * @retval None */ __attribute__( (naked) ) void HardFault_Handler(void) { __asm volatile 8026fa0: f01e 0f04 tst.w lr, #4 8026fa4: bf0c ite eq 8026fa6: f3ef 8008 mrseq r0, MSP 8026faa: f3ef 8009 mrsne r0, PSP 8026fae: f8df 1004 ldr.w r1, [pc, #4] ; 8026fb4 8026fb2: 4708 bx r1 08026fb4 : 8026fb4: 08026efd .word 0x08026efd 08026fb8 : * @brief This function handles Memory Manage exception. * @param None * @retval None */ void MemManage_Handler(void) { 8026fb8: e7fe b.n 8026fb8 8026fba: 0000 movs r0, r0 08026fbc : } } void TIM8_UP_TIM13_IRQHandler(void) { TIM_ClearITPendingBit(TIM13, TIM_IT_Update); 8026fbc: 4801 ldr r0, [pc, #4] ; (8026fc4 ) 8026fbe: 2101 movs r1, #1 8026fc0: f7fe bde2 b.w 8025b88 8026fc4: 40001c00 .word 0x40001c00 08026fc8 : * @brief This function handles Bus Fault exception. * @param None * @retval None */ void BusFault_Handler(void) { 8026fc8: e7fe b.n 8026fc8 08026fca : * @brief This function handles Usage Fault exception. * @param None * @retval None */ void UsageFault_Handler(void) { 8026fca: e7fe b.n 8026fca 08026fcc : * @brief This function handles Debug Monitor exception. * @param None * @retval None */ void DebugMon_Handler(void) { 8026fcc: 4770 bx lr 08026fce : /*void PPP_IRQHandler(void) { }*/ void SDIO_IRQHandler(void) { 8026fce: 4770 bx lr 08026fd0 : * @brief This function handles ethernet DMA interrupt request. * @param None * @retval None */ void ETH_IRQHandler(void) { 8026fd0: b507 push {r0, r1, r2, lr} portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; 8026fd2: 2300 movs r3, #0 /* Frame received */ if ( ETH_GetDMAFlagStatus(ETH_DMA_FLAG_R) == SET) 8026fd4: 2040 movs r0, #64 ; 0x40 * @param None * @retval None */ void ETH_IRQHandler(void) { portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; 8026fd6: 9301 str r3, [sp, #4] /* Frame received */ if ( ETH_GetDMAFlagStatus(ETH_DMA_FLAG_R) == SET) 8026fd8: f00e fb58 bl 803568c 8026fdc: 2801 cmp r0, #1 8026fde: d104 bne.n 8026fea { /* Give the semaphore to wakeup LwIP task */ xSemaphoreGiveFromISR( s_xSemaphore, &xHigherPriorityTaskWoken ); 8026fe0: 4b09 ldr r3, [pc, #36] ; (8027008 ) 8026fe2: a901 add r1, sp, #4 8026fe4: 6818 ldr r0, [r3, #0] 8026fe6: f002 f88f bl 8029108 } /* Clear the interrupt flags. */ /* Clear the Eth DMA Rx IT pending bits */ ETH_DMAClearITPendingBit(ETH_DMA_IT_R); 8026fea: 2040 movs r0, #64 ; 0x40 8026fec: f00e fb64 bl 80356b8 ETH_DMAClearITPendingBit(ETH_DMA_IT_NIS); 8026ff0: f44f 3080 mov.w r0, #65536 ; 0x10000 8026ff4: f00e fb60 bl 80356b8 // Switch tasks if necessary. */ if( xHigherPriorityTaskWoken != pdFALSE ) 8026ff8: 9b01 ldr r3, [sp, #4] 8026ffa: b11b cbz r3, 8027004 { portEND_SWITCHING_ISR( xHigherPriorityTaskWoken ); 8026ffc: 4b03 ldr r3, [pc, #12] ; (802700c ) 8026ffe: f04f 5280 mov.w r2, #268435456 ; 0x10000000 8027002: 601a str r2, [r3, #0] } } 8027004: bd0e pop {r1, r2, r3, pc} 8027006: bf00 nop 8027008: 2000e4dc .word 0x2000e4dc 802700c: e000ed04 .word 0xe000ed04 08027010 : #ifdef PRINTF_LONG_LONG_SUPPORT static void _TFP_GCC_NO_INLINE_ ulli2a( unsigned long long int num, struct param *p) { 8027010: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} int n = 0; unsigned long long int d = 1; char *bf = p->bf; while (num / d >= p->base) 8027014: 68d3 ldr r3, [r2, #12] static void _TFP_GCC_NO_INLINE_ ulli2a( unsigned long long int num, struct param *p) { int n = 0; unsigned long long int d = 1; char *bf = p->bf; 8027016: f8d2 b010 ldr.w fp, [r2, #16] #ifdef PRINTF_LONG_LONG_SUPPORT static void _TFP_GCC_NO_INLINE_ ulli2a( unsigned long long int num, struct param *p) { 802701a: 4681 mov r9, r0 802701c: 468a mov sl, r1 802701e: 4690 mov r8, r2 int n = 0; unsigned long long int d = 1; char *bf = p->bf; while (num / d >= p->base) 8027020: 461e mov r6, r3 8027022: 2700 movs r7, #0 #ifdef PRINTF_LONG_LONG_SUPPORT static void _TFP_GCC_NO_INLINE_ ulli2a( unsigned long long int num, struct param *p) { int n = 0; unsigned long long int d = 1; 8027024: 2401 movs r4, #1 8027026: 2500 movs r5, #0 char *bf = p->bf; while (num / d >= p->base) 8027028: e006 b.n 8027038 d *= p->base; 802702a: fb04 f307 mul.w r3, r4, r7 802702e: fb06 3305 mla r3, r6, r5, r3 8027032: fba4 4506 umull r4, r5, r4, r6 8027036: 195d adds r5, r3, r5 unsigned long long int num, struct param *p) { int n = 0; unsigned long long int d = 1; char *bf = p->bf; while (num / d >= p->base) 8027038: 4648 mov r0, r9 802703a: 4651 mov r1, sl 802703c: 4622 mov r2, r4 802703e: 462b mov r3, r5 8027040: f7f9 ff54 bl 8020eec <__aeabi_uldivmod> 8027044: 42b9 cmp r1, r7 8027046: bf08 it eq 8027048: 42b0 cmpeq r0, r6 802704a: d2ee bcs.n 802702a 802704c: 2600 movs r6, #0 802704e: e02d b.n 80270ac d *= p->base; while (d != 0) { int dgt = num / d; 8027050: 4622 mov r2, r4 8027052: 462b mov r3, r5 8027054: 4648 mov r0, r9 8027056: 4651 mov r1, sl 8027058: f7f9 ff48 bl 8020eec <__aeabi_uldivmod> num %= d; 802705c: 4651 mov r1, sl 802705e: 4622 mov r2, r4 8027060: 462b mov r3, r5 unsigned long long int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { int dgt = num / d; 8027062: 4607 mov r7, r0 num %= d; 8027064: 4648 mov r0, r9 8027066: f7f9 ff41 bl 8020eec <__aeabi_uldivmod> d /= p->base; 802706a: 4620 mov r0, r4 802706c: 4629 mov r1, r5 char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { int dgt = num / d; num %= d; 802706e: 4691 mov r9, r2 8027070: 469a mov sl, r3 d /= p->base; 8027072: f8d8 200c ldr.w r2, [r8, #12] 8027076: 2300 movs r3, #0 8027078: f7f9 ff38 bl 8020eec <__aeabi_uldivmod> 802707c: 4604 mov r4, r0 802707e: 460d mov r5, r1 if (n || dgt > 0 || d == 0) { 8027080: b926 cbnz r6, 802708c 8027082: 2f00 cmp r7, #0 8027084: dc02 bgt.n 802708c 8027086: ea54 0305 orrs.w r3, r4, r5 802708a: d1e1 bne.n 8027050 *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); 802708c: 2f09 cmp r7, #9 802708e: b2fa uxtb r2, r7 8027090: dd07 ble.n 80270a2 8027092: f898 3000 ldrb.w r3, [r8] 8027096: f013 0f04 tst.w r3, #4 802709a: bf0c ite eq 802709c: 2357 moveq r3, #87 ; 0x57 802709e: 2337 movne r3, #55 ; 0x37 80270a0: e000 b.n 80270a4 80270a2: 2330 movs r3, #48 ; 0x30 80270a4: 189b adds r3, r3, r2 80270a6: f80b 3b01 strb.w r3, [fp], #1 ++n; 80270aa: 3601 adds r6, #1 int n = 0; unsigned long long int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { 80270ac: ea54 0305 orrs.w r3, r4, r5 80270b0: d1ce bne.n 8027050 if (n || dgt > 0 || d == 0) { *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); ++n; } } *bf = 0; 80270b2: 2300 movs r3, #0 80270b4: f88b 3000 strb.w r3, [fp] 80270b8: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 080270bc : } #endif #ifdef PRINTF_LONG_SUPPORT static void uli2a(unsigned long int num, struct param *p) { 80270bc: b570 push {r4, r5, r6, lr} int n = 0; unsigned long int d = 1; char *bf = p->bf; while (num / d >= p->base) 80270be: 68ca ldr r2, [r1, #12] #ifdef PRINTF_LONG_SUPPORT static void uli2a(unsigned long int num, struct param *p) { int n = 0; unsigned long int d = 1; char *bf = p->bf; 80270c0: 690c ldr r4, [r1, #16] #ifdef PRINTF_LONG_SUPPORT static void uli2a(unsigned long int num, struct param *p) { int n = 0; unsigned long int d = 1; 80270c2: 2301 movs r3, #1 char *bf = p->bf; while (num / d >= p->base) 80270c4: e000 b.n 80270c8 d *= p->base; 80270c6: 4353 muls r3, r2 static void uli2a(unsigned long int num, struct param *p) { int n = 0; unsigned long int d = 1; char *bf = p->bf; while (num / d >= p->base) 80270c8: fbb0 f5f3 udiv r5, r0, r3 80270cc: 4295 cmp r5, r2 80270ce: d2fa bcs.n 80270c6 80270d0: 2500 movs r5, #0 80270d2: e01a b.n 802710a d *= p->base; while (d != 0) { int dgt = num / d; num %= d; d /= p->base; 80270d4: 68ce ldr r6, [r1, #12] unsigned long int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { int dgt = num / d; 80270d6: fbb0 f2f3 udiv r2, r0, r3 num %= d; 80270da: fb03 0012 mls r0, r3, r2, r0 d /= p->base; 80270de: fbb3 f3f6 udiv r3, r3, r6 if (n || dgt > 0 || d == 0) { 80270e2: b91d cbnz r5, 80270ec 80270e4: 2a00 cmp r2, #0 80270e6: dc01 bgt.n 80270ec 80270e8: 2b00 cmp r3, #0 80270ea: d1f3 bne.n 80270d4 *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); 80270ec: 2a09 cmp r2, #9 80270ee: b2d6 uxtb r6, r2 80270f0: dd06 ble.n 8027100 80270f2: 780a ldrb r2, [r1, #0] 80270f4: f012 0f04 tst.w r2, #4 80270f8: bf0c ite eq 80270fa: 2257 moveq r2, #87 ; 0x57 80270fc: 2237 movne r2, #55 ; 0x37 80270fe: e000 b.n 8027102 8027100: 2230 movs r2, #48 ; 0x30 8027102: 1992 adds r2, r2, r6 8027104: f804 2b01 strb.w r2, [r4], #1 ++n; 8027108: 3501 adds r5, #1 int n = 0; unsigned long int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { 802710a: 2b00 cmp r3, #0 802710c: d1e2 bne.n 80270d4 if (n || dgt > 0 || d == 0) { *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); ++n; } } *bf = 0; 802710e: 7023 strb r3, [r4, #0] 8027110: bd70 pop {r4, r5, r6, pc} 08027112 : uli2a(num, p); } #endif static void ui2a(unsigned int num, struct param *p) { 8027112: b570 push {r4, r5, r6, lr} int n = 0; unsigned int d = 1; char *bf = p->bf; while (num / d >= p->base) 8027114: 68ca ldr r2, [r1, #12] static void ui2a(unsigned int num, struct param *p) { int n = 0; unsigned int d = 1; char *bf = p->bf; 8027116: 690c ldr r4, [r1, #16] #endif static void ui2a(unsigned int num, struct param *p) { int n = 0; unsigned int d = 1; 8027118: 2301 movs r3, #1 char *bf = p->bf; while (num / d >= p->base) 802711a: e000 b.n 802711e d *= p->base; 802711c: 4353 muls r3, r2 static void ui2a(unsigned int num, struct param *p) { int n = 0; unsigned int d = 1; char *bf = p->bf; while (num / d >= p->base) 802711e: fbb0 f5f3 udiv r5, r0, r3 8027122: 4295 cmp r5, r2 8027124: d2fa bcs.n 802711c 8027126: 2500 movs r5, #0 8027128: e01a b.n 8027160 d *= p->base; while (d != 0) { int dgt = num / d; num %= d; d /= p->base; 802712a: 68ce ldr r6, [r1, #12] unsigned int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { int dgt = num / d; 802712c: fbb0 f2f3 udiv r2, r0, r3 num %= d; 8027130: fb03 0012 mls r0, r3, r2, r0 d /= p->base; 8027134: fbb3 f3f6 udiv r3, r3, r6 if (n || dgt > 0 || d == 0) { 8027138: b91d cbnz r5, 8027142 802713a: 2a00 cmp r2, #0 802713c: dc01 bgt.n 8027142 802713e: 2b00 cmp r3, #0 8027140: d1f3 bne.n 802712a *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); 8027142: 2a09 cmp r2, #9 8027144: b2d6 uxtb r6, r2 8027146: dd06 ble.n 8027156 8027148: 780a ldrb r2, [r1, #0] 802714a: f012 0f04 tst.w r2, #4 802714e: bf0c ite eq 8027150: 2257 moveq r2, #87 ; 0x57 8027152: 2237 movne r2, #55 ; 0x37 8027154: e000 b.n 8027158 8027156: 2230 movs r2, #48 ; 0x30 8027158: 1992 adds r2, r2, r6 802715a: f804 2b01 strb.w r2, [r4], #1 ++n; 802715e: 3501 adds r5, #1 int n = 0; unsigned int d = 1; char *bf = p->bf; while (num / d >= p->base) d *= p->base; while (d != 0) { 8027160: 2b00 cmp r3, #0 8027162: d1e2 bne.n 802712a if (n || dgt > 0 || d == 0) { *bf++ = dgt + (dgt < 10 ? '0' : (p->uc ? 'A' : 'a') - 10); ++n; } } *bf = 0; 8027164: 7023 strb r3, [r4, #0] 8027166: bd70 pop {r4, r5, r6, pc} 08027168 : } static void putchw(void *putp, putcf putf, struct param *p) { 8027168: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} char ch; int n = p->width; char *bf = p->bf; 802716c: 6913 ldr r3, [r2, #16] } static void putchw(void *putp, putcf putf, struct param *p) { char ch; int n = p->width; 802716e: 6854 ldr r4, [r2, #4] } static void putchw(void *putp, putcf putf, struct param *p) { 8027170: 4606 mov r6, r0 8027172: 460f mov r7, r1 8027174: 4615 mov r5, r2 char ch; int n = p->width; char *bf = p->bf; /* Number of filling characters */ while (*bf++ && n > 0) 8027176: e000 b.n 802717a n--; 8027178: 3c01 subs r4, #1 char ch; int n = p->width; char *bf = p->bf; /* Number of filling characters */ while (*bf++ && n > 0) 802717a: f813 2b01 ldrb.w r2, [r3], #1 802717e: b912 cbnz r2, 8027186 n--; if (p->sign) 8027180: 7a2b ldrb r3, [r5, #8] 8027182: b91b cbnz r3, 802718c 8027184: e003 b.n 802718e char ch; int n = p->width; char *bf = p->bf; /* Number of filling characters */ while (*bf++ && n > 0) 8027186: 2c00 cmp r4, #0 8027188: dcf6 bgt.n 8027178 802718a: e7f9 b.n 8027180 n--; if (p->sign) n--; 802718c: 3c01 subs r4, #1 if (p->alt && p->base == 16) 802718e: 782b ldrb r3, [r5, #0] 8027190: 0799 lsls r1, r3, #30 8027192: d507 bpl.n 80271a4 8027194: 68eb ldr r3, [r5, #12] 8027196: 2b10 cmp r3, #16 8027198: d101 bne.n 802719e n -= 2; 802719a: 3c02 subs r4, #2 802719c: e002 b.n 80271a4 else if (p->alt && p->base == 8) 802719e: 2b08 cmp r3, #8 n--; 80271a0: bf08 it eq 80271a2: 3c01 subeq r4, #1 /* Fill with space to align to the right, before alternate or sign */ if (!p->lz && !p->align_left) { 80271a4: 782b ldrb r3, [r5, #0] 80271a6: f013 0f09 tst.w r3, #9 80271aa: d10d bne.n 80271c8 80271ac: 46a0 mov r8, r4 80271ae: e004 b.n 80271ba while (n-- > 0) putf(putp, ' '); 80271b0: 4630 mov r0, r6 80271b2: 2120 movs r1, #32 80271b4: 47b8 blx r7 80271b6: f108 38ff add.w r8, r8, #4294967295 else if (p->alt && p->base == 8) n--; /* Fill with space to align to the right, before alternate or sign */ if (!p->lz && !p->align_left) { while (n-- > 0) 80271ba: f1b8 0f00 cmp.w r8, #0 80271be: dcf7 bgt.n 80271b0 return neg ? -fvalue : fvalue; } static void putchw(void *putp, putcf putf, struct param *p) 80271c0: 1e63 subs r3, r4, #1 80271c2: ea24 74e4 bic.w r4, r4, r4, asr #31 80271c6: 1b1c subs r4, r3, r4 while (n-- > 0) putf(putp, ' '); } /* print sign */ if (p->sign) 80271c8: 7a29 ldrb r1, [r5, #8] 80271ca: b109 cbz r1, 80271d0 putf(putp, p->sign); 80271cc: 4630 mov r0, r6 80271ce: 47b8 blx r7 /* Alternate */ if (p->alt && p->base == 16) { 80271d0: 782b ldrb r3, [r5, #0] 80271d2: 079a lsls r2, r3, #30 80271d4: d512 bpl.n 80271fc 80271d6: 68eb ldr r3, [r5, #12] 80271d8: 2b10 cmp r3, #16 80271da: d10a bne.n 80271f2 putf(putp, '0'); 80271dc: 2130 movs r1, #48 ; 0x30 80271de: 4630 mov r0, r6 80271e0: 47b8 blx r7 putf(putp, (p->uc ? 'X' : 'x')); 80271e2: 782b ldrb r3, [r5, #0] 80271e4: f013 0f04 tst.w r3, #4 80271e8: 4630 mov r0, r6 80271ea: bf0c ite eq 80271ec: 2178 moveq r1, #120 ; 0x78 80271ee: 2158 movne r1, #88 ; 0x58 80271f0: e003 b.n 80271fa } else if (p->alt && p->base == 8) { 80271f2: 2b08 cmp r3, #8 80271f4: d102 bne.n 80271fc putf(putp, '0'); 80271f6: 4630 mov r0, r6 80271f8: 2130 movs r1, #48 ; 0x30 80271fa: 47b8 blx r7 } /* Fill with zeros, after alternate or sign */ if (p->lz) { 80271fc: 782b ldrb r3, [r5, #0] 80271fe: 07db lsls r3, r3, #31 8027200: d50d bpl.n 802721e 8027202: 46a0 mov r8, r4 8027204: e004 b.n 8027210 while (n-- > 0) putf(putp, '0'); 8027206: 4630 mov r0, r6 8027208: 2130 movs r1, #48 ; 0x30 802720a: 47b8 blx r7 802720c: f108 38ff add.w r8, r8, #4294967295 putf(putp, '0'); } /* Fill with zeros, after alternate or sign */ if (p->lz) { while (n-- > 0) 8027210: f1b8 0f00 cmp.w r8, #0 8027214: dcf7 bgt.n 8027206 return neg ? -fvalue : fvalue; } static void putchw(void *putp, putcf putf, struct param *p) 8027216: 1e63 subs r3, r4, #1 8027218: ea24 74e4 bic.w r4, r4, r4, asr #31 802721c: 1b1c subs r4, r3, r4 while (n-- > 0) putf(putp, '0'); } /* Put actual buffer */ bf = p->bf; 802721e: f8d5 8010 ldr.w r8, [r5, #16] while ((ch = *bf++)) 8027222: e001 b.n 8027228 putf(putp, ch); 8027224: 4630 mov r0, r6 8027226: 47b8 blx r7 putf(putp, '0'); } /* Put actual buffer */ bf = p->bf; while ((ch = *bf++)) 8027228: f818 1b01 ldrb.w r1, [r8], #1 802722c: 2900 cmp r1, #0 802722e: d1f9 bne.n 8027224 putf(putp, ch); /* Fill with space to align to the left, after string */ if (!p->lz && p->align_left) { 8027230: 782b ldrb r3, [r5, #0] 8027232: f003 0309 and.w r3, r3, #9 8027236: 2b08 cmp r3, #8 8027238: d106 bne.n 8027248 802723a: e003 b.n 8027244 while (n-- > 0) putf(putp, ' '); 802723c: 4630 mov r0, r6 802723e: 2120 movs r1, #32 8027240: 47b8 blx r7 8027242: 3c01 subs r4, #1 while ((ch = *bf++)) putf(putp, ch); /* Fill with space to align to the left, after string */ if (!p->lz && p->align_left) { while (n-- > 0) 8027244: 2c00 cmp r4, #0 8027246: dcf9 bgt.n 802723c 8027248: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 0802724c <_vsnprintf_putcf>: }; static void _vsnprintf_putcf(void *p, char c) { struct _vsnprintf_putcf_data *data = (struct _vsnprintf_putcf_data*)p; if (data->num_chars < data->dest_capacity) 802724c: 6883 ldr r3, [r0, #8] 802724e: 6802 ldr r2, [r0, #0] 8027250: 4293 cmp r3, r2 data->dest[data->num_chars] = c; 8027252: bf3c itt cc 8027254: 6842 ldrcc r2, [r0, #4] 8027256: 54d1 strbcc r1, [r2, r3] data->num_chars ++; 8027258: 6883 ldr r3, [r0, #8] 802725a: 3301 adds r3, #1 802725c: 6083 str r3, [r0, #8] 802725e: 4770 bx lr 08027260 <_vsprintf_putcf>: }; static void _vsprintf_putcf(void *p, char c) { struct _vsprintf_putcf_data *data = (struct _vsprintf_putcf_data*)p; data->dest[data->num_chars++] = c; 8027260: e890 000c ldmia.w r0, {r2, r3} 8027264: 54d1 strb r1, [r2, r3] 8027266: 3301 adds r3, #1 8027268: 6043 str r3, [r0, #4] 802726a: 4770 bx lr 0802726c : putf(putp, ' '); } } void tfp_format(void *putp, putcf putf, const char *fmt, va_list va) { 802726c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8027270: b09b sub sp, #108 ; 0x6c 8027272: 4617 mov r7, r2 char bf[23]; /* long = 64b on some architectures */ #else char bf[12]; /* int = 32b on some architectures */ #endif char ch; p.bf = bf; 8027274: aa04 add r2, sp, #16 putf(putp, ' '); } } void tfp_format(void *putp, putcf putf, const char *fmt, va_list va) { 8027276: 4605 mov r5, r0 8027278: 460e mov r6, r1 802727a: 461c mov r4, r3 char bf[23]; /* long = 64b on some architectures */ #else char bf[12]; /* int = 32b on some architectures */ #endif char ch; p.bf = bf; 802727c: 920e str r2, [sp, #56] ; 0x38 while ((ch = *(fmt++))) { 802727e: e208 b.n 8027692 if (ch != '%') { 8027280: 2925 cmp r1, #37 ; 0x25 8027282: d000 beq.n 8027286 8027284: e13a b.n 80274fc #endif /* Init parameter struct */ p.lz = 0; p.alt = 0; p.width = 0; p.align_left = 0; 8027286: f89d 2028 ldrb.w r2, [sp, #40] ; 0x28 char lng = 0; /* 1 for long, 2 for long long */ #endif /* Init parameter struct */ p.lz = 0; p.alt = 0; p.width = 0; 802728a: 2300 movs r3, #0 p.align_left = 0; 802728c: f002 02fc and.w r2, r2, #252 ; 0xfc 8027290: f363 02c3 bfi r2, r3, #3, #1 8027294: f88d 2028 strb.w r2, [sp, #40] ; 0x28 p.sign = 0; p.prec = 2; 8027298: 2102 movs r1, #2 } else { #ifdef PRINTF_LONG_SUPPORT char lng = 0; /* 1 for long, 2 for long long */ #endif /* Init parameter struct */ p.lz = 0; 802729a: b2d2 uxtb r2, r2 802729c: f002 0c01 and.w ip, r2, #1 80272a0: f3c2 0040 ubfx r0, r2, #1, #1 p.alt = 0; p.width = 0; 80272a4: 930b str r3, [sp, #44] ; 0x2c p.align_left = 0; p.sign = 0; 80272a6: f88d 3030 strb.w r3, [sp, #48] ; 0x30 p.prec = 2; 80272aa: f88d 103c strb.w r1, [sp, #60] ; 0x3c 80272ae: f3c2 02c0 ubfx r2, r2, #3, #1 /* Flags */ while ((ch = *(fmt++))) { 80272b2: e012 b.n 80272da switch (ch) { 80272b4: 292d cmp r1, #45 ; 0x2d 80272b6: d00f beq.n 80272d8 80272b8: d804 bhi.n 80272c4 80272ba: 2923 cmp r1, #35 ; 0x23 80272bc: d008 beq.n 80272d0 80272be: 292b cmp r1, #43 ; 0x2b 80272c0: d10f bne.n 80272e2 80272c2: e007 b.n 80272d4 80272c4: 2930 cmp r1, #48 ; 0x30 80272c6: d000 beq.n 80272ca 80272c8: e00b b.n 80272e2 case '-': p.align_left = 1; continue; case '0': p.lz = 1; 80272ca: f04f 0c01 mov.w ip, #1 continue; 80272ce: e004 b.n 80272da case '#': p.alt = 1; 80272d0: 2001 movs r0, #1 continue; 80272d2: e002 b.n 80272da case '+': p.sign = 1; 80272d4: 2301 movs r3, #1 continue; 80272d6: e000 b.n 80272da /* Flags */ while ((ch = *(fmt++))) { switch (ch) { case '-': p.align_left = 1; 80272d8: 2201 movs r2, #1 p.align_left = 0; p.sign = 0; p.prec = 2; /* Flags */ while ((ch = *(fmt++))) { 80272da: f817 1b01 ldrb.w r1, [r7], #1 80272de: 2900 cmp r1, #0 80272e0: d1e8 bne.n 80272b4 80272e2: f89d 8028 ldrb.w r8, [sp, #40] ; 0x28 80272e6: f88d 3030 strb.w r3, [sp, #48] ; 0x30 80272ea: f36c 0800 bfi r8, ip, #0, #1 80272ee: 46c4 mov ip, r8 80272f0: f360 0c41 bfi ip, r0, #1, #1 80272f4: 4660 mov r0, ip } break; } /* Width */ if (ch >= '0' && ch <= '9') { 80272f6: f1a1 0330 sub.w r3, r1, #48 ; 0x30 80272fa: f362 00c3 bfi r0, r2, #3, #1 80272fe: 2b09 cmp r3, #9 8027300: f88d 0028 strb.w r0, [sp, #40] ; 0x28 8027304: d81d bhi.n 8027342 8027306: e004 b.n 8027312 unsigned int num = 0; int digit; while ((digit = a2d(ch)) >= 0) { if (digit > base) break; num = num * base + digit; 8027308: fb00 3202 mla r2, r0, r2, r3 ch = *p++; 802730c: f817 1b01 ldrb.w r1, [r7], #1 8027310: e001 b.n 8027316 } break; } /* Width */ if (ch >= '0' && ch <= '9') { 8027312: 2200 movs r2, #0 unsigned int num = 0; int digit; while ((digit = a2d(ch)) >= 0) { if (digit > base) break; num = num * base + digit; 8027314: 200a movs r0, #10 ui2a(num, p); } static int a2d(char ch) { if (ch >= '0' && ch <= '9') 8027316: f1a1 0330 sub.w r3, r1, #48 ; 0x30 802731a: fa5f fc83 uxtb.w ip, r3 802731e: f1bc 0f09 cmp.w ip, #9 8027322: d9f1 bls.n 8027308 return ch - '0'; else if (ch >= 'a' && ch <= 'f') 8027324: f1a1 0361 sub.w r3, r1, #97 ; 0x61 8027328: 2b05 cmp r3, #5 802732a: d802 bhi.n 8027332 return ch - 'a' + 10; 802732c: f1a1 0357 sub.w r3, r1, #87 ; 0x57 8027330: e1b5 b.n 802769e else if (ch >= 'A' && ch <= 'F') 8027332: f1a1 0341 sub.w r3, r1, #65 ; 0x41 8027336: 2b05 cmp r3, #5 8027338: d802 bhi.n 8027340 return ch - 'A' + 10; 802733a: f1a1 0337 sub.w r3, r1, #55 ; 0x37 802733e: e1ae b.n 802769e break; num = num * base + digit; ch = *p++; } *src = p; *nump = num; 8027340: 920b str r2, [sp, #44] ; 0x2c } /* We accept 'x.y' format but don't support it completely: * we ignore the 'y' digit => this ignores 0-fill * size and makes it == width (ie. 'x') */ if (ch == '.') { 8027342: 292e cmp r1, #46 ; 0x2e 8027344: d10e bne.n 8027364 //p.lz = 1; /* zero-padding */ /* ignore actual 0-fill size: */ ch = *(fmt++); if (ch >= '0' && ch <= '9') 8027346: 783a ldrb r2, [r7, #0] 8027348: 3a30 subs r2, #48 ; 0x30 802734a: b2d2 uxtb r2, r2 * we ignore the 'y' digit => this ignores 0-fill * size and makes it == width (ie. 'x') */ if (ch == '.') { //p.lz = 1; /* zero-padding */ /* ignore actual 0-fill size: */ ch = *(fmt++); 802734c: 1c7b adds r3, r7, #1 if (ch >= '0' && ch <= '9') 802734e: 2a09 cmp r2, #9 p.prec = ch - '0'; 8027350: bf98 it ls 8027352: f88d 203c strbls.w r2, [sp, #60] ; 0x3c do { ch = *(fmt++); 8027356: f813 1b01 ldrb.w r1, [r3], #1 } while (ch >= '0' && ch <= '9'); 802735a: f1a1 0230 sub.w r2, r1, #48 ; 0x30 802735e: 2a09 cmp r2, #9 ch = *(fmt++); if (ch >= '0' && ch <= '9') p.prec = ch - '0'; do { ch = *(fmt++); 8027360: 461f mov r7, r3 } while (ch >= '0' && ch <= '9'); 8027362: d9f8 bls.n 8027356 } #ifdef PRINTF_SIZE_T_SUPPORT # ifdef PRINTF_LONG_SUPPORT if (ch == 'z') { 8027364: 297a cmp r1, #122 ; 0x7a 8027366: d102 bne.n 802736e ch = *(fmt++); 8027368: f817 1b01 ldrb.w r1, [r7], #1 802736c: e005 b.n 802737a } else # endif #endif #ifdef PRINTF_LONG_SUPPORT if (ch == 'l') { 802736e: 296c cmp r1, #108 ; 0x6c 8027370: d109 bne.n 8027386 ch = *(fmt++); 8027372: 7839 ldrb r1, [r7, #0] lng = 1; #ifdef PRINTF_LONG_LONG_SUPPORT if (ch == 'l') { 8027374: 296c cmp r1, #108 ; 0x6c 8027376: d002 beq.n 802737e # endif #endif #ifdef PRINTF_LONG_SUPPORT if (ch == 'l') { ch = *(fmt++); 8027378: 3701 adds r7, #1 lng = 1; 802737a: 2301 movs r3, #1 802737c: e004 b.n 8027388 #ifdef PRINTF_LONG_LONG_SUPPORT if (ch == 'l') { ch = *(fmt++); 802737e: 7879 ldrb r1, [r7, #1] lng = 2; 8027380: 2302 movs r3, #2 if (ch == 'l') { ch = *(fmt++); lng = 1; #ifdef PRINTF_LONG_LONG_SUPPORT if (ch == 'l') { ch = *(fmt++); 8027382: 3702 adds r7, #2 8027384: e000 b.n 8027388 while ((ch = *(fmt++))) { if (ch != '%') { putf(putp, ch); } else { #ifdef PRINTF_LONG_SUPPORT char lng = 0; /* 1 for long, 2 for long long */ 8027386: 2300 movs r3, #0 lng = 2; } #endif } #endif switch (ch) { 8027388: 2969 cmp r1, #105 ; 0x69 802738a: d036 beq.n 80273fa 802738c: d816 bhi.n 80273bc 802738e: 2963 cmp r1, #99 ; 0x63 8027390: f000 80a1 beq.w 80274d6 8027394: d80c bhi.n 80273b0 8027396: 2946 cmp r1, #70 ; 0x46 8027398: f000 80b3 beq.w 8027502 802739c: d806 bhi.n 80273ac 802739e: 2900 cmp r1, #0 80273a0: f000 8181 beq.w 80276a6 80273a4: 2925 cmp r1, #37 ; 0x25 80273a6: f040 8174 bne.w 8027692 80273aa: e0a7 b.n 80274fc 80273ac: 2958 cmp r1, #88 ; 0x58 80273ae: e012 b.n 80273d6 80273b0: 2964 cmp r1, #100 ; 0x64 80273b2: d022 beq.n 80273fa 80273b4: 2966 cmp r1, #102 ; 0x66 80273b6: f040 816c bne.w 8027692 80273ba: e0a2 b.n 8027502 80273bc: 2973 cmp r1, #115 ; 0x73 80273be: f000 8090 beq.w 80274e2 80273c2: d805 bhi.n 80273d0 80273c4: 296f cmp r1, #111 ; 0x6f 80273c6: d078 beq.n 80274ba 80273c8: 2970 cmp r1, #112 ; 0x70 80273ca: f040 8162 bne.w 8027692 80273ce: e040 b.n 8027452 80273d0: 2975 cmp r1, #117 ; 0x75 80273d2: d003 beq.n 80273dc 80273d4: 2978 cmp r1, #120 ; 0x78 80273d6: f040 815c bne.w 8027692 80273da: e041 b.n 8027460 case 0: goto abort; case 'u': p.base = 10; 80273dc: 220a movs r2, #10 #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 80273de: 2b02 cmp r3, #2 #endif switch (ch) { case 0: goto abort; case 'u': p.base = 10; 80273e0: 920d str r2, [sp, #52] ; 0x34 #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 80273e2: d107 bne.n 80273f4 ulli2a(va_arg(va, unsigned long long int), &p); 80273e4: 3407 adds r4, #7 80273e6: f024 0307 bic.w r3, r4, #7 80273ea: f103 0408 add.w r4, r3, #8 80273ee: e9d3 0100 ldrd r0, r1, [r3] 80273f2: e017 b.n 8027424 else #endif if (1 == lng) uli2a(va_arg(va, unsigned long int), &p); 80273f4: 6820 ldr r0, [r4, #0] 80273f6: a90a add r1, sp, #40 ; 0x28 80273f8: e04f b.n 802749a ui2a(va_arg(va, unsigned int), &p); putchw(putp, putf, &p); break; case 'd': case 'i': p.base = 10; 80273fa: 220a movs r2, #10 #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 80273fc: 2b02 cmp r3, #2 ui2a(va_arg(va, unsigned int), &p); putchw(putp, putf, &p); break; case 'd': case 'i': p.base = 10; 80273fe: 920d str r2, [sp, #52] ; 0x34 #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 8027400: d112 bne.n 8027428 lli2a(va_arg(va, long long int), &p); 8027402: 3407 adds r4, #7 8027404: f024 0307 bic.w r3, r4, #7 8027408: e9d3 0100 ldrd r0, r1, [r3] 802740c: f103 0408 add.w r4, r3, #8 *bf = 0; } static void lli2a(long long int num, struct param *p) { if (num < 0) { 8027410: 2800 cmp r0, #0 8027412: f171 0300 sbcs.w r3, r1, #0 8027416: da05 bge.n 8027424 num = -num; p->sign = '-'; 8027418: 232d movs r3, #45 ; 0x2d } static void lli2a(long long int num, struct param *p) { if (num < 0) { num = -num; 802741a: 4240 negs r0, r0 802741c: eb61 0141 sbc.w r1, r1, r1, lsl #1 p->sign = '-'; 8027420: f88d 3030 strb.w r3, [sp, #48] ; 0x30 } ulli2a(num, p); 8027424: aa0a add r2, sp, #40 ; 0x28 8027426: e033 b.n 8027490 #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) lli2a(va_arg(va, long long int), &p); else #endif if (1 == lng) 8027428: 2b01 cmp r3, #1 li2a(va_arg(va, long int), &p); 802742a: 6820 ldr r0, [r4, #0] 802742c: f104 0804 add.w r8, r4, #4 #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) lli2a(va_arg(va, long long int), &p); else #endif if (1 == lng) 8027430: d107 bne.n 8027442 *bf = 0; } static void li2a(long num, struct param *p) { if (num < 0) { 8027432: 2800 cmp r0, #0 8027434: da03 bge.n 802743e num = -num; p->sign = '-'; 8027436: 232d movs r3, #45 ; 0x2d } static void li2a(long num, struct param *p) { if (num < 0) { num = -num; 8027438: 4240 negs r0, r0 p->sign = '-'; 802743a: f88d 3030 strb.w r3, [sp, #48] ; 0x30 } uli2a(num, p); 802743e: a90a add r1, sp, #40 ; 0x28 8027440: e02f b.n 80274a2 *bf = 0; } static void i2a(int num, struct param *p) { if (num < 0) { 8027442: 2800 cmp r0, #0 8027444: da03 bge.n 802744e num = -num; p->sign = '-'; 8027446: 232d movs r3, #45 ; 0x2d } static void i2a(int num, struct param *p) { if (num < 0) { num = -num; 8027448: 4240 negs r0, r0 p->sign = '-'; 802744a: f88d 3030 strb.w r3, [sp, #48] ; 0x30 } ui2a(num, p); 802744e: a90a add r1, sp, #40 ; 0x28 8027450: e02a b.n 80274a8 i2a(va_arg(va, int), &p); putchw(putp, putf, &p); break; #ifdef SIZEOF_POINTER case 'p': p.alt = 1; 8027452: f89d 3028 ldrb.w r3, [sp, #40] ; 0x28 8027456: f043 0302 orr.w r3, r3, #2 802745a: f88d 3028 strb.w r3, [sp, #40] ; 0x28 # if defined(SIZEOF_INT) && SIZEOF_POINTER <= SIZEOF_INT lng = 0; 802745e: 2300 movs r3, #0 lng = 2; # endif #endif case 'x': case 'X': p.base = 16; 8027460: 2210 movs r2, #16 p.uc = (ch == 'X')?1:0; 8027462: f1b1 0e58 subs.w lr, r1, #88 ; 0x58 8027466: f1de 0100 rsbs r1, lr, #0 802746a: f89d 0028 ldrb.w r0, [sp, #40] ; 0x28 lng = 2; # endif #endif case 'x': case 'X': p.base = 16; 802746e: 920d str r2, [sp, #52] ; 0x34 p.uc = (ch == 'X')?1:0; 8027470: eb51 010e adcs.w r1, r1, lr 8027474: aa1a add r2, sp, #104 ; 0x68 8027476: f361 0082 bfi r0, r1, #2, #1 #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 802747a: 2b02 cmp r3, #2 # endif #endif case 'x': case 'X': p.base = 16; p.uc = (ch == 'X')?1:0; 802747c: f802 0d40 strb.w r0, [r2, #-64]! #ifdef PRINTF_LONG_SUPPORT #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) 8027480: d109 bne.n 8027496 ulli2a(va_arg(va, unsigned long long int), &p); 8027482: 3407 adds r4, #7 8027484: f024 0307 bic.w r3, r4, #7 8027488: e9d3 0100 ldrd r0, r1, [r3] 802748c: f103 0408 add.w r4, r3, #8 8027490: f7ff fdbe bl 8027010 8027494: e00b b.n 80274ae else #endif if (1 == lng) uli2a(va_arg(va, unsigned long int), &p); 8027496: 6820 ldr r0, [r4, #0] 8027498: 4611 mov r1, r2 #ifdef PRINTF_LONG_LONG_SUPPORT if (2 == lng) ulli2a(va_arg(va, unsigned long long int), &p); else #endif if (1 == lng) 802749a: 2b01 cmp r3, #1 802749c: f104 0804 add.w r8, r4, #4 80274a0: d102 bne.n 80274a8 uli2a(va_arg(va, unsigned long int), &p); 80274a2: f7ff fe0b bl 80270bc 80274a6: e001 b.n 80274ac else #endif ui2a(va_arg(va, unsigned int), &p); 80274a8: f7ff fe33 bl 8027112 80274ac: 4644 mov r4, r8 putchw(putp, putf, &p); 80274ae: 4628 mov r0, r5 80274b0: 4631 mov r1, r6 80274b2: aa0a add r2, sp, #40 ; 0x28 80274b4: f7ff fe58 bl 8027168 break; 80274b8: e0eb b.n 8027692 case 'o': p.base = 8; 80274ba: 2308 movs r3, #8 ui2a(va_arg(va, unsigned int), &p); 80274bc: 6820 ldr r0, [r4, #0] #endif ui2a(va_arg(va, unsigned int), &p); putchw(putp, putf, &p); break; case 'o': p.base = 8; 80274be: 930d str r3, [sp, #52] ; 0x34 ui2a(va_arg(va, unsigned int), &p); 80274c0: a90a add r1, sp, #40 ; 0x28 80274c2: f7ff fe26 bl 8027112 putchw(putp, putf, &p); 80274c6: 4628 mov r0, r5 80274c8: 4631 mov r1, r6 80274ca: aa0a add r2, sp, #40 ; 0x28 ui2a(va_arg(va, unsigned int), &p); putchw(putp, putf, &p); break; case 'o': p.base = 8; ui2a(va_arg(va, unsigned int), &p); 80274cc: f104 0804 add.w r8, r4, #4 putchw(putp, putf, &p); 80274d0: f7ff fe4a bl 8027168 80274d4: e010 b.n 80274f8 break; case 'c': putf(putp, (char)(va_arg(va, int))); 80274d6: 4628 mov r0, r5 80274d8: 7821 ldrb r1, [r4, #0] 80274da: f104 0804 add.w r8, r4, #4 80274de: 47b0 blx r6 80274e0: e00a b.n 80274f8 break; case 's': p.bf = va_arg(va, char *); 80274e2: 6823 ldr r3, [r4, #0] putchw(putp, putf, &p); 80274e4: aa0a add r2, sp, #40 ; 0x28 80274e6: 4628 mov r0, r5 80274e8: 4631 mov r1, r6 break; case 'c': putf(putp, (char)(va_arg(va, int))); break; case 's': p.bf = va_arg(va, char *); 80274ea: 930e str r3, [sp, #56] ; 0x38 putchw(putp, putf, &p); 80274ec: f7ff fe3c bl 8027168 p.bf = bf; 80274f0: aa04 add r2, sp, #16 break; case 'c': putf(putp, (char)(va_arg(va, int))); break; case 's': p.bf = va_arg(va, char *); 80274f2: f104 0804 add.w r8, r4, #4 putchw(putp, putf, &p); p.bf = bf; 80274f6: 920e str r2, [sp, #56] ; 0x38 break; case 'c': putf(putp, (char)(va_arg(va, int))); break; case 's': p.bf = va_arg(va, char *); 80274f8: 4644 mov r4, r8 putchw(putp, putf, &p); p.bf = bf; break; 80274fa: e0ca b.n 8027692 case '%': putf(putp, ch); 80274fc: 4628 mov r0, r5 80274fe: 47b0 blx r6 break; 8027500: e0c7 b.n 8027692 case 'f': case 'F': fval = va_arg(va, double); 8027502: 3407 adds r4, #7 8027504: f024 0307 bic.w r3, r4, #7 8027508: f103 0408 add.w r4, r3, #8 802750c: e893 0404 ldmia.w r3, {r2, sl} 8027510: 9200 str r2, [sp, #0] sign = 0; if (fval < 0) 8027512: 4610 mov r0, r2 8027514: 4651 mov r1, sl 8027516: 2200 movs r2, #0 8027518: 2300 movs r3, #0 802751a: f7f9 fac3 bl 8020aa4 <__aeabi_dcmplt> 802751e: b138 cbz r0, 8027530 { sign = 1; p.width--; 8027520: 9b0b ldr r3, [sp, #44] ; 0x2c 8027522: 3b01 subs r3, #1 8027524: 930b str r3, [sp, #44] ; 0x2c fval = - fval; 8027526: f10a 4a00 add.w sl, sl, #2147483648 ; 0x80000000 case 'F': fval = va_arg(va, double); sign = 0; if (fval < 0) { sign = 1; 802752a: f04f 0b01 mov.w fp, #1 802752e: e009 b.n 8027544 p.width--; fval = - fval; } else if (p.sign) { 8027530: f89d 3030 ldrb.w r3, [sp, #48] ; 0x30 8027534: b12b cbz r3, 8027542 sign = 2; p.width--; 8027536: 9b0b ldr r3, [sp, #44] ; 0x2c 8027538: 3b01 subs r3, #1 802753a: 930b str r3, [sp, #44] ; 0x2c sign = 1; p.width--; fval = - fval; } else if (p.sign) { sign = 2; 802753c: f04f 0b02 mov.w fp, #2 8027540: e000 b.n 8027544 putf(putp, ch); break; case 'f': case 'F': fval = va_arg(va, double); sign = 0; 8027542: 469b mov fp, r3 else if (p.sign) { sign = 2; p.width--; } fpart = (int)fval; 8027544: 4651 mov r1, sl 8027546: 9800 ldr r0, [sp, #0] 8027548: f7f9 fad4 bl 8020af4 <__aeabi_d2iz> fiter = 0; 802754c: 2200 movs r2, #0 else if (p.sign) { sign = 2; p.width--; } fpart = (int)fval; 802754e: 9001 str r0, [sp, #4] 8027550: 4680 mov r8, r0 fiter = 0; while (fpart != 0) { temp_buffer[fiter++] = fpart % 10; 8027552: 210a movs r1, #10 } fpart = (int)fval; fiter = 0; while (fpart != 0) 8027554: e008 b.n 8027568 { temp_buffer[fiter++] = fpart % 10; 8027556: fb98 f0f1 sdiv r0, r8, r1 802755a: ab10 add r3, sp, #64 ; 0x40 802755c: fb01 8810 mls r8, r1, r0, r8 8027560: f843 8022 str.w r8, [r3, r2, lsl #2] 8027564: 3201 adds r2, #1 fpart = fpart / 10; 8027566: 4680 mov r8, r0 } fpart = (int)fval; fiter = 0; while (fpart != 0) 8027568: f1b8 0f00 cmp.w r8, #0 802756c: d1f3 bne.n 8027556 temp_buffer[fiter++] = fpart % 10; fpart = fpart / 10; } fiter--; if (fiter == -1) 802756e: f102 39ff add.w r9, r2, #4294967295 8027572: b912 cbnz r2, 802757a p.width--; 8027574: 9a0b ldr r2, [sp, #44] ; 0x2c 8027576: 3a01 subs r2, #1 8027578: 920b str r2, [sp, #44] ; 0x2c /* Leading zeros */ if (p.lz) { 802757a: f89d 2028 ldrb.w r2, [sp, #40] ; 0x28 802757e: 07d0 lsls r0, r2, #31 8027580: d51b bpl.n 80275ba if (sign == 1) 8027582: f1bb 0f01 cmp.w fp, #1 8027586: d102 bne.n 802758e putf(putp, '-'); 8027588: 4628 mov r0, r5 802758a: 212d movs r1, #45 ; 0x2d 802758c: e007 b.n 802759e else if (sign == 2) 802758e: f1bb 0f02 cmp.w fp, #2 8027592: d105 bne.n 80275a0 putf(putp, '+'); 8027594: 4628 mov r0, r5 8027596: 212b movs r1, #43 ; 0x2b 8027598: e001 b.n 802759e while (p.width-- > p.prec + fiter + 2) { putf(putp, '0'); 802759a: 4628 mov r0, r5 802759c: 2130 movs r1, #48 ; 0x30 802759e: 47b0 blx r6 if (sign == 1) putf(putp, '-'); else if (sign == 2) putf(putp, '+'); while (p.width-- > p.prec + fiter + 2) 80275a0: f89d 203c ldrb.w r2, [sp, #60] ; 0x3c 80275a4: 9b0b ldr r3, [sp, #44] ; 0x2c 80275a6: 444a add r2, r9 80275a8: 3202 adds r2, #2 80275aa: 1e59 subs r1, r3, #1 80275ac: 4293 cmp r3, r2 80275ae: 910b str r1, [sp, #44] ; 0x2c 80275b0: dcf3 bgt.n 802759a 80275b2: e017 b.n 80275e4 else { while (p.width-- > p.prec + fiter + 2) { putf(putp, ' '); 80275b4: 4628 mov r0, r5 80275b6: 2120 movs r1, #32 80275b8: 47b0 blx r6 } } else { while (p.width-- > p.prec + fiter + 2) 80275ba: f89d 103c ldrb.w r1, [sp, #60] ; 0x3c 80275be: 9a0b ldr r2, [sp, #44] ; 0x2c 80275c0: 4449 add r1, r9 80275c2: 3102 adds r1, #2 80275c4: 1e50 subs r0, r2, #1 80275c6: 428a cmp r2, r1 80275c8: 900b str r0, [sp, #44] ; 0x2c 80275ca: dcf3 bgt.n 80275b4 { putf(putp, ' '); } if (sign == 1) 80275cc: f1bb 0f01 cmp.w fp, #1 80275d0: d102 bne.n 80275d8 putf(putp, '-'); 80275d2: 4628 mov r0, r5 80275d4: 212d movs r1, #45 ; 0x2d 80275d6: e004 b.n 80275e2 else if (sign == 2) 80275d8: f1bb 0f02 cmp.w fp, #2 80275dc: d102 bne.n 80275e4 putf(putp, '+'); 80275de: 4628 mov r0, r5 80275e0: 212b movs r1, #43 ; 0x2b 80275e2: 47b0 blx r6 } if (fiter == -1) 80275e4: f1b9 3fff cmp.w r9, #4294967295 80275e8: d102 bne.n 80275f0 putf(putp, '0'); 80275ea: 4628 mov r0, r5 80275ec: 2130 movs r1, #48 ; 0x30 80275ee: e007 b.n 8027600 while (fiter > -1) { putf(putp, '0' + (temp_buffer[fiter--])); 80275f0: ab10 add r3, sp, #64 ; 0x40 80275f2: 4628 mov r0, r5 80275f4: f853 1029 ldr.w r1, [r3, r9, lsl #2] 80275f8: 3130 adds r1, #48 ; 0x30 80275fa: f109 39ff add.w r9, r9, #4294967295 80275fe: b2c9 uxtb r1, r1 8027600: 47b0 blx r6 } if (fiter == -1) putf(putp, '0'); while (fiter > -1) 8027602: f1b9 3fff cmp.w r9, #4294967295 8027606: d1f3 bne.n 80275f0 { putf(putp, '0' + (temp_buffer[fiter--])); } putf(putp, '.'); 8027608: 4628 mov r0, r5 802760a: 212e movs r1, #46 ; 0x2e 802760c: 47b0 blx r6 ffactor = 1; 802760e: f04f 0901 mov.w r9, #1 while (p.prec-- > 0) 8027612: e01d b.n 8027650 { ffactor *= 10; 8027614: 230a movs r3, #10 fpart = (int)((fval - (int)fval)*ffactor); 8027616: 9801 ldr r0, [sp, #4] putf(putp, '.'); ffactor = 1; while (p.prec-- > 0) { ffactor *= 10; 8027618: fb03 f909 mul.w r9, r3, r9 fpart = (int)((fval - (int)fval)*ffactor); 802761c: f7f8 ff6a bl 80204f4 <__aeabi_i2d> 8027620: 4602 mov r2, r0 8027622: 460b mov r3, r1 8027624: 9800 ldr r0, [sp, #0] 8027626: 4651 mov r1, sl 8027628: f7f8 fe16 bl 8020258 <__aeabi_dsub> 802762c: e9cd 0102 strd r0, r1, [sp, #8] 8027630: 4648 mov r0, r9 8027632: f7f8 ff5f bl 80204f4 <__aeabi_i2d> 8027636: 4602 mov r2, r0 8027638: 460b mov r3, r1 802763a: e9dd 0102 ldrd r0, r1, [sp, #8] 802763e: f7f8 ffbf bl 80205c0 <__aeabi_dmul> 8027642: f7f9 fa57 bl 8020af4 <__aeabi_d2iz> if (fpart == 0) 8027646: 4680 mov r8, r0 8027648: b910 cbnz r0, 8027650 putf(putp, '0'); 802764a: 4628 mov r0, r5 802764c: 2130 movs r1, #48 ; 0x30 802764e: 47b0 blx r6 putf(putp, '0' + (temp_buffer[fiter--])); } putf(putp, '.'); ffactor = 1; while (p.prec-- > 0) 8027650: f89d 303c ldrb.w r3, [sp, #60] ; 0x3c 8027654: 1e5a subs r2, r3, #1 8027656: f88d 203c strb.w r2, [sp, #60] ; 0x3c 802765a: 2b00 cmp r3, #0 802765c: d1da bne.n 8027614 putf(putp, '0'); } fiter = 0; while (fpart != 0) { temp_buffer[fiter++] = fpart % 10; 802765e: 220a movs r2, #10 8027660: e008 b.n 8027674 8027662: fb98 f1f2 sdiv r1, r8, r2 8027666: a810 add r0, sp, #64 ; 0x40 8027668: fb02 8811 mls r8, r2, r1, r8 802766c: f840 8023 str.w r8, [r0, r3, lsl #2] 8027670: 3301 adds r3, #1 fpart = fpart / 10; 8027672: 4688 mov r8, r1 fpart = (int)((fval - (int)fval)*ffactor); if (fpart == 0) putf(putp, '0'); } fiter = 0; while (fpart != 0) 8027674: f1b8 0f00 cmp.w r8, #0 8027678: d1f3 bne.n 8027662 802767a: 4698 mov r8, r3 temp_buffer[fiter++] = fpart % 10; fpart = fpart / 10; } fiter--; while (fiter > -1) 802767c: e006 b.n 802768c { putf(putp, '0' + (temp_buffer[fiter--])); 802767e: ab10 add r3, sp, #64 ; 0x40 8027680: 4628 mov r0, r5 8027682: f853 1028 ldr.w r1, [r3, r8, lsl #2] 8027686: 3130 adds r1, #48 ; 0x30 8027688: b2c9 uxtb r1, r1 802768a: 47b0 blx r6 temp_buffer[fiter++] = fpart % 10; fpart = fpart / 10; } fiter--; while (fiter > -1) 802768c: f118 38ff adds.w r8, r8, #4294967295 8027690: d2f5 bcs.n 802767e char bf[12]; /* int = 32b on some architectures */ #endif char ch; p.bf = bf; while ((ch = *(fmt++))) { 8027692: f817 1b01 ldrb.w r1, [r7], #1 8027696: 2900 cmp r1, #0 8027698: f47f adf2 bne.w 8027280 802769c: e003 b.n 80276a6 { const char *p = *src; unsigned int num = 0; int digit; while ((digit = a2d(ch)) >= 0) { if (digit > base) 802769e: 2b0a cmp r3, #10 80276a0: f77f ae32 ble.w 8027308 80276a4: e64c b.n 8027340 break; } } } abort:; } 80276a6: b01b add sp, #108 ; 0x6c 80276a8: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 080276ac : stdout_putf = putf; stdout_putp = putp; } void tfp_printf(char *fmt, ...) { 80276ac: b40f push {r0, r1, r2, r3} 80276ae: b507 push {r0, r1, r2, lr} va_list va; va_start(va, fmt); tfp_format(stdout_putp, stdout_putf, fmt, va); 80276b0: 4906 ldr r1, [pc, #24] ; (80276cc ) stdout_putf = putf; stdout_putp = putp; } void tfp_printf(char *fmt, ...) { 80276b2: ab04 add r3, sp, #16 va_list va; va_start(va, fmt); tfp_format(stdout_putp, stdout_putf, fmt, va); 80276b4: 6808 ldr r0, [r1, #0] 80276b6: 4906 ldr r1, [pc, #24] ; (80276d0 ) stdout_putf = putf; stdout_putp = putp; } void tfp_printf(char *fmt, ...) { 80276b8: f853 2b04 ldr.w r2, [r3], #4 va_list va; va_start(va, fmt); tfp_format(stdout_putp, stdout_putf, fmt, va); 80276bc: 6809 ldr r1, [r1, #0] } void tfp_printf(char *fmt, ...) { va_list va; va_start(va, fmt); 80276be: 9301 str r3, [sp, #4] tfp_format(stdout_putp, stdout_putf, fmt, va); 80276c0: f7ff fdd4 bl 802726c va_end(va); } 80276c4: e8bd 400e ldmia.w sp!, {r1, r2, r3, lr} 80276c8: b004 add sp, #16 80276ca: 4770 bx lr 80276cc: 200028a8 .word 0x200028a8 80276d0: 200028a4 .word 0x200028a4 080276d4 : data->dest[data->num_chars] = c; data->num_chars ++; } int tfp_vsnprintf(char *str, size_t size, const char *format, va_list ap) { 80276d4: b51f push {r0, r1, r2, r3, r4, lr} 80276d6: 2400 movs r4, #0 struct _vsnprintf_putcf_data data; if (size < 1) 80276d8: b181 cbz r1, 80276fc return 0; data.dest = str; data.dest_capacity = size-1; 80276da: 3901 subs r1, #1 struct _vsnprintf_putcf_data data; if (size < 1) return 0; data.dest = str; 80276dc: 9002 str r0, [sp, #8] data.dest_capacity = size-1; 80276de: 9101 str r1, [sp, #4] data.num_chars = 0; tfp_format(&data, _vsnprintf_putcf, format, ap); 80276e0: a801 add r0, sp, #4 80276e2: 4908 ldr r1, [pc, #32] ; (8027704 ) if (size < 1) return 0; data.dest = str; data.dest_capacity = size-1; data.num_chars = 0; 80276e4: 9403 str r4, [sp, #12] tfp_format(&data, _vsnprintf_putcf, format, ap); 80276e6: f7ff fdc1 bl 802726c if (data.num_chars < data.dest_capacity) 80276ea: 9903 ldr r1, [sp, #12] 80276ec: 9b01 ldr r3, [sp, #4] 80276ee: 9a02 ldr r2, [sp, #8] 80276f0: 4299 cmp r1, r3 data.dest[data.num_chars] = '\0'; 80276f2: bf34 ite cc 80276f4: 5454 strbcc r4, [r2, r1] else data.dest[data.dest_capacity] = '\0'; 80276f6: 54d4 strbcs r4, [r2, r3] return data.num_chars; 80276f8: 9803 ldr r0, [sp, #12] 80276fa: e000 b.n 80276fe int tfp_vsnprintf(char *str, size_t size, const char *format, va_list ap) { struct _vsnprintf_putcf_data data; if (size < 1) return 0; 80276fc: 4608 mov r0, r1 data.dest[data.num_chars] = '\0'; else data.dest[data.dest_capacity] = '\0'; return data.num_chars; } 80276fe: b004 add sp, #16 8027700: bd10 pop {r4, pc} 8027702: bf00 nop 8027704: 0802724d .word 0x0802724d 08027708 : int tfp_snprintf(char *str, size_t size, const char *format, ...) { 8027708: b40c push {r2, r3} 802770a: b507 push {r0, r1, r2, lr} 802770c: ab04 add r3, sp, #16 802770e: f853 2b04 ldr.w r2, [r3], #4 va_list ap; int retval; va_start(ap, format); 8027712: 9301 str r3, [sp, #4] retval = tfp_vsnprintf(str, size, format, ap); 8027714: f7ff ffde bl 80276d4 va_end(ap); return retval; } 8027718: e8bd 400e ldmia.w sp!, {r1, r2, r3, lr} 802771c: b002 add sp, #8 802771e: 4770 bx lr 08027720 : struct _vsprintf_putcf_data *data = (struct _vsprintf_putcf_data*)p; data->dest[data->num_chars++] = c; } int tfp_vsprintf(char *str, const char *format, va_list ap) { 8027720: b537 push {r0, r1, r2, r4, r5, lr} 8027722: 460d mov r5, r1 8027724: 4613 mov r3, r2 struct _vsprintf_putcf_data data; data.dest = str; 8027726: 9000 str r0, [sp, #0] data.num_chars = 0; 8027728: 2400 movs r4, #0 tfp_format(&data, _vsprintf_putcf, format, ap); 802772a: 4668 mov r0, sp 802772c: 462a mov r2, r5 802772e: 4904 ldr r1, [pc, #16] ; (8027740 ) int tfp_vsprintf(char *str, const char *format, va_list ap) { struct _vsprintf_putcf_data data; data.dest = str; data.num_chars = 0; 8027730: 9401 str r4, [sp, #4] tfp_format(&data, _vsprintf_putcf, format, ap); 8027732: f7ff fd9b bl 802726c data.dest[data.num_chars] = '\0'; 8027736: e89d 000c ldmia.w sp, {r2, r3} 802773a: 54d4 strb r4, [r2, r3] return data.num_chars; } 802773c: 9801 ldr r0, [sp, #4] 802773e: bd3e pop {r1, r2, r3, r4, r5, pc} 8027740: 08027261 .word 0x08027261 08027744 : int tfp_sprintf(char *str, const char *format, ...) { 8027744: b40e push {r1, r2, r3} 8027746: b503 push {r0, r1, lr} 8027748: aa03 add r2, sp, #12 802774a: f852 1b04 ldr.w r1, [r2], #4 va_list ap; int retval; va_start(ap, format); 802774e: 9201 str r2, [sp, #4] retval = tfp_vsprintf(str, format, ap); 8027750: f7ff ffe6 bl 8027720 va_end(ap); return retval; } 8027754: e8bd 400c ldmia.w sp!, {r2, r3, lr} 8027758: b003 add sp, #12 802775a: 4770 bx lr 0802775c : /* if (upsParams.lineFailBit) *str = '1'; else *str = '0';*/ *str = '0'; 802775c: 2330 movs r3, #48 ; 0x30 802775e: 7003 strb r3, [r0, #0] *len = 1; 8027760: 2301 movs r3, #1 8027762: 700b strb r3, [r1, #0] 8027764: 4770 bx lr 08027766 : *str = '1'; else *str = '0'; *len = 1;*/ *str = '0'; 8027766: 2330 movs r3, #48 ; 0x30 8027768: 7003 strb r3, [r0, #0] *len = 1; 802776a: 2301 movs r3, #1 802776c: 700b strb r3, [r1, #0] 802776e: 4770 bx lr 08027770 : /** * @brief */ void GetInputFreqStr(char *str, uint8_t *len) { 8027770: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.Freq_in); 8027772: 4b08 ldr r3, [pc, #32] ; (8027794 ) /** * @brief */ void GetInputFreqStr(char *str, uint8_t *len) { 8027774: 4604 mov r4, r0 sprintf(str, "%0.1f", UPS.Freq_in); 8027776: 6818 ldr r0, [r3, #0] /** * @brief */ void GetInputFreqStr(char *str, uint8_t *len) { 8027778: 460d mov r5, r1 sprintf(str, "%0.1f", UPS.Freq_in); 802777a: f7f8 fecd bl 8020518 <__aeabi_f2d> 802777e: 4602 mov r2, r0 8027780: 460b mov r3, r1 8027782: 4620 mov r0, r4 8027784: 4904 ldr r1, [pc, #16] ; (8027798 ) 8027786: f7ff ffdd bl 8027744 *len = strlen(str); 802778a: 4620 mov r0, r4 802778c: f7fa fb70 bl 8021e70 8027790: 7028 strb r0, [r5, #0] 8027792: bd38 pop {r3, r4, r5, pc} 8027794: 2000e8b4 .word 0x2000e8b4 8027798: 08035e4f .word 0x08035e4f 0802779c : /** * @brief */ void GetOutputFreqStr(char *str, uint8_t *len) { 802779c: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.Freq_in); 802779e: 4b08 ldr r3, [pc, #32] ; (80277c0 ) /** * @brief */ void GetOutputFreqStr(char *str, uint8_t *len) { 80277a0: 4604 mov r4, r0 sprintf(str, "%0.1f", UPS.Freq_in); 80277a2: 6818 ldr r0, [r3, #0] /** * @brief */ void GetOutputFreqStr(char *str, uint8_t *len) { 80277a4: 460d mov r5, r1 sprintf(str, "%0.1f", UPS.Freq_in); 80277a6: f7f8 feb7 bl 8020518 <__aeabi_f2d> 80277aa: 4602 mov r2, r0 80277ac: 460b mov r3, r1 80277ae: 4620 mov r0, r4 80277b0: 4904 ldr r1, [pc, #16] ; (80277c4 ) 80277b2: f7ff ffc7 bl 8027744 *len = strlen(str); 80277b6: 4620 mov r0, r4 80277b8: f7fa fb5a bl 8021e70 80277bc: 7028 strb r0, [r5, #0] 80277be: bd38 pop {r3, r4, r5, pc} 80277c0: 2000e8b4 .word 0x2000e8b4 80277c4: 08035e4f .word 0x08035e4f 080277c8 : /** * @brief */ void GetInputVoltageStr(char *str, uint8_t *len) { 80277c8: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.VAC_in); 80277ca: 4b08 ldr r3, [pc, #32] ; (80277ec ) /** * @brief */ void GetInputVoltageStr(char *str, uint8_t *len) { 80277cc: 4604 mov r4, r0 sprintf(str, "%0.1f", UPS.VAC_in); 80277ce: 6858 ldr r0, [r3, #4] /** * @brief */ void GetInputVoltageStr(char *str, uint8_t *len) { 80277d0: 460d mov r5, r1 sprintf(str, "%0.1f", UPS.VAC_in); 80277d2: f7f8 fea1 bl 8020518 <__aeabi_f2d> 80277d6: 4602 mov r2, r0 80277d8: 460b mov r3, r1 80277da: 4620 mov r0, r4 80277dc: 4904 ldr r1, [pc, #16] ; (80277f0 ) 80277de: f7ff ffb1 bl 8027744 *len = strlen(str); 80277e2: 4620 mov r0, r4 80277e4: f7fa fb44 bl 8021e70 80277e8: 7028 strb r0, [r5, #0] 80277ea: bd38 pop {r3, r4, r5, pc} 80277ec: 2000e8b4 .word 0x2000e8b4 80277f0: 08035e4f .word 0x08035e4f 080277f4 : /** * @brief */ void GetOutputVoltageStr(char *str, uint8_t *len) { 80277f4: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.VAC_out); 80277f6: 4b08 ldr r3, [pc, #32] ; (8027818 ) /** * @brief */ void GetOutputVoltageStr(char *str, uint8_t *len) { 80277f8: 4604 mov r4, r0 sprintf(str, "%0.1f", UPS.VAC_out); 80277fa: 6898 ldr r0, [r3, #8] /** * @brief */ void GetOutputVoltageStr(char *str, uint8_t *len) { 80277fc: 460d mov r5, r1 sprintf(str, "%0.1f", UPS.VAC_out); 80277fe: f7f8 fe8b bl 8020518 <__aeabi_f2d> 8027802: 4602 mov r2, r0 8027804: 460b mov r3, r1 8027806: 4620 mov r0, r4 8027808: 4904 ldr r1, [pc, #16] ; (802781c ) 802780a: f7ff ff9b bl 8027744 *len = strlen(str); 802780e: 4620 mov r0, r4 8027810: f7fa fb2e bl 8021e70 8027814: 7028 strb r0, [r5, #0] 8027816: bd38 pop {r3, r4, r5, pc} 8027818: 2000e8b4 .word 0x2000e8b4 802781c: 08035e4f .word 0x08035e4f 08027820 : /** * @brief */ void GetPowerStr(char *str, uint8_t *len) { 8027820: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.Load); 8027822: 4b06 ldr r3, [pc, #24] ; (802783c ) /** * @brief */ void GetPowerStr(char *str, uint8_t *len) { 8027824: 4605 mov r5, r0 8027826: 460c mov r4, r1 sprintf(str, "%0.1f", UPS.Load); 8027828: 7c1a ldrb r2, [r3, #16] 802782a: 4905 ldr r1, [pc, #20] ; (8027840 ) 802782c: f7ff ff8a bl 8027744 *len = strlen(str); 8027830: 4628 mov r0, r5 8027832: f7fa fb1d bl 8021e70 8027836: 7020 strb r0, [r4, #0] 8027838: bd38 pop {r3, r4, r5, pc} 802783a: bf00 nop 802783c: 2000e8b4 .word 0x2000e8b4 8027840: 08035e4f .word 0x08035e4f 08027844 : /** * @brief */ void GetBatCapacityStr(char *str, uint8_t *len) { 8027844: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.SOC); 8027846: 4b06 ldr r3, [pc, #24] ; (8027860 ) /** * @brief */ void GetBatCapacityStr(char *str, uint8_t *len) { 8027848: 4605 mov r5, r0 802784a: 460c mov r4, r1 sprintf(str, "%0.1f", UPS.SOC); 802784c: 7c5a ldrb r2, [r3, #17] 802784e: 4905 ldr r1, [pc, #20] ; (8027864 ) 8027850: f7ff ff78 bl 8027744 *len = strlen(str); 8027854: 4628 mov r0, r5 8027856: f7fa fb0b bl 8021e70 802785a: 7020 strb r0, [r4, #0] 802785c: bd38 pop {r3, r4, r5, pc} 802785e: bf00 nop 8027860: 2000e8b4 .word 0x2000e8b4 8027864: 08035e4f .word 0x08035e4f 08027868 : /** * @brief */ void GetRuntimeStr(char *str, uint8_t *len) { 8027868: b538 push {r3, r4, r5, lr} sprintf(str, "%d", UPS.work_time); 802786a: 4b06 ldr r3, [pc, #24] ; (8027884 ) /** * @brief */ void GetRuntimeStr(char *str, uint8_t *len) { 802786c: 4605 mov r5, r0 802786e: 460c mov r4, r1 sprintf(str, "%d", UPS.work_time); 8027870: 7c9a ldrb r2, [r3, #18] 8027872: 4905 ldr r1, [pc, #20] ; (8027888 ) 8027874: f7ff ff66 bl 8027744 *len = strlen(str); 8027878: 4628 mov r0, r5 802787a: f7fa faf9 bl 8021e70 802787e: 7020 strb r0, [r4, #0] 8027880: bd38 pop {r3, r4, r5, pc} 8027882: bf00 nop 8027884: 2000e8b4 .word 0x2000e8b4 8027888: 08035e55 .word 0x08035e55 0802788c : /** * @brief */ void GetInternalTempStr(char *str, uint8_t *len) { 802788c: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", UPS.Temp); 802788e: 4b08 ldr r3, [pc, #32] ; (80278b0 ) /** * @brief */ void GetInternalTempStr(char *str, uint8_t *len) { 8027890: 4604 mov r4, r0 sprintf(str, "%0.1f", UPS.Temp); 8027892: 68d8 ldr r0, [r3, #12] /** * @brief */ void GetInternalTempStr(char *str, uint8_t *len) { 8027894: 460d mov r5, r1 sprintf(str, "%0.1f", UPS.Temp); 8027896: f7f8 fe3f bl 8020518 <__aeabi_f2d> 802789a: 4602 mov r2, r0 802789c: 460b mov r3, r1 802789e: 4620 mov r0, r4 80278a0: 4904 ldr r1, [pc, #16] ; (80278b4 ) 80278a2: f7ff ff4f bl 8027744 *len = strlen(str); 80278a6: 4620 mov r0, r4 80278a8: f7fa fae2 bl 8021e70 80278ac: 7028 strb r0, [r5, #0] 80278ae: bd38 pop {r3, r4, r5, pc} 80278b0: 2000e8b4 .word 0x2000e8b4 80278b4: 08035e4f .word 0x08035e4f 080278b8 : { /* // if (upsParams.monitor_power) *str = '1'; else *str = '0';*/ *str = '0'; 80278b8: 2330 movs r3, #48 ; 0x30 80278ba: 7003 strb r3, [r0, #0] *len = 1; 80278bc: 2301 movs r3, #1 80278be: 700b strb r3, [r1, #0] 80278c0: 4770 bx lr 080278c2 : { /*// if (upsParams.monitor_temperature) *str = '1'; else *str = '0';*/ *str = '0'; 80278c2: 2330 movs r3, #48 ; 0x30 80278c4: 7003 strb r3, [r0, #0] *len = 1; 80278c6: 2301 movs r3, #1 80278c8: 700b strb r3, [r1, #0] 80278ca: 4770 bx lr 080278cc : // 0 - коннект есть, 1 - нет /* if (upsParams.connect) *str = '0'; else *str = '1';*/ *str = '0'; 80278cc: 2330 movs r3, #48 ; 0x30 80278ce: 7003 strb r3, [r0, #0] *len = 1; 80278d0: 2301 movs r3, #1 80278d2: 700b strb r3, [r1, #0] 80278d4: 4770 bx lr 80278d6: 0000 movs r0, r0 080278d8 : /** * @brief Индикация аварийных ситуаций */ void GetAlarmStr(char *str, uint8_t *len) { 80278d8: b538 push {r3, r4, r5, lr} sprintf(str, "%d", UPS.Status); 80278da: 4b06 ldr r3, [pc, #24] ; (80278f4 ) /** * @brief Индикация аварийных ситуаций */ void GetAlarmStr(char *str, uint8_t *len) { 80278dc: 4605 mov r5, r0 80278de: 460c mov r4, r1 sprintf(str, "%d", UPS.Status); 80278e0: 7cda ldrb r2, [r3, #19] 80278e2: 4905 ldr r1, [pc, #20] ; (80278f8 ) 80278e4: f7ff ff2e bl 8027744 *len = strlen(str); 80278e8: 4628 mov r0, r5 80278ea: f7fa fac1 bl 8021e70 80278ee: 7020 strb r0, [r4, #0] 80278f0: bd38 pop {r3, r4, r5, pc} 80278f2: bf00 nop 80278f4: 2000e8b4 .word 0x2000e8b4 80278f8: 08035e55 .word 0x08035e55 080278fc : /** * @brief Дата (Ready for PRS!) */ void GetDateStr(char *str, uint8_t *len) { 80278fc: b530 push {r4, r5, lr} 80278fe: b087 sub sp, #28 8027900: 4604 mov r4, r0 8027902: 460d mov r5, r1 TM_RTC_t data; uint16_t sys_year ; TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 8027904: a802 add r0, sp, #8 8027906: 2100 movs r1, #0 8027908: f7fe fdbe bl 8026488 sys_year = 2000 + data.year; sprintf(str, "%04i-%02i-%02i", sys_year, data.month, data.date); 802790c: f89d 100f ldrb.w r1, [sp, #15] { TM_RTC_t data; uint16_t sys_year ; TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); sys_year = 2000 + data.year; 8027910: f89d 2011 ldrb.w r2, [sp, #17] sprintf(str, "%04i-%02i-%02i", sys_year, data.month, data.date); 8027914: f89d 3010 ldrb.w r3, [sp, #16] 8027918: 9100 str r1, [sp, #0] 802791a: f502 62fa add.w r2, r2, #2000 ; 0x7d0 802791e: 4905 ldr r1, [pc, #20] ; (8027934 ) 8027920: 4620 mov r0, r4 8027922: f7ff ff0f bl 8027744 *len = strlen(str); 8027926: 4620 mov r0, r4 8027928: f7fa faa2 bl 8021e70 802792c: 7028 strb r0, [r5, #0] } 802792e: b007 add sp, #28 8027930: bd30 pop {r4, r5, pc} 8027932: bf00 nop 8027934: 08035e58 .word 0x08035e58 08027938 : /** * @brief Время (Ready for PRS!) */ void GetTimeStr(char *str, uint8_t *len) { 8027938: b530 push {r4, r5, lr} 802793a: b085 sub sp, #20 802793c: 4604 mov r4, r0 802793e: 460d mov r5, r1 TM_RTC_t data; TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 8027940: 4668 mov r0, sp 8027942: 2100 movs r1, #0 8027944: f7fe fda0 bl 8026488 sprintf(str, "%02i:%02i", data.hours, data.minutes); 8027948: 4906 ldr r1, [pc, #24] ; (8027964 ) 802794a: f89d 2005 ldrb.w r2, [sp, #5] 802794e: f89d 3004 ldrb.w r3, [sp, #4] 8027952: 4620 mov r0, r4 8027954: f7ff fef6 bl 8027744 *len = strlen(str); 8027958: 4620 mov r0, r4 802795a: f7fa fa89 bl 8021e70 802795e: 7028 strb r0, [r5, #0] } 8027960: b005 add sp, #20 8027962: bd30 pop {r4, r5, pc} 8027964: 08035e9b .word 0x08035e9b 08027968 : /** * @brief Время (Ready for PRS!) */ void GetUnixTimeStr(char *str, uint8_t *len) { 8027968: b530 push {r4, r5, lr} 802796a: b085 sub sp, #20 802796c: 4604 mov r4, r0 802796e: 460d mov r5, r1 TM_RTC_t data; TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 8027970: 4668 mov r0, sp 8027972: 2100 movs r1, #0 8027974: f7fe fd88 bl 8026488 sprintf(str, "%d", data.unix); 8027978: 4905 ldr r1, [pc, #20] ; (8027990 ) 802797a: 9a03 ldr r2, [sp, #12] 802797c: 4620 mov r0, r4 802797e: f7ff fee1 bl 8027744 *len = strlen(str); 8027982: 4620 mov r0, r4 8027984: f7fa fa74 bl 8021e70 8027988: 7028 strb r0, [r5, #0] } 802798a: b005 add sp, #20 802798c: bd30 pop {r4, r5, pc} 802798e: bf00 nop 8027990: 08035e55 .word 0x08035e55 08027994 : /** * @brief Состояние SNTP (Ready for PRS!) */ void GetSntpStateStr(char *str, uint8_t *len) { 8027994: b538 push {r3, r4, r5, lr} if (sSettings.sSNTP.sntpEnable) 8027996: 4b08 ldr r3, [pc, #32] ; (80279b8 ) 8027998: f893 3344 ldrb.w r3, [r3, #836] ; 0x344 /** * @brief Состояние SNTP (Ready for PRS!) */ void GetSntpStateStr(char *str, uint8_t *len) { 802799c: 460c mov r4, r1 802799e: 4605 mov r5, r0 if (sSettings.sSNTP.sntpEnable) { sprintf(str, "%s", "1"); //авто 80279a0: 4906 ldr r1, [pc, #24] ; (80279bc ) /** * @brief Состояние SNTP (Ready for PRS!) */ void GetSntpStateStr(char *str, uint8_t *len) { if (sSettings.sSNTP.sntpEnable) 80279a2: b10b cbz r3, 80279a8 { sprintf(str, "%s", "1"); //авто 80279a4: 4a06 ldr r2, [pc, #24] ; (80279c0 ) 80279a6: e000 b.n 80279aa *len = strlen(str); } else { sprintf(str, "%s", "0"); //ручной 80279a8: 4a06 ldr r2, [pc, #24] ; (80279c4 ) 80279aa: f7ff fecb bl 8027744 *len = strlen(str); 80279ae: 4628 mov r0, r5 80279b0: f7fa fa5e bl 8021e70 80279b4: 7020 strb r0, [r4, #0] 80279b6: bd38 pop {r3, r4, r5, pc} 80279b8: 2000e8e4 .word 0x2000e8e4 80279bc: 08035e67 .word 0x08035e67 80279c0: 08035f50 .word 0x08035f50 80279c4: 08035ef3 .word 0x08035ef3 080279c8 : /** * @brief IP адрес SNTP сервера (Ready for PRS!) */ void GetSntpServerIpStr(char *str, uint8_t *len) { 80279c8: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSNTP.ip); 80279ca: 4a05 ldr r2, [pc, #20] ; (80279e0 ) /** * @brief IP адрес SNTP сервера (Ready for PRS!) */ void GetSntpServerIpStr(char *str, uint8_t *len) { 80279cc: 4605 mov r5, r0 80279ce: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSNTP.ip); 80279d0: 4904 ldr r1, [pc, #16] ; (80279e4 ) 80279d2: f7ff feb7 bl 8027744 *len = strlen(str); 80279d6: 4628 mov r0, r5 80279d8: f7fa fa4a bl 8021e70 80279dc: 7020 strb r0, [r4, #0] 80279de: bd38 pop {r3, r4, r5, pc} 80279e0: 2000ec29 .word 0x2000ec29 80279e4: 08035e67 .word 0x08035e67 080279e8 : /** * @brief Часовой пояс контроллера (Ready for PRS!) */ void GetSntpTimeZoneStr(char *str, uint8_t *len) { 80279e8: b538 push {r3, r4, r5, lr} sprintf(str, "%0.1f", sSettings.sSNTP.timeZone); 80279ea: 4b09 ldr r3, [pc, #36] ; (8027a10 ) /** * @brief Часовой пояс контроллера (Ready for PRS!) */ void GetSntpTimeZoneStr(char *str, uint8_t *len) { 80279ec: 4604 mov r4, r0 sprintf(str, "%0.1f", sSettings.sSNTP.timeZone); 80279ee: f8d3 0374 ldr.w r0, [r3, #884] ; 0x374 /** * @brief Часовой пояс контроллера (Ready for PRS!) */ void GetSntpTimeZoneStr(char *str, uint8_t *len) { 80279f2: 460d mov r5, r1 sprintf(str, "%0.1f", sSettings.sSNTP.timeZone); 80279f4: f7f8 fd90 bl 8020518 <__aeabi_f2d> 80279f8: 4602 mov r2, r0 80279fa: 460b mov r3, r1 80279fc: 4620 mov r0, r4 80279fe: 4905 ldr r1, [pc, #20] ; (8027a14 ) 8027a00: f7ff fea0 bl 8027744 *len = strlen(str); 8027a04: 4620 mov r0, r4 8027a06: f7fa fa33 bl 8021e70 8027a0a: 7028 strb r0, [r5, #0] 8027a0c: bd38 pop {r3, r4, r5, pc} 8027a0e: bf00 nop 8027a10: 2000e8e4 .word 0x2000e8e4 8027a14: 08035e4f .word 0x08035e4f 08027a18 : /** * @brief Дата последней синхронизации SNTP (Ready for PRS!) */ void GetSntpLastDataStr(char *str, uint8_t *len) { 8027a18: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSNTP.data); 8027a1a: 4a05 ldr r2, [pc, #20] ; (8027a30 ) /** * @brief Дата последней синхронизации SNTP (Ready for PRS!) */ void GetSntpLastDataStr(char *str, uint8_t *len) { 8027a1c: 4605 mov r5, r0 8027a1e: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSNTP.data); 8027a20: 4904 ldr r1, [pc, #16] ; (8027a34 ) 8027a22: f7ff fe8f bl 8027744 *len = strlen(str); 8027a26: 4628 mov r0, r5 8027a28: f7fa fa22 bl 8021e70 8027a2c: 7020 strb r0, [r4, #0] 8027a2e: bd38 pop {r3, r4, r5, pc} 8027a30: 2000ec39 .word 0x2000ec39 8027a34: 08035e67 .word 0x08035e67 08027a38 : /** * @brief Тип действий при срабатывание сухих контактов */ void GetDINTypeActStr(char *str, uint8_t *len, uint8_t num) { 8027a38: b538 push {r3, r4, r5, lr} sprintf(str, "%d", sSettings.sInOuts.din_type_act[num]); 8027a3a: 4b07 ldr r3, [pc, #28] ; (8027a58 ) 8027a3c: 189a adds r2, r3, r2 /** * @brief Тип действий при срабатывание сухих контактов */ void GetDINTypeActStr(char *str, uint8_t *len, uint8_t num) { 8027a3e: 4605 mov r5, r0 8027a40: 460c mov r4, r1 sprintf(str, "%d", sSettings.sInOuts.din_type_act[num]); 8027a42: f892 237a ldrb.w r2, [r2, #890] ; 0x37a 8027a46: 4905 ldr r1, [pc, #20] ; (8027a5c ) 8027a48: f7ff fe7c bl 8027744 *len = strlen(str); 8027a4c: 4628 mov r0, r5 8027a4e: f7fa fa0f bl 8021e70 8027a52: 7020 strb r0, [r4, #0] 8027a54: bd38 pop {r3, r4, r5, pc} 8027a56: bf00 nop 8027a58: 2000e8e4 .word 0x2000e8e4 8027a5c: 08035e55 .word 0x08035e55 08027a60 : /** * @brief Источник срабатывания реле */ void GetROTypeActStr(char *str, uint8_t *len, uint8_t num) { 8027a60: b538 push {r3, r4, r5, lr} sprintf(str, "%d", sSettings.sInOuts.ro_type_source[num]); 8027a62: 4b07 ldr r3, [pc, #28] ; (8027a80 ) 8027a64: 189a adds r2, r3, r2 /** * @brief Источник срабатывания реле */ void GetROTypeActStr(char *str, uint8_t *len, uint8_t num) { 8027a66: 4605 mov r5, r0 8027a68: 460c mov r4, r1 sprintf(str, "%d", sSettings.sInOuts.ro_type_source[num]); 8027a6a: f892 2378 ldrb.w r2, [r2, #888] ; 0x378 8027a6e: 4905 ldr r1, [pc, #20] ; (8027a84 ) 8027a70: f7ff fe68 bl 8027744 *len = strlen(str); 8027a74: 4628 mov r0, r5 8027a76: f7fa f9fb bl 8021e70 8027a7a: 7020 strb r0, [r4, #0] 8027a7c: bd38 pop {r3, r4, r5, pc} 8027a7e: bf00 nop 8027a80: 2000e8e4 .word 0x2000e8e4 8027a84: 08035e55 .word 0x08035e55 08027a88 : /** * @brief Время работы устройства */ void GetWorkTimeStr(char *str, uint8_t *len) { 8027a88: b57f push {r0, r1, r2, r3, r4, r5, r6, lr} 8027a8a: 4604 mov r4, r0 u32_t tick; uint16_t day; uint8_t hour; uint8_t min; snmp_get_sysuptime(&tick); 8027a8c: a803 add r0, sp, #12 /** * @brief Время работы устройства */ void GetWorkTimeStr(char *str, uint8_t *len) { 8027a8e: 460e mov r6, r1 u32_t tick; uint16_t day; uint8_t hour; uint8_t min; snmp_get_sysuptime(&tick); 8027a90: f009 fdc0 bl 8031614 day = tick/8640000; 8027a94: 9803 ldr r0, [sp, #12] tick = tick%8640000; 8027a96: 4b0c ldr r3, [pc, #48] ; (8027ac8 ) hour = tick/360000; tick = tick%360000; 8027a98: 4d0c ldr r5, [pc, #48] ; (8027acc ) snmp_get_sysuptime(&tick); day = tick/8640000; tick = tick%8640000; 8027a9a: fbb0 f2f3 udiv r2, r0, r3 8027a9e: fb03 0012 mls r0, r3, r2, r0 hour = tick/360000; tick = tick%360000; 8027aa2: fbb0 f3f5 udiv r3, r0, r5 8027aa6: fb05 0013 mls r0, r5, r3, r0 min = tick/6000; 8027aaa: f241 7170 movw r1, #6000 ; 0x1770 day = tick/8640000; tick = tick%8640000; hour = tick/360000; tick = tick%360000; 8027aae: 9003 str r0, [sp, #12] min = tick/6000; 8027ab0: fbb0 f0f1 udiv r0, r0, r1 sprintf(str, "%d дн. %d ч. %d мин.", day, hour, min); 8027ab4: 9000 str r0, [sp, #0] 8027ab6: 4906 ldr r1, [pc, #24] ; (8027ad0 ) 8027ab8: 4620 mov r0, r4 8027aba: f7ff fe43 bl 8027744 *len = strlen(str); 8027abe: 4620 mov r0, r4 8027ac0: f7fa f9d6 bl 8021e70 8027ac4: 7030 strb r0, [r6, #0] } 8027ac6: bd7f pop {r0, r1, r2, r3, r4, r5, r6, pc} 8027ac8: 0083d600 .word 0x0083d600 8027acc: 00057e40 .word 0x00057e40 8027ad0: 08035e6a .word 0x08035e6a 08027ad4 : /** * @brief Модель устройства */ void GetModelStr(char *str, uint8_t *len) { 8027ad4: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sSnmp.sysName); 8027ad6: 4c07 ldr r4, [pc, #28] ; (8027af4 ) /** * @brief Модель устройства */ void GetModelStr(char *str, uint8_t *len) { 8027ad8: 4605 mov r5, r0 *len = strlen(sSettings.sSnmp.sysName); 8027ada: 4620 mov r0, r4 /** * @brief Модель устройства */ void GetModelStr(char *str, uint8_t *len) { 8027adc: 460e mov r6, r1 *len = strlen(sSettings.sSnmp.sysName); 8027ade: f7fa f9c7 bl 8021e70 8027ae2: 4602 mov r2, r0 8027ae4: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sSnmp.sysName, *len); 8027ae6: 4621 mov r1, r4 8027ae8: 4628 mov r0, r5 8027aea: b2d2 uxtb r2, r2 } 8027aec: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Модель устройства */ void GetModelStr(char *str, uint8_t *len) { *len = strlen(sSettings.sSnmp.sysName); strncpy(str, sSettings.sSnmp.sysName, *len); 8027af0: f7fa ba76 b.w 8021fe0 8027af4: 2000ea42 .word 0x2000ea42 08027af8 : /** * @brief Дата производства */ void GetProductionDataStr(char *str, uint8_t *len) { 8027af8: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sInfo.productionData); 8027afa: 4c07 ldr r4, [pc, #28] ; (8027b18 ) /** * @brief Дата производства */ void GetProductionDataStr(char *str, uint8_t *len) { 8027afc: 4605 mov r5, r0 *len = strlen(sSettings.sInfo.productionData); 8027afe: 4620 mov r0, r4 /** * @brief Дата производства */ void GetProductionDataStr(char *str, uint8_t *len) { 8027b00: 460e mov r6, r1 *len = strlen(sSettings.sInfo.productionData); 8027b02: f7fa f9b5 bl 8021e70 8027b06: 4602 mov r2, r0 8027b08: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sInfo.productionData, *len); 8027b0a: 4621 mov r1, r4 8027b0c: 4628 mov r0, r5 8027b0e: b2d2 uxtb r2, r2 } 8027b10: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Дата производства */ void GetProductionDataStr(char *str, uint8_t *len) { *len = strlen(sSettings.sInfo.productionData); strncpy(str, sSettings.sInfo.productionData, *len); 8027b14: f7fa ba64 b.w 8021fe0 8027b18: 2000eb28 .word 0x2000eb28 08027b1c : /** * @brief Версия ПО */ void GetVersionStr(char *str, uint8_t *len) // + { 8027b1c: b570 push {r4, r5, r6, lr} *len = strlen(VERSION); 8027b1e: 4c07 ldr r4, [pc, #28] ; (8027b3c ) /** * @brief Версия ПО */ void GetVersionStr(char *str, uint8_t *len) // + { 8027b20: 4605 mov r5, r0 *len = strlen(VERSION); 8027b22: 4620 mov r0, r4 /** * @brief Версия ПО */ void GetVersionStr(char *str, uint8_t *len) // + { 8027b24: 460e mov r6, r1 *len = strlen(VERSION); 8027b26: f7fa f9a3 bl 8021e70 8027b2a: 4602 mov r2, r0 8027b2c: 7030 strb r0, [r6, #0] strncpy(str, VERSION, *len); 8027b2e: 4621 mov r1, r4 8027b30: 4628 mov r0, r5 8027b32: b2d2 uxtb r2, r2 } 8027b34: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Версия ПО */ void GetVersionStr(char *str, uint8_t *len) // + { *len = strlen(VERSION); strncpy(str, VERSION, *len); 8027b38: f7fa ba52 b.w 8021fe0 8027b3c: 08035e85 .word 0x08035e85 08027b40 : /** * @brief MAC адрес устройства */ void GetMacStr(char *str, uint8_t *len) { 8027b40: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sInfo.mac); 8027b42: 4c07 ldr r4, [pc, #28] ; (8027b60 ) /** * @brief MAC адрес устройства */ void GetMacStr(char *str, uint8_t *len) { 8027b44: 4605 mov r5, r0 *len = strlen(sSettings.sInfo.mac); 8027b46: 4620 mov r0, r4 /** * @brief MAC адрес устройства */ void GetMacStr(char *str, uint8_t *len) { 8027b48: 460e mov r6, r1 *len = strlen(sSettings.sInfo.mac); 8027b4a: f7fa f991 bl 8021e70 8027b4e: 4602 mov r2, r0 8027b50: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sInfo.mac, *len); 8027b52: 4621 mov r1, r4 8027b54: 4628 mov r0, r5 8027b56: b2d2 uxtb r2, r2 } 8027b58: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief MAC адрес устройства */ void GetMacStr(char *str, uint8_t *len) { *len = strlen(sSettings.sInfo.mac); strncpy(str, sSettings.sInfo.mac, *len); 8027b5c: f7fa ba40 b.w 8021fe0 8027b60: 2000eb50 .word 0x2000eb50 08027b64 : /** * @brief Серийный номер устройства */ void GetSerialNumberStr(char *str, uint8_t *len) { 8027b64: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sInfo.serialNumber); 8027b66: 4c07 ldr r4, [pc, #28] ; (8027b84 ) /** * @brief Серийный номер устройства */ void GetSerialNumberStr(char *str, uint8_t *len) { 8027b68: 4605 mov r5, r0 *len = strlen(sSettings.sInfo.serialNumber); 8027b6a: 4620 mov r0, r4 /** * @brief Серийный номер устройства */ void GetSerialNumberStr(char *str, uint8_t *len) { 8027b6c: 460e mov r6, r1 *len = strlen(sSettings.sInfo.serialNumber); 8027b6e: f7fa f97f bl 8021e70 8027b72: 4602 mov r2, r0 8027b74: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sInfo.serialNumber, *len); 8027b76: 4621 mov r1, r4 8027b78: 4628 mov r0, r5 8027b7a: b2d2 uxtb r2, r2 } 8027b7c: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Серийный номер устройства */ void GetSerialNumberStr(char *str, uint8_t *len) { *len = strlen(sSettings.sInfo.serialNumber); strncpy(str, sSettings.sInfo.serialNumber, *len); 8027b80: f7fa ba2e b.w 8021fe0 8027b84: 2000eb62 .word 0x2000eb62 08027b88 : /** * @brief Владелец устройства */ void GetOwnerStr(char *str, uint8_t *len) { 8027b88: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sSnmp.sysContact); 8027b8a: 4c07 ldr r4, [pc, #28] ; (8027ba8 ) /** * @brief Владелец устройства */ void GetOwnerStr(char *str, uint8_t *len) { 8027b8c: 4605 mov r5, r0 *len = strlen(sSettings.sSnmp.sysContact); 8027b8e: 4620 mov r0, r4 /** * @brief Владелец устройства */ void GetOwnerStr(char *str, uint8_t *len) { 8027b90: 460e mov r6, r1 *len = strlen(sSettings.sSnmp.sysContact); 8027b92: f7fa f96d bl 8021e70 8027b96: 4602 mov r2, r0 8027b98: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sSnmp.sysContact, *len); 8027b9a: 4621 mov r1, r4 8027b9c: 4628 mov r0, r5 8027b9e: b2d2 uxtb r2, r2 } 8027ba0: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Владелец устройства */ void GetOwnerStr(char *str, uint8_t *len) { *len = strlen(sSettings.sSnmp.sysContact); strncpy(str, sSettings.sSnmp.sysContact, *len); 8027ba4: f7fa ba1c b.w 8021fe0 8027ba8: 2000ea10 .word 0x2000ea10 08027bac : /** * @brief Местоположение устройства */ void GetLocationStr(char *str, uint8_t *len) { 8027bac: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sSnmp.sysLocation); 8027bae: 4c07 ldr r4, [pc, #28] ; (8027bcc ) /** * @brief Местоположение устройства */ void GetLocationStr(char *str, uint8_t *len) { 8027bb0: 4605 mov r5, r0 *len = strlen(sSettings.sSnmp.sysLocation); 8027bb2: 4620 mov r0, r4 /** * @brief Местоположение устройства */ void GetLocationStr(char *str, uint8_t *len) { 8027bb4: 460e mov r6, r1 *len = strlen(sSettings.sSnmp.sysLocation); 8027bb6: f7fa f95b bl 8021e70 8027bba: 4602 mov r2, r0 8027bbc: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sSnmp.sysLocation, *len); 8027bbe: 4621 mov r1, r4 8027bc0: 4628 mov r0, r5 8027bc2: b2d2 uxtb r2, r2 } 8027bc4: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Местоположение устройства */ void GetLocationStr(char *str, uint8_t *len) { *len = strlen(sSettings.sSnmp.sysLocation); strncpy(str, sSettings.sSnmp.sysLocation, *len); 8027bc8: f7fa ba0a b.w 8021fe0 8027bcc: 2000ea56 .word 0x2000ea56 08027bd0 : /** * @brief Комментарии */ void GetCommentsStr(char *str, uint8_t *len) { 8027bd0: b570 push {r4, r5, r6, lr} *len = strlen(sSettings.sInfo.comments); 8027bd2: 4c07 ldr r4, [pc, #28] ; (8027bf0 ) /** * @brief Комментарии */ void GetCommentsStr(char *str, uint8_t *len) { 8027bd4: 4605 mov r5, r0 *len = strlen(sSettings.sInfo.comments); 8027bd6: 4620 mov r0, r4 /** * @brief Комментарии */ void GetCommentsStr(char *str, uint8_t *len) { 8027bd8: 460e mov r6, r1 *len = strlen(sSettings.sInfo.comments); 8027bda: f7fa f949 bl 8021e70 8027bde: 4602 mov r2, r0 8027be0: 7030 strb r0, [r6, #0] strncpy(str, sSettings.sInfo.comments, *len); 8027be2: 4621 mov r1, r4 8027be4: 4628 mov r0, r5 8027be6: b2d2 uxtb r2, r2 } 8027be8: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Комментарии */ void GetCommentsStr(char *str, uint8_t *len) { *len = strlen(sSettings.sInfo.comments); strncpy(str, sSettings.sInfo.comments, *len); 8027bec: f7fa b9f8 b.w 8021fe0 8027bf0: 2000eb72 .word 0x2000eb72 08027bf4 : /** * @brief Модель UPS */ void GetUPSModelStr(char *str, uint8_t *len) { 8027bf4: b570 push {r4, r5, r6, lr} *len = strlen(UPS.model); 8027bf6: 4c07 ldr r4, [pc, #28] ; (8027c14 ) /** * @brief Модель UPS */ void GetUPSModelStr(char *str, uint8_t *len) { 8027bf8: 4605 mov r5, r0 *len = strlen(UPS.model); 8027bfa: 4620 mov r0, r4 /** * @brief Модель UPS */ void GetUPSModelStr(char *str, uint8_t *len) { 8027bfc: 460e mov r6, r1 *len = strlen(UPS.model); 8027bfe: f7fa f937 bl 8021e70 8027c02: 4602 mov r2, r0 8027c04: 7030 strb r0, [r6, #0] strncpy(str, UPS.model, *len); 8027c06: 4621 mov r1, r4 8027c08: 4628 mov r0, r5 8027c0a: b2d2 uxtb r2, r2 } 8027c0c: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Модель UPS */ void GetUPSModelStr(char *str, uint8_t *len) { *len = strlen(UPS.model); strncpy(str, UPS.model, *len); 8027c10: f7fa b9e6 b.w 8021fe0 8027c14: 2000e8c8 .word 0x2000e8c8 08027c18 : /** * @brief Версия UPS ПО */ void GetUPSVersionStr(char *str, uint8_t *len) // + { 8027c18: b570 push {r4, r5, r6, lr} *len = strlen(UPS.vertion); 8027c1a: 4c07 ldr r4, [pc, #28] ; (8027c38 ) /** * @brief Версия UPS ПО */ void GetUPSVersionStr(char *str, uint8_t *len) // + { 8027c1c: 4605 mov r5, r0 *len = strlen(UPS.vertion); 8027c1e: 4620 mov r0, r4 /** * @brief Версия UPS ПО */ void GetUPSVersionStr(char *str, uint8_t *len) // + { 8027c20: 460e mov r6, r1 *len = strlen(UPS.vertion); 8027c22: f7fa f925 bl 8021e70 8027c26: 4602 mov r2, r0 8027c28: 7030 strb r0, [r6, #0] strncpy(str, UPS.vertion, *len); 8027c2a: 4621 mov r1, r4 8027c2c: 4628 mov r0, r5 8027c2e: b2d2 uxtb r2, r2 } 8027c30: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Версия UPS ПО */ void GetUPSVersionStr(char *str, uint8_t *len) // + { *len = strlen(UPS.vertion); strncpy(str, UPS.vertion, *len); 8027c34: f7fa b9d4 b.w 8021fe0 8027c38: 2000e8d3 .word 0x2000e8d3 08027c3c : // ************************************************************************** // // Настройки аутентификации void GetUserLogin(uint8_t user_id, char *str, uint8_t *len) { 8027c3c: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sAuth[user_id].login); 8027c3e: 4b08 ldr r3, [pc, #32] ; (8027c60 ) // ************************************************************************** // // Настройки аутентификации void GetUserLogin(uint8_t user_id, char *str, uint8_t *len) { 8027c40: 4615 mov r5, r2 sprintf(str, "%s", sSettings.sAuth[user_id].login); 8027c42: 2217 movs r2, #23 8027c44: fb02 3200 mla r2, r2, r0, r3 // ************************************************************************** // // Настройки аутентификации void GetUserLogin(uint8_t user_id, char *str, uint8_t *len) { 8027c48: 460c mov r4, r1 sprintf(str, "%s", sSettings.sAuth[user_id].login); 8027c4a: 4608 mov r0, r1 8027c4c: 3205 adds r2, #5 8027c4e: 4905 ldr r1, [pc, #20] ; (8027c64 ) 8027c50: f7ff fd78 bl 8027744 *len = strlen(str); 8027c54: 4620 mov r0, r4 8027c56: f7fa f90b bl 8021e70 8027c5a: 7028 strb r0, [r5, #0] 8027c5c: bd38 pop {r3, r4, r5, pc} 8027c5e: bf00 nop 8027c60: 2000ebf4 .word 0x2000ebf4 8027c64: 08035e67 .word 0x08035e67 08027c68 : } void GetUserPassword(uint8_t user_id, char *str, uint8_t *len) { 8027c68: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sAuth[user_id].password); 8027c6a: 4b08 ldr r3, [pc, #32] ; (8027c8c ) sprintf(str, "%s", sSettings.sAuth[user_id].login); *len = strlen(str); } void GetUserPassword(uint8_t user_id, char *str, uint8_t *len) { 8027c6c: 4615 mov r5, r2 sprintf(str, "%s", sSettings.sAuth[user_id].password); 8027c6e: 2217 movs r2, #23 8027c70: fb02 3200 mla r2, r2, r0, r3 sprintf(str, "%s", sSettings.sAuth[user_id].login); *len = strlen(str); } void GetUserPassword(uint8_t user_id, char *str, uint8_t *len) { 8027c74: 460c mov r4, r1 sprintf(str, "%s", sSettings.sAuth[user_id].password); 8027c76: 4608 mov r0, r1 8027c78: 3208 adds r2, #8 8027c7a: 4905 ldr r1, [pc, #20] ; (8027c90 ) 8027c7c: f7ff fd62 bl 8027744 *len = strlen(str); 8027c80: 4620 mov r0, r4 8027c82: f7fa f8f5 bl 8021e70 8027c86: 7028 strb r0, [r5, #0] 8027c88: bd38 pop {r3, r4, r5, pc} 8027c8a: bf00 nop 8027c8c: 2000ebfc .word 0x2000ebfc 8027c90: 08035e67 .word 0x08035e67 08027c94 : *len = strlen(str); } void GetUserLevelInt(uint8_t user_id, uint8_t *value) { *value = sSettings.sAuth[user_id].level; 8027c94: 4b03 ldr r3, [pc, #12] ; (8027ca4 ) 8027c96: 2217 movs r2, #23 8027c98: fb02 3000 mla r0, r2, r0, r3 8027c9c: f890 3314 ldrb.w r3, [r0, #788] ; 0x314 8027ca0: 700b strb r3, [r1, #0] 8027ca2: 4770 bx lr 8027ca4: 2000e8e4 .word 0x2000e8e4 08027ca8 : * @brief Текущий IP адрес */ void GetIpStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027ca8: 4a08 ldr r2, [pc, #32] ; (8027ccc ) /** * @brief Текущий IP адрес */ void GetIpStr(char *str, uint8_t *len) { 8027caa: b538 push {r3, r4, r5, lr} /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027cac: f892 32fc ldrb.w r3, [r2, #764] ; 0x2fc /** * @brief Текущий IP адрес */ void GetIpStr(char *str, uint8_t *len) { 8027cb0: 460c mov r4, r1 8027cb2: 4605 mov r5, r0 /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) sprintf(str, "%s", sSettings.sWebTempParams.ip); 8027cb4: 4906 ldr r1, [pc, #24] ; (8027cd0 ) * @brief Текущий IP адрес */ void GetIpStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027cb6: b10b cbz r3, 8027cbc sprintf(str, "%s", sSettings.sWebTempParams.ip); 8027cb8: 3233 adds r2, #51 ; 0x33 8027cba: e000 b.n 8027cbe else sprintf(str, "%s", sSettings.sWebParams.ip); 8027cbc: 3202 adds r2, #2 8027cbe: f7ff fd41 bl 8027744 *len = strlen(str); 8027cc2: 4628 mov r0, r5 8027cc4: f7fa f8d4 bl 8021e70 8027cc8: 7020 strb r0, [r4, #0] 8027cca: bd38 pop {r3, r4, r5, pc} 8027ccc: 2000e8e4 .word 0x2000e8e4 8027cd0: 08035e67 .word 0x08035e67 08027cd4 : * @brief Текущий шлюз */ void GetGatewayStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027cd4: 4a08 ldr r2, [pc, #32] ; (8027cf8 ) /** * @brief Текущий шлюз */ void GetGatewayStr(char *str, uint8_t *len) { 8027cd6: b538 push {r3, r4, r5, lr} /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027cd8: f892 32fc ldrb.w r3, [r2, #764] ; 0x2fc /** * @brief Текущий шлюз */ void GetGatewayStr(char *str, uint8_t *len) { 8027cdc: 460c mov r4, r1 8027cde: 4605 mov r5, r0 /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) sprintf(str, "%s", sSettings.sWebTempParams.gate); 8027ce0: 4906 ldr r1, [pc, #24] ; (8027cfc ) * @brief Текущий шлюз */ void GetGatewayStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027ce2: b10b cbz r3, 8027ce8 sprintf(str, "%s", sSettings.sWebTempParams.gate); 8027ce4: 3243 adds r2, #67 ; 0x43 8027ce6: e000 b.n 8027cea else sprintf(str, "%s", sSettings.sWebParams.gate); 8027ce8: 3212 adds r2, #18 8027cea: f7ff fd2b bl 8027744 *len = strlen(str); 8027cee: 4628 mov r0, r5 8027cf0: f7fa f8be bl 8021e70 8027cf4: 7020 strb r0, [r4, #0] 8027cf6: bd38 pop {r3, r4, r5, pc} 8027cf8: 2000e8e4 .word 0x2000e8e4 8027cfc: 08035e67 .word 0x08035e67 08027d00 : * @brief Текущая маска подсети */ void GetMaskStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027d00: 4a08 ldr r2, [pc, #32] ; (8027d24 ) /** * @brief Текущая маска подсети */ void GetMaskStr(char *str, uint8_t *len) { 8027d02: b538 push {r3, r4, r5, lr} /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027d04: f892 32fc ldrb.w r3, [r2, #764] ; 0x2fc /** * @brief Текущая маска подсети */ void GetMaskStr(char *str, uint8_t *len) { 8027d08: 460c mov r4, r1 8027d0a: 4605 mov r5, r0 /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) sprintf(str, "%s", sSettings.sWebTempParams.mask); 8027d0c: 4906 ldr r1, [pc, #24] ; (8027d28 ) * @brief Текущая маска подсети */ void GetMaskStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027d0e: b10b cbz r3, 8027d14 sprintf(str, "%s", sSettings.sWebTempParams.mask); 8027d10: 3253 adds r2, #83 ; 0x53 8027d12: e000 b.n 8027d16 else sprintf(str, "%s", sSettings.sWebParams.mask); 8027d14: 3222 adds r2, #34 ; 0x22 8027d16: f7ff fd15 bl 8027744 *len = strlen(str); 8027d1a: 4628 mov r0, r5 8027d1c: f7fa f8a8 bl 8021e70 8027d20: 7020 strb r0, [r4, #0] 8027d22: bd38 pop {r3, r4, r5, pc} 8027d24: 2000e8e4 .word 0x2000e8e4 8027d28: 08035e67 .word 0x08035e67 08027d2c : * @brief Настройка DHCP */ void GetDhcpStateStr(char *str, uint8_t *len) { /* Если сейчас временные настройки */ if (sSettings.sFlags.netsettingsChanged) 8027d2c: 4b08 ldr r3, [pc, #32] ; (8027d50 ) 8027d2e: f893 22fc ldrb.w r2, [r3, #764] ; 0x2fc 8027d32: b112 cbz r2, 8027d3a { if (sSettings.sWebTempParams.dhcpEnable) 8027d34: f893 3063 ldrb.w r3, [r3, #99] ; 0x63 8027d38: e001 b.n 8027d3e else *str = '0'; } else { if (sSettings.sWebParams.dhcpEnable) 8027d3a: f893 3032 ldrb.w r3, [r3, #50] ; 0x32 8027d3e: b10b cbz r3, 8027d44 *str = '1'; 8027d40: 2331 movs r3, #49 ; 0x31 8027d42: e000 b.n 8027d46 else *str = '0'; 8027d44: 2330 movs r3, #48 ; 0x30 8027d46: 7003 strb r3, [r0, #0] } *len = 1; 8027d48: 2301 movs r3, #1 8027d4a: 700b strb r3, [r1, #0] 8027d4c: 4770 bx lr 8027d4e: bf00 nop 8027d50: 2000e8e4 .word 0x2000e8e4 08027d54 : /** * @brief Текущее community для чтения */ void GetReadCommunity(char *str, uint8_t *len) { 8027d54: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.readCommunity); 8027d56: 4a05 ldr r2, [pc, #20] ; (8027d6c ) /** * @brief Текущее community для чтения */ void GetReadCommunity(char *str, uint8_t *len) { 8027d58: 4605 mov r5, r0 8027d5a: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.readCommunity); 8027d5c: 4904 ldr r1, [pc, #16] ; (8027d70 ) 8027d5e: f7ff fcf1 bl 8027744 *len = strlen(str); 8027d62: 4628 mov r0, r5 8027d64: f7fa f884 bl 8021e70 8027d68: 7020 strb r0, [r4, #0] 8027d6a: bd38 pop {r3, r4, r5, pc} 8027d6c: 2000e9e8 .word 0x2000e9e8 8027d70: 08035e67 .word 0x08035e67 08027d74 : /** * @brief Текущее community для записи */ void GetWriteCommunity(char *str, uint8_t *len) { 8027d74: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.writeCommunity); 8027d76: 4a05 ldr r2, [pc, #20] ; (8027d8c ) /** * @brief Текущее community для записи */ void GetWriteCommunity(char *str, uint8_t *len) { 8027d78: 4605 mov r5, r0 8027d7a: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.writeCommunity); 8027d7c: 4904 ldr r1, [pc, #16] ; (8027d90 ) 8027d7e: f7ff fce1 bl 8027744 *len = strlen(str); 8027d82: 4628 mov r0, r5 8027d84: f7fa f874 bl 8021e70 8027d88: 7020 strb r0, [r4, #0] 8027d8a: bd38 pop {r3, r4, r5, pc} 8027d8c: 2000e9fc .word 0x2000e9fc 8027d90: 08035e67 .word 0x08035e67 08027d94 : /** * @brief IP SNMP менеджера */ void GetManagerIp(char *str, uint8_t *len) { 8027d94: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.managerIP); 8027d96: 4a05 ldr r2, [pc, #20] ; (8027dac ) /** * @brief IP SNMP менеджера */ void GetManagerIp(char *str, uint8_t *len) { 8027d98: 4605 mov r5, r0 8027d9a: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.managerIP); 8027d9c: 4904 ldr r1, [pc, #16] ; (8027db0 ) 8027d9e: f7ff fcd1 bl 8027744 *len = strlen(str); 8027da2: 4628 mov r0, r5 8027da4: f7fa f864 bl 8021e70 8027da8: 7020 strb r0, [r4, #0] 8027daa: bd38 pop {r3, r4, r5, pc} 8027dac: 2000eac4 .word 0x2000eac4 8027db0: 08035e67 .word 0x08035e67 08027db4 : } void GetManagerIp2(char *str, uint8_t *len) { 8027db4: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.managerIP2); 8027db6: 4a05 ldr r2, [pc, #20] ; (8027dcc ) sprintf(str, "%s", sSettings.sSnmp.managerIP); *len = strlen(str); } void GetManagerIp2(char *str, uint8_t *len) { 8027db8: 4605 mov r5, r0 8027dba: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.managerIP2); 8027dbc: 4904 ldr r1, [pc, #16] ; (8027dd0 ) 8027dbe: f7ff fcc1 bl 8027744 *len = strlen(str); 8027dc2: 4628 mov r0, r5 8027dc4: f7fa f854 bl 8021e70 8027dc8: 7020 strb r0, [r4, #0] 8027dca: bd38 pop {r3, r4, r5, pc} 8027dcc: 2000ead8 .word 0x2000ead8 8027dd0: 08035e67 .word 0x08035e67 08027dd4 : } void GetManagerIp3(char *str, uint8_t *len) { 8027dd4: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.managerIP3); 8027dd6: 4a05 ldr r2, [pc, #20] ; (8027dec ) sprintf(str, "%s", sSettings.sSnmp.managerIP2); *len = strlen(str); } void GetManagerIp3(char *str, uint8_t *len) { 8027dd8: 4605 mov r5, r0 8027dda: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.managerIP3); 8027ddc: 4904 ldr r1, [pc, #16] ; (8027df0 ) 8027dde: f7ff fcb1 bl 8027744 *len = strlen(str); 8027de2: 4628 mov r0, r5 8027de4: f7fa f844 bl 8021e70 8027de8: 7020 strb r0, [r4, #0] 8027dea: bd38 pop {r3, r4, r5, pc} 8027dec: 2000eaec .word 0x2000eaec 8027df0: 08035e67 .word 0x08035e67 08027df4 : } void GetManagerIp4(char *str, uint8_t *len) { 8027df4: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.managerIP4); 8027df6: 4a05 ldr r2, [pc, #20] ; (8027e0c ) sprintf(str, "%s", sSettings.sSnmp.managerIP3); *len = strlen(str); } void GetManagerIp4(char *str, uint8_t *len) { 8027df8: 4605 mov r5, r0 8027dfa: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.managerIP4); 8027dfc: 4904 ldr r1, [pc, #16] ; (8027e10 ) 8027dfe: f7ff fca1 bl 8027744 *len = strlen(str); 8027e02: 4628 mov r0, r5 8027e04: f7fa f834 bl 8021e70 8027e08: 7020 strb r0, [r4, #0] 8027e0a: bd38 pop {r3, r4, r5, pc} 8027e0c: 2000eb00 .word 0x2000eb00 8027e10: 08035e67 .word 0x08035e67 08027e14 : } void GetManagerIp5(char *str, uint8_t *len) { 8027e14: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sSnmp.managerIP5); 8027e16: 4a05 ldr r2, [pc, #20] ; (8027e2c ) sprintf(str, "%s", sSettings.sSnmp.managerIP4); *len = strlen(str); } void GetManagerIp5(char *str, uint8_t *len) { 8027e18: 4605 mov r5, r0 8027e1a: 460c mov r4, r1 sprintf(str, "%s", sSettings.sSnmp.managerIP5); 8027e1c: 4904 ldr r1, [pc, #16] ; (8027e30 ) 8027e1e: f7ff fc91 bl 8027744 *len = strlen(str); 8027e22: 4628 mov r0, r5 8027e24: f7fa f824 bl 8021e70 8027e28: 7020 strb r0, [r4, #0] 8027e2a: bd38 pop {r3, r4, r5, pc} 8027e2c: 2000eb14 .word 0x2000eb14 8027e30: 08035e67 .word 0x08035e67 08027e34 : /** * @brief Текущий IP адрес */ void GetRDSIpStr(char *str, uint8_t *len) { 8027e34: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sRADIUS.ServerIP); 8027e36: 4a05 ldr r2, [pc, #20] ; (8027e4c ) /** * @brief Текущий IP адрес */ void GetRDSIpStr(char *str, uint8_t *len) { 8027e38: 4605 mov r5, r0 8027e3a: 460c mov r4, r1 sprintf(str, "%s", sSettings.sRADIUS.ServerIP); 8027e3c: 4904 ldr r1, [pc, #16] ; (8027e50 ) 8027e3e: f7ff fc81 bl 8027744 *len = strlen(str); 8027e42: 4628 mov r0, r5 8027e44: f7fa f814 bl 8021e70 8027e48: 7020 strb r0, [r4, #0] 8027e4a: bd38 pop {r3, r4, r5, pc} 8027e4c: 2000ec60 .word 0x2000ec60 8027e50: 08035e67 .word 0x08035e67 08027e54 : /** * @brief Текущий Порт */ void GetRDSPortStr(char *str, uint8_t *len) { 8027e54: b538 push {r3, r4, r5, lr} sprintf(str, "%d", sSettings.sRADIUS.port); 8027e56: 4b06 ldr r3, [pc, #24] ; (8027e70 ) /** * @brief Текущий Порт */ void GetRDSPortStr(char *str, uint8_t *len) { 8027e58: 4605 mov r5, r0 8027e5a: 460c mov r4, r1 sprintf(str, "%d", sSettings.sRADIUS.port); 8027e5c: f8d3 23a0 ldr.w r2, [r3, #928] ; 0x3a0 8027e60: 4904 ldr r1, [pc, #16] ; (8027e74 ) 8027e62: f7ff fc6f bl 8027744 *len = strlen(str); 8027e66: 4628 mov r0, r5 8027e68: f7fa f802 bl 8021e70 8027e6c: 7020 strb r0, [r4, #0] 8027e6e: bd38 pop {r3, r4, r5, pc} 8027e70: 2000e8e4 .word 0x2000e8e4 8027e74: 08035e55 .word 0x08035e55 08027e78 : /** * @brief Текущий Код access */ void GetRDSKeyAccesstStr(char *str, uint8_t *len) { 8027e78: b538 push {r3, r4, r5, lr} sprintf(str, "%d", sSettings.sRADIUS.key_access); 8027e7a: 4b06 ldr r3, [pc, #24] ; (8027e94 ) /** * @brief Текущий Код access */ void GetRDSKeyAccesstStr(char *str, uint8_t *len) { 8027e7c: 4605 mov r5, r0 8027e7e: 460c mov r4, r1 sprintf(str, "%d", sSettings.sRADIUS.key_access); 8027e80: f8d3 23a4 ldr.w r2, [r3, #932] ; 0x3a4 8027e84: 4904 ldr r1, [pc, #16] ; (8027e98 ) 8027e86: f7ff fc5d bl 8027744 *len = strlen(str); 8027e8a: 4628 mov r0, r5 8027e8c: f7f9 fff0 bl 8021e70 8027e90: 7020 strb r0, [r4, #0] 8027e92: bd38 pop {r3, r4, r5, pc} 8027e94: 2000e8e4 .word 0x2000e8e4 8027e98: 08035e55 .word 0x08035e55 08027e9c : /** * @brief Текущая пароль RADIUS */ void GetRDSPasswordkStr(char *str, uint8_t *len) { 8027e9c: b538 push {r3, r4, r5, lr} sprintf(str, "%s", sSettings.sRADIUS.rds_password); 8027e9e: 4a05 ldr r2, [pc, #20] ; (8027eb4 ) /** * @brief Текущая пароль RADIUS */ void GetRDSPasswordkStr(char *str, uint8_t *len) { 8027ea0: 4605 mov r5, r0 8027ea2: 460c mov r4, r1 sprintf(str, "%s", sSettings.sRADIUS.rds_password); 8027ea4: 4904 ldr r1, [pc, #16] ; (8027eb8 ) 8027ea6: f7ff fc4d bl 8027744 *len = strlen(str); 8027eaa: 4628 mov r0, r5 8027eac: f7f9 ffe0 bl 8021e70 8027eb0: 7020 strb r0, [r4, #0] 8027eb2: bd38 pop {r3, r4, r5, pc} 8027eb4: 2000ec70 .word 0x2000ec70 8027eb8: 08035e67 .word 0x08035e67 08027ebc : /** * @brief Настройка вкл/ выкл RADIUS сервера */ void GetRDSEnableStateStr(char *str, uint8_t *len) { if (sSettings.sRADIUS.RDSEnable) 8027ebc: 4b05 ldr r3, [pc, #20] ; (8027ed4 ) 8027ebe: f893 339d ldrb.w r3, [r3, #925] ; 0x39d 8027ec2: b10b cbz r3, 8027ec8 *str = '1'; 8027ec4: 2331 movs r3, #49 ; 0x31 8027ec6: e000 b.n 8027eca else *str = '0'; 8027ec8: 2330 movs r3, #48 ; 0x30 8027eca: 7003 strb r3, [r0, #0] *len = 1; 8027ecc: 2301 movs r3, #1 8027ece: 700b strb r3, [r1, #0] 8027ed0: 4770 bx lr 8027ed2: bf00 nop 8027ed4: 2000e8e4 .word 0x2000e8e4 08027ed8 : /** * @brief Произошел сброс настроек */ void GetRestore(char *str, uint8_t *len) // + { 8027ed8: b510 push {r4, lr} sprintf(str, "%s", "1"); 8027eda: 4a04 ldr r2, [pc, #16] ; (8027eec ) /** * @brief Произошел сброс настроек */ void GetRestore(char *str, uint8_t *len) // + { 8027edc: 460c mov r4, r1 sprintf(str, "%s", "1"); 8027ede: 4904 ldr r1, [pc, #16] ; (8027ef0 ) 8027ee0: f7ff fc30 bl 8027744 *len = 1; 8027ee4: 2301 movs r3, #1 8027ee6: 7023 strb r3, [r4, #0] 8027ee8: bd10 pop {r4, pc} 8027eea: bf00 nop 8027eec: 08035f50 .word 0x08035f50 8027ef0: 08035e67 .word 0x08035e67 08027ef4 : /** * @brief Произошла перезагрузка */ void GetReboot(char *str, uint8_t *len) // + { 8027ef4: b510 push {r4, lr} sprintf(str, "%s", "1"); 8027ef6: 4a04 ldr r2, [pc, #16] ; (8027f08 ) /** * @brief Произошла перезагрузка */ void GetReboot(char *str, uint8_t *len) // + { 8027ef8: 460c mov r4, r1 sprintf(str, "%s", "1"); 8027efa: 4904 ldr r1, [pc, #16] ; (8027f0c ) 8027efc: f7ff fc22 bl 8027744 *len = 1; 8027f00: 2301 movs r3, #1 8027f02: 7023 strb r3, [r4, #0] 8027f04: bd10 pop {r4, pc} 8027f06: bf00 nop 8027f08: 08035f50 .word 0x08035f50 8027f0c: 08035e67 .word 0x08035e67 08027f10 : /** * @brief Вернуть признак изменения сетевых параметров */ void GetWebReinitFlag(char *str, uint8_t *len) { 8027f10: b538 push {r3, r4, r5, lr} if (sSettings.sFlags.netsettingsChanged) 8027f12: 4b08 ldr r3, [pc, #32] ; (8027f34 ) 8027f14: f893 32fc ldrb.w r3, [r3, #764] ; 0x2fc /** * @brief Вернуть признак изменения сетевых параметров */ void GetWebReinitFlag(char *str, uint8_t *len) { 8027f18: 460c mov r4, r1 8027f1a: 4605 mov r5, r0 if (sSettings.sFlags.netsettingsChanged) { sprintf(str, "%s", "true"); 8027f1c: 4906 ldr r1, [pc, #24] ; (8027f38 ) /** * @brief Вернуть признак изменения сетевых параметров */ void GetWebReinitFlag(char *str, uint8_t *len) { if (sSettings.sFlags.netsettingsChanged) 8027f1e: b10b cbz r3, 8027f24 { sprintf(str, "%s", "true"); 8027f20: 4a06 ldr r2, [pc, #24] ; (8027f3c ) 8027f22: e000 b.n 8027f26 *len = strlen(str); } else { sprintf(str, "%s", "false"); 8027f24: 4a06 ldr r2, [pc, #24] ; (8027f40 ) 8027f26: f7ff fc0d bl 8027744 *len = strlen(str); 8027f2a: 4628 mov r0, r5 8027f2c: f7f9 ffa0 bl 8021e70 8027f30: 7020 strb r0, [r4, #0] 8027f32: bd38 pop {r3, r4, r5, pc} 8027f34: 2000e8e4 .word 0x2000e8e4 8027f38: 08035e67 .word 0x08035e67 8027f3c: 08035e89 .word 0x08035e89 8027f40: 08035e8e .word 0x08035e8e 08027f44 : /** * @brief Установить признак обновления ПО. */ void SetLoadMode(void) { sSettings.bootParams.loadMode = 1; 8027f44: 4b01 ldr r3, [pc, #4] ; (8027f4c ) 8027f46: 2201 movs r2, #1 8027f48: 701a strb r2, [r3, #0] 8027f4a: 4770 bx lr 8027f4c: 2000e8e4 .word 0x2000e8e4 08027f50 : /** * @brief Установить признак изменения сетевых параметров */ void SetWebReinitFlag(bool value) { sSettings.sFlags.netsettingsChanged = value; 8027f50: 4b01 ldr r3, [pc, #4] ; (8027f58 ) 8027f52: f883 02fc strb.w r0, [r3, #764] ; 0x2fc 8027f56: 4770 bx lr 8027f58: 2000e8e4 .word 0x2000e8e4 08027f5c : /** * @brief Установить флаг подтверждения сетевых настроек пользователем */ void SetConfirmWebParamsFlag(void) { fConfirmWebParams = true; 8027f5c: 4b01 ldr r3, [pc, #4] ; (8027f64 ) 8027f5e: 2201 movs r2, #1 8027f60: 701a strb r2, [r3, #0] 8027f62: 4770 bx lr 8027f64: 200028ac .word 0x200028ac 08027f68 : // Сетевые параметры /** * @brief IP адрес */ void SetIPStr(char *str) { 8027f68: 4601 mov r1, r0 //strcpy(sSettings.sWebParams.ip, str); strcpy(sSettings.sWebTempParams.ip, str); 8027f6a: 4801 ldr r0, [pc, #4] ; (8027f70 ) 8027f6c: f7f9 bf22 b.w 8021db4 8027f70: 2000e917 .word 0x2000e917 08027f74 : /** * @brief Шлюз */ void SetGatewayStr(char *str) { 8027f74: 4601 mov r1, r0 //strcpy(sSettings.sWebParams.gate, str); strcpy(sSettings.sWebTempParams.gate, str); 8027f76: 4801 ldr r0, [pc, #4] ; (8027f7c ) 8027f78: f7f9 bf1c b.w 8021db4 8027f7c: 2000e927 .word 0x2000e927 08027f80 : /** * @brief Текущая маска подсети */ void SetMaskStr(char *str) { 8027f80: 4601 mov r1, r0 //strcpy(sSettings.sWebParams.mask, str); strcpy(sSettings.sWebTempParams.mask, str); 8027f82: 4801 ldr r0, [pc, #4] ; (8027f88 ) 8027f84: f7f9 bf16 b.w 8021db4 8027f88: 2000e937 .word 0x2000e937 08027f8c : /** * @brief Настройка DHCP */ void SetDhcpStateStr(char *str) { 8027f8c: b508 push {r3, lr} if (strncmp(str, "on", 2) == 0) 8027f8e: 4906 ldr r1, [pc, #24] ; (8027fa8 ) 8027f90: 2202 movs r2, #2 8027f92: f7f9 ffcf bl 8021f34 8027f96: 4b05 ldr r3, [pc, #20] ; (8027fac ) 8027f98: b908 cbnz r0, 8027f9e //sSettings.sWebParams.dhcpEnable = 1; sSettings.sWebTempParams.dhcpEnable = 1; 8027f9a: 2201 movs r2, #1 8027f9c: e000 b.n 8027fa0 else //sSettings.sWebParams.dhcpEnable = 0; sSettings.sWebTempParams.dhcpEnable = 0; 8027f9e: 2200 movs r2, #0 8027fa0: f883 2063 strb.w r2, [r3, #99] ; 0x63 8027fa4: bd08 pop {r3, pc} 8027fa6: bf00 nop 8027fa8: 08035e94 .word 0x08035e94 8027fac: 2000e8e4 .word 0x2000e8e4 08027fb0 : /** * @brief Community для чтения */ void SetReadCommunity(char *str) { 8027fb0: 4601 mov r1, r0 strcpy(sSettings.sSnmp.readCommunity, str); 8027fb2: 4801 ldr r0, [pc, #4] ; (8027fb8 ) 8027fb4: f7f9 befe b.w 8021db4 8027fb8: 2000e9e8 .word 0x2000e9e8 08027fbc : /** * @brief Community для записи */ void SetWriteCommunity(char *str) { 8027fbc: 4601 mov r1, r0 strcpy(sSettings.sSnmp.writeCommunity, str); 8027fbe: 4801 ldr r0, [pc, #4] ; (8027fc4 ) 8027fc0: f7f9 bef8 b.w 8021db4 8027fc4: 2000e9fc .word 0x2000e9fc 08027fc8 : /** * @brief IP SNMP менеджера */ void SetManagerIp(char *str) { 8027fc8: b510 push {r4, lr} strcpy(sSettings.sSnmp.managerIP, str); 8027fca: 4c05 ldr r4, [pc, #20] ; (8027fe0 ) /** * @brief IP SNMP менеджера */ void SetManagerIp(char *str) { 8027fcc: 4601 mov r1, r0 strcpy(sSettings.sSnmp.managerIP, str); 8027fce: 4620 mov r0, r4 8027fd0: f7f9 fef0 bl 8021db4 SNMP_SetManagerIP(sSettings.sSnmp.managerIP); 8027fd4: 4620 mov r0, r4 } 8027fd6: e8bd 4010 ldmia.w sp!, {r4, lr} * @brief IP SNMP менеджера */ void SetManagerIp(char *str) { strcpy(sSettings.sSnmp.managerIP, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP); 8027fda: f00c bf97 b.w 8034f0c 8027fde: bf00 nop 8027fe0: 2000eac4 .word 0x2000eac4 08027fe4 : } void SetManagerIp2(char *str) { 8027fe4: b510 push {r4, lr} strcpy(sSettings.sSnmp.managerIP2, str); 8027fe6: 4c05 ldr r4, [pc, #20] ; (8027ffc ) strcpy(sSettings.sSnmp.managerIP, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP); } void SetManagerIp2(char *str) { 8027fe8: 4601 mov r1, r0 strcpy(sSettings.sSnmp.managerIP2, str); 8027fea: 4620 mov r0, r4 8027fec: f7f9 fee2 bl 8021db4 SNMP_SetManagerIP(sSettings.sSnmp.managerIP2); 8027ff0: 4620 mov r0, r4 } 8027ff2: e8bd 4010 ldmia.w sp!, {r4, lr} } void SetManagerIp2(char *str) { strcpy(sSettings.sSnmp.managerIP2, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP2); 8027ff6: f00c bf89 b.w 8034f0c 8027ffa: bf00 nop 8027ffc: 2000ead8 .word 0x2000ead8 08028000 : } void SetManagerIp3(char *str) { 8028000: b510 push {r4, lr} strcpy(sSettings.sSnmp.managerIP3, str); 8028002: 4c05 ldr r4, [pc, #20] ; (8028018 ) strcpy(sSettings.sSnmp.managerIP2, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP2); } void SetManagerIp3(char *str) { 8028004: 4601 mov r1, r0 strcpy(sSettings.sSnmp.managerIP3, str); 8028006: 4620 mov r0, r4 8028008: f7f9 fed4 bl 8021db4 SNMP_SetManagerIP(sSettings.sSnmp.managerIP3); 802800c: 4620 mov r0, r4 } 802800e: e8bd 4010 ldmia.w sp!, {r4, lr} } void SetManagerIp3(char *str) { strcpy(sSettings.sSnmp.managerIP3, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP3); 8028012: f00c bf7b b.w 8034f0c 8028016: bf00 nop 8028018: 2000eaec .word 0x2000eaec 0802801c : } void SetManagerIp4(char *str) { 802801c: b510 push {r4, lr} strcpy(sSettings.sSnmp.managerIP4, str); 802801e: 4c05 ldr r4, [pc, #20] ; (8028034 ) strcpy(sSettings.sSnmp.managerIP3, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP3); } void SetManagerIp4(char *str) { 8028020: 4601 mov r1, r0 strcpy(sSettings.sSnmp.managerIP4, str); 8028022: 4620 mov r0, r4 8028024: f7f9 fec6 bl 8021db4 SNMP_SetManagerIP(sSettings.sSnmp.managerIP4); 8028028: 4620 mov r0, r4 } 802802a: e8bd 4010 ldmia.w sp!, {r4, lr} } void SetManagerIp4(char *str) { strcpy(sSettings.sSnmp.managerIP4, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP4); 802802e: f00c bf6d b.w 8034f0c 8028032: bf00 nop 8028034: 2000eb00 .word 0x2000eb00 08028038 : } void SetManagerIp5(char *str) { 8028038: b510 push {r4, lr} strcpy(sSettings.sSnmp.managerIP5, str); 802803a: 4c05 ldr r4, [pc, #20] ; (8028050 ) strcpy(sSettings.sSnmp.managerIP4, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP4); } void SetManagerIp5(char *str) { 802803c: 4601 mov r1, r0 strcpy(sSettings.sSnmp.managerIP5, str); 802803e: 4620 mov r0, r4 8028040: f7f9 feb8 bl 8021db4 SNMP_SetManagerIP(sSettings.sSnmp.managerIP5); 8028044: 4620 mov r0, r4 } 8028046: e8bd 4010 ldmia.w sp!, {r4, lr} } void SetManagerIp5(char *str) { strcpy(sSettings.sSnmp.managerIP5, str); SNMP_SetManagerIP(sSettings.sSnmp.managerIP5); 802804a: f00c bf5f b.w 8034f0c 802804e: bf00 nop 8028050: 2000eb14 .word 0x2000eb14 08028054 : /** * @brief Установить владельца */ void SetOwner(char *str) { 8028054: b510 push {r4, lr} strcpy(sSettings.sSnmp.sysContact, str); 8028056: 4c06 ldr r4, [pc, #24] ; (8028070 ) /** * @brief Установить владельца */ void SetOwner(char *str) { 8028058: 4601 mov r1, r0 strcpy(sSettings.sSnmp.sysContact, str); 802805a: 4620 mov r0, r4 802805c: f7f9 feaa bl 8021db4 SNMP_SetSysContact(sSettings.sSnmp.sysContact); 8028060: 4620 mov r0, r4 8028062: f00c ff37 bl 8034ed4 SNMP_SetObjDescr(); } 8028066: e8bd 4010 ldmia.w sp!, {r4, lr} */ void SetOwner(char *str) { strcpy(sSettings.sSnmp.sysContact, str); SNMP_SetSysContact(sSettings.sSnmp.sysContact); SNMP_SetObjDescr(); 802806a: f00c befd b.w 8034e68 802806e: bf00 nop 8028070: 2000ea10 .word 0x2000ea10 08028074 : /** * @brief Установить местоположение */ void SetLocation(char *str) { 8028074: b510 push {r4, lr} strcpy(sSettings.sSnmp.sysLocation, str); 8028076: 4c05 ldr r4, [pc, #20] ; (802808c ) /** * @brief Установить местоположение */ void SetLocation(char *str) { 8028078: 4601 mov r1, r0 strcpy(sSettings.sSnmp.sysLocation, str); 802807a: 4620 mov r0, r4 802807c: f7f9 fe9a bl 8021db4 SNMP_SetSysLocation(sSettings.sSnmp.sysLocation); 8028080: 4620 mov r0, r4 } 8028082: e8bd 4010 ldmia.w sp!, {r4, lr} * @brief Установить местоположение */ void SetLocation(char *str) { strcpy(sSettings.sSnmp.sysLocation, str); SNMP_SetSysLocation(sSettings.sSnmp.sysLocation); 8028086: f00c bf33 b.w 8034ef0 802808a: bf00 nop 802808c: 2000ea56 .word 0x2000ea56 08028090 : /** * @brief Установить комментарий */ void SetComment(char *str) { 8028090: 4601 mov r1, r0 strcpy(sSettings.sInfo.comments, str); 8028092: 4801 ldr r0, [pc, #4] ; (8028098 ) 8028094: f7f9 be8e b.w 8021db4 8028098: 2000eb72 .word 0x2000eb72 0802809c : // Сетевые параметры RADIUS сервера /** * @brief IP адрес */ void SetRDSIpStr(char *str) { 802809c: 4601 mov r1, r0 strcpy(sSettings.sRADIUS.ServerIP, str); 802809e: 4801 ldr r0, [pc, #4] ; (80280a4 ) 80280a0: f7f9 be88 b.w 8021db4 80280a4: 2000ec60 .word 0x2000ec60 080280a8 : /** * @brief Порт */ void SetRDSPortStr(char *str) { 80280a8: b508 push {r3, lr} sSettings.sRADIUS.port = atoi(str); 80280aa: f7f9 fbe9 bl 8021880 80280ae: 4b02 ldr r3, [pc, #8] ; (80280b8 ) 80280b0: f8c3 03a0 str.w r0, [r3, #928] ; 0x3a0 80280b4: bd08 pop {r3, pc} 80280b6: bf00 nop 80280b8: 2000e8e4 .word 0x2000e8e4 080280bc : /** * @brief Код access */ void SetRDSKeyAccesstStr(char *str) { 80280bc: b508 push {r3, lr} sSettings.sRADIUS.key_access = atoi(str); 80280be: f7f9 fbdf bl 8021880 80280c2: 4b02 ldr r3, [pc, #8] ; (80280cc ) 80280c4: f8c3 03a4 str.w r0, [r3, #932] ; 0x3a4 80280c8: bd08 pop {r3, pc} 80280ca: bf00 nop 80280cc: 2000e8e4 .word 0x2000e8e4 080280d0 : /** * @brief пароль RADIUS */ void SetRDSPasswordkStr(char *str) { 80280d0: 4601 mov r1, r0 strcpy(sSettings.sRADIUS.rds_password, str); 80280d2: 4801 ldr r0, [pc, #4] ; (80280d8 ) 80280d4: f7f9 be6e b.w 8021db4 80280d8: 2000ec70 .word 0x2000ec70 080280dc : /** * @brief Настройка вкл/ выкл RADIUS сервера */ void SetRDSEnableStateStr(char *str) { 80280dc: b508 push {r3, lr} if (strncmp(str, "on", 2) == 0) 80280de: 4906 ldr r1, [pc, #24] ; (80280f8 ) 80280e0: 2202 movs r2, #2 80280e2: f7f9 ff27 bl 8021f34 80280e6: 4b05 ldr r3, [pc, #20] ; (80280fc ) 80280e8: b908 cbnz r0, 80280ee sSettings.sRADIUS.RDSEnable = 1; 80280ea: 2201 movs r2, #1 80280ec: e000 b.n 80280f0 else sSettings.sRADIUS.RDSEnable = 0; 80280ee: 2200 movs r2, #0 80280f0: f883 239d strb.w r2, [r3, #925] ; 0x39d 80280f4: bd08 pop {r3, pc} 80280f6: bf00 nop 80280f8: 08035e94 .word 0x08035e94 80280fc: 2000e8e4 .word 0x2000e8e4 08028100 : /** * @brief Дата */ void SetDateStr(char *str) { 8028100: b510 push {r4, lr} 8028102: b08c sub sp, #48 ; 0x30 8028104: 4604 mov r4, r0 TM_RTC_t tmp_data; char str_data[18]; char str_time[9]; uint8_t len; memset(str_data, 0, 18); 8028106: 2100 movs r1, #0 8028108: 2212 movs r2, #18 802810a: a807 add r0, sp, #28 802810c: f7f9 fcd8 bl 8021ac0 memset(str_time, 0, 9); 8028110: 2100 movs r1, #0 8028112: 2209 movs r2, #9 8028114: 4668 mov r0, sp 8028116: f7f9 fcd3 bl 8021ac0 str += 2; strncpy(str_data, (str + 6), 2); 802811a: f104 0108 add.w r1, r4, #8 802811e: 2202 movs r2, #2 8028120: a807 add r0, sp, #28 8028122: f7f9 ff5d bl 8021fe0 strncat(str_data, (str + 2), 4); 8028126: 1d21 adds r1, r4, #4 8028128: 2204 movs r2, #4 802812a: a807 add r0, sp, #28 802812c: f7f9 fed0 bl 8021ed0 strncat(str_data, str, 2); 8028130: 2202 movs r2, #2 8028132: 1ca1 adds r1, r4, #2 8028134: a807 add r0, sp, #28 8028136: f7f9 fecb bl 8021ed0 TM_RTC_GetDateTime(&tmp_data, TM_RTC_Format_BIN); 802813a: a803 add r0, sp, #12 802813c: 2100 movs r1, #0 802813e: f7fe f9a3 bl 8026488 sprintf(str_time, "-01-%02i:%02i", tmp_data.hours, tmp_data.minutes); 8028142: f89d 2011 ldrb.w r2, [sp, #17] 8028146: f89d 3010 ldrb.w r3, [sp, #16] 802814a: 4908 ldr r1, [pc, #32] ; (802816c ) 802814c: 4668 mov r0, sp 802814e: f7ff faf9 bl 8027744 len = strlen(str_time); 8028152: 4668 mov r0, sp 8028154: f7f9 fe8c bl 8021e70 strncat(str_data, str_time, len); 8028158: 4669 mov r1, sp 802815a: b2c2 uxtb r2, r0 802815c: a807 add r0, sp, #28 802815e: f7f9 feb7 bl 8021ed0 TM_RTC_SetDateTimeString(&str_data); 8028162: a807 add r0, sp, #28 8028164: f7fe f876 bl 8026254 } 8028168: b00c add sp, #48 ; 0x30 802816a: bd10 pop {r4, pc} 802816c: 08035e97 .word 0x08035e97 08028170 : /** * @brief Время */ void SetTimeStr(char *str) { 8028170: b510 push {r4, lr} 8028172: b090 sub sp, #64 ; 0x40 8028174: 4604 mov r4, r0 TM_RTC_t tmp_data; char str_data[18]; char str_date[14]; uint8_t len; memset(str_data, 0, 18); 8028176: 2100 movs r1, #0 8028178: 2212 movs r2, #18 802817a: a80b add r0, sp, #44 ; 0x2c 802817c: f7f9 fca0 bl 8021ac0 memset(str_date, 0, 14); 8028180: 220e movs r2, #14 8028182: 2100 movs r1, #0 8028184: a803 add r0, sp, #12 8028186: f7f9 fc9b bl 8021ac0 TM_RTC_GetDateTime(&tmp_data, TM_RTC_Format_BIN); 802818a: a807 add r0, sp, #28 802818c: 2100 movs r1, #0 802818e: f7fe f97b bl 8026488 sprintf(str_date, "%02i-%02i-%02i-01-", tmp_data.date, tmp_data.month, tmp_data.year); 8028192: f89d 1025 ldrb.w r1, [sp, #37] ; 0x25 8028196: f89d 3024 ldrb.w r3, [sp, #36] ; 0x24 802819a: f89d 2023 ldrb.w r2, [sp, #35] ; 0x23 802819e: 9100 str r1, [sp, #0] 80281a0: a803 add r0, sp, #12 80281a2: 490a ldr r1, [pc, #40] ; (80281cc ) 80281a4: f7ff face bl 8027744 len = strlen(str_date); 80281a8: a803 add r0, sp, #12 80281aa: f7f9 fe61 bl 8021e70 strncat(str_data, str_date, len); 80281ae: a903 add r1, sp, #12 80281b0: b2c2 uxtb r2, r0 80281b2: a80b add r0, sp, #44 ; 0x2c 80281b4: f7f9 fe8c bl 8021ed0 strncat(str_data, str, 5); 80281b8: a80b add r0, sp, #44 ; 0x2c 80281ba: 4621 mov r1, r4 80281bc: 2205 movs r2, #5 80281be: f7f9 fe87 bl 8021ed0 TM_RTC_SetDateTimeString(&str_data); 80281c2: a80b add r0, sp, #44 ; 0x2c 80281c4: f7fe f846 bl 8026254 } 80281c8: b010 add sp, #64 ; 0x40 80281ca: bd10 pop {r4, pc} 80281cc: 08035ea5 .word 0x08035ea5 080281d0 : /** * @brief Состояние SNTP */ void SetSntpStateStr(char *str) { 80281d0: b538 push {r3, r4, r5, lr} bool old_sntpEnable = sSettings.sSNTP.sntpEnable; 80281d2: 4c0d ldr r4, [pc, #52] ; (8028208 ) if (strncmp(str, "1", 1) == 0){ 80281d4: 490d ldr r1, [pc, #52] ; (802820c ) /** * @brief Состояние SNTP */ void SetSntpStateStr(char *str) { bool old_sntpEnable = sSettings.sSNTP.sntpEnable; 80281d6: f894 5344 ldrb.w r5, [r4, #836] ; 0x344 if (strncmp(str, "1", 1) == 0){ 80281da: 2201 movs r2, #1 80281dc: f7f9 feaa bl 8021f34 80281e0: b948 cbnz r0, 80281f6 sSettings.sSNTP.sntpEnable = true; 80281e2: 2001 movs r0, #1 80281e4: f884 0344 strb.w r0, [r4, #836] ; 0x344 if(old_sntpEnable != sSettings.sSNTP.sntpEnable){ 80281e8: b965 cbnz r5, 8028204 SNTP_Enable(sSettings.sSNTP.sntpEnable); 80281ea: f00c ff05 bl 8034ff8 } else{ sSettings.sSNTP.sntpEnable = false; SNTP_Enable(sSettings.sSNTP.sntpEnable); } } 80281ee: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} bool old_sntpEnable = sSettings.sSNTP.sntpEnable; if (strncmp(str, "1", 1) == 0){ sSettings.sSNTP.sntpEnable = true; if(old_sntpEnable != sSettings.sSNTP.sntpEnable){ SNTP_Enable(sSettings.sSNTP.sntpEnable); SNTP_Poll(); 80281f2: f00c bf43 b.w 803507c } } else{ sSettings.sSNTP.sntpEnable = false; 80281f6: 2000 movs r0, #0 80281f8: f884 0344 strb.w r0, [r4, #836] ; 0x344 SNTP_Enable(sSettings.sSNTP.sntpEnable); } } 80281fc: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} SNTP_Poll(); } } else{ sSettings.sSNTP.sntpEnable = false; SNTP_Enable(sSettings.sSNTP.sntpEnable); 8028200: f00c befa b.w 8034ff8 8028204: bd38 pop {r3, r4, r5, pc} 8028206: bf00 nop 8028208: 2000e8e4 .word 0x2000e8e4 802820c: 08035f50 .word 0x08035f50 08028210 : /** * @brief IP адрес SNTP сервера */ void SetSntpServerIpStr(char *str) { 8028210: 4601 mov r1, r0 strcpy(sSettings.sSNTP.ip, str); 8028212: 4801 ldr r0, [pc, #4] ; (8028218 ) 8028214: f7f9 bdce b.w 8021db4 8028218: 2000ec29 .word 0x2000ec29 0802821c : /** * @brief Часовой пояс контроллера */ void SetSntpTimeZoneStr(char *str) { 802821c: b570 push {r4, r5, r6, lr} float newUtc; newUtc = atof(str); 802821e: f7f9 fb2b bl 8021878 8028222: f7f8 fc8f bl 8020b44 <__aeabi_d2f> if (sSettings.sSNTP.timeZone > 0) 8028226: 4b27 ldr r3, [pc, #156] ; (80282c4 ) 8028228: f8d3 4374 ldr.w r4, [r3, #884] ; 0x374 */ void SetSntpTimeZoneStr(char *str) { float newUtc; newUtc = atof(str); 802822c: 4606 mov r6, r0 if (sSettings.sSNTP.timeZone > 0) 802822e: 2100 movs r1, #0 8028230: 4620 mov r0, r4 8028232: f7f8 fe51 bl 8020ed8 <__aeabi_fcmpgt> 8028236: b100 cbz r0, 802823a 8028238: e033 b.n 80282a2 { TM_RTC_Correction(newUtc - sSettings.sSNTP.timeZone); } } else if (sSettings.sSNTP.timeZone < 0) 802823a: 4620 mov r0, r4 802823c: 2100 movs r1, #0 802823e: f7f8 fe2d bl 8020e9c <__aeabi_fcmplt> 8028242: 2800 cmp r0, #0 8028244: d032 beq.n 80282ac { if (newUtc >= 0) 8028246: 4630 mov r0, r6 8028248: 2100 movs r1, #0 802824a: f7f8 fe3b bl 8020ec4 <__aeabi_fcmpge> 802824e: b170 cbz r0, 802826e { TM_RTC_Correction(newUtc + fabs(sSettings.sSNTP.timeZone)); 8028250: 4620 mov r0, r4 8028252: f7f8 f961 bl 8020518 <__aeabi_f2d> 8028256: f7fd f815 bl 8025284 802825a: 4604 mov r4, r0 802825c: 460d mov r5, r1 802825e: 4630 mov r0, r6 8028260: f7f8 f95a bl 8020518 <__aeabi_f2d> 8028264: 4622 mov r2, r4 8028266: 462b mov r3, r5 8028268: f7f7 fff8 bl 802025c <__adddf3> 802826c: e016 b.n 802829c } else { if (newUtc >= sSettings.sSNTP.timeZone) 802826e: 4630 mov r0, r6 8028270: 4621 mov r1, r4 8028272: f7f8 fe27 bl 8020ec4 <__aeabi_fcmpge> 8028276: b1a0 cbz r0, 80282a2 TM_RTC_Correction(fabs(sSettings.sSNTP.timeZone) - fabs(newUtc)); 8028278: 4620 mov r0, r4 802827a: f7f8 f94d bl 8020518 <__aeabi_f2d> 802827e: f7fd f801 bl 8025284 8028282: 4604 mov r4, r0 8028284: 4630 mov r0, r6 8028286: 460d mov r5, r1 8028288: f7f8 f946 bl 8020518 <__aeabi_f2d> 802828c: f7fc fffa bl 8025284 8028290: 4602 mov r2, r0 8028292: 460b mov r3, r1 8028294: 4620 mov r0, r4 8028296: 4629 mov r1, r5 8028298: f7f7 ffde bl 8020258 <__aeabi_dsub> 802829c: f7f8 fc52 bl 8020b44 <__aeabi_d2f> 80282a0: e00a b.n 80282b8 else TM_RTC_Correction(newUtc - sSettings.sSNTP.timeZone); 80282a2: 4630 mov r0, r6 80282a4: 4621 mov r1, r4 80282a6: f7f8 fca1 bl 8020bec <__aeabi_fsub> 80282aa: e005 b.n 80282b8 } } else if (sSettings.sSNTP.timeZone == 0) 80282ac: 4620 mov r0, r4 80282ae: 2100 movs r1, #0 80282b0: f7f8 fdea bl 8020e88 <__aeabi_fcmpeq> 80282b4: b110 cbz r0, 80282bc { TM_RTC_Correction(newUtc); 80282b6: 4630 mov r0, r6 80282b8: f7fe f9e2 bl 8026680 } sSettings.sSNTP.timeZone = newUtc; // atof(str); 80282bc: 4b01 ldr r3, [pc, #4] ; (80282c4 ) 80282be: f8c3 6374 str.w r6, [r3, #884] ; 0x374 80282c2: bd70 pop {r4, r5, r6, pc} 80282c4: 2000e8e4 .word 0x2000e8e4 080282c8 : /** * @brief Тип действий при срабатывание сухих контактов */ void SetDINTypeActStr(char *str, uint8_t num) { 80282c8: b510 push {r4, lr} 80282ca: 460c mov r4, r1 sSettings.sInOuts.din_type_act[num] = atoi(str); 80282cc: f7f9 fad8 bl 8021880 80282d0: 4902 ldr r1, [pc, #8] ; (80282dc ) 80282d2: 1909 adds r1, r1, r4 80282d4: f881 037a strb.w r0, [r1, #890] ; 0x37a 80282d8: bd10 pop {r4, pc} 80282da: bf00 nop 80282dc: 2000e8e4 .word 0x2000e8e4 080282e0 : /** * @brief Источник срабатывания реле */ void SetROTypeActStr(char *str, uint8_t num) { 80282e0: b510 push {r4, lr} 80282e2: 460c mov r4, r1 sSettings.sInOuts.ro_type_source[num] = atoi(str); 80282e4: f7f9 facc bl 8021880 80282e8: 4902 ldr r1, [pc, #8] ; (80282f4 ) 80282ea: 1909 adds r1, r1, r4 80282ec: f881 0378 strb.w r0, [r1, #888] ; 0x378 80282f0: bd10 pop {r4, pc} 80282f2: bf00 nop 80282f4: 2000e8e4 .word 0x2000e8e4 080282f8 : /** * @brief Установить параметры обновления ПО по умолчанию */ void SETTINGS_SetBootParamsDef(void) { sSettings.bootParams.loadMode = 1; 80282f8: 4b02 ldr r3, [pc, #8] ; (8028304 ) 80282fa: 2201 movs r2, #1 80282fc: 701a strb r2, [r3, #0] sSettings.bootParams.bootTry = 0; 80282fe: 2200 movs r2, #0 8028300: 705a strb r2, [r3, #1] 8028302: 4770 bx lr 8028304: 2000e8e4 .word 0x2000e8e4 08028308 : /** * @brief Установить параметры сетевого подключения по умолчанию */ void SETTINGS_SetWebParamsDef(void) { 8028308: b510 push {r4, lr} strcpy(sSettings.sWebParams.ip, "192.168.1.2"); 802830a: 4c09 ldr r4, [pc, #36] ; (8028330 ) 802830c: 4909 ldr r1, [pc, #36] ; (8028334 ) 802830e: 4620 mov r0, r4 8028310: f7f9 fd50 bl 8021db4 strcpy(sSettings.sWebParams.gate, "192.168.1.1"); 8028314: 4908 ldr r1, [pc, #32] ; (8028338 ) 8028316: f104 0010 add.w r0, r4, #16 802831a: f7f9 fd4b bl 8021db4 strcpy(sSettings.sWebParams.mask, "255.255.255.0"); 802831e: f104 0020 add.w r0, r4, #32 8028322: 4906 ldr r1, [pc, #24] ; (802833c ) 8028324: f7f9 fd46 bl 8021db4 sSettings.sWebParams.dhcpEnable = 1; 8028328: 2201 movs r2, #1 802832a: f884 2030 strb.w r2, [r4, #48] ; 0x30 802832e: bd10 pop {r4, pc} 8028330: 2000e8e6 .word 0x2000e8e6 8028334: 08035eb8 .word 0x08035eb8 8028338: 08035ec4 .word 0x08035ec4 802833c: 08035ed0 .word 0x08035ed0 08028340 : /** * @brief Установить временные параметры сетевого подключения по умолчанию */ void SETTINGS_SetTempWebParamsDef(void) { 8028340: b510 push {r4, lr} strcpy(sSettings.sWebParams.ip, "192.168.1.2"); 8028342: 4c09 ldr r4, [pc, #36] ; (8028368 ) 8028344: 4909 ldr r1, [pc, #36] ; (802836c ) 8028346: 4620 mov r0, r4 8028348: f7f9 fd34 bl 8021db4 strcpy(sSettings.sWebParams.gate, "192.168.1.1"); 802834c: 4908 ldr r1, [pc, #32] ; (8028370 ) 802834e: f104 0010 add.w r0, r4, #16 8028352: f7f9 fd2f bl 8021db4 strcpy(sSettings.sWebParams.mask, "255.255.255.0"); 8028356: f104 0020 add.w r0, r4, #32 802835a: 4906 ldr r1, [pc, #24] ; (8028374 ) 802835c: f7f9 fd2a bl 8021db4 sSettings.sWebParams.dhcpEnable = 1; 8028360: 2201 movs r2, #1 8028362: f884 2030 strb.w r2, [r4, #48] ; 0x30 8028366: bd10 pop {r4, pc} 8028368: 2000e8e6 .word 0x2000e8e6 802836c: 08035eb8 .word 0x08035eb8 8028370: 08035ec4 .word 0x08035ec4 8028374: 08035ed0 .word 0x08035ed0 08028378 : /** * @brief Установить параметры SNMP по умолчанию */ void SETTINGS_SetSnmpDef(void) { 8028378: b570 push {r4, r5, r6, lr} strcpy(sSettings.sSnmp.sysDescr, ""); 802837a: 4c1e ldr r4, [pc, #120] ; (80283f4 ) 802837c: 4d1e ldr r5, [pc, #120] ; (80283f8 ) strcpy(sSettings.sSnmp.readCommunity, "public"); 802837e: 4e1f ldr r6, [pc, #124] ; (80283fc ) /** * @brief Установить параметры SNMP по умолчанию */ void SETTINGS_SetSnmpDef(void) { strcpy(sSettings.sSnmp.sysDescr, ""); 8028380: 4629 mov r1, r5 8028382: 4620 mov r0, r4 8028384: f7f9 fd16 bl 8021db4 strcpy(sSettings.sSnmp.readCommunity, "public"); 8028388: 4631 mov r1, r6 802838a: f104 00a0 add.w r0, r4, #160 ; 0xa0 802838e: f7f9 fd11 bl 8021db4 strcpy(sSettings.sSnmp.writeCommunity, "public"); 8028392: 4631 mov r1, r6 8028394: f104 00b4 add.w r0, r4, #180 ; 0xb4 8028398: f7f9 fd0c bl 8021db4 strcpy(sSettings.sSnmp.sysContact, ""); 802839c: 4629 mov r1, r5 802839e: f104 00c8 add.w r0, r4, #200 ; 0xc8 80283a2: f7f9 fd07 bl 8021db4 strcpy(sSettings.sSnmp.sysName, "BT-6701"); 80283a6: f104 00fa add.w r0, r4, #250 ; 0xfa 80283aa: 4915 ldr r1, [pc, #84] ; (8028400 ) 80283ac: f7f9 fd02 bl 8021db4 strcpy(sSettings.sSnmp.sysLocation, ""); 80283b0: 4629 mov r1, r5 strcpy(sSettings.sSnmp.managerIP, "0.0.0.0"); 80283b2: 4d14 ldr r5, [pc, #80] ; (8028404 ) strcpy(sSettings.sSnmp.sysDescr, ""); strcpy(sSettings.sSnmp.readCommunity, "public"); strcpy(sSettings.sSnmp.writeCommunity, "public"); strcpy(sSettings.sSnmp.sysContact, ""); strcpy(sSettings.sSnmp.sysName, "BT-6701"); strcpy(sSettings.sSnmp.sysLocation, ""); 80283b4: f504 7087 add.w r0, r4, #270 ; 0x10e 80283b8: f7f9 fcfc bl 8021db4 strcpy(sSettings.sSnmp.managerIP, "0.0.0.0"); 80283bc: 4629 mov r1, r5 80283be: f504 70be add.w r0, r4, #380 ; 0x17c 80283c2: f7f9 fcf7 bl 8021db4 strcpy(sSettings.sSnmp.managerIP2, "0.0.0.0"); 80283c6: 4629 mov r1, r5 80283c8: f504 70c8 add.w r0, r4, #400 ; 0x190 80283cc: f7f9 fcf2 bl 8021db4 strcpy(sSettings.sSnmp.managerIP3, "0.0.0.0"); 80283d0: 4629 mov r1, r5 80283d2: f504 70d2 add.w r0, r4, #420 ; 0x1a4 80283d6: f7f9 fced bl 8021db4 strcpy(sSettings.sSnmp.managerIP4, "0.0.0.0"); 80283da: 4629 mov r1, r5 80283dc: f504 70dc add.w r0, r4, #440 ; 0x1b8 80283e0: f7f9 fce8 bl 8021db4 strcpy(sSettings.sSnmp.managerIP5, "0.0.0.0"); 80283e4: f504 70e6 add.w r0, r4, #460 ; 0x1cc 80283e8: 4629 mov r1, r5 } 80283ea: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} strcpy(sSettings.sSnmp.sysLocation, ""); strcpy(sSettings.sSnmp.managerIP, "0.0.0.0"); strcpy(sSettings.sSnmp.managerIP2, "0.0.0.0"); strcpy(sSettings.sSnmp.managerIP3, "0.0.0.0"); strcpy(sSettings.sSnmp.managerIP4, "0.0.0.0"); strcpy(sSettings.sSnmp.managerIP5, "0.0.0.0"); 80283ee: f7f9 bce1 b.w 8021db4 80283f2: bf00 nop 80283f4: 2000e948 .word 0x2000e948 80283f8: 0803a119 .word 0x0803a119 80283fc: 08035ede .word 0x08035ede 8028400: 08035ee5 .word 0x08035ee5 8028404: 08035eed .word 0x08035eed 08028408 : /** * @brief Установить Информацию об устройстве по умолчанию */ void SETTINGS_SetInfoDef(void) { 8028408: b510 push {r4, lr} strcpy(sSettings.sInfo.productionData, "08.07.2016"); 802840a: 4c0b ldr r4, [pc, #44] ; (8028438 ) 802840c: 490b ldr r1, [pc, #44] ; (802843c ) 802840e: 4620 mov r0, r4 8028410: f7f9 fcd0 bl 8021db4 //strcpy(sSettings.sInfo.mac, "EC-4C-4D-00-90-01"); strcpy(sSettings.sInfo.mac, "EC-4C-4D-00-00-0A"); 8028414: f104 0028 add.w r0, r4, #40 ; 0x28 8028418: 4909 ldr r1, [pc, #36] ; (8028440 ) 802841a: f7f9 fccb bl 8021db4 strcpy(sSettings.sInfo.serialNumber, "KN-03-00001"); 802841e: f104 003a add.w r0, r4, #58 ; 0x3a 8028422: 4908 ldr r1, [pc, #32] ; (8028444 ) 8028424: f7f9 fcc6 bl 8021db4 strcpy(sSettings.sInfo.comments, ""); 8028428: 4907 ldr r1, [pc, #28] ; (8028448 ) 802842a: f104 004a add.w r0, r4, #74 ; 0x4a } 802842e: e8bd 4010 ldmia.w sp!, {r4, lr} { strcpy(sSettings.sInfo.productionData, "08.07.2016"); //strcpy(sSettings.sInfo.mac, "EC-4C-4D-00-90-01"); strcpy(sSettings.sInfo.mac, "EC-4C-4D-00-00-0A"); strcpy(sSettings.sInfo.serialNumber, "KN-03-00001"); strcpy(sSettings.sInfo.comments, ""); 8028432: f7f9 bcbf b.w 8021db4 8028436: bf00 nop 8028438: 2000eb28 .word 0x2000eb28 802843c: 08035ef5 .word 0x08035ef5 8028440: 08035f00 .word 0x08035f00 8028444: 08035f12 .word 0x08035f12 8028448: 0803a119 .word 0x0803a119 0802844c : /** * @brief Установить значение сервисных настроек по умолчанию */ void SETTINGS_SetServiceDef(void) { 802844c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8028450: 4d13 ldr r5, [pc, #76] ; (80284a0 ) 8028452: 2400 movs r4, #0 } /** * @brief Установить значение сервисных настроек по умолчанию */ void SETTINGS_SetServiceDef(void) 8028454: 2717 movs r7, #23 strcpy(sSettings.sAuth[user_id].login, "admin"); strcpy(sSettings.sAuth[user_id].password, "12345"); break; case 1: default: sSettings.sAuth[user_id].level = USER; 8028456: f04f 0801 mov.w r8, #1 { uint8_t user_id; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { switch (user_id) { 802845a: f014 03ff ands.w r3, r4, #255 ; 0xff 802845e: d108 bne.n 8028472 /* First users in the system is always ADMIN. * Others are USER */ case 0: sSettings.sAuth[user_id].level = ADMIN; strcpy(sSettings.sAuth[user_id].login, "admin"); 8028460: 4910 ldr r1, [pc, #64] ; (80284a4 ) 8028462: 4811 ldr r0, [pc, #68] ; (80284a8 ) for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { switch (user_id) { /* First users in the system is always ADMIN. * Others are USER */ case 0: sSettings.sAuth[user_id].level = ADMIN; 8028464: f885 3314 strb.w r3, [r5, #788] ; 0x314 strcpy(sSettings.sAuth[user_id].login, "admin"); 8028468: f7f9 fca4 bl 8021db4 strcpy(sSettings.sAuth[user_id].password, "12345"); 802846c: 480f ldr r0, [pc, #60] ; (80284ac ) 802846e: 4910 ldr r1, [pc, #64] ; (80284b0 ) 8028470: e00f b.n 8028492 } /** * @brief Установить значение сервисных настроек по умолчанию */ void SETTINGS_SetServiceDef(void) 8028472: fb07 f604 mul.w r6, r7, r4 8028476: 19ab adds r3, r5, r6 strcpy(sSettings.sAuth[user_id].password, "12345"); break; case 1: default: sSettings.sAuth[user_id].level = USER; strcpy(sSettings.sAuth[user_id].login, "user"); 8028478: f506 7044 add.w r0, r6, #784 ; 0x310 802847c: 1828 adds r0, r5, r0 802847e: 490d ldr r1, [pc, #52] ; (80284b4 ) strcpy(sSettings.sAuth[user_id].login, "admin"); strcpy(sSettings.sAuth[user_id].password, "12345"); break; case 1: default: sSettings.sAuth[user_id].level = USER; 8028480: f883 8314 strb.w r8, [r3, #788] ; 0x314 strcpy(sSettings.sAuth[user_id].login, "user"); 8028484: 3005 adds r0, #5 8028486: f7f9 fc95 bl 8021db4 strcpy(sSettings.sAuth[user_id].password, "1234"); 802848a: 19a8 adds r0, r5, r6 802848c: 490a ldr r1, [pc, #40] ; (80284b8 ) 802848e: f500 7048 add.w r0, r0, #800 ; 0x320 8028492: 3401 adds r4, #1 8028494: f7f9 fc8e bl 8021db4 void SETTINGS_SetServiceDef(void) { uint8_t user_id; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 8028498: 2c02 cmp r4, #2 802849a: d1de bne.n 802845a strcpy(sSettings.sAuth[user_id].login, "user"); strcpy(sSettings.sAuth[user_id].password, "1234"); break; } } } 802849c: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 80284a0: 2000e8e4 .word 0x2000e8e4 80284a4: 08035f1e .word 0x08035f1e 80284a8: 2000ebf9 .word 0x2000ebf9 80284ac: 2000ec04 .word 0x2000ec04 80284b0: 08035f24 .word 0x08035f24 80284b4: 08035f2a .word 0x08035f2a 80284b8: 08035f2f .word 0x08035f2f 080284bc : /** * @brief Установить параметры SNTP по умолчанию */ void SETTINGS_SetSntpDef(void) { 80284bc: b510 push {r4, lr} sSettings.sSNTP.sntpEnable = true; 80284be: 4c08 ldr r4, [pc, #32] ; (80284e0 ) strcpy(sSettings.sSNTP.ip, "88.147.254.235"); 80284c0: 4908 ldr r1, [pc, #32] ; (80284e4 ) 80284c2: 4809 ldr r0, [pc, #36] ; (80284e8 ) /** * @brief Установить параметры SNTP по умолчанию */ void SETTINGS_SetSntpDef(void) { sSettings.sSNTP.sntpEnable = true; 80284c4: 2301 movs r3, #1 80284c6: f884 3344 strb.w r3, [r4, #836] ; 0x344 strcpy(sSettings.sSNTP.ip, "88.147.254.235"); 80284ca: f7f9 fc73 bl 8021db4 sSettings.sSNTP.timeZone = 3.0; 80284ce: 4b07 ldr r3, [pc, #28] ; (80284ec ) strcpy(sSettings.sSNTP.data, "none"); 80284d0: 4807 ldr r0, [pc, #28] ; (80284f0 ) 80284d2: 4908 ldr r1, [pc, #32] ; (80284f4 ) */ void SETTINGS_SetSntpDef(void) { sSettings.sSNTP.sntpEnable = true; strcpy(sSettings.sSNTP.ip, "88.147.254.235"); sSettings.sSNTP.timeZone = 3.0; 80284d4: f8c4 3374 str.w r3, [r4, #884] ; 0x374 strcpy(sSettings.sSNTP.data, "none"); } 80284d8: e8bd 4010 ldmia.w sp!, {r4, lr} void SETTINGS_SetSntpDef(void) { sSettings.sSNTP.sntpEnable = true; strcpy(sSettings.sSNTP.ip, "88.147.254.235"); sSettings.sSNTP.timeZone = 3.0; strcpy(sSettings.sSNTP.data, "none"); 80284dc: f7f9 bc6a b.w 8021db4 80284e0: 2000e8e4 .word 0x2000e8e4 80284e4: 08035f34 .word 0x08035f34 80284e8: 2000ec29 .word 0x2000ec29 80284ec: 40400000 .word 0x40400000 80284f0: 2000ec39 .word 0x2000ec39 80284f4: 08035f43 .word 0x08035f43 080284f8 : /** * @brief Установить параметры настроек сухих контактов / реле по умолчанию */ void SETTINGS_SetINOUTSDef(void) { sSettings.sInOuts.ro_type_source[0] = CRITICAL; 80284f8: 4b05 ldr r3, [pc, #20] ; (8028510 ) 80284fa: 2201 movs r2, #1 80284fc: f883 2378 strb.w r2, [r3, #888] ; 0x378 sSettings.sInOuts.ro_type_source[1] = SNMP_SET; 8028500: 2203 movs r2, #3 8028502: f883 2379 strb.w r2, [r3, #889] ; 0x379 sSettings.sInOuts.din_type_act[0] = SNMP_TRAP; 8028506: 2202 movs r2, #2 8028508: f883 237a strb.w r2, [r3, #890] ; 0x37a 802850c: 4770 bx lr 802850e: bf00 nop 8028510: 2000e8e4 .word 0x2000e8e4 08028514 : /** * @brief Установить параметры RADIUS по умолчанию */ void SETTINGS_SetRADIUSDef(void) { 8028514: b510 push {r4, lr} sSettings.sRADIUS.RDSEnable = true; 8028516: 4c0b ldr r4, [pc, #44] ; (8028544 ) strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); 8028518: 490b ldr r1, [pc, #44] ; (8028548 ) /** * @brief Установить параметры RADIUS по умолчанию */ void SETTINGS_SetRADIUSDef(void) { sSettings.sRADIUS.RDSEnable = true; 802851a: 2301 movs r3, #1 strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); 802851c: f504 705f add.w r0, r4, #892 ; 0x37c /** * @brief Установить параметры RADIUS по умолчанию */ void SETTINGS_SetRADIUSDef(void) { sSettings.sRADIUS.RDSEnable = true; 8028520: f884 339d strb.w r3, [r4, #925] ; 0x39d strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); 8028524: f7f9 fc46 bl 8021db4 sSettings.sRADIUS.port = 1227; 8028528: f240 43cb movw r3, #1227 ; 0x4cb sSettings.sRADIUS.key_access = 123; strcpy(sSettings.sRADIUS.rds_password, "12345"); 802852c: 4907 ldr r1, [pc, #28] ; (802854c ) */ void SETTINGS_SetRADIUSDef(void) { sSettings.sRADIUS.RDSEnable = true; strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); sSettings.sRADIUS.port = 1227; 802852e: f8c4 33a0 str.w r3, [r4, #928] ; 0x3a0 sSettings.sRADIUS.key_access = 123; strcpy(sSettings.sRADIUS.rds_password, "12345"); 8028532: f504 7063 add.w r0, r4, #908 ; 0x38c void SETTINGS_SetRADIUSDef(void) { sSettings.sRADIUS.RDSEnable = true; strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); sSettings.sRADIUS.port = 1227; sSettings.sRADIUS.key_access = 123; 8028536: 237b movs r3, #123 ; 0x7b 8028538: f8c4 33a4 str.w r3, [r4, #932] ; 0x3a4 strcpy(sSettings.sRADIUS.rds_password, "12345"); } 802853c: e8bd 4010 ldmia.w sp!, {r4, lr} { sSettings.sRADIUS.RDSEnable = true; strcpy(sSettings.sRADIUS.ServerIP, "127.0.0.1"); sSettings.sRADIUS.port = 1227; sSettings.sRADIUS.key_access = 123; strcpy(sSettings.sRADIUS.rds_password, "12345"); 8028540: f7f9 bc38 b.w 8021db4 8028544: 2000e8e4 .word 0x2000e8e4 8028548: 08035f48 .word 0x08035f48 802854c: 08035f24 .word 0x08035f24 08028550 : */ void SETTINGS_ReadFromFlash(uint8_t *data, uint32_t size) { uint32_t baseAddress = SETTINGS_SECTOR; for (uint32_t i = 0; i < size; i++) 8028550: 2300 movs r3, #0 8028552: e006 b.n 8028562 *data++ = (*(uint32_t*)baseAddress++);; 8028554: f103 6200 add.w r2, r3, #134217728 ; 0x8000000 8028558: f502 4280 add.w r2, r2, #16384 ; 0x4000 802855c: 6812 ldr r2, [r2, #0] 802855e: 54c2 strb r2, [r0, r3] */ void SETTINGS_ReadFromFlash(uint8_t *data, uint32_t size) { uint32_t baseAddress = SETTINGS_SECTOR; for (uint32_t i = 0; i < size; i++) 8028560: 3301 adds r3, #1 8028562: 428b cmp r3, r1 8028564: d1f6 bne.n 8028554 *data++ = (*(uint32_t*)baseAddress++);; } 8028566: 4770 bx lr 08028568 : */ void SETTINGS_EraseFlashSector(void) { FLASH_Status status; if ((status = FLASH_EraseSector(FLASH_Sector_1, VoltageRange_3)) != FLASH_COMPLETE) { 8028568: 2008 movs r0, #8 802856a: 2102 movs r1, #2 802856c: f7fc bf6c b.w 8025448 08028570 : /** * @brief * @retval */ uint32_t SETTINGS_GetCRC(void) { 8028570: b508 push {r3, lr} CRC_ResetDR(); 8028572: f7fc fed3 bl 802531c return CRC_CalcBlockCRC((uint32_t*)&sSettings, sizeof(sSettings)/4); 8028576: 4803 ldr r0, [pc, #12] ; (8028584 ) 8028578: 21ea movs r1, #234 ; 0xea } 802857a: e8bd 4008 ldmia.w sp!, {r3, lr} * @retval */ uint32_t SETTINGS_GetCRC(void) { CRC_ResetDR(); return CRC_CalcBlockCRC((uint32_t*)&sSettings, sizeof(sSettings)/4); 802857e: f7fc bed3 b.w 8025328 8028582: bf00 nop 8028584: 2000e8e4 .word 0x2000e8e4 08028588 : /** * @brief */ void SETTINGS_WriteToFlash(uint8_t *data, uint32_t size) { 8028588: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} 802858c: 4606 mov r6, r0 802858e: 468a mov sl, r1 uint32_t baseAddress = SETTINGS_SECTOR; uint32_t checkCrc = 0; uint32_t crc = SETTINGS_GetCRC(); 8028590: f7ff ffee bl 8028570 /** * @brief */ void SETTINGS_WriteToFlash(uint8_t *data, uint32_t size) { uint32_t baseAddress = SETTINGS_SECTOR; 8028594: 4c17 ldr r4, [pc, #92] ; (80285f4 ) uint32_t checkCrc = 0; uint32_t crc = SETTINGS_GetCRC(); 8028596: 4680 mov r8, r0 8028598: 2703 movs r7, #3 FLASH_Status status; for (uint8_t i = 0; i < 3; i++) { fAlarm = 0; FLASH_Unlock(); 802859a: f7fc fed5 bl 8025348 802859e: 4635 mov r5, r6 SETTINGS_EraseFlashSector(); 80285a0: f7ff ffe2 bl 8028568 } /** * @brief */ void SETTINGS_WriteToFlash(uint8_t *data, uint32_t size) 80285a4: eb04 0b0a add.w fp, r4, sl fAlarm = 0; FLASH_Unlock(); SETTINGS_EraseFlashSector(); for (uint32_t i = 0; i < size; i++) 80285a8: e00a b.n 80285c0 if ((status = FLASH_ProgramByte(baseAddress++, *data++)) != FLASH_COMPLETE) { 80285aa: f815 1b01 ldrb.w r1, [r5], #1 80285ae: 4620 mov r0, r4 80285b0: f7fc ff10 bl 80253d4 80285b4: f104 0901 add.w r9, r4, #1 80285b8: 2808 cmp r0, #8 80285ba: 462e mov r6, r5 80285bc: 464c mov r4, r9 80285be: d102 bne.n 80285c6 fAlarm = 0; FLASH_Unlock(); SETTINGS_EraseFlashSector(); for (uint32_t i = 0; i < size; i++) 80285c0: 455c cmp r4, fp 80285c2: 462e mov r6, r5 80285c4: d1f1 bne.n 80285aa if ((status = FLASH_ProgramByte(baseAddress++, *data++)) != FLASH_COMPLETE) { DBG printf("FLASH_ProgramByte error: status = %d\r\n", status); break; } if ((status = FLASH_ProgramWord((uint32_t)CRC_ADDRESS, crc)) != FLASH_COMPLETE) { 80285c6: 4641 mov r1, r8 80285c8: 480b ldr r0, [pc, #44] ; (80285f8 ) 80285ca: f7fc ff1f bl 802540c DBG printf("FLASH_ProgramWord error: status = %d\r\n", status); } FLASH_Lock(); 80285ce: f7fc fec9 bl 8025364 /* Считываем что записали */ SETTINGS_ReadFromFlash((uint8_t*)&sSettings, sizeof(sSettings)); 80285d2: 480a ldr r0, [pc, #40] ; (80285fc ) 80285d4: f44f 716a mov.w r1, #936 ; 0x3a8 80285d8: f7ff ffba bl 8028550 checkCrc = SETTINGS_GetCRC(); 80285dc: f7ff ffc8 bl 8028570 /* Проверяем CRC того что было записано */ if (checkCrc == crc) 80285e0: 4540 cmp r0, r8 80285e2: d004 beq.n 80285ee 80285e4: 3f01 subs r7, #1 uint32_t checkCrc = 0; uint32_t crc = SETTINGS_GetCRC(); bool fAlarm = 0; FLASH_Status status; for (uint8_t i = 0; i < 3; i++) 80285e6: f017 07ff ands.w r7, r7, #255 ; 0xff 80285ea: d1d6 bne.n 802859a 80285ec: e7fe b.n 80285ec 80285ee: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 80285f2: bf00 nop 80285f4: 08004000 .word 0x08004000 80285f8: 08007f9c .word 0x08007f9c 80285fc: 2000e8e4 .word 0x2000e8e4 08028600 : /** * @brief * @retval */ uint32_t SETTINGS_GetCritSecCRC(void) { 8028600: b508 push {r3, lr} CRC_ResetDR(); 8028602: f7fc fe8b bl 802531c uint32_t critsec_len = (uint32_t)((uint8_t *)(&sSettings.CritSecCRC) - (uint8_t *)&sSettings) / 4; return CRC_CalcBlockCRC((uint32_t *)&sSettings, critsec_len); 8028606: 4803 ldr r0, [pc, #12] ; (8028614 ) 8028608: 21c4 movs r1, #196 ; 0xc4 } 802860a: e8bd 4008 ldmia.w sp!, {r3, lr} */ uint32_t SETTINGS_GetCritSecCRC(void) { CRC_ResetDR(); uint32_t critsec_len = (uint32_t)((uint8_t *)(&sSettings.CritSecCRC) - (uint8_t *)&sSettings) / 4; return CRC_CalcBlockCRC((uint32_t *)&sSettings, critsec_len); 802860e: f7fc be8b b.w 8025328 8028612: bf00 nop 8028614: 2000e8e4 .word 0x2000e8e4 08028618 : /** * @brief Запись структуры настроек во flesh */ void SETTINGS_Save(void) { 8028618: b508 push {r3, lr} /* Calc critical section CRC and store to the settings structure */ sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); 802861a: f7ff fff1 bl 8028600 802861e: 4b05 ldr r3, [pc, #20] ; (8028634 ) SETTINGS_WriteToFlash((uint8_t*)&sSettings, sizeof(sSettings)); 8028620: f44f 716a mov.w r1, #936 ; 0x3a8 * @brief Запись структуры настроек во flesh */ void SETTINGS_Save(void) { /* Calc critical section CRC and store to the settings structure */ sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); 8028624: f8c3 0310 str.w r0, [r3, #784] ; 0x310 SETTINGS_WriteToFlash((uint8_t*)&sSettings, sizeof(sSettings)); 8028628: 4618 mov r0, r3 } 802862a: e8bd 4008 ldmia.w sp!, {r3, lr} void SETTINGS_Save(void) { /* Calc critical section CRC and store to the settings structure */ sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); SETTINGS_WriteToFlash((uint8_t*)&sSettings, sizeof(sSettings)); 802862e: f7ff bfab b.w 8028588 8028632: bf00 nop 8028634: 2000e8e4 .word 0x2000e8e4 08028638 : /** * @brief Установка настроек для отладки */ void SETTINGS_SetDefaultDebug(void) { 8028638: b510 push {r4, lr} /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 802863a: 4c0c ldr r4, [pc, #48] ; (802866c ) /** * @brief Установка настроек для отладки */ void SETTINGS_SetDefaultDebug(void) { SETTINGS_SetWebParamsDef(); 802863c: f7ff fe64 bl 8028308 SETTINGS_SetTempWebParamsDef(); 8028640: f7ff fe7e bl 8028340 SETTINGS_SetSnmpDef(); 8028644: f7ff fe98 bl 8028378 SETTINGS_SetBootParamsDef(); 8028648: f7ff fe56 bl 80282f8 /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 802864c: 2300 movs r3, #0 802864e: f884 32fc strb.w r3, [r4, #764] ; 0x2fc SETTINGS_SetWebParamsDef(); SETTINGS_SetTempWebParamsDef(); SETTINGS_SetSnmpDef(); SETTINGS_SetBootParamsDef(); SETTINGS_SetFlagsDef(); SETTINGS_SetServiceDef(); 8028652: f7ff fefb bl 802844c SETTINGS_SetSntpDef(); 8028656: f7ff ff31 bl 80284bc SETTINGS_SetINOUTSDef(); 802865a: f7ff ff4d bl 80284f8 SETTINGS_SetRADIUSDef(); 802865e: f7ff ff59 bl 8028514 //SETTINGS_SetInfoDef(); sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); 8028662: f7ff ffcd bl 8028600 8028666: f8c4 0310 str.w r0, [r4, #784] ; 0x310 802866a: bd10 pop {r4, pc} 802866c: 2000e8e4 .word 0x2000e8e4 08028670 : /** * @brief Сброс всех настроек в значения по умолчанию */ void SETTINGS_SetAllDefault(void) { 8028670: b510 push {r4, lr} /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 8028672: 4c0d ldr r4, [pc, #52] ; (80286a8 ) /** * @brief Сброс всех настроек в значения по умолчанию */ void SETTINGS_SetAllDefault(void) { SETTINGS_SetBootParamsDef(); 8028674: f7ff fe40 bl 80282f8 SETTINGS_SetWebParamsDef(); 8028678: f7ff fe46 bl 8028308 SETTINGS_SetTempWebParamsDef(); 802867c: f7ff fe60 bl 8028340 SETTINGS_SetSnmpDef(); 8028680: f7ff fe7a bl 8028378 SETTINGS_SetInfoDef(); 8028684: f7ff fec0 bl 8028408 /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 8028688: 2300 movs r3, #0 802868a: f884 32fc strb.w r3, [r4, #764] ; 0x2fc SETTINGS_SetWebParamsDef(); SETTINGS_SetTempWebParamsDef(); SETTINGS_SetSnmpDef(); SETTINGS_SetInfoDef(); SETTINGS_SetFlagsDef(); SETTINGS_SetServiceDef(); 802868e: f7ff fedd bl 802844c SETTINGS_SetSntpDef(); 8028692: f7ff ff13 bl 80284bc SETTINGS_SetINOUTSDef(); 8028696: f7ff ff2f bl 80284f8 SETTINGS_SetRADIUSDef(); 802869a: f7ff ff3b bl 8028514 sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); 802869e: f7ff ffaf bl 8028600 80286a2: f8c4 0310 str.w r0, [r4, #784] ; 0x310 80286a6: bd10 pop {r4, pc} 80286a8: 2000e8e4 .word 0x2000e8e4 080286ac : /** * @brief Загрузка структуры настроек из flesh */ void SETTINGS_Load(void) { 80286ac: b510 push {r4, lr} SETTINGS_ReadFromFlash((uint8_t*)&sSettings, sizeof(sSettings)); 80286ae: 4c09 ldr r4, [pc, #36] ; (80286d4 ) 80286b0: f44f 716a mov.w r1, #936 ; 0x3a8 80286b4: 4620 mov r0, r4 80286b6: f7ff ff4b bl 8028550 /* Проверка CRC критической секции сектора настроек. * Если CRC не совпадает, скорее всего настройки отсутствуют, * прошиваем значения по умолчанию */ uint32_t crc = SETTINGS_GetCritSecCRC(); 80286ba: f7ff ffa1 bl 8028600 if (sSettings.CritSecCRC != crc) { 80286be: f8d4 3310 ldr.w r3, [r4, #784] ; 0x310 80286c2: 4283 cmp r3, r0 80286c4: d005 beq.n 80286d2 SETTINGS_SetAllDefault(); 80286c6: f7ff ffd3 bl 8028670 SETTINGS_Save(); } } 80286ca: e8bd 4010 ldmia.w sp!, {r4, lr} * прошиваем значения по умолчанию */ uint32_t crc = SETTINGS_GetCritSecCRC(); if (sSettings.CritSecCRC != crc) { SETTINGS_SetAllDefault(); SETTINGS_Save(); 80286ce: f7ff bfa3 b.w 8028618 80286d2: bd10 pop {r4, pc} 80286d4: 2000e8e4 .word 0x2000e8e4 080286d8 : /** * @brief Сброс всех настроек в значения по умолчанию кроме сетевых настроек */ void SETTINGS_SetPartDefault(void) { 80286d8: b510 push {r4, lr} /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 80286da: 4c0a ldr r4, [pc, #40] ; (8028704 ) /** * @brief Сброс всех настроек в значения по умолчанию кроме сетевых настроек */ void SETTINGS_SetPartDefault(void) { SETTINGS_SetBootParamsDef(); 80286dc: f7ff fe0c bl 80282f8 SETTINGS_SetSnmpDef(); 80286e0: f7ff fe4a bl 8028378 /** * @brief Установить флаги по умолчанию */ void SETTINGS_SetFlagsDef(void) { sSettings.sFlags.netsettingsChanged = false; 80286e4: 2300 movs r3, #0 80286e6: f884 32fc strb.w r3, [r4, #764] ; 0x2fc void SETTINGS_SetPartDefault(void) { SETTINGS_SetBootParamsDef(); SETTINGS_SetSnmpDef(); SETTINGS_SetFlagsDef(); SETTINGS_SetServiceDef(); 80286ea: f7ff feaf bl 802844c SETTINGS_SetSntpDef(); 80286ee: f7ff fee5 bl 80284bc SETTINGS_SetINOUTSDef(); 80286f2: f7ff ff01 bl 80284f8 SETTINGS_SetRADIUSDef(); 80286f6: f7ff ff0d bl 8028514 sSettings.CritSecCRC = SETTINGS_GetCritSecCRC(); 80286fa: f7ff ff81 bl 8028600 80286fe: f8c4 0310 str.w r0, [r4, #784] ; 0x310 8028702: bd10 pop {r4, pc} 8028704: 2000e8e4 .word 0x2000e8e4 08028708 : /** * @brief Преобразует mac адрес строкового формата в массив uint8_t * @param mac - буфер для вывода mac адреса */ void SETTINGS_GetMac(uint8_t *mac) { 8028708: b573 push {r0, r1, r4, r5, r6, lr} char dummy[2]; char *macPtr = sSettings.sInfo.mac; for (uint8_t i = 0; i < 6; i++) { strncpy(dummy, macPtr+i*3, 2); 802870a: 4e0a ldr r6, [pc, #40] ; (8028734 ) /** * @brief Преобразует mac адрес строкового формата в массив uint8_t * @param mac - буфер для вывода mac адреса */ void SETTINGS_GetMac(uint8_t *mac) 802870c: 1e45 subs r5, r0, #1 802870e: 2400 movs r4, #0 char dummy[2]; char *macPtr = sSettings.sInfo.mac; for (uint8_t i = 0; i < 6; i++) { strncpy(dummy, macPtr+i*3, 2); 8028710: 1931 adds r1, r6, r4 8028712: 2202 movs r2, #2 8028714: f501 711b add.w r1, r1, #620 ; 0x26c 8028718: a801 add r0, sp, #4 802871a: f7f9 fc61 bl 8021fe0 mac[i] = (uint8_t)strtol(dummy, NULL, 16); 802871e: 2100 movs r1, #0 8028720: 2210 movs r2, #16 8028722: a801 add r0, sp, #4 8028724: f7fa ff92 bl 802364c 8028728: 3403 adds r4, #3 void SETTINGS_GetMac(uint8_t *mac) { char dummy[2]; char *macPtr = sSettings.sInfo.mac; for (uint8_t i = 0; i < 6; i++) 802872a: 2c12 cmp r4, #18 { strncpy(dummy, macPtr+i*3, 2); mac[i] = (uint8_t)strtol(dummy, NULL, 16); 802872c: f805 0f01 strb.w r0, [r5, #1]! void SETTINGS_GetMac(uint8_t *mac) { char dummy[2]; char *macPtr = sSettings.sInfo.mac; for (uint8_t i = 0; i < 6; i++) 8028730: d1ee bne.n 8028710 { strncpy(dummy, macPtr+i*3, 2); mac[i] = (uint8_t)strtol(dummy, NULL, 16); } } 8028732: bd7c pop {r2, r3, r4, r5, r6, pc} 8028734: 2000e8e4 .word 0x2000e8e4 08028738 : /** * @brief Установить дату производства */ void SETTINGS_SetProDate(char *proDate, uint8_t len) { 8028738: b570 push {r4, r5, r6, lr} memset(sSettings.sInfo.productionData, 0, 40); 802873a: 4c07 ldr r4, [pc, #28] ; (8028758 ) /** * @brief Установить дату производства */ void SETTINGS_SetProDate(char *proDate, uint8_t len) { 802873c: 4606 mov r6, r0 802873e: 460d mov r5, r1 memset(sSettings.sInfo.productionData, 0, 40); 8028740: 2228 movs r2, #40 ; 0x28 8028742: 2100 movs r1, #0 8028744: 4620 mov r0, r4 8028746: f7f9 f9bb bl 8021ac0 memcpy(sSettings.sInfo.productionData, proDate, len); 802874a: 4620 mov r0, r4 802874c: 4631 mov r1, r6 802874e: 462a mov r2, r5 } 8028750: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} * @brief Установить дату производства */ void SETTINGS_SetProDate(char *proDate, uint8_t len) { memset(sSettings.sInfo.productionData, 0, 40); memcpy(sSettings.sInfo.productionData, proDate, len); 8028754: f7f9 b8fa b.w 802194c 8028758: 2000eb28 .word 0x2000eb28 0802875c : #include #include /* Converts a hex character to its integer value */ char from_hex(char ch) { return isdigit(ch) ? ch - '0' : tolower(ch) - 'a' + 10; 802875c: 4b08 ldr r3, [pc, #32] ; (8028780 ) 802875e: 681b ldr r3, [r3, #0] 8028760: 181b adds r3, r3, r0 8028762: 785b ldrb r3, [r3, #1] 8028764: f003 0204 and.w r2, r3, #4 8028768: b2d2 uxtb r2, r2 802876a: b10a cbz r2, 8028770 802876c: 3830 subs r0, #48 ; 0x30 802876e: e005 b.n 802877c 8028770: f003 0303 and.w r3, r3, #3 8028774: 2b01 cmp r3, #1 8028776: bf08 it eq 8028778: 3020 addeq r0, #32 802877a: 3857 subs r0, #87 ; 0x57 802877c: b2c0 uxtb r0, r0 } 802877e: 4770 bx lr 8028780: 20000000 .word 0x20000000 08028784 : return buf; } /* Returns a url-decoded version of str */ /* IMPORTANT: be sure that outbuf is big enougth */ char *url_decode(char *outbuf, uint32_t outlen, char *inbuf) { 8028784: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 8028788: 4607 mov r7, r0 802878a: 460e mov r6, r1 char *pstr = inbuf, *buf = outbuf, *pbuf = buf; 802878c: 4604 mov r4, r0 802878e: 4615 mov r5, r2 if (pstr[1] && pstr[2]) { *pbuf++ = from_hex(pstr[1]) << 4 | from_hex(pstr[2]); pstr += 2; } } else if (*pstr == '+') { *pbuf++ = ' '; 8028790: f04f 0920 mov.w r9, #32 /* Returns a url-decoded version of str */ /* IMPORTANT: be sure that outbuf is big enougth */ char *url_decode(char *outbuf, uint32_t outlen, char *inbuf) { char *pstr = inbuf, *buf = outbuf, *pbuf = buf; while ((*pstr) && outlen > 1) { 8028794: e01e b.n 80287d4 if (*pstr == '%') { 8028796: 2b25 cmp r3, #37 ; 0x25 8028798: d112 bne.n 80287c0 if (pstr[1] && pstr[2]) { 802879a: 7868 ldrb r0, [r5, #1] 802879c: b1c0 cbz r0, 80287d0 802879e: f895 8002 ldrb.w r8, [r5, #2] 80287a2: f1b8 0f00 cmp.w r8, #0 80287a6: d013 beq.n 80287d0 *pbuf++ = from_hex(pstr[1]) << 4 | from_hex(pstr[2]); 80287a8: f7ff ffd8 bl 802875c 80287ac: 4682 mov sl, r0 80287ae: 4640 mov r0, r8 80287b0: f7ff ffd4 bl 802875c 80287b4: ea40 100a orr.w r0, r0, sl, lsl #4 80287b8: f804 0b01 strb.w r0, [r4], #1 pstr += 2; 80287bc: 3502 adds r5, #2 80287be: e007 b.n 80287d0 } } else if (*pstr == '+') { 80287c0: 2b2b cmp r3, #43 ; 0x2b 80287c2: f104 0201 add.w r2, r4, #1 *pbuf++ = ' '; 80287c6: bf0c ite eq 80287c8: f884 9000 strbeq.w r9, [r4] } else { *pbuf++ = *pstr; 80287cc: 7023 strbne r3, [r4, #0] 80287ce: 4614 mov r4, r2 } pstr++; 80287d0: 3501 adds r5, #1 outlen--; 80287d2: 3e01 subs r6, #1 /* Returns a url-decoded version of str */ /* IMPORTANT: be sure that outbuf is big enougth */ char *url_decode(char *outbuf, uint32_t outlen, char *inbuf) { char *pstr = inbuf, *buf = outbuf, *pbuf = buf; while ((*pstr) && outlen > 1) { 80287d4: 782b ldrb r3, [r5, #0] 80287d6: b10b cbz r3, 80287dc 80287d8: 2e01 cmp r6, #1 80287da: d8dc bhi.n 8028796 *pbuf++ = *pstr; } pstr++; outlen--; } *pbuf = '\0'; 80287dc: 2300 movs r3, #0 80287de: 7023 strb r3, [r4, #0] return buf; } 80287e0: 4638 mov r0, r7 80287e2: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 80287e6: 0000 movs r0, r0 080287e8 : /** * @brief Задача простой мигалки */ void vTaskLedBlink(void *arg) { 80287e8: b510 push {r4, lr} /* Просто отражает состояние контроллера - "живой" */ // LED_Toggle(LED_INIT_G); //LED_Toggle(LED_INIT_R); LED_Toggle(LED_MAJOR_R); // LED_Toggle(LED_MINOR_R); vTaskDelay(statusLedFreq); 80287ea: 4c04 ldr r4, [pc, #16] ; (80287fc ) /** * @brief Изменить состояние LED */ void LED_Toggle(gpio_t pin) { gpio_invert_output(pin); 80287ec: 200b movs r0, #11 80287ee: f7fd fc33 bl 8026058 /* Просто отражает состояние контроллера - "живой" */ // LED_Toggle(LED_INIT_G); //LED_Toggle(LED_INIT_R); LED_Toggle(LED_MAJOR_R); // LED_Toggle(LED_MINOR_R); vTaskDelay(statusLedFreq); 80287f2: 8820 ldrh r0, [r4, #0] 80287f4: f001 f85e bl 80298b4 80287f8: e7f8 b.n 80287ec 80287fa: bf00 nop 80287fc: 200015aa .word 0x200015aa 08028800 : /** * @brief */ void LED_Off(gpio_t pin) { gpio_set(pin, 0); 8028800: 2100 movs r1, #0 8028802: f7fd bb95 b.w 8025f30 08028806 : /** * @brief * @retval */ void LED_Init(void) { 8028806: b508 push {r3, lr} LED_Off(LED_INIT_R); 8028808: 2009 movs r0, #9 802880a: f7ff fff9 bl 8028800 LED_Off(LED_INIT_G); 802880e: 200a movs r0, #10 8028810: f7ff fff6 bl 8028800 LED_Off(LED_MAJOR_R); 8028814: 200b movs r0, #11 8028816: f7ff fff3 bl 8028800 LED_Off(LED_MINOR_G); 802881a: 200c movs r0, #12 802881c: f7ff fff0 bl 8028800 LED_Off(LED_MINOR_R); 8028820: 200d movs r0, #13 } 8028822: e8bd 4008 ldmia.w sp!, {r3, lr} { LED_Off(LED_INIT_R); LED_Off(LED_INIT_G); LED_Off(LED_MAJOR_R); LED_Off(LED_MINOR_G); LED_Off(LED_MINOR_R); 8028826: f7ff bfeb b.w 8028800 802882a: 0000 movs r0, r0 0802882c : /** * @brief */ void LED_SetStatusLedFreq(uint16_t freq) { statusLedFreq = freq; 802882c: 4b01 ldr r3, [pc, #4] ; (8028834 ) 802882e: 8018 strh r0, [r3, #0] 8028830: 4770 bx lr 8028832: bf00 nop 8028834: 200015aa .word 0x200015aa 08028838 : /** * @brief Заглушка */ void BUTTON_VoidHandler(void) { 8028838: 4770 bx lr 802883a: 0000 movs r0, r0 0802883c : /** * @brief Хендлер кнопки DEFAULT. Сброс всех настроек, сохранение и перезагрузка */ void BUTTON_DEF_DownHandler(void) { 802883c: b508 push {r3, lr} //taskENTER_CRITICAL(); SETTINGS_SetDefaultDebug(); 802883e: f7ff fefb bl 8028638 SETTINGS_Save(); 8028842: f7ff fee9 bl 8028618 vTaskDelay(1010); 8028846: f240 30f2 movw r0, #1010 ; 0x3f2 802884a: f001 f833 bl 80298b4 This function acts as a special kind of Data Memory Barrier. It completes when all explicit memory accesses before this instruction complete. */ __attribute__( ( always_inline ) ) __STATIC_INLINE void __DSB(void) { __ASM volatile ("dsb"); 802884e: f3bf 8f4f dsb sy //static inline void NVIC_SystemReset(void) { __DSB(); /* Ensure all outstanding memory accesses included buffered write are completed before reset */ SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | (SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) | 8028852: 4a05 ldr r2, [pc, #20] ; (8028868 ) 8028854: 4b05 ldr r3, [pc, #20] ; (802886c ) 8028856: 68d1 ldr r1, [r2, #12] 8028858: f401 61e0 and.w r1, r1, #1792 ; 0x700 802885c: 430b orrs r3, r1 __STATIC_INLINE void NVIC_SystemReset(void) //static inline void NVIC_SystemReset(void) { __DSB(); /* Ensure all outstanding memory accesses included buffered write are completed before reset */ SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | 802885e: 60d3 str r3, [r2, #12] 8028860: f3bf 8f4f dsb sy 8028864: e7fe b.n 8028864 8028866: bf00 nop 8028868: e000ed00 .word 0xe000ed00 802886c: 05fa0004 .word 0x05fa0004 08028870 : /** * @brief Возвращает сотояние ключа */ BUTTON_STATE_t BUTTON_GetState(BUTTON_NO_FIX_t *button) { return (BUTTON_STATE_t)gpio_get(button->id_pin); 8028870: 7800 ldrb r0, [r0, #0] 8028872: f7fd bc01 b.w 8026078 8028876: 0000 movs r0, r0 08028878 : /** * @brief * @retval */ void BUTTON_Init(void) { 8028878: b510 push {r4, lr} defButton.id_pin = KEY_DEF; 802887a: 4c09 ldr r4, [pc, #36] ; (80288a0 ) 802887c: 230f movs r3, #15 802887e: 7023 strb r3, [r4, #0] defButton.timeDelay = 5; 8028880: 2305 movs r3, #5 8028882: 8063 strh r3, [r4, #2] defButton.pressHandler = BUTTON_VoidHandler; 8028884: 4b07 ldr r3, [pc, #28] ; (80288a4 ) 8028886: 60a3 str r3, [r4, #8] defButton.unpressHandler = BUTTON_DEF_DownHandler; 8028888: 4b07 ldr r3, [pc, #28] ; (80288a8 ) defButton.counterActivation = 0; defButton.timeActivation = 40; 802888a: 2228 movs r2, #40 ; 0x28 void BUTTON_Init(void) { defButton.id_pin = KEY_DEF; defButton.timeDelay = 5; defButton.pressHandler = BUTTON_VoidHandler; defButton.unpressHandler = BUTTON_DEF_DownHandler; 802888c: 60e3 str r3, [r4, #12] defButton.counterActivation = 0; defButton.timeActivation = 40; defButton.fActivation = false; defButton.stateOld = BUTTON_GetState(&defButton); 802888e: 4620 mov r0, r4 { defButton.id_pin = KEY_DEF; defButton.timeDelay = 5; defButton.pressHandler = BUTTON_VoidHandler; defButton.unpressHandler = BUTTON_DEF_DownHandler; defButton.counterActivation = 0; 8028890: 2300 movs r3, #0 8028892: 6163 str r3, [r4, #20] defButton.timeActivation = 40; 8028894: 8322 strh r2, [r4, #24] defButton.fActivation = false; 8028896: 76a3 strb r3, [r4, #26] defButton.stateOld = BUTTON_GetState(&defButton); 8028898: f7ff ffea bl 8028870 802889c: 71a0 strb r0, [r4, #6] 802889e: bd10 pop {r4, pc} 80288a0: 2000ec8c .word 0x2000ec8c 80288a4: 08028839 .word 0x08028839 80288a8: 0802883d .word 0x0802883d 080288ac : время нажатия. * @param *button: указатель на структуру типа BUTTON_NO_FIX * @retval нет */ void BUTTON_DellayHandler(BUTTON_NO_FIX_t *button) { 80288ac: b510 push {r4, lr} 80288ae: 4604 mov r4, r0 /* Кнопка нажата. Ведем отсчет времени удержания */ if (gpio_get(button->id_pin) == 0) // определяем текущее (новое) состояние кнопки 80288b0: 7800 ldrb r0, [r0, #0] 80288b2: f7fd fbe1 bl 8026078 80288b6: 6963 ldr r3, [r4, #20] 80288b8: b950 cbnz r0, 80288d0 { button->counterActivation++; button->fActivation = false; /* Кнопка нажата более необходимого времени - начинаем чаще мигать диодом */ if (button->counterActivation > button->timeActivation) 80288ba: 8b22 ldrh r2, [r4, #24] { /* Кнопка нажата. Ведем отсчет времени удержания */ if (gpio_get(button->id_pin) == 0) // определяем текущее (новое) состояние кнопки { button->counterActivation++; button->fActivation = false; 80288bc: 76a0 strb r0, [r4, #26] void BUTTON_DellayHandler(BUTTON_NO_FIX_t *button) { /* Кнопка нажата. Ведем отсчет времени удержания */ if (gpio_get(button->id_pin) == 0) // определяем текущее (новое) состояние кнопки { button->counterActivation++; 80288be: 3301 adds r3, #1 button->fActivation = false; /* Кнопка нажата более необходимого времени - начинаем чаще мигать диодом */ if (button->counterActivation > button->timeActivation) 80288c0: 4293 cmp r3, r2 void BUTTON_DellayHandler(BUTTON_NO_FIX_t *button) { /* Кнопка нажата. Ведем отсчет времени удержания */ if (gpio_get(button->id_pin) == 0) // определяем текущее (новое) состояние кнопки { button->counterActivation++; 80288c2: 6163 str r3, [r4, #20] button->fActivation = false; /* Кнопка нажата более необходимого времени - начинаем чаще мигать диодом */ if (button->counterActivation > button->timeActivation) 80288c4: d914 bls.n 80288f0 LED_SetStatusLedFreq(100); 80288c6: 2064 movs r0, #100 ; 0x64 } else button->counterActivation = 0; } } 80288c8: e8bd 4010 ldmia.w sp!, {r4, lr} button->counterActivation++; button->fActivation = false; /* Кнопка нажата более необходимого времени - начинаем чаще мигать диодом */ if (button->counterActivation > button->timeActivation) LED_SetStatusLedFreq(100); 80288cc: f7ff bfae b.w 802882c } /* Кнопку отжата. Если до этого она была нажата нужное время - вызываем хендлер */ else { if ((button->counterActivation > button->timeActivation) 80288d0: 8b22 ldrh r2, [r4, #24] 80288d2: 4293 cmp r3, r2 80288d4: d90a bls.n 80288ec && button->fActivation == false) 80288d6: 7ea3 ldrb r3, [r4, #26] 80288d8: b943 cbnz r3, 80288ec { button->fActivation = true; 80288da: 2301 movs r3, #1 80288dc: 76a3 strb r3, [r4, #26] LED_SetStatusLedFreq(1000); 80288de: f44f 707a mov.w r0, #1000 ; 0x3e8 80288e2: f7ff ffa3 bl 802882c button->unpressHandler(); 80288e6: 68e3 ldr r3, [r4, #12] 80288e8: 4798 blx r3 80288ea: bd10 pop {r4, pc} } else button->counterActivation = 0; 80288ec: 2300 movs r3, #0 80288ee: 6163 str r3, [r4, #20] 80288f0: bd10 pop {r4, pc} 80288f2: 0000 movs r0, r0 080288f4 : /** * @brief Опрос кнопок */ void vTaskButtons(void *pvParameters) { 80288f4: b508 push {r3, lr} for (;;) { BUTTON_DellayHandler(&defButton); 80288f6: 4803 ldr r0, [pc, #12] ; (8028904 ) 80288f8: f7ff ffd8 bl 80288ac vTaskDelay(100); //20 80288fc: 2064 movs r0, #100 ; 0x64 80288fe: f000 ffd9 bl 80298b4 8028902: e7f8 b.n 80288f6 8028904: 2000ec8c .word 0x2000ec8c 08028908 : #include "gpio.h" bool value_jumper; void set_mode_jumper(void) { 8028908: b508 push {r3, lr} value_jumper = gpio_get(MODE_JUMPER); 802890a: 200e movs r0, #14 802890c: f7fd fbb4 bl 8026078 8028910: 4b01 ldr r3, [pc, #4] ; (8028918 ) 8028912: 7018 strb r0, [r3, #0] 8028914: bd08 pop {r3, pc} 8028916: bf00 nop 8028918: 2000eca8 .word 0x2000eca8 0802891c : } else if(command == ups_shutdown_restore){ } else{ ups_send_block(MegaTecCMD[command], strlen(MegaTecCMD[command])); 802891c: 4b06 ldr r3, [pc, #24] ; (8028938 ) memset(UPS.model, 0, 11); memset(UPS.vertion, 0, 11); } void send_MegaTec_cmd(cmdMegaTecEnums_t command) 802891e: b510 push {r4, lr} } else if(command == ups_shutdown_restore){ } else{ ups_send_block(MegaTecCMD[command], strlen(MegaTecCMD[command])); 8028920: f853 4020 ldr.w r4, [r3, r0, lsl #2] 8028924: 4620 mov r0, r4 8028926: f7f9 faa3 bl 8021e70 802892a: b2c1 uxtb r1, r0 802892c: 4620 mov r0, r4 } } 802892e: e8bd 4010 ldmia.w sp!, {r4, lr} } else if(command == ups_shutdown_restore){ } else{ ups_send_block(MegaTecCMD[command], strlen(MegaTecCMD[command])); 8028932: f7fe b9a3 b.w 8026c7c 8028936: bf00 nop 8028938: 200015ac .word 0x200015ac 0802893c : "F\r" }; void init_UPS_value(void) { 802893c: b538 push {r3, r4, r5, lr} UPS.Freq_in = 0; 802893e: 4c0d ldr r4, [pc, #52] ; (8028974 ) UPS.VAC_in = 0; UPS.VAC_out = 0; UPS.Temp = 0; UPS.Load = 0; 8028940: 2500 movs r5, #0 }; void init_UPS_value(void) { UPS.Freq_in = 0; 8028942: 2300 movs r3, #0 UPS.SOC = 0; UPS.work_time = 0; UPS.Status = 0; UPS.Present = false; memset(UPS.model, 0, 11); 8028944: 4629 mov r1, r5 8028946: 220b movs r2, #11 8028948: f104 0014 add.w r0, r4, #20 }; void init_UPS_value(void) { UPS.Freq_in = 0; 802894c: 6023 str r3, [r4, #0] UPS.VAC_in = 0; 802894e: 6063 str r3, [r4, #4] UPS.VAC_out = 0; 8028950: 60a3 str r3, [r4, #8] UPS.Temp = 0; 8028952: 60e3 str r3, [r4, #12] UPS.Load = 0; 8028954: 7425 strb r5, [r4, #16] UPS.SOC = 0; 8028956: 7465 strb r5, [r4, #17] UPS.work_time = 0; 8028958: 74a5 strb r5, [r4, #18] UPS.Status = 0; 802895a: 74e5 strb r5, [r4, #19] UPS.Present = false; 802895c: f884 502a strb.w r5, [r4, #42] ; 0x2a memset(UPS.model, 0, 11); 8028960: f7f9 f8ae bl 8021ac0 memset(UPS.vertion, 0, 11); 8028964: f104 001f add.w r0, r4, #31 8028968: 4629 mov r1, r5 802896a: 220b movs r2, #11 } 802896c: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} UPS.work_time = 0; UPS.Status = 0; UPS.Present = false; memset(UPS.model, 0, 11); memset(UPS.vertion, 0, 11); 8028970: f7f9 b8a6 b.w 8021ac0 8028974: 2000e8b4 .word 0x2000e8b4 08028978 : ups_send_block(MegaTecCMD[command], strlen(MegaTecCMD[command])); } } bool ups_megatec_rx_pdu(void) { 8028978: b510 push {r4, lr} int c = 0; ups_pdu.len = 0; 802897a: 4c0e ldr r4, [pc, #56] ; (80289b4 ) 802897c: 2000 movs r0, #0 802897e: 8660 strh r0, [r4, #50] ; 0x32 while ((ups_pdu.len < UPS_PDU_MAX_LEN) && (c != 0x0d)) { 8028980: e00d b.n 802899e c = ups_getchar(500);//portMAX_DELAY 8028982: f44f 70fa mov.w r0, #500 ; 0x1f4 8028986: f7fe f99d bl 8026cc4 if(c < 0) 802898a: 2800 cmp r0, #0 802898c: da03 bge.n 8028996 { ups_pdu.len = 0; 802898e: 4b09 ldr r3, [pc, #36] ; (80289b4 ) 8028990: 2200 movs r2, #0 8028992: 865a strh r2, [r3, #50] ; 0x32 break; 8028994: e008 b.n 80289a8 } ups_pdu.data[ups_pdu.len++] = c; 8028996: 8e63 ldrh r3, [r4, #50] ; 0x32 8028998: 54e0 strb r0, [r4, r3] 802899a: 3301 adds r3, #1 802899c: 8663 strh r3, [r4, #50] ; 0x32 { int c = 0; ups_pdu.len = 0; while ((ups_pdu.len < UPS_PDU_MAX_LEN) && (c != 0x0d)) { 802899e: 8e63 ldrh r3, [r4, #50] ; 0x32 80289a0: 2b31 cmp r3, #49 ; 0x31 80289a2: d801 bhi.n 80289a8 80289a4: 280d cmp r0, #13 80289a6: d1ec bne.n 8028982 break; } ups_pdu.data[ups_pdu.len++] = c; } if (ups_pdu.len == 0) 80289a8: 4b02 ldr r3, [pc, #8] ; (80289b4 ) 80289aa: 8e58 ldrh r0, [r3, #50] ; 0x32 return false; return true; } 80289ac: 3000 adds r0, #0 80289ae: bf18 it ne 80289b0: 2001 movne r0, #1 80289b2: bd10 pop {r4, pc} 80289b4: 200028ae .word 0x200028ae 080289b8 : void ups_status_response(char *data) { 80289b8: e92d 41ff stmdb sp!, {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} uint8_t i; char *endValue; char value[10]; uint8_t len = 0; if(data[0] != '(') 80289bc: 7803 ldrb r3, [r0, #0] 80289be: 2b28 cmp r3, #40 ; 0x28 80289c0: f040 80c1 bne.w 8028b46 return; data++; 80289c4: 1c44 adds r4, r0, #1 memset(value, 0, 10); 80289c6: 220a movs r2, #10 80289c8: 2100 movs r1, #0 80289ca: a801 add r0, sp, #4 80289cc: f7f9 f878 bl 8021ac0 endValue = strpbrk(data," "); 80289d0: 4620 mov r0, r4 80289d2: 495e ldr r1, [pc, #376] ; (8028b4c ) 80289d4: f7f9 fb36 bl 8022044 len = endValue - data; 80289d8: 1b00 subs r0, r0, r4 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 80289da: b2c6 uxtb r6, r0 data++; memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 80289dc: 4632 mov r2, r6 80289de: 4621 mov r1, r4 80289e0: a801 add r0, sp, #4 80289e2: f7f9 fafd bl 8021fe0 data += (len + 1); UPS.VAC_in = atof(value); 80289e6: a801 add r0, sp, #4 80289e8: f7f8 ff46 bl 8021878 80289ec: f7f8 f8aa bl 8020b44 <__aeabi_d2f> memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); 80289f0: 3601 adds r6, #1 80289f2: 19a6 adds r6, r4, r6 UPS.VAC_in = atof(value); 80289f4: 4c56 ldr r4, [pc, #344] ; (8028b50 ) //TODO memset(value, 0, 10); 80289f6: 220a movs r2, #10 80289f8: 2100 movs r1, #0 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); UPS.VAC_in = atof(value); 80289fa: 6060 str r0, [r4, #4] //TODO memset(value, 0, 10); 80289fc: a801 add r0, sp, #4 80289fe: f7f9 f85f bl 8021ac0 endValue = strpbrk(data," "); 8028a02: 4630 mov r0, r6 8028a04: 4951 ldr r1, [pc, #324] ; (8028b4c ) 8028a06: f7f9 fb1d bl 8022044 len = endValue - data; 8028a0a: 1b80 subs r0, r0, r6 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028a0c: b2c5 uxtb r5, r0 //TODO memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028a0e: 4631 mov r1, r6 8028a10: 462a mov r2, r5 8028a12: a801 add r0, sp, #4 data += (len + 1); 8028a14: 3501 adds r5, #1 //TODO memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028a16: f7f9 fae3 bl 8021fe0 data += (len + 1); 8028a1a: 1975 adds r5, r6, r5 memset(value, 0, 10); 8028a1c: 220a movs r2, #10 8028a1e: 2100 movs r1, #0 8028a20: a801 add r0, sp, #4 8028a22: f7f9 f84d bl 8021ac0 endValue = strpbrk(data," "); 8028a26: 4628 mov r0, r5 8028a28: 4948 ldr r1, [pc, #288] ; (8028b4c ) 8028a2a: f7f9 fb0b bl 8022044 len = endValue - data; 8028a2e: 1b40 subs r0, r0, r5 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028a30: fa5f f880 uxtb.w r8, r0 data += (len + 1); memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028a34: 4642 mov r2, r8 8028a36: 4629 mov r1, r5 8028a38: a801 add r0, sp, #4 8028a3a: f7f9 fad1 bl 8021fe0 data += (len + 1); UPS.VAC_out = atof(value); 8028a3e: a801 add r0, sp, #4 8028a40: f7f8 ff1a bl 8021878 8028a44: f7f8 f87e bl 8020b44 <__aeabi_d2f> memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); 8028a48: f108 0801 add.w r8, r8, #1 8028a4c: 44a8 add r8, r5 UPS.VAC_out = atof(value); memset(value, 0, 10); 8028a4e: 220a movs r2, #10 8028a50: 2100 movs r1, #0 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); UPS.VAC_out = atof(value); 8028a52: 60a0 str r0, [r4, #8] memset(value, 0, 10); 8028a54: a801 add r0, sp, #4 8028a56: f7f9 f833 bl 8021ac0 endValue = strpbrk(data," "); 8028a5a: 493c ldr r1, [pc, #240] ; (8028b4c ) 8028a5c: 4640 mov r0, r8 8028a5e: f7f9 faf1 bl 8022044 len = endValue - data; 8028a62: ebc8 0000 rsb r0, r8, r0 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028a66: b2c7 uxtb r7, r0 UPS.VAC_out = atof(value); memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028a68: 463a mov r2, r7 8028a6a: 4641 mov r1, r8 8028a6c: a801 add r0, sp, #4 8028a6e: f7f9 fab7 bl 8021fe0 data += (len + 1); UPS.Load = atoi(value); 8028a72: a801 add r0, sp, #4 8028a74: f7f8 ff04 bl 8021880 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); 8028a78: 3701 adds r7, #1 8028a7a: 4447 add r7, r8 UPS.Load = atoi(value); memset(value, 0, 10); 8028a7c: 220a movs r2, #10 8028a7e: 2100 movs r1, #0 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); UPS.Load = atoi(value); 8028a80: 7420 strb r0, [r4, #16] memset(value, 0, 10); 8028a82: a801 add r0, sp, #4 8028a84: f7f9 f81c bl 8021ac0 endValue = strpbrk(data," "); 8028a88: 4930 ldr r1, [pc, #192] ; (8028b4c ) 8028a8a: 4638 mov r0, r7 8028a8c: f7f9 fada bl 8022044 len = endValue - data; 8028a90: 1bc0 subs r0, r0, r7 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028a92: b2c6 uxtb r6, r0 UPS.Load = atoi(value); memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028a94: 4632 mov r2, r6 8028a96: 4639 mov r1, r7 8028a98: a801 add r0, sp, #4 8028a9a: f7f9 faa1 bl 8021fe0 data += (len + 1); UPS.Freq_in = atof(value); 8028a9e: a801 add r0, sp, #4 8028aa0: f7f8 feea bl 8021878 8028aa4: f7f8 f84e bl 8020b44 <__aeabi_d2f> memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); 8028aa8: 3601 adds r6, #1 8028aaa: 19be adds r6, r7, r6 UPS.Freq_in = atof(value); //TODO memset(value, 0, 10); 8028aac: 220a movs r2, #10 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); UPS.Freq_in = atof(value); 8028aae: 6020 str r0, [r4, #0] //TODO memset(value, 0, 10); 8028ab0: 2100 movs r1, #0 8028ab2: a801 add r0, sp, #4 8028ab4: f7f9 f804 bl 8021ac0 endValue = strpbrk(data," "); 8028ab8: 4630 mov r0, r6 8028aba: 4924 ldr r1, [pc, #144] ; (8028b4c ) 8028abc: f7f9 fac2 bl 8022044 len = endValue - data; 8028ac0: 1b80 subs r0, r0, r6 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028ac2: b2c5 uxtb r5, r0 //TODO memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028ac4: 4631 mov r1, r6 8028ac6: 462a mov r2, r5 8028ac8: a801 add r0, sp, #4 data += (len + 1); 8028aca: 3501 adds r5, #1 //TODO memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028acc: f7f9 fa88 bl 8021fe0 data += (len + 1); 8028ad0: 1975 adds r5, r6, r5 memset(value, 0, 10); 8028ad2: 220a movs r2, #10 8028ad4: 2100 movs r1, #0 8028ad6: a801 add r0, sp, #4 8028ad8: f7f8 fff2 bl 8021ac0 endValue = strpbrk(data," "); 8028adc: 4628 mov r0, r5 8028ade: 491b ldr r1, [pc, #108] ; (8028b4c ) 8028ae0: f7f9 fab0 bl 8022044 len = endValue - data; 8028ae4: 1b40 subs r0, r0, r5 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028ae6: b2c6 uxtb r6, r0 data += (len + 1); memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); 8028ae8: 4632 mov r2, r6 8028aea: 4629 mov r1, r5 8028aec: a801 add r0, sp, #4 8028aee: f7f9 fa77 bl 8021fe0 data += (len + 1); UPS.Temp = atof(value); 8028af2: a801 add r0, sp, #4 8028af4: f7f8 fec0 bl 8021878 8028af8: f7f8 f824 bl 8020b44 <__aeabi_d2f> memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); 8028afc: 3601 adds r6, #1 8028afe: 19ad adds r5, r5, r6 UPS.Temp = atof(value); memset(value, 0, 10); 8028b00: 220a movs r2, #10 memset(value, 0, 10); endValue = strpbrk(data," "); len = endValue - data; strncpy(value, data, len); data += (len + 1); UPS.Temp = atof(value); 8028b02: 60e0 str r0, [r4, #12] memset(value, 0, 10); 8028b04: 2100 movs r1, #0 8028b06: a801 add r0, sp, #4 8028b08: f7f8 ffda bl 8021ac0 endValue = strpbrk(data,"\r"); 8028b0c: 4911 ldr r1, [pc, #68] ; (8028b54 ) 8028b0e: 4628 mov r0, r5 8028b10: f7f9 fa98 bl 8022044 len = endValue - data; 8028b14: 1b40 subs r0, r0, r5 8028b16: b2c6 uxtb r6, r0 strncpy(value, data, len); 8028b18: 4629 mov r1, r5 8028b1a: a801 add r0, sp, #4 8028b1c: 4632 mov r2, r6 8028b1e: f7f9 fa5f bl 8021fe0 8028b22: 7ce1 ldrb r1, [r4, #19] for(i = 0; i < len; i ++) 8028b24: 2300 movs r3, #0 8028b26: e009 b.n 8028b3c { UPS.Status |= (value[i] - 0x30) << (7-i); 8028b28: aa01 add r2, sp, #4 return false; return true; } void ups_status_response(char *data) 8028b2a: f1c3 0007 rsb r0, r3, #7 endValue = strpbrk(data,"\r"); len = endValue - data; strncpy(value, data, len); for(i = 0; i < len; i ++) { UPS.Status |= (value[i] - 0x30) << (7-i); 8028b2e: 5c9a ldrb r2, [r3, r2] 8028b30: 3a30 subs r2, #48 ; 0x30 8028b32: fa02 f200 lsl.w r2, r2, r0 8028b36: 4311 orrs r1, r2 8028b38: b2c9 uxtb r1, r1 8028b3a: 3301 adds r3, #1 memset(value, 0, 10); endValue = strpbrk(data,"\r"); len = endValue - data; strncpy(value, data, len); for(i = 0; i < len; i ++) 8028b3c: b2da uxtb r2, r3 8028b3e: 42b2 cmp r2, r6 8028b40: d3f2 bcc.n 8028b28 8028b42: 4b03 ldr r3, [pc, #12] ; (8028b50 ) 8028b44: 74d9 strb r1, [r3, #19] { UPS.Status |= (value[i] - 0x30) << (7-i); } } 8028b46: e8bd 81ff ldmia.w sp!, {r0, r1, r2, r3, r4, r5, r6, r7, r8, pc} 8028b4a: bf00 nop 8028b4c: 08035f57 .word 0x08035f57 8028b50: 2000e8b4 .word 0x2000e8b4 8028b54: 080409a5 .word 0x080409a5 08028b58 : void ups_info_response(char *data) { 8028b58: b538 push {r3, r4, r5, lr} uint8_t i = 0; char *endValue; uint8_t len = 0; if(data[0] != '#') 8028b5a: 7803 ldrb r3, [r0, #0] 8028b5c: 2b23 cmp r3, #35 ; 0x23 8028b5e: d123 bne.n 8028ba8 return; data++; data += 16; 8028b60: 3011 adds r0, #17 while(data[0] == ' '){ 8028b62: 4603 mov r3, r0 8028b64: 461c mov r4, r3 UPS.Status |= (value[i] - 0x30) << (7-i); } } void ups_info_response(char *data) 8028b66: 1a1a subs r2, r3, r0 data++; data += 16; while(data[0] == ' '){ 8028b68: 7821 ldrb r1, [r4, #0] 8028b6a: 3301 adds r3, #1 8028b6c: 2920 cmp r1, #32 UPS.Status |= (value[i] - 0x30) << (7-i); } } void ups_info_response(char *data) 8028b6e: b2d2 uxtb r2, r2 data++; data += 16; while(data[0] == ' '){ 8028b70: d0f8 beq.n 8028b64 data ++; i ++; } if(i < 11){ 8028b72: 2a0a cmp r2, #10 8028b74: d80c bhi.n 8028b90 endValue = strpbrk(data," "); 8028b76: 4620 mov r0, r4 8028b78: 490c ldr r1, [pc, #48] ; (8028bac ) 8028b7a: f7f9 fa63 bl 8022044 len = endValue - data; 8028b7e: 1b00 subs r0, r0, r4 void ups_megatec_init(void) { init_UPS_value(); xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); } 8028b80: b2c5 uxtb r5, r0 i ++; } if(i < 11){ endValue = strpbrk(data," "); len = endValue - data; strncpy(UPS.model, data, len); 8028b82: 4621 mov r1, r4 8028b84: 462a mov r2, r5 8028b86: 480a ldr r0, [pc, #40] ; (8028bb0 ) 8028b88: f7f9 fa2a bl 8021fe0 data += (len + 1); 8028b8c: 3501 adds r5, #1 8028b8e: 1964 adds r4, r4, r5 } endValue = strpbrk(data,"\r"); 8028b90: 4620 mov r0, r4 8028b92: 4908 ldr r1, [pc, #32] ; (8028bb4 ) 8028b94: f7f9 fa56 bl 8022044 len = endValue - data; 8028b98: 1b02 subs r2, r0, r4 strncpy(UPS.vertion, data, len); 8028b9a: 4807 ldr r0, [pc, #28] ; (8028bb8 ) 8028b9c: 4621 mov r1, r4 8028b9e: b2d2 uxtb r2, r2 } 8028ba0: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} data += (len + 1); } endValue = strpbrk(data,"\r"); len = endValue - data; strncpy(UPS.vertion, data, len); 8028ba4: f7f9 ba1c b.w 8021fe0 8028ba8: bd38 pop {r3, r4, r5, pc} 8028baa: bf00 nop 8028bac: 08035f57 .word 0x08035f57 8028bb0: 2000e8c8 .word 0x2000e8c8 8028bb4: 080409a5 .word 0x080409a5 8028bb8: 2000e8d3 .word 0x2000e8d3 08028bbc : break; } } void request_task(void) { 8028bbc: b508 push {r3, lr} 8028bbe: 2000 movs r0, #0 8028bc0: f7ff feac bl 802891c for(;;) { send_MegaTec_cmd(ups_status_req); if (ups_megatec_rx_pdu()) 8028bc4: f7ff fed8 bl 8028978 8028bc8: b110 cbz r0, 8028bd0 void ups_megatec_process_pdu(cmdMegaTecEnums_t command) { switch(command) { case ups_status_req: ups_status_response(ups_pdu.data); 8028bca: 4808 ldr r0, [pc, #32] ; (8028bec ) 8028bcc: f7ff fef4 bl 80289b8 8028bd0: 2009 movs r0, #9 8028bd2: f7ff fea3 bl 802891c { send_MegaTec_cmd(ups_status_req); if (ups_megatec_rx_pdu()) ups_megatec_process_pdu(ups_status_req); send_MegaTec_cmd(ups_info); if (ups_megatec_rx_pdu()) 8028bd6: f7ff fecf bl 8028978 8028bda: b110 cbz r0, 8028be2 { case ups_status_req: ups_status_response(ups_pdu.data); break; case ups_info: ups_info_response(ups_pdu.data); 8028bdc: 4803 ldr r0, [pc, #12] ; (8028bec ) 8028bde: f7ff ffbb bl 8028b58 ups_megatec_process_pdu(ups_status_req); send_MegaTec_cmd(ups_info); if (ups_megatec_rx_pdu()) ups_megatec_process_pdu(ups_info); vTaskDelay(1000); 8028be2: f44f 707a mov.w r0, #1000 ; 0x3e8 8028be6: f000 fe65 bl 80298b4 } 8028bea: e7e8 b.n 8028bbe 8028bec: 200028ae .word 0x200028ae 08028bf0 : } void ups_megatec_init(void) { 8028bf0: b51f push {r0, r1, r2, r3, r4, lr} init_UPS_value(); 8028bf2: f7ff fea3 bl 802893c xTaskCreate(request_task, ( char * ) "request_task", configMINIMAL_STACK_SIZE * 2, NULL, tskIDLE_PRIORITY, NULL); 8028bf6: 2300 movs r3, #0 8028bf8: 9300 str r3, [sp, #0] 8028bfa: 9301 str r3, [sp, #4] 8028bfc: 9302 str r3, [sp, #8] 8028bfe: 9303 str r3, [sp, #12] 8028c00: 4903 ldr r1, [pc, #12] ; (8028c10 ) 8028c02: 4804 ldr r0, [pc, #16] ; (8028c14 ) 8028c04: f44f 7280 mov.w r2, #256 ; 0x100 8028c08: f000 fbba bl 8029380 } 8028c0c: b005 add sp, #20 8028c0e: bd00 pop {pc} 8028c10: 08035f59 .word 0x08035f59 8028c14: 08028bbd .word 0x08028bbd 08028c18 : #define _size_w(n) sizeof(n) / sizeof(int) void rbuf32_init(rbuf_t *rbuf32, uint32_t *buffer, uint32_t size) { rbuf32->buf_ptr = buffer; rbuf32->size = size; rbuf32->read_index = 0; 8028c18: 2300 movs r3, #0 #define _size_w(n) sizeof(n) / sizeof(int) void rbuf32_init(rbuf_t *rbuf32, uint32_t *buffer, uint32_t size) { rbuf32->buf_ptr = buffer; rbuf32->size = size; 8028c1a: e880 0006 stmia.w r0, {r1, r2} rbuf32->read_index = 0; 8028c1e: 6083 str r3, [r0, #8] rbuf32->write_index = 0; 8028c20: 60c3 str r3, [r0, #12] 8028c22: 4770 bx lr 08028c24 : return full_space; } bool rbuf_isfull(rbuf_t *rbuf) { int r_tmp; if (rbuf->write_index == (rbuf->size - 1)) { 8028c24: 6842 ldr r2, [r0, #4] 8028c26: 68c3 ldr r3, [r0, #12] 8028c28: 6880 ldr r0, [r0, #8] 8028c2a: 1e51 subs r1, r2, #1 8028c2c: 428b cmp r3, r1 r_tmp = rbuf->read_index + rbuf->size; 8028c2e: bf08 it eq 8028c30: 1810 addeq r0, r2, r0 } else r_tmp = rbuf->read_index; if (r_tmp - rbuf->write_index == 1) 8028c32: 1ac0 subs r0, r0, r3 return true; else return false; } 8028c34: 1e42 subs r2, r0, #1 8028c36: 4250 negs r0, r2 8028c38: 4150 adcs r0, r2 8028c3a: 4770 bx lr 08028c3c : rbuf64->read_index = 0; rbuf64->write_index = 0; } bool rbuf_isempty(rbuf_t *rbuf) { if (rbuf->read_index == rbuf->write_index) 8028c3c: 6883 ldr r3, [r0, #8] 8028c3e: 68c2 ldr r2, [r0, #12] 8028c40: 4293 cmp r3, r2 8028c42: d105 bne.n 8028c50 8028c44: e002 b.n 8028c4c /* Check whether buffer is not empty */ if (!rbuf_isempty(rbuf32)) { *data = rbuf32->buf_ptr[rbuf32->read_index++]; /* swap the read pointer */ if (rbuf32->read_index == (rbuf32->size)) rbuf32->read_index = 0; 8028c46: 2300 movs r3, #0 8028c48: 6083 str r3, [r0, #8] 8028c4a: e00a b.n 8028c62 return true; } else return false; 8028c4c: 2000 movs r0, #0 8028c4e: 4770 bx lr } bool rbuf32_get(rbuf_t *rbuf32, uint32_t *data) { /* Check whether buffer is not empty */ if (!rbuf_isempty(rbuf32)) { *data = rbuf32->buf_ptr[rbuf32->read_index++]; 8028c50: 6802 ldr r2, [r0, #0] 8028c52: f852 2023 ldr.w r2, [r2, r3, lsl #2] 8028c56: 600a str r2, [r1, #0] /* swap the read pointer */ if (rbuf32->read_index == (rbuf32->size)) 8028c58: 6842 ldr r2, [r0, #4] } bool rbuf32_get(rbuf_t *rbuf32, uint32_t *data) { /* Check whether buffer is not empty */ if (!rbuf_isempty(rbuf32)) { *data = rbuf32->buf_ptr[rbuf32->read_index++]; 8028c5a: 3301 adds r3, #1 /* swap the read pointer */ if (rbuf32->read_index == (rbuf32->size)) 8028c5c: 4293 cmp r3, r2 } bool rbuf32_get(rbuf_t *rbuf32, uint32_t *data) { /* Check whether buffer is not empty */ if (!rbuf_isempty(rbuf32)) { *data = rbuf32->buf_ptr[rbuf32->read_index++]; 8028c5e: 6083 str r3, [r0, #8] /* swap the read pointer */ if (rbuf32->read_index == (rbuf32->size)) 8028c60: d0f1 beq.n 8028c46 rbuf32->read_index = 0; return true; 8028c62: 2001 movs r0, #1 } else return false; } 8028c64: 4770 bx lr 08028c66 : /* * Oldest data is overwriting when write_ptr reaches read_ptr - 1 (!). * For check use rbuf_isfull. */ bool rbuf32_put(rbuf_t *rbuf32, uint32_t data) { 8028c66: b538 push {r3, r4, r5, lr} 8028c68: 4604 mov r4, r0 8028c6a: 460d mov r5, r1 if(!rbuf_isfull(rbuf32)) 8028c6c: f7ff ffda bl 8028c24 8028c70: b950 cbnz r0, 8028c88 { rbuf32->buf_ptr[rbuf32->write_index++] = data; 8028c72: 68e3 ldr r3, [r4, #12] 8028c74: 6822 ldr r2, [r4, #0] 8028c76: f842 5023 str.w r5, [r2, r3, lsl #2] /* swap the write pointer */ if (rbuf32->write_index == (rbuf32->size)) 8028c7a: 6862 ldr r2, [r4, #4] */ bool rbuf32_put(rbuf_t *rbuf32, uint32_t data) { if(!rbuf_isfull(rbuf32)) { rbuf32->buf_ptr[rbuf32->write_index++] = data; 8028c7c: 3301 adds r3, #1 /* swap the write pointer */ if (rbuf32->write_index == (rbuf32->size)) 8028c7e: 4293 cmp r3, r2 */ bool rbuf32_put(rbuf_t *rbuf32, uint32_t data) { if(!rbuf_isfull(rbuf32)) { rbuf32->buf_ptr[rbuf32->write_index++] = data; 8028c80: 60e3 str r3, [r4, #12] /* swap the write pointer */ if (rbuf32->write_index == (rbuf32->size)) 8028c82: d103 bne.n 8028c8c rbuf32->write_index = 0; 8028c84: 60e0 str r0, [r4, #12] 8028c86: e001 b.n 8028c8c return true; } else return false; 8028c88: 2000 movs r0, #0 8028c8a: bd38 pop {r3, r4, r5, pc} bool rbuf32_put(rbuf_t *rbuf32, uint32_t data) { if(!rbuf_isfull(rbuf32)) { rbuf32->buf_ptr[rbuf32->write_index++] = data; /* swap the write pointer */ if (rbuf32->write_index == (rbuf32->size)) 8028c8c: 2001 movs r0, #1 rbuf32->write_index = 0; return true; } else return false; } 8028c8e: bd38 pop {r3, r4, r5, pc} 08028c90 : void vListInitialise( List_t * const pxList ) { /* The list structure contains a list item which is used to mark the end of the list. To initialise the list the list end is inserted as the only list entry. */ pxList->pxIndex = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ 8028c90: f100 0308 add.w r3, r0, #8 8028c94: 6043 str r3, [r0, #4] /* The list end value is the highest possible value in the list to ensure it remains at the end of the list. */ pxList->xListEnd.xItemValue = portMAX_DELAY; 8028c96: f04f 32ff mov.w r2, #4294967295 /* The list end next and previous pointers point to itself so we know when the list is empty. */ pxList->xListEnd.pxNext = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ 8028c9a: 60c3 str r3, [r0, #12] pxList->xListEnd.pxPrevious = ( ListItem_t * ) &( pxList->xListEnd );/*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ 8028c9c: 6103 str r3, [r0, #16] pxList->uxNumberOfItems = ( UBaseType_t ) 0U; 8028c9e: 2300 movs r3, #0 as the only list entry. */ pxList->pxIndex = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ /* The list end value is the highest possible value in the list to ensure it remains at the end of the list. */ pxList->xListEnd.xItemValue = portMAX_DELAY; 8028ca0: 6082 str r2, [r0, #8] /* The list end next and previous pointers point to itself so we know when the list is empty. */ pxList->xListEnd.pxNext = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ pxList->xListEnd.pxPrevious = ( ListItem_t * ) &( pxList->xListEnd );/*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ pxList->uxNumberOfItems = ( UBaseType_t ) 0U; 8028ca2: 6003 str r3, [r0, #0] 8028ca4: 4770 bx lr 08028ca6 : /*-----------------------------------------------------------*/ void vListInitialiseItem( ListItem_t * const pxItem ) { /* Make sure the list item is not recorded as being on a list. */ pxItem->pvContainer = NULL; 8028ca6: 2300 movs r3, #0 8028ca8: 6103 str r3, [r0, #16] 8028caa: 4770 bx lr 08028cac : } /*-----------------------------------------------------------*/ void vListInsertEnd( List_t * const pxList, ListItem_t * const pxNewListItem ) { ListItem_t * const pxIndex = pxList->pxIndex; 8028cac: 6843 ldr r3, [r0, #4] pxNewListItem->pxPrevious = pxIndex->pxPrevious; pxIndex->pxPrevious->pxNext = pxNewListItem; pxIndex->pxPrevious = pxNewListItem; /* Remember which list the item is in. */ pxNewListItem->pvContainer = ( void * ) pxList; 8028cae: 6108 str r0, [r1, #16] /* Insert a new list item into pxList, but rather than sort the list, makes the new list item the last item to be removed by a call to listGET_OWNER_OF_NEXT_ENTRY(). */ pxNewListItem->pxNext = pxIndex; pxNewListItem->pxPrevious = pxIndex->pxPrevious; 8028cb0: 689a ldr r2, [r3, #8] listTEST_LIST_ITEM_INTEGRITY( pxNewListItem ); /* Insert a new list item into pxList, but rather than sort the list, makes the new list item the last item to be removed by a call to listGET_OWNER_OF_NEXT_ENTRY(). */ pxNewListItem->pxNext = pxIndex; 8028cb2: 604b str r3, [r1, #4] pxNewListItem->pxPrevious = pxIndex->pxPrevious; 8028cb4: 608a str r2, [r1, #8] pxIndex->pxPrevious->pxNext = pxNewListItem; 8028cb6: 689a ldr r2, [r3, #8] pxIndex->pxPrevious = pxNewListItem; 8028cb8: 6099 str r1, [r3, #8] /* Remember which list the item is in. */ pxNewListItem->pvContainer = ( void * ) pxList; ( pxList->uxNumberOfItems )++; 8028cba: 6803 ldr r3, [r0, #0] /* Insert a new list item into pxList, but rather than sort the list, makes the new list item the last item to be removed by a call to listGET_OWNER_OF_NEXT_ENTRY(). */ pxNewListItem->pxNext = pxIndex; pxNewListItem->pxPrevious = pxIndex->pxPrevious; pxIndex->pxPrevious->pxNext = pxNewListItem; 8028cbc: 6051 str r1, [r2, #4] pxIndex->pxPrevious = pxNewListItem; /* Remember which list the item is in. */ pxNewListItem->pvContainer = ( void * ) pxList; ( pxList->uxNumberOfItems )++; 8028cbe: 3301 adds r3, #1 8028cc0: 6003 str r3, [r0, #0] 8028cc2: 4770 bx lr 08028cc4 : /*-----------------------------------------------------------*/ void vListInsert( List_t * const pxList, ListItem_t * const pxNewListItem ) { ListItem_t *pxIterator; const TickType_t xValueOfInsertion = pxNewListItem->xItemValue; 8028cc4: 680a ldr r2, [r1, #0] new list item should be placed after it. This ensures that TCB's which are stored in ready lists (all of which have the same xItemValue value) get a share of the CPU. However, if the xItemValue is the same as the back marker the iteration loop below will not end. Therefore the value is checked first, and the algorithm slightly modified if necessary. */ if( xValueOfInsertion == portMAX_DELAY ) 8028cc6: 1c53 adds r3, r2, #1 ( pxList->uxNumberOfItems )++; } /*-----------------------------------------------------------*/ void vListInsert( List_t * const pxList, ListItem_t * const pxNewListItem ) { 8028cc8: b530 push {r4, r5, lr} new list item should be placed after it. This ensures that TCB's which are stored in ready lists (all of which have the same xItemValue value) get a share of the CPU. However, if the xItemValue is the same as the back marker the iteration loop below will not end. Therefore the value is checked first, and the algorithm slightly modified if necessary. */ if( xValueOfInsertion == portMAX_DELAY ) 8028cca: d101 bne.n 8028cd0 { pxIterator = pxList->xListEnd.pxPrevious; 8028ccc: 6903 ldr r3, [r0, #16] 8028cce: e007 b.n 8028ce0 4) Using a queue or semaphore before it has been initialised or before the scheduler has been started (are interrupts firing before vTaskStartScheduler() has been called?). **********************************************************************/ for( pxIterator = ( ListItem_t * ) &( pxList->xListEnd ); pxIterator->pxNext->xItemValue <= xValueOfInsertion; pxIterator = pxIterator->pxNext ) /*lint !e826 !e740 The mini list structure is used as the list end to save RAM. This is checked and valid. */ 8028cd0: f100 0308 add.w r3, r0, #8 8028cd4: e000 b.n 8028cd8 8028cd6: 4623 mov r3, r4 8028cd8: 685c ldr r4, [r3, #4] 8028cda: 6825 ldr r5, [r4, #0] 8028cdc: 4295 cmp r5, r2 8028cde: d9fa bls.n 8028cd6 /* There is nothing to do here, just iterating to the wanted insertion position. */ } } pxNewListItem->pxNext = pxIterator->pxNext; 8028ce0: 685a ldr r2, [r3, #4] pxNewListItem->pxPrevious = pxIterator; pxIterator->pxNext = pxNewListItem; /* Remember which list the item is in. This allows fast removal of the item later. */ pxNewListItem->pvContainer = ( void * ) pxList; 8028ce2: 6108 str r0, [r1, #16] /* There is nothing to do here, just iterating to the wanted insertion position. */ } } pxNewListItem->pxNext = pxIterator->pxNext; 8028ce4: 604a str r2, [r1, #4] pxNewListItem->pxNext->pxPrevious = pxNewListItem; 8028ce6: 6091 str r1, [r2, #8] pxNewListItem->pxPrevious = pxIterator; pxIterator->pxNext = pxNewListItem; 8028ce8: 6059 str r1, [r3, #4] } } pxNewListItem->pxNext = pxIterator->pxNext; pxNewListItem->pxNext->pxPrevious = pxNewListItem; pxNewListItem->pxPrevious = pxIterator; 8028cea: 608b str r3, [r1, #8] /* Remember which list the item is in. This allows fast removal of the item later. */ pxNewListItem->pvContainer = ( void * ) pxList; ( pxList->uxNumberOfItems )++; 8028cec: 6803 ldr r3, [r0, #0] 8028cee: 3301 adds r3, #1 8028cf0: 6003 str r3, [r0, #0] 8028cf2: bd30 pop {r4, r5, pc} 08028cf4 : { /* The list item knows which list it is in. Obtain the list from the list item. */ List_t * const pxList = ( List_t * ) pxItemToRemove->pvContainer; pxItemToRemove->pxNext->pxPrevious = pxItemToRemove->pxPrevious; 8028cf4: 6841 ldr r1, [r0, #4] 8028cf6: 6882 ldr r2, [r0, #8] UBaseType_t uxListRemove( ListItem_t * const pxItemToRemove ) { /* The list item knows which list it is in. Obtain the list from the list item. */ List_t * const pxList = ( List_t * ) pxItemToRemove->pvContainer; 8028cf8: 6903 ldr r3, [r0, #16] pxItemToRemove->pxNext->pxPrevious = pxItemToRemove->pxPrevious; 8028cfa: 608a str r2, [r1, #8] pxItemToRemove->pxPrevious->pxNext = pxItemToRemove->pxNext; 8028cfc: 6882 ldr r2, [r0, #8] 8028cfe: 6051 str r1, [r2, #4] /* Make sure the index is left pointing to a valid item. */ if( pxList->pxIndex == pxItemToRemove ) 8028d00: 6859 ldr r1, [r3, #4] 8028d02: 4281 cmp r1, r0 { pxList->pxIndex = pxItemToRemove->pxPrevious; 8028d04: bf08 it eq 8028d06: 605a streq r2, [r3, #4] else { mtCOVERAGE_TEST_MARKER(); } pxItemToRemove->pvContainer = NULL; 8028d08: 2200 movs r2, #0 8028d0a: 6102 str r2, [r0, #16] ( pxList->uxNumberOfItems )--; 8028d0c: 6818 ldr r0, [r3, #0] 8028d0e: 3801 subs r0, #1 8028d10: 6018 str r0, [r3, #0] return pxList->uxNumberOfItems; } 8028d12: 4770 bx lr 08028d14 : } } /*-----------------------------------------------------------*/ static void prvUnlockQueue( Queue_t * const pxQueue ) { 8028d14: b538 push {r3, r4, r5, lr} 8028d16: 4604 mov r4, r0 { /* Tasks that are removed from the event list will get added to the pending ready list as the scheduler is still suspended. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) 8028d18: f104 0524 add.w r5, r4, #36 ; 0x24 /* The lock counts contains the number of extra data items placed or removed from the queue while the queue was locked. When a queue is locked items can be added or removed, but the event lists cannot be updated. */ taskENTER_CRITICAL(); 8028d1c: f001 f994 bl 802a048 { /* See if data was added to the queue while it was locked. */ while( pxQueue->xTxLock > queueLOCKED_UNMODIFIED ) 8028d20: e00a b.n 8028d38 } #else /* configUSE_QUEUE_SETS */ { /* Tasks that are removed from the event list will get added to the pending ready list as the scheduler is still suspended. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 8028d22: 6a63 ldr r3, [r4, #36] ; 0x24 8028d24: b15b cbz r3, 8028d3e { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) 8028d26: 4628 mov r0, r5 8028d28: f000 fe82 bl 8029a30 8028d2c: b108 cbz r0, 8028d32 { /* The task waiting has a higher priority so record that a context switch is required. */ vTaskMissedYield(); 8028d2e: f000 fef9 bl 8029b24 break; } } #endif /* configUSE_QUEUE_SETS */ --( pxQueue->xTxLock ); 8028d32: 6ca3 ldr r3, [r4, #72] ; 0x48 8028d34: 3b01 subs r3, #1 8028d36: 64a3 str r3, [r4, #72] ; 0x48 locked items can be added or removed, but the event lists cannot be updated. */ taskENTER_CRITICAL(); { /* See if data was added to the queue while it was locked. */ while( pxQueue->xTxLock > queueLOCKED_UNMODIFIED ) 8028d38: 6ca3 ldr r3, [r4, #72] ; 0x48 8028d3a: 2b00 cmp r3, #0 8028d3c: dcf1 bgt.n 8028d22 #endif /* configUSE_QUEUE_SETS */ --( pxQueue->xTxLock ); } pxQueue->xTxLock = queueUNLOCKED; 8028d3e: f04f 33ff mov.w r3, #4294967295 8028d42: 64a3 str r3, [r4, #72] ; 0x48 } taskEXIT_CRITICAL(); 8028d44: f001 f9ac bl 802a0a0 { while( pxQueue->xRxLock > queueLOCKED_UNMODIFIED ) { if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) 8028d48: f104 0510 add.w r5, r4, #16 pxQueue->xTxLock = queueUNLOCKED; } taskEXIT_CRITICAL(); /* Do the same for the Rx lock. */ taskENTER_CRITICAL(); 8028d4c: f001 f97c bl 802a048 { while( pxQueue->xRxLock > queueLOCKED_UNMODIFIED ) 8028d50: e00a b.n 8028d68 { if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) 8028d52: 6923 ldr r3, [r4, #16] 8028d54: b15b cbz r3, 8028d6e { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) 8028d56: 4628 mov r0, r5 8028d58: f000 fe6a bl 8029a30 8028d5c: b108 cbz r0, 8028d62 { vTaskMissedYield(); 8028d5e: f000 fee1 bl 8029b24 else { mtCOVERAGE_TEST_MARKER(); } --( pxQueue->xRxLock ); 8028d62: 6c63 ldr r3, [r4, #68] ; 0x44 8028d64: 3b01 subs r3, #1 8028d66: 6463 str r3, [r4, #68] ; 0x44 taskEXIT_CRITICAL(); /* Do the same for the Rx lock. */ taskENTER_CRITICAL(); { while( pxQueue->xRxLock > queueLOCKED_UNMODIFIED ) 8028d68: 6c63 ldr r3, [r4, #68] ; 0x44 8028d6a: 2b00 cmp r3, #0 8028d6c: dcf1 bgt.n 8028d52 { break; } } pxQueue->xRxLock = queueUNLOCKED; 8028d6e: f04f 33ff mov.w r3, #4294967295 8028d72: 6463 str r3, [r4, #68] ; 0x44 } taskEXIT_CRITICAL(); } 8028d74: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} } } pxQueue->xRxLock = queueUNLOCKED; } taskEXIT_CRITICAL(); 8028d78: f001 b992 b.w 802a0a0 08028d7c : } /*-----------------------------------------------------------*/ static void prvCopyDataFromQueue( Queue_t * const pxQueue, void * const pvBuffer ) { if( pxQueue->uxItemSize != ( UBaseType_t ) 0 ) 8028d7c: 6c02 ldr r2, [r0, #64] ; 0x40 return xReturn; } /*-----------------------------------------------------------*/ static void prvCopyDataFromQueue( Queue_t * const pxQueue, void * const pvBuffer ) { 8028d7e: b530 push {r4, r5, lr} 8028d80: 4603 mov r3, r0 if( pxQueue->uxItemSize != ( UBaseType_t ) 0 ) 8028d82: b16a cbz r2, 8028da0 { pxQueue->u.pcReadFrom += pxQueue->uxItemSize; 8028d84: 68c4 ldr r4, [r0, #12] if( pxQueue->u.pcReadFrom >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as use of the relational operator is the cleanest solutions. */ 8028d86: 6845 ldr r5, [r0, #4] static void prvCopyDataFromQueue( Queue_t * const pxQueue, void * const pvBuffer ) { if( pxQueue->uxItemSize != ( UBaseType_t ) 0 ) { pxQueue->u.pcReadFrom += pxQueue->uxItemSize; 8028d88: 18a4 adds r4, r4, r2 if( pxQueue->u.pcReadFrom >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as use of the relational operator is the cleanest solutions. */ 8028d8a: 42ac cmp r4, r5 static void prvCopyDataFromQueue( Queue_t * const pxQueue, void * const pvBuffer ) { if( pxQueue->uxItemSize != ( UBaseType_t ) 0 ) { pxQueue->u.pcReadFrom += pxQueue->uxItemSize; 8028d8c: 60c4 str r4, [r0, #12] if( pxQueue->u.pcReadFrom >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as use of the relational operator is the cleanest solutions. */ { pxQueue->u.pcReadFrom = pxQueue->pcHead; 8028d8e: bf24 itt cs 8028d90: 6804 ldrcs r4, [r0, #0] 8028d92: 60c4 strcs r4, [r0, #12] } else { mtCOVERAGE_TEST_MARKER(); } ( void ) memcpy( ( void * ) pvBuffer, ( void * ) pxQueue->u.pcReadFrom, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 !e418 MISRA exception as the casts are only redundant for some ports. Also previous logic ensures a null pointer can only be passed to memcpy() when the count is 0. */ 8028d94: 4608 mov r0, r1 8028d96: 68d9 ldr r1, [r3, #12] } } 8028d98: e8bd 4030 ldmia.w sp!, {r4, r5, lr} } else { mtCOVERAGE_TEST_MARKER(); } ( void ) memcpy( ( void * ) pvBuffer, ( void * ) pxQueue->u.pcReadFrom, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 !e418 MISRA exception as the casts are only redundant for some ports. Also previous logic ensures a null pointer can only be passed to memcpy() when the count is 0. */ 8028d9c: f7f8 bdd6 b.w 802194c 8028da0: bd30 pop {r4, r5, pc} 08028da2 : #endif /* configUSE_TRACE_FACILITY */ /*-----------------------------------------------------------*/ static BaseType_t prvCopyDataToQueue( Queue_t * const pxQueue, const void *pvItemToQueue, const BaseType_t xPosition ) { 8028da2: b538 push {r3, r4, r5, lr} 8028da4: 4615 mov r5, r2 BaseType_t xReturn = pdFALSE; if( pxQueue->uxItemSize == ( UBaseType_t ) 0 ) 8028da6: 6c02 ldr r2, [r0, #64] ; 0x40 #endif /* configUSE_TRACE_FACILITY */ /*-----------------------------------------------------------*/ static BaseType_t prvCopyDataToQueue( Queue_t * const pxQueue, const void *pvItemToQueue, const BaseType_t xPosition ) { 8028da8: 4604 mov r4, r0 BaseType_t xReturn = pdFALSE; if( pxQueue->uxItemSize == ( UBaseType_t ) 0 ) 8028daa: b93a cbnz r2, 8028dbc { #if ( configUSE_MUTEXES == 1 ) { if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) 8028dac: 6805 ldr r5, [r0, #0] 8028dae: b105 cbz r5, 8028db2 8028db0: e028 b.n 8028e04 { /* The mutex is no longer being held. */ xReturn = xTaskPriorityDisinherit( ( void * ) pxQueue->pxMutexHolder ); 8028db2: 6840 ldr r0, [r0, #4] 8028db4: f000 ff18 bl 8029be8 pxQueue->pxMutexHolder = NULL; 8028db8: 6065 str r5, [r4, #4] 8028dba: e024 b.n 8028e06 mtCOVERAGE_TEST_MARKER(); } } #endif /* configUSE_MUTEXES */ } else if( xPosition == queueSEND_TO_BACK ) 8028dbc: b96d cbnz r5, 8028dda { ( void ) memcpy( ( void * ) pxQueue->pcWriteTo, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 !e418 MISRA exception as the casts are only redundant for some ports, plus previous logic ensures a null pointer can only be passed to memcpy() if the copy size is 0. */ 8028dbe: 6880 ldr r0, [r0, #8] 8028dc0: f7f8 fdc4 bl 802194c pxQueue->pcWriteTo += pxQueue->uxItemSize; 8028dc4: 68a2 ldr r2, [r4, #8] 8028dc6: 6c23 ldr r3, [r4, #64] ; 0x40 8028dc8: 18d3 adds r3, r2, r3 if( pxQueue->pcWriteTo >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ 8028dca: 6862 ldr r2, [r4, #4] #endif /* configUSE_MUTEXES */ } else if( xPosition == queueSEND_TO_BACK ) { ( void ) memcpy( ( void * ) pxQueue->pcWriteTo, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 !e418 MISRA exception as the casts are only redundant for some ports, plus previous logic ensures a null pointer can only be passed to memcpy() if the copy size is 0. */ pxQueue->pcWriteTo += pxQueue->uxItemSize; 8028dcc: 60a3 str r3, [r4, #8] if( pxQueue->pcWriteTo >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ 8028dce: 4293 cmp r3, r2 8028dd0: d318 bcc.n 8028e04 { pxQueue->pcWriteTo = pxQueue->pcHead; 8028dd2: 6823 ldr r3, [r4, #0] #endif /* configUSE_TRACE_FACILITY */ /*-----------------------------------------------------------*/ static BaseType_t prvCopyDataToQueue( Queue_t * const pxQueue, const void *pvItemToQueue, const BaseType_t xPosition ) { BaseType_t xReturn = pdFALSE; 8028dd4: 4628 mov r0, r5 { ( void ) memcpy( ( void * ) pxQueue->pcWriteTo, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 !e418 MISRA exception as the casts are only redundant for some ports, plus previous logic ensures a null pointer can only be passed to memcpy() if the copy size is 0. */ pxQueue->pcWriteTo += pxQueue->uxItemSize; if( pxQueue->pcWriteTo >= pxQueue->pcTail ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ { pxQueue->pcWriteTo = pxQueue->pcHead; 8028dd6: 60a3 str r3, [r4, #8] 8028dd8: e015 b.n 8028e06 mtCOVERAGE_TEST_MARKER(); } } else { ( void ) memcpy( ( void * ) pxQueue->u.pcReadFrom, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 8028dda: 68c0 ldr r0, [r0, #12] 8028ddc: f7f8 fdb6 bl 802194c pxQueue->u.pcReadFrom -= pxQueue->uxItemSize; 8028de0: 6c23 ldr r3, [r4, #64] ; 0x40 8028de2: 68e2 ldr r2, [r4, #12] if( pxQueue->u.pcReadFrom < pxQueue->pcHead ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ 8028de4: 6821 ldr r1, [r4, #0] } } else { ( void ) memcpy( ( void * ) pxQueue->u.pcReadFrom, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ pxQueue->u.pcReadFrom -= pxQueue->uxItemSize; 8028de6: 425b negs r3, r3 8028de8: 18d2 adds r2, r2, r3 if( pxQueue->u.pcReadFrom < pxQueue->pcHead ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ 8028dea: 428a cmp r2, r1 } } else { ( void ) memcpy( ( void * ) pxQueue->u.pcReadFrom, pvItemToQueue, ( size_t ) pxQueue->uxItemSize ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ pxQueue->u.pcReadFrom -= pxQueue->uxItemSize; 8028dec: 60e2 str r2, [r4, #12] if( pxQueue->u.pcReadFrom < pxQueue->pcHead ) /*lint !e946 MISRA exception justified as comparison of pointers is the cleanest solution. */ 8028dee: d202 bcs.n 8028df6 { pxQueue->u.pcReadFrom = ( pxQueue->pcTail - pxQueue->uxItemSize ); 8028df0: 6862 ldr r2, [r4, #4] 8028df2: 18d3 adds r3, r2, r3 8028df4: 60e3 str r3, [r4, #12] else { mtCOVERAGE_TEST_MARKER(); } if( xPosition == queueOVERWRITE ) 8028df6: 2d02 cmp r5, #2 8028df8: d104 bne.n 8028e04 { if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) 8028dfa: 6ba3 ldr r3, [r4, #56] ; 0x38 8028dfc: b113 cbz r3, 8028e04 { /* An item is not being added but overwritten, so subtract one from the recorded number of items in the queue so when one is added again below the number of recorded items remains correct. */ --( pxQueue->uxMessagesWaiting ); 8028dfe: 6ba3 ldr r3, [r4, #56] ; 0x38 8028e00: 3b01 subs r3, #1 8028e02: 63a3 str r3, [r4, #56] ; 0x38 #endif /* configUSE_TRACE_FACILITY */ /*-----------------------------------------------------------*/ static BaseType_t prvCopyDataToQueue( Queue_t * const pxQueue, const void *pvItemToQueue, const BaseType_t xPosition ) { BaseType_t xReturn = pdFALSE; 8028e04: 2000 movs r0, #0 { mtCOVERAGE_TEST_MARKER(); } } ++( pxQueue->uxMessagesWaiting ); 8028e06: 6ba3 ldr r3, [r4, #56] ; 0x38 8028e08: 3301 adds r3, #1 8028e0a: 63a3 str r3, [r4, #56] ; 0x38 return xReturn; } 8028e0c: bd38 pop {r3, r4, r5, pc} 08028e0e : } \ taskEXIT_CRITICAL() /*-----------------------------------------------------------*/ BaseType_t xQueueGenericReset( QueueHandle_t xQueue, BaseType_t xNewQueue ) { 8028e0e: b538 push {r3, r4, r5, lr} 8028e10: 460d mov r5, r1 Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 8028e12: 4604 mov r4, r0 8028e14: b910 cbnz r0, 8028e1c 8028e16: f001 f90f bl 802a038 8028e1a: e7fe b.n 8028e1a taskENTER_CRITICAL(); 8028e1c: f001 f914 bl 802a048 { pxQueue->pcTail = pxQueue->pcHead + ( pxQueue->uxLength * pxQueue->uxItemSize ); 8028e20: 6823 ldr r3, [r4, #0] 8028e22: 6be0 ldr r0, [r4, #60] ; 0x3c 8028e24: 6c22 ldr r2, [r4, #64] ; 0x40 pxQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxQueue->pcWriteTo = pxQueue->pcHead; 8028e26: 60a3 str r3, [r4, #8] configASSERT( pxQueue ); taskENTER_CRITICAL(); { pxQueue->pcTail = pxQueue->pcHead + ( pxQueue->uxLength * pxQueue->uxItemSize ); 8028e28: fb00 3102 mla r1, r0, r2, r3 pxQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxQueue->pcWriteTo = pxQueue->pcHead; pxQueue->u.pcReadFrom = pxQueue->pcHead + ( ( pxQueue->uxLength - ( UBaseType_t ) 1U ) * pxQueue->uxItemSize ); 8028e2c: 3801 subs r0, #1 8028e2e: fb02 3300 mla r3, r2, r0, r3 configASSERT( pxQueue ); taskENTER_CRITICAL(); { pxQueue->pcTail = pxQueue->pcHead + ( pxQueue->uxLength * pxQueue->uxItemSize ); 8028e32: 6061 str r1, [r4, #4] pxQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxQueue->pcWriteTo = pxQueue->pcHead; pxQueue->u.pcReadFrom = pxQueue->pcHead + ( ( pxQueue->uxLength - ( UBaseType_t ) 1U ) * pxQueue->uxItemSize ); 8028e34: 60e3 str r3, [r4, #12] configASSERT( pxQueue ); taskENTER_CRITICAL(); { pxQueue->pcTail = pxQueue->pcHead + ( pxQueue->uxLength * pxQueue->uxItemSize ); pxQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; 8028e36: 2100 movs r1, #0 pxQueue->pcWriteTo = pxQueue->pcHead; pxQueue->u.pcReadFrom = pxQueue->pcHead + ( ( pxQueue->uxLength - ( UBaseType_t ) 1U ) * pxQueue->uxItemSize ); pxQueue->xRxLock = queueUNLOCKED; 8028e38: f04f 33ff mov.w r3, #4294967295 configASSERT( pxQueue ); taskENTER_CRITICAL(); { pxQueue->pcTail = pxQueue->pcHead + ( pxQueue->uxLength * pxQueue->uxItemSize ); pxQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; 8028e3c: 63a1 str r1, [r4, #56] ; 0x38 pxQueue->pcWriteTo = pxQueue->pcHead; pxQueue->u.pcReadFrom = pxQueue->pcHead + ( ( pxQueue->uxLength - ( UBaseType_t ) 1U ) * pxQueue->uxItemSize ); pxQueue->xRxLock = queueUNLOCKED; 8028e3e: 6463 str r3, [r4, #68] ; 0x44 pxQueue->xTxLock = queueUNLOCKED; 8028e40: 64a3 str r3, [r4, #72] ; 0x48 if( xNewQueue == pdFALSE ) 8028e42: b955 cbnz r5, 8028e5a /* If there are tasks blocked waiting to read from the queue, then the tasks will remain blocked as after this function exits the queue will still be empty. If there are tasks blocked waiting to write to the queue, then one should be unblocked as after this function exits it will be possible to write to it. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) 8028e44: 6923 ldr r3, [r4, #16] 8028e46: b183 cbz r3, 8028e6a { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) == pdTRUE ) 8028e48: f104 0010 add.w r0, r4, #16 8028e4c: f000 fdf0 bl 8029a30 8028e50: 2801 cmp r0, #1 8028e52: d10a bne.n 8028e6a { queueYIELD_IF_USING_PREEMPTION(); 8028e54: f001 f8e4 bl 802a020 8028e58: e007 b.n 8028e6a } } else { /* Ensure the event queues start in the correct state. */ vListInitialise( &( pxQueue->xTasksWaitingToSend ) ); 8028e5a: f104 0010 add.w r0, r4, #16 8028e5e: f7ff ff17 bl 8028c90 vListInitialise( &( pxQueue->xTasksWaitingToReceive ) ); 8028e62: f104 0024 add.w r0, r4, #36 ; 0x24 8028e66: f7ff ff13 bl 8028c90 } } taskEXIT_CRITICAL(); 8028e6a: f001 f919 bl 802a0a0 /* A value is returned for calling semantic consistency with previous versions. */ return pdPASS; } 8028e6e: 2001 movs r0, #1 8028e70: bd38 pop {r3, r4, r5, pc} 08028e72 : /*-----------------------------------------------------------*/ QueueHandle_t xQueueGenericCreate( const UBaseType_t uxQueueLength, const UBaseType_t uxItemSize, const uint8_t ucQueueType ) { 8028e72: b5f8 push {r3, r4, r5, r6, r7, lr} 8028e74: 460d mov r5, r1 8028e76: 4617 mov r7, r2 /* Remove compiler warnings about unused parameters should configUSE_TRACE_FACILITY not be set to 1. */ ( void ) ucQueueType; configASSERT( uxQueueLength > ( UBaseType_t ) 0 ); 8028e78: 4606 mov r6, r0 8028e7a: b910 cbnz r0, 8028e82 8028e7c: f001 f8dc bl 802a038 8028e80: e7fe b.n 8028e80 if( uxItemSize == ( UBaseType_t ) 0 ) 8028e82: b111 cbz r1, 8028e8a } else { /* The queue is one byte longer than asked for to make wrap checking easier/faster. */ xQueueSizeInBytes = ( size_t ) ( uxQueueLength * uxItemSize ) + ( size_t ) 1; /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 8028e84: 4348 muls r0, r1 8028e86: 3001 adds r0, #1 8028e88: e000 b.n 8028e8c configASSERT( uxQueueLength > ( UBaseType_t ) 0 ); if( uxItemSize == ( UBaseType_t ) 0 ) { /* There is not going to be a queue storage area. */ xQueueSizeInBytes = ( size_t ) 0; 8028e8a: 4608 mov r0, r1 easier/faster. */ xQueueSizeInBytes = ( size_t ) ( uxQueueLength * uxItemSize ) + ( size_t ) 1; /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ } /* Allocate the new queue structure and storage area. */ pcAllocatedBuffer = ( int8_t * ) pvPortMalloc( sizeof( Queue_t ) + xQueueSizeInBytes ); 8028e8c: 3054 adds r0, #84 ; 0x54 8028e8e: f001 f9e9 bl 802a264 if( pcAllocatedBuffer != NULL ) 8028e92: 4604 mov r4, r0 8028e94: b138 cbz r0, 8028ea6 { pxNewQueue = ( Queue_t * ) pcAllocatedBuffer; /*lint !e826 MISRA The buffer cannot be to small because it was dimensioned by sizeof( Queue_t ) + xQueueSizeInBytes. */ if( uxItemSize == ( UBaseType_t ) 0 ) 8028e96: b90d cbnz r5, 8028e9c { /* No RAM was allocated for the queue storage area, but PC head cannot be set to NULL because NULL is used as a key to say the queue is used as a mutex. Therefore just set pcHead to point to the queue as a benign value that is known to be within the memory map. */ pxNewQueue->pcHead = ( int8_t * ) pxNewQueue; 8028e98: 6020 str r0, [r4, #0] 8028e9a: e007 b.n 8028eac } else { /* Jump past the queue structure to find the location of the queue storage area - adding the padding bytes to get a better alignment. */ pxNewQueue->pcHead = pcAllocatedBuffer + sizeof( Queue_t ); 8028e9c: f100 0354 add.w r3, r0, #84 ; 0x54 8028ea0: 6003 str r3, [r0, #0] 8028ea2: e003 b.n 8028eac 8028ea4: e7fe b.n 8028ea4 else { mtCOVERAGE_TEST_MARKER(); } configASSERT( xReturn ); 8028ea6: f001 f8c7 bl 802a038 8028eaa: e7fb b.n 8028ea4 pxNewQueue->pcHead = pcAllocatedBuffer + sizeof( Queue_t ); } /* Initialise the queue members as described above where the queue type is defined. */ pxNewQueue->uxLength = uxQueueLength; 8028eac: 63e6 str r6, [r4, #60] ; 0x3c pxNewQueue->uxItemSize = uxItemSize; 8028eae: 6425 str r5, [r4, #64] ; 0x40 ( void ) xQueueGenericReset( pxNewQueue, pdTRUE ); 8028eb0: 4620 mov r0, r4 8028eb2: 2101 movs r1, #1 8028eb4: f7ff ffab bl 8028e0e #if ( configUSE_TRACE_FACILITY == 1 ) { pxNewQueue->ucQueueType = ucQueueType; 8028eb8: f884 7050 strb.w r7, [r4, #80] ; 0x50 } configASSERT( xReturn ); return xReturn; } 8028ebc: 4620 mov r0, r4 8028ebe: bdf8 pop {r3, r4, r5, r6, r7, pc} 08028ec0 : /*-----------------------------------------------------------*/ #if ( configUSE_COUNTING_SEMAPHORES == 1 ) QueueHandle_t xQueueCreateCountingSemaphore( const UBaseType_t uxMaxCount, const UBaseType_t uxInitialCount ) { 8028ec0: b510 push {r4, lr} 8028ec2: 460c mov r4, r1 QueueHandle_t xHandle; configASSERT( uxMaxCount != 0 ); 8028ec4: b910 cbnz r0, 8028ecc 8028ec6: f001 f8b7 bl 802a038 8028eca: e7fe b.n 8028eca configASSERT( uxInitialCount <= uxMaxCount ); 8028ecc: 4281 cmp r1, r0 8028ece: d902 bls.n 8028ed6 8028ed0: f001 f8b2 bl 802a038 8028ed4: e7fe b.n 8028ed4 xHandle = xQueueGenericCreate( uxMaxCount, queueSEMAPHORE_QUEUE_ITEM_LENGTH, queueQUEUE_TYPE_COUNTING_SEMAPHORE ); 8028ed6: 2100 movs r1, #0 8028ed8: 2202 movs r2, #2 8028eda: f7ff ffca bl 8028e72 if( xHandle != NULL ) 8028ede: b110 cbz r0, 8028ee6 { ( ( Queue_t * ) xHandle )->uxMessagesWaiting = uxInitialCount; 8028ee0: 6384 str r4, [r0, #56] ; 0x38 8028ee2: bd10 pop {r4, pc} 8028ee4: e7fe b.n 8028ee4 else { traceCREATE_COUNTING_SEMAPHORE_FAILED(); } configASSERT( xHandle ); 8028ee6: f001 f8a7 bl 802a038 8028eea: e7fb b.n 8028ee4 08028eec : #endif /* configUSE_COUNTING_SEMAPHORES */ /*-----------------------------------------------------------*/ BaseType_t xQueueGenericSend( QueueHandle_t xQueue, const void * const pvItemToQueue, TickType_t xTicksToWait, const BaseType_t xCopyPosition ) { 8028eec: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} 8028ef0: b085 sub sp, #20 8028ef2: 460f mov r7, r1 8028ef4: 9201 str r2, [sp, #4] 8028ef6: 461d mov r5, r3 BaseType_t xEntryTimeSet = pdFALSE, xYieldRequired; TimeOut_t xTimeOut; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 8028ef8: 4604 mov r4, r0 8028efa: b910 cbnz r0, 8028f02 8028efc: f001 f89c bl 802a038 8028f00: e7fe b.n 8028f00 configASSERT( !( ( pvItemToQueue == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 8028f02: 2900 cmp r1, #0 8028f04: d17b bne.n 8028ffe 8028f06: 6c03 ldr r3, [r0, #64] ; 0x40 8028f08: 2b00 cmp r3, #0 8028f0a: d078 beq.n 8028ffe 8028f0c: e074 b.n 8028ff8 8028f0e: e7fe b.n 8028f0e configASSERT( !( ( xCopyPosition == queueOVERWRITE ) && ( pxQueue->uxLength != 1 ) ) ); 8028f10: 6be3 ldr r3, [r4, #60] ; 0x3c 8028f12: 2b01 cmp r3, #1 8028f14: d176 bne.n 8029004 8028f16: e078 b.n 802900a 8028f18: e7fe b.n 8028f18 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) { configASSERT( !( ( xTaskGetSchedulerState() == taskSCHEDULER_SUSPENDED ) && ( xTicksToWait != 0 ) ) ); 8028f1a: 9e01 ldr r6, [sp, #4] 8028f1c: b126 cbz r6, 8028f28 8028f1e: e079 b.n 8029014 8028f20: e7fe b.n 8028f20 8028f22: 2601 movs r6, #1 8028f24: e002 b.n 8028f2c 8028f26: 2600 movs r6, #0 /* Interrupts and other tasks can send to and receive from the queue now the critical section has been exited. */ vTaskSuspendAll(); prvLockQueue( pxQueue ); 8028f28: f04f 0800 mov.w r8, #0 /* This function relaxes the coding standard somewhat to allow return statements within the function itself. This is done in the interest of execution time efficiency. */ for( ;; ) { taskENTER_CRITICAL(); 8028f2c: f001 f88c bl 802a048 { /* Is there room on the queue now? The running task must be the highest priority task wanting to access the queue. If the head item in the queue is to be overwritten then it does not matter if the queue is full. */ if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) 8028f30: 6ba2 ldr r2, [r4, #56] ; 0x38 8028f32: 6be3 ldr r3, [r4, #60] ; 0x3c 8028f34: 429a cmp r2, r3 8028f36: d301 bcc.n 8028f3c 8028f38: 2d02 cmp r5, #2 8028f3a: d115 bne.n 8028f68 { traceQUEUE_SEND( pxQueue ); xYieldRequired = prvCopyDataToQueue( pxQueue, pvItemToQueue, xCopyPosition ); 8028f3c: 4620 mov r0, r4 8028f3e: 4639 mov r1, r7 8028f40: 462a mov r2, r5 8028f42: f7ff ff2e bl 8028da2 } #else /* configUSE_QUEUE_SETS */ { /* If there was a task waiting for data to arrive on the queue then unblock it now. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 8028f46: 6a63 ldr r3, [r4, #36] ; 0x24 8028f48: b143 cbz r3, 8028f5c { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) == pdTRUE ) 8028f4a: f104 0024 add.w r0, r4, #36 ; 0x24 8028f4e: f000 fd6f bl 8029a30 8028f52: 2801 cmp r0, #1 8028f54: d104 bne.n 8028f60 { /* The unblocked task has a priority higher than our own so yield immediately. Yes it is ok to do this from within the critical section - the kernel takes care of that. */ queueYIELD_IF_USING_PREEMPTION(); 8028f56: f001 f863 bl 802a020 8028f5a: e001 b.n 8028f60 else { mtCOVERAGE_TEST_MARKER(); } } else if( xYieldRequired != pdFALSE ) 8028f5c: 2800 cmp r0, #0 8028f5e: d1fa bne.n 8028f56 mtCOVERAGE_TEST_MARKER(); } } #endif /* configUSE_QUEUE_SETS */ taskEXIT_CRITICAL(); 8028f60: f001 f89e bl 802a0a0 return pdPASS; 8028f64: 2001 movs r0, #1 8028f66: e058 b.n 802901a } else { if( xTicksToWait == ( TickType_t ) 0 ) 8028f68: f8dd 9004 ldr.w r9, [sp, #4] 8028f6c: f1b9 0f00 cmp.w r9, #0 8028f70: d102 bne.n 8028f78 { /* The queue was full and no block time is specified (or the block time has expired) so leave now. */ taskEXIT_CRITICAL(); 8028f72: f001 f895 bl 802a0a0 8028f76: e03d b.n 8028ff4 /* Return to the original privilege level before exiting the function. */ traceQUEUE_SEND_FAILED( pxQueue ); return errQUEUE_FULL; } else if( xEntryTimeSet == pdFALSE ) 8028f78: b916 cbnz r6, 8028f80 { /* The queue was full and a block time was specified so configure the timeout structure. */ vTaskSetTimeOutState( &xTimeOut ); 8028f7a: a802 add r0, sp, #8 8028f7c: f000 fd94 bl 8029aa8 /* Entry time was already set. */ mtCOVERAGE_TEST_MARKER(); } } } taskEXIT_CRITICAL(); 8028f80: f001 f88e bl 802a0a0 /* Interrupts and other tasks can send to and receive from the queue now the critical section has been exited. */ vTaskSuspendAll(); 8028f84: f000 fb5c bl 8029640 prvLockQueue( pxQueue ); 8028f88: f001 f85e bl 802a048 8028f8c: 6c63 ldr r3, [r4, #68] ; 0x44 8028f8e: 3301 adds r3, #1 8028f90: bf08 it eq 8028f92: f8c4 8044 streq.w r8, [r4, #68] ; 0x44 8028f96: 6ca3 ldr r3, [r4, #72] ; 0x48 8028f98: 3301 adds r3, #1 8028f9a: bf08 it eq 8028f9c: f8c4 8048 streq.w r8, [r4, #72] ; 0x48 8028fa0: f001 f87e bl 802a0a0 /* Update the timeout state to see if it has expired yet. */ if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) 8028fa4: a802 add r0, sp, #8 8028fa6: a901 add r1, sp, #4 8028fa8: f000 fd8e bl 8029ac8 8028fac: b9e8 cbnz r0, 8028fea static BaseType_t prvIsQueueFull( const Queue_t *pxQueue ) { BaseType_t xReturn; taskENTER_CRITICAL(); 8028fae: f001 f84b bl 802a048 { if( pxQueue->uxMessagesWaiting == pxQueue->uxLength ) 8028fb2: f8d4 9038 ldr.w r9, [r4, #56] ; 0x38 8028fb6: 6be6 ldr r6, [r4, #60] ; 0x3c else { xReturn = pdFALSE; } } taskEXIT_CRITICAL(); 8028fb8: f001 f872 bl 802a0a0 prvLockQueue( pxQueue ); /* Update the timeout state to see if it has expired yet. */ if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) { if( prvIsQueueFull( pxQueue ) != pdFALSE ) 8028fbc: 45b1 cmp r9, r6 8028fbe: d10e bne.n 8028fde { traceBLOCKING_ON_QUEUE_SEND( pxQueue ); vTaskPlaceOnEventList( &( pxQueue->xTasksWaitingToSend ), xTicksToWait ); 8028fc0: f104 0010 add.w r0, r4, #16 8028fc4: 9901 ldr r1, [sp, #4] 8028fc6: f000 fcd7 bl 8029978 /* Unlocking the queue means queue events can effect the event list. It is possible that interrupts occurring now remove this task from the event list again - but as the scheduler is suspended the task will go onto the pending ready last instead of the actual ready list. */ prvUnlockQueue( pxQueue ); 8028fca: 4620 mov r0, r4 8028fcc: f7ff fea2 bl 8028d14 /* Resuming the scheduler will move tasks from the pending ready list into the ready list - so it is feasible that this task is already in a ready list before it yields - in which case the yield will not cause a context switch unless there is also a higher priority task in the pending ready list. */ if( xTaskResumeAll() == pdFALSE ) 8028fd0: f000 fbd2 bl 8029778 8028fd4: 2800 cmp r0, #0 8028fd6: d1a4 bne.n 8028f22 { portYIELD_WITHIN_API(); 8028fd8: f001 f822 bl 802a020 8028fdc: e7a1 b.n 8028f22 } } else { /* Try again. */ prvUnlockQueue( pxQueue ); 8028fde: 4620 mov r0, r4 8028fe0: f7ff fe98 bl 8028d14 ( void ) xTaskResumeAll(); 8028fe4: f000 fbc8 bl 8029778 8028fe8: e79b b.n 8028f22 } } else { /* The timeout has expired. */ prvUnlockQueue( pxQueue ); 8028fea: 4620 mov r0, r4 8028fec: f7ff fe92 bl 8028d14 ( void ) xTaskResumeAll(); 8028ff0: f000 fbc2 bl 8029778 /* Return to the original privilege level before exiting the function. */ traceQUEUE_SEND_FAILED( pxQueue ); return errQUEUE_FULL; 8028ff4: 2000 movs r0, #0 8028ff6: e010 b.n 802901a BaseType_t xEntryTimeSet = pdFALSE, xYieldRequired; TimeOut_t xTimeOut; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); configASSERT( !( ( pvItemToQueue == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 8028ff8: f001 f81e bl 802a038 8028ffc: e787 b.n 8028f0e configASSERT( !( ( xCopyPosition == queueOVERWRITE ) && ( pxQueue->uxLength != 1 ) ) ); 8028ffe: 2d02 cmp r5, #2 8029000: d103 bne.n 802900a 8029002: e785 b.n 8028f10 8029004: f001 f818 bl 802a038 8029008: e786 b.n 8028f18 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) { configASSERT( !( ( xTaskGetSchedulerState() == taskSCHEDULER_SUSPENDED ) && ( xTicksToWait != 0 ) ) ); 802900a: f000 fd91 bl 8029b30 802900e: 2800 cmp r0, #0 8029010: d189 bne.n 8028f26 8029012: e782 b.n 8028f1a 8029014: f001 f810 bl 802a038 8029018: e782 b.n 8028f20 function. */ traceQUEUE_SEND_FAILED( pxQueue ); return errQUEUE_FULL; } } } 802901a: b005 add sp, #20 802901c: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 08029020 : /*-----------------------------------------------------------*/ #if ( configUSE_MUTEXES == 1 ) QueueHandle_t xQueueCreateMutex( const uint8_t ucQueueType ) { 8029020: b570 push {r4, r5, r6, lr} 8029022: 4606 mov r6, r0 /* Prevent compiler warnings about unused parameters if configUSE_TRACE_FACILITY does not equal 1. */ ( void ) ucQueueType; /* Allocate the new queue structure. */ pxNewQueue = ( Queue_t * ) pvPortMalloc( sizeof( Queue_t ) ); 8029024: 2054 movs r0, #84 ; 0x54 8029026: f001 f91d bl 802a264 if( pxNewQueue != NULL ) 802902a: 4604 mov r4, r0 802902c: b108 cbz r0, 8029032 802902e: e003 b.n 8029038 8029030: e7fe b.n 8029030 else { traceCREATE_MUTEX_FAILED(); } configASSERT( pxNewQueue ); 8029032: f001 f801 bl 802a038 8029036: e7fb b.n 8029030 /* Each mutex has a length of 1 (like a binary semaphore) and an item size of 0 as nothing is actually copied into or out of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxNewQueue->uxLength = ( UBaseType_t ) 1U; 8029038: 2301 movs r3, #1 /* Allocate the new queue structure. */ pxNewQueue = ( Queue_t * ) pvPortMalloc( sizeof( Queue_t ) ); if( pxNewQueue != NULL ) { /* Information required for priority inheritance. */ pxNewQueue->pxMutexHolder = NULL; 802903a: 2500 movs r5, #0 /* Each mutex has a length of 1 (like a binary semaphore) and an item size of 0 as nothing is actually copied into or out of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxNewQueue->uxLength = ( UBaseType_t ) 1U; 802903c: 63c3 str r3, [r0, #60] ; 0x3c pxNewQueue->uxItemSize = ( UBaseType_t ) 0U; pxNewQueue->xRxLock = queueUNLOCKED; 802903e: f04f 33ff mov.w r3, #4294967295 pxNewQueue->u.pcReadFrom = NULL; /* Each mutex has a length of 1 (like a binary semaphore) and an item size of 0 as nothing is actually copied into or out of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; 8029042: 6385 str r5, [r0, #56] ; 0x38 /* Allocate the new queue structure. */ pxNewQueue = ( Queue_t * ) pvPortMalloc( sizeof( Queue_t ) ); if( pxNewQueue != NULL ) { /* Information required for priority inheritance. */ pxNewQueue->pxMutexHolder = NULL; 8029044: 6045 str r5, [r0, #4] an item size of 0 as nothing is actually copied into or out of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxNewQueue->uxLength = ( UBaseType_t ) 1U; pxNewQueue->uxItemSize = ( UBaseType_t ) 0U; pxNewQueue->xRxLock = queueUNLOCKED; 8029046: 6443 str r3, [r0, #68] ; 0x44 pxNewQueue = ( Queue_t * ) pvPortMalloc( sizeof( Queue_t ) ); if( pxNewQueue != NULL ) { /* Information required for priority inheritance. */ pxNewQueue->pxMutexHolder = NULL; pxNewQueue->uxQueueType = queueQUEUE_IS_MUTEX; 8029048: 6005 str r5, [r0, #0] of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxNewQueue->uxLength = ( UBaseType_t ) 1U; pxNewQueue->uxItemSize = ( UBaseType_t ) 0U; pxNewQueue->xRxLock = queueUNLOCKED; pxNewQueue->xTxLock = queueUNLOCKED; 802904a: 6483 str r3, [r0, #72] ; 0x48 pxNewQueue->pxMutexHolder = NULL; pxNewQueue->uxQueueType = queueQUEUE_IS_MUTEX; /* Queues used as a mutex no data is actually copied into or out of the queue. */ pxNewQueue->pcWriteTo = NULL; 802904c: 6085 str r5, [r0, #8] pxNewQueue->u.pcReadFrom = NULL; 802904e: 60c5 str r5, [r0, #12] /* Each mutex has a length of 1 (like a binary semaphore) and an item size of 0 as nothing is actually copied into or out of the mutex. */ pxNewQueue->uxMessagesWaiting = ( UBaseType_t ) 0U; pxNewQueue->uxLength = ( UBaseType_t ) 1U; pxNewQueue->uxItemSize = ( UBaseType_t ) 0U; 8029050: 6405 str r5, [r0, #64] ; 0x40 pxNewQueue->xRxLock = queueUNLOCKED; pxNewQueue->xTxLock = queueUNLOCKED; #if ( configUSE_TRACE_FACILITY == 1 ) { pxNewQueue->ucQueueType = ucQueueType; 8029052: f880 6050 strb.w r6, [r0, #80] ; 0x50 pxNewQueue->pxQueueSetContainer = NULL; } #endif /* Ensure the event queues start with the correct state. */ vListInitialise( &( pxNewQueue->xTasksWaitingToSend ) ); 8029056: 3010 adds r0, #16 8029058: f7ff fe1a bl 8028c90 vListInitialise( &( pxNewQueue->xTasksWaitingToReceive ) ); 802905c: f104 0024 add.w r0, r4, #36 ; 0x24 8029060: f7ff fe16 bl 8028c90 traceCREATE_MUTEX( pxNewQueue ); /* Start with the semaphore in the expected state. */ ( void ) xQueueGenericSend( pxNewQueue, NULL, ( TickType_t ) 0U, queueSEND_TO_BACK ); 8029064: 4620 mov r0, r4 8029066: 4629 mov r1, r5 8029068: 462a mov r2, r5 802906a: 462b mov r3, r5 802906c: f7ff ff3e bl 8028eec traceCREATE_MUTEX_FAILED(); } configASSERT( pxNewQueue ); return pxNewQueue; } 8029070: 4620 mov r0, r4 8029072: bd70 pop {r4, r5, r6, pc} 08029074 : #endif /* configUSE_ALTERNATIVE_API */ /*-----------------------------------------------------------*/ BaseType_t xQueueGenericSendFromISR( QueueHandle_t xQueue, const void * const pvItemToQueue, BaseType_t * const pxHigherPriorityTaskWoken, const BaseType_t xCopyPosition ) { 8029074: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8029078: 460f mov r7, r1 802907a: 4616 mov r6, r2 802907c: 461d mov r5, r3 BaseType_t xReturn; UBaseType_t uxSavedInterruptStatus; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 802907e: 4604 mov r4, r0 8029080: b910 cbnz r0, 8029088 8029082: f000 ffd9 bl 802a038 8029086: e7fe b.n 8029086 configASSERT( !( ( pvItemToQueue == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 8029088: bb41 cbnz r1, 80290dc 802908a: 6c03 ldr r3, [r0, #64] ; 0x40 802908c: b333 cbz r3, 80290dc 802908e: e022 b.n 80290d6 8029090: e7fe b.n 8029090 configASSERT( !( ( xCopyPosition == queueOVERWRITE ) && ( pxQueue->uxLength != 1 ) ) ); 8029092: 6be3 ldr r3, [r4, #60] ; 0x3c 8029094: 2b01 cmp r3, #1 8029096: d124 bne.n 80290e2 8029098: e026 b.n 80290e8 802909a: e7fe b.n 802909a read, instead return a flag to say whether a context switch is required or not (i.e. has a task with a higher priority than us been woken by this post). */ uxSavedInterruptStatus = portSET_INTERRUPT_MASK_FROM_ISR(); { if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) 802909c: 2d02 cmp r5, #2 802909e: d118 bne.n 80290d2 /* A task can only have an inherited priority if it is a mutex holder - and if there is a mutex holder then the mutex cannot be given from an ISR. Therefore, unlike the xQueueGenericGive() function, there is no need to determine the need for priority disinheritance here or to clear the mutex holder TCB member. */ ( void ) prvCopyDataToQueue( pxQueue, pvItemToQueue, xCopyPosition ); 80290a0: 4620 mov r0, r4 80290a2: 4639 mov r1, r7 80290a4: 462a mov r2, r5 80290a6: f7ff fe7c bl 8028da2 /* The event list is not altered if the queue is locked. This will be done when the queue is unlocked later. */ if( pxQueue->xTxLock == queueUNLOCKED ) 80290aa: 6ca3 ldr r3, [r4, #72] ; 0x48 80290ac: 3301 adds r3, #1 80290ae: d10b bne.n 80290c8 } } } #else /* configUSE_QUEUE_SETS */ { if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 80290b0: 6a63 ldr r3, [r4, #36] ; 0x24 80290b2: b903 cbnz r3, 80290b6 80290b4: e00b b.n 80290ce { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) 80290b6: f104 0024 add.w r0, r4, #36 ; 0x24 80290ba: f000 fcb9 bl 8029a30 80290be: b130 cbz r0, 80290ce { /* The task waiting has a higher priority so record that a context switch is required. */ if( pxHigherPriorityTaskWoken != NULL ) 80290c0: b12e cbz r6, 80290ce { *pxHigherPriorityTaskWoken = pdTRUE; 80290c2: 2401 movs r4, #1 80290c4: 6034 str r4, [r6, #0] 80290c6: e019 b.n 80290fc } else { /* Increment the lock count so the task that unlocks the queue knows that data was posted while it was locked. */ ++( pxQueue->xTxLock ); 80290c8: 6ca3 ldr r3, [r4, #72] ; 0x48 80290ca: 3301 adds r3, #1 80290cc: 64a3 str r3, [r4, #72] ; 0x48 } xReturn = pdPASS; 80290ce: 2401 movs r4, #1 80290d0: e014 b.n 80290fc } else { traceQUEUE_SEND_FROM_ISR_FAILED( pxQueue ); xReturn = errQUEUE_FULL; 80290d2: 2400 movs r4, #0 80290d4: e012 b.n 80290fc BaseType_t xReturn; UBaseType_t uxSavedInterruptStatus; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); configASSERT( !( ( pvItemToQueue == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 80290d6: f000 ffaf bl 802a038 80290da: e7d9 b.n 8029090 configASSERT( !( ( xCopyPosition == queueOVERWRITE ) && ( pxQueue->uxLength != 1 ) ) ); 80290dc: 2d02 cmp r5, #2 80290de: d103 bne.n 80290e8 80290e0: e7d7 b.n 8029092 80290e2: f000 ffa9 bl 802a038 80290e6: e7d8 b.n 802909a that have been assigned a priority at or (logically) below the maximum system call interrupt priority. FreeRTOS maintains a separate interrupt safe API to ensure interrupt entry is as fast and as simple as possible. More information (albeit Cortex-M specific) is provided on the following link: http://www.freertos.org/RTOS-Cortex-M3-M4.html */ portASSERT_IF_INTERRUPT_PRIORITY_INVALID(); 80290e8: f001 f876 bl 802a1d8 /* Similar to xQueueGenericSend, except without blocking if there is no room in the queue. Also don't directly wake a task that was blocked on a queue read, instead return a flag to say whether a context switch is required or not (i.e. has a task with a higher priority than us been woken by this post). */ uxSavedInterruptStatus = portSET_INTERRUPT_MASK_FROM_ISR(); 80290ec: f000 ffa4 bl 802a038 { if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) 80290f0: 6ba2 ldr r2, [r4, #56] ; 0x38 80290f2: 6be3 ldr r3, [r4, #60] ; 0x3c 80290f4: 429a cmp r2, r3 /* Similar to xQueueGenericSend, except without blocking if there is no room in the queue. Also don't directly wake a task that was blocked on a queue read, instead return a flag to say whether a context switch is required or not (i.e. has a task with a higher priority than us been woken by this post). */ uxSavedInterruptStatus = portSET_INTERRUPT_MASK_FROM_ISR(); 80290f6: 4680 mov r8, r0 { if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) 80290f8: d2d0 bcs.n 802909c 80290fa: e7d1 b.n 80290a0 { traceQUEUE_SEND_FROM_ISR_FAILED( pxQueue ); xReturn = errQUEUE_FULL; } } portCLEAR_INTERRUPT_MASK_FROM_ISR( uxSavedInterruptStatus ); 80290fc: 4640 mov r0, r8 80290fe: f000 ffcb bl 802a098 return xReturn; } 8029102: 4620 mov r0, r4 8029104: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 08029108 : /*-----------------------------------------------------------*/ BaseType_t xQueueGiveFromISR( QueueHandle_t xQueue, BaseType_t * const pxHigherPriorityTaskWoken ) { 8029108: b5f8 push {r3, r4, r5, r6, r7, lr} 802910a: 460d mov r5, r1 BaseType_t xReturn; UBaseType_t uxSavedInterruptStatus; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 802910c: 4604 mov r4, r0 802910e: b910 cbnz r0, 8029116 8029110: f000 ff92 bl 802a038 8029114: e7fe b.n 8029114 /* xQueueGenericSendFromISR() should be used in the item size is not 0. */ configASSERT( pxQueue->uxItemSize == 0 ); 8029116: 6c06 ldr r6, [r0, #64] ; 0x40 8029118: b116 cbz r6, 8029120 802911a: f000 ff8d bl 802a038 802911e: e7fe b.n 802911e that have been assigned a priority at or (logically) below the maximum system call interrupt priority. FreeRTOS maintains a separate interrupt safe API to ensure interrupt entry is as fast and as simple as possible. More information (albeit Cortex-M specific) is provided on the following link: http://www.freertos.org/RTOS-Cortex-M3-M4.html */ portASSERT_IF_INTERRUPT_PRIORITY_INVALID(); 8029120: f001 f85a bl 802a1d8 /* Similar to xQueueGenericSendFromISR() but used with semaphores where the item size is 0. Don't directly wake a task that was blocked on a queue read, instead return a flag to say whether a context switch is required or not (i.e. has a task with a higher priority than us been woken by this post). */ uxSavedInterruptStatus = portSET_INTERRUPT_MASK_FROM_ISR(); 8029124: f000 ff88 bl 802a038 { /* When the queue is used to implement a semaphore no data is ever moved through the queue but it is still valid to see if the queue 'has space'. */ if( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) 8029128: 6ba2 ldr r2, [r4, #56] ; 0x38 802912a: 6be3 ldr r3, [r4, #60] ; 0x3c 802912c: 429a cmp r2, r3 /* Similar to xQueueGenericSendFromISR() but used with semaphores where the item size is 0. Don't directly wake a task that was blocked on a queue read, instead return a flag to say whether a context switch is required or not (i.e. has a task with a higher priority than us been woken by this post). */ uxSavedInterruptStatus = portSET_INTERRUPT_MASK_FROM_ISR(); 802912e: 4607 mov r7, r0 { /* When the queue is used to implement a semaphore no data is ever moved through the queue but it is still valid to see if the queue 'has space'. */ if( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) 8029130: d216 bcs.n 8029160 holder - and if there is a mutex holder then the mutex cannot be given from an ISR. Therefore, unlike the xQueueGenericGive() function, there is no need to determine the need for priority disinheritance here or to clear the mutex holder TCB member. */ ++( pxQueue->uxMessagesWaiting ); 8029132: 6ba3 ldr r3, [r4, #56] ; 0x38 8029134: 3301 adds r3, #1 8029136: 63a3 str r3, [r4, #56] ; 0x38 /* The event list is not altered if the queue is locked. This will be done when the queue is unlocked later. */ if( pxQueue->xTxLock == queueUNLOCKED ) 8029138: 6ca3 ldr r3, [r4, #72] ; 0x48 802913a: 3301 adds r3, #1 802913c: d10b bne.n 8029156 } } } #else /* configUSE_QUEUE_SETS */ { if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 802913e: 6a63 ldr r3, [r4, #36] ; 0x24 8029140: b903 cbnz r3, 8029144 8029142: e00b b.n 802915c { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) 8029144: f104 0024 add.w r0, r4, #36 ; 0x24 8029148: f000 fc72 bl 8029a30 802914c: b130 cbz r0, 802915c { /* The task waiting has a higher priority so record that a context switch is required. */ if( pxHigherPriorityTaskWoken != NULL ) 802914e: b12d cbz r5, 802915c { *pxHigherPriorityTaskWoken = pdTRUE; 8029150: 2401 movs r4, #1 8029152: 602c str r4, [r5, #0] 8029154: e005 b.n 8029162 } else { /* Increment the lock count so the task that unlocks the queue knows that data was posted while it was locked. */ ++( pxQueue->xTxLock ); 8029156: 6ca3 ldr r3, [r4, #72] ; 0x48 8029158: 3301 adds r3, #1 802915a: 64a3 str r3, [r4, #72] ; 0x48 } xReturn = pdPASS; 802915c: 2401 movs r4, #1 802915e: e000 b.n 8029162 } else { traceQUEUE_SEND_FROM_ISR_FAILED( pxQueue ); xReturn = errQUEUE_FULL; 8029160: 4634 mov r4, r6 } } portCLEAR_INTERRUPT_MASK_FROM_ISR( uxSavedInterruptStatus ); 8029162: 4638 mov r0, r7 8029164: f000 ff98 bl 802a098 return xReturn; } 8029168: 4620 mov r0, r4 802916a: bdf8 pop {r3, r4, r5, r6, r7, pc} 0802916c : /*-----------------------------------------------------------*/ BaseType_t xQueueGenericReceive( QueueHandle_t xQueue, void * const pvBuffer, TickType_t xTicksToWait, const BaseType_t xJustPeeking ) { 802916c: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} 8029170: b085 sub sp, #20 8029172: 460e mov r6, r1 8029174: 9201 str r2, [sp, #4] 8029176: 4699 mov r9, r3 BaseType_t xEntryTimeSet = pdFALSE; TimeOut_t xTimeOut; int8_t *pcOriginalReadPosition; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 8029178: 4604 mov r4, r0 802917a: b910 cbnz r0, 8029182 802917c: f000 ff5c bl 802a038 8029180: e7fe b.n 8029180 configASSERT( !( ( pvBuffer == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 8029182: 2900 cmp r1, #0 8029184: f040 8089 bne.w 802929a 8029188: 6c03 ldr r3, [r0, #64] ; 0x40 802918a: 2b00 cmp r3, #0 802918c: f000 8085 beq.w 802929a 8029190: e080 b.n 8029294 8029192: e7fe b.n 8029192 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) { configASSERT( !( ( xTaskGetSchedulerState() == taskSCHEDULER_SUSPENDED ) && ( xTicksToWait != 0 ) ) ); 8029194: 9d01 ldr r5, [sp, #4] 8029196: b125 cbz r5, 80291a2 8029198: e085 b.n 80292a6 802919a: e7fe b.n 802919a 802919c: 2501 movs r5, #1 802919e: e001 b.n 80291a4 80291a0: 2500 movs r5, #0 /* Interrupts and other tasks can send to and receive from the queue now the critical section has been exited. */ vTaskSuspendAll(); prvLockQueue( pxQueue ); 80291a2: 2700 movs r7, #0 statements within the function itself. This is done in the interest of execution time efficiency. */ for( ;; ) { taskENTER_CRITICAL(); 80291a4: f000 ff50 bl 802a048 { /* Is there data in the queue now? To be running the calling task must be the highest priority task wanting to access the queue. */ if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) 80291a8: 6ba3 ldr r3, [r4, #56] ; 0x38 80291aa: b33b cbz r3, 80291fc { /* Remember the read position in case the queue is only being peeked. */ pcOriginalReadPosition = pxQueue->u.pcReadFrom; prvCopyDataFromQueue( pxQueue, pvBuffer ); 80291ac: 4620 mov r0, r4 80291ae: 4631 mov r1, r6 must be the highest priority task wanting to access the queue. */ if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) { /* Remember the read position in case the queue is only being peeked. */ pcOriginalReadPosition = pxQueue->u.pcReadFrom; 80291b0: 68e5 ldr r5, [r4, #12] prvCopyDataFromQueue( pxQueue, pvBuffer ); 80291b2: f7ff fde3 bl 8028d7c if( xJustPeeking == pdFALSE ) 80291b6: f1b9 0f00 cmp.w r9, #0 80291ba: d112 bne.n 80291e2 { traceQUEUE_RECEIVE( pxQueue ); /* Actually removing data, not just peeking. */ --( pxQueue->uxMessagesWaiting ); 80291bc: 6ba3 ldr r3, [r4, #56] ; 0x38 80291be: 3b01 subs r3, #1 80291c0: 63a3 str r3, [r4, #56] ; 0x38 #if ( configUSE_MUTEXES == 1 ) { if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) 80291c2: 6823 ldr r3, [r4, #0] 80291c4: b913 cbnz r3, 80291cc { /* Record the information required to implement priority inheritance should it become necessary. */ pxQueue->pxMutexHolder = ( int8_t * ) pvTaskIncrementMutexHeldCount(); /*lint !e961 Cast is not redundant as TaskHandle_t is a typedef. */ 80291c6: f000 fd4d bl 8029c64 80291ca: 6060 str r0, [r4, #4] mtCOVERAGE_TEST_MARKER(); } } #endif /* configUSE_MUTEXES */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) 80291cc: 6923 ldr r3, [r4, #16] 80291ce: b18b cbz r3, 80291f4 { if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) == pdTRUE ) 80291d0: f104 0010 add.w r0, r4, #16 80291d4: f000 fc2c bl 8029a30 80291d8: 2801 cmp r0, #1 80291da: d10b bne.n 80291f4 { queueYIELD_IF_USING_PREEMPTION(); 80291dc: f000 ff20 bl 802a020 80291e0: e008 b.n 80291f4 pointer. */ pxQueue->u.pcReadFrom = pcOriginalReadPosition; /* The data is being left in the queue, so see if there are any other tasks waiting for the data. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 80291e2: 6a63 ldr r3, [r4, #36] ; 0x24 { traceQUEUE_PEEK( pxQueue ); /* The data is not being removed, so reset the read pointer. */ pxQueue->u.pcReadFrom = pcOriginalReadPosition; 80291e4: 60e5 str r5, [r4, #12] /* The data is being left in the queue, so see if there are any other tasks waiting for the data. */ if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) 80291e6: b12b cbz r3, 80291f4 { /* Tasks that are removed from the event list will get added to the pending ready list as the scheduler is still suspended. */ if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) 80291e8: f104 0024 add.w r0, r4, #36 ; 0x24 80291ec: f000 fc20 bl 8029a30 80291f0: 2800 cmp r0, #0 80291f2: d1f3 bne.n 80291dc { mtCOVERAGE_TEST_MARKER(); } } taskEXIT_CRITICAL(); 80291f4: f000 ff54 bl 802a0a0 return pdPASS; 80291f8: 2001 movs r0, #1 80291fa: e057 b.n 80292ac } else { if( xTicksToWait == ( TickType_t ) 0 ) 80291fc: f8dd 8004 ldr.w r8, [sp, #4] 8029200: f1b8 0f00 cmp.w r8, #0 8029204: d102 bne.n 802920c { /* The queue was empty and no block time is specified (or the block time has expired) so leave now. */ taskEXIT_CRITICAL(); 8029206: f000 ff4b bl 802a0a0 802920a: e041 b.n 8029290 traceQUEUE_RECEIVE_FAILED( pxQueue ); return errQUEUE_EMPTY; } else if( xEntryTimeSet == pdFALSE ) 802920c: b915 cbnz r5, 8029214 { /* The queue was empty and a block time was specified so configure the timeout structure. */ vTaskSetTimeOutState( &xTimeOut ); 802920e: a802 add r0, sp, #8 8029210: f000 fc4a bl 8029aa8 /* Entry time was already set. */ mtCOVERAGE_TEST_MARKER(); } } } taskEXIT_CRITICAL(); 8029214: f000 ff44 bl 802a0a0 /* Interrupts and other tasks can send to and receive from the queue now the critical section has been exited. */ vTaskSuspendAll(); 8029218: f000 fa12 bl 8029640 prvLockQueue( pxQueue ); 802921c: f000 ff14 bl 802a048 8029220: 6c63 ldr r3, [r4, #68] ; 0x44 8029222: 3301 adds r3, #1 8029224: bf08 it eq 8029226: 6467 streq r7, [r4, #68] ; 0x44 8029228: 6ca3 ldr r3, [r4, #72] ; 0x48 802922a: 3301 adds r3, #1 802922c: bf08 it eq 802922e: 64a7 streq r7, [r4, #72] ; 0x48 8029230: f000 ff36 bl 802a0a0 /* Update the timeout state to see if it has expired yet. */ if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) 8029234: a802 add r0, sp, #8 8029236: a901 add r1, sp, #4 8029238: f000 fc46 bl 8029ac8 802923c: bb18 cbnz r0, 8029286 static BaseType_t prvIsQueueEmpty( const Queue_t *pxQueue ) { BaseType_t xReturn; taskENTER_CRITICAL(); 802923e: f000 ff03 bl 802a048 { if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0 ) 8029242: 6ba5 ldr r5, [r4, #56] ; 0x38 else { xReturn = pdFALSE; } } taskEXIT_CRITICAL(); 8029244: f000 ff2c bl 802a0a0 prvLockQueue( pxQueue ); /* Update the timeout state to see if it has expired yet. */ if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) { if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) 8029248: b9bd cbnz r5, 802927a { traceBLOCKING_ON_QUEUE_RECEIVE( pxQueue ); #if ( configUSE_MUTEXES == 1 ) { if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) 802924a: 6823 ldr r3, [r4, #0] 802924c: b933 cbnz r3, 802925c { taskENTER_CRITICAL(); 802924e: f000 fefb bl 802a048 { vTaskPriorityInherit( ( void * ) pxQueue->pxMutexHolder ); 8029252: 6860 ldr r0, [r4, #4] 8029254: f000 fc7c bl 8029b50 } taskEXIT_CRITICAL(); 8029258: f000 ff22 bl 802a0a0 mtCOVERAGE_TEST_MARKER(); } } #endif vTaskPlaceOnEventList( &( pxQueue->xTasksWaitingToReceive ), xTicksToWait ); 802925c: f104 0024 add.w r0, r4, #36 ; 0x24 8029260: 9901 ldr r1, [sp, #4] 8029262: f000 fb89 bl 8029978 prvUnlockQueue( pxQueue ); 8029266: 4620 mov r0, r4 8029268: f7ff fd54 bl 8028d14 if( xTaskResumeAll() == pdFALSE ) 802926c: f000 fa84 bl 8029778 8029270: 2800 cmp r0, #0 8029272: d193 bne.n 802919c { portYIELD_WITHIN_API(); 8029274: f000 fed4 bl 802a020 8029278: e790 b.n 802919c } } else { /* Try again. */ prvUnlockQueue( pxQueue ); 802927a: 4620 mov r0, r4 802927c: f7ff fd4a bl 8028d14 ( void ) xTaskResumeAll(); 8029280: f000 fa7a bl 8029778 8029284: e78a b.n 802919c } } else { prvUnlockQueue( pxQueue ); 8029286: 4620 mov r0, r4 8029288: f7ff fd44 bl 8028d14 ( void ) xTaskResumeAll(); 802928c: f000 fa74 bl 8029778 traceQUEUE_RECEIVE_FAILED( pxQueue ); return errQUEUE_EMPTY; 8029290: 2000 movs r0, #0 8029292: e00b b.n 80292ac TimeOut_t xTimeOut; int8_t *pcOriginalReadPosition; Queue_t * const pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); configASSERT( !( ( pvBuffer == NULL ) && ( pxQueue->uxItemSize != ( UBaseType_t ) 0U ) ) ); 8029294: f000 fed0 bl 802a038 8029298: e77b b.n 8029192 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) { configASSERT( !( ( xTaskGetSchedulerState() == taskSCHEDULER_SUSPENDED ) && ( xTicksToWait != 0 ) ) ); 802929a: f000 fc49 bl 8029b30 802929e: 2800 cmp r0, #0 80292a0: f47f af7e bne.w 80291a0 80292a4: e776 b.n 8029194 80292a6: f000 fec7 bl 802a038 80292aa: e776 b.n 802919a ( void ) xTaskResumeAll(); traceQUEUE_RECEIVE_FAILED( pxQueue ); return errQUEUE_EMPTY; } } } 80292ac: b005 add sp, #20 80292ae: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 080292b2 : return uxReturn; } /*lint !e818 Pointer cannot be declared const as xQueue is a typedef not pointer. */ /*-----------------------------------------------------------*/ UBaseType_t uxQueueSpacesAvailable( const QueueHandle_t xQueue ) { 80292b2: b510 push {r4, lr} UBaseType_t uxReturn; Queue_t *pxQueue; pxQueue = ( Queue_t * ) xQueue; configASSERT( pxQueue ); 80292b4: 4604 mov r4, r0 80292b6: b910 cbnz r0, 80292be 80292b8: f000 febe bl 802a038 80292bc: e7fe b.n 80292bc taskENTER_CRITICAL(); 80292be: f000 fec3 bl 802a048 { uxReturn = pxQueue->uxLength - pxQueue->uxMessagesWaiting; 80292c2: 6ba3 ldr r3, [r4, #56] ; 0x38 80292c4: 6be4 ldr r4, [r4, #60] ; 0x3c 80292c6: 1ae4 subs r4, r4, r3 } taskEXIT_CRITICAL(); 80292c8: f000 feea bl 802a0a0 return uxReturn; } /*lint !e818 Pointer cannot be declared const as xQueue is a typedef not pointer. */ 80292cc: 4620 mov r0, r4 80292ce: bd10 pop {r4, pc} 080292d0 : /*-----------------------------------------------------------*/ #if ( configUSE_TIMERS == 1 ) void vQueueWaitForMessageRestricted( QueueHandle_t xQueue, TickType_t xTicksToWait ) { 80292d0: b538 push {r3, r4, r5, lr} 80292d2: 4604 mov r4, r0 80292d4: 460d mov r5, r1 will not actually cause the task to block, just place it on a blocked list. It will not block until the scheduler is unlocked - at which time a yield will be performed. If an item is added to the queue while the queue is locked, and the calling task blocks on the queue, then the calling task will be immediately unblocked when the queue is unlocked. */ prvLockQueue( pxQueue ); 80292d6: f000 feb7 bl 802a048 80292da: 6c63 ldr r3, [r4, #68] ; 0x44 80292dc: 3301 adds r3, #1 80292de: d101 bne.n 80292e4 80292e0: 2300 movs r3, #0 80292e2: 6463 str r3, [r4, #68] ; 0x44 80292e4: 6ca3 ldr r3, [r4, #72] ; 0x48 80292e6: 3301 adds r3, #1 80292e8: d101 bne.n 80292ee 80292ea: 2300 movs r3, #0 80292ec: 64a3 str r3, [r4, #72] ; 0x48 80292ee: f000 fed7 bl 802a0a0 if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0U ) 80292f2: 6ba3 ldr r3, [r4, #56] ; 0x38 80292f4: b923 cbnz r3, 8029300 { /* There is nothing in the queue, block for the specified period. */ vTaskPlaceOnEventListRestricted( &( pxQueue->xTasksWaitingToReceive ), xTicksToWait ); 80292f6: f104 0024 add.w r0, r4, #36 ; 0x24 80292fa: 4629 mov r1, r5 80292fc: f000 fb70 bl 80299e0 } else { mtCOVERAGE_TEST_MARKER(); } prvUnlockQueue( pxQueue ); 8029300: 4620 mov r0, r4 } 8029302: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} } else { mtCOVERAGE_TEST_MARKER(); } prvUnlockQueue( pxQueue ); 8029306: f7ff bd05 b.w 8028d14 802930a: 0000 movs r0, r0 0802930c : static void prvResetNextTaskUnblockTime( void ) { TCB_t *pxTCB; if( listLIST_IS_EMPTY( pxDelayedTaskList ) != pdFALSE ) 802930c: 4a06 ldr r2, [pc, #24] ; (8029328 ) 802930e: 6813 ldr r3, [r2, #0] 8029310: 6819 ldr r1, [r3, #0] 8029312: 4b06 ldr r3, [pc, #24] ; (802932c ) 8029314: b911 cbnz r1, 802931c /* The new current delayed list is empty. Set xNextTaskUnblockTime to the maximum possible value so it is extremely unlikely that the if( xTickCount >= xNextTaskUnblockTime ) test will pass until there is an item in the delayed list. */ xNextTaskUnblockTime = portMAX_DELAY; 8029316: f04f 32ff mov.w r2, #4294967295 802931a: e003 b.n 8029324 { /* The new current delayed list is not empty, get the value of the item at the head of the delayed list. This is the time at which the task at the head of the delayed list should be removed from the Blocked state. */ ( pxTCB ) = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxDelayedTaskList ); 802931c: 6812 ldr r2, [r2, #0] 802931e: 68d2 ldr r2, [r2, #12] xNextTaskUnblockTime = listGET_LIST_ITEM_VALUE( &( ( pxTCB )->xGenericListItem ) ); 8029320: 68d2 ldr r2, [r2, #12] 8029322: 6852 ldr r2, [r2, #4] 8029324: 601a str r2, [r3, #0] 8029326: 4770 bx lr 8029328: 200028e8 .word 0x200028e8 802932c: 200015d8 .word 0x200015d8 08029330 : /*-----------------------------------------------------------*/ static void prvAddCurrentTaskToDelayedList( const TickType_t xTimeToWake ) { /* The list item will be inserted in wake time order. */ listSET_LIST_ITEM_VALUE( &( pxCurrentTCB->xGenericListItem ), xTimeToWake ); 8029330: 4b0e ldr r3, [pc, #56] ; (802936c ) 8029332: 681a ldr r2, [r3, #0] #endif /* vTaskDelete */ } /*-----------------------------------------------------------*/ static void prvAddCurrentTaskToDelayedList( const TickType_t xTimeToWake ) { 8029334: b510 push {r4, lr} /* The list item will be inserted in wake time order. */ listSET_LIST_ITEM_VALUE( &( pxCurrentTCB->xGenericListItem ), xTimeToWake ); 8029336: 6050 str r0, [r2, #4] if( xTimeToWake < xTickCount ) 8029338: 4a0d ldr r2, [pc, #52] ; (8029370 ) 802933a: 6812 ldr r2, [r2, #0] 802933c: 4290 cmp r0, r2 #endif /* vTaskDelete */ } /*-----------------------------------------------------------*/ static void prvAddCurrentTaskToDelayedList( const TickType_t xTimeToWake ) { 802933e: 4604 mov r4, r0 /* The list item will be inserted in wake time order. */ listSET_LIST_ITEM_VALUE( &( pxCurrentTCB->xGenericListItem ), xTimeToWake ); if( xTimeToWake < xTickCount ) 8029340: d207 bcs.n 8029352 { /* Wake time has overflowed. Place this item in the overflow list. */ vListInsert( pxOverflowDelayedTaskList, &( pxCurrentTCB->xGenericListItem ) ); 8029342: 4a0c ldr r2, [pc, #48] ; (8029374 ) 8029344: 6810 ldr r0, [r2, #0] 8029346: 6819 ldr r1, [r3, #0] 8029348: 3104 adds r1, #4 else { mtCOVERAGE_TEST_MARKER(); } } } 802934a: e8bd 4010 ldmia.w sp!, {r4, lr} listSET_LIST_ITEM_VALUE( &( pxCurrentTCB->xGenericListItem ), xTimeToWake ); if( xTimeToWake < xTickCount ) { /* Wake time has overflowed. Place this item in the overflow list. */ vListInsert( pxOverflowDelayedTaskList, &( pxCurrentTCB->xGenericListItem ) ); 802934e: f7ff bcb9 b.w 8028cc4 } else { /* The wake time has not overflowed, so the current block list is used. */ vListInsert( pxDelayedTaskList, &( pxCurrentTCB->xGenericListItem ) ); 8029352: 4a09 ldr r2, [pc, #36] ; (8029378 ) 8029354: 6810 ldr r0, [r2, #0] 8029356: 6819 ldr r1, [r3, #0] 8029358: 3104 adds r1, #4 802935a: f7ff fcb3 bl 8028cc4 /* If the task entering the blocked state was placed at the head of the list of blocked tasks then xNextTaskUnblockTime needs to be updated too. */ if( xTimeToWake < xNextTaskUnblockTime ) 802935e: 4b07 ldr r3, [pc, #28] ; (802937c ) 8029360: 681a ldr r2, [r3, #0] 8029362: 4294 cmp r4, r2 { xNextTaskUnblockTime = xTimeToWake; 8029364: bf38 it cc 8029366: 601c strcc r4, [r3, #0] 8029368: bd10 pop {r4, pc} 802936a: bf00 nop 802936c: 20002998 .word 0x20002998 8029370: 200029b4 .word 0x200029b4 8029374: 200029b8 .word 0x200029b8 8029378: 200028e8 .word 0x200028e8 802937c: 200015d8 .word 0x200015d8 08029380 : #endif /*-----------------------------------------------------------*/ BaseType_t xTaskGenericCreate( TaskFunction_t pxTaskCode, const char * const pcName, const uint16_t usStackDepth, void * const pvParameters, UBaseType_t uxPriority, TaskHandle_t * const pxCreatedTask, StackType_t * const puxStackBuffer, const MemoryRegion_t * const xRegions ) /*lint !e971 Unqualified char types are allowed for strings and single characters only. */ { 8029380: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} 8029384: 9d0a ldr r5, [sp, #40] ; 0x28 8029386: f8dd 802c ldr.w r8, [sp, #44] ; 0x2c 802938a: 9e0c ldr r6, [sp, #48] ; 0x30 802938c: 460f mov r7, r1 802938e: 4693 mov fp, r2 8029390: 469a mov sl, r3 BaseType_t xReturn; TCB_t * pxNewTCB; StackType_t *pxTopOfStack; configASSERT( pxTaskCode ); 8029392: 4681 mov r9, r0 8029394: b910 cbnz r0, 802939c 8029396: f000 fe4f bl 802a038 802939a: e7fe b.n 802939a configASSERT( ( ( uxPriority & ( ~portPRIVILEGE_BIT ) ) < configMAX_PRIORITIES ) ); 802939c: 2d04 cmp r5, #4 802939e: d902 bls.n 80293a6 80293a0: f000 fe4a bl 802a038 80293a4: e7fe b.n 80293a4 #else /* portSTACK_GROWTH */ { StackType_t *pxStack; /* Allocate space for the stack used by the task being created. */ pxStack = ( StackType_t * ) pvPortMallocAligned( ( ( ( size_t ) usStackDepth ) * sizeof( StackType_t ) ), puxStackBuffer ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 80293a6: b936 cbnz r6, 80293b6 80293a8: 0090 lsls r0, r2, #2 80293aa: f000 ff5b bl 802a264 if( pxStack != NULL ) 80293ae: 4606 mov r6, r0 80293b0: 2800 cmp r0, #0 80293b2: f000 809e beq.w 80294f2 { /* Allocate space for the TCB. Where the memory comes from depends on the implementation of the port malloc function. */ pxNewTCB = ( TCB_t * ) pvPortMalloc( sizeof( TCB_t ) ); 80293b6: 205c movs r0, #92 ; 0x5c 80293b8: f000 ff54 bl 802a264 if( pxNewTCB != NULL ) 80293bc: 4604 mov r4, r0 80293be: b178 cbz r0, 80293e0 { /* Store the stack location in the TCB. */ pxNewTCB->pxStack = pxStack; 80293c0: 6306 str r6, [r0, #48] ; 0x30 { /* Avoid dependency on memset() if it is not required. */ #if( ( configCHECK_FOR_STACK_OVERFLOW > 1 ) || ( configUSE_TRACE_FACILITY == 1 ) || ( INCLUDE_uxTaskGetStackHighWaterMark == 1 ) ) { /* Just to help debugging. */ ( void ) memset( pxNewTCB->pxStack, ( int ) tskSTACK_FILL_BYTE, ( size_t ) usStackDepth * sizeof( StackType_t ) ); 80293c2: ea4f 028b mov.w r2, fp, lsl #2 80293c6: 4630 mov r0, r6 80293c8: 21a5 movs r1, #165 ; 0xa5 80293ca: f7f8 fb79 bl 8021ac0 stack grows from high memory to low (as per the 80x86) or vice versa. portSTACK_GROWTH is used to make the result positive or negative as required by the port. */ #if( portSTACK_GROWTH < 0 ) { pxTopOfStack = pxNewTCB->pxStack + ( usStackDepth - ( uint16_t ) 1 ); 80293ce: 6b23 ldr r3, [r4, #48] ; 0x30 80293d0: f10b 3bff add.w fp, fp, #4294967295 80293d4: eb03 0b8b add.w fp, r3, fp, lsl #2 pxTopOfStack = ( StackType_t * ) ( ( ( portPOINTER_SIZE_TYPE ) pxTopOfStack ) & ( ( portPOINTER_SIZE_TYPE ) ~portBYTE_ALIGNMENT_MASK ) ); /*lint !e923 MISRA exception. Avoiding casts between pointers and integers is not practical. Size differences accounted for using portPOINTER_SIZE_TYPE type. */ 80293d8: f02b 0b07 bic.w fp, fp, #7 static void prvInitialiseTCBVariables( TCB_t * const pxTCB, const char * const pcName, UBaseType_t uxPriority, const MemoryRegion_t * const xRegions, const uint16_t usStackDepth ) /*lint !e971 Unqualified char types are allowed for strings and single characters only. */ { UBaseType_t x; /* Store the task name in the TCB. */ for( x = ( UBaseType_t ) 0; x < ( UBaseType_t ) configMAX_TASK_NAME_LEN; x++ ) 80293dc: 2600 movs r6, #0 80293de: e003 b.n 80293e8 } else { /* The stack cannot be used as the TCB was not created. Free it again. */ vPortFree( pxStack ); 80293e0: 4630 mov r0, r6 80293e2: f000 ffc5 bl 802a370 80293e6: e084 b.n 80294f2 static char *prvWriteNameToBuffer( char *pcBuffer, const char *pcTaskName ); #endif /*-----------------------------------------------------------*/ BaseType_t xTaskGenericCreate( TaskFunction_t pxTaskCode, const char * const pcName, const uint16_t usStackDepth, void * const pvParameters, UBaseType_t uxPriority, TaskHandle_t * const pxCreatedTask, StackType_t * const puxStackBuffer, const MemoryRegion_t * const xRegions ) /*lint !e971 Unqualified char types are allowed for strings and single characters only. */ 80293e8: 19a3 adds r3, r4, r6 UBaseType_t x; /* Store the task name in the TCB. */ for( x = ( UBaseType_t ) 0; x < ( UBaseType_t ) configMAX_TASK_NAME_LEN; x++ ) { pxTCB->pcTaskName[ x ] = pcName[ x ]; 80293ea: 5dba ldrb r2, [r7, r6] 80293ec: f883 2034 strb.w r2, [r3, #52] ; 0x34 /* Don't copy all configMAX_TASK_NAME_LEN if the string is shorter than configMAX_TASK_NAME_LEN characters just in case the memory after the string is not accessible (extremely unlikely). */ if( pcName[ x ] == 0x00 ) 80293f0: 5dbb ldrb r3, [r7, r6] 80293f2: b113 cbz r3, 80293fa static void prvInitialiseTCBVariables( TCB_t * const pxTCB, const char * const pcName, UBaseType_t uxPriority, const MemoryRegion_t * const xRegions, const uint16_t usStackDepth ) /*lint !e971 Unqualified char types are allowed for strings and single characters only. */ { UBaseType_t x; /* Store the task name in the TCB. */ for( x = ( UBaseType_t ) 0; x < ( UBaseType_t ) configMAX_TASK_NAME_LEN; x++ ) 80293f4: 3601 adds r6, #1 80293f6: 2e10 cmp r6, #16 80293f8: d1f6 bne.n 80293e8 } } /* Ensure the name string is terminated in the case that the string length was greater or equal to configMAX_TASK_NAME_LEN. */ pxTCB->pcTaskName[ configMAX_TASK_NAME_LEN - 1 ] = '\0'; 80293fa: 2600 movs r6, #0 pxTCB->uxBasePriority = uxPriority; pxTCB->uxMutexesHeld = 0; } #endif /* configUSE_MUTEXES */ vListInitialiseItem( &( pxTCB->xGenericListItem ) ); 80293fc: 1d27 adds r7, r4, #4 80293fe: 4638 mov r0, r7 } } /* Ensure the name string is terminated in the case that the string length was greater or equal to configMAX_TASK_NAME_LEN. */ pxTCB->pcTaskName[ configMAX_TASK_NAME_LEN - 1 ] = '\0'; 8029400: f884 6043 strb.w r6, [r4, #67] ; 0x43 else { mtCOVERAGE_TEST_MARKER(); } pxTCB->uxPriority = uxPriority; 8029404: 62e5 str r5, [r4, #44] ; 0x2c #if ( configUSE_MUTEXES == 1 ) { pxTCB->uxBasePriority = uxPriority; 8029406: 64e5 str r5, [r4, #76] ; 0x4c pxTCB->uxMutexesHeld = 0; 8029408: 6526 str r6, [r4, #80] ; 0x50 } #endif /* configUSE_MUTEXES */ vListInitialiseItem( &( pxTCB->xGenericListItem ) ); 802940a: f7ff fc4c bl 8028ca6 vListInitialiseItem( &( pxTCB->xEventListItem ) ); 802940e: f104 0018 add.w r0, r4, #24 8029412: f7ff fc48 bl 8028ca6 /* Set the pxTCB as a link back from the ListItem_t. This is so we can get back to the containing TCB from a generic item in a list. */ listSET_LIST_ITEM_OWNER( &( pxTCB->xGenericListItem ), pxTCB ); /* Event lists are always in priority order. */ listSET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ), ( TickType_t ) configMAX_PRIORITIES - ( TickType_t ) uxPriority ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 8029416: f1c5 0305 rsb r3, r5, #5 } #endif /* portUSING_MPU_WRAPPERS */ #if ( configUSE_TASK_NOTIFICATIONS == 1 ) { pxTCB->ulNotifiedValue = 0; 802941a: 6566 str r6, [r4, #84] ; 0x54 vListInitialiseItem( &( pxTCB->xGenericListItem ) ); vListInitialiseItem( &( pxTCB->xEventListItem ) ); /* Set the pxTCB as a link back from the ListItem_t. This is so we can get back to the containing TCB from a generic item in a list. */ listSET_LIST_ITEM_OWNER( &( pxTCB->xGenericListItem ), pxTCB ); 802941c: 6124 str r4, [r4, #16] /* Event lists are always in priority order. */ listSET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ), ( TickType_t ) configMAX_PRIORITIES - ( TickType_t ) uxPriority ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 802941e: 61a3 str r3, [r4, #24] listSET_LIST_ITEM_OWNER( &( pxTCB->xEventListItem ), pxTCB ); 8029420: 6264 str r4, [r4, #36] ; 0x24 #endif /* portUSING_MPU_WRAPPERS */ #if ( configUSE_TASK_NOTIFICATIONS == 1 ) { pxTCB->ulNotifiedValue = 0; pxTCB->eNotifyState = eNotWaitingNotification; 8029422: f884 6058 strb.w r6, [r4, #88] ; 0x58 { pxNewTCB->pxTopOfStack = pxPortInitialiseStack( pxTopOfStack, pxTaskCode, pvParameters, xRunPrivileged ); } #else /* portUSING_MPU_WRAPPERS */ { pxNewTCB->pxTopOfStack = pxPortInitialiseStack( pxTopOfStack, pxTaskCode, pvParameters ); 8029426: 4658 mov r0, fp 8029428: 4649 mov r1, r9 802942a: 4652 mov r2, sl 802942c: f000 fdd8 bl 8029fe0 8029430: 6020 str r0, [r4, #0] } #endif /* portUSING_MPU_WRAPPERS */ if( ( void * ) pxCreatedTask != NULL ) 8029432: f1b8 0f00 cmp.w r8, #0 8029436: d001 beq.n 802943c { /* Pass the TCB out - in an anonymous way. The calling function/ task can use this as a handle to delete the task later if required.*/ *pxCreatedTask = ( TaskHandle_t ) pxNewTCB; 8029438: f8c8 4000 str.w r4, [r8] mtCOVERAGE_TEST_MARKER(); } /* Ensure interrupts don't access the task lists while they are being updated. */ taskENTER_CRITICAL(); 802943c: f000 fe04 bl 802a048 { uxCurrentNumberOfTasks++; 8029440: 4a2e ldr r2, [pc, #184] ; (80294fc ) 8029442: 6813 ldr r3, [r2, #0] 8029444: 3301 adds r3, #1 8029446: 6013 str r3, [r2, #0] if( pxCurrentTCB == NULL ) 8029448: 4b2d ldr r3, [pc, #180] ; (8029500 ) 802944a: 681e ldr r6, [r3, #0] 802944c: bb36 cbnz r6, 802949c { /* There are no other tasks, or all the other tasks are in the suspended state - make this the current task. */ pxCurrentTCB = pxNewTCB; 802944e: 601c str r4, [r3, #0] if( uxCurrentNumberOfTasks == ( UBaseType_t ) 1 ) 8029450: 6813 ldr r3, [r2, #0] 8029452: 2b01 cmp r3, #1 8029454: d12a bne.n 80294ac { UBaseType_t uxPriority; for( uxPriority = ( UBaseType_t ) 0U; uxPriority < ( UBaseType_t ) configMAX_PRIORITIES; uxPriority++ ) { vListInitialise( &( pxReadyTasksLists[ uxPriority ] ) ); 8029456: f8df 80d0 ldr.w r8, [pc, #208] ; 8029528 802945a: f04f 0914 mov.w r9, #20 802945e: fb09 8006 mla r0, r9, r6, r8 static void prvInitialiseTaskLists( void ) { UBaseType_t uxPriority; for( uxPriority = ( UBaseType_t ) 0U; uxPriority < ( UBaseType_t ) configMAX_PRIORITIES; uxPriority++ ) 8029462: 3601 adds r6, #1 { vListInitialise( &( pxReadyTasksLists[ uxPriority ] ) ); 8029464: f7ff fc14 bl 8028c90 static void prvInitialiseTaskLists( void ) { UBaseType_t uxPriority; for( uxPriority = ( UBaseType_t ) 0U; uxPriority < ( UBaseType_t ) configMAX_PRIORITIES; uxPriority++ ) 8029468: 2e05 cmp r6, #5 802946a: d1f8 bne.n 802945e { vListInitialise( &( pxReadyTasksLists[ uxPriority ] ) ); } vListInitialise( &xDelayedTaskList1 ); 802946c: f8df 80bc ldr.w r8, [pc, #188] ; 802952c vListInitialise( &xDelayedTaskList2 ); 8029470: 4e24 ldr r6, [pc, #144] ; (8029504 ) for( uxPriority = ( UBaseType_t ) 0U; uxPriority < ( UBaseType_t ) configMAX_PRIORITIES; uxPriority++ ) { vListInitialise( &( pxReadyTasksLists[ uxPriority ] ) ); } vListInitialise( &xDelayedTaskList1 ); 8029472: 4640 mov r0, r8 8029474: f7ff fc0c bl 8028c90 vListInitialise( &xDelayedTaskList2 ); 8029478: 4630 mov r0, r6 802947a: f7ff fc09 bl 8028c90 vListInitialise( &xPendingReadyList ); 802947e: 4822 ldr r0, [pc, #136] ; (8029508 ) 8029480: f7ff fc06 bl 8028c90 #if ( INCLUDE_vTaskDelete == 1 ) { vListInitialise( &xTasksWaitingTermination ); 8029484: 4821 ldr r0, [pc, #132] ; (802950c ) 8029486: f7ff fc03 bl 8028c90 } #endif /* INCLUDE_vTaskDelete */ #if ( INCLUDE_vTaskSuspend == 1 ) { vListInitialise( &xSuspendedTaskList ); 802948a: 4821 ldr r0, [pc, #132] ; (8029510 ) 802948c: f7ff fc00 bl 8028c90 } #endif /* INCLUDE_vTaskSuspend */ /* Start with pxDelayedTaskList using list1 and the pxOverflowDelayedTaskList using list2. */ pxDelayedTaskList = &xDelayedTaskList1; 8029490: 4b20 ldr r3, [pc, #128] ; (8029514 ) 8029492: f8c3 8000 str.w r8, [r3] pxOverflowDelayedTaskList = &xDelayedTaskList2; 8029496: 4b20 ldr r3, [pc, #128] ; (8029518 ) 8029498: 601e str r6, [r3, #0] 802949a: e007 b.n 80294ac else { /* If the scheduler is not already running, make this task the current task if it is the highest priority task to be created so far. */ if( xSchedulerRunning == pdFALSE ) 802949c: 4a1f ldr r2, [pc, #124] ; (802951c ) 802949e: 6812 ldr r2, [r2, #0] 80294a0: b922 cbnz r2, 80294ac { if( pxCurrentTCB->uxPriority <= uxPriority ) 80294a2: 681a ldr r2, [r3, #0] 80294a4: 6ad2 ldr r2, [r2, #44] ; 0x2c 80294a6: 42aa cmp r2, r5 { pxCurrentTCB = pxNewTCB; 80294a8: bf98 it ls 80294aa: 601c strls r4, [r3, #0] { mtCOVERAGE_TEST_MARKER(); } } uxTaskNumber++; 80294ac: 4a1c ldr r2, [pc, #112] ; (8029520 ) 80294ae: 6813 ldr r3, [r2, #0] 80294b0: 3301 adds r3, #1 80294b2: 6013 str r3, [r2, #0] pxNewTCB->uxTCBNumber = uxTaskNumber; } #endif /* configUSE_TRACE_FACILITY */ traceTASK_CREATE( pxNewTCB ); prvAddTaskToReadyList( pxNewTCB ); 80294b4: 4a1b ldr r2, [pc, #108] ; (8029524 ) uxTaskNumber++; #if ( configUSE_TRACE_FACILITY == 1 ) { /* Add a counter into the TCB for tracing only. */ pxNewTCB->uxTCBNumber = uxTaskNumber; 80294b6: 6463 str r3, [r4, #68] ; 0x44 } #endif /* configUSE_TRACE_FACILITY */ traceTASK_CREATE( pxNewTCB ); prvAddTaskToReadyList( pxNewTCB ); 80294b8: 6ae3 ldr r3, [r4, #44] ; 0x2c 80294ba: 6811 ldr r1, [r2, #0] 80294bc: 2401 movs r4, #1 80294be: fa04 f003 lsl.w r0, r4, r3 80294c2: 4301 orrs r1, r0 80294c4: 6011 str r1, [r2, #0] 80294c6: 4a18 ldr r2, [pc, #96] ; (8029528 ) 80294c8: 2014 movs r0, #20 80294ca: fb00 2003 mla r0, r0, r3, r2 80294ce: 4639 mov r1, r7 80294d0: f7ff fbec bl 8028cac xReturn = pdPASS; portSETUP_TCB( pxNewTCB ); } taskEXIT_CRITICAL(); 80294d4: f000 fde4 bl 802a0a0 traceTASK_CREATE_FAILED(); } if( xReturn == pdPASS ) { if( xSchedulerRunning != pdFALSE ) 80294d8: 4b10 ldr r3, [pc, #64] ; (802951c ) 80294da: 681b ldr r3, [r3, #0] 80294dc: b133 cbz r3, 80294ec { /* If the created task is of a higher priority than the current task then it should run now. */ if( pxCurrentTCB->uxPriority < uxPriority ) 80294de: 4b08 ldr r3, [pc, #32] ; (8029500 ) 80294e0: 681b ldr r3, [r3, #0] 80294e2: 6adb ldr r3, [r3, #44] ; 0x2c 80294e4: 42ab cmp r3, r5 80294e6: d201 bcs.n 80294ec { taskYIELD_IF_USING_PREEMPTION(); 80294e8: f000 fd9a bl 802a020 #endif /* configUSE_TRACE_FACILITY */ traceTASK_CREATE( pxNewTCB ); prvAddTaskToReadyList( pxNewTCB ); xReturn = pdPASS; 80294ec: 4620 mov r0, r4 80294ee: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} } taskEXIT_CRITICAL(); } else { xReturn = errCOULD_NOT_ALLOCATE_REQUIRED_MEMORY; 80294f2: f04f 30ff mov.w r0, #4294967295 mtCOVERAGE_TEST_MARKER(); } } return xReturn; } 80294f6: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 80294fa: bf00 nop 80294fc: 200029c0 .word 0x200029c0 8029500: 20002998 .word 0x20002998 8029504: 20002908 .word 0x20002908 8029508: 2000299c .word 0x2000299c 802950c: 20002984 .word 0x20002984 8029510: 200029c4 .word 0x200029c4 8029514: 200028e8 .word 0x200028e8 8029518: 200029b8 .word 0x200029b8 802951c: 200028ec .word 0x200028ec 8029520: 200029bc .word 0x200029bc 8029524: 200029d8 .word 0x200029d8 8029528: 20002920 .word 0x20002920 802952c: 200028f4 .word 0x200028f4 08029530 : /*-----------------------------------------------------------*/ #if ( INCLUDE_vTaskDelete == 1 ) void vTaskDelete( TaskHandle_t xTaskToDelete ) { 8029530: b538 push {r3, r4, r5, lr} 8029532: 4604 mov r4, r0 TCB_t *pxTCB; taskENTER_CRITICAL(); 8029534: f000 fd88 bl 802a048 { /* If null is passed in here then it is the calling task that is being deleted. */ pxTCB = prvGetTCBFromHandle( xTaskToDelete ); 8029538: b90c cbnz r4, 802953e 802953a: 4b22 ldr r3, [pc, #136] ; (80295c4 ) 802953c: 681c ldr r4, [r3, #0] /* Remove task from the ready list and place in the termination list. This will stop the task from be scheduled. The idle task will check the termination list and free up any memory allocated by the scheduler for the TCB and stack. */ if( uxListRemove( &( pxTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 802953e: 1d25 adds r5, r4, #4 8029540: 4628 mov r0, r5 8029542: f7ff fbd7 bl 8028cf4 8029546: b968 cbnz r0, 8029564 { taskRESET_READY_PRIORITY( pxTCB->uxPriority ); 8029548: 6ae2 ldr r2, [r4, #44] ; 0x2c 802954a: 491f ldr r1, [pc, #124] ; (80295c8 ) 802954c: 2314 movs r3, #20 802954e: 4353 muls r3, r2 8029550: 58cb ldr r3, [r1, r3] 8029552: b93b cbnz r3, 8029564 8029554: 4b1d ldr r3, [pc, #116] ; (80295cc ) 8029556: 2001 movs r0, #1 8029558: 6819 ldr r1, [r3, #0] 802955a: fa00 f202 lsl.w r2, r0, r2 802955e: ea21 0202 bic.w r2, r1, r2 8029562: 601a str r2, [r3, #0] { mtCOVERAGE_TEST_MARKER(); } /* Is the task waiting on an event also? */ if( listLIST_ITEM_CONTAINER( &( pxTCB->xEventListItem ) ) != NULL ) 8029564: 6aa3 ldr r3, [r4, #40] ; 0x28 8029566: b11b cbz r3, 8029570 { ( void ) uxListRemove( &( pxTCB->xEventListItem ) ); 8029568: f104 0018 add.w r0, r4, #24 802956c: f7ff fbc2 bl 8028cf4 else { mtCOVERAGE_TEST_MARKER(); } vListInsertEnd( &xTasksWaitingTermination, &( pxTCB->xGenericListItem ) ); 8029570: 4817 ldr r0, [pc, #92] ; (80295d0 ) 8029572: 4629 mov r1, r5 8029574: f7ff fb9a bl 8028cac /* Increment the ucTasksDeleted variable so the idle task knows there is a task that has been deleted and that it should therefore check the xTasksWaitingTermination list. */ ++uxTasksDeleted; 8029578: 4b16 ldr r3, [pc, #88] ; (80295d4 ) 802957a: 681a ldr r2, [r3, #0] 802957c: 3201 adds r2, #1 802957e: 601a str r2, [r3, #0] /* Increment the uxTaskNumberVariable also so kernel aware debuggers can detect that the task lists need re-generating. */ uxTaskNumber++; 8029580: 4b15 ldr r3, [pc, #84] ; (80295d8 ) 8029582: 681a ldr r2, [r3, #0] 8029584: 3201 adds r2, #1 8029586: 601a str r2, [r3, #0] traceTASK_DELETE( pxTCB ); } taskEXIT_CRITICAL(); 8029588: f000 fd8a bl 802a0a0 /* Force a reschedule if it is the currently running task that has just been deleted. */ if( xSchedulerRunning != pdFALSE ) 802958c: 4b13 ldr r3, [pc, #76] ; (80295dc ) 802958e: 681b ldr r3, [r3, #0] 8029590: 2b00 cmp r3, #0 8029592: d015 beq.n 80295c0 { if( pxTCB == pxCurrentTCB ) 8029594: 4b0b ldr r3, [pc, #44] ; (80295c4 ) 8029596: 681b ldr r3, [r3, #0] 8029598: 429c cmp r4, r3 802959a: d109 bne.n 80295b0 { configASSERT( uxSchedulerSuspended == 0 ); 802959c: 4b10 ldr r3, [pc, #64] ; (80295e0 ) 802959e: 681b ldr r3, [r3, #0] 80295a0: b113 cbz r3, 80295a8 80295a2: f000 fd49 bl 802a038 80295a6: e7fe b.n 80295a6 prvResetNextTaskUnblockTime(); } taskEXIT_CRITICAL(); } } } 80295a8: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} in which Windows specific clean up operations are performed, after which it is not possible to yield away from this task - hence xYieldPending is used to latch that a context switch is required. */ portPRE_TASK_DELETE_HOOK( pxTCB, &xYieldPending ); portYIELD_WITHIN_API(); 80295ac: f000 bd38 b.w 802a020 } else { /* Reset the next expected unblock time in case it referred to the task that has just been deleted. */ taskENTER_CRITICAL(); 80295b0: f000 fd4a bl 802a048 { prvResetNextTaskUnblockTime(); 80295b4: f7ff feaa bl 802930c } taskEXIT_CRITICAL(); } } } 80295b8: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} the task that has just been deleted. */ taskENTER_CRITICAL(); { prvResetNextTaskUnblockTime(); } taskEXIT_CRITICAL(); 80295bc: f000 bd70 b.w 802a0a0 80295c0: bd38 pop {r3, r4, r5, pc} 80295c2: bf00 nop 80295c4: 20002998 .word 0x20002998 80295c8: 20002920 .word 0x20002920 80295cc: 200029d8 .word 0x200029d8 80295d0: 20002984 .word 0x20002984 80295d4: 200028f0 .word 0x200028f0 80295d8: 200029bc .word 0x200029bc 80295dc: 200028ec .word 0x200028ec 80295e0: 200029b0 .word 0x200029b0 080295e4 : #endif /* ( ( INCLUDE_xTaskResumeFromISR == 1 ) && ( INCLUDE_vTaskSuspend == 1 ) ) */ /*-----------------------------------------------------------*/ void vTaskStartScheduler( void ) { 80295e4: b530 push {r4, r5, lr} 80295e6: b085 sub sp, #20 xReturn = xTaskCreate( prvIdleTask, "IDLE", tskIDLE_STACK_SIZE, ( void * ) NULL, ( tskIDLE_PRIORITY | portPRIVILEGE_BIT ), &xIdleTaskHandle ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */ } #else { /* Create the idle task without storing its handle. */ xReturn = xTaskCreate( prvIdleTask, "IDLE", tskIDLE_STACK_SIZE, ( void * ) NULL, ( tskIDLE_PRIORITY | portPRIVILEGE_BIT ), NULL ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */ 80295e8: 2400 movs r4, #0 80295ea: 2280 movs r2, #128 ; 0x80 80295ec: 9400 str r4, [sp, #0] 80295ee: 9401 str r4, [sp, #4] 80295f0: 9402 str r4, [sp, #8] 80295f2: 9403 str r4, [sp, #12] 80295f4: 480e ldr r0, [pc, #56] ; (8029630 ) 80295f6: 490f ldr r1, [pc, #60] ; (8029634 ) 80295f8: 4623 mov r3, r4 80295fa: f7ff fec1 bl 8029380 } #endif /* INCLUDE_xTaskGetIdleTaskHandle */ #if ( configUSE_TIMERS == 1 ) { if( xReturn == pdPASS ) 80295fe: 2801 cmp r0, #1 xReturn = xTaskCreate( prvIdleTask, "IDLE", tskIDLE_STACK_SIZE, ( void * ) NULL, ( tskIDLE_PRIORITY | portPRIVILEGE_BIT ), &xIdleTaskHandle ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */ } #else { /* Create the idle task without storing its handle. */ xReturn = xTaskCreate( prvIdleTask, "IDLE", tskIDLE_STACK_SIZE, ( void * ) NULL, ( tskIDLE_PRIORITY | portPRIVILEGE_BIT ), NULL ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */ 8029600: 4605 mov r5, r0 } #endif /* INCLUDE_xTaskGetIdleTaskHandle */ #if ( configUSE_TIMERS == 1 ) { if( xReturn == pdPASS ) 8029602: d10f bne.n 8029624 { xReturn = xTimerCreateTimerTask(); 8029604: f000 fb82 bl 8029d0c mtCOVERAGE_TEST_MARKER(); } } #endif /* configUSE_TIMERS */ if( xReturn == pdPASS ) 8029608: 2801 cmp r0, #1 #if ( configUSE_TIMERS == 1 ) { if( xReturn == pdPASS ) { xReturn = xTimerCreateTimerTask(); 802960a: 4605 mov r5, r0 mtCOVERAGE_TEST_MARKER(); } } #endif /* configUSE_TIMERS */ if( xReturn == pdPASS ) 802960c: d10a bne.n 8029624 /* Interrupts are turned off here, to ensure a tick does not occur before or during the call to xPortStartScheduler(). The stacks of the created tasks contain a status word with interrupts switched on so interrupts will automatically get re-enabled when the first task starts to run. */ portDISABLE_INTERRUPTS(); 802960e: f000 fd13 bl 802a038 structure specific to the task that will run first. */ _impure_ptr = &( pxCurrentTCB->xNewLib_reent ); } #endif /* configUSE_NEWLIB_REENTRANT */ xSchedulerRunning = pdTRUE; 8029612: 4b09 ldr r3, [pc, #36] ; (8029638 ) 8029614: 601d str r5, [r3, #0] xTickCount = ( TickType_t ) 0U; 8029616: 4b09 ldr r3, [pc, #36] ; (802963c ) 8029618: 601c str r4, [r3, #0] /* This line will only be reached if the kernel could not be started, because there was not enough FreeRTOS heap to create the idle task or the timer task. */ configASSERT( xReturn ); } } 802961a: b005 add sp, #20 802961c: e8bd 4030 ldmia.w sp!, {r4, r5, lr} the run time counter time base. */ portCONFIGURE_TIMER_FOR_RUN_TIME_STATS(); /* Setting up the timer tick is hardware specific and thus in the portable interface. */ if( xPortStartScheduler() != pdFALSE ) 8029620: f000 bd96 b.w 802a150 else { /* This line will only be reached if the kernel could not be started, because there was not enough FreeRTOS heap to create the idle task or the timer task. */ configASSERT( xReturn ); 8029624: b915 cbnz r5, 802962c 8029626: f000 fd07 bl 802a038 802962a: e7fe b.n 802962a } } 802962c: b005 add sp, #20 802962e: bd30 pop {r4, r5, pc} 8029630: 08029851 .word 0x08029851 8029634: 08035f84 .word 0x08035f84 8029638: 200028ec .word 0x200028ec 802963c: 200029b4 .word 0x200029b4 08029640 : { /* A critical section is not required as the variable is of type BaseType_t. Please read Richard Barry's reply in the following link to a post in the FreeRTOS support forum before reporting this as a bug! - http://goo.gl/wu4acr */ ++uxSchedulerSuspended; 8029640: 4b02 ldr r3, [pc, #8] ; (802964c ) 8029642: 681a ldr r2, [r3, #0] 8029644: 3201 adds r2, #1 8029646: 601a str r2, [r3, #0] 8029648: 4770 bx lr 802964a: bf00 nop 802964c: 200029b0 .word 0x200029b0 08029650 : TickType_t xTicks; /* Critical section required if running on a 16 bit processor. */ portTICK_TYPE_ENTER_CRITICAL(); { xTicks = xTickCount; 8029650: 4b01 ldr r3, [pc, #4] ; (8029658 ) 8029652: 6818 ldr r0, [r3, #0] } portTICK_TYPE_EXIT_CRITICAL(); return xTicks; } 8029654: 4770 bx lr 8029656: bf00 nop 8029658: 200029b4 .word 0x200029b4 0802965c : /* Called by the portable layer each time a tick interrupt occurs. Increments the tick then checks to see if the new tick value will cause any tasks to be unblocked. */ traceTASK_INCREMENT_TICK( xTickCount ); if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) 802965c: 4b3b ldr r3, [pc, #236] ; (802974c ) 802965e: 681b ldr r3, [r3, #0] #endif /* configUSE_TICKLESS_IDLE */ /*----------------------------------------------------------*/ BaseType_t xTaskIncrementTick( void ) { 8029660: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} /* Called by the portable layer each time a tick interrupt occurs. Increments the tick then checks to see if the new tick value will cause any tasks to be unblocked. */ traceTASK_INCREMENT_TICK( xTickCount ); if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) 8029664: 2b00 cmp r3, #0 8029666: d15b bne.n 8029720 { /* Increment the RTOS tick, switching the delayed and overflowed delayed lists if it wraps to 0. */ ++xTickCount; 8029668: 4b39 ldr r3, [pc, #228] ; (8029750 ) 802966a: 681a ldr r2, [r3, #0] 802966c: 3201 adds r2, #1 802966e: 601a str r2, [r3, #0] { /* Minor optimisation. The tick count cannot change in this block. */ const TickType_t xConstTickCount = xTickCount; 8029670: 681e ldr r6, [r3, #0] if( xConstTickCount == ( TickType_t ) 0U ) 8029672: b98e cbnz r6, 8029698 { taskSWITCH_DELAYED_LISTS(); 8029674: 4b37 ldr r3, [pc, #220] ; (8029754 ) 8029676: 681a ldr r2, [r3, #0] 8029678: 6812 ldr r2, [r2, #0] 802967a: b112 cbz r2, 8029682 802967c: f000 fcdc bl 802a038 8029680: e7fe b.n 8029680 8029682: 4a35 ldr r2, [pc, #212] ; (8029758 ) 8029684: 6819 ldr r1, [r3, #0] 8029686: 6810 ldr r0, [r2, #0] 8029688: 6018 str r0, [r3, #0] 802968a: 4b34 ldr r3, [pc, #208] ; (802975c ) 802968c: 6011 str r1, [r2, #0] 802968e: 681a ldr r2, [r3, #0] 8029690: 3201 adds r2, #1 8029692: 601a str r2, [r3, #0] 8029694: f7ff fe3a bl 802930c /* See if this tick has made a timeout expire. Tasks are stored in the queue in the order of their wake time - meaning once one task has been found whose block time has not expired there is no need to look any further down the list. */ if( xConstTickCount >= xNextTaskUnblockTime ) 8029698: 4b31 ldr r3, [pc, #196] ; (8029760 ) 802969a: 681b ldr r3, [r3, #0] 802969c: 2400 movs r4, #0 802969e: 429e cmp r6, r3 80296a0: d200 bcs.n 80296a4 80296a2: e032 b.n 802970a { for( ;; ) { if( listLIST_IS_EMPTY( pxDelayedTaskList ) != pdFALSE ) 80296a4: 4f2b ldr r7, [pc, #172] ; (8029754 ) mtCOVERAGE_TEST_MARKER(); } /* Place the unblocked task into the appropriate ready list. */ prvAddTaskToReadyList( pxTCB ); 80296a6: f8df 80cc ldr.w r8, [pc, #204] ; 8029774 80296aa: f8df a0bc ldr.w sl, [pc, #188] ; 8029768 look any further down the list. */ if( xConstTickCount >= xNextTaskUnblockTime ) { for( ;; ) { if( listLIST_IS_EMPTY( pxDelayedTaskList ) != pdFALSE ) 80296ae: 683b ldr r3, [r7, #0] 80296b0: 681b ldr r3, [r3, #0] 80296b2: 2b00 cmp r3, #0 80296b4: d13a bne.n 802972c /* The delayed list is empty. Set xNextTaskUnblockTime to the maximum possible value so it is extremely unlikely that the if( xTickCount >= xNextTaskUnblockTime ) test will pass next time through. */ xNextTaskUnblockTime = portMAX_DELAY; 80296b6: 4b2a ldr r3, [pc, #168] ; (8029760 ) 80296b8: f04f 32ff mov.w r2, #4294967295 80296bc: 601a str r2, [r3, #0] break; 80296be: e024 b.n 802970a /* It is not time to unblock this item yet, but the item value is the time at which the task at the head of the blocked list must be removed from the Blocked state - so record the item value in xNextTaskUnblockTime. */ xNextTaskUnblockTime = xItemValue; 80296c0: 4a27 ldr r2, [pc, #156] ; (8029760 ) 80296c2: 6013 str r3, [r2, #0] break; 80296c4: e021 b.n 802970a { mtCOVERAGE_TEST_MARKER(); } /* It is time to remove the item from the Blocked state. */ ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); 80296c6: f105 0904 add.w r9, r5, #4 80296ca: 4648 mov r0, r9 80296cc: f7ff fb12 bl 8028cf4 /* Is the task waiting on an event also? If so remove it from the event list. */ if( listLIST_ITEM_CONTAINER( &( pxTCB->xEventListItem ) ) != NULL ) 80296d0: 6aab ldr r3, [r5, #40] ; 0x28 80296d2: b11b cbz r3, 80296dc { ( void ) uxListRemove( &( pxTCB->xEventListItem ) ); 80296d4: f105 0018 add.w r0, r5, #24 80296d8: f7ff fb0c bl 8028cf4 mtCOVERAGE_TEST_MARKER(); } /* Place the unblocked task into the appropriate ready list. */ prvAddTaskToReadyList( pxTCB ); 80296dc: 6aeb ldr r3, [r5, #44] ; 0x2c 80296de: f8d8 1000 ldr.w r1, [r8] 80296e2: 2201 movs r2, #1 80296e4: fa02 f203 lsl.w r2, r2, r3 80296e8: 2014 movs r0, #20 80296ea: 430a orrs r2, r1 80296ec: fb00 a003 mla r0, r0, r3, sl 80296f0: 4649 mov r1, r9 80296f2: f8c8 2000 str.w r2, [r8] 80296f6: f7ff fad9 bl 8028cac { /* Preemption is on, but a context switch should only be performed if the unblocked task has a priority that is equal to or higher than the currently executing task. */ if( pxTCB->uxPriority >= pxCurrentTCB->uxPriority ) 80296fa: 4b1a ldr r3, [pc, #104] ; (8029764 ) 80296fc: 6aea ldr r2, [r5, #44] ; 0x2c 80296fe: 681b ldr r3, [r3, #0] 8029700: 6adb ldr r3, [r3, #44] ; 0x2c { xSwitchRequired = pdTRUE; 8029702: 429a cmp r2, r3 8029704: bf28 it cs 8029706: 2401 movcs r4, #1 8029708: e7d1 b.n 80296ae /* Tasks of equal priority to the currently running task will share processing time (time slice) if preemption is on, and the application writer has not explicitly turned time slicing off. */ #if ( ( configUSE_PREEMPTION == 1 ) && ( configUSE_TIME_SLICING == 1 ) ) { if( listCURRENT_LIST_LENGTH( &( pxReadyTasksLists[ pxCurrentTCB->uxPriority ] ) ) > ( UBaseType_t ) 1 ) 802970a: 4b16 ldr r3, [pc, #88] ; (8029764 ) 802970c: 681b ldr r3, [r3, #0] 802970e: 6adb ldr r3, [r3, #44] ; 0x2c 8029710: 2214 movs r2, #20 8029712: 4353 muls r3, r2 8029714: 4a14 ldr r2, [pc, #80] ; (8029768 ) 8029716: 58d3 ldr r3, [r2, r3] { xSwitchRequired = pdTRUE; 8029718: 2b01 cmp r3, #1 802971a: bf88 it hi 802971c: 2401 movhi r4, #1 802971e: e00c b.n 802973a } #endif /* configUSE_TICK_HOOK */ } else { ++uxPendedTicks; 8029720: 4b12 ldr r3, [pc, #72] ; (802976c ) 8029722: 681a ldr r2, [r3, #0] 8029724: 3201 adds r2, #1 8029726: 601a str r2, [r3, #0] BaseType_t xTaskIncrementTick( void ) { TCB_t * pxTCB; TickType_t xItemValue; BaseType_t xSwitchRequired = pdFALSE; 8029728: 2400 movs r4, #0 802972a: e006 b.n 802973a { /* The delayed list is not empty, get the value of the item at the head of the delayed list. This is the time at which the task at the head of the delayed list must be removed from the Blocked state. */ pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxDelayedTaskList ); 802972c: 683b ldr r3, [r7, #0] 802972e: 68db ldr r3, [r3, #12] 8029730: 68dd ldr r5, [r3, #12] xItemValue = listGET_LIST_ITEM_VALUE( &( pxTCB->xGenericListItem ) ); 8029732: 686b ldr r3, [r5, #4] if( xConstTickCount < xItemValue ) 8029734: 429e cmp r6, r3 8029736: d2c6 bcs.n 80296c6 8029738: e7c2 b.n 80296c0 #endif } #if ( configUSE_PREEMPTION == 1 ) { if( xYieldPending != pdFALSE ) 802973a: 4b0d ldr r3, [pc, #52] ; (8029770 ) 802973c: 681b ldr r3, [r3, #0] { xSwitchRequired = pdTRUE; 802973e: 2b00 cmp r3, #0 8029740: bf18 it ne 8029742: 2401 movne r4, #1 } } #endif /* configUSE_PREEMPTION */ return xSwitchRequired; } 8029744: 4620 mov r0, r4 8029746: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 802974a: bf00 nop 802974c: 200029b0 .word 0x200029b0 8029750: 200029b4 .word 0x200029b4 8029754: 200028e8 .word 0x200028e8 8029758: 200029b8 .word 0x200029b8 802975c: 200028e4 .word 0x200028e4 8029760: 200015d8 .word 0x200015d8 8029764: 20002998 .word 0x20002998 8029768: 20002920 .word 0x20002920 802976c: 2000291c .word 0x2000291c 8029770: 200029dc .word 0x200029dc 8029774: 200029d8 .word 0x200029d8 08029778 : #endif /* configUSE_TICKLESS_IDLE */ /*----------------------------------------------------------*/ BaseType_t xTaskResumeAll( void ) { 8029778: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} TCB_t *pxTCB; BaseType_t xAlreadyYielded = pdFALSE; /* If uxSchedulerSuspended is zero then this function does not match a previous call to vTaskSuspendAll(). */ configASSERT( uxSchedulerSuspended ); 802977c: 4c2c ldr r4, [pc, #176] ; (8029830 ) 802977e: 6823 ldr r3, [r4, #0] 8029780: b913 cbnz r3, 8029788 8029782: f000 fc59 bl 802a038 8029786: e7fe b.n 8029786 /* It is possible that an ISR caused a task to be removed from an event list while the scheduler was suspended. If this was the case then the removed task will have been added to the xPendingReadyList. Once the scheduler has been resumed it is safe to move all the pending ready tasks from this list into their appropriate ready list. */ taskENTER_CRITICAL(); 8029788: f000 fc5e bl 802a048 { --uxSchedulerSuspended; 802978c: 6823 ldr r3, [r4, #0] 802978e: 3b01 subs r3, #1 8029790: 6023 str r3, [r4, #0] if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) 8029792: 6823 ldr r3, [r4, #0] 8029794: b10b cbz r3, 802979a /*----------------------------------------------------------*/ BaseType_t xTaskResumeAll( void ) { TCB_t *pxTCB; BaseType_t xAlreadyYielded = pdFALSE; 8029796: 2400 movs r4, #0 8029798: e044 b.n 8029824 { --uxSchedulerSuspended; if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) { if( uxCurrentNumberOfTasks > ( UBaseType_t ) 0U ) 802979a: 4b26 ldr r3, [pc, #152] ; (8029834 ) 802979c: 681b ldr r3, [r3, #0] 802979e: bb0b cbnz r3, 80297e4 80297a0: e7f9 b.n 8029796 { /* Move any readied tasks from the pending list into the appropriate ready list. */ while( listLIST_IS_EMPTY( &xPendingReadyList ) == pdFALSE ) { pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( ( &xPendingReadyList ) ); 80297a2: 68f3 ldr r3, [r6, #12] 80297a4: 68dc ldr r4, [r3, #12] ( void ) uxListRemove( &( pxTCB->xEventListItem ) ); ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); 80297a6: f104 0804 add.w r8, r4, #4 /* Move any readied tasks from the pending list into the appropriate ready list. */ while( listLIST_IS_EMPTY( &xPendingReadyList ) == pdFALSE ) { pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( ( &xPendingReadyList ) ); ( void ) uxListRemove( &( pxTCB->xEventListItem ) ); 80297aa: f104 0018 add.w r0, r4, #24 80297ae: f7ff faa1 bl 8028cf4 ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); 80297b2: 4640 mov r0, r8 80297b4: f7ff fa9e bl 8028cf4 prvAddTaskToReadyList( pxTCB ); 80297b8: 6ae3 ldr r3, [r4, #44] ; 0x2c 80297ba: 682a ldr r2, [r5, #0] 80297bc: 2701 movs r7, #1 80297be: fa07 f103 lsl.w r1, r7, r3 80297c2: 2014 movs r0, #20 80297c4: 430a orrs r2, r1 80297c6: fb00 9003 mla r0, r0, r3, r9 80297ca: 4641 mov r1, r8 80297cc: 602a str r2, [r5, #0] 80297ce: f7ff fa6d bl 8028cac /* If the moved task has a priority higher than the current task then a yield must be performed. */ if( pxTCB->uxPriority >= pxCurrentTCB->uxPriority ) 80297d2: 4b19 ldr r3, [pc, #100] ; (8029838 ) 80297d4: 6ae2 ldr r2, [r4, #44] ; 0x2c 80297d6: 681b ldr r3, [r3, #0] 80297d8: 6adb ldr r3, [r3, #44] ; 0x2c 80297da: 429a cmp r2, r3 80297dc: d306 bcc.n 80297ec { xYieldPending = pdTRUE; 80297de: 4b17 ldr r3, [pc, #92] ; (802983c ) 80297e0: 601f str r7, [r3, #0] 80297e2: e003 b.n 80297ec { if( uxCurrentNumberOfTasks > ( UBaseType_t ) 0U ) { /* Move any readied tasks from the pending list into the appropriate ready list. */ while( listLIST_IS_EMPTY( &xPendingReadyList ) == pdFALSE ) 80297e4: 4e16 ldr r6, [pc, #88] ; (8029840 ) { pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( ( &xPendingReadyList ) ); ( void ) uxListRemove( &( pxTCB->xEventListItem ) ); ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); prvAddTaskToReadyList( pxTCB ); 80297e6: 4d17 ldr r5, [pc, #92] ; (8029844 ) 80297e8: f8df 9060 ldr.w r9, [pc, #96] ; 802984c { if( uxCurrentNumberOfTasks > ( UBaseType_t ) 0U ) { /* Move any readied tasks from the pending list into the appropriate ready list. */ while( listLIST_IS_EMPTY( &xPendingReadyList ) == pdFALSE ) 80297ec: 6833 ldr r3, [r6, #0] 80297ee: 2b00 cmp r3, #0 80297f0: d1d7 bne.n 80297a2 /* If any ticks occurred while the scheduler was suspended then they should be processed now. This ensures the tick count does not slip, and that any delayed tasks are resumed at the correct time. */ if( uxPendedTicks > ( UBaseType_t ) 0U ) 80297f2: 4c15 ldr r4, [pc, #84] ; (8029848 ) 80297f4: 6823 ldr r3, [r4, #0] 80297f6: b96b cbnz r3, 8029814 else { mtCOVERAGE_TEST_MARKER(); } if( xYieldPending == pdTRUE ) 80297f8: 4b10 ldr r3, [pc, #64] ; (802983c ) 80297fa: 681c ldr r4, [r3, #0] 80297fc: 2c01 cmp r4, #1 80297fe: d1ca bne.n 8029796 8029800: e00e b.n 8029820 time. */ if( uxPendedTicks > ( UBaseType_t ) 0U ) { while( uxPendedTicks > ( UBaseType_t ) 0U ) { if( xTaskIncrementTick() != pdFALSE ) 8029802: f7ff ff2b bl 802965c 8029806: b108 cbz r0, 802980c { xYieldPending = pdTRUE; 8029808: 2301 movs r3, #1 802980a: 6033 str r3, [r6, #0] } else { mtCOVERAGE_TEST_MARKER(); } --uxPendedTicks; 802980c: 682b ldr r3, [r5, #0] 802980e: 3b01 subs r3, #1 8029810: 602b str r3, [r5, #0] 8029812: e001 b.n 8029818 { while( uxPendedTicks > ( UBaseType_t ) 0U ) { if( xTaskIncrementTick() != pdFALSE ) { xYieldPending = pdTRUE; 8029814: 4e09 ldr r6, [pc, #36] ; (802983c ) 8029816: 4625 mov r5, r4 they should be processed now. This ensures the tick count does not slip, and that any delayed tasks are resumed at the correct time. */ if( uxPendedTicks > ( UBaseType_t ) 0U ) { while( uxPendedTicks > ( UBaseType_t ) 0U ) 8029818: 6823 ldr r3, [r4, #0] 802981a: 2b00 cmp r3, #0 802981c: d1f1 bne.n 8029802 802981e: e7eb b.n 80297f8 #if( configUSE_PREEMPTION != 0 ) { xAlreadyYielded = pdTRUE; } #endif taskYIELD_IF_USING_PREEMPTION(); 8029820: f000 fbfe bl 802a020 else { mtCOVERAGE_TEST_MARKER(); } } taskEXIT_CRITICAL(); 8029824: f000 fc3c bl 802a0a0 return xAlreadyYielded; } 8029828: 4620 mov r0, r4 802982a: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 802982e: bf00 nop 8029830: 200029b0 .word 0x200029b0 8029834: 200029c0 .word 0x200029c0 8029838: 20002998 .word 0x20002998 802983c: 200029dc .word 0x200029dc 8029840: 2000299c .word 0x2000299c 8029844: 200029d8 .word 0x200029d8 8029848: 2000291c .word 0x2000291c 802984c: 20002920 .word 0x20002920 08029850 : * * void prvIdleTask( void *pvParameters ); * */ static portTASK_FUNCTION( prvIdleTask, pvParameters ) { 8029850: b5f8 push {r3, r4, r5, r6, r7, lr} { BaseType_t xListIsEmpty; /* ucTasksDeleted is used to prevent vTaskSuspendAll() being called too often in the idle task. */ while( uxTasksDeleted > ( UBaseType_t ) 0U ) 8029852: 4c14 ldr r4, [pc, #80] ; (80298a4 ) { vTaskSuspendAll(); { xListIsEmpty = listLIST_IS_EMPTY( &xTasksWaitingTermination ); 8029854: 4e14 ldr r6, [pc, #80] ; (80298a8 ) taskENTER_CRITICAL(); { pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( ( &xTasksWaitingTermination ) ); ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); --uxCurrentNumberOfTasks; 8029856: 4f15 ldr r7, [pc, #84] ; (80298ac ) { BaseType_t xListIsEmpty; /* ucTasksDeleted is used to prevent vTaskSuspendAll() being called too often in the idle task. */ while( uxTasksDeleted > ( UBaseType_t ) 0U ) 8029858: 6823 ldr r3, [r4, #0] 802985a: b1e3 cbz r3, 8029896 { vTaskSuspendAll(); 802985c: f7ff fef0 bl 8029640 { xListIsEmpty = listLIST_IS_EMPTY( &xTasksWaitingTermination ); 8029860: 6835 ldr r5, [r6, #0] } ( void ) xTaskResumeAll(); 8029862: f7ff ff89 bl 8029778 if( xListIsEmpty == pdFALSE ) 8029866: 2d00 cmp r5, #0 8029868: d0f6 beq.n 8029858 { TCB_t *pxTCB; taskENTER_CRITICAL(); 802986a: f000 fbed bl 802a048 { pxTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( ( &xTasksWaitingTermination ) ); 802986e: 68f3 ldr r3, [r6, #12] 8029870: 68dd ldr r5, [r3, #12] ( void ) uxListRemove( &( pxTCB->xGenericListItem ) ); 8029872: 1d28 adds r0, r5, #4 8029874: f7ff fa3e bl 8028cf4 --uxCurrentNumberOfTasks; 8029878: 683b ldr r3, [r7, #0] 802987a: 3b01 subs r3, #1 802987c: 603b str r3, [r7, #0] --uxTasksDeleted; 802987e: 6823 ldr r3, [r4, #0] 8029880: 3b01 subs r3, #1 8029882: 6023 str r3, [r4, #0] } taskEXIT_CRITICAL(); 8029884: f000 fc0c bl 802a0a0 vPortFreeAligned( pxTCB->pxStack ); } } #else { vPortFreeAligned( pxTCB->pxStack ); 8029888: 6b28 ldr r0, [r5, #48] ; 0x30 802988a: f000 fd71 bl 802a370 } #endif vPortFree( pxTCB ); 802988e: 4628 mov r0, r5 8029890: f000 fd6e bl 802a370 8029894: e7e0 b.n 8029858 A critical region is not required here as we are just reading from the list, and an occasional incorrect value will not matter. If the ready list at the idle priority contains more than one task then a task other than the idle task is ready to execute. */ if( listCURRENT_LIST_LENGTH( &( pxReadyTasksLists[ tskIDLE_PRIORITY ] ) ) > ( UBaseType_t ) 1 ) 8029896: 4b06 ldr r3, [pc, #24] ; (80298b0 ) 8029898: 681b ldr r3, [r3, #0] 802989a: 2b01 cmp r3, #1 802989c: d9dc bls.n 8029858 { taskYIELD(); 802989e: f000 fbbf bl 802a020 80298a2: e7d9 b.n 8029858 80298a4: 200028f0 .word 0x200028f0 80298a8: 20002984 .word 0x20002984 80298ac: 200029c0 .word 0x200029c0 80298b0: 20002920 .word 0x20002920 080298b4 : /*-----------------------------------------------------------*/ #if ( INCLUDE_vTaskDelay == 1 ) void vTaskDelay( const TickType_t xTicksToDelay ) { 80298b4: b538 push {r3, r4, r5, lr} TickType_t xTimeToWake; BaseType_t xAlreadyYielded = pdFALSE; /* A delay time of zero just forces a reschedule. */ if( xTicksToDelay > ( TickType_t ) 0U ) 80298b6: 4604 mov r4, r0 80298b8: b918 cbnz r0, 80298c2 } else { mtCOVERAGE_TEST_MARKER(); } } 80298ba: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} /* Force a reschedule if xTaskResumeAll has not already done so, we may have put ourselves to sleep. */ if( xAlreadyYielded == pdFALSE ) { portYIELD_WITHIN_API(); 80298be: f000 bbaf b.w 802a020 /* A delay time of zero just forces a reschedule. */ if( xTicksToDelay > ( TickType_t ) 0U ) { configASSERT( uxSchedulerSuspended == 0 ); 80298c2: 4b11 ldr r3, [pc, #68] ; (8029908 ) 80298c4: 681b ldr r3, [r3, #0] 80298c6: b113 cbz r3, 80298ce 80298c8: f000 fbb6 bl 802a038 80298cc: e7fe b.n 80298cc vTaskSuspendAll(); 80298ce: f7ff feb7 bl 8029640 This task cannot be in an event list as it is the currently executing task. */ /* Calculate the time to wake - this may overflow but this is not a problem. */ xTimeToWake = xTickCount + xTicksToDelay; 80298d2: 4b0e ldr r3, [pc, #56] ; (802990c ) 80298d4: 681d ldr r5, [r3, #0] 80298d6: 1965 adds r5, r4, r5 /* We must remove ourselves from the ready list before adding ourselves to the blocked list as the same list item is used for both lists. */ if( uxListRemove( &( pxCurrentTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 80298d8: 4c0d ldr r4, [pc, #52] ; (8029910 ) 80298da: 6820 ldr r0, [r4, #0] 80298dc: 3004 adds r0, #4 80298de: f7ff fa09 bl 8028cf4 80298e2: b948 cbnz r0, 80298f8 { /* The current task must be in a ready list, so there is no need to check, and the port reset macro can be called directly. */ portRESET_READY_PRIORITY( pxCurrentTCB->uxPriority, uxTopReadyPriority ); 80298e4: 4b0b ldr r3, [pc, #44] ; (8029914 ) 80298e6: 6819 ldr r1, [r3, #0] 80298e8: 6822 ldr r2, [r4, #0] 80298ea: 6ad2 ldr r2, [r2, #44] ; 0x2c 80298ec: 2001 movs r0, #1 80298ee: fa00 f202 lsl.w r2, r0, r2 80298f2: ea21 0202 bic.w r2, r1, r2 80298f6: 601a str r2, [r3, #0] } else { mtCOVERAGE_TEST_MARKER(); } prvAddCurrentTaskToDelayedList( xTimeToWake ); 80298f8: 4628 mov r0, r5 80298fa: f7ff fd19 bl 8029330 } xAlreadyYielded = xTaskResumeAll(); 80298fe: f7ff ff3b bl 8029778 mtCOVERAGE_TEST_MARKER(); } /* Force a reschedule if xTaskResumeAll has not already done so, we may have put ourselves to sleep. */ if( xAlreadyYielded == pdFALSE ) 8029902: 2800 cmp r0, #0 8029904: d0d9 beq.n 80298ba } else { mtCOVERAGE_TEST_MARKER(); } } 8029906: bd38 pop {r3, r4, r5, pc} 8029908: 200029b0 .word 0x200029b0 802990c: 200029b4 .word 0x200029b4 8029910: 20002998 .word 0x20002998 8029914: 200029d8 .word 0x200029d8 08029918 : #endif /* configUSE_APPLICATION_TASK_TAG */ /*-----------------------------------------------------------*/ void vTaskSwitchContext( void ) { 8029918: b508 push {r3, lr} if( uxSchedulerSuspended != ( UBaseType_t ) pdFALSE ) 802991a: 4b12 ldr r3, [pc, #72] ; (8029964 ) 802991c: 681a ldr r2, [r3, #0] 802991e: 4b12 ldr r3, [pc, #72] ; (8029968 ) 8029920: b10a cbz r2, 8029926 { /* The scheduler is currently suspended - do not allow a context switch. */ xYieldPending = pdTRUE; 8029922: 2201 movs r2, #1 8029924: e01c b.n 8029960 } else { xYieldPending = pdFALSE; 8029926: 601a str r2, [r3, #0] taskFIRST_CHECK_FOR_STACK_OVERFLOW(); taskSECOND_CHECK_FOR_STACK_OVERFLOW(); /* Select a new task to run using either the generic C or port optimised asm code. */ taskSELECT_HIGHEST_PRIORITY_TASK(); 8029928: 4b10 ldr r3, [pc, #64] ; (802996c ) 802992a: 681a ldr r2, [r3, #0] /* Generic helper function. */ __attribute__( ( always_inline ) ) static inline uint8_t ucPortCountLeadingZeros( uint32_t ulBitmap ) { uint8_t ucReturn; __asm volatile ( "clz %0, %1" : "=r" ( ucReturn ) : "r" ( ulBitmap ) ); 802992c: fab2 f282 clz r2, r2 8029930: b2d2 uxtb r2, r2 8029932: 2314 movs r3, #20 8029934: f1c2 021f rsb r2, r2, #31 8029938: 490d ldr r1, [pc, #52] ; (8029970 ) 802993a: 435a muls r2, r3 802993c: 188b adds r3, r1, r2 802993e: 588a ldr r2, [r1, r2] 8029940: b912 cbnz r2, 8029948 8029942: f000 fb79 bl 802a038 8029946: e7fe b.n 8029946 8029948: 685a ldr r2, [r3, #4] 802994a: 6852 ldr r2, [r2, #4] 802994c: f103 0108 add.w r1, r3, #8 8029950: 428a cmp r2, r1 8029952: 605a str r2, [r3, #4] 8029954: bf04 itt eq 8029956: 6852 ldreq r2, [r2, #4] 8029958: 605a streq r2, [r3, #4] 802995a: 685b ldr r3, [r3, #4] 802995c: 68da ldr r2, [r3, #12] 802995e: 4b05 ldr r3, [pc, #20] ; (8029974 ) 8029960: 601a str r2, [r3, #0] 8029962: bd08 pop {r3, pc} 8029964: 200029b0 .word 0x200029b0 8029968: 200029dc .word 0x200029dc 802996c: 200029d8 .word 0x200029d8 8029970: 20002920 .word 0x20002920 8029974: 20002998 .word 0x20002998 08029978 : } } /*-----------------------------------------------------------*/ void vTaskPlaceOnEventList( List_t * const pxEventList, const TickType_t xTicksToWait ) { 8029978: b538 push {r3, r4, r5, lr} 802997a: 460d mov r5, r1 TickType_t xTimeToWake; configASSERT( pxEventList ); 802997c: b910 cbnz r0, 8029984 802997e: f000 fb5b bl 802a038 8029982: e7fe b.n 8029982 /* Place the event list item of the TCB in the appropriate event list. This is placed in the list in priority order so the highest priority task is the first to be woken by the event. The queue that contains the event list is locked, preventing simultaneous access from interrupts. */ vListInsert( pxEventList, &( pxCurrentTCB->xEventListItem ) ); 8029984: 4c12 ldr r4, [pc, #72] ; (80299d0 ) 8029986: 6821 ldr r1, [r4, #0] 8029988: 3118 adds r1, #24 802998a: f7ff f99b bl 8028cc4 /* The task must be removed from from the ready list before it is added to the blocked list as the same list item is used for both lists. Exclusive access to the ready lists guaranteed because the scheduler is locked. */ if( uxListRemove( &( pxCurrentTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 802998e: 6820 ldr r0, [r4, #0] 8029990: 3004 adds r0, #4 8029992: f7ff f9af bl 8028cf4 8029996: b948 cbnz r0, 80299ac { /* The current task must be in a ready list, so there is no need to check, and the port reset macro can be called directly. */ portRESET_READY_PRIORITY( pxCurrentTCB->uxPriority, uxTopReadyPriority ); 8029998: 4b0e ldr r3, [pc, #56] ; (80299d4 ) 802999a: 6819 ldr r1, [r3, #0] 802999c: 6822 ldr r2, [r4, #0] 802999e: 6ad2 ldr r2, [r2, #44] ; 0x2c 80299a0: 2001 movs r0, #1 80299a2: fa00 f202 lsl.w r2, r0, r2 80299a6: ea21 0202 bic.w r2, r1, r2 80299aa: 601a str r2, [r3, #0] mtCOVERAGE_TEST_MARKER(); } #if ( INCLUDE_vTaskSuspend == 1 ) { if( xTicksToWait == portMAX_DELAY ) 80299ac: 1c69 adds r1, r5, #1 80299ae: d107 bne.n 80299c0 { /* Add the task to the suspended task list instead of a delayed task list to ensure the task is not woken by a timing event. It will block indefinitely. */ vListInsertEnd( &xSuspendedTaskList, &( pxCurrentTCB->xGenericListItem ) ); 80299b0: 4b07 ldr r3, [pc, #28] ; (80299d0 ) 80299b2: 4809 ldr r0, [pc, #36] ; (80299d8 ) 80299b4: 6819 ldr r1, [r3, #0] 80299b6: 3104 adds r1, #4 will handle it. */ xTimeToWake = xTickCount + xTicksToWait; prvAddCurrentTaskToDelayedList( xTimeToWake ); } #endif /* INCLUDE_vTaskSuspend */ } 80299b8: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} if( xTicksToWait == portMAX_DELAY ) { /* Add the task to the suspended task list instead of a delayed task list to ensure the task is not woken by a timing event. It will block indefinitely. */ vListInsertEnd( &xSuspendedTaskList, &( pxCurrentTCB->xGenericListItem ) ); 80299bc: f7ff b976 b.w 8028cac else { /* Calculate the time at which the task should be woken if the event does not occur. This may overflow but this doesn't matter, the scheduler will handle it. */ xTimeToWake = xTickCount + xTicksToWait; 80299c0: 4b06 ldr r3, [pc, #24] ; (80299dc ) 80299c2: 6818 ldr r0, [r3, #0] prvAddCurrentTaskToDelayedList( xTimeToWake ); 80299c4: 1828 adds r0, r5, r0 will handle it. */ xTimeToWake = xTickCount + xTicksToWait; prvAddCurrentTaskToDelayedList( xTimeToWake ); } #endif /* INCLUDE_vTaskSuspend */ } 80299c6: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} { /* Calculate the time at which the task should be woken if the event does not occur. This may overflow but this doesn't matter, the scheduler will handle it. */ xTimeToWake = xTickCount + xTicksToWait; prvAddCurrentTaskToDelayedList( xTimeToWake ); 80299ca: f7ff bcb1 b.w 8029330 80299ce: bf00 nop 80299d0: 20002998 .word 0x20002998 80299d4: 200029d8 .word 0x200029d8 80299d8: 200029c4 .word 0x200029c4 80299dc: 200029b4 .word 0x200029b4 080299e0 : /*-----------------------------------------------------------*/ #if configUSE_TIMERS == 1 void vTaskPlaceOnEventListRestricted( List_t * const pxEventList, const TickType_t xTicksToWait ) { 80299e0: b538 push {r3, r4, r5, lr} 80299e2: 460d mov r5, r1 TickType_t xTimeToWake; configASSERT( pxEventList ); 80299e4: b910 cbnz r0, 80299ec 80299e6: f000 fb27 bl 802a038 80299ea: e7fe b.n 80299ea /* Place the event list item of the TCB in the appropriate event list. In this case it is assume that this is the only task that is going to be waiting on this event list, so the faster vListInsertEnd() function can be used in place of vListInsert. */ vListInsertEnd( pxEventList, &( pxCurrentTCB->xEventListItem ) ); 80299ec: 4c0d ldr r4, [pc, #52] ; (8029a24 ) 80299ee: 6821 ldr r1, [r4, #0] 80299f0: 3118 adds r1, #24 80299f2: f7ff f95b bl 8028cac /* We must remove this task from the ready list before adding it to the blocked list as the same list item is used for both lists. This function is called form a critical section. */ if( uxListRemove( &( pxCurrentTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 80299f6: 6820 ldr r0, [r4, #0] 80299f8: 3004 adds r0, #4 80299fa: f7ff f97b bl 8028cf4 80299fe: b948 cbnz r0, 8029a14 { /* The current task must be in a ready list, so there is no need to check, and the port reset macro can be called directly. */ portRESET_READY_PRIORITY( pxCurrentTCB->uxPriority, uxTopReadyPriority ); 8029a00: 4b09 ldr r3, [pc, #36] ; (8029a28 ) 8029a02: 6819 ldr r1, [r3, #0] 8029a04: 6822 ldr r2, [r4, #0] 8029a06: 6ad2 ldr r2, [r2, #44] ; 0x2c 8029a08: 2001 movs r0, #1 8029a0a: fa00 f202 lsl.w r2, r0, r2 8029a0e: ea21 0202 bic.w r2, r1, r2 8029a12: 601a str r2, [r3, #0] mtCOVERAGE_TEST_MARKER(); } /* Calculate the time at which the task should be woken if the event does not occur. This may overflow but this doesn't matter. */ xTimeToWake = xTickCount + xTicksToWait; 8029a14: 4b05 ldr r3, [pc, #20] ; (8029a2c ) 8029a16: 6818 ldr r0, [r3, #0] traceTASK_DELAY_UNTIL(); prvAddCurrentTaskToDelayedList( xTimeToWake ); 8029a18: 1828 adds r0, r5, r0 } 8029a1a: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} /* Calculate the time at which the task should be woken if the event does not occur. This may overflow but this doesn't matter. */ xTimeToWake = xTickCount + xTicksToWait; traceTASK_DELAY_UNTIL(); prvAddCurrentTaskToDelayedList( xTimeToWake ); 8029a1e: f7ff bc87 b.w 8029330 8029a22: bf00 nop 8029a24: 20002998 .word 0x20002998 8029a28: 200029d8 .word 0x200029d8 8029a2c: 200029b4 .word 0x200029b4 08029a30 : #endif /* configUSE_TIMERS */ /*-----------------------------------------------------------*/ BaseType_t xTaskRemoveFromEventList( const List_t * const pxEventList ) { 8029a30: b538 push {r3, r4, r5, lr} get called - the lock count on the queue will get modified instead. This means exclusive access to the event list is guaranteed here. This function assumes that a check has already been made to ensure that pxEventList is not empty. */ pxUnblockedTCB = ( TCB_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxEventList ); 8029a32: 68c3 ldr r3, [r0, #12] 8029a34: 68dc ldr r4, [r3, #12] configASSERT( pxUnblockedTCB ); 8029a36: b914 cbnz r4, 8029a3e 8029a38: f000 fafe bl 802a038 8029a3c: e7fe b.n 8029a3c ( void ) uxListRemove( &( pxUnblockedTCB->xEventListItem ) ); 8029a3e: f104 0518 add.w r5, r4, #24 8029a42: 4628 mov r0, r5 8029a44: f7ff f956 bl 8028cf4 if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) 8029a48: 4b11 ldr r3, [pc, #68] ; (8029a90 ) 8029a4a: 681b ldr r3, [r3, #0] 8029a4c: b983 cbnz r3, 8029a70 { ( void ) uxListRemove( &( pxUnblockedTCB->xGenericListItem ) ); 8029a4e: 1d25 adds r5, r4, #4 8029a50: 4628 mov r0, r5 8029a52: f7ff f94f bl 8028cf4 prvAddTaskToReadyList( pxUnblockedTCB ); 8029a56: 4a0f ldr r2, [pc, #60] ; (8029a94 ) 8029a58: 6ae3 ldr r3, [r4, #44] ; 0x2c 8029a5a: 6810 ldr r0, [r2, #0] 8029a5c: 2101 movs r1, #1 8029a5e: fa01 f103 lsl.w r1, r1, r3 8029a62: 4301 orrs r1, r0 8029a64: 6011 str r1, [r2, #0] 8029a66: 4a0c ldr r2, [pc, #48] ; (8029a98 ) 8029a68: 2014 movs r0, #20 8029a6a: fb00 2003 mla r0, r0, r3, r2 8029a6e: e000 b.n 8029a72 } else { /* The delayed and ready lists cannot be accessed, so hold this task pending until the scheduler is resumed. */ vListInsertEnd( &( xPendingReadyList ), &( pxUnblockedTCB->xEventListItem ) ); 8029a70: 480a ldr r0, [pc, #40] ; (8029a9c ) 8029a72: 4629 mov r1, r5 8029a74: f7ff f91a bl 8028cac } if( pxUnblockedTCB->uxPriority > pxCurrentTCB->uxPriority ) 8029a78: 4b09 ldr r3, [pc, #36] ; (8029aa0 ) 8029a7a: 6ae2 ldr r2, [r4, #44] ; 0x2c 8029a7c: 681b ldr r3, [r3, #0] 8029a7e: 6adb ldr r3, [r3, #44] ; 0x2c 8029a80: 429a cmp r2, r3 8029a82: d903 bls.n 8029a8c it should force a context switch now. */ xReturn = pdTRUE; /* Mark that a yield is pending in case the user is not using the "xHigherPriorityTaskWoken" parameter to an ISR safe FreeRTOS function. */ xYieldPending = pdTRUE; 8029a84: 4b07 ldr r3, [pc, #28] ; (8029aa4 ) 8029a86: 2001 movs r0, #1 8029a88: 6018 str r0, [r3, #0] 8029a8a: bd38 pop {r3, r4, r5, pc} } else { xReturn = pdFALSE; 8029a8c: 2000 movs r0, #0 prvResetNextTaskUnblockTime(); } #endif return xReturn; } 8029a8e: bd38 pop {r3, r4, r5, pc} 8029a90: 200029b0 .word 0x200029b0 8029a94: 200029d8 .word 0x200029d8 8029a98: 20002920 .word 0x20002920 8029a9c: 2000299c .word 0x2000299c 8029aa0: 20002998 .word 0x20002998 8029aa4: 200029dc .word 0x200029dc 08029aa8 : return xReturn; } /*-----------------------------------------------------------*/ void vTaskSetTimeOutState( TimeOut_t * const pxTimeOut ) { 8029aa8: b508 push {r3, lr} configASSERT( pxTimeOut ); 8029aaa: b910 cbnz r0, 8029ab2 8029aac: f000 fac4 bl 802a038 8029ab0: e7fe b.n 8029ab0 pxTimeOut->xOverflowCount = xNumOfOverflows; 8029ab2: 4b03 ldr r3, [pc, #12] ; (8029ac0 ) 8029ab4: 681b ldr r3, [r3, #0] 8029ab6: 6003 str r3, [r0, #0] pxTimeOut->xTimeOnEntering = xTickCount; 8029ab8: 4b02 ldr r3, [pc, #8] ; (8029ac4 ) 8029aba: 681b ldr r3, [r3, #0] 8029abc: 6043 str r3, [r0, #4] 8029abe: bd08 pop {r3, pc} 8029ac0: 200028e4 .word 0x200028e4 8029ac4: 200029b4 .word 0x200029b4 08029ac8 : } /*-----------------------------------------------------------*/ BaseType_t xTaskCheckForTimeOut( TimeOut_t * const pxTimeOut, TickType_t * const pxTicksToWait ) { 8029ac8: b538 push {r3, r4, r5, lr} 8029aca: 460d mov r5, r1 BaseType_t xReturn; configASSERT( pxTimeOut ); 8029acc: 4604 mov r4, r0 8029ace: b910 cbnz r0, 8029ad6 8029ad0: f000 fab2 bl 802a038 8029ad4: e7fe b.n 8029ad4 configASSERT( pxTicksToWait ); 8029ad6: b911 cbnz r1, 8029ade 8029ad8: f000 faae bl 802a038 8029adc: e7fe b.n 8029adc taskENTER_CRITICAL(); 8029ade: f000 fab3 bl 802a048 { /* Minor optimisation. The tick count cannot change in this block. */ const TickType_t xConstTickCount = xTickCount; 8029ae2: 4b0e ldr r3, [pc, #56] ; (8029b1c ) 8029ae4: 681a ldr r2, [r3, #0] #if ( INCLUDE_vTaskSuspend == 1 ) /* If INCLUDE_vTaskSuspend is set to 1 and the block time specified is the maximum block time then the task should block indefinitely, and therefore never time out. */ if( *pxTicksToWait == portMAX_DELAY ) 8029ae6: 682b ldr r3, [r5, #0] 8029ae8: 1c59 adds r1, r3, #1 8029aea: d010 beq.n 8029b0e xReturn = pdFALSE; } else /* We are not blocking indefinitely, perform the checks below. */ #endif if( ( xNumOfOverflows != pxTimeOut->xOverflowCount ) && ( xConstTickCount >= pxTimeOut->xTimeOnEntering ) ) /*lint !e525 Indentation preferred as is to make code within pre-processor directives clearer. */ 8029aec: 490c ldr r1, [pc, #48] ; (8029b20 ) 8029aee: 6808 ldr r0, [r1, #0] 8029af0: 6821 ldr r1, [r4, #0] 8029af2: 4288 cmp r0, r1 8029af4: 6861 ldr r1, [r4, #4] 8029af6: d001 beq.n 8029afc 8029af8: 428a cmp r2, r1 8029afa: d20a bcs.n 8029b12 was called, but has also overflowed since vTaskSetTimeOut() was called. It must have wrapped all the way around and gone past us again. This passed since vTaskSetTimeout() was called. */ xReturn = pdTRUE; } else if( ( xConstTickCount - pxTimeOut->xTimeOnEntering ) < *pxTicksToWait ) 8029afc: 1a50 subs r0, r2, r1 8029afe: 4298 cmp r0, r3 8029b00: d207 bcs.n 8029b12 { /* Not a genuine timeout. Adjust parameters for time remaining. */ *pxTicksToWait -= ( xConstTickCount - pxTimeOut->xTimeOnEntering ); 8029b02: 1a8a subs r2, r1, r2 8029b04: 18d3 adds r3, r2, r3 8029b06: 602b str r3, [r5, #0] vTaskSetTimeOutState( pxTimeOut ); 8029b08: 4620 mov r0, r4 8029b0a: f7ff ffcd bl 8029aa8 /* If INCLUDE_vTaskSuspend is set to 1 and the block time specified is the maximum block time then the task should block indefinitely, and therefore never time out. */ if( *pxTicksToWait == portMAX_DELAY ) { xReturn = pdFALSE; 8029b0e: 2400 movs r4, #0 8029b10: e000 b.n 8029b14 { /* The tick count is greater than the time at which vTaskSetTimeout() was called, but has also overflowed since vTaskSetTimeOut() was called. It must have wrapped all the way around and gone past us again. This passed since vTaskSetTimeout() was called. */ xReturn = pdTRUE; 8029b12: 2401 movs r4, #1 else { xReturn = pdTRUE; } } taskEXIT_CRITICAL(); 8029b14: f000 fac4 bl 802a0a0 return xReturn; } 8029b18: 4620 mov r0, r4 8029b1a: bd38 pop {r3, r4, r5, pc} 8029b1c: 200029b4 .word 0x200029b4 8029b20: 200028e4 .word 0x200028e4 08029b24 : /*-----------------------------------------------------------*/ void vTaskMissedYield( void ) { xYieldPending = pdTRUE; 8029b24: 4b01 ldr r3, [pc, #4] ; (8029b2c ) 8029b26: 2201 movs r2, #1 8029b28: 601a str r2, [r3, #0] 8029b2a: 4770 bx lr 8029b2c: 200029dc .word 0x200029dc 08029b30 : BaseType_t xTaskGetSchedulerState( void ) { BaseType_t xReturn; if( xSchedulerRunning == pdFALSE ) 8029b30: 4b05 ldr r3, [pc, #20] ; (8029b48 ) 8029b32: 681b ldr r3, [r3, #0] 8029b34: b133 cbz r3, 8029b44 { xReturn = taskSCHEDULER_NOT_STARTED; } else { if( uxSchedulerSuspended == ( UBaseType_t ) pdFALSE ) 8029b36: 4b05 ldr r3, [pc, #20] ; (8029b4c ) 8029b38: 6818 ldr r0, [r3, #0] { xReturn = taskSCHEDULER_RUNNING; 8029b3a: 2800 cmp r0, #0 8029b3c: bf0c ite eq 8029b3e: 2002 moveq r0, #2 8029b40: 2000 movne r0, #0 8029b42: 4770 bx lr { BaseType_t xReturn; if( xSchedulerRunning == pdFALSE ) { xReturn = taskSCHEDULER_NOT_STARTED; 8029b44: 2001 movs r0, #1 xReturn = taskSCHEDULER_SUSPENDED; } } return xReturn; } 8029b46: 4770 bx lr 8029b48: 200028ec .word 0x200028ec 8029b4c: 200029b0 .word 0x200029b0 08029b50 : /*-----------------------------------------------------------*/ #if ( configUSE_MUTEXES == 1 ) void vTaskPriorityInherit( TaskHandle_t const pxMutexHolder ) { 8029b50: b5f8 push {r3, r4, r5, r6, r7, lr} TCB_t * const pxTCB = ( TCB_t * ) pxMutexHolder; /* If the mutex was given back by an interrupt while the queue was locked then the mutex holder might now be NULL. */ if( pxMutexHolder != NULL ) 8029b52: 4604 mov r4, r0 8029b54: 2800 cmp r0, #0 8029b56: d040 beq.n 8029bda { if( pxTCB->uxPriority < pxCurrentTCB->uxPriority ) 8029b58: 4a20 ldr r2, [pc, #128] ; (8029bdc ) 8029b5a: 6ac3 ldr r3, [r0, #44] ; 0x2c 8029b5c: 6811 ldr r1, [r2, #0] 8029b5e: 6ac9 ldr r1, [r1, #44] ; 0x2c 8029b60: 428b cmp r3, r1 8029b62: d23a bcs.n 8029bda { /* Adjust the mutex holder state to account for its new priority. Only reset the event list item value if the value is not being used for anything else. */ if( ( listGET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ) ) & taskEVENT_LIST_ITEM_VALUE_IN_USE ) == 0UL ) 8029b64: 6981 ldr r1, [r0, #24] 8029b66: 2900 cmp r1, #0 8029b68: db04 blt.n 8029b74 { listSET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ), ( TickType_t ) configMAX_PRIORITIES - ( TickType_t ) pxCurrentTCB->uxPriority ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 8029b6a: 6812 ldr r2, [r2, #0] 8029b6c: 6ad2 ldr r2, [r2, #44] ; 0x2c 8029b6e: f1c2 0205 rsb r2, r2, #5 8029b72: 6182 str r2, [r0, #24] mtCOVERAGE_TEST_MARKER(); } /* If the task being modified is in the ready state it will need to be moved into a new list. */ if( listIS_CONTAINED_WITHIN( &( pxReadyTasksLists[ pxTCB->uxPriority ] ), &( pxTCB->xGenericListItem ) ) != pdFALSE ) 8029b74: 4e1a ldr r6, [pc, #104] ; (8029be0 ) 8029b76: 6962 ldr r2, [r4, #20] 8029b78: 2714 movs r7, #20 8029b7a: fb07 6303 mla r3, r7, r3, r6 8029b7e: 429a cmp r2, r3 8029b80: d127 bne.n 8029bd2 8029b82: e01f b.n 8029bc4 { if( uxListRemove( &( pxTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) { taskRESET_READY_PRIORITY( pxTCB->uxPriority ); 8029b84: 6ae2 ldr r2, [r4, #44] ; 0x2c 8029b86: 4357 muls r7, r2 8029b88: 59f3 ldr r3, [r6, r7] 8029b8a: b93b cbnz r3, 8029b9c 8029b8c: 4b15 ldr r3, [pc, #84] ; (8029be4 ) 8029b8e: 2001 movs r0, #1 8029b90: 6819 ldr r1, [r3, #0] 8029b92: fa00 f202 lsl.w r2, r0, r2 8029b96: ea21 0202 bic.w r2, r1, r2 8029b9a: 601a str r2, [r3, #0] { mtCOVERAGE_TEST_MARKER(); } /* Inherit the priority before being moved into the new list. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; 8029b9c: 4b0f ldr r3, [pc, #60] ; (8029bdc ) prvAddTaskToReadyList( pxTCB ); 8029b9e: 4a11 ldr r2, [pc, #68] ; (8029be4 ) { mtCOVERAGE_TEST_MARKER(); } /* Inherit the priority before being moved into the new list. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; 8029ba0: 681b ldr r3, [r3, #0] prvAddTaskToReadyList( pxTCB ); 8029ba2: 6810 ldr r0, [r2, #0] { mtCOVERAGE_TEST_MARKER(); } /* Inherit the priority before being moved into the new list. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; 8029ba4: 6adb ldr r3, [r3, #44] ; 0x2c prvAddTaskToReadyList( pxTCB ); 8029ba6: 2101 movs r1, #1 8029ba8: fa01 f103 lsl.w r1, r1, r3 8029bac: 4301 orrs r1, r0 8029bae: 6011 str r1, [r2, #0] 8029bb0: 4a0b ldr r2, [pc, #44] ; (8029be0 ) { mtCOVERAGE_TEST_MARKER(); } /* Inherit the priority before being moved into the new list. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; 8029bb2: 62e3 str r3, [r4, #44] ; 0x2c prvAddTaskToReadyList( pxTCB ); 8029bb4: 2014 movs r0, #20 8029bb6: fb00 2003 mla r0, r0, r3, r2 8029bba: 4629 mov r1, r5 } else { mtCOVERAGE_TEST_MARKER(); } } 8029bbc: e8bd 40f8 ldmia.w sp!, {r3, r4, r5, r6, r7, lr} mtCOVERAGE_TEST_MARKER(); } /* Inherit the priority before being moved into the new list. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; prvAddTaskToReadyList( pxTCB ); 8029bc0: f7ff b874 b.w 8028cac /* If the task being modified is in the ready state it will need to be moved into a new list. */ if( listIS_CONTAINED_WITHIN( &( pxReadyTasksLists[ pxTCB->uxPriority ] ), &( pxTCB->xGenericListItem ) ) != pdFALSE ) { if( uxListRemove( &( pxTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 8029bc4: 1d25 adds r5, r4, #4 8029bc6: 4628 mov r0, r5 8029bc8: f7ff f894 bl 8028cf4 8029bcc: 2800 cmp r0, #0 8029bce: d0d9 beq.n 8029b84 8029bd0: e7e4 b.n 8029b9c prvAddTaskToReadyList( pxTCB ); } else { /* Just inherit the priority. */ pxTCB->uxPriority = pxCurrentTCB->uxPriority; 8029bd2: 4b02 ldr r3, [pc, #8] ; (8029bdc ) 8029bd4: 681b ldr r3, [r3, #0] 8029bd6: 6adb ldr r3, [r3, #44] ; 0x2c 8029bd8: 62e3 str r3, [r4, #44] ; 0x2c 8029bda: bdf8 pop {r3, r4, r5, r6, r7, pc} 8029bdc: 20002998 .word 0x20002998 8029be0: 20002920 .word 0x20002920 8029be4: 200029d8 .word 0x200029d8 08029be8 : /*-----------------------------------------------------------*/ #if ( configUSE_MUTEXES == 1 ) BaseType_t xTaskPriorityDisinherit( TaskHandle_t const pxMutexHolder ) { 8029be8: b538 push {r3, r4, r5, lr} TCB_t * const pxTCB = ( TCB_t * ) pxMutexHolder; BaseType_t xReturn = pdFALSE; if( pxMutexHolder != NULL ) 8029bea: 4604 mov r4, r0 8029bec: b908 cbnz r0, 8029bf2 #if ( configUSE_MUTEXES == 1 ) BaseType_t xTaskPriorityDisinherit( TaskHandle_t const pxMutexHolder ) { TCB_t * const pxTCB = ( TCB_t * ) pxMutexHolder; BaseType_t xReturn = pdFALSE; 8029bee: 2000 movs r0, #0 8029bf0: bd38 pop {r3, r4, r5, pc} if( pxMutexHolder != NULL ) { configASSERT( pxTCB->uxMutexesHeld ); 8029bf2: 6d03 ldr r3, [r0, #80] ; 0x50 8029bf4: b913 cbnz r3, 8029bfc 8029bf6: f000 fa1f bl 802a038 8029bfa: e7fe b.n 8029bfa ( pxTCB->uxMutexesHeld )--; if( pxTCB->uxPriority != pxTCB->uxBasePriority ) 8029bfc: 6ac1 ldr r1, [r0, #44] ; 0x2c 8029bfe: 6cc2 ldr r2, [r0, #76] ; 0x4c BaseType_t xReturn = pdFALSE; if( pxMutexHolder != NULL ) { configASSERT( pxTCB->uxMutexesHeld ); ( pxTCB->uxMutexesHeld )--; 8029c00: 3b01 subs r3, #1 if( pxTCB->uxPriority != pxTCB->uxBasePriority ) 8029c02: 4291 cmp r1, r2 BaseType_t xReturn = pdFALSE; if( pxMutexHolder != NULL ) { configASSERT( pxTCB->uxMutexesHeld ); ( pxTCB->uxMutexesHeld )--; 8029c04: 6503 str r3, [r0, #80] ; 0x50 if( pxTCB->uxPriority != pxTCB->uxBasePriority ) 8029c06: d0f2 beq.n 8029bee { /* Only disinherit if no other mutexes are held. */ if( pxTCB->uxMutexesHeld == ( UBaseType_t ) 0 ) 8029c08: 2b00 cmp r3, #0 8029c0a: d1f0 bne.n 8029bee /* A task can only have an inhertied priority if it holds the mutex. If the mutex is held by a task then it cannot be given from an interrupt, and if a mutex is given by the holding task then it must be the running state task. Remove the holding task from the ready list. */ if( uxListRemove( &( pxTCB->xGenericListItem ) ) == ( UBaseType_t ) 0 ) 8029c0c: 1d05 adds r5, r0, #4 8029c0e: 4628 mov r0, r5 8029c10: f7ff f870 bl 8028cf4 8029c14: b968 cbnz r0, 8029c32 { taskRESET_READY_PRIORITY( pxTCB->uxPriority ); 8029c16: 6ae2 ldr r2, [r4, #44] ; 0x2c 8029c18: 4910 ldr r1, [pc, #64] ; (8029c5c ) 8029c1a: 2314 movs r3, #20 8029c1c: 4353 muls r3, r2 8029c1e: 58cb ldr r3, [r1, r3] 8029c20: b93b cbnz r3, 8029c32 8029c22: 4b0f ldr r3, [pc, #60] ; (8029c60 ) 8029c24: 2001 movs r0, #1 8029c26: 6819 ldr r1, [r3, #0] 8029c28: fa00 f202 lsl.w r2, r0, r2 8029c2c: ea21 0202 bic.w r2, r1, r2 8029c30: 601a str r2, [r3, #0] } /* Disinherit the priority before adding the task into the new ready list. */ traceTASK_PRIORITY_DISINHERIT( pxTCB, pxTCB->uxBasePriority ); pxTCB->uxPriority = pxTCB->uxBasePriority; 8029c32: 6ce3 ldr r3, [r4, #76] ; 0x4c /* Reset the event list item value. It cannot be in use for any other purpose if this task is running, and it must be running to give back the mutex. */ listSET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ), ( TickType_t ) configMAX_PRIORITIES - ( TickType_t ) pxTCB->uxPriority ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ 8029c34: f1c3 0205 rsb r2, r3, #5 8029c38: 61a2 str r2, [r4, #24] prvAddTaskToReadyList( pxTCB ); 8029c3a: 4a09 ldr r2, [pc, #36] ; (8029c60 ) } /* Disinherit the priority before adding the task into the new ready list. */ traceTASK_PRIORITY_DISINHERIT( pxTCB, pxTCB->uxBasePriority ); pxTCB->uxPriority = pxTCB->uxBasePriority; 8029c3c: 62e3 str r3, [r4, #44] ; 0x2c /* Reset the event list item value. It cannot be in use for any other purpose if this task is running, and it must be running to give back the mutex. */ listSET_LIST_ITEM_VALUE( &( pxTCB->xEventListItem ), ( TickType_t ) configMAX_PRIORITIES - ( TickType_t ) pxTCB->uxPriority ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */ prvAddTaskToReadyList( pxTCB ); 8029c3e: 6811 ldr r1, [r2, #0] 8029c40: 2401 movs r4, #1 8029c42: fa04 f003 lsl.w r0, r4, r3 8029c46: 4301 orrs r1, r0 8029c48: 6011 str r1, [r2, #0] 8029c4a: 4a04 ldr r2, [pc, #16] ; (8029c5c ) 8029c4c: 2014 movs r0, #20 8029c4e: fb00 2003 mla r0, r0, r3, r2 8029c52: 4629 mov r1, r5 8029c54: f7ff f82a bl 8028cac in an order different to that in which they were taken. If a context switch did not occur when the first mutex was returned, even if a task was waiting on it, then a context switch should occur when the last mutex is returned whether a task is waiting on it or not. */ xReturn = pdTRUE; 8029c58: 4620 mov r0, r4 { mtCOVERAGE_TEST_MARKER(); } return xReturn; } 8029c5a: bd38 pop {r3, r4, r5, pc} 8029c5c: 20002920 .word 0x20002920 8029c60: 200029d8 .word 0x200029d8 08029c64 : void *pvTaskIncrementMutexHeldCount( void ) { /* If xSemaphoreCreateMutex() is called before any tasks have been created then pxCurrentTCB will be NULL. */ if( pxCurrentTCB != NULL ) 8029c64: 4b04 ldr r3, [pc, #16] ; (8029c78 ) 8029c66: 681a ldr r2, [r3, #0] 8029c68: b11a cbz r2, 8029c72 { ( pxCurrentTCB->uxMutexesHeld )++; 8029c6a: 681a ldr r2, [r3, #0] 8029c6c: 6d11 ldr r1, [r2, #80] ; 0x50 8029c6e: 3101 adds r1, #1 8029c70: 6511 str r1, [r2, #80] ; 0x50 } return pxCurrentTCB; 8029c72: 6818 ldr r0, [r3, #0] } 8029c74: 4770 bx lr 8029c76: bf00 nop 8029c78: 20002998 .word 0x20002998 08029c7c : pxOverflowTimerList = pxTemp; } /*-----------------------------------------------------------*/ static void prvCheckForValidListAndQueue( void ) { 8029c7c: b5f8 push {r3, r4, r5, r6, r7, lr} /* Check that the list from which active timers are referenced, and the queue used to communicate with the timer service, have been initialised. */ taskENTER_CRITICAL(); { if( xTimerQueue == NULL ) 8029c7e: 4c0f ldr r4, [pc, #60] ; (8029cbc ) static void prvCheckForValidListAndQueue( void ) { /* Check that the list from which active timers are referenced, and the queue used to communicate with the timer service, have been initialised. */ taskENTER_CRITICAL(); 8029c80: f000 f9e2 bl 802a048 { if( xTimerQueue == NULL ) 8029c84: 6825 ldr r5, [r4, #0] 8029c86: b9ad cbnz r5, 8029cb4 { vListInitialise( &xActiveTimerList1 ); 8029c88: 4f0d ldr r7, [pc, #52] ; (8029cc0 ) vListInitialise( &xActiveTimerList2 ); 8029c8a: 4e0e ldr r6, [pc, #56] ; (8029cc4 ) initialised. */ taskENTER_CRITICAL(); { if( xTimerQueue == NULL ) { vListInitialise( &xActiveTimerList1 ); 8029c8c: 4638 mov r0, r7 8029c8e: f7fe ffff bl 8028c90 vListInitialise( &xActiveTimerList2 ); 8029c92: 4630 mov r0, r6 8029c94: f7fe fffc bl 8028c90 pxCurrentTimerList = &xActiveTimerList1; 8029c98: 4b0b ldr r3, [pc, #44] ; (8029cc8 ) 8029c9a: 601f str r7, [r3, #0] pxOverflowTimerList = &xActiveTimerList2; 8029c9c: 4b0b ldr r3, [pc, #44] ; (8029ccc ) xTimerQueue = xQueueCreate( ( UBaseType_t ) configTIMER_QUEUE_LENGTH, sizeof( DaemonTaskMessage_t ) ); 8029c9e: 200a movs r0, #10 8029ca0: 210c movs r1, #12 8029ca2: 462a mov r2, r5 if( xTimerQueue == NULL ) { vListInitialise( &xActiveTimerList1 ); vListInitialise( &xActiveTimerList2 ); pxCurrentTimerList = &xActiveTimerList1; pxOverflowTimerList = &xActiveTimerList2; 8029ca4: 601e str r6, [r3, #0] xTimerQueue = xQueueCreate( ( UBaseType_t ) configTIMER_QUEUE_LENGTH, sizeof( DaemonTaskMessage_t ) ); 8029ca6: f7ff f8e4 bl 8028e72 8029caa: 6020 str r0, [r4, #0] configASSERT( xTimerQueue ); 8029cac: b910 cbnz r0, 8029cb4 8029cae: f000 f9c3 bl 802a038 8029cb2: e7fe b.n 8029cb2 { mtCOVERAGE_TEST_MARKER(); } } taskEXIT_CRITICAL(); } 8029cb4: e8bd 40f8 ldmia.w sp!, {r3, r4, r5, r6, r7, lr} else { mtCOVERAGE_TEST_MARKER(); } } taskEXIT_CRITICAL(); 8029cb8: f000 b9f2 b.w 802a0a0 8029cbc: 20002a10 .word 0x20002a10 8029cc0: 200029e4 .word 0x200029e4 8029cc4: 200029f8 .word 0x200029f8 8029cc8: 200029e0 .word 0x200029e0 8029ccc: 20002a14 .word 0x20002a14 08029cd0 : return xTimeNow; } /*-----------------------------------------------------------*/ static BaseType_t prvInsertTimerInActiveList( Timer_t * const pxTimer, const TickType_t xNextExpiryTime, const TickType_t xTimeNow, const TickType_t xCommandTime ) { 8029cd0: b510 push {r4, lr} 8029cd2: 4604 mov r4, r0 BaseType_t xProcessTimerNow = pdFALSE; listSET_LIST_ITEM_VALUE( &( pxTimer->xTimerListItem ), xNextExpiryTime ); listSET_LIST_ITEM_OWNER( &( pxTimer->xTimerListItem ), pxTimer ); if( xNextExpiryTime <= xTimeNow ) 8029cd4: 4291 cmp r1, r2 static BaseType_t prvInsertTimerInActiveList( Timer_t * const pxTimer, const TickType_t xNextExpiryTime, const TickType_t xTimeNow, const TickType_t xCommandTime ) { BaseType_t xProcessTimerNow = pdFALSE; listSET_LIST_ITEM_VALUE( &( pxTimer->xTimerListItem ), xNextExpiryTime ); 8029cd6: 6041 str r1, [r0, #4] listSET_LIST_ITEM_OWNER( &( pxTimer->xTimerListItem ), pxTimer ); 8029cd8: 6120 str r0, [r4, #16] if( xNextExpiryTime <= xTimeNow ) 8029cda: d805 bhi.n 8029ce8 { /* Has the expiry time elapsed between the command to start/reset a timer was issued, and the time the command was processed? */ if( ( xTimeNow - xCommandTime ) >= pxTimer->xTimerPeriodInTicks ) 8029cdc: 6981 ldr r1, [r0, #24] 8029cde: 1ad2 subs r2, r2, r3 8029ce0: 428a cmp r2, r1 8029ce2: d20c bcs.n 8029cfe processed actually exceeds the timers period. */ xProcessTimerNow = pdTRUE; } else { vListInsert( pxOverflowTimerList, &( pxTimer->xTimerListItem ) ); 8029ce4: 4b07 ldr r3, [pc, #28] ; (8029d04 ) 8029ce6: e004 b.n 8029cf2 } } else { if( ( xTimeNow < xCommandTime ) && ( xNextExpiryTime >= xCommandTime ) ) 8029ce8: 429a cmp r2, r3 8029cea: d201 bcs.n 8029cf0 8029cec: 4299 cmp r1, r3 8029cee: d206 bcs.n 8029cfe its expiry time and should be processed immediately. */ xProcessTimerNow = pdTRUE; } else { vListInsert( pxCurrentTimerList, &( pxTimer->xTimerListItem ) ); 8029cf0: 4b05 ldr r3, [pc, #20] ; (8029d08 ) 8029cf2: 6818 ldr r0, [r3, #0] 8029cf4: 1d21 adds r1, r4, #4 8029cf6: f7fe ffe5 bl 8028cc4 } /*-----------------------------------------------------------*/ static BaseType_t prvInsertTimerInActiveList( Timer_t * const pxTimer, const TickType_t xNextExpiryTime, const TickType_t xTimeNow, const TickType_t xCommandTime ) { BaseType_t xProcessTimerNow = pdFALSE; 8029cfa: 2000 movs r0, #0 8029cfc: bd10 pop {r4, pc} timer was issued, and the time the command was processed? */ if( ( xTimeNow - xCommandTime ) >= pxTimer->xTimerPeriodInTicks ) { /* The time between a command being issued and the command being processed actually exceeds the timers period. */ xProcessTimerNow = pdTRUE; 8029cfe: 2001 movs r0, #1 vListInsert( pxCurrentTimerList, &( pxTimer->xTimerListItem ) ); } } return xProcessTimerNow; } 8029d00: bd10 pop {r4, pc} 8029d02: bf00 nop 8029d04: 20002a14 .word 0x20002a14 8029d08: 200029e0 .word 0x200029e0 08029d0c : static void prvProcessTimerOrBlockTask( const TickType_t xNextExpireTime, const BaseType_t xListWasEmpty ) PRIVILEGED_FUNCTION; /*-----------------------------------------------------------*/ BaseType_t xTimerCreateTimerTask( void ) { 8029d0c: b51f push {r0, r1, r2, r3, r4, lr} /* This function is called when the scheduler is started if configUSE_TIMERS is set to 1. Check that the infrastructure used by the timer service task has been created/initialised. If timers have already been created then the initialisation will already have been performed. */ prvCheckForValidListAndQueue(); 8029d0e: f7ff ffb5 bl 8029c7c if( xTimerQueue != NULL ) 8029d12: 4b0b ldr r3, [pc, #44] ; (8029d40 ) 8029d14: 681b ldr r3, [r3, #0] 8029d16: b913 cbnz r3, 8029d1e else { mtCOVERAGE_TEST_MARKER(); } configASSERT( xReturn ); 8029d18: f000 f98e bl 802a038 8029d1c: e00d b.n 8029d3a xReturn = xTaskCreate( prvTimerTask, "Tmr Svc", ( uint16_t ) configTIMER_TASK_STACK_DEPTH, NULL, ( ( UBaseType_t ) configTIMER_TASK_PRIORITY ) | portPRIVILEGE_BIT, &xTimerTaskHandle ); } #else { /* Create the timer task without storing its handle. */ xReturn = xTaskCreate( prvTimerTask, "Tmr Svc", ( uint16_t ) configTIMER_TASK_STACK_DEPTH, NULL, ( ( UBaseType_t ) configTIMER_TASK_PRIORITY ) | portPRIVILEGE_BIT, NULL); 8029d1e: 2301 movs r3, #1 8029d20: 9300 str r3, [sp, #0] 8029d22: 2300 movs r3, #0 8029d24: 9301 str r3, [sp, #4] 8029d26: 9302 str r3, [sp, #8] 8029d28: 9303 str r3, [sp, #12] 8029d2a: 4806 ldr r0, [pc, #24] ; (8029d44 ) 8029d2c: 4906 ldr r1, [pc, #24] ; (8029d48 ) 8029d2e: f44f 7280 mov.w r2, #256 ; 0x100 8029d32: f7ff fb25 bl 8029380 else { mtCOVERAGE_TEST_MARKER(); } configASSERT( xReturn ); 8029d36: b908 cbnz r0, 8029d3c 8029d38: e7ee b.n 8029d18 8029d3a: e7fe b.n 8029d3a return xReturn; } 8029d3c: b005 add sp, #20 8029d3e: bd00 pop {pc} 8029d40: 20002a10 .word 0x20002a10 8029d44: 08029e45 .word 0x08029e45 8029d48: 08035f98 .word 0x08035f98 08029d4c : /*-----------------------------------------------------------*/ TimerHandle_t xTimerCreate( const char * const pcTimerName, const TickType_t xTimerPeriodInTicks, const UBaseType_t uxAutoReload, void * const pvTimerID, TimerCallbackFunction_t pxCallbackFunction ) /*lint !e971 Unqualified char types are allowed for strings and single characters only. */ { 8029d4c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8029d50: 4680 mov r8, r0 8029d52: 4617 mov r7, r2 8029d54: 461e mov r6, r3 Timer_t *pxNewTimer; /* Allocate the timer structure. */ if( xTimerPeriodInTicks == ( TickType_t ) 0U ) 8029d56: 460d mov r5, r1 8029d58: b191 cbz r1, 8029d80 { pxNewTimer = NULL; } else { pxNewTimer = ( Timer_t * ) pvPortMalloc( sizeof( Timer_t ) ); 8029d5a: 202c movs r0, #44 ; 0x2c 8029d5c: f000 fa82 bl 802a264 if( pxNewTimer != NULL ) 8029d60: 4604 mov r4, r0 8029d62: b180 cbz r0, 8029d86 { /* Ensure the infrastructure used by the timer service task has been created/initialised. */ prvCheckForValidListAndQueue(); 8029d64: f7ff ff8a bl 8029c7c /* Initialise the timer structure members using the function parameters. */ pxNewTimer->pcTimerName = pcTimerName; pxNewTimer->xTimerPeriodInTicks = xTimerPeriodInTicks; pxNewTimer->uxAutoReload = uxAutoReload; pxNewTimer->pvTimerID = pvTimerID; pxNewTimer->pxCallbackFunction = pxCallbackFunction; 8029d68: 9b06 ldr r3, [sp, #24] /* Ensure the infrastructure used by the timer service task has been created/initialised. */ prvCheckForValidListAndQueue(); /* Initialise the timer structure members using the function parameters. */ pxNewTimer->pcTimerName = pcTimerName; 8029d6a: f8c4 8000 str.w r8, [r4] pxNewTimer->xTimerPeriodInTicks = xTimerPeriodInTicks; 8029d6e: 61a5 str r5, [r4, #24] pxNewTimer->uxAutoReload = uxAutoReload; 8029d70: 61e7 str r7, [r4, #28] pxNewTimer->pvTimerID = pvTimerID; 8029d72: 6226 str r6, [r4, #32] pxNewTimer->pxCallbackFunction = pxCallbackFunction; 8029d74: 6263 str r3, [r4, #36] ; 0x24 vListInitialiseItem( &( pxNewTimer->xTimerListItem ) ); 8029d76: 1d20 adds r0, r4, #4 8029d78: f7fe ff95 bl 8028ca6 8029d7c: e003 b.n 8029d86 8029d7e: e7fe b.n 8029d7e traceTIMER_CREATE_FAILED(); } } /* 0 is not a valid value for xTimerPeriodInTicks. */ configASSERT( ( xTimerPeriodInTicks > 0 ) ); 8029d80: f000 f95a bl 802a038 8029d84: e7fb b.n 8029d7e return ( TimerHandle_t ) pxNewTimer; } 8029d86: 4620 mov r0, r4 8029d88: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 08029d8c : /*-----------------------------------------------------------*/ BaseType_t xTimerGenericCommand( TimerHandle_t xTimer, const BaseType_t xCommandID, const TickType_t xOptionalValue, BaseType_t * const pxHigherPriorityTaskWoken, const TickType_t xTicksToWait ) { 8029d8c: b530 push {r4, r5, lr} BaseType_t xReturn = pdFAIL; DaemonTaskMessage_t xMessage; /* Send a message to the timer service task to perform a particular action on a particular timer definition. */ if( xTimerQueue != NULL ) 8029d8e: 4c0f ldr r4, [pc, #60] ; (8029dcc ) return ( TimerHandle_t ) pxNewTimer; } /*-----------------------------------------------------------*/ BaseType_t xTimerGenericCommand( TimerHandle_t xTimer, const BaseType_t xCommandID, const TickType_t xOptionalValue, BaseType_t * const pxHigherPriorityTaskWoken, const TickType_t xTicksToWait ) { 8029d90: 4605 mov r5, r0 BaseType_t xReturn = pdFAIL; DaemonTaskMessage_t xMessage; /* Send a message to the timer service task to perform a particular action on a particular timer definition. */ if( xTimerQueue != NULL ) 8029d92: 6820 ldr r0, [r4, #0] return ( TimerHandle_t ) pxNewTimer; } /*-----------------------------------------------------------*/ BaseType_t xTimerGenericCommand( TimerHandle_t xTimer, const BaseType_t xCommandID, const TickType_t xOptionalValue, BaseType_t * const pxHigherPriorityTaskWoken, const TickType_t xTicksToWait ) { 8029d94: b085 sub sp, #20 BaseType_t xReturn = pdFAIL; DaemonTaskMessage_t xMessage; /* Send a message to the timer service task to perform a particular action on a particular timer definition. */ if( xTimerQueue != NULL ) 8029d96: b1b8 cbz r0, 8029dc8 /* Send a command to the timer service task to start the xTimer timer. */ xMessage.xMessageID = xCommandID; xMessage.u.xTimerParameters.xMessageValue = xOptionalValue; xMessage.u.xTimerParameters.pxTimer = ( Timer_t * ) xTimer; if( xCommandID < tmrFIRST_FROM_ISR_COMMAND ) 8029d98: 2905 cmp r1, #5 /* Send a message to the timer service task to perform a particular action on a particular timer definition. */ if( xTimerQueue != NULL ) { /* Send a command to the timer service task to start the xTimer timer. */ xMessage.xMessageID = xCommandID; 8029d9a: 9101 str r1, [sp, #4] xMessage.u.xTimerParameters.xMessageValue = xOptionalValue; 8029d9c: 9202 str r2, [sp, #8] xMessage.u.xTimerParameters.pxTimer = ( Timer_t * ) xTimer; 8029d9e: 9503 str r5, [sp, #12] if( xCommandID < tmrFIRST_FROM_ISR_COMMAND ) 8029da0: dc0d bgt.n 8029dbe { if( xTaskGetSchedulerState() == taskSCHEDULER_RUNNING ) 8029da2: f7ff fec5 bl 8029b30 8029da6: 2802 cmp r0, #2 { xReturn = xQueueSendToBack( xTimerQueue, &xMessage, xTicksToWait ); 8029da8: a901 add r1, sp, #4 8029daa: 6820 ldr r0, [r4, #0] xMessage.u.xTimerParameters.xMessageValue = xOptionalValue; xMessage.u.xTimerParameters.pxTimer = ( Timer_t * ) xTimer; if( xCommandID < tmrFIRST_FROM_ISR_COMMAND ) { if( xTaskGetSchedulerState() == taskSCHEDULER_RUNNING ) 8029dac: d102 bne.n 8029db4 { xReturn = xQueueSendToBack( xTimerQueue, &xMessage, xTicksToWait ); 8029dae: 9a08 ldr r2, [sp, #32] 8029db0: 2300 movs r3, #0 8029db2: e001 b.n 8029db8 } else { xReturn = xQueueSendToBack( xTimerQueue, &xMessage, tmrNO_DELAY ); 8029db4: 2200 movs r2, #0 8029db6: 4613 mov r3, r2 8029db8: f7ff f898 bl 8028eec 8029dbc: e004 b.n 8029dc8 } } else { xReturn = xQueueSendToBackFromISR( xTimerQueue, &xMessage, pxHigherPriorityTaskWoken ); 8029dbe: 461a mov r2, r3 8029dc0: a901 add r1, sp, #4 8029dc2: 2300 movs r3, #0 8029dc4: f7ff f956 bl 8029074 { mtCOVERAGE_TEST_MARKER(); } return xReturn; } 8029dc8: b005 add sp, #20 8029dca: bd30 pop {r4, r5, pc} 8029dcc: 20002a10 .word 0x20002a10 08029dd0 : } } /*-----------------------------------------------------------*/ static void prvSwitchTimerLists( void ) { 8029dd0: e92d 41f3 stmdb sp!, {r0, r1, r4, r5, r6, r7, r8, lr} /* The tick count has overflowed. The timer lists must be switched. If there are any timers still referenced from the current timer list then they must have expired and should be processed before the lists are switched. */ while( listLIST_IS_EMPTY( pxCurrentTimerList ) == pdFALSE ) 8029dd4: 4e19 ldr r6, [pc, #100] ; (8029e3c ) listSET_LIST_ITEM_OWNER( &( pxTimer->xTimerListItem ), pxTimer ); vListInsert( pxCurrentTimerList, &( pxTimer->xTimerListItem ) ); } else { xResult = xTimerGenericCommand( pxTimer, tmrCOMMAND_START_DONT_TRACE, xNextExpireTime, NULL, tmrNO_DELAY ); 8029dd6: f04f 0800 mov.w r8, #0 8029dda: e023 b.n 8029e24 If there are any timers still referenced from the current timer list then they must have expired and should be processed before the lists are switched. */ while( listLIST_IS_EMPTY( pxCurrentTimerList ) == pdFALSE ) { xNextExpireTime = listGET_ITEM_VALUE_OF_HEAD_ENTRY( pxCurrentTimerList ); 8029ddc: 68db ldr r3, [r3, #12] /* Remove the timer from the list. */ pxTimer = ( Timer_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxCurrentTimerList ); 8029dde: 68dc ldr r4, [r3, #12] If there are any timers still referenced from the current timer list then they must have expired and should be processed before the lists are switched. */ while( listLIST_IS_EMPTY( pxCurrentTimerList ) == pdFALSE ) { xNextExpireTime = listGET_ITEM_VALUE_OF_HEAD_ENTRY( pxCurrentTimerList ); 8029de0: 681d ldr r5, [r3, #0] /* Remove the timer from the list. */ pxTimer = ( Timer_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxCurrentTimerList ); ( void ) uxListRemove( &( pxTimer->xTimerListItem ) ); 8029de2: 1d27 adds r7, r4, #4 8029de4: 4638 mov r0, r7 8029de6: f7fe ff85 bl 8028cf4 traceTIMER_EXPIRED( pxTimer ); /* Execute its callback, then send a command to restart the timer if it is an auto-reload timer. It cannot be restarted here as the lists have not yet been switched. */ pxTimer->pxCallbackFunction( ( TimerHandle_t ) pxTimer ); 8029dea: 6a63 ldr r3, [r4, #36] ; 0x24 8029dec: 4620 mov r0, r4 8029dee: 4798 blx r3 if( pxTimer->uxAutoReload == ( UBaseType_t ) pdTRUE ) 8029df0: 69e3 ldr r3, [r4, #28] 8029df2: 2b01 cmp r3, #1 8029df4: d116 bne.n 8029e24 the timer going into the same timer list then it has already expired and the timer should be re-inserted into the current list so it is processed again within this loop. Otherwise a command should be sent to restart the timer to ensure it is only inserted into a list after the lists have been swapped. */ xReloadTime = ( xNextExpireTime + pxTimer->xTimerPeriodInTicks ); 8029df6: 69a3 ldr r3, [r4, #24] 8029df8: 18eb adds r3, r5, r3 if( xReloadTime > xNextExpireTime ) 8029dfa: 42ab cmp r3, r5 8029dfc: d906 bls.n 8029e0c { listSET_LIST_ITEM_VALUE( &( pxTimer->xTimerListItem ), xReloadTime ); 8029dfe: 6063 str r3, [r4, #4] listSET_LIST_ITEM_OWNER( &( pxTimer->xTimerListItem ), pxTimer ); 8029e00: 6124 str r4, [r4, #16] vListInsert( pxCurrentTimerList, &( pxTimer->xTimerListItem ) ); 8029e02: 6830 ldr r0, [r6, #0] 8029e04: 4639 mov r1, r7 8029e06: f7fe ff5d bl 8028cc4 8029e0a: e00b b.n 8029e24 } else { xResult = xTimerGenericCommand( pxTimer, tmrCOMMAND_START_DONT_TRACE, xNextExpireTime, NULL, tmrNO_DELAY ); 8029e0c: 2100 movs r1, #0 8029e0e: f8cd 8000 str.w r8, [sp] 8029e12: 4620 mov r0, r4 8029e14: 462a mov r2, r5 8029e16: 460b mov r3, r1 8029e18: f7ff ffb8 bl 8029d8c configASSERT( xResult ); 8029e1c: b910 cbnz r0, 8029e24 8029e1e: f000 f90b bl 802a038 8029e22: e7fe b.n 8029e22 /* The tick count has overflowed. The timer lists must be switched. If there are any timers still referenced from the current timer list then they must have expired and should be processed before the lists are switched. */ while( listLIST_IS_EMPTY( pxCurrentTimerList ) == pdFALSE ) 8029e24: 6833 ldr r3, [r6, #0] 8029e26: 681a ldr r2, [r3, #0] 8029e28: 2a00 cmp r2, #0 8029e2a: d1d7 bne.n 8029ddc mtCOVERAGE_TEST_MARKER(); } } pxTemp = pxCurrentTimerList; pxCurrentTimerList = pxOverflowTimerList; 8029e2c: 4a04 ldr r2, [pc, #16] ; (8029e40 ) 8029e2e: 4803 ldr r0, [pc, #12] ; (8029e3c ) 8029e30: 6811 ldr r1, [r2, #0] pxOverflowTimerList = pxTemp; 8029e32: 6013 str r3, [r2, #0] mtCOVERAGE_TEST_MARKER(); } } pxTemp = pxCurrentTimerList; pxCurrentTimerList = pxOverflowTimerList; 8029e34: 6001 str r1, [r0, #0] pxOverflowTimerList = pxTemp; } 8029e36: e8bd 81fc ldmia.w sp!, {r2, r3, r4, r5, r6, r7, r8, pc} 8029e3a: bf00 nop 8029e3c: 200029e0 .word 0x200029e0 8029e40: 20002a14 .word 0x20002a14 08029e44 : pxTimer->pxCallbackFunction( ( TimerHandle_t ) pxTimer ); } /*-----------------------------------------------------------*/ static void prvTimerTask( void *pvParameters ) { 8029e44: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} TickType_t xTimeNow; PRIVILEGED_DATA static TickType_t xLastTime = ( TickType_t ) 0U; /*lint !e956 Variable is only accessible to one task. */ xTimeNow = xTaskGetTickCount(); if( xTimeNow < xLastTime ) 8029e48: f8df 816c ldr.w r8, [pc, #364] ; 8029fb8 pxTimer->pxCallbackFunction( ( TimerHandle_t ) pxTimer ); } /*-----------------------------------------------------------*/ static void prvTimerTask( void *pvParameters ) { 8029e4c: b087 sub sp, #28 8029e4e: 46c1 mov r9, r8 the timer with the nearest expiry time will expire. If there are no active timers then just set the next expire time to 0. That will cause this task to unblock when the tick count overflows, at which point the timer lists will be switched and the next expiry time can be re-assessed. */ *pxListWasEmpty = listLIST_IS_EMPTY( pxCurrentTimerList ); 8029e50: 4b57 ldr r3, [pc, #348] ; (8029fb0 ) 8029e52: 681b ldr r3, [r3, #0] 8029e54: 681f ldr r7, [r3, #0] 8029e56: f1d7 0701 rsbs r7, r7, #1 8029e5a: bf38 it cc 8029e5c: 2700 movcc r7, #0 if( *pxListWasEmpty == pdFALSE ) 8029e5e: b917 cbnz r7, 8029e66 { xNextExpireTime = listGET_ITEM_VALUE_OF_HEAD_ENTRY( pxCurrentTimerList ); 8029e60: 68db ldr r3, [r3, #12] 8029e62: 681d ldr r5, [r3, #0] 8029e64: e000 b.n 8029e68 } else { /* Ensure the task unblocks when the tick count rolls over. */ xNextExpireTime = ( TickType_t ) 0U; 8029e66: 2500 movs r5, #0 static void prvProcessTimerOrBlockTask( const TickType_t xNextExpireTime, const BaseType_t xListWasEmpty ) { TickType_t xTimeNow; BaseType_t xTimerListsWereSwitched; vTaskSuspendAll(); 8029e68: f7ff fbea bl 8029640 static TickType_t prvSampleTimeNow( BaseType_t * const pxTimerListsWereSwitched ) { TickType_t xTimeNow; PRIVILEGED_DATA static TickType_t xLastTime = ( TickType_t ) 0U; /*lint !e956 Variable is only accessible to one task. */ xTimeNow = xTaskGetTickCount(); 8029e6c: f7ff fbf0 bl 8029650 if( xTimeNow < xLastTime ) 8029e70: f8d8 3000 ldr.w r3, [r8] 8029e74: 4298 cmp r0, r3 static TickType_t prvSampleTimeNow( BaseType_t * const pxTimerListsWereSwitched ) { TickType_t xTimeNow; PRIVILEGED_DATA static TickType_t xLastTime = ( TickType_t ) 0U; /*lint !e956 Variable is only accessible to one task. */ xTimeNow = xTaskGetTickCount(); 8029e76: 4606 mov r6, r0 if( xTimeNow < xLastTime ) 8029e78: d203 bcs.n 8029e82 { prvSwitchTimerLists(); 8029e7a: f7ff ffa9 bl 8029dd0 *pxTimerListsWereSwitched = pdTRUE; 8029e7e: 2301 movs r3, #1 8029e80: e000 b.n 8029e84 } else { *pxTimerListsWereSwitched = pdFALSE; 8029e82: 2300 movs r3, #0 } xLastTime = xTimeNow; 8029e84: f8c9 6000 str.w r6, [r9] has expired or not. If obtaining the time causes the lists to switch then don't process this timer as any timers that remained in the list when the lists were switched will have been processed within the prvSampleTimeNow() function. */ xTimeNow = prvSampleTimeNow( &xTimerListsWereSwitched ); if( xTimerListsWereSwitched == pdFALSE ) 8029e88: 2b00 cmp r3, #0 8029e8a: d132 bne.n 8029ef2 { /* The tick count has not overflowed, has the timer expired? */ if( ( xListWasEmpty == pdFALSE ) && ( xNextExpireTime <= xTimeNow ) ) 8029e8c: bb2f cbnz r7, 8029eda 8029e8e: 42b5 cmp r5, r6 8029e90: d823 bhi.n 8029eda { ( void ) xTaskResumeAll(); 8029e92: f7ff fc71 bl 8029778 /*-----------------------------------------------------------*/ static void prvProcessExpiredTimer( const TickType_t xNextExpireTime, const TickType_t xTimeNow ) { BaseType_t xResult; Timer_t * const pxTimer = ( Timer_t * ) listGET_OWNER_OF_HEAD_ENTRY( pxCurrentTimerList ); 8029e96: 4b46 ldr r3, [pc, #280] ; (8029fb0 ) 8029e98: 681b ldr r3, [r3, #0] 8029e9a: 68db ldr r3, [r3, #12] 8029e9c: 68dc ldr r4, [r3, #12] /* Remove the timer from the list of active timers. A check has already been performed to ensure the list is not empty. */ ( void ) uxListRemove( &( pxTimer->xTimerListItem ) ); 8029e9e: 1d20 adds r0, r4, #4 8029ea0: f7fe ff28 bl 8028cf4 traceTIMER_EXPIRED( pxTimer ); /* If the timer is an auto reload timer then calculate the next expiry time and re-insert the timer in the list of active timers. */ if( pxTimer->uxAutoReload == ( UBaseType_t ) pdTRUE ) 8029ea4: 69e3 ldr r3, [r4, #28] 8029ea6: 2b01 cmp r3, #1 8029ea8: d113 bne.n 8029ed2 { /* The timer is inserted into a list using a time relative to anything other than the current time. It will therefore be inserted into the correct list relative to the time this task thinks it is now. */ if( prvInsertTimerInActiveList( pxTimer, ( xNextExpireTime + pxTimer->xTimerPeriodInTicks ), xTimeNow, xNextExpireTime ) == pdTRUE ) 8029eaa: 69a1 ldr r1, [r4, #24] 8029eac: 4620 mov r0, r4 8029eae: 1869 adds r1, r5, r1 8029eb0: 4632 mov r2, r6 8029eb2: 462b mov r3, r5 8029eb4: f7ff ff0c bl 8029cd0 8029eb8: 2801 cmp r0, #1 8029eba: d10a bne.n 8029ed2 { /* The timer expired before it was added to the active timer list. Reload it now. */ xResult = xTimerGenericCommand( pxTimer, tmrCOMMAND_START_DONT_TRACE, xNextExpireTime, NULL, tmrNO_DELAY ); 8029ebc: 9700 str r7, [sp, #0] 8029ebe: 4620 mov r0, r4 8029ec0: 4639 mov r1, r7 8029ec2: 462a mov r2, r5 8029ec4: 463b mov r3, r7 8029ec6: f7ff ff61 bl 8029d8c configASSERT( xResult ); 8029eca: b910 cbnz r0, 8029ed2 8029ecc: f000 f8b4 bl 802a038 8029ed0: e7fe b.n 8029ed0 { mtCOVERAGE_TEST_MARKER(); } /* Call the timer callback. */ pxTimer->pxCallbackFunction( ( TimerHandle_t ) pxTimer ); 8029ed2: 6a63 ldr r3, [r4, #36] ; 0x24 8029ed4: 4620 mov r0, r4 8029ed6: 4798 blx r3 8029ed8: e05f b.n 8029f9a time has not been reached yet. This task should therefore block to wait for the next expire time or a command to be received - whichever comes first. The following line cannot be reached unless xNextExpireTime > xTimeNow, except in the case when the current timer list is empty. */ vQueueWaitForMessageRestricted( xTimerQueue, ( xNextExpireTime - xTimeNow ) ); 8029eda: 4b36 ldr r3, [pc, #216] ; (8029fb4 ) 8029edc: 1ba9 subs r1, r5, r6 8029ede: 6818 ldr r0, [r3, #0] 8029ee0: f7ff f9f6 bl 80292d0 if( xTaskResumeAll() == pdFALSE ) 8029ee4: f7ff fc48 bl 8029778 8029ee8: 2800 cmp r0, #0 8029eea: d156 bne.n 8029f9a { /* Yield to wait for either a command to arrive, or the block time to expire. If a command arrived between the critical section being exited and this yield then the yield will not cause the task to block. */ portYIELD_WITHIN_API(); 8029eec: f000 f898 bl 802a020 8029ef0: e053 b.n 8029f9a } } } else { ( void ) xTaskResumeAll(); 8029ef2: f7ff fc41 bl 8029778 8029ef6: e050 b.n 8029f9a } #endif /* INCLUDE_xTimerPendFunctionCall */ /* Commands that are positive are timer commands rather than pended function calls. */ if( xMessage.xMessageID >= ( BaseType_t ) 0 ) 8029ef8: 9b03 ldr r3, [sp, #12] 8029efa: 2b00 cmp r3, #0 8029efc: db4e blt.n 8029f9c { /* The messages uses the xTimerParameters member to work on a software timer. */ pxTimer = xMessage.u.xTimerParameters.pxTimer; 8029efe: 9c05 ldr r4, [sp, #20] if( listIS_CONTAINED_WITHIN( NULL, &( pxTimer->xTimerListItem ) ) == pdFALSE ) 8029f00: 6963 ldr r3, [r4, #20] 8029f02: b113 cbz r3, 8029f0a { /* The timer is in a list, remove it. */ ( void ) uxListRemove( &( pxTimer->xTimerListItem ) ); 8029f04: 1d20 adds r0, r4, #4 8029f06: f7fe fef5 bl 8028cf4 static TickType_t prvSampleTimeNow( BaseType_t * const pxTimerListsWereSwitched ) { TickType_t xTimeNow; PRIVILEGED_DATA static TickType_t xLastTime = ( TickType_t ) 0U; /*lint !e956 Variable is only accessible to one task. */ xTimeNow = xTaskGetTickCount(); 8029f0a: f7ff fba1 bl 8029650 if( xTimeNow < xLastTime ) 8029f0e: f8d8 3000 ldr.w r3, [r8] 8029f12: 4298 cmp r0, r3 static TickType_t prvSampleTimeNow( BaseType_t * const pxTimerListsWereSwitched ) { TickType_t xTimeNow; PRIVILEGED_DATA static TickType_t xLastTime = ( TickType_t ) 0U; /*lint !e956 Variable is only accessible to one task. */ xTimeNow = xTaskGetTickCount(); 8029f14: 4605 mov r5, r0 if( xTimeNow < xLastTime ) 8029f16: d201 bcs.n 8029f1c { prvSwitchTimerLists(); 8029f18: f7ff ff5a bl 8029dd0 possibility of a higher priority task adding a message to the message queue with a time that is ahead of the timer daemon task (because it pre-empted the timer daemon task after the xTimeNow value was set). */ xTimeNow = prvSampleTimeNow( &xTimerListsWereSwitched ); switch( xMessage.xMessageID ) 8029f1c: 9b03 ldr r3, [sp, #12] else { *pxTimerListsWereSwitched = pdFALSE; } xLastTime = xTimeNow; 8029f1e: f8c9 5000 str.w r5, [r9] possibility of a higher priority task adding a message to the message queue with a time that is ahead of the timer daemon task (because it pre-empted the timer daemon task after the xTimeNow value was set). */ xTimeNow = prvSampleTimeNow( &xTimerListsWereSwitched ); switch( xMessage.xMessageID ) 8029f22: 2b09 cmp r3, #9 8029f24: d83a bhi.n 8029f9c 8029f26: f04f 6204 mov.w r2, #138412032 ; 0x8400000 8029f2a: 409a lsls r2, r3 8029f2c: d424 bmi.n 8029f78 8029f2e: f04f 4263 mov.w r2, #3808428032 ; 0xe3000000 8029f32: 409a lsls r2, r3 8029f34: d404 bmi.n 8029f40 8029f36: f04f 6280 mov.w r2, #67108864 ; 0x4000000 8029f3a: 409a lsls r2, r3 8029f3c: d429 bmi.n 8029f92 8029f3e: e02d b.n 8029f9c case tmrCOMMAND_START_FROM_ISR : case tmrCOMMAND_RESET : case tmrCOMMAND_RESET_FROM_ISR : case tmrCOMMAND_START_DONT_TRACE : /* Start or restart a timer. */ if( prvInsertTimerInActiveList( pxTimer, xMessage.u.xTimerParameters.xMessageValue + pxTimer->xTimerPeriodInTicks, xTimeNow, xMessage.u.xTimerParameters.xMessageValue ) == pdTRUE ) 8029f40: 9b04 ldr r3, [sp, #16] 8029f42: 69a1 ldr r1, [r4, #24] 8029f44: 4620 mov r0, r4 8029f46: 1859 adds r1, r3, r1 8029f48: 462a mov r2, r5 8029f4a: f7ff fec1 bl 8029cd0 8029f4e: 2801 cmp r0, #1 8029f50: d124 bne.n 8029f9c { /* The timer expired before it was added to the active timer list. Process it now. */ pxTimer->pxCallbackFunction( ( TimerHandle_t ) pxTimer ); 8029f52: 6a63 ldr r3, [r4, #36] ; 0x24 8029f54: 4620 mov r0, r4 8029f56: 4798 blx r3 traceTIMER_EXPIRED( pxTimer ); if( pxTimer->uxAutoReload == ( UBaseType_t ) pdTRUE ) 8029f58: 69e3 ldr r3, [r4, #28] 8029f5a: 2b01 cmp r3, #1 8029f5c: d11e bne.n 8029f9c { xResult = xTimerGenericCommand( pxTimer, tmrCOMMAND_START_DONT_TRACE, xMessage.u.xTimerParameters.xMessageValue + pxTimer->xTimerPeriodInTicks, NULL, tmrNO_DELAY ); 8029f5e: 69a2 ldr r2, [r4, #24] 8029f60: 9b04 ldr r3, [sp, #16] 8029f62: 2100 movs r1, #0 8029f64: 18d2 adds r2, r2, r3 8029f66: 9100 str r1, [sp, #0] 8029f68: 4620 mov r0, r4 8029f6a: 460b mov r3, r1 8029f6c: f7ff ff0e bl 8029d8c configASSERT( xResult ); 8029f70: b9a0 cbnz r0, 8029f9c 8029f72: f000 f861 bl 802a038 8029f76: e7fe b.n 8029f76 There is nothing to do here. */ break; case tmrCOMMAND_CHANGE_PERIOD : case tmrCOMMAND_CHANGE_PERIOD_FROM_ISR : pxTimer->xTimerPeriodInTicks = xMessage.u.xTimerParameters.xMessageValue; 8029f78: 9904 ldr r1, [sp, #16] 8029f7a: 61a1 str r1, [r4, #24] configASSERT( ( pxTimer->xTimerPeriodInTicks > 0 ) ); 8029f7c: b911 cbnz r1, 8029f84 8029f7e: f000 f85b bl 802a038 8029f82: e7fe b.n 8029f82 longer or shorter than the old one. The command time is therefore set to the current time, and as the period cannot be zero the next expiry time can only be in the future, meaning (unlike for the xTimerStart() case above) there is no fail case that needs to be handled here. */ ( void ) prvInsertTimerInActiveList( pxTimer, ( xTimeNow + pxTimer->xTimerPeriodInTicks ), xTimeNow, xTimeNow ); 8029f84: 4620 mov r0, r4 8029f86: 1869 adds r1, r5, r1 8029f88: 462a mov r2, r5 8029f8a: 462b mov r3, r5 8029f8c: f7ff fea0 bl 8029cd0 8029f90: e004 b.n 8029f9c break; case tmrCOMMAND_DELETE : /* The timer has already been removed from the active list, just free up the memory. */ vPortFree( pxTimer ); 8029f92: 4620 mov r0, r4 8029f94: f000 f9ec bl 802a370 8029f98: e000 b.n 8029f9c DaemonTaskMessage_t xMessage; Timer_t *pxTimer; BaseType_t xTimerListsWereSwitched, xResult; TickType_t xTimeNow; while( xQueueReceive( xTimerQueue, &xMessage, tmrNO_DELAY ) != pdFAIL ) /*lint !e603 xMessage does not have to be initialised as it is passed out, not in, and it is not used unless xQueueReceive() returns pdTRUE. */ 8029f9a: 4e06 ldr r6, [pc, #24] ; (8029fb4 ) 8029f9c: 2200 movs r2, #0 8029f9e: 6830 ldr r0, [r6, #0] 8029fa0: a903 add r1, sp, #12 8029fa2: 4613 mov r3, r2 8029fa4: f7ff f8e2 bl 802916c 8029fa8: 2800 cmp r0, #0 8029faa: d1a5 bne.n 8029ef8 8029fac: e750 b.n 8029e50 8029fae: bf00 nop 8029fb0: 200029e0 .word 0x200029e0 8029fb4: 20002a10 .word 0x20002a10 8029fb8: 20002a0c .word 0x20002a0c 08029fbc : void *pvTimerGetTimerID( const TimerHandle_t xTimer ) { Timer_t * const pxTimer = ( Timer_t * ) xTimer; return pxTimer->pvTimerID; } 8029fbc: 6a00 ldr r0, [r0, #32] 8029fbe: 4770 bx lr 08029fc0 : } /*-----------------------------------------------------------*/ static void prvPortStartFirstTask( void ) { __asm volatile( 8029fc0: 4806 ldr r0, [pc, #24] ; (8029fdc ) 8029fc2: 6800 ldr r0, [r0, #0] 8029fc4: 6800 ldr r0, [r0, #0] 8029fc6: f380 8808 msr MSP, r0 8029fca: b662 cpsie i 8029fcc: b661 cpsie f 8029fce: f3bf 8f4f dsb sy 8029fd2: f3bf 8f6f isb sy 8029fd6: df00 svc 0 8029fd8: bf00 nop 8029fda: 0000 .short 0x0000 8029fdc: e000ed08 .word 0xe000ed08 08029fe0 : StackType_t *pxPortInitialiseStack( StackType_t *pxTopOfStack, TaskFunction_t pxCode, void *pvParameters ) { /* Simulate the stack frame as it would be created by a context switch interrupt. */ pxTopOfStack--; /* Offset added to account for the way the MCU uses the stack on entry/exit of interrupts. */ *pxTopOfStack = portINITIAL_XPSR; /* xPSR */ 8029fe0: f04f 7380 mov.w r3, #16777216 ; 0x1000000 pxTopOfStack--; *pxTopOfStack = ( StackType_t ) pxCode; /* PC */ 8029fe4: e900 000a stmdb r0, {r1, r3} pxTopOfStack--; *pxTopOfStack = ( StackType_t ) portTASK_RETURN_ADDRESS; /* LR */ 8029fe8: 4b03 ldr r3, [pc, #12] ; (8029ff8 ) pxTopOfStack -= 5; /* R12, R3, R2 and R1. */ *pxTopOfStack = ( StackType_t ) pvParameters; /* R0 */ 8029fea: f840 2c20 str.w r2, [r0, #-32] pxTopOfStack--; /* Offset added to account for the way the MCU uses the stack on entry/exit of interrupts. */ *pxTopOfStack = portINITIAL_XPSR; /* xPSR */ pxTopOfStack--; *pxTopOfStack = ( StackType_t ) pxCode; /* PC */ pxTopOfStack--; *pxTopOfStack = ( StackType_t ) portTASK_RETURN_ADDRESS; /* LR */ 8029fee: f840 3c0c str.w r3, [r0, #-12] pxTopOfStack -= 5; /* R12, R3, R2 and R1. */ *pxTopOfStack = ( StackType_t ) pvParameters; /* R0 */ pxTopOfStack -= 8; /* R11, R10, R9, R8, R7, R6, R5 and R4. */ return pxTopOfStack; } 8029ff2: 3840 subs r0, #64 ; 0x40 8029ff4: 4770 bx lr 8029ff6: bf00 nop 8029ff8: 0802a07d .word 0x0802a07d 08029ffc : } /*-----------------------------------------------------------*/ void vPortSVCHandler( void ) { __asm volatile ( 8029ffc: 4b07 ldr r3, [pc, #28] ; (802a01c ) 8029ffe: 6819 ldr r1, [r3, #0] 802a000: 6808 ldr r0, [r1, #0] 802a002: e8b0 0ff0 ldmia.w r0!, {r4, r5, r6, r7, r8, r9, sl, fp} 802a006: f380 8809 msr PSP, r0 802a00a: f3bf 8f6f isb sy 802a00e: f04f 0000 mov.w r0, #0 802a012: f380 8811 msr BASEPRI, r0 802a016: f04e 0e0d orr.w lr, lr, #13 802a01a: 4770 bx lr 0802a01c : 802a01c: 20002998 .word 0x20002998 0802a020 : /*-----------------------------------------------------------*/ void vPortYield( void ) { /* Set a PendSV to request a context switch. */ portNVIC_INT_CTRL_REG = portNVIC_PENDSVSET_BIT; 802a020: 4b04 ldr r3, [pc, #16] ; (802a034 ) 802a022: f04f 5280 mov.w r2, #268435456 ; 0x10000000 802a026: 601a str r2, [r3, #0] /* Barriers are normally not required but do ensure the code is completely within the specified behaviour for the architecture. */ __asm volatile( "dsb" ); 802a028: f3bf 8f4f dsb sy __asm volatile( "isb" ); 802a02c: f3bf 8f6f isb sy 802a030: 4770 bx lr 802a032: bf00 nop 802a034: e000ed04 .word 0xe000ed04 0802a038 : } /*-----------------------------------------------------------*/ __attribute__(( naked )) uint32_t ulPortSetInterruptMask( void ) { __asm volatile \ 802a038: f3ef 8011 mrs r0, BASEPRI 802a03c: f04f 0150 mov.w r1, #80 ; 0x50 802a040: f381 8811 msr BASEPRI, r1 802a044: 4770 bx lr ); /* This return will not be reached but is necessary to prevent compiler warnings. */ return 0; } 802a046: 2000 movs r0, #0 0802a048 : __asm volatile( "isb" ); } /*-----------------------------------------------------------*/ void vPortEnterCritical( void ) { 802a048: b508 push {r3, lr} portDISABLE_INTERRUPTS(); 802a04a: f7ff fff5 bl 802a038 uxCriticalNesting++; 802a04e: 4a09 ldr r2, [pc, #36] ; (802a074 ) 802a050: 6813 ldr r3, [r2, #0] 802a052: 3301 adds r3, #1 802a054: 6013 str r3, [r2, #0] __asm volatile( "dsb" ); 802a056: f3bf 8f4f dsb sy __asm volatile( "isb" ); 802a05a: f3bf 8f6f isb sy /* This is not the interrupt safe version of the enter critical function so assert() if it is being called from an interrupt context. Only API functions that end in "FromISR" can be used in an interrupt. Only assert if the critical nesting count is 1 to protect against recursive calls if the assert function also uses a critical section. */ if( uxCriticalNesting == 1 ) 802a05e: 2b01 cmp r3, #1 802a060: d107 bne.n 802a072 { configASSERT( ( portNVIC_INT_CTRL_REG & portVECTACTIVE_MASK ) == 0 ); 802a062: 4b05 ldr r3, [pc, #20] ; (802a078 ) 802a064: 681b ldr r3, [r3, #0] 802a066: f013 0fff tst.w r3, #255 ; 0xff 802a06a: d002 beq.n 802a072 802a06c: f7ff ffe4 bl 802a038 802a070: e7fe b.n 802a070 802a072: bd08 pop {r3, pc} 802a074: 200015dc .word 0x200015dc 802a078: e000ed04 .word 0xe000ed04 0802a07c : return pxTopOfStack; } /*-----------------------------------------------------------*/ static void prvTaskExitError( void ) { 802a07c: b508 push {r3, lr} its caller as there is nothing to return to. If a task wants to exit it should instead call vTaskDelete( NULL ). Artificially force an assert() to be triggered if configASSERT() is defined, then stop here so application writers can catch the error. */ configASSERT( uxCriticalNesting == ~0UL ); 802a07e: 4b05 ldr r3, [pc, #20] ; (802a094 ) 802a080: 681b ldr r3, [r3, #0] 802a082: 3301 adds r3, #1 802a084: d002 beq.n 802a08c 802a086: f7ff ffd7 bl 802a038 802a08a: e7fe b.n 802a08a portDISABLE_INTERRUPTS(); 802a08c: f7ff ffd4 bl 802a038 802a090: e7fe b.n 802a090 802a092: bf00 nop 802a094: 200015dc .word 0x200015dc 0802a098 : } /*-----------------------------------------------------------*/ __attribute__(( naked )) void vPortClearInterruptMask( uint32_t ulNewMaskValue ) { __asm volatile \ 802a098: f380 8811 msr BASEPRI, r0 802a09c: 4770 bx lr 802a09e: 0000 movs r0, r0 0802a0a0 : } } /*-----------------------------------------------------------*/ void vPortExitCritical( void ) { 802a0a0: b508 push {r3, lr} configASSERT( uxCriticalNesting ); 802a0a2: 4b07 ldr r3, [pc, #28] ; (802a0c0 ) 802a0a4: 6818 ldr r0, [r3, #0] 802a0a6: b910 cbnz r0, 802a0ae 802a0a8: f7ff ffc6 bl 802a038 802a0ac: e7fe b.n 802a0ac uxCriticalNesting--; 802a0ae: 3801 subs r0, #1 802a0b0: 6018 str r0, [r3, #0] if( uxCriticalNesting == 0 ) 802a0b2: b918 cbnz r0, 802a0bc { portENABLE_INTERRUPTS(); } } 802a0b4: e8bd 4008 ldmia.w sp!, {r3, lr} { configASSERT( uxCriticalNesting ); uxCriticalNesting--; if( uxCriticalNesting == 0 ) { portENABLE_INTERRUPTS(); 802a0b8: f7ff bfee b.w 802a098 802a0bc: bd08 pop {r3, pc} 802a0be: bf00 nop 802a0c0: 200015dc .word 0x200015dc 0802a0c4 : void xPortPendSVHandler( void ) { /* This is a naked function. */ __asm volatile 802a0c4: f3ef 8009 mrs r0, PSP 802a0c8: f3bf 8f6f isb sy 802a0cc: 4b0d ldr r3, [pc, #52] ; (802a104 ) 802a0ce: 681a ldr r2, [r3, #0] 802a0d0: e920 0ff0 stmdb r0!, {r4, r5, r6, r7, r8, r9, sl, fp} 802a0d4: 6010 str r0, [r2, #0] 802a0d6: e92d 4008 stmdb sp!, {r3, lr} 802a0da: f04f 0050 mov.w r0, #80 ; 0x50 802a0de: f380 8811 msr BASEPRI, r0 802a0e2: f7ff fc19 bl 8029918 802a0e6: f04f 0000 mov.w r0, #0 802a0ea: f380 8811 msr BASEPRI, r0 802a0ee: e8bd 4008 ldmia.w sp!, {r3, lr} 802a0f2: 6819 ldr r1, [r3, #0] 802a0f4: 6808 ldr r0, [r1, #0] 802a0f6: e8b0 0ff0 ldmia.w r0!, {r4, r5, r6, r7, r8, r9, sl, fp} 802a0fa: f380 8809 msr PSP, r0 802a0fe: f3bf 8f6f isb sy 802a102: 4770 bx lr 0802a104 : 802a104: 20002998 .word 0x20002998 0802a108 : ); } /*-----------------------------------------------------------*/ void xPortSysTickHandler( void ) { 802a108: b508 push {r3, lr} /* The SysTick runs at the lowest interrupt priority, so when this interrupt executes all interrupts must be unmasked. There is therefore no need to save and then restore the interrupt mask value as its value is already known. */ ( void ) portSET_INTERRUPT_MASK_FROM_ISR(); 802a10a: f7ff ff95 bl 802a038 { /* Increment the RTOS tick. */ if( xTaskIncrementTick() != pdFALSE ) 802a10e: f7ff faa5 bl 802965c 802a112: b118 cbz r0, 802a11c { /* A context switch is required. Context switching is performed in the PendSV interrupt. Pend the PendSV interrupt. */ portNVIC_INT_CTRL_REG = portNVIC_PENDSVSET_BIT; 802a114: 4b04 ldr r3, [pc, #16] ; (802a128 ) 802a116: f04f 5280 mov.w r2, #268435456 ; 0x10000000 802a11a: 601a str r2, [r3, #0] } } portCLEAR_INTERRUPT_MASK_FROM_ISR( 0 ); 802a11c: 2000 movs r0, #0 } 802a11e: e8bd 4008 ldmia.w sp!, {r3, lr} /* A context switch is required. Context switching is performed in the PendSV interrupt. Pend the PendSV interrupt. */ portNVIC_INT_CTRL_REG = portNVIC_PENDSVSET_BIT; } } portCLEAR_INTERRUPT_MASK_FROM_ISR( 0 ); 802a122: f7ff bfb9 b.w 802a098 802a126: bf00 nop 802a128: e000ed04 .word 0xe000ed04 0802a12c : ulStoppedTimerCompensation = portMISSED_COUNTS_FACTOR / ( configCPU_CLOCK_HZ / configSYSTICK_CLOCK_HZ ); } #endif /* configUSE_TICKLESS_IDLE */ /* Configure SysTick to interrupt at the requested rate. */ portNVIC_SYSTICK_LOAD_REG = ( configSYSTICK_CLOCK_HZ / configTICK_RATE_HZ ) - 1UL; 802a12c: 4b06 ldr r3, [pc, #24] ; (802a148 ) 802a12e: 681a ldr r2, [r3, #0] 802a130: f44f 737a mov.w r3, #1000 ; 0x3e8 802a134: fbb2 f2f3 udiv r2, r2, r3 802a138: 4b04 ldr r3, [pc, #16] ; (802a14c ) 802a13a: 3a01 subs r2, #1 802a13c: 601a str r2, [r3, #0] portNVIC_SYSTICK_CTRL_REG = ( portNVIC_SYSTICK_CLK_BIT | portNVIC_SYSTICK_INT_BIT | portNVIC_SYSTICK_ENABLE_BIT ); 802a13e: 2207 movs r2, #7 802a140: f843 2c04 str.w r2, [r3, #-4] 802a144: 4770 bx lr 802a146: bf00 nop 802a148: 200005bc .word 0x200005bc 802a14c: e000e014 .word 0xe000e014 0802a150 : /* * See header file for description. */ BaseType_t xPortStartScheduler( void ) { 802a150: b507 push {r0, r1, r2, lr} functions can be called. ISR safe functions are those that end in "FromISR". FreeRTOS maintains separate thread and ISR API functions to ensure interrupt entry is as fast and simple as possible. Save the interrupt priority value that is about to be clobbered. */ ulOriginalPriority = *pucFirstUserPriorityRegister; 802a152: 4b1d ldr r3, [pc, #116] ; (802a1c8 ) 802a154: 781a ldrb r2, [r3, #0] 802a156: 9201 str r2, [sp, #4] /* Determine the number of priority bits available. First write to all possible bits. */ *pucFirstUserPriorityRegister = portMAX_8_BIT_VALUE; 802a158: 22ff movs r2, #255 ; 0xff 802a15a: 701a strb r2, [r3, #0] /* Read the value back to see how many bits stuck. */ ucMaxPriorityValue = *pucFirstUserPriorityRegister; 802a15c: 781b ldrb r3, [r3, #0] 802a15e: f88d 3003 strb.w r3, [sp, #3] /* Use the same mask on the maximum system call priority. */ ucMaxSysCallPriority = configMAX_SYSCALL_INTERRUPT_PRIORITY & ucMaxPriorityValue; 802a162: f89d 2003 ldrb.w r2, [sp, #3] 802a166: 4b19 ldr r3, [pc, #100] ; (802a1cc ) 802a168: f002 0250 and.w r2, r2, #80 ; 0x50 802a16c: 701a strb r2, [r3, #0] /* Calculate the maximum acceptable priority group value for the number of bits read back. */ ulMaxPRIGROUPValue = portMAX_PRIGROUP_BITS; 802a16e: 4a18 ldr r2, [pc, #96] ; (802a1d0 ) 802a170: 2307 movs r3, #7 802a172: 6013 str r3, [r2, #0] while( ( ucMaxPriorityValue & portTOP_BIT_OF_BYTE ) == portTOP_BIT_OF_BYTE ) 802a174: e005 b.n 802a182 { ulMaxPRIGROUPValue--; ucMaxPriorityValue <<= ( uint8_t ) 0x01; 802a176: f89d 3003 ldrb.w r3, [sp, #3] 802a17a: 005b lsls r3, r3, #1 802a17c: f88d 3003 strb.w r3, [sp, #3] 802a180: 460b mov r3, r1 ucMaxSysCallPriority = configMAX_SYSCALL_INTERRUPT_PRIORITY & ucMaxPriorityValue; /* Calculate the maximum acceptable priority group value for the number of bits read back. */ ulMaxPRIGROUPValue = portMAX_PRIGROUP_BITS; while( ( ucMaxPriorityValue & portTOP_BIT_OF_BYTE ) == portTOP_BIT_OF_BYTE ) 802a182: f89d 2003 ldrb.w r2, [sp, #3] 802a186: 1e59 subs r1, r3, #1 802a188: 0612 lsls r2, r2, #24 802a18a: d4f4 bmi.n 802a176 } /* Shift the priority group value back to its position within the AIRCR register. */ ulMaxPRIGROUPValue <<= portPRIGROUP_SHIFT; ulMaxPRIGROUPValue &= portPRIORITY_GROUP_MASK; 802a18c: 4a10 ldr r2, [pc, #64] ; (802a1d0 ) ucMaxPriorityValue <<= ( uint8_t ) 0x01; } /* Shift the priority group value back to its position within the AIRCR register. */ ulMaxPRIGROUPValue <<= portPRIGROUP_SHIFT; 802a18e: 021b lsls r3, r3, #8 ulMaxPRIGROUPValue &= portPRIORITY_GROUP_MASK; 802a190: f403 63e0 and.w r3, r3, #1792 ; 0x700 802a194: 6013 str r3, [r2, #0] /* Restore the clobbered interrupt priority register to its original value. */ *pucFirstUserPriorityRegister = ulOriginalPriority; 802a196: 4b0c ldr r3, [pc, #48] ; (802a1c8 ) 802a198: 9a01 ldr r2, [sp, #4] 802a19a: 701a strb r2, [r3, #0] } #endif /* conifgASSERT_DEFINED */ /* Make PendSV and SysTick the lowest priority interrupts. */ portNVIC_SYSPRI2_REG |= portNVIC_PENDSV_PRI; 802a19c: f8d3 2920 ldr.w r2, [r3, #2336] ; 0x920 802a1a0: f442 0270 orr.w r2, r2, #15728640 ; 0xf00000 802a1a4: f8c3 2920 str.w r2, [r3, #2336] ; 0x920 portNVIC_SYSPRI2_REG |= portNVIC_SYSTICK_PRI; 802a1a8: f8d3 2920 ldr.w r2, [r3, #2336] ; 0x920 802a1ac: f042 4270 orr.w r2, r2, #4026531840 ; 0xf0000000 802a1b0: f8c3 2920 str.w r2, [r3, #2336] ; 0x920 /* Start the timer that generates the tick ISR. Interrupts are disabled here already. */ vPortSetupTimerInterrupt(); 802a1b4: f7ff ffba bl 802a12c /* Initialise the critical nesting count ready for the first task. */ uxCriticalNesting = 0; 802a1b8: 4b06 ldr r3, [pc, #24] ; (802a1d4 ) 802a1ba: 2200 movs r2, #0 802a1bc: 601a str r2, [r3, #0] /* Start the first task. */ prvPortStartFirstTask(); 802a1be: f7ff feff bl 8029fc0 /* Should never get here as the tasks will now be executing! Call the task exit error function to prevent compiler warnings about a static function not being called in the case that the application writer overrides this functionality by defining configTASK_RETURN_ADDRESS. */ prvTaskExitError(); 802a1c2: f7ff ff5b bl 802a07c 802a1c6: bf00 nop 802a1c8: e000e400 .word 0xe000e400 802a1cc: 20002a18 .word 0x20002a18 802a1d0: 20002a1c .word 0x20002a1c 802a1d4: 200015dc .word 0x200015dc 0802a1d8 : /*-----------------------------------------------------------*/ #if( configASSERT_DEFINED == 1 ) void vPortValidateInterruptPriority( void ) { 802a1d8: b508 push {r3, lr} uint32_t ulCurrentInterrupt; uint8_t ucCurrentPriority; /* Obtain the number of the currently executing interrupt. */ __asm volatile( "mrs %0, ipsr" : "=r"( ulCurrentInterrupt ) ); 802a1da: f3ef 8305 mrs r3, IPSR /* Is the interrupt number a user defined interrupt? */ if( ulCurrentInterrupt >= portFIRST_USER_INTERRUPT_NUMBER ) 802a1de: 2b0f cmp r3, #15 802a1e0: d908 bls.n 802a1f4 { /* Look up the interrupt's priority. */ ucCurrentPriority = pcInterruptPriorityRegisters[ ulCurrentInterrupt ]; 802a1e2: 4a0a ldr r2, [pc, #40] ; (802a20c ) 802a1e4: 5c9b ldrb r3, [r3, r2] interrupt entry is as fast and simple as possible. The following links provide detailed information: http://www.freertos.org/RTOS-Cortex-M3-M4.html http://www.freertos.org/FAQHelp.html */ configASSERT( ucCurrentPriority >= ucMaxSysCallPriority ); 802a1e6: 4a0a ldr r2, [pc, #40] ; (802a210 ) 802a1e8: 7812 ldrb r2, [r2, #0] 802a1ea: 429a cmp r2, r3 802a1ec: d902 bls.n 802a1f4 802a1ee: f7ff ff23 bl 802a038 802a1f2: e7fe b.n 802a1f2 configuration then the correct setting can be achieved on all Cortex-M devices by calling NVIC_SetPriorityGrouping( 0 ); before starting the scheduler. Note however that some vendor specific peripheral libraries assume a non-zero priority group setting, in which cases using a value of zero will result in unpredicable behaviour. */ configASSERT( ( portAIRCR_REG & portPRIORITY_GROUP_MASK ) <= ulMaxPRIGROUPValue ); 802a1f4: 4b07 ldr r3, [pc, #28] ; (802a214 ) 802a1f6: 681a ldr r2, [r3, #0] 802a1f8: 4b07 ldr r3, [pc, #28] ; (802a218 ) 802a1fa: 681b ldr r3, [r3, #0] 802a1fc: f402 62e0 and.w r2, r2, #1792 ; 0x700 802a200: 429a cmp r2, r3 802a202: d902 bls.n 802a20a 802a204: f7ff ff18 bl 802a038 802a208: e7fe b.n 802a208 802a20a: bd08 pop {r3, pc} 802a20c: e000e3f0 .word 0xe000e3f0 802a210: 20002a18 .word 0x20002a18 802a214: e000ed0c .word 0xe000ed0c 802a218: 20002a1c .word 0x20002a1c 0802a21c : xBlockAllocatedBit = ( ( size_t ) 1 ) << ( ( sizeof( size_t ) * heapBITS_PER_BYTE ) - 1 ); } /*-----------------------------------------------------------*/ static void prvInsertBlockIntoFreeList( BlockLink_t *pxBlockToInsert ) { 802a21c: b510 push {r4, lr} BlockLink_t *pxIterator; uint8_t *puc; /* Iterate through the list until a block is found that has a higher address than the block being inserted. */ for( pxIterator = &xStart; pxIterator->pxNextFreeBlock < pxBlockToInsert; pxIterator = pxIterator->pxNextFreeBlock ) 802a21e: 4b0f ldr r3, [pc, #60] ; (802a25c ) 802a220: e000 b.n 802a224 802a222: 4613 mov r3, r2 802a224: 681a ldr r2, [r3, #0] 802a226: 4282 cmp r2, r0 802a228: d3fb bcc.n 802a222 } /* Do the block being inserted, and the block it is being inserted after make a contiguous block of memory? */ puc = ( uint8_t * ) pxIterator; if( ( puc + pxIterator->xBlockSize ) == ( uint8_t * ) pxBlockToInsert ) 802a22a: 6859 ldr r1, [r3, #4] 802a22c: 185c adds r4, r3, r1 802a22e: 4284 cmp r4, r0 802a230: d103 bne.n 802a23a { pxIterator->xBlockSize += pxBlockToInsert->xBlockSize; 802a232: 6840 ldr r0, [r0, #4] 802a234: 1841 adds r1, r0, r1 802a236: 6059 str r1, [r3, #4] 802a238: 4618 mov r0, r3 } /* Do the block being inserted, and the block it is being inserted before make a contiguous block of memory? */ puc = ( uint8_t * ) pxBlockToInsert; if( ( puc + pxBlockToInsert->xBlockSize ) == ( uint8_t * ) pxIterator->pxNextFreeBlock ) 802a23a: 6841 ldr r1, [r0, #4] 802a23c: 1844 adds r4, r0, r1 802a23e: 4294 cmp r4, r2 802a240: d106 bne.n 802a250 { if( pxIterator->pxNextFreeBlock != pxEnd ) 802a242: 4c07 ldr r4, [pc, #28] ; (802a260 ) 802a244: 6824 ldr r4, [r4, #0] 802a246: 42a2 cmp r2, r4 802a248: d002 beq.n 802a250 { /* Form one big block from the two blocks. */ pxBlockToInsert->xBlockSize += pxIterator->pxNextFreeBlock->xBlockSize; pxBlockToInsert->pxNextFreeBlock = pxIterator->pxNextFreeBlock->pxNextFreeBlock; 802a24a: ca14 ldmia r2, {r2, r4} if( ( puc + pxBlockToInsert->xBlockSize ) == ( uint8_t * ) pxIterator->pxNextFreeBlock ) { if( pxIterator->pxNextFreeBlock != pxEnd ) { /* Form one big block from the two blocks. */ pxBlockToInsert->xBlockSize += pxIterator->pxNextFreeBlock->xBlockSize; 802a24c: 1861 adds r1, r4, r1 802a24e: 6041 str r1, [r0, #4] /* If the block being inserted plugged a gab, so was merged with the block before and the block after, then it's pxNextFreeBlock pointer will have already been set, and should not be set here as that would make it point to itself. */ if( pxIterator != pxBlockToInsert ) 802a250: 4283 cmp r3, r0 pxBlockToInsert->pxNextFreeBlock = pxEnd; } } else { pxBlockToInsert->pxNextFreeBlock = pxIterator->pxNextFreeBlock; 802a252: 6002 str r2, [r0, #0] before and the block after, then it's pxNextFreeBlock pointer will have already been set, and should not be set here as that would make it point to itself. */ if( pxIterator != pxBlockToInsert ) { pxIterator->pxNextFreeBlock = pxBlockToInsert; 802a254: bf18 it ne 802a256: 6018 strne r0, [r3, #0] 802a258: bd10 pop {r4, pc} 802a25a: bf00 nop 802a25c: 20002a28 .word 0x20002a28 802a260: 20002a24 .word 0x20002a24 0802a264 : static size_t xBlockAllocatedBit = 0; /*-----------------------------------------------------------*/ void *pvPortMalloc( size_t xWantedSize ) { 802a264: b5f8 push {r3, r4, r5, r6, r7, lr} 802a266: 4605 mov r5, r0 BlockLink_t *pxBlock, *pxPreviousBlock, *pxNewBlockLink; void *pvReturn = NULL; vTaskSuspendAll(); 802a268: f7ff f9ea bl 8029640 { /* If this is the first call to malloc then the heap will require initialisation to setup the list of free blocks. */ if( pxEnd == NULL ) 802a26c: 4b3a ldr r3, [pc, #232] ; (802a358 ) 802a26e: 681b ldr r3, [r3, #0] 802a270: bb1b cbnz r3, 802a2ba uint8_t *pucAlignedHeap; uint32_t ulAddress; size_t xTotalHeapSize = configTOTAL_HEAP_SIZE; /* Ensure the heap starts on a correctly aligned boundary. */ ulAddress = ( uint32_t ) ucHeap; 802a272: 4a3a ldr r2, [pc, #232] ; (802a35c ) if( ( ulAddress & portBYTE_ALIGNMENT_MASK ) != 0 ) 802a274: 0756 lsls r6, r2, #29 802a276: d007 beq.n 802a288 { ulAddress += ( portBYTE_ALIGNMENT - 1 ); 802a278: 1dd3 adds r3, r2, #7 ulAddress &= ~portBYTE_ALIGNMENT_MASK; 802a27a: f023 0307 bic.w r3, r3, #7 xTotalHeapSize -= ulAddress - ( uint32_t ) ucHeap; 802a27e: f502 4270 add.w r2, r2, #61440 ; 0xf000 802a282: 1ad1 subs r1, r2, r3 ulAddress = ( uint32_t ) ucHeap; if( ( ulAddress & portBYTE_ALIGNMENT_MASK ) != 0 ) { ulAddress += ( portBYTE_ALIGNMENT - 1 ); ulAddress &= ~portBYTE_ALIGNMENT_MASK; 802a284: 461a mov r2, r3 802a286: e001 b.n 802a28c static void prvHeapInit( void ) { BlockLink_t *pxFirstFreeBlock; uint8_t *pucAlignedHeap; uint32_t ulAddress; size_t xTotalHeapSize = configTOTAL_HEAP_SIZE; 802a288: f44f 4170 mov.w r1, #61440 ; 0xf000 xStart.pxNextFreeBlock = ( void * ) pucAlignedHeap; xStart.xBlockSize = ( size_t ) 0; /* pxEnd is used to mark the end of the list of free blocks and is inserted at the end of the heap space. */ ulAddress = ( ( uint32_t ) pucAlignedHeap ) + xTotalHeapSize; 802a28c: 1851 adds r1, r2, r1 ulAddress -= xHeapStructSize; 802a28e: 3908 subs r1, #8 ulAddress &= ~portBYTE_ALIGNMENT_MASK; 802a290: f021 0107 bic.w r1, r1, #7 pucAlignedHeap = ( uint8_t * ) ulAddress; /* xStart is used to hold a pointer to the first item in the list of free blocks. The void cast is used to prevent compiler warnings. */ xStart.pxNextFreeBlock = ( void * ) pucAlignedHeap; 802a294: 4832 ldr r0, [pc, #200] ; (802a360 ) xStart.xBlockSize = ( size_t ) 0; 802a296: 2300 movs r3, #0 802a298: e880 000c stmia.w r0, {r2, r3} ulAddress = ( ( uint32_t ) pucAlignedHeap ) + xTotalHeapSize; ulAddress -= xHeapStructSize; ulAddress &= ~portBYTE_ALIGNMENT_MASK; pxEnd = ( void * ) ulAddress; pxEnd->xBlockSize = 0; pxEnd->pxNextFreeBlock = NULL; 802a29c: 600b str r3, [r1, #0] at the end of the heap space. */ ulAddress = ( ( uint32_t ) pucAlignedHeap ) + xTotalHeapSize; ulAddress -= xHeapStructSize; ulAddress &= ~portBYTE_ALIGNMENT_MASK; pxEnd = ( void * ) ulAddress; pxEnd->xBlockSize = 0; 802a29e: 604b str r3, [r1, #4] pxEnd->pxNextFreeBlock = NULL; /* To start with there is a single free block that is sized to take up the entire heap space, minus the space taken by pxEnd. */ pxFirstFreeBlock = ( void * ) pucAlignedHeap; pxFirstFreeBlock->xBlockSize = ulAddress - ( uint32_t ) pxFirstFreeBlock; 802a2a0: 1a8b subs r3, r1, r2 pxFirstFreeBlock->pxNextFreeBlock = pxEnd; 802a2a2: e882 000a stmia.w r2, {r1, r3} /* Only one block exists - and it covers the entire usable heap space. */ xMinimumEverFreeBytesRemaining = pxFirstFreeBlock->xBlockSize; 802a2a6: 4a2f ldr r2, [pc, #188] ; (802a364 ) /* pxEnd is used to mark the end of the list of free blocks and is inserted at the end of the heap space. */ ulAddress = ( ( uint32_t ) pucAlignedHeap ) + xTotalHeapSize; ulAddress -= xHeapStructSize; ulAddress &= ~portBYTE_ALIGNMENT_MASK; pxEnd = ( void * ) ulAddress; 802a2a8: 482b ldr r0, [pc, #172] ; (802a358 ) pxFirstFreeBlock = ( void * ) pucAlignedHeap; pxFirstFreeBlock->xBlockSize = ulAddress - ( uint32_t ) pxFirstFreeBlock; pxFirstFreeBlock->pxNextFreeBlock = pxEnd; /* Only one block exists - and it covers the entire usable heap space. */ xMinimumEverFreeBytesRemaining = pxFirstFreeBlock->xBlockSize; 802a2aa: 6013 str r3, [r2, #0] xFreeBytesRemaining = pxFirstFreeBlock->xBlockSize; 802a2ac: 4a2e ldr r2, [pc, #184] ; (802a368 ) /* pxEnd is used to mark the end of the list of free blocks and is inserted at the end of the heap space. */ ulAddress = ( ( uint32_t ) pucAlignedHeap ) + xTotalHeapSize; ulAddress -= xHeapStructSize; ulAddress &= ~portBYTE_ALIGNMENT_MASK; pxEnd = ( void * ) ulAddress; 802a2ae: 6001 str r1, [r0, #0] pxFirstFreeBlock->xBlockSize = ulAddress - ( uint32_t ) pxFirstFreeBlock; pxFirstFreeBlock->pxNextFreeBlock = pxEnd; /* Only one block exists - and it covers the entire usable heap space. */ xMinimumEverFreeBytesRemaining = pxFirstFreeBlock->xBlockSize; xFreeBytesRemaining = pxFirstFreeBlock->xBlockSize; 802a2b0: 6013 str r3, [r2, #0] /* Work out the position of the top bit in a size_t variable. */ xBlockAllocatedBit = ( ( size_t ) 1 ) << ( ( sizeof( size_t ) * heapBITS_PER_BYTE ) - 1 ); 802a2b2: 4b2e ldr r3, [pc, #184] ; (802a36c ) 802a2b4: f04f 4200 mov.w r2, #2147483648 ; 0x80000000 802a2b8: 601a str r2, [r3, #0] /* Check the requested block size is not so large that the top bit is set. The top bit of the block size member of the BlockLink_t structure is used to determine who owns the block - the application or the kernel, so it must be free. */ if( ( xWantedSize & xBlockAllocatedBit ) == 0 ) 802a2ba: 4b2c ldr r3, [pc, #176] ; (802a36c ) 802a2bc: 681e ldr r6, [r3, #0] 802a2be: 4235 tst r5, r6 802a2c0: d140 bne.n 802a344 { /* The wanted size is increased so it can contain a BlockLink_t structure in addition to the requested amount of bytes. */ if( xWantedSize > 0 ) 802a2c2: 2d00 cmp r5, #0 802a2c4: d03f beq.n 802a346 { xWantedSize += xHeapStructSize; 802a2c6: f105 0308 add.w r3, r5, #8 /* Ensure that blocks are always aligned to the required number of bytes. */ if( ( xWantedSize & portBYTE_ALIGNMENT_MASK ) != 0x00 ) 802a2ca: 0758 lsls r0, r3, #29 { /* Byte alignment required. */ xWantedSize += ( portBYTE_ALIGNMENT - ( xWantedSize & portBYTE_ALIGNMENT_MASK ) ); 802a2cc: bf1c itt ne 802a2ce: f023 0307 bicne.w r3, r3, #7 802a2d2: 3308 addne r3, #8 else { mtCOVERAGE_TEST_MARKER(); } if( ( xWantedSize > 0 ) && ( xWantedSize <= xFreeBytesRemaining ) ) 802a2d4: 2b00 cmp r3, #0 802a2d6: d033 beq.n 802a340 802a2d8: 4a23 ldr r2, [pc, #140] ; (802a368 ) 802a2da: 6817 ldr r7, [r2, #0] 802a2dc: 42bb cmp r3, r7 802a2de: d831 bhi.n 802a344 { /* Traverse the list from the start (lowest address) block until one of adequate size is found. */ pxPreviousBlock = &xStart; pxBlock = xStart.pxNextFreeBlock; 802a2e0: 4a1f ldr r2, [pc, #124] ; (802a360 ) 802a2e2: 6814 ldr r4, [r2, #0] while( ( pxBlock->xBlockSize < xWantedSize ) && ( pxBlock->pxNextFreeBlock != NULL ) ) 802a2e4: e001 b.n 802a2ea 802a2e6: 4622 mov r2, r4 { pxPreviousBlock = pxBlock; pxBlock = pxBlock->pxNextFreeBlock; 802a2e8: 4604 mov r4, r0 { /* Traverse the list from the start (lowest address) block until one of adequate size is found. */ pxPreviousBlock = &xStart; pxBlock = xStart.pxNextFreeBlock; while( ( pxBlock->xBlockSize < xWantedSize ) && ( pxBlock->pxNextFreeBlock != NULL ) ) 802a2ea: 6861 ldr r1, [r4, #4] 802a2ec: 4299 cmp r1, r3 802a2ee: d304 bcc.n 802a2fa pxBlock = pxBlock->pxNextFreeBlock; } /* If the end marker was reached then a block of adequate size was not found. */ if( pxBlock != pxEnd ) 802a2f0: 4819 ldr r0, [pc, #100] ; (802a358 ) 802a2f2: 6800 ldr r0, [r0, #0] 802a2f4: 4284 cmp r4, r0 802a2f6: d104 bne.n 802a302 802a2f8: e024 b.n 802a344 { /* Traverse the list from the start (lowest address) block until one of adequate size is found. */ pxPreviousBlock = &xStart; pxBlock = xStart.pxNextFreeBlock; while( ( pxBlock->xBlockSize < xWantedSize ) && ( pxBlock->pxNextFreeBlock != NULL ) ) 802a2fa: 6820 ldr r0, [r4, #0] 802a2fc: 2800 cmp r0, #0 802a2fe: d1f2 bne.n 802a2e6 802a300: e7f6 b.n 802a2f0 BlockLink_t structure at its start. */ pvReturn = ( void * ) ( ( ( uint8_t * ) pxPreviousBlock->pxNextFreeBlock ) + xHeapStructSize ); /* This block is being returned for use so must be taken out of the list of free blocks. */ pxPreviousBlock->pxNextFreeBlock = pxBlock->pxNextFreeBlock; 802a302: 6820 ldr r0, [r4, #0] was not found. */ if( pxBlock != pxEnd ) { /* Return the memory space pointed to - jumping over the BlockLink_t structure at its start. */ pvReturn = ( void * ) ( ( ( uint8_t * ) pxPreviousBlock->pxNextFreeBlock ) + xHeapStructSize ); 802a304: 6815 ldr r5, [r2, #0] /* This block is being returned for use so must be taken out of the list of free blocks. */ pxPreviousBlock->pxNextFreeBlock = pxBlock->pxNextFreeBlock; 802a306: 6010 str r0, [r2, #0] /* If the block is larger than required it can be split into two. */ if( ( pxBlock->xBlockSize - xWantedSize ) > heapMINIMUM_BLOCK_SIZE ) 802a308: 1aca subs r2, r1, r3 was not found. */ if( pxBlock != pxEnd ) { /* Return the memory space pointed to - jumping over the BlockLink_t structure at its start. */ pvReturn = ( void * ) ( ( ( uint8_t * ) pxPreviousBlock->pxNextFreeBlock ) + xHeapStructSize ); 802a30a: 3508 adds r5, #8 of the list of free blocks. */ pxPreviousBlock->pxNextFreeBlock = pxBlock->pxNextFreeBlock; /* If the block is larger than required it can be split into two. */ if( ( pxBlock->xBlockSize - xWantedSize ) > heapMINIMUM_BLOCK_SIZE ) 802a30c: 2a10 cmp r2, #16 802a30e: d909 bls.n 802a324 { /* This block is to be split into two. Create a new block following the number of bytes requested. The void cast is used to prevent byte alignment warnings from the compiler. */ pxNewBlockLink = ( void * ) ( ( ( uint8_t * ) pxBlock ) + xWantedSize ); 802a310: 18e0 adds r0, r4, r3 configASSERT( ( ( ( uint32_t ) pxNewBlockLink ) & portBYTE_ALIGNMENT_MASK ) == 0 ); 802a312: 0741 lsls r1, r0, #29 802a314: d002 beq.n 802a31c 802a316: f7ff fe8f bl 802a038 802a31a: e7fe b.n 802a31a /* Calculate the sizes of two blocks split from the single block. */ pxNewBlockLink->xBlockSize = pxBlock->xBlockSize - xWantedSize; 802a31c: 6042 str r2, [r0, #4] pxBlock->xBlockSize = xWantedSize; 802a31e: 6063 str r3, [r4, #4] /* Insert the new block into the list of free blocks. */ prvInsertBlockIntoFreeList( ( pxNewBlockLink ) ); 802a320: f7ff ff7c bl 802a21c else { mtCOVERAGE_TEST_MARKER(); } xFreeBytesRemaining -= pxBlock->xBlockSize; 802a324: 6862 ldr r2, [r4, #4] 802a326: 4910 ldr r1, [pc, #64] ; (802a368 ) 802a328: 1abb subs r3, r7, r2 802a32a: 600b str r3, [r1, #0] if( xFreeBytesRemaining < xMinimumEverFreeBytesRemaining ) 802a32c: 490d ldr r1, [pc, #52] ; (802a364 ) 802a32e: 6808 ldr r0, [r1, #0] 802a330: 4283 cmp r3, r0 { xMinimumEverFreeBytesRemaining = xFreeBytesRemaining; 802a332: bf38 it cc 802a334: 600b strcc r3, [r1, #0] mtCOVERAGE_TEST_MARKER(); } /* The block is being returned - it is allocated and owned by the application and has no "next" block. */ pxBlock->xBlockSize |= xBlockAllocatedBit; 802a336: 4316 orrs r6, r2 pxBlock->pxNextFreeBlock = NULL; 802a338: 2300 movs r3, #0 802a33a: e884 0048 stmia.w r4, {r3, r6} 802a33e: e002 b.n 802a346 /*-----------------------------------------------------------*/ void *pvPortMalloc( size_t xWantedSize ) { BlockLink_t *pxBlock, *pxPreviousBlock, *pxNewBlockLink; void *pvReturn = NULL; 802a340: 461d mov r5, r3 802a342: e000 b.n 802a346 802a344: 2500 movs r5, #0 mtCOVERAGE_TEST_MARKER(); } traceMALLOC( pvReturn, xWantedSize ); } ( void ) xTaskResumeAll(); 802a346: f7ff fa17 bl 8029778 mtCOVERAGE_TEST_MARKER(); } } #endif configASSERT( ( ( ( uint32_t ) pvReturn ) & portBYTE_ALIGNMENT_MASK ) == 0 ); 802a34a: 076b lsls r3, r5, #29 802a34c: d002 beq.n 802a354 802a34e: f7ff fe73 bl 802a038 802a352: e7fe b.n 802a352 return pvReturn; } 802a354: 4628 mov r0, r5 802a356: bdf8 pop {r3, r4, r5, r6, r7, pc} 802a358: 20002a24 .word 0x20002a24 802a35c: 10000000 .word 0x10000000 802a360: 20002a28 .word 0x20002a28 802a364: 20002a30 .word 0x20002a30 802a368: 20002a20 .word 0x20002a20 802a36c: 20002a34 .word 0x20002a34 0802a370 : /*-----------------------------------------------------------*/ void vPortFree( void *pv ) { 802a370: b510 push {r4, lr} uint8_t *puc = ( uint8_t * ) pv; BlockLink_t *pxLink; if( pv != NULL ) 802a372: 4604 mov r4, r0 802a374: b310 cbz r0, 802a3bc /* This casting is to keep the compiler from issuing warnings. */ pxLink = ( void * ) puc; /* Check the block is actually allocated. */ configASSERT( ( pxLink->xBlockSize & xBlockAllocatedBit ) != 0 ); 802a376: 4a12 ldr r2, [pc, #72] ; (802a3c0 ) 802a378: f850 3c04 ldr.w r3, [r0, #-4] 802a37c: 6812 ldr r2, [r2, #0] 802a37e: 421a tst r2, r3 802a380: d102 bne.n 802a388 802a382: f7ff fe59 bl 802a038 802a386: e7fe b.n 802a386 configASSERT( pxLink->pxNextFreeBlock == NULL ); 802a388: f850 1c08 ldr.w r1, [r0, #-8] 802a38c: b111 cbz r1, 802a394 802a38e: f7ff fe53 bl 802a038 802a392: e7fe b.n 802a392 { if( pxLink->pxNextFreeBlock == NULL ) { /* The block is being returned to the heap - it is no longer allocated. */ pxLink->xBlockSize &= ~xBlockAllocatedBit; 802a394: ea23 0302 bic.w r3, r3, r2 802a398: f840 3c04 str.w r3, [r0, #-4] vTaskSuspendAll(); 802a39c: f7ff f950 bl 8029640 { /* Add this block to the list of free blocks. */ xFreeBytesRemaining += pxLink->xBlockSize; 802a3a0: 4b08 ldr r3, [pc, #32] ; (802a3c4 ) 802a3a2: f854 1c04 ldr.w r1, [r4, #-4] 802a3a6: 681a ldr r2, [r3, #0] traceFREE( pv, pxLink->xBlockSize ); prvInsertBlockIntoFreeList( ( ( BlockLink_t * ) pxLink ) ); 802a3a8: f1a4 0008 sub.w r0, r4, #8 pxLink->xBlockSize &= ~xBlockAllocatedBit; vTaskSuspendAll(); { /* Add this block to the list of free blocks. */ xFreeBytesRemaining += pxLink->xBlockSize; 802a3ac: 188a adds r2, r1, r2 802a3ae: 601a str r2, [r3, #0] traceFREE( pv, pxLink->xBlockSize ); prvInsertBlockIntoFreeList( ( ( BlockLink_t * ) pxLink ) ); 802a3b0: f7ff ff34 bl 802a21c else { mtCOVERAGE_TEST_MARKER(); } } } 802a3b4: e8bd 4010 ldmia.w sp!, {r4, lr} /* Add this block to the list of free blocks. */ xFreeBytesRemaining += pxLink->xBlockSize; traceFREE( pv, pxLink->xBlockSize ); prvInsertBlockIntoFreeList( ( ( BlockLink_t * ) pxLink ) ); } ( void ) xTaskResumeAll(); 802a3b8: f7ff b9de b.w 8029778 802a3bc: bd10 pop {r4, pc} 802a3be: bf00 nop 802a3c0: 20002a34 .word 0x20002a34 802a3c4: 20002a20 .word 0x20002a20 0802a3c8 : /** * @brief Обновление времени последней активности пользователя */ static void HTTP_UpdateUserLoginTime(uint8_t user_id) { xTimerStart(users[user_id].LogoutTimer, 0); 802a3c8: 4b07 ldr r3, [pc, #28] ; (802a3e8 ) 802a3ca: 2214 movs r2, #20 /** * @brief Обновление времени последней активности пользователя */ static void HTTP_UpdateUserLoginTime(uint8_t user_id) { 802a3cc: b513 push {r0, r1, r4, lr} xTimerStart(users[user_id].LogoutTimer, 0); 802a3ce: fb02 3000 mla r0, r2, r0, r3 802a3d2: 6904 ldr r4, [r0, #16] 802a3d4: f7ff f93c bl 8029650 802a3d8: 2300 movs r3, #0 802a3da: 4602 mov r2, r0 802a3dc: 9300 str r3, [sp, #0] 802a3de: 4620 mov r0, r4 802a3e0: 2101 movs r1, #1 802a3e2: f7ff fcd3 bl 8029d8c } 802a3e6: bd1c pop {r2, r3, r4, pc} 802a3e8: 2000fb5c .word 0x2000fb5c 0802a3ec : * @param name : pointer to a file name * @param file : pointer to a fs_file structure * @retval 1 if success, 0 if fail */ static int fs_open(char *name, struct fs_file *file) { 802a3ec: b570 push {r4, r5, r6, lr} struct fsdata_file_noconst *f; for (f = (struct fsdata_file_noconst *)FS_ROOT; f != NULL; f = (struct fsdata_file_noconst *)f->next) 802a3ee: 4c09 ldr r4, [pc, #36] ; (802a414 ) * @param name : pointer to a file name * @param file : pointer to a fs_file structure * @retval 1 if success, 0 if fail */ static int fs_open(char *name, struct fs_file *file) { 802a3f0: 4606 mov r6, r0 802a3f2: 460d mov r5, r1 struct fsdata_file_noconst *f; for (f = (struct fsdata_file_noconst *)FS_ROOT; f != NULL; f = (struct fsdata_file_noconst *)f->next) { if (!strcmp(name, f->name)) 802a3f4: 4630 mov r0, r6 802a3f6: 6861 ldr r1, [r4, #4] 802a3f8: f7f7 fbee bl 8021bd8 802a3fc: b928 cbnz r0, 802a40a { file->data = f->data; 802a3fe: 68a3 ldr r3, [r4, #8] 802a400: 602b str r3, [r5, #0] file->len = f->len; 802a402: 68e3 ldr r3, [r4, #12] return 1; 802a404: 2001 movs r0, #1 for (f = (struct fsdata_file_noconst *)FS_ROOT; f != NULL; f = (struct fsdata_file_noconst *)f->next) { if (!strcmp(name, f->name)) { file->data = f->data; file->len = f->len; 802a406: 606b str r3, [r5, #4] return 1; 802a408: bd70 pop {r4, r5, r6, pc} */ static int fs_open(char *name, struct fs_file *file) { struct fsdata_file_noconst *f; for (f = (struct fsdata_file_noconst *)FS_ROOT; f != NULL; f = (struct fsdata_file_noconst *)f->next) 802a40a: 6824 ldr r4, [r4, #0] 802a40c: 2c00 cmp r4, #0 802a40e: d1f1 bne.n 802a3f4 file->data = f->data; file->len = f->len; return 1; } } return 0; 802a410: 4620 mov r0, r4 } 802a412: bd70 pop {r4, r5, r6, pc} 802a414: 0803cd28 .word 0x0803cd28 0802a418 : * @param pcb: pointer to a tcp_pcb structure * ¶m err: Lwip stack error code * @retval err */ static err_t http_accept(void *arg, struct tcp_pcb *pcb, err_t err) { 802a418: b538 push {r3, r4, r5, lr} struct http_state *hs; /* Allocate memory for the structure that holds the state of the connection */ hs = mem_malloc(sizeof(struct http_state)); 802a41a: 2008 movs r0, #8 * @param pcb: pointer to a tcp_pcb structure * ¶m err: Lwip stack error code * @retval err */ static err_t http_accept(void *arg, struct tcp_pcb *pcb, err_t err) { 802a41c: 460c mov r4, r1 struct http_state *hs; /* Allocate memory for the structure that holds the state of the connection */ hs = mem_malloc(sizeof(struct http_state)); 802a41e: f002 fc5d bl 802ccdc if (hs == NULL) 802a422: 4601 mov r1, r0 802a424: b1a0 cbz r0, 802a450 { return ERR_MEM; } /* Initialize the structure. */ hs->file = NULL; 802a426: 2500 movs r5, #0 802a428: 6005 str r5, [r0, #0] hs->left = 0; 802a42a: 6045 str r5, [r0, #4] /* Tell TCP that this is the structure we wish to be passed for our callbacks. */ tcp_arg(pcb, hs); 802a42c: 4620 mov r0, r4 802a42e: f003 f8c3 bl 802d5b8 /* Tell TCP that we wish to be informed of incoming data by a call to the http_recv() function. */ tcp_recv(pcb, http_recv); 802a432: 4620 mov r0, r4 802a434: 4908 ldr r1, [pc, #32] ; (802a458 ) 802a436: f003 f8c1 bl 802d5bc tcp_err(pcb, conn_err); 802a43a: 4620 mov r0, r4 802a43c: 4907 ldr r1, [pc, #28] ; (802a45c ) 802a43e: f003 f8c1 bl 802d5c4 tcp_poll(pcb, http_poll, 10); 802a442: 4620 mov r0, r4 802a444: 4906 ldr r1, [pc, #24] ; (802a460 ) 802a446: 220a movs r2, #10 802a448: f003 f8c1 bl 802d5ce return ERR_OK; 802a44c: 4628 mov r0, r5 802a44e: e000 b.n 802a452 /* Allocate memory for the structure that holds the state of the connection */ hs = mem_malloc(sizeof(struct http_state)); if (hs == NULL) { return ERR_MEM; 802a450: 20ff movs r0, #255 ; 0xff tcp_err(pcb, conn_err); tcp_poll(pcb, http_poll, 10); return ERR_OK; } 802a452: b240 sxtb r0, r0 802a454: bd38 pop {r3, r4, r5, pc} 802a456: bf00 nop 802a458: 0802ae31 .word 0x0802ae31 802a45c: 0802a4a7 .word 0x0802a4a7 802a460: 0802a48f .word 0x0802a48f 0802a464 : * @param pcb: pointer to a tcp_pcb struct * @param hs: pointer to a http_state struct * @retval none */ static void send_data(struct tcp_pcb *pcb, struct http_state *hs) { 802a464: b538 push {r3, r4, r5, lr} err_t err; u16_t len; /* We cannot send more data than space available in the send buffer */ if (tcp_sndbuf(pcb) < hs->left) 802a466: 684b ldr r3, [r1, #4] 802a468: f8b0 5066 ldrh.w r5, [r0, #102] ; 0x66 802a46c: 429d cmp r5, r3 { len = tcp_sndbuf(pcb); } else { len = hs->left; 802a46e: bf28 it cs 802a470: b29d uxthcs r5, r3 * @param pcb: pointer to a tcp_pcb struct * @param hs: pointer to a http_state struct * @retval none */ static void send_data(struct tcp_pcb *pcb, struct http_state *hs) { 802a472: 460c mov r4, r1 } else { len = hs->left; } err = tcp_write(pcb, hs->file, len, 0); 802a474: 462a mov r2, r5 802a476: 6809 ldr r1, [r1, #0] 802a478: 2300 movs r3, #0 802a47a: f004 fc02 bl 802ec82 if (err == ERR_OK) 802a47e: b928 cbnz r0, 802a48c { hs->file += len; 802a480: 6823 ldr r3, [r4, #0] 802a482: 195b adds r3, r3, r5 802a484: 6023 str r3, [r4, #0] hs->left -= len; 802a486: 6863 ldr r3, [r4, #4] 802a488: 1b5d subs r5, r3, r5 802a48a: 6065 str r5, [r4, #4] 802a48c: bd38 pop {r3, r4, r5, pc} 0802a48e : * @param arg: pointer to an argument to be passed to callback function * @param pcb: pointer on tcp_pcb structure * @retval err_t */ static err_t http_poll(void *arg, struct tcp_pcb *pcb) { 802a48e: b508 push {r3, lr} if (arg == NULL) 802a490: 4603 mov r3, r0 { tcp_close(pcb); 802a492: 4608 mov r0, r1 * @param pcb: pointer on tcp_pcb structure * @retval err_t */ static err_t http_poll(void *arg, struct tcp_pcb *pcb) { if (arg == NULL) 802a494: b913 cbnz r3, 802a49c { tcp_close(pcb); 802a496: f003 fb2d bl 802daf4 802a49a: e002 b.n 802a4a2 } else { send_data(pcb, (struct http_state *)arg); 802a49c: 4619 mov r1, r3 802a49e: f7ff ffe1 bl 802a464 } return ERR_OK; } 802a4a2: 2000 movs r0, #0 802a4a4: bd08 pop {r3, pc} 0802a4a6 : static void conn_err(void *arg, err_t err) { struct http_state *hs; hs = arg; mem_free(hs); 802a4a6: f002 bb51 b.w 802cb4c 0802a4aa : * @param pcb: pointer to a tcp_pcb struct * @param hs: pointer to a http_state struct * @retval */ static void close_conn(struct tcp_pcb *pcb, struct http_state *hs) { 802a4aa: b538 push {r3, r4, r5, lr} 802a4ac: 4604 mov r4, r0 802a4ae: 460d mov r5, r1 tcp_arg(pcb, NULL); 802a4b0: 2100 movs r1, #0 802a4b2: f003 f881 bl 802d5b8 tcp_sent(pcb, NULL); 802a4b6: 4620 mov r0, r4 802a4b8: 2100 movs r1, #0 802a4ba: f003 f881 bl 802d5c0 tcp_recv(pcb, NULL); 802a4be: 4620 mov r0, r4 802a4c0: 2100 movs r1, #0 802a4c2: f003 f87b bl 802d5bc mem_free(hs); 802a4c6: 4628 mov r0, r5 802a4c8: f002 fb40 bl 802cb4c tcp_close(pcb); 802a4cc: 4620 mov r0, r4 } 802a4ce: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} { tcp_arg(pcb, NULL); tcp_sent(pcb, NULL); tcp_recv(pcb, NULL); mem_free(hs); tcp_close(pcb); 802a4d2: f003 bb0f b.w 802daf4 0802a4d6 : * @param pcb: pointer on tcp_pcb structure * @param len * @retval err : LwIP error code */ static err_t http_sent(void *arg, struct tcp_pcb *pcb, u16_t len) { 802a4d6: b508 push {r3, lr} 802a4d8: 4603 mov r3, r0 802a4da: 4608 mov r0, r1 struct http_state *hs; hs = arg; if (hs->left > 0) 802a4dc: 685a ldr r2, [r3, #4] { send_data(pcb, hs); 802a4de: 4619 mov r1, r3 { struct http_state *hs; hs = arg; if (hs->left > 0) 802a4e0: b112 cbz r2, 802a4e8 { send_data(pcb, hs); 802a4e2: f7ff ffbf bl 802a464 802a4e6: e001 b.n 802a4ec } else { close_conn(pcb, hs); 802a4e8: f7ff ffdf bl 802a4aa } return ERR_OK; } 802a4ec: 2000 movs r0, #0 802a4ee: bd08 pop {r3, pc} 0802a4f0 : } /** * @brief >Callback таймера логаута пользователя */ void LogoutTimerCallback(TimerHandle_t pxTimer) { 802a4f0: b51f push {r0, r1, r2, r3, r4, lr} uint8_t user_id = (uint8_t)pvTimerGetTimerID( pxTimer ); 802a4f2: f7ff fd63 bl 8029fbc 802a4f6: 4604 mov r4, r0 static void HTTP_ForceUserLogout(uint8_t user_id) { char cookie[MAX_WEB_COOKIE_LEN]; /* Flush user cookie by random value */ sprintf(cookie, "%X", (unsigned int)GetRandomNumber()); 802a4f8: f7fb fde8 bl 80260cc 802a4fc: 4906 ldr r1, [pc, #24] ; (802a518 ) 802a4fe: 4602 mov r2, r0 802a500: 4668 mov r0, sp 802a502: f7fd f91f bl 8027744 /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a506: 4b05 ldr r3, [pc, #20] ; (802a51c ) 802a508: b2e0 uxtb r0, r4 802a50a: 2214 movs r2, #20 802a50c: fb00 3002 mla r0, r0, r2, r3 802a510: 4669 mov r1, sp 802a512: f7f7 fc4f bl 8021db4 */ void LogoutTimerCallback(TimerHandle_t pxTimer) { uint8_t user_id = (uint8_t)pvTimerGetTimerID( pxTimer ); HTTP_ForceUserLogout(user_id); } 802a516: bd1f pop {r0, r1, r2, r3, r4, pc} 802a518: 0803a02c .word 0x0803a02c 802a51c: 2000fb5c .word 0x2000fb5c 0802a520 : * @brief Initialize the HTTP server (start its thread) * @param none * @retval None */ void HTTP_Init() { 802a520: b5f0 push {r4, r5, r6, r7, lr} 802a522: b087 sub sp, #28 char buf[MAX_WEB_COOKIE_LEN]; uint8_t user_id; //sys_thread_new("HTTP", http_server_netconn_thread, NULL, 3000, 2); struct tcp_pcb *pcb; /*create new pcb*/ pcb = tcp_new(); 802a524: f003 fc14 bl 802dd50 /* bind HTTP traffic to pcb */ tcp_bind(pcb, IP_ADDR_ANY, 80); 802a528: 2250 movs r2, #80 ; 0x50 char buf[MAX_WEB_COOKIE_LEN]; uint8_t user_id; //sys_thread_new("HTTP", http_server_netconn_thread, NULL, 3000, 2); struct tcp_pcb *pcb; /*create new pcb*/ pcb = tcp_new(); 802a52a: 4604 mov r4, r0 /* bind HTTP traffic to pcb */ tcp_bind(pcb, IP_ADDR_ANY, 80); 802a52c: 4913 ldr r1, [pc, #76] ; (802a57c ) /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a52e: 4f14 ldr r7, [pc, #80] ; (802a580 ) sprintf(buf, "%X", (unsigned int)GetRandomNumber()); HTTP_SetUserCookie(buf, user_id); /* Create user logout timers */ users[user_id].LogoutTimer = xTimerCreate("LogoutTmr", WEB_LOGOUT_TIME, pdFALSE, ( void * ) user_id, LogoutTimerCallback); 802a530: 4e14 ldr r6, [pc, #80] ; (802a584 ) //sys_thread_new("HTTP", http_server_netconn_thread, NULL, 3000, 2); struct tcp_pcb *pcb; /*create new pcb*/ pcb = tcp_new(); /* bind HTTP traffic to pcb */ tcp_bind(pcb, IP_ADDR_ANY, 80); 802a532: f002 ff6f bl 802d414 /* start listening on port 80 */ pcb = tcp_listen(pcb); 802a536: 4620 mov r0, r4 802a538: 21ff movs r1, #255 ; 0xff 802a53a: f002 ffa3 bl 802d484 /* define callback function for TCP connection setup */ tcp_accept(pcb, http_accept); 802a53e: 4912 ldr r1, [pc, #72] ; (802a588 ) 802a540: f003 f843 bl 802d5ca 802a544: 2400 movs r4, #0 for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { /* Flush user cookie by random value */ sprintf(buf, "%X", (unsigned int)GetRandomNumber()); 802a546: f7fb fdc1 bl 80260cc /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a54a: 2514 movs r5, #20 pcb = tcp_listen(pcb); /* define callback function for TCP connection setup */ tcp_accept(pcb, http_accept); for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { /* Flush user cookie by random value */ sprintf(buf, "%X", (unsigned int)GetRandomNumber()); 802a54c: 4602 mov r2, r0 /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a54e: fb05 7504 mla r5, r5, r4, r7 pcb = tcp_listen(pcb); /* define callback function for TCP connection setup */ tcp_accept(pcb, http_accept); for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { /* Flush user cookie by random value */ sprintf(buf, "%X", (unsigned int)GetRandomNumber()); 802a552: 490e ldr r1, [pc, #56] ; (802a58c ) 802a554: a802 add r0, sp, #8 802a556: f7fd f8f5 bl 8027744 /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a55a: a902 add r1, sp, #8 802a55c: 4628 mov r0, r5 802a55e: f7f7 fc29 bl 8021db4 sprintf(buf, "%X", (unsigned int)GetRandomNumber()); HTTP_SetUserCookie(buf, user_id); /* Create user logout timers */ users[user_id].LogoutTimer = xTimerCreate("LogoutTmr", WEB_LOGOUT_TIME, pdFALSE, ( void * ) user_id, LogoutTimerCallback); 802a562: 2200 movs r2, #0 802a564: 4623 mov r3, r4 802a566: 9600 str r6, [sp, #0] 802a568: 4809 ldr r0, [pc, #36] ; (802a590 ) 802a56a: 490a ldr r1, [pc, #40] ; (802a594 ) 802a56c: f7ff fbee bl 8029d4c 802a570: 3401 adds r4, #1 tcp_bind(pcb, IP_ADDR_ANY, 80); /* start listening on port 80 */ pcb = tcp_listen(pcb); /* define callback function for TCP connection setup */ tcp_accept(pcb, http_accept); for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 802a572: 2c02 cmp r4, #2 /* Flush user cookie by random value */ sprintf(buf, "%X", (unsigned int)GetRandomNumber()); HTTP_SetUserCookie(buf, user_id); /* Create user logout timers */ users[user_id].LogoutTimer = 802a574: 6128 str r0, [r5, #16] tcp_bind(pcb, IP_ADDR_ANY, 80); /* start listening on port 80 */ pcb = tcp_listen(pcb); /* define callback function for TCP connection setup */ tcp_accept(pcb, http_accept); for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 802a576: d1e6 bne.n 802a546 /* Create user logout timers */ users[user_id].LogoutTimer = xTimerCreate("LogoutTmr", WEB_LOGOUT_TIME, pdFALSE, ( void * ) user_id, LogoutTimerCallback); } } 802a578: b007 add sp, #28 802a57a: bdf0 pop {r4, r5, r6, r7, pc} 802a57c: 0803fe88 .word 0x0803fe88 802a580: 2000fb5c .word 0x2000fb5c 802a584: 0802a4f1 .word 0x0802a4f1 802a588: 0802a419 .word 0x0802a419 802a58c: 0803a02c .word 0x0803a02c 802a590: 0803a02f .word 0x0803a02f 802a594: 001b7740 .word 0x001b7740 0802a598 : /** * @brief Возвращает uptime, freq, dutycicle */ void HTTP_Progon(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a598: b538 push {r3, r4, r5, lr} memset(bufOut, 0, SEND_BUF_MAX_LEN); 802a59a: f44f 62fa mov.w r2, #2000 ; 0x7d0 /** * @brief Возвращает uptime, freq, dutycicle */ void HTTP_Progon(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a59e: 460c mov r4, r1 memset(bufOut, 0, SEND_BUF_MAX_LEN); 802a5a0: 4608 mov r0, r1 802a5a2: 2100 movs r1, #0 /** * @brief Возвращает uptime, freq, dutycicle */ void HTTP_Progon(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a5a4: 461d mov r5, r3 memset(bufOut, 0, SEND_BUF_MAX_LEN); 802a5a6: f7f7 fa8b bl 8021ac0 HTTP_GetProgonParams(bufOut); 802a5aa: 4620 mov r0, r4 802a5ac: f001 fb22 bl 802bbf4 *lenBufOut = strlen(bufOut); 802a5b0: 4620 mov r0, r4 802a5b2: f7f7 fc5d bl 8021e70 802a5b6: 8028 strh r0, [r5, #0] 802a5b8: bd38 pop {r3, r4, r5, pc} 802a5ba: 0000 movs r0, r0 0802a5bc : /** * @brief * @retval None */ uint8_t GetParamValue(char *inStr, char *paramName, char *paramValue, uint8_t *paramLen) { 802a5bc: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802a5c0: 4690 mov r8, r2 802a5c2: 461f mov r7, r3 char *beginValue = 0; char *endValue = 0; int len = 0; char *strPtr = 0; strPtr = strstr(inStr, paramName); 802a5c4: f7f7 fed4 bl 8022370 if (strPtr != 0) 802a5c8: 4605 mov r5, r0 802a5ca: b1e0 cbz r0, 802a606 { beginValue = strpbrk(strPtr,"="); 802a5cc: 490f ldr r1, [pc, #60] ; (802a60c ) 802a5ce: f7f7 fd39 bl 8022044 endValue = strpbrk(strPtr,"&"); 802a5d2: 490f ldr r1, [pc, #60] ; (802a610 ) strPtr = strstr(inStr, paramName); if (strPtr != 0) { beginValue = strpbrk(strPtr,"="); 802a5d4: 4606 mov r6, r0 endValue = strpbrk(strPtr,"&"); 802a5d6: 4628 mov r0, r5 802a5d8: f7f7 fd34 bl 8022044 if (endValue == 0) 802a5dc: 4604 mov r4, r0 802a5de: b920 cbnz r0, 802a5ea endValue = strpbrk(strPtr," "); 802a5e0: 4628 mov r0, r5 802a5e2: 490c ldr r1, [pc, #48] ; (802a614 ) 802a5e4: f7f7 fd2e bl 8022044 802a5e8: 4604 mov r4, r0 len = endValue - beginValue - 1; 802a5ea: 1ba5 subs r5, r4, r6 802a5ec: 3d01 subs r5, #1 strncpy(paramValue, beginValue + 1, len); 802a5ee: 4640 mov r0, r8 802a5f0: 1c71 adds r1, r6, #1 802a5f2: 462a mov r2, r5 802a5f4: f7f7 fcf4 bl 8021fe0 *endValue = '0'; 802a5f8: 2330 movs r3, #48 ; 0x30 802a5fa: 7023 strb r3, [r4, #0] *beginValue = '0'; *paramLen = len; return 1; 802a5fc: 2001 movs r0, #1 if (endValue == 0) endValue = strpbrk(strPtr," "); len = endValue - beginValue - 1; strncpy(paramValue, beginValue + 1, len); *endValue = '0'; *beginValue = '0'; 802a5fe: 7033 strb r3, [r6, #0] *paramLen = len; 802a600: 703d strb r5, [r7, #0] return 1; 802a602: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} } else { *paramLen = 0; 802a606: 7038 strb r0, [r7, #0] return 0; } } 802a608: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802a60c: 0803a205 .word 0x0803a205 802a610: 0803a039 .word 0x0803a039 802a614: 08035f57 .word 0x08035f57 0802a618 : /** * @brief Проверка пароля для входа в Web * @retval None */ int HTTP_ConfirmWebPwd(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a618: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802a61c: b0a8 sub sp, #160 ; 0xa0 802a61e: 4604 mov r4, r0 char *strPtr = 0; char WebPassword[MAX_WEB_PASSWD_LEN]; char WebLogin[MAX_WEB_LOGIN_LEN]; char buf[40]; memset(login, 0, 20); 802a620: 2214 movs r2, #20 /** * @brief Проверка пароля для входа в Web * @retval None */ int HTTP_ConfirmWebPwd(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a622: 460d mov r5, r1 char *strPtr = 0; char WebPassword[MAX_WEB_PASSWD_LEN]; char WebLogin[MAX_WEB_LOGIN_LEN]; char buf[40]; memset(login, 0, 20); 802a624: a807 add r0, sp, #28 802a626: 2100 movs r1, #0 /** * @brief Проверка пароля для входа в Web * @retval None */ int HTTP_ConfirmWebPwd(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a628: 4698 mov r8, r3 char *strPtr = 0; char WebPassword[MAX_WEB_PASSWD_LEN]; char WebLogin[MAX_WEB_LOGIN_LEN]; char buf[40]; memset(login, 0, 20); 802a62a: f7f7 fa49 bl 8021ac0 memset(password, 0, 20); 802a62e: 2100 movs r1, #0 802a630: 2214 movs r2, #20 802a632: a80c add r0, sp, #48 ; 0x30 802a634: f7f7 fa44 bl 8021ac0 memset(tempStr, 0, 50); 802a638: 2100 movs r1, #0 802a63a: 2232 movs r2, #50 ; 0x32 802a63c: a81b add r0, sp, #108 ; 0x6c 802a63e: f7f7 fa3f bl 8021ac0 /* Get first 50 bytes of string */ strncpy(tempStr, bufIn, 49); 802a642: 2231 movs r2, #49 ; 0x31 802a644: 4621 mov r1, r4 802a646: a81b add r0, sp, #108 ; 0x6c 802a648: f7f7 fcca bl 8021fe0 /* Add " " to the string in order GetParamValue() can be able to parse the param */ strcat(tempStr, " "); if (GetParamValue(tempStr, "login=", login, &valueLen) && 802a64c: f10d 0603 add.w r6, sp, #3 /* Get first 50 bytes of string */ strncpy(tempStr, bufIn, 49); /* Add " " to the string in order GetParamValue() can be able to parse the param */ strcat(tempStr, " "); 802a650: 4941 ldr r1, [pc, #260] ; (802a758 ) 802a652: a81b add r0, sp, #108 ; 0x6c 802a654: f7f7 fa9a bl 8021b8c if (GetParamValue(tempStr, "login=", login, &valueLen) && 802a658: a81b add r0, sp, #108 ; 0x6c 802a65a: 4940 ldr r1, [pc, #256] ; (802a75c ) 802a65c: aa07 add r2, sp, #28 802a65e: 4633 mov r3, r6 802a660: f7ff ffac bl 802a5bc 802a664: b920 cbnz r0, 802a670 } } /* No valid login and pass found */ /* TODO replace global flag with user-pass-cookie*/ Authenticated = false; 802a666: 4b3e ldr r3, [pc, #248] ; (802a760 ) 802a668: 2200 movs r2, #0 802a66a: 701a strb r2, [r3, #0] /* Wrong login or pass, return */ return SEND_REQUIRED_NO; 802a66c: 2001 movs r0, #1 802a66e: e06f b.n 802a750 /* Add " " to the string in order GetParamValue() can be able to parse the param */ strcat(tempStr, " "); if (GetParamValue(tempStr, "login=", login, &valueLen) && GetParamValue(tempStr, "password=", password, &valueLen)) 802a670: a81b add r0, sp, #108 ; 0x6c 802a672: 493c ldr r1, [pc, #240] ; (802a764 ) 802a674: aa0c add r2, sp, #48 ; 0x30 802a676: 4633 mov r3, r6 802a678: f7ff ffa0 bl 802a5bc strncpy(tempStr, bufIn, 49); /* Add " " to the string in order GetParamValue() can be able to parse the param */ strcat(tempStr, " "); if (GetParamValue(tempStr, "login=", login, &valueLen) && 802a67c: 2800 cmp r0, #0 802a67e: d0f2 beq.n 802a666 802a680: 2400 movs r4, #0 GetParamValue(tempStr, "password=", password, &valueLen)) { for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { GetUserLogin(user_id, WebLogin, &valueLen); 802a682: 4637 mov r7, r6 802a684: 4620 mov r0, r4 802a686: a904 add r1, sp, #16 802a688: 463a mov r2, r7 802a68a: f7fd fad7 bl 8027c3c GetUserPassword(user_id, WebPassword, &valueLen); 802a68e: 4620 mov r0, r4 802a690: a901 add r1, sp, #4 802a692: 463a mov r2, r7 802a694: f7fd fae8 bl 8027c68 /* Check login and password */ if ((strncmp(WebLogin, login, MAX_WEB_LOGIN_LEN) == 0) && 802a698: a804 add r0, sp, #16 802a69a: a907 add r1, sp, #28 802a69c: 220b movs r2, #11 802a69e: f7f7 fc49 bl 8021f34 802a6a2: 2800 cmp r0, #0 802a6a4: d14f bne.n 802a746 (strncmp(WebPassword, password, MAX_WEB_PASSWD_LEN) == 0)) { 802a6a6: a801 add r0, sp, #4 802a6a8: a90c add r1, sp, #48 ; 0x30 802a6aa: 220b movs r2, #11 802a6ac: f7f7 fc42 bl 8021f34 GetUserLogin(user_id, WebLogin, &valueLen); GetUserPassword(user_id, WebPassword, &valueLen); /* Check login and password */ if ((strncmp(WebLogin, login, MAX_WEB_LOGIN_LEN) == 0) && 802a6b0: 4606 mov r6, r0 802a6b2: 2800 cmp r0, #0 802a6b4: d147 bne.n 802a746 if (user_id >= 1) { } /* TODO replace global flag with user-pass-cookie */ Authenticated = true; 802a6b6: 4b2a ldr r3, [pc, #168] ; (802a760 ) 802a6b8: 2201 movs r2, #1 802a6ba: 701a strb r2, [r3, #0] /* Generate cookie */ sprintf(tempStr, "%X", (unsigned int)GetRandomNumber()); 802a6bc: f7fb fd06 bl 80260cc 802a6c0: 4929 ldr r1, [pc, #164] ; (802a768 ) 802a6c2: 4602 mov r2, r0 802a6c4: a81b add r0, sp, #108 ; 0x6c 802a6c6: f7fd f83d bl 8027744 /** * @brief Установка Cookie пользователя */ static void HTTP_SetUserCookie(char *str, uint8_t user_id) { strcpy(users[user_id].cookie, str); 802a6ca: 4b28 ldr r3, [pc, #160] ; (802a76c ) 802a6cc: 2014 movs r0, #20 802a6ce: fb00 3004 mla r0, r0, r4, r3 802a6d2: a91b add r1, sp, #108 ; 0x6c 802a6d4: f7f7 fb6e bl 8021db4 sprintf(tempStr, "%X", (unsigned int)GetRandomNumber()); /* Set users cookie */ HTTP_SetUserCookie(tempStr, user_id); HTTP_UpdateUserLoginTime(user_id); 802a6d8: 4620 mov r0, r4 802a6da: f7ff fe75 bl 802a3c8 /* Send login and cookie back */ strcpy(bufOut, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\nSet-Cookie: uname="); 802a6de: 4924 ldr r1, [pc, #144] ; (802a770 ) 802a6e0: 4628 mov r0, r5 802a6e2: f7f7 fb67 bl 8021db4 strcat(bufOut, WebLogin); 802a6e6: a904 add r1, sp, #16 802a6e8: 4628 mov r0, r5 802a6ea: f7f7 fa4f bl 8021b8c strcat(bufOut, "\r\nSet-Cookie: id="); 802a6ee: 4921 ldr r1, [pc, #132] ; (802a774 ) 802a6f0: 4628 mov r0, r5 802a6f2: f7f7 fa4b bl 8021b8c strcat(bufOut, tempStr); 802a6f6: a91b add r1, sp, #108 ; 0x6c 802a6f8: 4628 mov r0, r5 802a6fa: f7f7 fa47 bl 8021b8c sprintf(tempStr, "%d", user_id); 802a6fe: 4622 mov r2, r4 802a700: 491d ldr r1, [pc, #116] ; (802a778 ) 802a702: a81b add r0, sp, #108 ; 0x6c 802a704: f7fd f81e bl 8027744 strcat(bufOut, "\r\nSet-Cookie: role="); 802a708: 491c ldr r1, [pc, #112] ; (802a77c ) 802a70a: 4628 mov r0, r5 802a70c: f7f7 fa3e bl 8021b8c strcat(bufOut, tempStr); 802a710: a91b add r1, sp, #108 ; 0x6c 802a712: 4628 mov r0, r5 802a714: f7f7 fa3a bl 8021b8c strcat(bufOut, "\r\n\r\n"); 802a718: 4919 ldr r1, [pc, #100] ; (802a780 ) 802a71a: 4628 mov r0, r5 802a71c: f7f7 fa36 bl 8021b8c strcat(bufOut,"\r\n\r\n"); 802a720: 4918 ldr r1, [pc, #96] ; (802a784 ) 802a722: 4628 mov r0, r5 802a724: f7f7 fa32 bl 8021b8c *lenBufOut = strlen(bufOut); 802a728: 4628 mov r0, r5 802a72a: f7f7 fba1 bl 8021e70 switch (user_id) { case 0: snprintf(buf, sizeof(buf), "Администратор"); break; case 1: snprintf(buf, sizeof(buf), "Пользователь"); 802a72e: 2128 movs r1, #40 ; 0x28 strcat(bufOut, "\r\n\r\n"); strcat(bufOut,"\r\n\r\n"); *lenBufOut = strlen(bufOut); switch (user_id) { 802a730: 2c01 cmp r4, #1 strcat(bufOut, "\r\nSet-Cookie: role="); strcat(bufOut, tempStr); strcat(bufOut, "\r\n\r\n"); strcat(bufOut,"\r\n\r\n"); *lenBufOut = strlen(bufOut); 802a732: f8a8 0000 strh.w r0, [r8] switch (user_id) { case 0: snprintf(buf, sizeof(buf), "Администратор"); 802a736: bf14 ite ne 802a738: 4a13 ldrne r2, [pc, #76] ; (802a788 ) break; case 1: snprintf(buf, sizeof(buf), "Пользователь"); 802a73a: 4a14 ldreq r2, [pc, #80] ; (802a78c ) 802a73c: a811 add r0, sp, #68 ; 0x44 802a73e: f7fc ffe3 bl 8027708 break; } /* Запускаем задачу-таймер логаута. */ /* TODO отправить ответ серверу о статусе пароля */ return SEND_REQUIRED_YES; 802a742: 4630 mov r0, r6 case 0: snprintf(buf, sizeof(buf), "Администратор"); break; case 1: snprintf(buf, sizeof(buf), "Пользователь"); break; 802a744: e004 b.n 802a750 strcat(tempStr, " "); if (GetParamValue(tempStr, "login=", login, &valueLen) && GetParamValue(tempStr, "password=", password, &valueLen)) { for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 802a746: 3401 adds r4, #1 802a748: b2e4 uxtb r4, r4 802a74a: 2c02 cmp r4, #2 802a74c: d08b beq.n 802a666 802a74e: e799 b.n 802a684 /* TODO replace global flag with user-pass-cookie*/ Authenticated = false; /* Wrong login or pass, return */ return SEND_REQUIRED_NO; } 802a750: b028 add sp, #160 ; 0xa0 802a752: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802a756: bf00 nop 802a758: 08035f57 .word 0x08035f57 802a75c: 0803a03b .word 0x0803a03b 802a760: 20002a39 .word 0x20002a39 802a764: 0803a042 .word 0x0803a042 802a768: 0803a02c .word 0x0803a02c 802a76c: 2000fb5c .word 0x2000fb5c 802a770: 0803a04c .word 0x0803a04c 802a774: 0803a088 .word 0x0803a088 802a778: 08035e55 .word 0x08035e55 802a77c: 0803a09a .word 0x0803a09a 802a780: 0803a115 .word 0x0803a115 802a784: 0803a0ae .word 0x0803a0ae 802a788: 0803a11a .word 0x0803a11a 802a78c: 0803a135 .word 0x0803a135 0802a790 : /** * @brief Проверка пароля для перехода в режим bootloader * @retval None */ void HTTP_ConfirmBootPwd(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a790: b530 push {r4, r5, lr} 802a792: 4602 mov r2, r0 802a794: b095 sub sp, #84 ; 0x54 802a796: 460c mov r4, r1 char tempStr[50]; strncpy(tempStr, bufIn, 50); 802a798: a807 add r0, sp, #28 802a79a: 4611 mov r1, r2 802a79c: 2232 movs r2, #50 ; 0x32 /** * @brief Проверка пароля для перехода в режим bootloader * @retval None */ void HTTP_ConfirmBootPwd(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802a79e: 461d mov r5, r3 char tempStr[50]; strncpy(tempStr, bufIn, 50); 802a7a0: f7f7 fc1e bl 8021fe0 char value[20]; uint8_t valueLen; memset(value, 0, 20); 802a7a4: 2100 movs r1, #0 802a7a6: 2214 movs r2, #20 802a7a8: a802 add r0, sp, #8 802a7aa: f7f7 f989 bl 8021ac0 if (GetParamValue(tempStr, "password=", value, &valueLen)) 802a7ae: a807 add r0, sp, #28 802a7b0: 490b ldr r1, [pc, #44] ; (802a7e0 ) 802a7b2: aa02 add r2, sp, #8 802a7b4: f10d 0307 add.w r3, sp, #7 802a7b8: f7ff ff00 bl 802a5bc 802a7bc: b170 cbz r0, 802a7dc { if (strcmp(BOOTLOADER_PASWORD, value) == 0) 802a7be: 4809 ldr r0, [pc, #36] ; (802a7e4 ) 802a7c0: a902 add r1, sp, #8 802a7c2: f7f7 fa09 bl 8021bd8 802a7c6: b928 cbnz r0, 802a7d4 { *bufOut = '1'; 802a7c8: 2331 movs r3, #49 ; 0x31 802a7ca: 7023 strb r3, [r4, #0] /* Запускаем задачу отложенной перезагрузки. Контроллер должен успеть отправить ответ серверу о статусе пароля */ HTTP_StartResetTask(true); 802a7cc: 2001 movs r0, #1 802a7ce: f001 fa55 bl 802bc7c 802a7d2: e001 b.n 802a7d8 } else *bufOut = '0'; 802a7d4: 2330 movs r3, #48 ; 0x30 802a7d6: 7023 strb r3, [r4, #0] *lenBufOut = 1; 802a7d8: 2301 movs r3, #1 802a7da: 802b strh r3, [r5, #0] } } 802a7dc: b015 add sp, #84 ; 0x54 802a7de: bd30 pop {r4, r5, pc} 802a7e0: 0803a042 .word 0x0803a042 802a7e4: 0803a14e .word 0x0803a14e 0802a7e8 : /** * @brief * @retval None */ uint8_t GetCookieValue(char *inStr, char *paramName, char *paramValue, uint8_t *paramLen) { 802a7e8: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802a7ec: 4690 mov r8, r2 802a7ee: 461f mov r7, r3 char *beginValue = 0; char *endValue = 0; int len = 0; char *strPtr = 0; strPtr = strstr(inStr, paramName); 802a7f0: f7f7 fdbe bl 8022370 if (strPtr != 0) 802a7f4: 4605 mov r5, r0 802a7f6: b1e0 cbz r0, 802a832 { beginValue = strpbrk(strPtr,"="); 802a7f8: 490f ldr r1, [pc, #60] ; (802a838 ) 802a7fa: f7f7 fc23 bl 8022044 endValue = strpbrk(strPtr,";"); 802a7fe: 490f ldr r1, [pc, #60] ; (802a83c ) strPtr = strstr(inStr, paramName); if (strPtr != 0) { beginValue = strpbrk(strPtr,"="); 802a800: 4606 mov r6, r0 endValue = strpbrk(strPtr,";"); 802a802: 4628 mov r0, r5 802a804: f7f7 fc1e bl 8022044 if (endValue == 0) 802a808: 4604 mov r4, r0 802a80a: b920 cbnz r0, 802a816 endValue = strpbrk(strPtr,"\n"); 802a80c: 4628 mov r0, r5 802a80e: 490c ldr r1, [pc, #48] ; (802a840 ) 802a810: f7f7 fc18 bl 8022044 802a814: 4604 mov r4, r0 len = endValue - beginValue - 1; 802a816: 1ba5 subs r5, r4, r6 802a818: 3d01 subs r5, #1 strncpy(paramValue, beginValue + 1, len); 802a81a: 4640 mov r0, r8 802a81c: 1c71 adds r1, r6, #1 802a81e: 462a mov r2, r5 802a820: f7f7 fbde bl 8021fe0 *endValue = '0'; 802a824: 2330 movs r3, #48 ; 0x30 802a826: 7023 strb r3, [r4, #0] *beginValue = '0'; *paramLen = len; return 1; 802a828: 2001 movs r0, #1 if (endValue == 0) endValue = strpbrk(strPtr,"\n"); len = endValue - beginValue - 1; strncpy(paramValue, beginValue + 1, len); *endValue = '0'; *beginValue = '0'; 802a82a: 7033 strb r3, [r6, #0] *paramLen = len; 802a82c: 703d strb r5, [r7, #0] return 1; 802a82e: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} } else { *paramLen = 0; 802a832: 7038 strb r0, [r7, #0] return 0; } } 802a834: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802a838: 0803a205 .word 0x0803a205 802a83c: 0803a157 .word 0x0803a157 802a840: 0803a118 .word 0x0803a118 0802a844 : } } */ void ClearParamString(char *inBuf) { 802a844: b510 push {r4, lr} uint16_t len; char *str; str = strstr(inBuf, "HTTP"); 802a846: 4908 ldr r1, [pc, #32] ; (802a868 ) } } */ void ClearParamString(char *inBuf) { 802a848: 4604 mov r4, r0 uint16_t len; char *str; str = strstr(inBuf, "HTTP"); 802a84a: f7f7 fd91 bl 8022370 if (str != 0) 802a84e: b148 cbz r0, 802a864 { len = str - inBuf; 802a850: 1b02 subs r2, r0, r4 memset(str, 0, RECIVE_BUF_MAX_LEN - len - 1); 802a852: b292 uxth r2, r2 802a854: f5c2 62bb rsb r2, r2, #1496 ; 0x5d8 802a858: 2100 movs r1, #0 802a85a: 3203 adds r2, #3 } } 802a85c: e8bd 4010 ldmia.w sp!, {r4, lr} str = strstr(inBuf, "HTTP"); if (str != 0) { len = str - inBuf; memset(str, 0, RECIVE_BUF_MAX_LEN - len - 1); 802a860: f7f7 b92e b.w 8021ac0 802a864: bd10 pop {r4, pc} 802a866: bf00 nop 802a868: 0803a159 .word 0x0803a159 0802a86c : /** * @brief * @retval None */ void HTTP_SetSettings(char *buf, uint16_t lenBuf) { 802a86c: b530 push {r4, r5, lr} 802a86e: b0a3 sub sp, #140 ; 0x8c uint8_t valueLen = 0; 802a870: 2500 movs r5, #0 /** * @brief * @retval None */ void HTTP_SetSettings(char *buf, uint16_t lenBuf) { 802a872: 4604 mov r4, r0 uint8_t valueLen = 0; 802a874: f88d 5007 strb.w r5, [sp, #7] char value[MAX_WEB_PARAM_LEN]; char str[MAX_WEB_PARAM_LEN]; //printf(buf); ClearParamString(buf); 802a878: f7ff ffe4 bl 802a844 memset(value, 0, len); 802a87c: 2240 movs r2, #64 ; 0x40 802a87e: 4629 mov r1, r5 802a880: a802 add r0, sp, #8 802a882: f7f7 f91d bl 8021ac0 memset(str, 0, MAX_WEB_PARAM_LEN); 802a886: 2240 movs r2, #64 ; 0x40 802a888: 4629 mov r1, r5 802a88a: a812 add r0, sp, #72 ; 0x48 802a88c: f7f7 f918 bl 8021ac0 /* SNMP */ GetParamValue(buf, "read_community=", value, &valueLen); 802a890: f10d 0307 add.w r3, sp, #7 802a894: 49a5 ldr r1, [pc, #660] ; (802ab2c ) 802a896: aa02 add r2, sp, #8 802a898: 4620 mov r0, r4 802a89a: f7ff fe8f bl 802a5bc SetReadCommunity(value); 802a89e: a802 add r0, sp, #8 802a8a0: f7fd fb86 bl 8027fb0 memset(value, 0, len); 802a8a4: 2240 movs r2, #64 ; 0x40 802a8a6: 4629 mov r1, r5 802a8a8: a802 add r0, sp, #8 802a8aa: f7f7 f909 bl 8021ac0 GetParamValue(buf, "write_community=", value, &valueLen); 802a8ae: f10d 0307 add.w r3, sp, #7 802a8b2: 499f ldr r1, [pc, #636] ; (802ab30 ) 802a8b4: aa02 add r2, sp, #8 802a8b6: 4620 mov r0, r4 802a8b8: f7ff fe80 bl 802a5bc SetWriteCommunity(value); 802a8bc: a802 add r0, sp, #8 802a8be: f7fd fb7d bl 8027fbc memset(value, 0, len); 802a8c2: 2240 movs r2, #64 ; 0x40 802a8c4: 4629 mov r1, r5 802a8c6: a802 add r0, sp, #8 802a8c8: f7f7 f8fa bl 8021ac0 GetParamValue(buf, "managerIP=", value, &valueLen); 802a8cc: f10d 0307 add.w r3, sp, #7 802a8d0: 4998 ldr r1, [pc, #608] ; (802ab34 ) 802a8d2: aa02 add r2, sp, #8 802a8d4: 4620 mov r0, r4 802a8d6: f7ff fe71 bl 802a5bc SetManagerIp(value); 802a8da: a802 add r0, sp, #8 802a8dc: f7fd fb74 bl 8027fc8 memset(value, 0, len); 802a8e0: 2240 movs r2, #64 ; 0x40 802a8e2: 4629 mov r1, r5 802a8e4: a802 add r0, sp, #8 802a8e6: f7f7 f8eb bl 8021ac0 GetParamValue(buf, "managerIP2=", value, &valueLen); 802a8ea: f10d 0307 add.w r3, sp, #7 802a8ee: 4992 ldr r1, [pc, #584] ; (802ab38 ) 802a8f0: aa02 add r2, sp, #8 802a8f2: 4620 mov r0, r4 802a8f4: f7ff fe62 bl 802a5bc SetManagerIp2(value); 802a8f8: a802 add r0, sp, #8 802a8fa: f7fd fb73 bl 8027fe4 memset(value, 0, len); 802a8fe: 2240 movs r2, #64 ; 0x40 802a900: 4629 mov r1, r5 802a902: a802 add r0, sp, #8 802a904: f7f7 f8dc bl 8021ac0 GetParamValue(buf, "managerIP3=", value, &valueLen); 802a908: f10d 0307 add.w r3, sp, #7 802a90c: 498b ldr r1, [pc, #556] ; (802ab3c ) 802a90e: aa02 add r2, sp, #8 802a910: 4620 mov r0, r4 802a912: f7ff fe53 bl 802a5bc SetManagerIp3(value); 802a916: a802 add r0, sp, #8 802a918: f7fd fb72 bl 8028000 memset(value, 0, len); 802a91c: 2240 movs r2, #64 ; 0x40 802a91e: 4629 mov r1, r5 802a920: a802 add r0, sp, #8 802a922: f7f7 f8cd bl 8021ac0 GetParamValue(buf, "managerIP4=", value, &valueLen); 802a926: f10d 0307 add.w r3, sp, #7 802a92a: 4985 ldr r1, [pc, #532] ; (802ab40 ) 802a92c: aa02 add r2, sp, #8 802a92e: 4620 mov r0, r4 802a930: f7ff fe44 bl 802a5bc SetManagerIp4(value); 802a934: a802 add r0, sp, #8 802a936: f7fd fb71 bl 802801c memset(value, 0, len); 802a93a: 2240 movs r2, #64 ; 0x40 802a93c: 4629 mov r1, r5 802a93e: a802 add r0, sp, #8 802a940: f7f7 f8be bl 8021ac0 GetParamValue(buf, "managerIP5=", value, &valueLen); 802a944: f10d 0307 add.w r3, sp, #7 802a948: 497e ldr r1, [pc, #504] ; (802ab44 ) 802a94a: aa02 add r2, sp, #8 802a94c: 4620 mov r0, r4 802a94e: f7ff fe35 bl 802a5bc SetManagerIp5(value); 802a952: a802 add r0, sp, #8 802a954: f7fd fb70 bl 8028038 memset(value, 0, len); 802a958: 4629 mov r1, r5 802a95a: 2240 movs r2, #64 ; 0x40 802a95c: a802 add r0, sp, #8 802a95e: f7f7 f8af bl 8021ac0 /* Сетевые параметры */ GetParamValue(buf, "dhcp=", value, &valueLen); 802a962: 4979 ldr r1, [pc, #484] ; (802ab48 ) 802a964: aa02 add r2, sp, #8 802a966: f10d 0307 add.w r3, sp, #7 802a96a: 4620 mov r0, r4 802a96c: f7ff fe26 bl 802a5bc SetDhcpStateStr(value); 802a970: a802 add r0, sp, #8 802a972: f7fd fb0b bl 8027f8c if (strncmp(value, "on", 2) != 0) // Если dhcp off устанавливаем параметры 802a976: a802 add r0, sp, #8 802a978: 4974 ldr r1, [pc, #464] ; (802ab4c ) 802a97a: 2202 movs r2, #2 802a97c: f7f7 fada bl 8021f34 802a980: 2800 cmp r0, #0 802a982: d031 beq.n 802a9e8 { memset(value, 0, len); 802a984: 4629 mov r1, r5 802a986: 2240 movs r2, #64 ; 0x40 802a988: a802 add r0, sp, #8 802a98a: f7f7 f899 bl 8021ac0 GetParamValue(buf, "ipaddr=", value, &valueLen); 802a98e: f10d 0307 add.w r3, sp, #7 802a992: 496f ldr r1, [pc, #444] ; (802ab50 ) 802a994: aa02 add r2, sp, #8 802a996: 4620 mov r0, r4 802a998: f7ff fe10 bl 802a5bc SetIPStr(value); 802a99c: a802 add r0, sp, #8 802a99e: f7fd fae3 bl 8027f68 memset(value, 0, len); 802a9a2: 4629 mov r1, r5 802a9a4: 2240 movs r2, #64 ; 0x40 802a9a6: a802 add r0, sp, #8 802a9a8: f7f7 f88a bl 8021ac0 GetParamValue(buf, "gw=", value, &valueLen); 802a9ac: f10d 0307 add.w r3, sp, #7 802a9b0: 4968 ldr r1, [pc, #416] ; (802ab54 ) 802a9b2: aa02 add r2, sp, #8 802a9b4: 4620 mov r0, r4 802a9b6: f7ff fe01 bl 802a5bc SetGatewayStr(value); 802a9ba: a802 add r0, sp, #8 802a9bc: f7fd fada bl 8027f74 memset(value, 0, len); 802a9c0: 4629 mov r1, r5 802a9c2: 2240 movs r2, #64 ; 0x40 802a9c4: a802 add r0, sp, #8 802a9c6: f7f7 f87b bl 8021ac0 GetParamValue(buf, "mask=", value, &valueLen); 802a9ca: 4963 ldr r1, [pc, #396] ; (802ab58 ) 802a9cc: aa02 add r2, sp, #8 802a9ce: f10d 0307 add.w r3, sp, #7 802a9d2: 4620 mov r0, r4 802a9d4: f7ff fdf2 bl 802a5bc SetMaskStr(value); 802a9d8: a802 add r0, sp, #8 802a9da: f7fd fad1 bl 8027f80 memset(value, 0, len); 802a9de: a802 add r0, sp, #8 802a9e0: 4629 mov r1, r5 802a9e2: 2240 movs r2, #64 ; 0x40 802a9e4: f7f7 f86c bl 8021ac0 } memset(value, 0, len); 802a9e8: 2100 movs r1, #0 802a9ea: 2240 movs r2, #64 ; 0x40 802a9ec: a802 add r0, sp, #8 802a9ee: f7f7 f867 bl 8021ac0 /* параметры RADIUS*/ GetParamValue(buf, "rs_enabled=", value, &valueLen); 802a9f2: f10d 0307 add.w r3, sp, #7 802a9f6: 4959 ldr r1, [pc, #356] ; (802ab5c ) 802a9f8: aa02 add r2, sp, #8 802a9fa: 4620 mov r0, r4 802a9fc: f7ff fdde bl 802a5bc SetRDSEnableStateStr(value); 802aa00: a802 add r0, sp, #8 802aa02: f7fd fb6b bl 80280dc memset(value, 0, len); 802aa06: 2100 movs r1, #0 802aa08: 2240 movs r2, #64 ; 0x40 802aa0a: a802 add r0, sp, #8 802aa0c: f7f7 f858 bl 8021ac0 GetParamValue(buf, "rs_server=", value, &valueLen); 802aa10: f10d 0307 add.w r3, sp, #7 802aa14: 4952 ldr r1, [pc, #328] ; (802ab60 ) 802aa16: aa02 add r2, sp, #8 802aa18: 4620 mov r0, r4 802aa1a: f7ff fdcf bl 802a5bc SetRDSIpStr(value); 802aa1e: a802 add r0, sp, #8 802aa20: f7fd fb3c bl 802809c memset(value, 0, len); 802aa24: 2100 movs r1, #0 802aa26: 2240 movs r2, #64 ; 0x40 802aa28: a802 add r0, sp, #8 802aa2a: f7f7 f849 bl 8021ac0 GetParamValue(buf, "rs_port=", value, &valueLen); 802aa2e: f10d 0307 add.w r3, sp, #7 802aa32: 494c ldr r1, [pc, #304] ; (802ab64 ) 802aa34: aa02 add r2, sp, #8 802aa36: 4620 mov r0, r4 802aa38: f7ff fdc0 bl 802a5bc SetRDSPortStr(value); 802aa3c: a802 add r0, sp, #8 802aa3e: f7fd fb33 bl 80280a8 memset(value, 0, len); 802aa42: 2100 movs r1, #0 802aa44: 2240 movs r2, #64 ; 0x40 802aa46: a802 add r0, sp, #8 802aa48: f7f7 f83a bl 8021ac0 GetParamValue(buf, "rs_pwd=", value, &valueLen); 802aa4c: f10d 0307 add.w r3, sp, #7 802aa50: 4945 ldr r1, [pc, #276] ; (802ab68 ) 802aa52: aa02 add r2, sp, #8 802aa54: 4620 mov r0, r4 802aa56: f7ff fdb1 bl 802a5bc SetRDSPasswordkStr(value); 802aa5a: a802 add r0, sp, #8 802aa5c: f7fd fb38 bl 80280d0 memset(value, 0, len); 802aa60: 2100 movs r1, #0 802aa62: 2240 movs r2, #64 ; 0x40 802aa64: a802 add r0, sp, #8 802aa66: f7f7 f82b bl 8021ac0 GetParamValue(buf, "rs_key=", value, &valueLen); 802aa6a: f10d 0307 add.w r3, sp, #7 802aa6e: 493f ldr r1, [pc, #252] ; (802ab6c ) 802aa70: aa02 add r2, sp, #8 802aa72: 4620 mov r0, r4 802aa74: f7ff fda2 bl 802a5bc SetRDSKeyAccesstStr(value); 802aa78: a802 add r0, sp, #8 802aa7a: f7fd fb1f bl 80280bc memset(value, 0, len); 802aa7e: 2100 movs r1, #0 802aa80: 2240 movs r2, #64 ; 0x40 802aa82: a802 add r0, sp, #8 802aa84: f7f7 f81c bl 8021ac0 // Параметры реле и сухих контактов GetParamValue(buf, "di1=", value, &valueLen); 802aa88: f10d 0307 add.w r3, sp, #7 802aa8c: aa02 add r2, sp, #8 802aa8e: 4938 ldr r1, [pc, #224] ; (802ab70 ) 802aa90: 4620 mov r0, r4 802aa92: f7ff fd93 bl 802a5bc SetDINTypeActStr(value, 0); 802aa96: 2100 movs r1, #0 802aa98: a802 add r0, sp, #8 802aa9a: f7fd fc15 bl 80282c8 memset(value, 0, len); 802aa9e: 2100 movs r1, #0 802aaa0: 2240 movs r2, #64 ; 0x40 802aaa2: a802 add r0, sp, #8 802aaa4: f7f7 f80c bl 8021ac0 GetParamValue(buf, "ro1=", value, &valueLen); 802aaa8: f10d 0307 add.w r3, sp, #7 802aaac: aa02 add r2, sp, #8 802aaae: 4931 ldr r1, [pc, #196] ; (802ab74 ) 802aab0: 4620 mov r0, r4 802aab2: f7ff fd83 bl 802a5bc SetROTypeActStr(value, 0); 802aab6: a802 add r0, sp, #8 802aab8: 2100 movs r1, #0 802aaba: f7fd fc11 bl 80282e0 memset(value, 0, len); 802aabe: 2100 movs r1, #0 802aac0: 2240 movs r2, #64 ; 0x40 802aac2: a802 add r0, sp, #8 802aac4: f7f6 fffc bl 8021ac0 GetParamValue(buf, "ro2=", value, &valueLen); 802aac8: f10d 0307 add.w r3, sp, #7 802aacc: aa02 add r2, sp, #8 802aace: 492a ldr r1, [pc, #168] ; (802ab78 ) 802aad0: 4620 mov r0, r4 802aad2: f7ff fd73 bl 802a5bc SetROTypeActStr(value, 1); 802aad6: a802 add r0, sp, #8 802aad8: 2101 movs r1, #1 802aada: f7fd fc01 bl 80282e0 memset(value, 0, len); 802aade: 2100 movs r1, #0 802aae0: 2240 movs r2, #64 ; 0x40 802aae2: a802 add r0, sp, #8 802aae4: f7f6 ffec bl 8021ac0 // Параметры даты и времени GetParamValue(buf, "ntp=", value, &valueLen); 802aae8: 4924 ldr r1, [pc, #144] ; (802ab7c ) 802aaea: aa02 add r2, sp, #8 802aaec: f10d 0307 add.w r3, sp, #7 802aaf0: 4620 mov r0, r4 802aaf2: f7ff fd63 bl 802a5bc SetSntpStateStr(value); 802aaf6: a802 add r0, sp, #8 802aaf8: f7fd fb6a bl 80281d0 if (strncmp(value, "1", 1) == 0) // Если ntp on устанавливаем параметры 802aafc: a802 add r0, sp, #8 802aafe: 4920 ldr r1, [pc, #128] ; (802ab80 ) 802ab00: 2201 movs r2, #1 802ab02: f7f7 fa17 bl 8021f34 802ab06: 4605 mov r5, r0 { memset(value, 0, len); 802ab08: a802 add r0, sp, #8 // Параметры даты и времени GetParamValue(buf, "ntp=", value, &valueLen); SetSntpStateStr(value); if (strncmp(value, "1", 1) == 0) // Если ntp on устанавливаем параметры 802ab0a: 2d00 cmp r5, #0 802ab0c: d13c bne.n 802ab88 { memset(value, 0, len); 802ab0e: 4629 mov r1, r5 802ab10: 2240 movs r2, #64 ; 0x40 802ab12: f7f6 ffd5 bl 8021ac0 GetParamValue(buf, "ntpservip=", value, &valueLen); 802ab16: 4620 mov r0, r4 802ab18: 491a ldr r1, [pc, #104] ; (802ab84 ) 802ab1a: aa02 add r2, sp, #8 802ab1c: f10d 0307 add.w r3, sp, #7 802ab20: f7ff fd4c bl 802a5bc SetSntpServerIpStr(value); 802ab24: a802 add r0, sp, #8 802ab26: f7fd fb73 bl 8028210 802ab2a: e051 b.n 802abd0 802ab2c: 0803a15e .word 0x0803a15e 802ab30: 0803a16e .word 0x0803a16e 802ab34: 0803a17f .word 0x0803a17f 802ab38: 0803a18a .word 0x0803a18a 802ab3c: 0803a196 .word 0x0803a196 802ab40: 0803a1a2 .word 0x0803a1a2 802ab44: 0803a1ae .word 0x0803a1ae 802ab48: 0803a1ba .word 0x0803a1ba 802ab4c: 08035e94 .word 0x08035e94 802ab50: 0803a1c0 .word 0x0803a1c0 802ab54: 0803a1c8 .word 0x0803a1c8 802ab58: 0803a1cc .word 0x0803a1cc 802ab5c: 0803a1d2 .word 0x0803a1d2 802ab60: 0803a1de .word 0x0803a1de 802ab64: 0803a1e9 .word 0x0803a1e9 802ab68: 0803a1f2 .word 0x0803a1f2 802ab6c: 0803a1fa .word 0x0803a1fa 802ab70: 0803a202 .word 0x0803a202 802ab74: 0803a207 .word 0x0803a207 802ab78: 0803a20c .word 0x0803a20c 802ab7c: 0803a211 .word 0x0803a211 802ab80: 08035f50 .word 0x08035f50 802ab84: 0803a216 .word 0x0803a216 memset(value, 0, len); } else if (strncmp(value, "0", 1) == 0){ 802ab88: 4929 ldr r1, [pc, #164] ; (802ac30 ) 802ab8a: 2201 movs r2, #1 802ab8c: f7f7 f9d2 bl 8021f34 802ab90: 4605 mov r5, r0 802ab92: bb10 cbnz r0, 802abda GetParamValue(buf, "date=", value, &valueLen); 802ab94: f10d 0307 add.w r3, sp, #7 802ab98: 4926 ldr r1, [pc, #152] ; (802ac34 ) 802ab9a: aa02 add r2, sp, #8 802ab9c: 4620 mov r0, r4 802ab9e: f7ff fd0d bl 802a5bc SetDateStr(value); 802aba2: a802 add r0, sp, #8 802aba4: f7fd faac bl 8028100 memset(value, 0, len); 802aba8: 4629 mov r1, r5 802abaa: 2240 movs r2, #64 ; 0x40 802abac: a802 add r0, sp, #8 802abae: f7f6 ff87 bl 8021ac0 GetParamValue(buf, "time=", value, &valueLen); 802abb2: 4921 ldr r1, [pc, #132] ; (802ac38 ) 802abb4: aa02 add r2, sp, #8 802abb6: f10d 0307 add.w r3, sp, #7 802abba: 4620 mov r0, r4 802abbc: f7ff fcfe bl 802a5bc url_decode(str, sizeof(str), value); 802abc0: a812 add r0, sp, #72 ; 0x48 802abc2: 2140 movs r1, #64 ; 0x40 802abc4: aa02 add r2, sp, #8 802abc6: f7fd fddd bl 8028784 SetTimeStr(str); 802abca: a812 add r0, sp, #72 ; 0x48 802abcc: f7fd fad0 bl 8028170 memset(value, 0, len); 802abd0: a802 add r0, sp, #8 802abd2: 4629 mov r1, r5 802abd4: 2240 movs r2, #64 ; 0x40 802abd6: f7f6 ff73 bl 8021ac0 } GetParamValue(buf, "utc=", value, &valueLen); 802abda: 4918 ldr r1, [pc, #96] ; (802ac3c ) 802abdc: aa02 add r2, sp, #8 802abde: f10d 0307 add.w r3, sp, #7 802abe2: 4620 mov r0, r4 802abe4: f7ff fcea bl 802a5bc SetSntpTimeZoneStr(value); 802abe8: a802 add r0, sp, #8 802abea: f7fd fb17 bl 802821c memset(value, 0, len); 802abee: 2100 movs r1, #0 802abf0: 2240 movs r2, #64 ; 0x40 802abf2: a802 add r0, sp, #8 802abf4: f7f6 ff64 bl 8021ac0 /* Если параметры WEB изменились выставляем флаг, сохраняем настройки и перезагружаемся */ if (GetStateWebReinit() == true) 802abf8: f00a f832 bl 8034c60 802abfc: b1a0 cbz r0, 802ac28 { SetWebReinitFlag(true); 802abfe: 2001 movs r0, #1 802ac00: f7fd f9a6 bl 8027f50 HTTP_SaveSettings(); 802ac04: f001 f831 bl 802bc6a /* Блокируем управление ключем на тау секунд*/ //IO_KeyBlockOn(); vTaskDelay(1010); 802ac08: f240 30f2 movw r0, #1010 ; 0x3f2 802ac0c: f7fe fe52 bl 80298b4 802ac10: f3bf 8f4f dsb sy (SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) | 802ac14: 4a0a ldr r2, [pc, #40] ; (802ac40 ) 802ac16: 4b0b ldr r3, [pc, #44] ; (802ac44 ) 802ac18: 68d1 ldr r1, [r2, #12] 802ac1a: f401 61e0 and.w r1, r1, #1792 ; 0x700 802ac1e: 430b orrs r3, r1 __STATIC_INLINE void NVIC_SystemReset(void) //static inline void NVIC_SystemReset(void) { __DSB(); /* Ensure all outstanding memory accesses included buffered write are completed before reset */ SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | 802ac20: 60d3 str r3, [r2, #12] 802ac22: f3bf 8f4f dsb sy 802ac26: e7fe b.n 802ac26 NVIC_SystemReset(); } HTTP_SaveSettings(); 802ac28: f001 f81f bl 802bc6a } 802ac2c: b023 add sp, #140 ; 0x8c 802ac2e: bd30 pop {r4, r5, pc} 802ac30: 08035ef3 .word 0x08035ef3 802ac34: 0803a231 .word 0x0803a231 802ac38: 0803a221 .word 0x0803a221 802ac3c: 0803a227 .word 0x0803a227 802ac40: e000ed00 .word 0xe000ed00 802ac44: 05fa0004 .word 0x05fa0004 0802ac48 : /** * @brief * @retval None */ int HTTP_SettingsPage(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802ac48: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802ac4c: 4606 mov r6, r0 802ac4e: b088 sub sp, #32 802ac50: 460c mov r4, r1 802ac52: 4690 mov r8, r2 char tempStr[30]; strncpy(tempStr, bufIn, 30); 802ac54: 4631 mov r1, r6 802ac56: 221e movs r2, #30 802ac58: 4668 mov r0, sp /** * @brief * @retval None */ int HTTP_SettingsPage(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802ac5a: 461f mov r7, r3 char tempStr[30]; strncpy(tempStr, bufIn, 30); 802ac5c: f7f7 f9c0 bl 8021fe0 /* В запросе нет параметров, нужно формировать JSON ответ */ if (strpbrk(tempStr,"?") == 0) 802ac60: 4668 mov r0, sp 802ac62: 490e ldr r1, [pc, #56] ; (802ac9c ) 802ac64: f7f7 f9ee bl 8022044 802ac68: 4605 mov r5, r0 802ac6a: b970 cbnz r0, 802ac8a { memset(bufOut, 0, SEND_BUF_MAX_LEN); 802ac6c: 4629 mov r1, r5 802ac6e: f44f 62fa mov.w r2, #2000 ; 0x7d0 802ac72: 4620 mov r0, r4 802ac74: f7f6 ff24 bl 8021ac0 HTTP_GetSettings(bufOut); 802ac78: 4620 mov r0, r4 802ac7a: f000 fcfb bl 802b674 //printf(bufOut); *lenBufOut = strlen(bufOut); 802ac7e: 4620 mov r0, r4 802ac80: f7f7 f8f6 bl 8021e70 802ac84: 8038 strh r0, [r7, #0] return SEND_REQUIRED_YES; 802ac86: 4628 mov r0, r5 802ac88: e004 b.n 802ac94 } /* В запросе есть параметры, нужно парсить и сохранять настройки */ else { HTTP_SetSettings(bufIn, lenBufIn); 802ac8a: 4630 mov r0, r6 802ac8c: 4641 mov r1, r8 802ac8e: f7ff fded bl 802a86c return SEND_REQUIRED_NO; 802ac92: 2001 movs r0, #1 } } 802ac94: b008 add sp, #32 802ac96: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802ac9a: bf00 nop 802ac9c: 0803a22c .word 0x0803a22c 0802aca0 : /** * @brief Установка даты производства */ // TODO Убрать заглушку! void HTTP_Prodate(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802aca0: b5f0 push {r4, r5, r6, r7, lr} uint8_t valueLen = 0; 802aca2: 2500 movs r5, #0 /** * @brief Установка даты производства */ // TODO Убрать заглушку! void HTTP_Prodate(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802aca4: b087 sub sp, #28 802aca6: 4606 mov r6, r0 802aca8: 460c mov r4, r1 uint8_t valueLen = 0; char value[20]; memset(bufOut, 0, SEND_BUF_MAX_LEN); 802acaa: f44f 62fa mov.w r2, #2000 ; 0x7d0 802acae: 4608 mov r0, r1 802acb0: 4629 mov r1, r5 /** * @brief Установка даты производства */ // TODO Убрать заглушку! void HTTP_Prodate(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802acb2: 461f mov r7, r3 uint8_t valueLen = 0; 802acb4: f88d 5003 strb.w r5, [sp, #3] char value[20]; memset(bufOut, 0, SEND_BUF_MAX_LEN); 802acb8: f7f6 ff02 bl 8021ac0 ClearParamString(bufIn); 802acbc: 4630 mov r0, r6 802acbe: f7ff fdc1 bl 802a844 memset(value, 0, 20); 802acc2: 4629 mov r1, r5 802acc4: 2214 movs r2, #20 802acc6: a801 add r0, sp, #4 802acc8: f7f6 fefa bl 8021ac0 GetParamValue(bufIn, "prodate=", value, &valueLen); 802accc: aa01 add r2, sp, #4 802acce: f10d 0303 add.w r3, sp, #3 802acd2: 490b ldr r1, [pc, #44] ; (802ad00 ) 802acd4: 4630 mov r0, r6 802acd6: f7ff fc71 bl 802a5bc printf(value); printf("\r\n"); */ /* Устанавливаем дату производства */ SETTINGS_SetProDate(value, valueLen); 802acda: f89d 1003 ldrb.w r1, [sp, #3] 802acde: a801 add r0, sp, #4 802ace0: f7fd fd2a bl 8028738 /* Устанавливаем дату следующей профилактики +1 год */ RTC_SetProfTime(value); 802ace4: a801 add r0, sp, #4 802ace6: f7fb fd2b bl 8026740 /* Пока отправляем true */ strcpy(bufOut, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\nTrue"); 802acea: 4906 ldr r1, [pc, #24] ; (802ad04 ) 802acec: 4620 mov r0, r4 802acee: f7f7 f861 bl 8021db4 *lenBufOut = strlen(bufOut); 802acf2: 4620 mov r0, r4 802acf4: f7f7 f8bc bl 8021e70 802acf8: 8038 strh r0, [r7, #0] // TEST_SetServerFlag(); } 802acfa: b007 add sp, #28 802acfc: bdf0 pop {r4, r5, r6, r7, pc} 802acfe: bf00 nop 802ad00: 0803a22e .word 0x0803a22e 802ad04: 0803a237 .word 0x0803a237 0802ad08 : * @param *str - входная строка * @param sim1 - символ который надо заменить * @param sim2 - символ на который надо заменить */ void HTTP_ReplaceSimbol(char *str, char sim1, char sim2) { 802ad08: b570 push {r4, r5, r6, lr} 802ad0a: 4604 mov r4, r0 802ad0c: 460d mov r5, r1 802ad0e: 4616 mov r6, r2 uint16_t len = strlen(str); 802ad10: f7f7 f8ae bl 8021e70 for (uint16_t i = 0; i < len; i++) 802ad14: 4623 mov r3, r4 * @param sim1 - символ который надо заменить * @param sim2 - символ на который надо заменить */ void HTTP_ReplaceSimbol(char *str, char sim1, char sim2) { uint16_t len = strlen(str); 802ad16: b280 uxth r0, r0 for (uint16_t i = 0; i < len; i++) 802ad18: e005 b.n 802ad26 { if (*str == sim1) 802ad1a: f813 2b01 ldrb.w r2, [r3], #1 802ad1e: 42aa cmp r2, r5 *str = sim2; 802ad20: bf08 it eq 802ad22: f803 6c01 strbeq.w r6, [r3, #-1] */ void HTTP_ReplaceSimbol(char *str, char sim1, char sim2) { uint16_t len = strlen(str); for (uint16_t i = 0; i < len; i++) 802ad26: 1b1a subs r2, r3, r4 802ad28: b292 uxth r2, r2 802ad2a: 4282 cmp r2, r0 802ad2c: d3f5 bcc.n 802ad1a { if (*str == sim1) *str = sim2; str++; } } 802ad2e: bd70 pop {r4, r5, r6, pc} 0802ad30 : /** * @brief * @retval None */ void HTTP_SetInfo(char *buf, uint16_t lenBuf) { 802ad30: b530 push {r4, r5, lr} 802ad32: b09f sub sp, #124 ; 0x7c uint8_t valueLen = 0; 802ad34: 2400 movs r4, #0 /** * @brief * @retval None */ void HTTP_SetInfo(char *buf, uint16_t lenBuf) { 802ad36: 4605 mov r5, r0 uint8_t valueLen = 0; 802ad38: f88d 4007 strb.w r4, [sp, #7] const uint8_t len = 110; char value[110]; ClearParamString(buf); 802ad3c: f7ff fd82 bl 802a844 memset(value, 0, len); 802ad40: 4621 mov r1, r4 802ad42: 226e movs r2, #110 ; 0x6e 802ad44: a802 add r0, sp, #8 802ad46: f7f6 febb bl 8021ac0 /* Владелец */ GetParamValue(buf, "owner=", value, &valueLen); 802ad4a: f10d 0307 add.w r3, sp, #7 802ad4e: aa02 add r2, sp, #8 802ad50: 4628 mov r0, r5 802ad52: 491e ldr r1, [pc, #120] ; (802adcc ) 802ad54: f7ff fc32 bl 802a5bc HTTP_ReplaceSimbol(value, '+', ' '); 802ad58: 212b movs r1, #43 ; 0x2b 802ad5a: 2220 movs r2, #32 802ad5c: a802 add r0, sp, #8 802ad5e: f7ff ffd3 bl 802ad08 SetOwner(value); 802ad62: a802 add r0, sp, #8 802ad64: f7fd f976 bl 8028054 memset(value, 0, len); 802ad68: 4621 mov r1, r4 802ad6a: 226e movs r2, #110 ; 0x6e 802ad6c: a802 add r0, sp, #8 802ad6e: f7f6 fea7 bl 8021ac0 /* Владелец */ GetParamValue(buf, "sysLocation=", value, &valueLen); 802ad72: f10d 0307 add.w r3, sp, #7 802ad76: aa02 add r2, sp, #8 802ad78: 4628 mov r0, r5 802ad7a: 4915 ldr r1, [pc, #84] ; (802add0 ) 802ad7c: f7ff fc1e bl 802a5bc HTTP_ReplaceSimbol(value, '+', ' '); 802ad80: 212b movs r1, #43 ; 0x2b 802ad82: 2220 movs r2, #32 802ad84: a802 add r0, sp, #8 802ad86: f7ff ffbf bl 802ad08 SetLocation(value); 802ad8a: a802 add r0, sp, #8 802ad8c: f7fd f972 bl 8028074 memset(value, 0, len); 802ad90: 4621 mov r1, r4 802ad92: 226e movs r2, #110 ; 0x6e 802ad94: a802 add r0, sp, #8 802ad96: f7f6 fe93 bl 8021ac0 /* Комментарий */ GetParamValue(buf, "comment=", value, &valueLen); 802ad9a: f10d 0307 add.w r3, sp, #7 802ad9e: aa02 add r2, sp, #8 802ada0: 4628 mov r0, r5 802ada2: 490c ldr r1, [pc, #48] ; (802add4 ) 802ada4: f7ff fc0a bl 802a5bc HTTP_ReplaceSimbol(value, '+', ' '); 802ada8: 212b movs r1, #43 ; 0x2b 802adaa: 2220 movs r2, #32 802adac: a802 add r0, sp, #8 802adae: f7ff ffab bl 802ad08 SetComment(value); 802adb2: a802 add r0, sp, #8 802adb4: f7fd f96c bl 8028090 memset(value, 0, len); 802adb8: 4621 mov r1, r4 802adba: 226e movs r2, #110 ; 0x6e 802adbc: a802 add r0, sp, #8 802adbe: f7f6 fe7f bl 8021ac0 HTTP_SaveSettings(); 802adc2: f000 ff52 bl 802bc6a } 802adc6: b01f add sp, #124 ; 0x7c 802adc8: bd30 pop {r4, r5, pc} 802adca: bf00 nop 802adcc: 0803a267 .word 0x0803a267 802add0: 0803a26e .word 0x0803a26e 802add4: 0803a27b .word 0x0803a27b 0802add8 : /** * @brief * @retval None */ int HTTP_InfoPage(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802add8: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802addc: 4606 mov r6, r0 802adde: b088 sub sp, #32 802ade0: 460c mov r4, r1 802ade2: 4690 mov r8, r2 char tempStr[30]; strncpy(tempStr, bufIn, 30); 802ade4: 4631 mov r1, r6 802ade6: 221e movs r2, #30 802ade8: 4668 mov r0, sp /** * @brief * @retval None */ int HTTP_InfoPage(char *bufIn, char *bufOut, uint16_t lenBufIn, uint16_t *lenBufOut) { 802adea: 461f mov r7, r3 char tempStr[30]; strncpy(tempStr, bufIn, 30); 802adec: f7f7 f8f8 bl 8021fe0 /* В запросе нет параметров, нужно формировать JSON ответ */ if (strpbrk(tempStr,"?") == 0) 802adf0: 4668 mov r0, sp 802adf2: 490e ldr r1, [pc, #56] ; (802ae2c ) 802adf4: f7f7 f926 bl 8022044 802adf8: 4605 mov r5, r0 802adfa: b970 cbnz r0, 802ae1a { memset(bufOut, 0, SEND_BUF_MAX_LEN); 802adfc: 4629 mov r1, r5 802adfe: f44f 62fa mov.w r2, #2000 ; 0x7d0 802ae02: 4620 mov r0, r4 802ae04: f7f6 fe5c bl 8021ac0 HTTP_GetInfo(bufOut); 802ae08: 4620 mov r0, r4 802ae0a: f000 fe15 bl 802ba38 *lenBufOut = strlen(bufOut); 802ae0e: 4620 mov r0, r4 802ae10: f7f7 f82e bl 8021e70 802ae14: 8038 strh r0, [r7, #0] return SEND_REQUIRED_YES; 802ae16: 4628 mov r0, r5 802ae18: e004 b.n 802ae24 } /* В запросе есть параметры, нужно парсить и сохранять настройки */ else { HTTP_SetInfo(bufIn, lenBufIn); 802ae1a: 4630 mov r0, r6 802ae1c: 4641 mov r1, r8 802ae1e: f7ff ff87 bl 802ad30 return SEND_REQUIRED_NO; 802ae22: 2001 movs r0, #1 /* HTTP_SetSettings(bufIn, lenBufIn); return SEND_REQUIRED_NO; */ } } 802ae24: b008 add sp, #32 802ae26: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802ae2a: bf00 nop 802ae2c: 0803a22c .word 0x0803a22c 0802ae30 : * @param p: pointer to a packet buffer * @param err: LwIP error code * @retval err */ static err_t http_recv(void *arg, struct tcp_pcb *pcb, struct pbuf *p, err_t err) { 802ae30: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 802ae34: b09d sub sp, #116 ; 0x74 802ae36: 4617 mov r7, r2 struct http_state *hs; char CookieBuf[50]; char *CookiePtr = NULL; char name[MAX_WEB_COOKIE_LEN]; char id[MAX_WEB_COOKIE_LEN]; uint8_t nameLen = 0, idLen = 0; 802ae38: 2200 movs r2, #0 * @param p: pointer to a packet buffer * @param err: LwIP error code * @retval err */ static err_t http_recv(void *arg, struct tcp_pcb *pcb, struct pbuf *p, err_t err) { 802ae3a: 4604 mov r4, r0 802ae3c: 460d mov r5, r1 struct http_state *hs; char CookieBuf[50]; char *CookiePtr = NULL; char name[MAX_WEB_COOKIE_LEN]; char id[MAX_WEB_COOKIE_LEN]; uint8_t nameLen = 0, idLen = 0; 802ae3e: f88d 200a strb.w r2, [sp, #10] 802ae42: f88d 200b strb.w r2, [sp, #11] struct fs_file file = {0, 0}; 802ae46: 9205 str r2, [sp, #20] 802ae48: 9206 str r2, [sp, #24] hs = arg; if (err == ERR_OK && p != NULL) 802ae4a: 2b00 cmp r3, #0 802ae4c: f040 8294 bne.w 802b378 { tcp_recved(pcb, p->tot_len); 802ae50: 4608 mov r0, r1 uint8_t nameLen = 0, idLen = 0; struct fs_file file = {0, 0}; hs = arg; if (err == ERR_OK && p != NULL) 802ae52: 2f00 cmp r7, #0 802ae54: f000 828d beq.w 802b372 { tcp_recved(pcb, p->tot_len); 802ae58: 8939 ldrh r1, [r7, #8] 802ae5a: f002 fb7b bl 802d554 if (hs->file == NULL) 802ae5e: f8d4 8000 ldr.w r8, [r4] 802ae62: f1b8 0f00 cmp.w r8, #0 802ae66: f040 8280 bne.w 802b36a printLen = p->tot_len; memcpy(printBuf, p->payload , printLen); printf(printBuf); */ receivedBufLen = p->tot_len; memcpy(receiveBuf, p->payload , receivedBufLen); 802ae6a: f8df a2fc ldr.w sl, [pc, #764] ; 802b168 { tcp_recved(pcb, p->tot_len); if (hs->file == NULL) { data = p->payload; 802ae6e: 687e ldr r6, [r7, #4] /* printLen = p->tot_len; memcpy(printBuf, p->payload , printLen); printf(printBuf); */ receivedBufLen = p->tot_len; 802ae70: 893a ldrh r2, [r7, #8] 802ae72: f8df 92f0 ldr.w r9, [pc, #752] ; 802b164 memcpy(receiveBuf, p->payload , receivedBufLen); 802ae76: 4650 mov r0, sl 802ae78: 4631 mov r1, r6 /* printLen = p->tot_len; memcpy(printBuf, p->payload , printLen); printf(printBuf); */ receivedBufLen = p->tot_len; 802ae7a: f8a9 2000 strh.w r2, [r9] memcpy(receiveBuf, p->payload , receivedBufLen); 802ae7e: f7f6 fd65 bl 802194c receiveBuf[receivedBufLen] = '\0'; 802ae82: f8b9 3000 ldrh.w r3, [r9] // printf("receive %s \r\n", receiveBuf); /* Get cookie "uname" value */ CookiePtr = strstr(receiveBuf, "uname="); 802ae86: 49a7 ldr r1, [pc, #668] ; (802b124 ) printf(printBuf); */ receivedBufLen = p->tot_len; memcpy(receiveBuf, p->payload , receivedBufLen); receiveBuf[receivedBufLen] = '\0'; 802ae88: f80a 8003 strb.w r8, [sl, r3] // printf("receive %s \r\n", receiveBuf); /* Get cookie "uname" value */ CookiePtr = strstr(receiveBuf, "uname="); 802ae8c: 4650 mov r0, sl 802ae8e: f7f7 fa6f bl 8022370 strncpy(CookieBuf, CookiePtr, 50); 802ae92: f10d 093c add.w r9, sp, #60 ; 0x3c memcpy(receiveBuf, p->payload , receivedBufLen); receiveBuf[receivedBufLen] = '\0'; // printf("receive %s \r\n", receiveBuf); /* Get cookie "uname" value */ CookiePtr = strstr(receiveBuf, "uname="); 802ae96: 4601 mov r1, r0 strncpy(CookieBuf, CookiePtr, 50); 802ae98: 2232 movs r2, #50 ; 0x32 802ae9a: 4648 mov r0, r9 802ae9c: f7f7 f8a0 bl 8021fe0 //printf("********CookieBuf1= %s\r\n", CookieBuf); memset(name, 0, MAX_WEB_COOKIE_LEN); 802aea0: 4641 mov r1, r8 802aea2: 2210 movs r2, #16 802aea4: a807 add r0, sp, #28 802aea6: f7f6 fe0b bl 8021ac0 GetCookieValue(CookieBuf, "uname=", name, &nameLen); 802aeaa: f10d 030a add.w r3, sp, #10 802aeae: aa07 add r2, sp, #28 802aeb0: 499c ldr r1, [pc, #624] ; (802b124 ) 802aeb2: 4648 mov r0, r9 802aeb4: f7ff fc98 bl 802a7e8 //printf("********CookieBuf2= %s\r\n", CookieBuf); //printf("********uname= %s\r\n", name); /* Get cookie "id" value */ CookiePtr = strstr(receiveBuf, "id="); 802aeb8: 4650 mov r0, sl 802aeba: 499b ldr r1, [pc, #620] ; (802b128 ) 802aebc: f7f7 fa58 bl 8022370 strncpy(CookieBuf, CookiePtr, 50); //printf("********CookieBuf1= %s\r\n", CookieBuf); memset(id, 0, MAX_WEB_COOKIE_LEN); 802aec0: f10d 0b2c add.w fp, sp, #44 ; 0x2c GetCookieValue(CookieBuf, "uname=", name, &nameLen); //printf("********CookieBuf2= %s\r\n", CookieBuf); //printf("********uname= %s\r\n", name); /* Get cookie "id" value */ CookiePtr = strstr(receiveBuf, "id="); 802aec4: 4601 mov r1, r0 strncpy(CookieBuf, CookiePtr, 50); 802aec6: 2232 movs r2, #50 ; 0x32 802aec8: 4648 mov r0, r9 802aeca: f7f7 f889 bl 8021fe0 //printf("********CookieBuf1= %s\r\n", CookieBuf); memset(id, 0, MAX_WEB_COOKIE_LEN); 802aece: 4641 mov r1, r8 802aed0: 2210 movs r2, #16 802aed2: 4658 mov r0, fp 802aed4: f7f6 fdf4 bl 8021ac0 GetCookieValue(CookieBuf, "id=", id, &idLen); 802aed8: 465a mov r2, fp 802aeda: f10d 030b add.w r3, sp, #11 802aede: 4648 mov r0, r9 802aee0: 4991 ldr r1, [pc, #580] ; (802b128 ) 802aee2: f7ff fc81 bl 802a7e8 /* Id of currently logged-in user */ uint8_t user_id; /* Level of currently logged-in user */ seclevel = 0xFF; 802aee6: 4b91 ldr r3, [pc, #580] ; (802b12c ) 802aee8: 22ff movs r2, #255 ; 0xff 802aeea: 701a strb r2, [r3, #0] /** * @brief Чтение Cookie пользователя */ static void HTTP_GetUserCookie(uint8_t user_id, char *str, uint8_t *len) { sprintf(str, "%s", users[user_id].cookie); 802aeec: 4b90 ldr r3, [pc, #576] ; (802b130 ) uint8_t user_id; /* Level of currently logged-in user */ seclevel = 0xFF; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { HTTP_GetUserCookie(user_id, CookieBuf, &idLen); 802aeee: 46ca mov sl, r9 /** * @brief Чтение Cookie пользователя */ static void HTTP_GetUserCookie(uint8_t user_id, char *str, uint8_t *len) { sprintf(str, "%s", users[user_id].cookie); 802aef0: 2214 movs r2, #20 802aef2: fb02 3208 mla r2, r2, r8, r3 802aef6: 498f ldr r1, [pc, #572] ; (802b134 ) 802aef8: 9301 str r3, [sp, #4] 802aefa: 4650 mov r0, sl 802aefc: f7fc fc22 bl 8027744 *len = strlen(str); 802af00: 4650 mov r0, sl 802af02: f7f6 ffb5 bl 8021e70 802af06: 4602 mov r2, r0 802af08: f88d 000b strb.w r0, [sp, #11] /* Level of currently logged-in user */ seclevel = 0xFF; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { HTTP_GetUserCookie(user_id, CookieBuf, &idLen); if (strncmp(id, CookieBuf, idLen) == 0 ) { 802af0c: b2d2 uxtb r2, r2 802af0e: 4658 mov r0, fp 802af10: 4651 mov r1, sl 802af12: f7f7 f80f bl 8021f34 802af16: fa5f f988 uxtb.w r9, r8 802af1a: 4a87 ldr r2, [pc, #540] ; (802b138 ) 802af1c: 9b01 ldr r3, [sp, #4] 802af1e: b940 cbnz r0, 802af32 GetUserLevelInt(user_id, &seclevel); 802af20: 4648 mov r0, r9 802af22: 4982 ldr r1, [pc, #520] ; (802b12c ) 802af24: 9201 str r2, [sp, #4] 802af26: f7fc feb5 bl 8027c94 Authenticated = true; 802af2a: 9a01 ldr r2, [sp, #4] 802af2c: 2301 movs r3, #1 802af2e: 7013 strb r3, [r2, #0] break; 802af30: e00a b.n 802af48 } Authenticated = false; 802af32: 2100 movs r1, #0 802af34: 7011 strb r1, [r2, #0] 802af36: f108 0801 add.w r8, r8, #1 seclevel = 0xFF; 802af3a: 4a7c ldr r2, [pc, #496] ; (802b12c ) 802af3c: 21ff movs r1, #255 ; 0xff /* Id of currently logged-in user */ uint8_t user_id; /* Level of currently logged-in user */ seclevel = 0xFF; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 802af3e: f1b8 0f02 cmp.w r8, #2 GetUserLevelInt(user_id, &seclevel); Authenticated = true; break; } Authenticated = false; seclevel = 0xFF; 802af42: 7011 strb r1, [r2, #0] /* Id of currently logged-in user */ uint8_t user_id; /* Level of currently logged-in user */ seclevel = 0xFF; for (user_id = 0; user_id < MAX_WEB_USERS; user_id++) { 802af44: d1d4 bne.n 802aef0 802af46: 46c1 mov r9, r8 } Authenticated = false; seclevel = 0xFF; } if ( Authenticated == false ) 802af48: 4b7b ldr r3, [pc, #492] ; (802b138 ) { if (strncmp(data, "GET /main.css", 13) == 0) // + 802af4a: 497c ldr r1, [pc, #496] ; (802b13c ) } Authenticated = false; seclevel = 0xFF; } if ( Authenticated == false ) 802af4c: 781b ldrb r3, [r3, #0] { if (strncmp(data, "GET /main.css", 13) == 0) // + 802af4e: 4630 mov r0, r6 802af50: 220d movs r2, #13 } Authenticated = false; seclevel = 0xFF; } if ( Authenticated == false ) 802af52: 2b00 cmp r3, #0 802af54: f040 812e bne.w 802b1b4 { if (strncmp(data, "GET /main.css", 13) == 0) // + 802af58: f7f6 ffec bl 8021f34 802af5c: b900 cbnz r0, 802af60 802af5e: e12c b.n 802b1ba hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /rotek.png", 14) == 0) // + 802af60: 4630 mov r0, r6 802af62: 4977 ldr r1, [pc, #476] ; (802b140 ) 802af64: 220e movs r2, #14 802af66: f7f6 ffe5 bl 8021f34 802af6a: b900 cbnz r0, 802af6e 802af6c: e12d b.n 802b1ca hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /favicon.ico", 16) == 0) // ? 802af6e: 4630 mov r0, r6 802af70: 4974 ldr r1, [pc, #464] ; (802b144 ) 802af72: 2210 movs r2, #16 802af74: f7f6 ffde bl 8021f34 802af78: b900 cbnz r0, 802af7c 802af7a: e12e b.n 802b1da hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /role.js", 12) == 0) 802af7c: 4630 mov r0, r6 802af7e: 4972 ldr r1, [pc, #456] ; (802b148 ) 802af80: 220c movs r2, #12 802af82: f7f6 ffd7 bl 8021f34 802af86: b900 cbnz r0, 802af8a 802af88: e137 b.n 802b1fa hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if ((strncmp(data, "POST /login.cgi", 15) == 0) || (log_post_reqn > 0)) 802af8a: 4630 mov r0, r6 802af8c: 496f ldr r1, [pc, #444] ; (802b14c ) 802af8e: 220f movs r2, #15 802af90: f7f6 ffd0 bl 8021f34 802af94: b120 cbz r0, 802afa0 802af96: 4b6e ldr r3, [pc, #440] ; (802b150 ) 802af98: 681b ldr r3, [r3, #0] 802af9a: 2b00 cmp r3, #0 802af9c: f000 80a8 beq.w 802b0f0 { uint32_t i=0,size=0, S=1; int32_t j=0; char sizestring[6], *ptr; ContentLengthOffset =0; 802afa0: 4a6c ldr r2, [pc, #432] ; (802b154 ) uint32_t i, offset = 0, req_data_received = 0; //printf("request 1: %d\r\n", receivedBufLen); /* parse packet for Content-length field */ post_data_count = Parse_Content_Length(data, p->tot_len); 802afa2: f8b7 9008 ldrh.w r9, [r7, #8] { uint32_t i=0,size=0, S=1; int32_t j=0; char sizestring[6], *ptr; ContentLengthOffset =0; 802afa6: 2300 movs r3, #0 802afa8: 6013 str r3, [r2, #0] /* find Content-Length data in packet buffer */ for (i=0;i { if (strncmp ((char*)(data+i), Content_Length, 16)==0) 802afae: eb06 0008 add.w r0, r6, r8 802afb2: 4969 ldr r1, [pc, #420] ; (802b158 ) 802afb4: 2210 movs r2, #16 802afb6: f7f6 ffbd bl 8021f34 802afba: b920 cbnz r0, 802afc6 { ContentLengthOffset = i+16; 802afbc: 4b65 ldr r3, [pc, #404] ; (802b154 ) 802afbe: f108 0210 add.w r2, r8, #16 802afc2: 601a str r2, [r3, #0] 802afc4: e003 b.n 802afce char sizestring[6], *ptr; ContentLengthOffset =0; /* find Content-Length data in packet buffer */ for (i=0;i ContentLengthOffset = i+16; break; } } /* read Content-Length value */ if (ContentLengthOffset) 802afce: 4b61 ldr r3, [pc, #388] ; (802b154 ) 802afd0: 681a ldr r2, [r3, #0] 802afd2: 4618 mov r0, r3 802afd4: b90a cbnz r2, 802afda * @param len : buffer length * @retval size : Content_length in numeric format */ static uint32_t Parse_Content_Length(char *data, uint32_t len) { uint32_t i=0,size=0, S=1; 802afd6: 2200 movs r2, #0 802afd8: e023 b.n 802b022 } /* read Content-Length value */ if (ContentLengthOffset) { i=0; ptr = (char*)(data + ContentLengthOffset); 802afda: eb06 0c02 add.w ip, r6, r2 } } /* read Content-Length value */ if (ContentLengthOffset) { i=0; 802afde: 2300 movs r3, #0 802afe0: e004 b.n 802afec ptr = (char*)(data + ContentLengthOffset); while(*(ptr+i)!=0x0d) { sizestring[i] = *(ptr+i); 802afe2: f10d 0e0c add.w lr, sp, #12 802afe6: f803 100e strb.w r1, [r3, lr] i++; 802afea: 3301 adds r3, #1 /* read Content-Length value */ if (ContentLengthOffset) { i=0; ptr = (char*)(data + ContentLengthOffset); while(*(ptr+i)!=0x0d) 802afec: f81c 1003 ldrb.w r1, [ip, r3] 802aff0: 290d cmp r1, #13 802aff2: eb03 0e02 add.w lr, r3, r2 802aff6: d1f4 bne.n 802afe2 802aff8: f8c0 e000 str.w lr, [r0] { sizestring[i] = *(ptr+i); i++; ContentLengthOffset++; } if (i>0) 802affc: 2b00 cmp r3, #0 802affe: d0ea beq.n 802afd6 { /* transform string data into numeric format */ for(j=i-1;j>=0;j--) 802b000: 3b01 subs r3, #1 * @param len : buffer length * @retval size : Content_length in numeric format */ static uint32_t Parse_Content_Length(char *data, uint32_t len) { uint32_t i=0,size=0, S=1; 802b002: 2101 movs r1, #1 802b004: 2200 movs r2, #0 { /* transform string data into numeric format */ for(j=i-1;j>=0;j--) { size += (sizestring[j]-0x30)*S; S=S*10; 802b006: 200a movs r0, #10 802b008: e009 b.n 802b01e if (i>0) { /* transform string data into numeric format */ for(j=i-1;j>=0;j--) { size += (sizestring[j]-0x30)*S; 802b00a: f10d 0e0c add.w lr, sp, #12 802b00e: f813 e00e ldrb.w lr, [r3, lr] 802b012: f1ae 0e30 sub.w lr, lr, #48 ; 0x30 802b016: fb01 220e mla r2, r1, lr, r2 ContentLengthOffset++; } if (i>0) { /* transform string data into numeric format */ for(j=i-1;j>=0;j--) 802b01a: 3b01 subs r3, #1 { size += (sizestring[j]-0x30)*S; S=S*10; 802b01c: 4341 muls r1, r0 ContentLengthOffset++; } if (i>0) { /* transform string data into numeric format */ for(j=i-1;j>=0;j--) 802b01e: 2b00 cmp r3, #0 802b020: daf3 bge.n 802b00a uint32_t i, offset = 0, req_data_received = 0; //printf("request 1: %d\r\n", receivedBufLen); /* parse packet for Content-length field */ post_data_count = Parse_Content_Length(data, p->tot_len); 802b022: f8df 8150 ldr.w r8, [pc, #336] ; 802b174 //printf("Content-length: %d\r\n", (int)post_data_count); if (post_data_count < MAX_POST_REQ_LEN) { 802b026: 2aff cmp r2, #255 ; 0xff uint32_t i, offset = 0, req_data_received = 0; //printf("request 1: %d\r\n", receivedBufLen); /* parse packet for Content-length field */ post_data_count = Parse_Content_Length(data, p->tot_len); 802b028: f8c8 2000 str.w r2, [r8] //printf("Content-length: %d\r\n", (int)post_data_count); if (post_data_count < MAX_POST_REQ_LEN) { 802b02c: d857 bhi.n 802b0de memset(post_req_data, 0, MAX_POST_REQ_LEN); 802b02e: 484b ldr r0, [pc, #300] ; (802b15c ) /* parse packet for "\r\n\r\n" */ for (i = 0; i < receivedBufLen; i++) 802b030: f8df 9130 ldr.w r9, [pc, #304] ; 802b164 post_data_count = Parse_Content_Length(data, p->tot_len); //printf("Content-length: %d\r\n", (int)post_data_count); if (post_data_count < MAX_POST_REQ_LEN) { memset(post_req_data, 0, MAX_POST_REQ_LEN); 802b034: 2100 movs r1, #0 802b036: f44f 7280 mov.w r2, #256 ; 0x100 802b03a: f7f6 fd41 bl 8021ac0 /* parse packet for "\r\n\r\n" */ for (i = 0; i < receivedBufLen; i++) 802b03e: f04f 0800 mov.w r8, #0 802b042: e00b b.n 802b05c { if (strncmp ((char*)(data+i), "\r\n\r\n", 4) == 0) 802b044: eb06 0008 add.w r0, r6, r8 802b048: 4945 ldr r1, [pc, #276] ; (802b160 ) 802b04a: 2204 movs r2, #4 802b04c: f7f6 ff72 bl 8021f34 802b050: b910 cbnz r0, 802b058 { offset = i+4; 802b052: f108 0804 add.w r8, r8, #4 //printf("offset: %d\r\n", (int)offset); break; 802b056: e007 b.n 802b068 if (post_data_count < MAX_POST_REQ_LEN) { memset(post_req_data, 0, MAX_POST_REQ_LEN); /* parse packet for "\r\n\r\n" */ for (i = 0; i < receivedBufLen; i++) 802b058: f108 0801 add.w r8, r8, #1 802b05c: f8b9 3000 ldrh.w r3, [r9] 802b060: 4598 cmp r8, r3 802b062: d3ef bcc.n 802b044 tcp_sent(pcb, http_sent); } else if ((strncmp(data, "POST /login.cgi", 15) == 0) || (log_post_reqn > 0)) { uint32_t i, offset = 0, req_data_received = 0; 802b064: f04f 0800 mov.w r8, #0 //printf("offset: %d\r\n", (int)offset); break; } } req_data_received = receivedBufLen - offset; 802b068: 4b3e ldr r3, [pc, #248] ; (802b164 ) 802b06a: f8b3 a000 ldrh.w sl, [r3] 802b06e: ebc8 0a0a rsb sl, r8, sl //printf("req data received: %d\r\n", (int)req_data_received); /* Check if "\r\n\r\n" was found */ if (offset != 0) { 802b072: f1b8 0f00 cmp.w r8, #0 802b076: d015 beq.n 802b0a4 /* if data was splited in two packets */ if (req_data_received < post_data_count) { 802b078: f8df 90f8 ldr.w r9, [pc, #248] ; 802b174 /* Copy request data to buffer */ snprintf(post_req_data, req_data_received, "%s", receiveBuf); 802b07c: 4837 ldr r0, [pc, #220] ; (802b15c ) /* Check if "\r\n\r\n" was found */ if (offset != 0) { /* if data was splited in two packets */ if (req_data_received < post_data_count) { 802b07e: f8d9 2000 ldr.w r2, [r9] 802b082: 4592 cmp sl, r2 802b084: d20b bcs.n 802b09e /* Copy request data to buffer */ snprintf(post_req_data, req_data_received, "%s", receiveBuf); 802b086: 4b38 ldr r3, [pc, #224] ; (802b168 ) 802b088: 4a2a ldr r2, [pc, #168] ; (802b134 ) 802b08a: 4651 mov r1, sl 802b08c: f7fc fb3c bl 8027708 //printf("copied: %d\r\n", (int)req_data_received); post_data_count -= req_data_received; 802b090: f8d9 3000 ldr.w r3, [r9] 802b094: ebca 0303 rsb r3, sl, r3 802b098: f8c9 3000 str.w r3, [r9] 802b09c: e165 b.n 802b36a } /* if data received completely */ else { strncat(post_req_data, (char *)(data + offset), post_data_count); 802b09e: eb06 0108 add.w r1, r6, r8 802b0a2: e02b b.n 802b0fc /* request was fragmented before "\r\n\r\n" */ else { //printf("no data found!\r\n"); /* wait next packet */ log_post_reqn++; 802b0a4: 4e2a ldr r6, [pc, #168] ; (802b150 ) 802b0a6: 6833 ldr r3, [r6, #0] 802b0a8: 3301 adds r3, #1 /* wait max 2 requests */ if (log_post_reqn > 1) { 802b0aa: 2b01 cmp r3, #1 /* request was fragmented before "\r\n\r\n" */ else { //printf("no data found!\r\n"); /* wait next packet */ log_post_reqn++; 802b0ac: 6033 str r3, [r6, #0] /* wait max 2 requests */ if (log_post_reqn > 1) { 802b0ae: f240 815c bls.w 802b36a /* Redirect to login page */ fs_open("/login.html", &file); 802b0b2: a905 add r1, sp, #20 802b0b4: 482d ldr r0, [pc, #180] ; (802b16c ) 802b0b6: f7ff f999 bl 802a3ec hs->file = file.data; 802b0ba: 9b05 ldr r3, [sp, #20] 802b0bc: 6023 str r3, [r4, #0] hs->left = file.len; 802b0be: 9b06 ldr r3, [sp, #24] send_data(pcb, hs); 802b0c0: 4628 mov r0, r5 /* wait max 2 requests */ if (log_post_reqn > 1) { /* Redirect to login page */ fs_open("/login.html", &file); hs->file = file.data; hs->left = file.len; 802b0c2: 6063 str r3, [r4, #4] send_data(pcb, hs); 802b0c4: 4621 mov r1, r4 802b0c6: f7ff f9cd bl 802a464 tcp_sent(pcb, http_sent); 802b0ca: 4628 mov r0, r5 802b0cc: 4928 ldr r1, [pc, #160] ; (802b170 ) 802b0ce: f002 fa77 bl 802d5c0 /* End reqest */ post_data_count = 0; 802b0d2: 4b28 ldr r3, [pc, #160] ; (802b174 ) log_post_reqn = 0; 802b0d4: f8c6 8000 str.w r8, [r6] hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); /* End reqest */ post_data_count = 0; 802b0d8: f8c3 8000 str.w r8, [r3] 802b0dc: e145 b.n 802b36a log_post_reqn = 0; } } } else { printf("Too long POST request!\r\n"); 802b0de: 4826 ldr r0, [pc, #152] ; (802b178 ) 802b0e0: f7fc fae4 bl 80276ac /* Ignore request */ post_data_count = 0; log_post_reqn = 0; 802b0e4: 4a1a ldr r2, [pc, #104] ; (802b150 ) } } else { printf("Too long POST request!\r\n"); /* Ignore request */ post_data_count = 0; 802b0e6: 2300 movs r3, #0 802b0e8: f8c8 3000 str.w r3, [r8] log_post_reqn = 0; 802b0ec: 6013 str r3, [r2, #0] 802b0ee: e05f b.n 802b1b0 hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } } else if (post_data_count > 0) 802b0f0: 4b20 ldr r3, [pc, #128] ; (802b174 ) 802b0f2: 681a ldr r2, [r3, #0] 802b0f4: 2a00 cmp r2, #0 802b0f6: d05b beq.n 802b1b0 { strncat(post_req_data, data, post_data_count); 802b0f8: 4818 ldr r0, [pc, #96] ; (802b15c ) 802b0fa: 4631 mov r1, r6 802b0fc: f7f6 fee8 bl 8021ed0 //printf("copied: %d\r\n", (int)post_data_count); //printf("post_req_data: %s\r\n", post_req_data); if (HTTP_ConfirmWebPwd(post_req_data, sendBuf, strlen(post_req_data), &sendBufLoadLen) == SEND_REQUIRED_YES) { 802b100: 4816 ldr r0, [pc, #88] ; (802b15c ) 802b102: f8df 807c ldr.w r8, [pc, #124] ; 802b180 802b106: 4e1d ldr r6, [pc, #116] ; (802b17c ) 802b108: f7f6 feb2 bl 8021e70 802b10c: 4641 mov r1, r8 802b10e: b282 uxth r2, r0 802b110: 4633 mov r3, r6 802b112: 4812 ldr r0, [pc, #72] ; (802b15c ) 802b114: f7ff fa80 bl 802a618 802b118: bba0 cbnz r0, 802b184 hs->file = sendBuf; 802b11a: f8c4 8000 str.w r8, [r4] hs->left = sendBufLoadLen; 802b11e: 8833 ldrh r3, [r6, #0] 802b120: e037 b.n 802b192 802b122: bf00 nop 802b124: 0803a081 .word 0x0803a081 802b128: 0803a096 .word 0x0803a096 802b12c: 200015e0 .word 0x200015e0 802b130: 2000fb5c .word 0x2000fb5c 802b134: 08035e67 .word 0x08035e67 802b138: 20002a39 .word 0x20002a39 802b13c: 0803a284 .word 0x0803a284 802b140: 0803a292 .word 0x0803a292 802b144: 0803a2a1 .word 0x0803a2a1 802b148: 0803a2b2 .word 0x0803a2b2 802b14c: 0803a2bf .word 0x0803a2bf 802b150: 2000fb58 .word 0x2000fb58 802b154: 20002a3c .word 0x20002a3c 802b158: 08039fcb .word 0x08039fcb 802b15c: 2000fa58 .word 0x2000fa58 802b160: 0803a115 .word 0x0803a115 802b164: 20002a42 .word 0x20002a42 802b168: 2000f47c .word 0x2000f47c 802b16c: 0803a2cf .word 0x0803a2cf 802b170: 0802a4d7 .word 0x0802a4d7 802b174: 2000fb84 .word 0x2000fb84 802b178: 0803a2db .word 0x0803a2db 802b17c: 20002a40 .word 0x20002a40 802b180: 2000ecac .word 0x2000ecac tcp_sent(pcb, http_sent); } else { /* Redirect to login page */ fs_open("/login.html", &file); 802b184: 487e ldr r0, [pc, #504] ; (802b380 ) 802b186: a905 add r1, sp, #20 802b188: f7ff f930 bl 802a3ec hs->file = file.data; 802b18c: 9b05 ldr r3, [sp, #20] 802b18e: 6023 str r3, [r4, #0] hs->left = file.len; 802b190: 9b06 ldr r3, [sp, #24] 802b192: 6063 str r3, [r4, #4] send_data(pcb, hs); 802b194: 4628 mov r0, r5 802b196: 4621 mov r1, r4 802b198: f7ff f964 bl 802a464 tcp_sent(pcb, http_sent); 802b19c: 4628 mov r0, r5 802b19e: 4979 ldr r1, [pc, #484] ; (802b384 ) 802b1a0: f002 fa0e bl 802d5c0 } /* End reqest */ post_data_count = 0; 802b1a4: 4a78 ldr r2, [pc, #480] ; (802b388 ) 802b1a6: 2300 movs r3, #0 802b1a8: 6013 str r3, [r2, #0] log_post_reqn = 0; 802b1aa: 4a78 ldr r2, [pc, #480] ; (802b38c ) 802b1ac: 6013 str r3, [r2, #0] 802b1ae: e0dc b.n 802b36a } else { fs_open("/login.html", &file); 802b1b0: 4873 ldr r0, [pc, #460] ; (802b380 ) 802b1b2: e0cb b.n 802b34c } else if ( Authenticated == true ) { if (strncmp(data, "GET /main.css", 13) == 0) // + 802b1b4: f7f6 febe bl 8021f34 802b1b8: b908 cbnz r0, 802b1be { fs_open("/main.css", &file); 802b1ba: 4875 ldr r0, [pc, #468] ; (802b390 ) 802b1bc: e0c6 b.n 802b34c hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /rotek.png", 14) == 0) // + 802b1be: 4630 mov r0, r6 802b1c0: 4974 ldr r1, [pc, #464] ; (802b394 ) 802b1c2: 220e movs r2, #14 802b1c4: f7f6 feb6 bl 8021f34 802b1c8: b908 cbnz r0, 802b1ce { fs_open("/rotek.png", &file); 802b1ca: 4873 ldr r0, [pc, #460] ; (802b398 ) 802b1cc: e0be b.n 802b34c hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /favicon.ico", 16) == 0) // ? 802b1ce: 4630 mov r0, r6 802b1d0: 4972 ldr r1, [pc, #456] ; (802b39c ) 802b1d2: 2210 movs r2, #16 802b1d4: f7f6 feae bl 8021f34 802b1d8: b908 cbnz r0, 802b1de { fs_open("/favicon.ico", &file); 802b1da: 4871 ldr r0, [pc, #452] ; (802b3a0 ) 802b1dc: e0b6 b.n 802b34c hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /main.js", 12) == 0) // + 802b1de: 4630 mov r0, r6 802b1e0: 4970 ldr r1, [pc, #448] ; (802b3a4 ) 802b1e2: 220c movs r2, #12 802b1e4: f7f6 fea6 bl 8021f34 802b1e8: b908 cbnz r0, 802b1ee { fs_open("/main.js", &file); 802b1ea: 486f ldr r0, [pc, #444] ; (802b3a8 ) 802b1ec: e0ae b.n 802b34c hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /role.js", 12) == 0) 802b1ee: 4630 mov r0, r6 802b1f0: 496e ldr r1, [pc, #440] ; (802b3ac ) 802b1f2: 220c movs r2, #12 802b1f4: f7f6 fe9e bl 8021f34 802b1f8: b908 cbnz r0, 802b1fe { fs_open("/role.js", &file); 802b1fa: 486d ldr r0, [pc, #436] ; (802b3b0 ) 802b1fc: e0a6 b.n 802b34c hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /settings.html", 18) == 0) // + 802b1fe: 4630 mov r0, r6 802b200: 496c ldr r1, [pc, #432] ; (802b3b4 ) 802b202: 2212 movs r2, #18 802b204: f7f6 fe96 bl 8021f34 802b208: b918 cbnz r0, 802b212 { HTTP_UpdateUserLoginTime(user_id); 802b20a: 4648 mov r0, r9 802b20c: f7ff f8dc bl 802a3c8 802b210: e04c b.n 802b2ac hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /info.html", 14) == 0) // + 802b212: 4630 mov r0, r6 802b214: 4968 ldr r1, [pc, #416] ; (802b3b8 ) 802b216: 220e movs r2, #14 802b218: f7f6 fe8c bl 8021f34 802b21c: b918 cbnz r0, 802b226 { HTTP_UpdateUserLoginTime(user_id); 802b21e: 4648 mov r0, r9 802b220: f7ff f8d2 bl 802a3c8 802b224: e036 b.n 802b294 hs->file = file.data; hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /getJson.cgi", 16) == 0) // + 802b226: 4630 mov r0, r6 802b228: 4964 ldr r1, [pc, #400] ; (802b3bc ) 802b22a: 2210 movs r2, #16 802b22c: f7f6 fe82 bl 8021f34 802b230: b948 cbnz r0, 802b246 { HTTP_GetParamsPage1(sendBuf); 802b232: 4e63 ldr r6, [pc, #396] ; (802b3c0 ) 802b234: 4630 mov r0, r6 802b236: f000 f907 bl 802b448 hs->file = sendBuf; 802b23a: 6026 str r6, [r4, #0] hs->left = strlen(sendBuf); 802b23c: 4630 mov r0, r6 802b23e: f7f6 fe17 bl 8021e70 802b242: 6060 str r0, [r4, #4] 802b244: e089 b.n 802b35a send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /settings.cgi", 17) == 0) // + 802b246: 4630 mov r0, r6 802b248: 495e ldr r1, [pc, #376] ; (802b3c4 ) 802b24a: 2211 movs r2, #17 802b24c: f7f6 fe72 bl 8021f34 802b250: b970 cbnz r0, 802b270 { SET_PAGE = SET_PAGE_PAGE2; 802b252: 4b5d ldr r3, [pc, #372] ; (802b3c8 ) if (HTTP_SettingsPage(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen) == SEND_REQUIRED_YES) 802b254: f8df 8168 ldr.w r8, [pc, #360] ; 802b3c0 802b258: 4e5c ldr r6, [pc, #368] ; (802b3cc ) 802b25a: 485d ldr r0, [pc, #372] ; (802b3d0 ) send_data(pcb, hs); tcp_sent(pcb, http_sent); } else if (strncmp(data, "GET /settings.cgi", 17) == 0) // + { SET_PAGE = SET_PAGE_PAGE2; 802b25c: 2202 movs r2, #2 802b25e: 701a strb r2, [r3, #0] if (HTTP_SettingsPage(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen) == SEND_REQUIRED_YES) 802b260: 4b5c ldr r3, [pc, #368] ; (802b3d4 ) 802b262: 4641 mov r1, r8 802b264: 881a ldrh r2, [r3, #0] 802b266: 4633 mov r3, r6 802b268: f7ff fcee bl 802ac48 802b26c: b9f0 cbnz r0, 802b2ac 802b26e: e065 b.n 802b33c hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } } else if (strncmp(data, "GET /info.cgi", 13) == 0) // + 802b270: 4630 mov r0, r6 802b272: 4959 ldr r1, [pc, #356] ; (802b3d8 ) 802b274: 220d movs r2, #13 802b276: f7f6 fe5d bl 8021f34 802b27a: b968 cbnz r0, 802b298 { if (HTTP_InfoPage(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen) == SEND_REQUIRED_YES) 802b27c: 4b55 ldr r3, [pc, #340] ; (802b3d4 ) 802b27e: f8df 8140 ldr.w r8, [pc, #320] ; 802b3c0 802b282: 4e52 ldr r6, [pc, #328] ; (802b3cc ) 802b284: 881a ldrh r2, [r3, #0] 802b286: 4852 ldr r0, [pc, #328] ; (802b3d0 ) 802b288: 4641 mov r1, r8 802b28a: 4633 mov r3, r6 802b28c: f7ff fda4 bl 802add8 802b290: b900 cbnz r0, 802b294 802b292: e053 b.n 802b33c send_data(pcb, hs); tcp_sent(pcb, http_sent); } else { fs_open("/info.html", &file); 802b294: 4851 ldr r0, [pc, #324] ; (802b3dc ) 802b296: e059 b.n 802b34c send_data(pcb, hs); tcp_sent(pcb, http_sent); } } /* Сброс настроек и сохранине */ else if (strncmp(data, "GET /reset.cgi", 14) == 0) 802b298: 4630 mov r0, r6 802b29a: 4951 ldr r1, [pc, #324] ; (802b3e0 ) 802b29c: 220e movs r2, #14 802b29e: f7f6 fe49 bl 8021f34 802b2a2: b928 cbnz r0, 802b2b0 { HTTP_ResetSettings(); 802b2a4: f000 fcda bl 802bc5c HTTP_SaveSettings(); 802b2a8: f000 fcdf bl 802bc6a fs_open("/settings.html", &file); 802b2ac: 484d ldr r0, [pc, #308] ; (802b3e4 ) 802b2ae: e04d b.n 802b34c hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } /* Перезагрузка контроллера */ else if (strncmp(data, "GET /reboot.cgi", 15) == 0) 802b2b0: 4630 mov r0, r6 802b2b2: 494d ldr r1, [pc, #308] ; (802b3e8 ) 802b2b4: 220f movs r2, #15 802b2b6: f7f6 fe3d bl 8021f34 802b2ba: b910 cbnz r0, 802b2c2 { HTTP_Reboot(); 802b2bc: f000 fcd7 bl 802bc6e 802b2c0: e053 b.n 802b36a } /* Подтверждение новых сетевых настроек */ else if (strncmp(data, "GET /confirm.cgi", 16) == 0) 802b2c2: 4630 mov r0, r6 802b2c4: 4949 ldr r1, [pc, #292] ; (802b3ec ) 802b2c6: 2210 movs r2, #16 802b2c8: f7f6 fe34 bl 8021f34 802b2cc: b920 cbnz r0, 802b2d8 { SetWebReinitFlag(false); 802b2ce: f7fc fe3f bl 8027f50 SetConfirmWebParamsFlag(); 802b2d2: f7fc fe43 bl 8027f5c 802b2d6: e038 b.n 802b34a hs->left = file.len; send_data(pcb, hs); tcp_sent(pcb, http_sent); } /* Проверка пароля, переход в bootloader */ else if (strncmp(data, "POST /checkpwd.cgi", 18) == 0) 802b2d8: 4630 mov r0, r6 802b2da: 4945 ldr r1, [pc, #276] ; (802b3f0 ) 802b2dc: 2212 movs r2, #18 802b2de: f7f6 fe29 bl 8021f34 802b2e2: b950 cbnz r0, 802b2fa { HTTP_ConfirmBootPwd(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen); 802b2e4: f8df 80d8 ldr.w r8, [pc, #216] ; 802b3c0 802b2e8: 4e38 ldr r6, [pc, #224] ; (802b3cc ) 802b2ea: 4b3a ldr r3, [pc, #232] ; (802b3d4 ) 802b2ec: 4838 ldr r0, [pc, #224] ; (802b3d0 ) 802b2ee: 881a ldrh r2, [r3, #0] 802b2f0: 4641 mov r1, r8 802b2f2: 4633 mov r3, r6 802b2f4: f7ff fa4c bl 802a790 802b2f8: e020 b.n 802b33c hs->left = sendBufLoadLen; send_data(pcb, hs); tcp_sent(pcb, http_sent); } // На производстве else if (strncmp(data, "GET /setProdate.cgi", 19) == 0) 802b2fa: 4630 mov r0, r6 802b2fc: 493d ldr r1, [pc, #244] ; (802b3f4 ) 802b2fe: 2213 movs r2, #19 802b300: f7f6 fe18 bl 8021f34 802b304: b950 cbnz r0, 802b31c { HTTP_Prodate(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen); 802b306: f8df 80b8 ldr.w r8, [pc, #184] ; 802b3c0 802b30a: 4e30 ldr r6, [pc, #192] ; (802b3cc ) 802b30c: 4b31 ldr r3, [pc, #196] ; (802b3d4 ) 802b30e: 4830 ldr r0, [pc, #192] ; (802b3d0 ) 802b310: 881a ldrh r2, [r3, #0] 802b312: 4641 mov r1, r8 802b314: 4633 mov r3, r6 802b316: f7ff fcc3 bl 802aca0 802b31a: e00f b.n 802b33c hs->left = sendBufLoadLen; send_data(pcb, hs); tcp_sent(pcb, http_sent); } // На производстве else if (strncmp(data, "GET /progon.cgi", 15) == 0) 802b31c: 4630 mov r0, r6 802b31e: 4936 ldr r1, [pc, #216] ; (802b3f8 ) 802b320: 220f movs r2, #15 802b322: f7f6 fe07 bl 8021f34 802b326: b968 cbnz r0, 802b344 { HTTP_Progon(receiveBuf, sendBuf, receivedBufLen, &sendBufLoadLen); 802b328: 4b2a ldr r3, [pc, #168] ; (802b3d4 ) 802b32a: f8df 8094 ldr.w r8, [pc, #148] ; 802b3c0 802b32e: 4e27 ldr r6, [pc, #156] ; (802b3cc ) 802b330: 881a ldrh r2, [r3, #0] 802b332: 4827 ldr r0, [pc, #156] ; (802b3d0 ) 802b334: 4641 mov r1, r8 802b336: 4633 mov r3, r6 802b338: f7ff f92e bl 802a598 hs->file = sendBuf; 802b33c: f8c4 8000 str.w r8, [r4] hs->left = sendBufLoadLen; 802b340: 8833 ldrh r3, [r6, #0] 802b342: e009 b.n 802b358 send_data(pcb, hs); tcp_sent(pcb, http_sent); } else { HTTP_UpdateUserLoginTime(user_id); 802b344: 4648 mov r0, r9 802b346: f7ff f83f bl 802a3c8 fs_open("/index.html", &file); // + 802b34a: 482c ldr r0, [pc, #176] ; (802b3fc ) 802b34c: a905 add r1, sp, #20 802b34e: f7ff f84d bl 802a3ec hs->file = file.data; 802b352: 9b05 ldr r3, [sp, #20] 802b354: 6023 str r3, [r4, #0] hs->left = file.len; 802b356: 9b06 ldr r3, [sp, #24] 802b358: 6063 str r3, [r4, #4] send_data(pcb, hs); 802b35a: 4628 mov r0, r5 802b35c: 4621 mov r1, r4 802b35e: f7ff f881 bl 802a464 tcp_sent(pcb, http_sent); 802b362: 4628 mov r0, r5 802b364: 4907 ldr r1, [pc, #28] ; (802b384 ) 802b366: f002 f92b bl 802d5c0 } } } pbuf_free(p); 802b36a: 4638 mov r0, r7 802b36c: f001 fe60 bl 802d030 close_conn(pcb,hs); 802b370: 4628 mov r0, r5 } if (err == ERR_OK && p == NULL) { close_conn(pcb, hs); 802b372: 4621 mov r1, r4 802b374: f7ff f899 bl 802a4aa } return ERR_OK; } 802b378: 2000 movs r0, #0 802b37a: b01d add sp, #116 ; 0x74 802b37c: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802b380: 0803a2cf .word 0x0803a2cf 802b384: 0802a4d7 .word 0x0802a4d7 802b388: 2000fb84 .word 0x2000fb84 802b38c: 2000fb58 .word 0x2000fb58 802b390: 0803a288 .word 0x0803a288 802b394: 0803a292 .word 0x0803a292 802b398: 0803a296 .word 0x0803a296 802b39c: 0803a2a1 .word 0x0803a2a1 802b3a0: 0803a2a5 .word 0x0803a2a5 802b3a4: 0803a2f4 .word 0x0803a2f4 802b3a8: 0803a2f8 .word 0x0803a2f8 802b3ac: 0803a2b2 .word 0x0803a2b2 802b3b0: 0803a2b6 .word 0x0803a2b6 802b3b4: 0803a301 .word 0x0803a301 802b3b8: 0803a314 .word 0x0803a314 802b3bc: 0803a323 .word 0x0803a323 802b3c0: 2000ecac .word 0x2000ecac 802b3c4: 0803a334 .word 0x0803a334 802b3c8: 20002a38 .word 0x20002a38 802b3cc: 20002a40 .word 0x20002a40 802b3d0: 2000f47c .word 0x2000f47c 802b3d4: 20002a42 .word 0x20002a42 802b3d8: 0803a346 .word 0x0803a346 802b3dc: 0803a318 .word 0x0803a318 802b3e0: 0803a354 .word 0x0803a354 802b3e4: 0803a305 .word 0x0803a305 802b3e8: 0803a363 .word 0x0803a363 802b3ec: 0803a373 .word 0x0803a373 802b3f0: 0803a390 .word 0x0803a390 802b3f4: 0803a3a3 .word 0x0803a3a3 802b3f8: 0803a3b7 .word 0x0803a3b7 802b3fc: 0803a384 .word 0x0803a384 0802b400 : 802b400: f3bf 8f4f dsb sy (SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) | 802b404: 4a04 ldr r2, [pc, #16] ; (802b418 ) 802b406: 4b05 ldr r3, [pc, #20] ; (802b41c ) 802b408: 68d1 ldr r1, [r2, #12] 802b40a: f401 61e0 and.w r1, r1, #1792 ; 0x700 802b40e: 430b orrs r3, r1 __STATIC_INLINE void NVIC_SystemReset(void) //static inline void NVIC_SystemReset(void) { __DSB(); /* Ensure all outstanding memory accesses included buffered write are completed before reset */ SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | 802b410: 60d3 str r3, [r2, #12] 802b412: f3bf 8f4f dsb sy 802b416: e7fe b.n 802b416 802b418: e000ed00 .word 0xe000ed00 802b41c: 05fa0004 .word 0x05fa0004 0802b420 : /** * @brief */ void vTaskReboot(void * pvParameters) { 802b420: b508 push {r3, lr} for (;;) { mode = *(bool*)pvParameters; if (mode) 802b422: 7803 ldrb r3, [r0, #0] 802b424: b133 cbz r3, 802b434 { SetLoadMode(); 802b426: f7fc fd8d bl 8027f44 */ void HTTP_SaveSettings(void) { // taskENTER_CRITICAL(); SETTINGS_Save(); 802b42a: f7fd f8f5 bl 8028618 if (mode) { SetLoadMode(); HTTP_SaveSettings(); SNMP_SendUserTrap(FW_VERSION_UPDATE); 802b42e: 2001 movs r0, #1 802b430: f009 fcfa bl 8034e28 vTaskDelay(1010); NVIC_SystemReset(); } else { vTaskDelay(1000); 802b434: f44f 707a mov.w r0, #1000 ; 0x3e8 802b438: f7fe fa3c bl 80298b4 /* Блокируем управление ключем на тау секунд*/ //IO_KeyBlockOn(); vTaskDelay(1010); 802b43c: f240 30f2 movw r0, #1010 ; 0x3f2 802b440: f7fe fa38 bl 80298b4 NVIC_SystemReset(); 802b444: f7ff ffdc bl 802b400 0802b448 : /** * @brief Возвращяет строку с настройками на первой странице * @retval None */ void HTTP_GetParamsPage1(char *buf) { 802b448: b510 push {r4, lr} char str[40]; uint8_t len; memset(buf, 0, 1000); 802b44a: f44f 727a mov.w r2, #1000 ; 0x3e8 /** * @brief Возвращяет строку с настройками на первой странице * @retval None */ void HTTP_GetParamsPage1(char *buf) { 802b44e: b08c sub sp, #48 ; 0x30 802b450: 4604 mov r4, r0 char str[40]; uint8_t len; memset(buf, 0, 1000); 802b452: 2100 movs r1, #0 802b454: f7f6 fb34 bl 8021ac0 // Headers для поддержки saffari strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802b458: 4620 mov r0, r4 802b45a: 4975 ldr r1, [pc, #468] ; (802b630 ) 802b45c: f7f6 fcaa bl 8021db4 // Параметры UPS GetInputVoltageStr(str, &len); 802b460: a802 add r0, sp, #8 802b462: f10d 0107 add.w r1, sp, #7 802b466: f7fc f9af bl 80277c8 strcat(buf, "{\"AC\":\""); 802b46a: 4620 mov r0, r4 802b46c: 4971 ldr r1, [pc, #452] ; (802b634 ) 802b46e: f7f6 fb8d bl 8021b8c strncat(buf, str, len); 802b472: f89d 2007 ldrb.w r2, [sp, #7] 802b476: a902 add r1, sp, #8 802b478: 4620 mov r0, r4 802b47a: f7f6 fd29 bl 8021ed0 GetOutputVoltageStr(str, &len); 802b47e: a802 add r0, sp, #8 802b480: f10d 0107 add.w r1, sp, #7 802b484: f7fc f9b6 bl 80277f4 strcat(buf, "\",\"DC\":\""); 802b488: 4620 mov r0, r4 802b48a: 496b ldr r1, [pc, #428] ; (802b638 ) 802b48c: f7f6 fb7e bl 8021b8c strncat(buf, str, len); 802b490: f89d 2007 ldrb.w r2, [sp, #7] 802b494: a902 add r1, sp, #8 802b496: 4620 mov r0, r4 802b498: f7f6 fd1a bl 8021ed0 GetInputFreqStr(str, &len); 802b49c: a802 add r0, sp, #8 802b49e: f10d 0107 add.w r1, sp, #7 802b4a2: f7fc f965 bl 8027770 strcat(buf, "\",\"in_freq\":\""); 802b4a6: 4620 mov r0, r4 802b4a8: 4964 ldr r1, [pc, #400] ; (802b63c ) 802b4aa: f7f6 fb6f bl 8021b8c strncat(buf, str, len); 802b4ae: f89d 2007 ldrb.w r2, [sp, #7] 802b4b2: a902 add r1, sp, #8 802b4b4: 4620 mov r0, r4 802b4b6: f7f6 fd0b bl 8021ed0 GetOutputFreqStr(str, &len); 802b4ba: a802 add r0, sp, #8 802b4bc: f10d 0107 add.w r1, sp, #7 802b4c0: f7fc f96c bl 802779c strcat(buf, "\",\"out_freq\":\""); 802b4c4: 4620 mov r0, r4 802b4c6: 495e ldr r1, [pc, #376] ; (802b640 ) 802b4c8: f7f6 fb60 bl 8021b8c strncat(buf, str, len); 802b4cc: f89d 2007 ldrb.w r2, [sp, #7] 802b4d0: a902 add r1, sp, #8 802b4d2: 4620 mov r0, r4 802b4d4: f7f6 fcfc bl 8021ed0 GetPowerStr(str, &len); 802b4d8: a802 add r0, sp, #8 802b4da: f10d 0107 add.w r1, sp, #7 802b4de: f7fc f99f bl 8027820 strcat(buf, "\",\"pwr\":\""); 802b4e2: 4620 mov r0, r4 802b4e4: 4957 ldr r1, [pc, #348] ; (802b644 ) 802b4e6: f7f6 fb51 bl 8021b8c strncat(buf, str, len); 802b4ea: f89d 2007 ldrb.w r2, [sp, #7] 802b4ee: a902 add r1, sp, #8 802b4f0: 4620 mov r0, r4 802b4f2: f7f6 fced bl 8021ed0 GetLineFailBitStr(str, &len); 802b4f6: a802 add r0, sp, #8 802b4f8: f10d 0107 add.w r1, sp, #7 802b4fc: f7fc f92e bl 802775c strcat(buf, "\",\"line_fail\":\""); 802b500: 4620 mov r0, r4 802b502: 4951 ldr r1, [pc, #324] ; (802b648 ) 802b504: f7f6 fb42 bl 8021b8c strncat(buf, str, len); 802b508: f89d 2007 ldrb.w r2, [sp, #7] 802b50c: a902 add r1, sp, #8 802b50e: 4620 mov r0, r4 802b510: f7f6 fcde bl 8021ed0 GetLowBatteryBitStr(str, &len); 802b514: a802 add r0, sp, #8 802b516: f10d 0107 add.w r1, sp, #7 802b51a: f7fc f924 bl 8027766 strcat(buf, "\",\"low_battery\":\""); 802b51e: 4620 mov r0, r4 802b520: 494a ldr r1, [pc, #296] ; (802b64c ) 802b522: f7f6 fb33 bl 8021b8c strncat(buf, str, len); 802b526: f89d 2007 ldrb.w r2, [sp, #7] 802b52a: a902 add r1, sp, #8 802b52c: 4620 mov r0, r4 802b52e: f7f6 fccf bl 8021ed0 GetBatCapacityStr(str, &len); 802b532: a802 add r0, sp, #8 802b534: f10d 0107 add.w r1, sp, #7 802b538: f7fc f984 bl 8027844 strcat(buf, "\",\"bat_cap\":\""); 802b53c: 4620 mov r0, r4 802b53e: 4944 ldr r1, [pc, #272] ; (802b650 ) 802b540: f7f6 fb24 bl 8021b8c strncat(buf, str, len); 802b544: f89d 2007 ldrb.w r2, [sp, #7] 802b548: a902 add r1, sp, #8 802b54a: 4620 mov r0, r4 802b54c: f7f6 fcc0 bl 8021ed0 GetInternalTempStr(str, &len); 802b550: a802 add r0, sp, #8 802b552: f10d 0107 add.w r1, sp, #7 802b556: f7fc f999 bl 802788c strcat(buf, "\",\"inner_temp\":\""); 802b55a: 4620 mov r0, r4 802b55c: 493d ldr r1, [pc, #244] ; (802b654 ) 802b55e: f7f6 fb15 bl 8021b8c strncat(buf, str, len); 802b562: f89d 2007 ldrb.w r2, [sp, #7] 802b566: a902 add r1, sp, #8 802b568: 4620 mov r0, r4 802b56a: f7f6 fcb1 bl 8021ed0 GetRuntimeStr(str, &len); 802b56e: a802 add r0, sp, #8 802b570: f10d 0107 add.w r1, sp, #7 802b574: f7fc f978 bl 8027868 strcat(buf, "\",\"bat_time_left\":\""); 802b578: 4620 mov r0, r4 802b57a: 4937 ldr r1, [pc, #220] ; (802b658 ) 802b57c: f7f6 fb06 bl 8021b8c strncat(buf, str, len); 802b580: f89d 2007 ldrb.w r2, [sp, #7] 802b584: a902 add r1, sp, #8 802b586: 4620 mov r0, r4 802b588: f7f6 fca2 bl 8021ed0 // Мониторинг // load_monitor (нагрузка, 0 - норма, 1 - fail) // temp_monitor (внутренняя температура, 0 - норма, 1 - fail) // connect_monitor (связь с UPSом, 0 - норма, 1 - fail) GetLoadMonitorStr(str, &len); 802b58c: a802 add r0, sp, #8 802b58e: f10d 0107 add.w r1, sp, #7 802b592: f7fc f991 bl 80278b8 strcat(buf, "\",\"load_monitor\":\""); 802b596: 4620 mov r0, r4 802b598: 4930 ldr r1, [pc, #192] ; (802b65c ) 802b59a: f7f6 faf7 bl 8021b8c strncat(buf, str, len); 802b59e: f89d 2007 ldrb.w r2, [sp, #7] 802b5a2: a902 add r1, sp, #8 802b5a4: 4620 mov r0, r4 802b5a6: f7f6 fc93 bl 8021ed0 GetTempMonitorStr(str, &len); 802b5aa: a802 add r0, sp, #8 802b5ac: f10d 0107 add.w r1, sp, #7 802b5b0: f7fc f987 bl 80278c2 strcat(buf, "\",\"temp_monitor\":\""); 802b5b4: 4620 mov r0, r4 802b5b6: 492a ldr r1, [pc, #168] ; (802b660 ) 802b5b8: f7f6 fae8 bl 8021b8c strncat(buf, str, len); 802b5bc: f89d 2007 ldrb.w r2, [sp, #7] 802b5c0: a902 add r1, sp, #8 802b5c2: 4620 mov r0, r4 802b5c4: f7f6 fc84 bl 8021ed0 GetConnectMonitorStr(str, &len); 802b5c8: a802 add r0, sp, #8 802b5ca: f10d 0107 add.w r1, sp, #7 802b5ce: f7fc f97d bl 80278cc strcat(buf, "\",\"connect_monitor\":\""); 802b5d2: 4620 mov r0, r4 802b5d4: 4923 ldr r1, [pc, #140] ; (802b664 ) 802b5d6: f7f6 fad9 bl 8021b8c strncat(buf, str, len); 802b5da: f89d 2007 ldrb.w r2, [sp, #7] 802b5de: a902 add r1, sp, #8 802b5e0: 4620 mov r0, r4 802b5e2: f7f6 fc75 bl 8021ed0 GetAlarmStr(str, &len); 802b5e6: a802 add r0, sp, #8 802b5e8: f10d 0107 add.w r1, sp, #7 802b5ec: f7fc f974 bl 80278d8 strcat(buf, "\",\"alarm\":\""); 802b5f0: 4620 mov r0, r4 802b5f2: 491d ldr r1, [pc, #116] ; (802b668 ) 802b5f4: f7f6 faca bl 8021b8c strncat(buf, str, len); 802b5f8: f89d 2007 ldrb.w r2, [sp, #7] 802b5fc: a902 add r1, sp, #8 802b5fe: 4620 mov r0, r4 802b600: f7f6 fc66 bl 8021ed0 // Признак изменения сетевых настроек GetWebReinitFlag(str, &len); 802b604: a802 add r0, sp, #8 802b606: f10d 0107 add.w r1, sp, #7 802b60a: f7fc fc81 bl 8027f10 strcat(buf, "\",\"netsettings_changed\":\""); 802b60e: 4620 mov r0, r4 802b610: 4916 ldr r1, [pc, #88] ; (802b66c ) 802b612: f7f6 fabb bl 8021b8c strncat(buf, str, len); 802b616: a902 add r1, sp, #8 802b618: f89d 2007 ldrb.w r2, [sp, #7] 802b61c: 4620 mov r0, r4 802b61e: f7f6 fc57 bl 8021ed0 strncat(buf, "\"}", 2); 802b622: 4620 mov r0, r4 802b624: 4912 ldr r1, [pc, #72] ; (802b670 ) 802b626: 2202 movs r2, #2 802b628: f7f6 fc52 bl 8021ed0 //printf(buf); } 802b62c: b00c add sp, #48 ; 0x30 802b62e: bd10 pop {r4, pc} 802b630: 0803fae4 .word 0x0803fae4 802b634: 0803fb10 .word 0x0803fb10 802b638: 0803fb18 .word 0x0803fb18 802b63c: 0803fb21 .word 0x0803fb21 802b640: 0803fb2f .word 0x0803fb2f 802b644: 0803fb3e .word 0x0803fb3e 802b648: 0803fb48 .word 0x0803fb48 802b64c: 0803fb58 .word 0x0803fb58 802b650: 0803fb6a .word 0x0803fb6a 802b654: 0803fb78 .word 0x0803fb78 802b658: 0803fb89 .word 0x0803fb89 802b65c: 0803fb9d .word 0x0803fb9d 802b660: 0803fbb0 .word 0x0803fbb0 802b664: 0803fbc3 .word 0x0803fbc3 802b668: 0803fbd9 .word 0x0803fbd9 802b66c: 0803fbe5 .word 0x0803fbe5 802b670: 0803fbff .word 0x0803fbff 0802b674 : /** * @brief Возвращяет строку с настройками на второй странице * @retval None */ void HTTP_GetSettings(char *buf) { 802b674: b510 push {r4, lr} char str[30]; uint8_t len; /* Headers для поддержки saffari */ strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802b676: 49bf ldr r1, [pc, #764] ; (802b974 ) /** * @brief Возвращяет строку с настройками на второй странице * @retval None */ void HTTP_GetSettings(char *buf) { 802b678: b08a sub sp, #40 ; 0x28 802b67a: 4604 mov r4, r0 char str[30]; uint8_t len; /* Headers для поддержки saffari */ strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802b67c: f7f6 fb9a bl 8021db4 /* SNMP */ GetReadCommunity(str, &len); 802b680: a802 add r0, sp, #8 802b682: f10d 0107 add.w r1, sp, #7 802b686: f7fc fb65 bl 8027d54 strcat(buf, "{\"read_community\":\""); 802b68a: 4620 mov r0, r4 802b68c: 49ba ldr r1, [pc, #744] ; (802b978 ) 802b68e: f7f6 fa7d bl 8021b8c strncat(buf, str, len); 802b692: f89d 2007 ldrb.w r2, [sp, #7] 802b696: a902 add r1, sp, #8 802b698: 4620 mov r0, r4 802b69a: f7f6 fc19 bl 8021ed0 GetWriteCommunity(str, &len); 802b69e: a802 add r0, sp, #8 802b6a0: f10d 0107 add.w r1, sp, #7 802b6a4: f7fc fb66 bl 8027d74 strcat(buf, "\",\"write_community\":\""); 802b6a8: 4620 mov r0, r4 802b6aa: 49b4 ldr r1, [pc, #720] ; (802b97c ) 802b6ac: f7f6 fa6e bl 8021b8c strncat(buf, str, len); 802b6b0: f89d 2007 ldrb.w r2, [sp, #7] 802b6b4: a902 add r1, sp, #8 802b6b6: 4620 mov r0, r4 802b6b8: f7f6 fc0a bl 8021ed0 GetManagerIp(str, &len); 802b6bc: a802 add r0, sp, #8 802b6be: f10d 0107 add.w r1, sp, #7 802b6c2: f7fc fb67 bl 8027d94 strcat(buf, "\",\"managerIP\":\""); 802b6c6: 4620 mov r0, r4 802b6c8: 49ad ldr r1, [pc, #692] ; (802b980 ) 802b6ca: f7f6 fa5f bl 8021b8c strncat(buf, str, len); 802b6ce: f89d 2007 ldrb.w r2, [sp, #7] 802b6d2: a902 add r1, sp, #8 802b6d4: 4620 mov r0, r4 802b6d6: f7f6 fbfb bl 8021ed0 GetManagerIp2(str, &len); 802b6da: a802 add r0, sp, #8 802b6dc: f10d 0107 add.w r1, sp, #7 802b6e0: f7fc fb68 bl 8027db4 strcat(buf, "\",\"managerIP2\":\""); 802b6e4: 4620 mov r0, r4 802b6e6: 49a7 ldr r1, [pc, #668] ; (802b984 ) 802b6e8: f7f6 fa50 bl 8021b8c strncat(buf, str, len); 802b6ec: f89d 2007 ldrb.w r2, [sp, #7] 802b6f0: a902 add r1, sp, #8 802b6f2: 4620 mov r0, r4 802b6f4: f7f6 fbec bl 8021ed0 GetManagerIp3(str, &len); 802b6f8: a802 add r0, sp, #8 802b6fa: f10d 0107 add.w r1, sp, #7 802b6fe: f7fc fb69 bl 8027dd4 strcat(buf, "\",\"managerIP3\":\""); 802b702: 4620 mov r0, r4 802b704: 49a0 ldr r1, [pc, #640] ; (802b988 ) 802b706: f7f6 fa41 bl 8021b8c strncat(buf, str, len); 802b70a: f89d 2007 ldrb.w r2, [sp, #7] 802b70e: a902 add r1, sp, #8 802b710: 4620 mov r0, r4 802b712: f7f6 fbdd bl 8021ed0 GetManagerIp4(str, &len); 802b716: a802 add r0, sp, #8 802b718: f10d 0107 add.w r1, sp, #7 802b71c: f7fc fb6a bl 8027df4 strcat(buf, "\",\"managerIP4\":\""); 802b720: 4620 mov r0, r4 802b722: 499a ldr r1, [pc, #616] ; (802b98c ) 802b724: f7f6 fa32 bl 8021b8c strncat(buf, str, len); 802b728: f89d 2007 ldrb.w r2, [sp, #7] 802b72c: a902 add r1, sp, #8 802b72e: 4620 mov r0, r4 802b730: f7f6 fbce bl 8021ed0 GetManagerIp5(str, &len); 802b734: a802 add r0, sp, #8 802b736: f10d 0107 add.w r1, sp, #7 802b73a: f7fc fb6b bl 8027e14 strcat(buf, "\",\"managerIP5\":\""); 802b73e: 4620 mov r0, r4 802b740: 4993 ldr r1, [pc, #588] ; (802b990 ) 802b742: f7f6 fa23 bl 8021b8c strncat(buf, str, len); 802b746: a902 add r1, sp, #8 802b748: f89d 2007 ldrb.w r2, [sp, #7] 802b74c: 4620 mov r0, r4 802b74e: f7f6 fbbf bl 8021ed0 /*Параметры реле и сухих контактов*/ GetDINTypeActStr(str, &len, 0); 802b752: 2200 movs r2, #0 802b754: a802 add r0, sp, #8 802b756: f10d 0107 add.w r1, sp, #7 802b75a: f7fc f96d bl 8027a38 strcat(buf, "\",\"di1\":\""); 802b75e: 4620 mov r0, r4 802b760: 498c ldr r1, [pc, #560] ; (802b994 ) 802b762: f7f6 fa13 bl 8021b8c strncat(buf, str, len); 802b766: a902 add r1, sp, #8 802b768: f89d 2007 ldrb.w r2, [sp, #7] 802b76c: 4620 mov r0, r4 802b76e: f7f6 fbaf bl 8021ed0 GetROTypeActStr(str, &len, 0); 802b772: 2200 movs r2, #0 802b774: a802 add r0, sp, #8 802b776: f10d 0107 add.w r1, sp, #7 802b77a: f7fc f971 bl 8027a60 strcat(buf, "\",\"ro1\":\""); 802b77e: 4620 mov r0, r4 802b780: 4985 ldr r1, [pc, #532] ; (802b998 ) 802b782: f7f6 fa03 bl 8021b8c strncat(buf, str, len); 802b786: a902 add r1, sp, #8 802b788: f89d 2007 ldrb.w r2, [sp, #7] 802b78c: 4620 mov r0, r4 802b78e: f7f6 fb9f bl 8021ed0 GetROTypeActStr(str, &len, 1); 802b792: 2201 movs r2, #1 802b794: a802 add r0, sp, #8 802b796: f10d 0107 add.w r1, sp, #7 802b79a: f7fc f961 bl 8027a60 strcat(buf, "\",\"ro2\":\""); 802b79e: 4620 mov r0, r4 802b7a0: 497e ldr r1, [pc, #504] ; (802b99c ) 802b7a2: f7f6 f9f3 bl 8021b8c strncat(buf, str, len); 802b7a6: f89d 2007 ldrb.w r2, [sp, #7] 802b7aa: a902 add r1, sp, #8 802b7ac: 4620 mov r0, r4 802b7ae: f7f6 fb8f bl 8021ed0 /* WEB */ GetIpStr(str, &len); 802b7b2: a802 add r0, sp, #8 802b7b4: f10d 0107 add.w r1, sp, #7 802b7b8: f7fc fa76 bl 8027ca8 strcat(buf, "\",\"ipaddr\":\""); 802b7bc: 4620 mov r0, r4 802b7be: 4978 ldr r1, [pc, #480] ; (802b9a0 ) 802b7c0: f7f6 f9e4 bl 8021b8c strncat(buf, str, len); 802b7c4: f89d 2007 ldrb.w r2, [sp, #7] 802b7c8: a902 add r1, sp, #8 802b7ca: 4620 mov r0, r4 802b7cc: f7f6 fb80 bl 8021ed0 GetGatewayStr(str, &len); 802b7d0: a802 add r0, sp, #8 802b7d2: f10d 0107 add.w r1, sp, #7 802b7d6: f7fc fa7d bl 8027cd4 strcat(buf, "\",\"gw\":\""); 802b7da: 4620 mov r0, r4 802b7dc: 4971 ldr r1, [pc, #452] ; (802b9a4 ) 802b7de: f7f6 f9d5 bl 8021b8c strncat(buf, str, len); 802b7e2: f89d 2007 ldrb.w r2, [sp, #7] 802b7e6: a902 add r1, sp, #8 802b7e8: 4620 mov r0, r4 802b7ea: f7f6 fb71 bl 8021ed0 GetMaskStr(str, &len); 802b7ee: a802 add r0, sp, #8 802b7f0: f10d 0107 add.w r1, sp, #7 802b7f4: f7fc fa84 bl 8027d00 strcat(buf, "\",\"mask\":\""); 802b7f8: 4620 mov r0, r4 802b7fa: 496b ldr r1, [pc, #428] ; (802b9a8 ) 802b7fc: f7f6 f9c6 bl 8021b8c strncat(buf, str, len); 802b800: f89d 2007 ldrb.w r2, [sp, #7] 802b804: a902 add r1, sp, #8 802b806: 4620 mov r0, r4 802b808: f7f6 fb62 bl 8021ed0 GetDhcpStateStr(str, &len); 802b80c: a802 add r0, sp, #8 802b80e: f10d 0107 add.w r1, sp, #7 802b812: f7fc fa8b bl 8027d2c strcat(buf, "\",\"dhcp\":"); 802b816: 4620 mov r0, r4 802b818: 4964 ldr r1, [pc, #400] ; (802b9ac ) 802b81a: f7f6 f9b7 bl 8021b8c strncat(buf, str, len); 802b81e: f89d 2007 ldrb.w r2, [sp, #7] 802b822: a902 add r1, sp, #8 802b824: 4620 mov r0, r4 802b826: f7f6 fb53 bl 8021ed0 /* RADIUS */ GetRDSIpStr(str, &len); 802b82a: a802 add r0, sp, #8 802b82c: f10d 0107 add.w r1, sp, #7 802b830: f7fc fb00 bl 8027e34 strcat(buf, ",\"rs_server\":\""); 802b834: 4620 mov r0, r4 802b836: 495e ldr r1, [pc, #376] ; (802b9b0 ) 802b838: f7f6 f9a8 bl 8021b8c strncat(buf, str, len); 802b83c: f89d 2007 ldrb.w r2, [sp, #7] 802b840: a902 add r1, sp, #8 802b842: 4620 mov r0, r4 802b844: f7f6 fb44 bl 8021ed0 GetRDSPortStr(str, &len); 802b848: a802 add r0, sp, #8 802b84a: f10d 0107 add.w r1, sp, #7 802b84e: f7fc fb01 bl 8027e54 strcat(buf, "\",\"rs_port\":\""); 802b852: 4620 mov r0, r4 802b854: 4957 ldr r1, [pc, #348] ; (802b9b4 ) 802b856: f7f6 f999 bl 8021b8c strncat(buf, str, len); 802b85a: f89d 2007 ldrb.w r2, [sp, #7] 802b85e: a902 add r1, sp, #8 802b860: 4620 mov r0, r4 802b862: f7f6 fb35 bl 8021ed0 GetRDSPasswordkStr(str, &len); 802b866: a802 add r0, sp, #8 802b868: f10d 0107 add.w r1, sp, #7 802b86c: f7fc fb16 bl 8027e9c strcat(buf, "\",\"rs_pwd\":\""); 802b870: 4620 mov r0, r4 802b872: 4951 ldr r1, [pc, #324] ; (802b9b8 ) 802b874: f7f6 f98a bl 8021b8c strncat(buf, str, len); 802b878: f89d 2007 ldrb.w r2, [sp, #7] 802b87c: a902 add r1, sp, #8 802b87e: 4620 mov r0, r4 802b880: f7f6 fb26 bl 8021ed0 GetRDSKeyAccesstStr(str, &len); 802b884: a802 add r0, sp, #8 802b886: f10d 0107 add.w r1, sp, #7 802b88a: f7fc faf5 bl 8027e78 strcat(buf, "\",\"rs_key\":\""); 802b88e: 4620 mov r0, r4 802b890: 494a ldr r1, [pc, #296] ; (802b9bc ) 802b892: f7f6 f97b bl 8021b8c strncat(buf, str, len); 802b896: f89d 2007 ldrb.w r2, [sp, #7] 802b89a: a902 add r1, sp, #8 802b89c: 4620 mov r0, r4 802b89e: f7f6 fb17 bl 8021ed0 GetRDSEnableStateStr(str, &len); 802b8a2: a802 add r0, sp, #8 802b8a4: f10d 0107 add.w r1, sp, #7 802b8a8: f7fc fb08 bl 8027ebc strcat(buf, "\",\"rs_enabled\":"); 802b8ac: 4620 mov r0, r4 802b8ae: 4944 ldr r1, [pc, #272] ; (802b9c0 ) 802b8b0: f7f6 f96c bl 8021b8c strncat(buf, str, len); 802b8b4: f89d 2007 ldrb.w r2, [sp, #7] 802b8b8: a902 add r1, sp, #8 802b8ba: 4620 mov r0, r4 802b8bc: f7f6 fb08 bl 8021ed0 /* Параметры даты и времени */ GetDateStr(str, &len); 802b8c0: a802 add r0, sp, #8 802b8c2: f10d 0107 add.w r1, sp, #7 802b8c6: f7fc f819 bl 80278fc strcat(buf, ",\"date\":\""); 802b8ca: 4620 mov r0, r4 802b8cc: 493d ldr r1, [pc, #244] ; (802b9c4 ) 802b8ce: f7f6 f95d bl 8021b8c strncat(buf, str, len); 802b8d2: f89d 2007 ldrb.w r2, [sp, #7] 802b8d6: a902 add r1, sp, #8 802b8d8: 4620 mov r0, r4 802b8da: f7f6 faf9 bl 8021ed0 GetTimeStr(str, &len); 802b8de: a802 add r0, sp, #8 802b8e0: f10d 0107 add.w r1, sp, #7 802b8e4: f7fc f828 bl 8027938 strcat(buf, "\",\"time\":\""); 802b8e8: 4620 mov r0, r4 802b8ea: 4937 ldr r1, [pc, #220] ; (802b9c8 ) 802b8ec: f7f6 f94e bl 8021b8c strncat(buf, str, len); 802b8f0: f89d 2007 ldrb.w r2, [sp, #7] 802b8f4: a902 add r1, sp, #8 802b8f6: 4620 mov r0, r4 802b8f8: f7f6 faea bl 8021ed0 /* Параметры SNTP */ GetSntpStateStr(str, &len); 802b8fc: a802 add r0, sp, #8 802b8fe: f10d 0107 add.w r1, sp, #7 802b902: f7fc f847 bl 8027994 strcat(buf, "\",\"ntp\":\""); 802b906: 4620 mov r0, r4 802b908: 4930 ldr r1, [pc, #192] ; (802b9cc ) 802b90a: f7f6 f93f bl 8021b8c strncat(buf, str, len); 802b90e: f89d 2007 ldrb.w r2, [sp, #7] 802b912: a902 add r1, sp, #8 802b914: 4620 mov r0, r4 802b916: f7f6 fadb bl 8021ed0 GetSntpServerIpStr(str, &len); 802b91a: a802 add r0, sp, #8 802b91c: f10d 0107 add.w r1, sp, #7 802b920: f7fc f852 bl 80279c8 strcat(buf, "\",\"ntpservip\":\""); 802b924: 4620 mov r0, r4 802b926: 492a ldr r1, [pc, #168] ; (802b9d0 ) 802b928: f7f6 f930 bl 8021b8c strncat(buf, str, len); 802b92c: f89d 2007 ldrb.w r2, [sp, #7] 802b930: a902 add r1, sp, #8 802b932: 4620 mov r0, r4 802b934: f7f6 facc bl 8021ed0 GetSntpTimeZoneStr(str, &len); 802b938: a802 add r0, sp, #8 802b93a: f10d 0107 add.w r1, sp, #7 802b93e: f7fc f853 bl 80279e8 strcat(buf, "\",\"utc\":\""); 802b942: 4620 mov r0, r4 802b944: 4923 ldr r1, [pc, #140] ; (802b9d4 ) 802b946: f7f6 f921 bl 8021b8c strncat(buf, str, len); 802b94a: f89d 2007 ldrb.w r2, [sp, #7] 802b94e: a902 add r1, sp, #8 802b950: 4620 mov r0, r4 802b952: f7f6 fabd bl 8021ed0 GetUnixTimeStr(str, &len); 802b956: a802 add r0, sp, #8 802b958: f10d 0107 add.w r1, sp, #7 802b95c: f7fc f804 bl 8027968 strcat(buf, "\",\"utm\":\""); 802b960: 4620 mov r0, r4 802b962: 491d ldr r1, [pc, #116] ; (802b9d8 ) 802b964: f7f6 f912 bl 8021b8c strncat(buf, str, len); 802b968: f89d 2007 ldrb.w r2, [sp, #7] 802b96c: a902 add r1, sp, #8 802b96e: 4620 mov r0, r4 802b970: e034 b.n 802b9dc 802b972: bf00 nop 802b974: 0803fae4 .word 0x0803fae4 802b978: 0803fc02 .word 0x0803fc02 802b97c: 0803fc16 .word 0x0803fc16 802b980: 0803fc2c .word 0x0803fc2c 802b984: 0803fc3c .word 0x0803fc3c 802b988: 0803fc4d .word 0x0803fc4d 802b98c: 0803fc5e .word 0x0803fc5e 802b990: 0803fc6f .word 0x0803fc6f 802b994: 0803fc80 .word 0x0803fc80 802b998: 0803fc8a .word 0x0803fc8a 802b99c: 0803fc94 .word 0x0803fc94 802b9a0: 0803fc9e .word 0x0803fc9e 802b9a4: 0803fcab .word 0x0803fcab 802b9a8: 0803fcb4 .word 0x0803fcb4 802b9ac: 0803fcbf .word 0x0803fcbf 802b9b0: 0803fcc9 .word 0x0803fcc9 802b9b4: 0803fcd8 .word 0x0803fcd8 802b9b8: 0803fce6 .word 0x0803fce6 802b9bc: 0803fcf3 .word 0x0803fcf3 802b9c0: 0803fd00 .word 0x0803fd00 802b9c4: 0803fd10 .word 0x0803fd10 802b9c8: 0803fd1a .word 0x0803fd1a 802b9cc: 0803fd25 .word 0x0803fd25 802b9d0: 0803fd2f .word 0x0803fd2f 802b9d4: 0803fd3f .word 0x0803fd3f 802b9d8: 0803fd49 .word 0x0803fd49 802b9dc: f7f6 fa78 bl 8021ed0 GetSntpLastDataStr(str, &len); 802b9e0: a802 add r0, sp, #8 802b9e2: f10d 0107 add.w r1, sp, #7 802b9e6: f7fc f817 bl 8027a18 strcat(buf, "\",\"lastsynctime\":\""); 802b9ea: 4620 mov r0, r4 802b9ec: 490f ldr r1, [pc, #60] ; (802ba2c ) 802b9ee: f7f6 f8cd bl 8021b8c strncat(buf, str, len); 802b9f2: f89d 2007 ldrb.w r2, [sp, #7] 802b9f6: a902 add r1, sp, #8 802b9f8: 4620 mov r0, r4 802b9fa: f7f6 fa69 bl 8021ed0 /* Признак изменения сетевых настроек */ GetWebReinitFlag(str, &len); 802b9fe: a802 add r0, sp, #8 802ba00: f10d 0107 add.w r1, sp, #7 802ba04: f7fc fa84 bl 8027f10 strcat(buf, "\",\"netsettings_changed\":\""); 802ba08: 4620 mov r0, r4 802ba0a: 4909 ldr r1, [pc, #36] ; (802ba30 ) 802ba0c: f7f6 f8be bl 8021b8c strncat(buf, str, len); 802ba10: a902 add r1, sp, #8 802ba12: f89d 2007 ldrb.w r2, [sp, #7] 802ba16: 4620 mov r0, r4 802ba18: f7f6 fa5a bl 8021ed0 strncat(buf, "\"}", 2); 802ba1c: 4620 mov r0, r4 802ba1e: 4905 ldr r1, [pc, #20] ; (802ba34 ) 802ba20: 2202 movs r2, #2 802ba22: f7f6 fa55 bl 8021ed0 //printf(buf); } 802ba26: b00a add sp, #40 ; 0x28 802ba28: bd10 pop {r4, pc} 802ba2a: bf00 nop 802ba2c: 0803fd53 .word 0x0803fd53 802ba30: 0803fbe5 .word 0x0803fbe5 802ba34: 0803fbff .word 0x0803fbff 0802ba38 : * @brief Возвращяет строку с информацией об устройстве * @retval None */ // TODO Согласовать максимальную длину строк void HTTP_GetInfo(char *buf) { 802ba38: b510 push {r4, lr} char str[40]; uint8_t len; /* Headers для поддержки saffari */ strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802ba3a: 4960 ldr r1, [pc, #384] ; (802bbbc ) * @brief Возвращяет строку с информацией об устройстве * @retval None */ // TODO Согласовать максимальную длину строк void HTTP_GetInfo(char *buf) { 802ba3c: b08c sub sp, #48 ; 0x30 802ba3e: 4604 mov r4, r0 char str[40]; uint8_t len; /* Headers для поддержки saffari */ strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802ba40: f7f6 f9b8 bl 8021db4 GetWorkTimeStr(str, &len); 802ba44: a802 add r0, sp, #8 802ba46: f10d 0107 add.w r1, sp, #7 802ba4a: f7fc f81d bl 8027a88 strcat(buf, "{\"uptime\":\""); 802ba4e: 4620 mov r0, r4 802ba50: 495b ldr r1, [pc, #364] ; (802bbc0 ) 802ba52: f7f6 f89b bl 8021b8c strncat(buf, str, len); 802ba56: f89d 2007 ldrb.w r2, [sp, #7] 802ba5a: a902 add r1, sp, #8 802ba5c: 4620 mov r0, r4 802ba5e: f7f6 fa37 bl 8021ed0 GetModelStr(str, &len); 802ba62: a802 add r0, sp, #8 802ba64: f10d 0107 add.w r1, sp, #7 802ba68: f7fc f834 bl 8027ad4 strcat(buf, "\",\"model\":\""); 802ba6c: 4620 mov r0, r4 802ba6e: 4955 ldr r1, [pc, #340] ; (802bbc4 ) 802ba70: f7f6 f88c bl 8021b8c strncat(buf, str, len); 802ba74: f89d 2007 ldrb.w r2, [sp, #7] 802ba78: a902 add r1, sp, #8 802ba7a: 4620 mov r0, r4 802ba7c: f7f6 fa28 bl 8021ed0 GetProductionDataStr(str, &len); 802ba80: a802 add r0, sp, #8 802ba82: f10d 0107 add.w r1, sp, #7 802ba86: f7fc f837 bl 8027af8 strcat(buf, "\",\"prodate\":\""); 802ba8a: 4620 mov r0, r4 802ba8c: 494e ldr r1, [pc, #312] ; (802bbc8 ) 802ba8e: f7f6 f87d bl 8021b8c strncat(buf, str, len); 802ba92: f89d 2007 ldrb.w r2, [sp, #7] 802ba96: a902 add r1, sp, #8 802ba98: 4620 mov r0, r4 802ba9a: f7f6 fa19 bl 8021ed0 GetVersionStr(str, &len); 802ba9e: a802 add r0, sp, #8 802baa0: f10d 0107 add.w r1, sp, #7 802baa4: f7fc f83a bl 8027b1c strcat(buf, "\",\"fwversion\":\""); 802baa8: 4620 mov r0, r4 802baaa: 4948 ldr r1, [pc, #288] ; (802bbcc ) 802baac: f7f6 f86e bl 8021b8c strncat(buf, str, len); 802bab0: f89d 2007 ldrb.w r2, [sp, #7] 802bab4: a902 add r1, sp, #8 802bab6: 4620 mov r0, r4 802bab8: f7f6 fa0a bl 8021ed0 GetMacStr(str, &len); 802babc: a802 add r0, sp, #8 802babe: f10d 0107 add.w r1, sp, #7 802bac2: f7fc f83d bl 8027b40 strcat(buf, "\",\"macaddr\":\""); 802bac6: 4620 mov r0, r4 802bac8: 4941 ldr r1, [pc, #260] ; (802bbd0 ) 802baca: f7f6 f85f bl 8021b8c strncat(buf, str, len); 802bace: f89d 2007 ldrb.w r2, [sp, #7] 802bad2: a902 add r1, sp, #8 802bad4: 4620 mov r0, r4 802bad6: f7f6 f9fb bl 8021ed0 GetSerialNumberStr(str, &len); 802bada: a802 add r0, sp, #8 802badc: f10d 0107 add.w r1, sp, #7 802bae0: f7fc f840 bl 8027b64 strcat(buf, "\",\"serno\":\""); 802bae4: 4620 mov r0, r4 802bae6: 493b ldr r1, [pc, #236] ; (802bbd4 ) 802bae8: f7f6 f850 bl 8021b8c strncat(buf, str, len); 802baec: f89d 2007 ldrb.w r2, [sp, #7] 802baf0: a902 add r1, sp, #8 802baf2: 4620 mov r0, r4 802baf4: f7f6 f9ec bl 8021ed0 GetOwnerStr(str, &len); 802baf8: a802 add r0, sp, #8 802bafa: f10d 0107 add.w r1, sp, #7 802bafe: f7fc f843 bl 8027b88 strcat(buf, "\",\"owner\":\""); 802bb02: 4620 mov r0, r4 802bb04: 4934 ldr r1, [pc, #208] ; (802bbd8 ) 802bb06: f7f6 f841 bl 8021b8c strncat(buf, str, len); 802bb0a: f89d 2007 ldrb.w r2, [sp, #7] 802bb0e: a902 add r1, sp, #8 802bb10: 4620 mov r0, r4 802bb12: f7f6 f9dd bl 8021ed0 GetLocationStr(str, &len); 802bb16: a802 add r0, sp, #8 802bb18: f10d 0107 add.w r1, sp, #7 802bb1c: f7fc f846 bl 8027bac strcat(buf, "\",\"sysLocation\":\""); 802bb20: 4620 mov r0, r4 802bb22: 492e ldr r1, [pc, #184] ; (802bbdc ) 802bb24: f7f6 f832 bl 8021b8c strncat(buf, str, len); 802bb28: f89d 2007 ldrb.w r2, [sp, #7] 802bb2c: a902 add r1, sp, #8 802bb2e: 4620 mov r0, r4 802bb30: f7f6 f9ce bl 8021ed0 GetCommentsStr(str, &len); 802bb34: a802 add r0, sp, #8 802bb36: f10d 0107 add.w r1, sp, #7 802bb3a: f7fc f849 bl 8027bd0 strcat(buf, "\",\"comment\":\""); 802bb3e: 4620 mov r0, r4 802bb40: 4927 ldr r1, [pc, #156] ; (802bbe0 ) 802bb42: f7f6 f823 bl 8021b8c strncat(buf, str, len); 802bb46: f89d 2007 ldrb.w r2, [sp, #7] 802bb4a: a902 add r1, sp, #8 802bb4c: 4620 mov r0, r4 802bb4e: f7f6 f9bf bl 8021ed0 GetUPSModelStr(str, &len); 802bb52: a802 add r0, sp, #8 802bb54: f10d 0107 add.w r1, sp, #7 802bb58: f7fc f84c bl 8027bf4 strcat(buf, "\",\"ups_model\":\""); 802bb5c: 4620 mov r0, r4 802bb5e: 4921 ldr r1, [pc, #132] ; (802bbe4 ) 802bb60: f7f6 f814 bl 8021b8c strncat(buf, str, len); 802bb64: f89d 2007 ldrb.w r2, [sp, #7] 802bb68: a902 add r1, sp, #8 802bb6a: 4620 mov r0, r4 802bb6c: f7f6 f9b0 bl 8021ed0 GetUPSVersionStr(str, &len); 802bb70: a802 add r0, sp, #8 802bb72: f10d 0107 add.w r1, sp, #7 802bb76: f7fc f84f bl 8027c18 strcat(buf, "\",\"ups_fwversion\":\""); 802bb7a: 4620 mov r0, r4 802bb7c: 491a ldr r1, [pc, #104] ; (802bbe8 ) 802bb7e: f7f6 f805 bl 8021b8c strncat(buf, str, len); 802bb82: f89d 2007 ldrb.w r2, [sp, #7] 802bb86: a902 add r1, sp, #8 802bb88: 4620 mov r0, r4 802bb8a: f7f6 f9a1 bl 8021ed0 /* Признак изменения сетевых настроек */ GetWebReinitFlag(str, &len); 802bb8e: a802 add r0, sp, #8 802bb90: f10d 0107 add.w r1, sp, #7 802bb94: f7fc f9bc bl 8027f10 strcat(buf, "\",\"netsettings_changed\":\""); 802bb98: 4620 mov r0, r4 802bb9a: 4914 ldr r1, [pc, #80] ; (802bbec ) 802bb9c: f7f5 fff6 bl 8021b8c strncat(buf, str, len); 802bba0: a902 add r1, sp, #8 802bba2: f89d 2007 ldrb.w r2, [sp, #7] 802bba6: 4620 mov r0, r4 802bba8: f7f6 f992 bl 8021ed0 strncat(buf, "\"}", 2); 802bbac: 4620 mov r0, r4 802bbae: 4910 ldr r1, [pc, #64] ; (802bbf0 ) 802bbb0: 2202 movs r2, #2 802bbb2: f7f6 f98d bl 8021ed0 } 802bbb6: b00c add sp, #48 ; 0x30 802bbb8: bd10 pop {r4, pc} 802bbba: bf00 nop 802bbbc: 0803fae4 .word 0x0803fae4 802bbc0: 0803fd66 .word 0x0803fd66 802bbc4: 0803fd72 .word 0x0803fd72 802bbc8: 0803fd7e .word 0x0803fd7e 802bbcc: 0803fd8c .word 0x0803fd8c 802bbd0: 0803fd9c .word 0x0803fd9c 802bbd4: 0803fdaa .word 0x0803fdaa 802bbd8: 0803fdb6 .word 0x0803fdb6 802bbdc: 0803fdc2 .word 0x0803fdc2 802bbe0: 0803fdd4 .word 0x0803fdd4 802bbe4: 0803fde2 .word 0x0803fde2 802bbe8: 0803fdf2 .word 0x0803fdf2 802bbec: 0803fbe5 .word 0x0803fbe5 802bbf0: 0803fbff .word 0x0803fbff 0802bbf4 : /** * @brief Возвращает uptime, freq, dutycicle */ void HTTP_GetProgonParams(char *buf) { 802bbf4: b510 push {r4, lr} char str[20]; u32_t tick; strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802bbf6: 4915 ldr r1, [pc, #84] ; (802bc4c ) /** * @brief Возвращает uptime, freq, dutycicle */ void HTTP_GetProgonParams(char *buf) { 802bbf8: b086 sub sp, #24 802bbfa: 4604 mov r4, r0 char str[20]; u32_t tick; strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); 802bbfc: f7f6 f8da bl 8021db4 strcat(buf, "{\"uptime\":\""); 802bc00: 4913 ldr r1, [pc, #76] ; (802bc50 ) 802bc02: 4620 mov r0, r4 802bc04: f7f5 ffc2 bl 8021b8c snmp_get_sysuptime(&tick); 802bc08: 4668 mov r0, sp 802bc0a: f005 fd03 bl 8031614 tick = tick/100; 802bc0e: 9b00 ldr r3, [sp, #0] 802bc10: 2264 movs r2, #100 ; 0x64 802bc12: fbb3 f3f2 udiv r3, r3, r2 memset(str, 0, 20); 802bc16: 2100 movs r1, #0 802bc18: 2214 movs r2, #20 802bc1a: a801 add r0, sp, #4 strcpy(buf, "HTTP/1.0 200 OK\r\nContent-Type:text/html\r\n\r\n"); strcat(buf, "{\"uptime\":\""); snmp_get_sysuptime(&tick); tick = tick/100; 802bc1c: 9300 str r3, [sp, #0] memset(str, 0, 20); 802bc1e: f7f5 ff4f bl 8021ac0 sprintf(str, "%d", tick); 802bc22: 9a00 ldr r2, [sp, #0] 802bc24: 490b ldr r1, [pc, #44] ; (802bc54 ) 802bc26: a801 add r0, sp, #4 802bc28: f7fb fd8c bl 8027744 strncat(buf, str, strlen(str)); 802bc2c: a801 add r0, sp, #4 802bc2e: f7f6 f91f bl 8021e70 802bc32: a901 add r1, sp, #4 802bc34: 4602 mov r2, r0 802bc36: 4620 mov r0, r4 802bc38: f7f6 f94a bl 8021ed0 strncat(buf, "\"}", 2); 802bc3c: 4620 mov r0, r4 802bc3e: 4906 ldr r1, [pc, #24] ; (802bc58 ) 802bc40: 2202 movs r2, #2 802bc42: f7f6 f945 bl 8021ed0 } 802bc46: b006 add sp, #24 802bc48: bd10 pop {r4, pc} 802bc4a: bf00 nop 802bc4c: 0803fae4 .word 0x0803fae4 802bc50: 0803fd66 .word 0x0803fd66 802bc54: 08035e55 .word 0x08035e55 802bc58: 0803fbff .word 0x0803fbff 0802bc5c : /** * @brief Сброс настроек (всё кроме сетевых параметров) */ void HTTP_ResetSettings(void) { 802bc5c: b508 push {r3, lr} //taskENTER_CRITICAL(); SETTINGS_SetPartDefault(); 802bc5e: f7fc fd3b bl 80286d8 SETTINGS_Save(); //taskEXIT_CRITICAL(); } 802bc62: e8bd 4008 ldmia.w sp!, {r3, lr} void HTTP_ResetSettings(void) { //taskENTER_CRITICAL(); SETTINGS_SetPartDefault(); SETTINGS_Save(); 802bc66: f7fc bcd7 b.w 8028618 0802bc6a : */ void HTTP_SaveSettings(void) { // taskENTER_CRITICAL(); SETTINGS_Save(); 802bc6a: f7fc bcd5 b.w 8028618 0802bc6e : /** * @brief Перезагрузка контроллера */ void HTTP_Reboot(void) { 802bc6e: b508 push {r3, lr} vTaskDelay(1010); 802bc70: f240 30f2 movw r0, #1010 ; 0x3f2 802bc74: f7fd fe1e bl 80298b4 NVIC_SystemReset(); 802bc78: f7ff fbc2 bl 802b400 0802bc7c : * bootloader и перезаписаны настройки * * false - обычная перезагрузка */ void HTTP_StartResetTask(bool fBootMode) { 802bc7c: b51f push {r0, r1, r2, r3, r4, lr} static bool temp; temp = fBootMode; 802bc7e: 4b07 ldr r3, [pc, #28] ; (802bc9c ) xTaskCreate(vTaskReboot, "RebootTask", configMINIMAL_STACK_SIZE, 802bc80: 4907 ldr r1, [pc, #28] ; (802bca0 ) */ void HTTP_StartResetTask(bool fBootMode) { static bool temp; temp = fBootMode; 802bc82: 7018 strb r0, [r3, #0] xTaskCreate(vTaskReboot, "RebootTask", configMINIMAL_STACK_SIZE, 802bc84: 2200 movs r2, #0 802bc86: 9200 str r2, [sp, #0] 802bc88: 9201 str r2, [sp, #4] 802bc8a: 9202 str r2, [sp, #8] 802bc8c: 9203 str r2, [sp, #12] 802bc8e: 4805 ldr r0, [pc, #20] ; (802bca4 ) 802bc90: 2280 movs r2, #128 ; 0x80 802bc92: f7fd fb75 bl 8029380 (void*)&temp, tskIDLE_PRIORITY, NULL); } 802bc96: b005 add sp, #20 802bc98: bd00 pop {pc} 802bc9a: bf00 nop 802bc9c: 20002a44 .word 0x20002a44 802bca0: 0803fe06 .word 0x0803fe06 802bca4: 0802b421 .word 0x0802b421 0802bca8 : tcpip_thread(void *arg) { struct tcpip_msg *msg; LWIP_UNUSED_ARG(arg); if (tcpip_init_done != NULL) { 802bca8: 4b1e ldr r3, [pc, #120] ; (802bd24 ) 802bcaa: 681b ldr r3, [r3, #0] * * @param arg unused argument */ static void tcpip_thread(void *arg) { 802bcac: b507 push {r0, r1, r2, lr} struct tcpip_msg *msg; LWIP_UNUSED_ARG(arg); if (tcpip_init_done != NULL) { 802bcae: b113 cbz r3, 802bcb6 tcpip_init_done(tcpip_init_done_arg); 802bcb0: 4a1d ldr r2, [pc, #116] ; (802bd28 ) 802bcb2: 6810 ldr r0, [r2, #0] 802bcb4: 4798 blx r3 LOCK_TCPIP_CORE(); while (1) { /* MAIN Loop */ UNLOCK_TCPIP_CORE(); LWIP_TCPIP_THREAD_ALIVE(); /* wait for a message, timeouts are processed while waiting */ sys_timeouts_mbox_fetch(&mbox, (void **)&msg); 802bcb6: 481d ldr r0, [pc, #116] ; (802bd2c ) 802bcb8: a901 add r1, sp, #4 802bcba: f003 fd0d bl 802f6d8 LOCK_TCPIP_CORE(); switch (msg->type) { 802bcbe: 9b01 ldr r3, [sp, #4] 802bcc0: 781a ldrb r2, [r3, #0] 802bcc2: 2a05 cmp r2, #5 802bcc4: d8f7 bhi.n 802bcb6 802bcc6: e8df f002 tbb [pc, r2] 802bcca: 0703 .short 0x0703 802bccc: 28201b15 .word 0x28201b15 #if LWIP_NETCONN case TCPIP_MSG_API: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: API message %p\n", (void *)msg)); msg->msg.apimsg->function(&(msg->msg.apimsg->msg)); 802bcd0: 6898 ldr r0, [r3, #8] 802bcd2: 6803 ldr r3, [r0, #0] 802bcd4: 3004 adds r0, #4 802bcd6: e7ed b.n 802bcb4 #if !LWIP_TCPIP_CORE_LOCKING_INPUT case TCPIP_MSG_INPKT: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: PACKET %p\n", (void *)msg)); #if LWIP_ETHERNET if (msg->msg.inp.netif->flags & (NETIF_FLAG_ETHARP | NETIF_FLAG_ETHERNET)) { 802bcd8: 68d9 ldr r1, [r3, #12] ethernet_input(msg->msg.inp.p, msg->msg.inp.netif); 802bcda: 6898 ldr r0, [r3, #8] #if !LWIP_TCPIP_CORE_LOCKING_INPUT case TCPIP_MSG_INPKT: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: PACKET %p\n", (void *)msg)); #if LWIP_ETHERNET if (msg->msg.inp.netif->flags & (NETIF_FLAG_ETHARP | NETIF_FLAG_ETHERNET)) { 802bcdc: f891 202d ldrb.w r2, [r1, #45] ; 0x2d 802bce0: f012 0f60 tst.w r2, #96 ; 0x60 802bce4: d002 beq.n 802bcec ethernet_input(msg->msg.inp.p, msg->msg.inp.netif); 802bce6: f008 fb51 bl 803438c 802bcea: e001 b.n 802bcf0 } else #endif /* LWIP_ETHERNET */ { ip_input(msg->msg.inp.p, msg->msg.inp.netif); 802bcec: f004 f94e bl 802ff8c } memp_free(MEMP_TCPIP_MSG_INPKT, msg); 802bcf0: 2008 movs r0, #8 802bcf2: e00e b.n 802bd12 #endif /* LWIP_NETIF_API */ #if LWIP_TCPIP_TIMEOUT case TCPIP_MSG_TIMEOUT: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: TIMEOUT %p\n", (void *)msg)); sys_timeout(msg->msg.tmo.msecs, msg->msg.tmo.h, msg->msg.tmo.arg); 802bcf4: f103 0008 add.w r0, r3, #8 802bcf8: c807 ldmia r0, {r0, r1, r2} 802bcfa: f003 fc1f bl 802f53c 802bcfe: e007 b.n 802bd10 memp_free(MEMP_TCPIP_MSG_API, msg); break; case TCPIP_MSG_UNTIMEOUT: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: UNTIMEOUT %p\n", (void *)msg)); sys_untimeout(msg->msg.tmo.h, msg->msg.tmo.arg); 802bd00: 68d8 ldr r0, [r3, #12] 802bd02: 6919 ldr r1, [r3, #16] 802bd04: f003 fcc4 bl 802f690 802bd08: e002 b.n 802bd10 break; #endif /* LWIP_TCPIP_TIMEOUT */ case TCPIP_MSG_CALLBACK: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: CALLBACK %p\n", (void *)msg)); msg->msg.cb.function(msg->msg.cb.ctx); 802bd0a: 689a ldr r2, [r3, #8] 802bd0c: 68d8 ldr r0, [r3, #12] 802bd0e: 4790 blx r2 memp_free(MEMP_TCPIP_MSG_API, msg); 802bd10: 2007 movs r0, #7 802bd12: 9901 ldr r1, [sp, #4] 802bd14: f001 f882 bl 802ce1c break; 802bd18: e7cd b.n 802bcb6 case TCPIP_MSG_CALLBACK_STATIC: LWIP_DEBUGF(TCPIP_DEBUG, ("tcpip_thread: CALLBACK_STATIC %p\n", (void *)msg)); msg->msg.cb.function(msg->msg.cb.ctx); 802bd1a: 689a ldr r2, [r3, #8] 802bd1c: 68d8 ldr r0, [r3, #12] 802bd1e: 4790 blx r2 break; 802bd20: e7c9 b.n 802bcb6 802bd22: bf00 nop 802bd24: 20002a50 .word 0x20002a50 802bd28: 20002a4c .word 0x20002a4c 802bd2c: 20002a48 .word 0x20002a48 0802bd30 : * NETIF_FLAG_ETHERNET flags) * @param inp the network interface on which the packet was received */ err_t tcpip_input(struct pbuf *p, struct netif *inp) { 802bd30: b5f8 push {r3, r4, r5, r6, r7, lr} UNLOCK_TCPIP_CORE(); return ret; #else /* LWIP_TCPIP_CORE_LOCKING_INPUT */ struct tcpip_msg *msg; if (!sys_mbox_valid(&mbox)) { 802bd32: 4d0e ldr r5, [pc, #56] ; (802bd6c ) 802bd34: 682b ldr r3, [r5, #0] * NETIF_FLAG_ETHERNET flags) * @param inp the network interface on which the packet was received */ err_t tcpip_input(struct pbuf *p, struct netif *inp) { 802bd36: 4606 mov r6, r0 802bd38: 460f mov r7, r1 UNLOCK_TCPIP_CORE(); return ret; #else /* LWIP_TCPIP_CORE_LOCKING_INPUT */ struct tcpip_msg *msg; if (!sys_mbox_valid(&mbox)) { 802bd3a: b193 cbz r3, 802bd62 return ERR_VAL; } msg = (struct tcpip_msg *)memp_malloc(MEMP_TCPIP_MSG_INPKT); 802bd3c: 2008 movs r0, #8 802bd3e: f001 f857 bl 802cdf0 if (msg == NULL) { 802bd42: 4604 mov r4, r0 802bd44: b178 cbz r0, 802bd66 return ERR_MEM; } msg->type = TCPIP_MSG_INPKT; 802bd46: 2301 movs r3, #1 802bd48: 7003 strb r3, [r0, #0] msg->msg.inp.p = p; 802bd4a: 6086 str r6, [r0, #8] msg->msg.inp.netif = inp; 802bd4c: 60c7 str r7, [r0, #12] if (sys_mbox_trypost(&mbox, msg) != ERR_OK) { 802bd4e: 4621 mov r1, r4 802bd50: 4628 mov r0, r5 802bd52: f008 fd69 bl 8034828 802bd56: b138 cbz r0, 802bd68 memp_free(MEMP_TCPIP_MSG_INPKT, msg); 802bd58: 2008 movs r0, #8 802bd5a: 4621 mov r1, r4 802bd5c: f001 f85e bl 802ce1c 802bd60: e001 b.n 802bd66 return ret; #else /* LWIP_TCPIP_CORE_LOCKING_INPUT */ struct tcpip_msg *msg; if (!sys_mbox_valid(&mbox)) { return ERR_VAL; 802bd62: 20fa movs r0, #250 ; 0xfa 802bd64: e000 b.n 802bd68 } msg = (struct tcpip_msg *)memp_malloc(MEMP_TCPIP_MSG_INPKT); if (msg == NULL) { return ERR_MEM; 802bd66: 20ff movs r0, #255 ; 0xff memp_free(MEMP_TCPIP_MSG_INPKT, msg); return ERR_MEM; } return ERR_OK; #endif /* LWIP_TCPIP_CORE_LOCKING_INPUT */ } 802bd68: b240 sxtb r0, r0 802bd6a: bdf8 pop {r3, r4, r5, r6, r7, pc} 802bd6c: 20002a48 .word 0x20002a48 0802bd70 : * @param initfunc a function to call when tcpip_thread is running and finished initializing * @param arg argument to pass to initfunc */ void tcpip_init(tcpip_init_done_fn initfunc, void *arg) { 802bd70: b537 push {r0, r1, r2, r4, r5, lr} 802bd72: 4604 mov r4, r0 802bd74: 460d mov r5, r1 lwip_init(); 802bd76: f000 feb3 bl 802cae0 tcpip_init_done = initfunc; 802bd7a: 4b09 ldr r3, [pc, #36] ; (802bda0 ) tcpip_init_done_arg = arg; if(sys_mbox_new(&mbox, TCPIP_MBOX_SIZE) != ERR_OK) { 802bd7c: 4809 ldr r0, [pc, #36] ; (802bda4 ) void tcpip_init(tcpip_init_done_fn initfunc, void *arg) { lwip_init(); tcpip_init_done = initfunc; 802bd7e: 601c str r4, [r3, #0] tcpip_init_done_arg = arg; 802bd80: 4b09 ldr r3, [pc, #36] ; (802bda8 ) if(sys_mbox_new(&mbox, TCPIP_MBOX_SIZE) != ERR_OK) { 802bd82: 2132 movs r1, #50 ; 0x32 tcpip_init(tcpip_init_done_fn initfunc, void *arg) { lwip_init(); tcpip_init_done = initfunc; tcpip_init_done_arg = arg; 802bd84: 601d str r5, [r3, #0] if(sys_mbox_new(&mbox, TCPIP_MBOX_SIZE) != ERR_OK) { 802bd86: f008 fd41 bl 803480c if(sys_mutex_new(&lock_tcpip_core) != ERR_OK) { LWIP_ASSERT("failed to create lock_tcpip_core", 0); } #endif /* LWIP_TCPIP_CORE_LOCKING */ sys_thread_new(TCPIP_THREAD_NAME, tcpip_thread, NULL, TCPIP_THREAD_STACKSIZE, TCPIP_THREAD_PRIO); 802bd8a: 2303 movs r3, #3 802bd8c: 9300 str r3, [sp, #0] 802bd8e: 4907 ldr r1, [pc, #28] ; (802bdac ) 802bd90: 4807 ldr r0, [pc, #28] ; (802bdb0 ) 802bd92: 2200 movs r2, #0 802bd94: f44f 73c8 mov.w r3, #400 ; 0x190 802bd98: f008 fdb7 bl 803490a } 802bd9c: bd3e pop {r1, r2, r3, r4, r5, pc} 802bd9e: bf00 nop 802bda0: 20002a50 .word 0x20002a50 802bda4: 20002a48 .word 0x20002a48 802bda8: 20002a4c .word 0x20002a4c 802bdac: 0802bca9 .word 0x0802bca9 802bdb0: 0803fe11 .word 0x0803fe11 0802bdb4 : * @return n in network byte order */ u16_t lwip_htons(u16_t n) { return ((n & 0xff) << 8) | ((n & 0xff00) >> 8); 802bdb4: 0a03 lsrs r3, r0, #8 802bdb6: ea43 2000 orr.w r0, r3, r0, lsl #8 } 802bdba: b280 uxth r0, r0 802bdbc: 4770 bx lr 0802bdbe : * @return n in network byte order */ u16_t lwip_htons(u16_t n) { return ((n & 0xff) << 8) | ((n & 0xff00) >> 8); 802bdbe: 0a03 lsrs r3, r0, #8 802bdc0: ea43 2000 orr.w r0, r3, r0, lsl #8 */ u16_t lwip_ntohs(u16_t n) { return lwip_htons(n); } 802bdc4: b280 uxth r0, r0 802bdc6: 4770 bx lr 0802bdc8 : { return ((n & 0xff) << 24) | ((n & 0xff00) << 8) | ((n & 0xff0000UL) >> 8) | ((n & 0xff000000UL) >> 24); } 802bdc8: ba00 rev r0, r0 802bdca: 4770 bx lr 0802bdcc : * @return n in host byte order */ u32_t lwip_ntohl(u32_t n) { return lwip_htonl(n); 802bdcc: f7ff bffc b.w 802bdc8 0802bdd0 : * If the state changed, reset the number of tries. */ static void dhcp_set_state(struct dhcp *dhcp, u8_t new_state) { if (new_state != dhcp->state) { 802bdd0: 7b03 ldrb r3, [r0, #12] 802bdd2: 428b cmp r3, r1 802bdd4: d003 beq.n 802bdde dhcp->state = new_state; dhcp->tries = 0; 802bdd6: 2300 movs r3, #0 */ static void dhcp_set_state(struct dhcp *dhcp, u8_t new_state) { if (new_state != dhcp->state) { dhcp->state = new_state; 802bdd8: 7301 strb r1, [r0, #12] dhcp->tries = 0; 802bdda: 7343 strb r3, [r0, #13] dhcp->request_timeout = 0; 802bddc: 8343 strh r3, [r0, #26] 802bdde: 4770 bx lr 0802bde0 : */ static void dhcp_option(struct dhcp *dhcp, u8_t option_type, u8_t option_len) { LWIP_ASSERT("dhcp_option: dhcp->options_out_len + 2 + option_len <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U + option_len <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = option_type; 802bde0: 8b03 ldrh r3, [r0, #24] * DHCP message. * */ static void dhcp_option(struct dhcp *dhcp, u8_t option_type, u8_t option_len) { 802bde2: b510 push {r4, lr} LWIP_ASSERT("dhcp_option: dhcp->options_out_len + 2 + option_len <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U + option_len <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = option_type; 802bde4: 6944 ldr r4, [r0, #20] 802bde6: 18e4 adds r4, r4, r3 802bde8: f884 10f0 strb.w r1, [r4, #240] ; 0xf0 dhcp->msg_out->options[dhcp->options_out_len++] = option_len; 802bdec: 6941 ldr r1, [r0, #20] */ static void dhcp_option(struct dhcp *dhcp, u8_t option_type, u8_t option_len) { LWIP_ASSERT("dhcp_option: dhcp->options_out_len + 2 + option_len <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U + option_len <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = option_type; 802bdee: 1c5c adds r4, r3, #1 dhcp->msg_out->options[dhcp->options_out_len++] = option_len; 802bdf0: fa11 f184 uxtah r1, r1, r4 802bdf4: 3302 adds r3, #2 802bdf6: f881 20f0 strb.w r2, [r1, #240] ; 0xf0 802bdfa: 8303 strh r3, [r0, #24] 802bdfc: bd10 pop {r4, pc} 0802bdfe : */ static void dhcp_option_byte(struct dhcp *dhcp, u8_t value) { LWIP_ASSERT("dhcp_option_byte: dhcp->options_out_len < DHCP_OPTIONS_LEN", dhcp->options_out_len < DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = value; 802bdfe: 8b03 ldrh r3, [r0, #24] 802be00: 6942 ldr r2, [r0, #20] 802be02: 18d2 adds r2, r2, r3 802be04: 3301 adds r3, #1 802be06: f882 10f0 strb.w r1, [r2, #240] ; 0xf0 802be0a: 8303 strh r3, [r0, #24] 802be0c: 4770 bx lr 0802be0e : static void dhcp_option_short(struct dhcp *dhcp, u16_t value) { LWIP_ASSERT("dhcp_option_short: dhcp->options_out_len + 2 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff00U) >> 8); 802be0e: 8b03 ldrh r3, [r0, #24] 802be10: 6942 ldr r2, [r0, #20] 802be12: 18d2 adds r2, r2, r3 dhcp->msg_out->options[dhcp->options_out_len++] = value; } static void dhcp_option_short(struct dhcp *dhcp, u16_t value) { 802be14: b510 push {r4, lr} LWIP_ASSERT("dhcp_option_short: dhcp->options_out_len + 2 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff00U) >> 8); 802be16: 0a0c lsrs r4, r1, #8 802be18: f882 40f0 strb.w r4, [r2, #240] ; 0xf0 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t) (value & 0x00ffU); 802be1c: 6942 ldr r2, [r0, #20] static void dhcp_option_short(struct dhcp *dhcp, u16_t value) { LWIP_ASSERT("dhcp_option_short: dhcp->options_out_len + 2 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 2U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff00U) >> 8); 802be1e: 1c5c adds r4, r3, #1 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t) (value & 0x00ffU); 802be20: fa12 f284 uxtah r2, r2, r4 802be24: 3302 adds r3, #2 802be26: f882 10f0 strb.w r1, [r2, #240] ; 0xf0 802be2a: 8303 strh r3, [r0, #24] 802be2c: bd10 pop {r4, pc} 0802be2e : static void dhcp_option_long(struct dhcp *dhcp, u32_t value) { LWIP_ASSERT("dhcp_option_long: dhcp->options_out_len + 4 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 4U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff000000UL) >> 24); 802be2e: 8b03 ldrh r3, [r0, #24] 802be30: 6942 ldr r2, [r0, #20] 802be32: 18d2 adds r2, r2, r3 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t) (value & 0x00ffU); } static void dhcp_option_long(struct dhcp *dhcp, u32_t value) { 802be34: b510 push {r4, lr} LWIP_ASSERT("dhcp_option_long: dhcp->options_out_len + 4 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 4U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff000000UL) >> 24); 802be36: 0e0c lsrs r4, r1, #24 802be38: f882 40f0 strb.w r4, [r2, #240] ; 0xf0 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x00ff0000UL) >> 16); 802be3c: 6942 ldr r2, [r0, #20] static void dhcp_option_long(struct dhcp *dhcp, u32_t value) { LWIP_ASSERT("dhcp_option_long: dhcp->options_out_len + 4 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 4U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff000000UL) >> 24); 802be3e: 1c5c adds r4, r3, #1 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x00ff0000UL) >> 16); 802be40: fa12 f284 uxtah r2, r2, r4 802be44: f3c1 4407 ubfx r4, r1, #16, #8 802be48: f882 40f0 strb.w r4, [r2, #240] ; 0xf0 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x0000ff00UL) >> 8); 802be4c: 6942 ldr r2, [r0, #20] static void dhcp_option_long(struct dhcp *dhcp, u32_t value) { LWIP_ASSERT("dhcp_option_long: dhcp->options_out_len + 4 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 4U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff000000UL) >> 24); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x00ff0000UL) >> 16); 802be4e: 1c9c adds r4, r3, #2 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x0000ff00UL) >> 8); 802be50: fa12 f284 uxtah r2, r2, r4 802be54: f3c1 2407 ubfx r4, r1, #8, #8 802be58: f882 40f0 strb.w r4, [r2, #240] ; 0xf0 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x000000ffUL)); 802be5c: 6942 ldr r2, [r0, #20] dhcp_option_long(struct dhcp *dhcp, u32_t value) { LWIP_ASSERT("dhcp_option_long: dhcp->options_out_len + 4 <= DHCP_OPTIONS_LEN", dhcp->options_out_len + 4U <= DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0xff000000UL) >> 24); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x00ff0000UL) >> 16); dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x0000ff00UL) >> 8); 802be5e: 1cdc adds r4, r3, #3 dhcp->msg_out->options[dhcp->options_out_len++] = (u8_t)((value & 0x000000ffUL)); 802be60: fa12 f284 uxtah r2, r2, r4 802be64: 3304 adds r3, #4 802be66: f882 10f0 strb.w r1, [r2, #240] ; 0xf0 802be6a: 8303 strh r3, [r0, #24] 802be6c: bd10 pop {r4, pc} 0802be6e : * @param dhcp DHCP state structure */ static void dhcp_option_trailer(struct dhcp *dhcp) { LWIP_ERROR("dhcp_option_trailer: dhcp != NULL", (dhcp != NULL), return;); 802be6e: b190 cbz r0, 802be96 LWIP_ASSERT("dhcp_option_trailer: dhcp->msg_out != NULL\n", dhcp->msg_out != NULL); LWIP_ASSERT("dhcp_option_trailer: dhcp->options_out_len < DHCP_OPTIONS_LEN\n", dhcp->options_out_len < DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = DHCP_OPTION_END; 802be70: 8b03 ldrh r3, [r0, #24] 802be72: 6942 ldr r2, [r0, #20] 802be74: 18d2 adds r2, r2, r3 802be76: 21ff movs r1, #255 ; 0xff 802be78: 3301 adds r3, #1 802be7a: f882 10f0 strb.w r1, [r2, #240] ; 0xf0 802be7e: 8303 strh r3, [r0, #24] /* packet is too small, or not 4 byte aligned? */ while (((dhcp->options_out_len < DHCP_MIN_OPTIONS_LEN) || (dhcp->options_out_len & 3)) && (dhcp->options_out_len < DHCP_OPTIONS_LEN)) { /* add a fill/padding byte */ dhcp->msg_out->options[dhcp->options_out_len++] = 0; 802be80: 2100 movs r1, #0 LWIP_ERROR("dhcp_option_trailer: dhcp != NULL", (dhcp != NULL), return;); LWIP_ASSERT("dhcp_option_trailer: dhcp->msg_out != NULL\n", dhcp->msg_out != NULL); LWIP_ASSERT("dhcp_option_trailer: dhcp->options_out_len < DHCP_OPTIONS_LEN\n", dhcp->options_out_len < DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = DHCP_OPTION_END; /* packet is too small, or not 4 byte aligned? */ while (((dhcp->options_out_len < DHCP_MIN_OPTIONS_LEN) || (dhcp->options_out_len & 3)) && 802be82: e005 b.n 802be90 (dhcp->options_out_len < DHCP_OPTIONS_LEN)) { /* add a fill/padding byte */ dhcp->msg_out->options[dhcp->options_out_len++] = 0; 802be84: 6942 ldr r2, [r0, #20] 802be86: 18d2 adds r2, r2, r3 802be88: 3301 adds r3, #1 802be8a: f882 10f0 strb.w r1, [r2, #240] ; 0xf0 802be8e: 8303 strh r3, [r0, #24] LWIP_ERROR("dhcp_option_trailer: dhcp != NULL", (dhcp != NULL), return;); LWIP_ASSERT("dhcp_option_trailer: dhcp->msg_out != NULL\n", dhcp->msg_out != NULL); LWIP_ASSERT("dhcp_option_trailer: dhcp->options_out_len < DHCP_OPTIONS_LEN\n", dhcp->options_out_len < DHCP_OPTIONS_LEN); dhcp->msg_out->options[dhcp->options_out_len++] = DHCP_OPTION_END; /* packet is too small, or not 4 byte aligned? */ while (((dhcp->options_out_len < DHCP_MIN_OPTIONS_LEN) || (dhcp->options_out_len & 3)) && 802be90: 8b03 ldrh r3, [r0, #24] 802be92: 2b43 cmp r3, #67 ; 0x43 802be94: d9f6 bls.n 802be84 802be96: 4770 bx lr 0802be98 : * @param dhcp dhcp control struct * @param message_type message type of the request */ static err_t dhcp_create_msg(struct netif *netif, struct dhcp *dhcp, u8_t message_type) { 802be98: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802be9c: 460c mov r4, r1 802be9e: 4617 mov r7, r2 if (!xid_initialised) { xid = DHCP_GLOBAL_XID; xid_initialised = !xid_initialised; } #endif LWIP_ERROR("dhcp_create_msg: netif != NULL", (netif != NULL), return ERR_ARG;); 802bea0: 4606 mov r6, r0 802bea2: 2800 cmp r0, #0 802bea4: f000 808e beq.w 802bfc4 LWIP_ERROR("dhcp_create_msg: dhcp != NULL", (dhcp != NULL), return ERR_VAL;); 802bea8: 2900 cmp r1, #0 802beaa: f000 808d beq.w 802bfc8 LWIP_ASSERT("dhcp_create_msg: dhcp->p_out == NULL", dhcp->p_out == NULL); LWIP_ASSERT("dhcp_create_msg: dhcp->msg_out == NULL", dhcp->msg_out == NULL); dhcp->p_out = pbuf_alloc(PBUF_TRANSPORT, sizeof(struct dhcp_msg), PBUF_RAM); 802beae: 2000 movs r0, #0 802beb0: f44f 719a mov.w r1, #308 ; 0x134 802beb4: 4602 mov r2, r0 802beb6: f001 f908 bl 802d0ca 802beba: 6120 str r0, [r4, #16] if (dhcp->p_out == NULL) { 802bebc: 2800 cmp r0, #0 802bebe: f000 8085 beq.w 802bfcc } LWIP_ASSERT("dhcp_create_msg: check that first pbuf can hold struct dhcp_msg", (dhcp->p_out->len >= sizeof(struct dhcp_msg))); /* reuse transaction identifier in retransmissions */ if (dhcp->tries == 0) { 802bec2: 7b62 ldrb r2, [r4, #13] 802bec4: 4b43 ldr r3, [pc, #268] ; (802bfd4 ) 802bec6: b912 cbnz r2, 802bece #if DHCP_CREATE_RAND_XID && defined(LWIP_RAND) xid = LWIP_RAND(); #else /* DHCP_CREATE_RAND_XID && defined(LWIP_RAND) */ xid++; 802bec8: 681a ldr r2, [r3, #0] 802beca: 3201 adds r2, #1 802becc: 601a str r2, [r3, #0] #endif /* DHCP_CREATE_RAND_XID && defined(LWIP_RAND) */ } dhcp->xid = xid; 802bece: 681b ldr r3, [r3, #0] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("transaction id xid(%"X32_F")\n", xid)); dhcp->msg_out = (struct dhcp_msg *)dhcp->p_out->payload; 802bed0: 6842 ldr r2, [r0, #4] xid = LWIP_RAND(); #else /* DHCP_CREATE_RAND_XID && defined(LWIP_RAND) */ xid++; #endif /* DHCP_CREATE_RAND_XID && defined(LWIP_RAND) */ } dhcp->xid = xid; 802bed2: 6023 str r3, [r4, #0] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("transaction id xid(%"X32_F")\n", xid)); dhcp->msg_out = (struct dhcp_msg *)dhcp->p_out->payload; dhcp->msg_out->op = DHCP_BOOTREQUEST; 802bed4: 2301 movs r3, #1 } dhcp->xid = xid; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("transaction id xid(%"X32_F")\n", xid)); dhcp->msg_out = (struct dhcp_msg *)dhcp->p_out->payload; 802bed6: 6162 str r2, [r4, #20] dhcp->msg_out->op = DHCP_BOOTREQUEST; 802bed8: 7013 strb r3, [r2, #0] /* TODO: make link layer independent */ dhcp->msg_out->htype = DHCP_HTYPE_ETH; 802beda: 6962 ldr r2, [r4, #20] 802bedc: 7053 strb r3, [r2, #1] dhcp->msg_out->hlen = netif->hwaddr_len; 802bede: 6963 ldr r3, [r4, #20] 802bee0: f896 2026 ldrb.w r2, [r6, #38] ; 0x26 802bee4: 709a strb r2, [r3, #2] dhcp->msg_out->hops = 0; 802bee6: 6963 ldr r3, [r4, #20] 802bee8: 2500 movs r5, #0 802beea: 70dd strb r5, [r3, #3] dhcp->msg_out->xid = htonl(dhcp->xid); 802beec: 6820 ldr r0, [r4, #0] 802beee: f8d4 8014 ldr.w r8, [r4, #20] 802bef2: f7ff ff69 bl 802bdc8 802bef6: f8c8 0004 str.w r0, [r8, #4] dhcp->msg_out->secs = 0; 802befa: 6963 ldr r3, [r4, #20] /* we don't need the broadcast flag since we can receive unicast traffic before being fully configured! */ dhcp->msg_out->flags = 0; ip_addr_set_zero(&dhcp->msg_out->ciaddr); /* set ciaddr to netif->ip_addr based on message_type and state */ if ((message_type == DHCP_INFORM) || (message_type == DHCP_DECLINE) || 802befc: 2f08 cmp r7, #8 /* TODO: make link layer independent */ dhcp->msg_out->htype = DHCP_HTYPE_ETH; dhcp->msg_out->hlen = netif->hwaddr_len; dhcp->msg_out->hops = 0; dhcp->msg_out->xid = htonl(dhcp->xid); dhcp->msg_out->secs = 0; 802befe: 721d strb r5, [r3, #8] 802bf00: 725d strb r5, [r3, #9] /* we don't need the broadcast flag since we can receive unicast traffic before being fully configured! */ dhcp->msg_out->flags = 0; 802bf02: 729d strb r5, [r3, #10] 802bf04: 72dd strb r5, [r3, #11] ip_addr_set_zero(&dhcp->msg_out->ciaddr); 802bf06: 731d strb r5, [r3, #12] 802bf08: 735d strb r5, [r3, #13] 802bf0a: 739d strb r5, [r3, #14] 802bf0c: 73dd strb r5, [r3, #15] /* set ciaddr to netif->ip_addr based on message_type and state */ if ((message_type == DHCP_INFORM) || (message_type == DHCP_DECLINE) || 802bf0e: d007 beq.n 802bf20 802bf10: 2f04 cmp r7, #4 802bf12: d005 beq.n 802bf20 802bf14: 2f03 cmp r7, #3 802bf16: d105 bne.n 802bf24 ((message_type == DHCP_REQUEST) && /* DHCP_BOUND not used for sending! */ ((dhcp->state==DHCP_RENEWING) || dhcp->state==DHCP_REBINDING))) { 802bf18: 7b22 ldrb r2, [r4, #12] before being fully configured! */ dhcp->msg_out->flags = 0; ip_addr_set_zero(&dhcp->msg_out->ciaddr); /* set ciaddr to netif->ip_addr based on message_type and state */ if ((message_type == DHCP_INFORM) || (message_type == DHCP_DECLINE) || ((message_type == DHCP_REQUEST) && /* DHCP_BOUND not used for sending! */ 802bf1a: 3a04 subs r2, #4 802bf1c: 2a01 cmp r2, #1 802bf1e: d801 bhi.n 802bf24 ((dhcp->state==DHCP_RENEWING) || dhcp->state==DHCP_REBINDING))) { ip_addr_copy(dhcp->msg_out->ciaddr, netif->ip_addr); 802bf20: 6872 ldr r2, [r6, #4] 802bf22: 60da str r2, [r3, #12] } ip_addr_set_zero(&dhcp->msg_out->yiaddr); 802bf24: 2500 movs r5, #0 802bf26: 741d strb r5, [r3, #16] 802bf28: 745d strb r5, [r3, #17] 802bf2a: 749d strb r5, [r3, #18] 802bf2c: 74dd strb r5, [r3, #19] ip_addr_set_zero(&dhcp->msg_out->siaddr); 802bf2e: 751d strb r5, [r3, #20] 802bf30: 755d strb r5, [r3, #21] 802bf32: 759d strb r5, [r3, #22] 802bf34: 75dd strb r5, [r3, #23] ip_addr_set_zero(&dhcp->msg_out->giaddr); 802bf36: 761d strb r5, [r3, #24] 802bf38: 765d strb r5, [r3, #25] 802bf3a: 769d strb r5, [r3, #26] 802bf3c: 76dd strb r5, [r3, #27] for (i = 0; i < DHCP_CHADDR_LEN; i++) { /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; 802bf3e: f896 1026 ldrb.w r1, [r6, #38] ; 0x26 802bf42: 6962 ldr r2, [r4, #20] 802bf44: b2ab uxth r3, r5 802bf46: 4299 cmp r1, r3 * @param netif the netif under DHCP control * @param dhcp dhcp control struct * @param message_type message type of the request */ static err_t dhcp_create_msg(struct netif *netif, struct dhcp *dhcp, u8_t message_type) 802bf48: bf88 it hi 802bf4a: 1973 addhi r3, r6, r5 ip_addr_set_zero(&dhcp->msg_out->yiaddr); ip_addr_set_zero(&dhcp->msg_out->siaddr); ip_addr_set_zero(&dhcp->msg_out->giaddr); for (i = 0; i < DHCP_CHADDR_LEN; i++) { /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; 802bf4c: 442a add r2, r5 802bf4e: bf8c ite hi 802bf50: f893 3027 ldrbhi.w r3, [r3, #39] ; 0x27 802bf54: 2300 movls r3, #0 802bf56: 3501 adds r5, #1 ip_addr_copy(dhcp->msg_out->ciaddr, netif->ip_addr); } ip_addr_set_zero(&dhcp->msg_out->yiaddr); ip_addr_set_zero(&dhcp->msg_out->siaddr); ip_addr_set_zero(&dhcp->msg_out->giaddr); for (i = 0; i < DHCP_CHADDR_LEN; i++) { 802bf58: 2d10 cmp r5, #16 /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; 802bf5a: 7713 strb r3, [r2, #28] ip_addr_copy(dhcp->msg_out->ciaddr, netif->ip_addr); } ip_addr_set_zero(&dhcp->msg_out->yiaddr); ip_addr_set_zero(&dhcp->msg_out->siaddr); ip_addr_set_zero(&dhcp->msg_out->giaddr); for (i = 0; i < DHCP_CHADDR_LEN; i++) { 802bf5c: d1ef bne.n 802bf3e 802bf5e: 2300 movs r3, #0 /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; } for (i = 0; i < DHCP_SNAME_LEN; i++) { dhcp->msg_out->sname[i] = 0; 802bf60: 4619 mov r1, r3 802bf62: 6962 ldr r2, [r4, #20] 802bf64: 18d2 adds r2, r2, r3 802bf66: 3301 adds r3, #1 ip_addr_set_zero(&dhcp->msg_out->giaddr); for (i = 0; i < DHCP_CHADDR_LEN; i++) { /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; } for (i = 0; i < DHCP_SNAME_LEN; i++) { 802bf68: 2b40 cmp r3, #64 ; 0x40 dhcp->msg_out->sname[i] = 0; 802bf6a: f882 102c strb.w r1, [r2, #44] ; 0x2c ip_addr_set_zero(&dhcp->msg_out->giaddr); for (i = 0; i < DHCP_CHADDR_LEN; i++) { /* copy netif hardware address, pad with zeroes */ dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; } for (i = 0; i < DHCP_SNAME_LEN; i++) { 802bf6e: d1f8 bne.n 802bf62 802bf70: 2200 movs r2, #0 dhcp->msg_out->sname[i] = 0; } for (i = 0; i < DHCP_FILE_LEN; i++) { dhcp->msg_out->file[i] = 0; 802bf72: 4610 mov r0, r2 802bf74: 6963 ldr r3, [r4, #20] 802bf76: 1899 adds r1, r3, r2 802bf78: 3201 adds r2, #1 802bf7a: 2300 movs r3, #0 dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; } for (i = 0; i < DHCP_SNAME_LEN; i++) { dhcp->msg_out->sname[i] = 0; } for (i = 0; i < DHCP_FILE_LEN; i++) { 802bf7c: 2a80 cmp r2, #128 ; 0x80 dhcp->msg_out->file[i] = 0; 802bf7e: f881 006c strb.w r0, [r1, #108] ; 0x6c dhcp->msg_out->chaddr[i] = (i < netif->hwaddr_len) ? netif->hwaddr[i] : 0/* pad byte*/; } for (i = 0; i < DHCP_SNAME_LEN; i++) { dhcp->msg_out->sname[i] = 0; } for (i = 0; i < DHCP_FILE_LEN; i++) { 802bf82: d1f7 bne.n 802bf74 dhcp->msg_out->file[i] = 0; } dhcp->msg_out->cookie = PP_HTONL(DHCP_MAGIC_COOKIE); 802bf84: 6962 ldr r2, [r4, #20] 802bf86: f06f 007d mvn.w r0, #125 ; 0x7d 802bf8a: 2163 movs r1, #99 ; 0x63 802bf8c: f882 00ed strb.w r0, [r2, #237] ; 0xed 802bf90: 2053 movs r0, #83 ; 0x53 802bf92: f882 10ec strb.w r1, [r2, #236] ; 0xec 802bf96: f882 00ee strb.w r0, [r2, #238] ; 0xee 802bf9a: f882 10ef strb.w r1, [r2, #239] ; 0xef dhcp->options_out_len = 0; 802bf9e: 8323 strh r3, [r4, #24] /* fill options field with an incrementing array (for debugging purposes) */ for (i = 0; i < DHCP_OPTIONS_LEN; i++) { dhcp->msg_out->options[i] = (u8_t)i; /* for debugging only, no matter if truncated */ 802bfa0: 6962 ldr r2, [r4, #20] 802bfa2: 18d2 adds r2, r2, r3 802bfa4: f882 30f0 strb.w r3, [r2, #240] ; 0xf0 802bfa8: 3301 adds r3, #1 dhcp->msg_out->file[i] = 0; } dhcp->msg_out->cookie = PP_HTONL(DHCP_MAGIC_COOKIE); dhcp->options_out_len = 0; /* fill options field with an incrementing array (for debugging purposes) */ for (i = 0; i < DHCP_OPTIONS_LEN; i++) { 802bfaa: 2b44 cmp r3, #68 ; 0x44 802bfac: d1f8 bne.n 802bfa0 dhcp->msg_out->options[i] = (u8_t)i; /* for debugging only, no matter if truncated */ } /* Add option MESSAGE_TYPE */ dhcp_option(dhcp, DHCP_OPTION_MESSAGE_TYPE, DHCP_OPTION_MESSAGE_TYPE_LEN); 802bfae: 4620 mov r0, r4 802bfb0: 2135 movs r1, #53 ; 0x35 802bfb2: 2201 movs r2, #1 802bfb4: f7ff ff14 bl 802bde0 dhcp_option_byte(dhcp, message_type); 802bfb8: 4620 mov r0, r4 802bfba: 4639 mov r1, r7 802bfbc: f7ff ff1f bl 802bdfe return ERR_OK; 802bfc0: 2000 movs r0, #0 802bfc2: e004 b.n 802bfce if (!xid_initialised) { xid = DHCP_GLOBAL_XID; xid_initialised = !xid_initialised; } #endif LWIP_ERROR("dhcp_create_msg: netif != NULL", (netif != NULL), return ERR_ARG;); 802bfc4: 20f2 movs r0, #242 ; 0xf2 802bfc6: e002 b.n 802bfce LWIP_ERROR("dhcp_create_msg: dhcp != NULL", (dhcp != NULL), return ERR_VAL;); 802bfc8: 20fa movs r0, #250 ; 0xfa 802bfca: e000 b.n 802bfce LWIP_ASSERT("dhcp_create_msg: dhcp->msg_out == NULL", dhcp->msg_out == NULL); dhcp->p_out = pbuf_alloc(PBUF_TRANSPORT, sizeof(struct dhcp_msg), PBUF_RAM); if (dhcp->p_out == NULL) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_create_msg(): could not allocate pbuf\n")); return ERR_MEM; 802bfcc: 20ff movs r0, #255 ; 0xff } /* Add option MESSAGE_TYPE */ dhcp_option(dhcp, DHCP_OPTION_MESSAGE_TYPE, DHCP_OPTION_MESSAGE_TYPE_LEN); dhcp_option_byte(dhcp, message_type); return ERR_OK; } 802bfce: b240 sxtb r0, r0 802bfd0: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802bfd4: 200015e4 .word 0x200015e4 0802bfd8 : * * @param dhcp the dhcp struct to free the request from */ static void dhcp_delete_msg(struct dhcp *dhcp) { 802bfd8: b510 push {r4, lr} LWIP_ERROR("dhcp_delete_msg: dhcp != NULL", (dhcp != NULL), return;); 802bfda: 4604 mov r4, r0 802bfdc: b130 cbz r0, 802bfec LWIP_ASSERT("dhcp_delete_msg: dhcp->p_out != NULL", dhcp->p_out != NULL); LWIP_ASSERT("dhcp_delete_msg: dhcp->msg_out != NULL", dhcp->msg_out != NULL); if (dhcp->p_out != NULL) { 802bfde: 6900 ldr r0, [r0, #16] 802bfe0: b108 cbz r0, 802bfe6 pbuf_free(dhcp->p_out); 802bfe2: f001 f825 bl 802d030 } dhcp->p_out = NULL; 802bfe6: 2300 movs r3, #0 802bfe8: 6123 str r3, [r4, #16] dhcp->msg_out = NULL; 802bfea: 6163 str r3, [r4, #20] 802bfec: bd10 pop {r4, pc} 802bfee: 0000 movs r0, r0 0802bff0 : * * @param netif the netif under DHCP control */ static err_t dhcp_discover(struct netif *netif) { 802bff0: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802bff2: 6a04 ldr r4, [r0, #32] err_t result = ERR_OK; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover()\n")); ip_addr_set_any(&dhcp->offered_ip_addr); 802bff4: 2300 movs r3, #0 * * @param netif the netif under DHCP control */ static err_t dhcp_discover(struct netif *netif) { 802bff6: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result = ERR_OK; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover()\n")); ip_addr_set_any(&dhcp->offered_ip_addr); 802bff8: 6263 str r3, [r4, #36] ; 0x24 dhcp_set_state(dhcp, DHCP_SELECTING); 802bffa: 4620 mov r0, r4 802bffc: 2106 movs r1, #6 802bffe: f7ff fee7 bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_DISCOVER); 802c002: 4628 mov r0, r5 802c004: 4621 mov r1, r4 802c006: 2201 movs r2, #1 802c008: f7ff ff46 bl 802be98 if (result == ERR_OK) { 802c00c: 4606 mov r6, r0 802c00e: 2800 cmp r0, #0 802c010: d130 bne.n 802c074 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover: making request\n")); dhcp_option(dhcp, DHCP_OPTION_MAX_MSG_SIZE, DHCP_OPTION_MAX_MSG_SIZE_LEN); 802c012: 2202 movs r2, #2 802c014: 4620 mov r0, r4 802c016: 2139 movs r1, #57 ; 0x39 802c018: f7ff fee2 bl 802bde0 dhcp_option_short(dhcp, DHCP_MAX_MSG_LEN(netif)); 802c01c: 4620 mov r0, r4 802c01e: 8ca9 ldrh r1, [r5, #36] ; 0x24 802c020: f7ff fef5 bl 802be0e dhcp_option(dhcp, DHCP_OPTION_PARAMETER_REQUEST_LIST, 4/*num options*/); 802c024: 2204 movs r2, #4 802c026: 4620 mov r0, r4 802c028: 2137 movs r1, #55 ; 0x37 802c02a: f7ff fed9 bl 802bde0 dhcp_option_byte(dhcp, DHCP_OPTION_SUBNET_MASK); 802c02e: 4620 mov r0, r4 802c030: 2101 movs r1, #1 802c032: f7ff fee4 bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_ROUTER); 802c036: 4620 mov r0, r4 802c038: 2103 movs r1, #3 802c03a: f7ff fee0 bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_BROADCAST); 802c03e: 4620 mov r0, r4 802c040: 211c movs r1, #28 802c042: f7ff fedc bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_DNS_SERVER); 802c046: 2106 movs r1, #6 802c048: 4620 mov r0, r4 802c04a: f7ff fed8 bl 802bdfe dhcp_option_trailer(dhcp); 802c04e: 4620 mov r0, r4 802c050: f7ff ff0d bl 802be6e LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover: realloc()ing\n")); pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c054: 8b21 ldrh r1, [r4, #24] 802c056: 6920 ldr r0, [r4, #16] 802c058: 31f0 adds r1, #240 ; 0xf0 802c05a: b289 uxth r1, r1 802c05c: f001 f80f bl 802d07e LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover: sendto(DISCOVER, IP_ADDR_BROADCAST, DHCP_SERVER_PORT)\n")); udp_sendto_if(dhcp->pcb, dhcp->p_out, IP_ADDR_BROADCAST, DHCP_SERVER_PORT, netif); 802c060: 9500 str r5, [sp, #0] 802c062: 6860 ldr r0, [r4, #4] 802c064: 6921 ldr r1, [r4, #16] 802c066: 4a0f ldr r2, [pc, #60] ; (802c0a4 ) 802c068: 2343 movs r3, #67 ; 0x43 802c06a: f003 fc81 bl 802f970 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_discover: deleting()ing\n")); dhcp_delete_msg(dhcp); 802c06e: 4620 mov r0, r4 802c070: f7ff ffb2 bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_discover: SELECTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_discover: could not allocate DHCP request\n")); } dhcp->tries++; 802c074: 7b63 ldrb r3, [r4, #13] 802c076: 3301 adds r3, #1 802c078: b2db uxtb r3, r3 if(dhcp->tries >= LWIP_DHCP_AUTOIP_COOP_TRIES && dhcp->autoip_coop_state == DHCP_AUTOIP_COOP_STATE_OFF) { dhcp->autoip_coop_state = DHCP_AUTOIP_COOP_STATE_ON; autoip_start(netif); } #endif /* LWIP_DHCP_AUTOIP_COOP */ msecs = (dhcp->tries < 6 ? 1 << dhcp->tries : 60) * 1000; 802c07a: 2b05 cmp r3, #5 802c07c: bf98 it ls 802c07e: f44f 727a movls.w r2, #1000 ; 0x3e8 dhcp_delete_msg(dhcp); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_discover: SELECTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_discover: could not allocate DHCP request\n")); } dhcp->tries++; 802c082: 7363 strb r3, [r4, #13] if(dhcp->tries >= LWIP_DHCP_AUTOIP_COOP_TRIES && dhcp->autoip_coop_state == DHCP_AUTOIP_COOP_STATE_OFF) { dhcp->autoip_coop_state = DHCP_AUTOIP_COOP_STATE_ON; autoip_start(netif); } #endif /* LWIP_DHCP_AUTOIP_COOP */ msecs = (dhcp->tries < 6 ? 1 << dhcp->tries : 60) * 1000; 802c084: bf9a itte ls 802c086: fa02 f303 lslls.w r3, r2, r3 802c08a: b29b uxthls r3, r3 802c08c: f64e 2360 movwhi r3, #60000 ; 0xea60 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c090: f44f 72fa mov.w r2, #500 ; 0x1f4 802c094: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c098: fb93 f3f2 sdiv r3, r3, r2 802c09c: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_discover(): set request timeout %"U16_F" msecs\n", msecs)); return result; } 802c09e: 4630 mov r0, r6 802c0a0: bd7c pop {r2, r3, r4, r5, r6, pc} 802c0a2: bf00 nop 802c0a4: 0803fe84 .word 0x0803fe84 0802c0a8 : * * @param netif network interface which must rebind with a DHCP server */ static err_t dhcp_rebind(struct netif *netif) { 802c0a8: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802c0aa: 6a04 ldr r4, [r0, #32] * * @param netif network interface which must rebind with a DHCP server */ static err_t dhcp_rebind(struct netif *netif) { 802c0ac: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_rebind()\n")); dhcp_set_state(dhcp, DHCP_REBINDING); 802c0ae: 2104 movs r1, #4 802c0b0: 4620 mov r0, r4 802c0b2: f7ff fe8d bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_REQUEST); 802c0b6: 4628 mov r0, r5 802c0b8: 4621 mov r1, r4 802c0ba: 2203 movs r2, #3 802c0bc: f7ff feec bl 802be98 if (result == ERR_OK) { 802c0c0: 4606 mov r6, r0 802c0c2: b9d8 cbnz r0, 802c0fc dhcp_option(dhcp, DHCP_OPTION_MAX_MSG_SIZE, DHCP_OPTION_MAX_MSG_SIZE_LEN); 802c0c4: 2202 movs r2, #2 802c0c6: 4620 mov r0, r4 802c0c8: 2139 movs r1, #57 ; 0x39 802c0ca: f7ff fe89 bl 802bde0 dhcp_option_short(dhcp, DHCP_MAX_MSG_LEN(netif)); 802c0ce: 8ca9 ldrh r1, [r5, #36] ; 0x24 802c0d0: 4620 mov r0, r4 802c0d2: f7ff fe9c bl 802be0e dhcp_option(dhcp, DHCP_OPTION_SERVER_ID, 4); dhcp_option_long(dhcp, ntohl(dhcp->server_ip_addr.addr)); #endif dhcp_option_trailer(dhcp); 802c0d6: 4620 mov r0, r4 802c0d8: f7ff fec9 bl 802be6e pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c0dc: 8b21 ldrh r1, [r4, #24] 802c0de: 6920 ldr r0, [r4, #16] 802c0e0: 31f0 adds r1, #240 ; 0xf0 802c0e2: b289 uxth r1, r1 802c0e4: f000 ffcb bl 802d07e /* broadcast to server */ udp_sendto_if(dhcp->pcb, dhcp->p_out, IP_ADDR_BROADCAST, DHCP_SERVER_PORT, netif); 802c0e8: 9500 str r5, [sp, #0] 802c0ea: 6860 ldr r0, [r4, #4] 802c0ec: 6921 ldr r1, [r4, #16] 802c0ee: 4a0e ldr r2, [pc, #56] ; (802c128 ) 802c0f0: 2343 movs r3, #67 ; 0x43 802c0f2: f003 fc3d bl 802f970 dhcp_delete_msg(dhcp); 802c0f6: 4620 mov r0, r4 802c0f8: f7ff ff6e bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_rebind: REBINDING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_rebind: could not allocate DHCP request\n")); } dhcp->tries++; 802c0fc: 7b63 ldrb r3, [r4, #13] 802c0fe: 3301 adds r3, #1 802c100: b2db uxtb r3, r3 msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c102: 2b09 cmp r3, #9 dhcp_delete_msg(dhcp); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_rebind: REBINDING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_rebind: could not allocate DHCP request\n")); } dhcp->tries++; 802c104: 7363 strb r3, [r4, #13] msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c106: d804 bhi.n 802c112 802c108: f44f 727a mov.w r2, #1000 ; 0x3e8 802c10c: 4353 muls r3, r2 802c10e: b29b uxth r3, r3 802c110: e001 b.n 802c116 802c112: f242 7310 movw r3, #10000 ; 0x2710 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c116: f44f 72fa mov.w r2, #500 ; 0x1f4 802c11a: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c11e: fb93 f3f2 sdiv r3, r3, r2 802c122: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_rebind(): set request timeout %"U16_F" msecs\n", msecs)); return result; } 802c124: 4630 mov r0, r6 802c126: bd7c pop {r2, r3, r4, r5, r6, pc} 802c128: 0803fe84 .word 0x0803fe84 0802c12c : * * @param netif network interface which must reboot */ static err_t dhcp_reboot(struct netif *netif) { 802c12c: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802c12e: 6a04 ldr r4, [r0, #32] * * @param netif network interface which must reboot */ static err_t dhcp_reboot(struct netif *netif) { 802c130: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_reboot()\n")); dhcp_set_state(dhcp, DHCP_REBOOTING); 802c132: 2103 movs r1, #3 802c134: 4620 mov r0, r4 802c136: f7ff fe4b bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_REQUEST); 802c13a: 4628 mov r0, r5 802c13c: 4621 mov r1, r4 802c13e: 2203 movs r2, #3 802c140: f7ff feaa bl 802be98 if (result == ERR_OK) { 802c144: 4606 mov r6, r0 802c146: bb40 cbnz r0, 802c19a dhcp_option(dhcp, DHCP_OPTION_MAX_MSG_SIZE, DHCP_OPTION_MAX_MSG_SIZE_LEN); 802c148: 2202 movs r2, #2 802c14a: 4620 mov r0, r4 802c14c: 2139 movs r1, #57 ; 0x39 802c14e: f7ff fe47 bl 802bde0 dhcp_option_short(dhcp, 576); 802c152: 4620 mov r0, r4 802c154: f44f 7110 mov.w r1, #576 ; 0x240 802c158: f7ff fe59 bl 802be0e dhcp_option(dhcp, DHCP_OPTION_REQUESTED_IP, 4); 802c15c: 2204 movs r2, #4 802c15e: 2132 movs r1, #50 ; 0x32 802c160: 4620 mov r0, r4 802c162: f7ff fe3d bl 802bde0 dhcp_option_long(dhcp, ntohl(ip4_addr_get_u32(&dhcp->offered_ip_addr))); 802c166: 6a60 ldr r0, [r4, #36] ; 0x24 802c168: f7ff fe30 bl 802bdcc 802c16c: 4601 mov r1, r0 802c16e: 4620 mov r0, r4 802c170: f7ff fe5d bl 802be2e dhcp_option_trailer(dhcp); 802c174: 4620 mov r0, r4 802c176: f7ff fe7a bl 802be6e pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c17a: 8b21 ldrh r1, [r4, #24] 802c17c: 6920 ldr r0, [r4, #16] 802c17e: 31f0 adds r1, #240 ; 0xf0 802c180: b289 uxth r1, r1 802c182: f000 ff7c bl 802d07e /* broadcast to server */ udp_sendto_if(dhcp->pcb, dhcp->p_out, IP_ADDR_BROADCAST, DHCP_SERVER_PORT, netif); 802c186: 9500 str r5, [sp, #0] 802c188: 6860 ldr r0, [r4, #4] 802c18a: 6921 ldr r1, [r4, #16] 802c18c: 4a0e ldr r2, [pc, #56] ; (802c1c8 ) 802c18e: 2343 movs r3, #67 ; 0x43 802c190: f003 fbee bl 802f970 dhcp_delete_msg(dhcp); 802c194: 4620 mov r0, r4 802c196: f7ff ff1f bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_reboot: REBOOTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_reboot: could not allocate DHCP request\n")); } dhcp->tries++; 802c19a: 7b63 ldrb r3, [r4, #13] 802c19c: 3301 adds r3, #1 802c19e: b2db uxtb r3, r3 msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c1a0: 2b09 cmp r3, #9 dhcp_delete_msg(dhcp); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_reboot: REBOOTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_reboot: could not allocate DHCP request\n")); } dhcp->tries++; 802c1a2: 7363 strb r3, [r4, #13] msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c1a4: d804 bhi.n 802c1b0 802c1a6: f44f 727a mov.w r2, #1000 ; 0x3e8 802c1aa: 4353 muls r3, r2 802c1ac: b29b uxth r3, r3 802c1ae: e001 b.n 802c1b4 802c1b0: f242 7310 movw r3, #10000 ; 0x2710 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c1b4: f44f 72fa mov.w r2, #500 ; 0x1f4 802c1b8: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c1bc: fb93 f3f2 sdiv r3, r3, r2 802c1c0: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_reboot(): set request timeout %"U16_F" msecs\n", msecs)); return result; } 802c1c2: 4630 mov r0, r6 802c1c4: bd7c pop {r2, r3, r4, r5, r6, pc} 802c1c6: bf00 nop 802c1c8: 0803fe84 .word 0x0803fe84 0802c1cc : * @param netif the netif under DHCP control * @return lwIP specific error (see error.h) */ static err_t dhcp_select(struct netif *netif) { 802c1cc: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802c1ce: 6a04 ldr r4, [r0, #32] * @param netif the netif under DHCP control * @return lwIP specific error (see error.h) */ static err_t dhcp_select(struct netif *netif) { 802c1d0: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_select(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); dhcp_set_state(dhcp, DHCP_REQUESTING); 802c1d2: 2101 movs r1, #1 802c1d4: 4620 mov r0, r4 802c1d6: f7ff fdfb bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_REQUEST); 802c1da: 4628 mov r0, r5 802c1dc: 4621 mov r1, r4 802c1de: 2203 movs r2, #3 802c1e0: f7ff fe5a bl 802be98 if (result == ERR_OK) { 802c1e4: 4606 mov r6, r0 802c1e6: 2800 cmp r0, #0 802c1e8: d148 bne.n 802c27c dhcp_option(dhcp, DHCP_OPTION_MAX_MSG_SIZE, DHCP_OPTION_MAX_MSG_SIZE_LEN); 802c1ea: 2202 movs r2, #2 802c1ec: 4620 mov r0, r4 802c1ee: 2139 movs r1, #57 ; 0x39 802c1f0: f7ff fdf6 bl 802bde0 dhcp_option_short(dhcp, DHCP_MAX_MSG_LEN(netif)); 802c1f4: 4620 mov r0, r4 802c1f6: 8ca9 ldrh r1, [r5, #36] ; 0x24 802c1f8: f7ff fe09 bl 802be0e /* MUST request the offered IP address */ dhcp_option(dhcp, DHCP_OPTION_REQUESTED_IP, 4); 802c1fc: 2204 movs r2, #4 802c1fe: 2132 movs r1, #50 ; 0x32 802c200: 4620 mov r0, r4 802c202: f7ff fded bl 802bde0 dhcp_option_long(dhcp, ntohl(ip4_addr_get_u32(&dhcp->offered_ip_addr))); 802c206: 6a60 ldr r0, [r4, #36] ; 0x24 802c208: f7ff fde0 bl 802bdcc 802c20c: 4601 mov r1, r0 802c20e: 4620 mov r0, r4 802c210: f7ff fe0d bl 802be2e dhcp_option(dhcp, DHCP_OPTION_SERVER_ID, 4); 802c214: 2204 movs r2, #4 802c216: 2136 movs r1, #54 ; 0x36 802c218: 4620 mov r0, r4 802c21a: f7ff fde1 bl 802bde0 dhcp_option_long(dhcp, ntohl(ip4_addr_get_u32(&dhcp->server_ip_addr))); 802c21e: 6a20 ldr r0, [r4, #32] 802c220: f7ff fdd4 bl 802bdcc 802c224: 4601 mov r1, r0 802c226: 4620 mov r0, r4 802c228: f7ff fe01 bl 802be2e dhcp_option(dhcp, DHCP_OPTION_PARAMETER_REQUEST_LIST, 4/*num options*/); 802c22c: 2204 movs r2, #4 802c22e: 4620 mov r0, r4 802c230: 2137 movs r1, #55 ; 0x37 802c232: f7ff fdd5 bl 802bde0 dhcp_option_byte(dhcp, DHCP_OPTION_SUBNET_MASK); 802c236: 4620 mov r0, r4 802c238: 2101 movs r1, #1 802c23a: f7ff fde0 bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_ROUTER); 802c23e: 4620 mov r0, r4 802c240: 2103 movs r1, #3 802c242: f7ff fddc bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_BROADCAST); 802c246: 4620 mov r0, r4 802c248: 211c movs r1, #28 802c24a: f7ff fdd8 bl 802bdfe dhcp_option_byte(dhcp, DHCP_OPTION_DNS_SERVER); 802c24e: 2106 movs r1, #6 802c250: 4620 mov r0, r4 802c252: f7ff fdd4 bl 802bdfe #if LWIP_NETIF_HOSTNAME dhcp_option_hostname(dhcp, netif); #endif /* LWIP_NETIF_HOSTNAME */ dhcp_option_trailer(dhcp); 802c256: 4620 mov r0, r4 802c258: f7ff fe09 bl 802be6e /* shrink the pbuf to the actual content length */ pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c25c: 8b21 ldrh r1, [r4, #24] 802c25e: 6920 ldr r0, [r4, #16] 802c260: 31f0 adds r1, #240 ; 0xf0 802c262: b289 uxth r1, r1 802c264: f000 ff0b bl 802d07e /* send broadcast to any DHCP server */ udp_sendto_if(dhcp->pcb, dhcp->p_out, IP_ADDR_BROADCAST, DHCP_SERVER_PORT, netif); 802c268: 9500 str r5, [sp, #0] 802c26a: 6860 ldr r0, [r4, #4] 802c26c: 6921 ldr r1, [r4, #16] 802c26e: 4a0f ldr r2, [pc, #60] ; (802c2ac ) 802c270: 2343 movs r3, #67 ; 0x43 802c272: f003 fb7d bl 802f970 dhcp_delete_msg(dhcp); 802c276: 4620 mov r0, r4 802c278: f7ff feae bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_select: REQUESTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("dhcp_select: could not allocate DHCP request\n")); } dhcp->tries++; 802c27c: 7b63 ldrb r3, [r4, #13] 802c27e: 3301 adds r3, #1 802c280: b2db uxtb r3, r3 msecs = (dhcp->tries < 6 ? 1 << dhcp->tries : 60) * 1000; 802c282: 2b05 cmp r3, #5 802c284: bf98 it ls 802c286: f44f 727a movls.w r2, #1000 ; 0x3e8 dhcp_delete_msg(dhcp); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_select: REQUESTING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("dhcp_select: could not allocate DHCP request\n")); } dhcp->tries++; 802c28a: 7363 strb r3, [r4, #13] msecs = (dhcp->tries < 6 ? 1 << dhcp->tries : 60) * 1000; 802c28c: bf9a itte ls 802c28e: fa02 f303 lslls.w r3, r2, r3 802c292: b29b uxthls r3, r3 802c294: f64e 2360 movwhi r3, #60000 ; 0xea60 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c298: f44f 72fa mov.w r2, #500 ; 0x1f4 802c29c: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c2a0: fb93 f3f2 sdiv r3, r3, r2 802c2a4: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_select(): set request timeout %"U16_F" msecs\n", msecs)); return result; } 802c2a6: 4630 mov r0, r6 802c2a8: bd7c pop {r2, r3, r4, r5, r6, pc} 802c2aa: bf00 nop 802c2ac: 0803fe84 .word 0x0803fe84 0802c2b0 : * * @param netif the netif under DHCP control */ static void dhcp_check(struct netif *netif) { 802c2b0: b538 push {r3, r4, r5, lr} struct dhcp *dhcp = netif->dhcp; 802c2b2: 6a04 ldr r4, [r0, #32] * * @param netif the netif under DHCP control */ static void dhcp_check(struct netif *netif) { 802c2b4: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_check(netif=%p) %c%c\n", (void *)netif, (s16_t)netif->name[0], (s16_t)netif->name[1])); dhcp_set_state(dhcp, DHCP_CHECKING); 802c2b6: 2108 movs r1, #8 802c2b8: 4620 mov r0, r4 802c2ba: f7ff fd89 bl 802bdd0 /* create an ARP query for the offered IP address, expecting that no host responds, as the IP address should not be in use. */ result = etharp_query(netif, &dhcp->offered_ip_addr, NULL); 802c2be: 4628 mov r0, r5 802c2c0: f104 0124 add.w r1, r4, #36 ; 0x24 802c2c4: 2200 movs r2, #0 802c2c6: f007 ff41 bl 803414c if (result != ERR_OK) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("dhcp_check: could not perform ARP query\n")); } dhcp->tries++; 802c2ca: 7b63 ldrb r3, [r4, #13] 802c2cc: 3301 adds r3, #1 802c2ce: 7363 strb r3, [r4, #13] msecs = 500; dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c2d0: 2301 movs r3, #1 802c2d2: 8363 strh r3, [r4, #26] 802c2d4: bd38 pop {r3, r4, r5, pc} 0802c2d6 : * * @param netif network interface to bind to the offered address */ static void dhcp_bind(struct netif *netif) { 802c2d6: b537 push {r0, r1, r2, r4, r5, lr} u32_t timeout; struct dhcp *dhcp; ip_addr_t sn_mask, gw_addr; LWIP_ERROR("dhcp_bind: netif != NULL", (netif != NULL), return;); 802c2d8: 4605 mov r5, r0 802c2da: 2800 cmp r0, #0 802c2dc: d059 beq.n 802c392 dhcp = netif->dhcp; 802c2de: 6a04 ldr r4, [r0, #32] LWIP_ERROR("dhcp_bind: dhcp != NULL", (dhcp != NULL), return;); 802c2e0: 2c00 cmp r4, #0 802c2e2: d056 beq.n 802c392 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_bind(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* temporary DHCP lease? */ if (dhcp->offered_t1_renew != 0xffffffffUL) { 802c2e4: 6b63 ldr r3, [r4, #52] ; 0x34 802c2e6: 1c58 adds r0, r3, #1 802c2e8: d00d beq.n 802c306 /* set renewal period timer */ LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_bind(): t1 renewal timer %"U32_F" secs\n", dhcp->offered_t1_renew)); timeout = (dhcp->offered_t1_renew + DHCP_COARSE_TIMER_SECS / 2) / DHCP_COARSE_TIMER_SECS; 802c2ea: 223c movs r2, #60 ; 0x3c 802c2ec: 331e adds r3, #30 802c2ee: fbb3 f3f2 udiv r3, r3, r2 if(timeout > 0xffff) { timeout = 0xffff; } dhcp->t1_timeout = (u16_t)timeout; 802c2f2: f64f 72ff movw r2, #65535 ; 0xffff 802c2f6: 4293 cmp r3, r2 802c2f8: bf28 it cs 802c2fa: 4613 movcs r3, r2 802c2fc: b29b uxth r3, r3 802c2fe: 83a3 strh r3, [r4, #28] if (dhcp->t1_timeout == 0) { 802c300: b90b cbnz r3, 802c306 dhcp->t1_timeout = 1; 802c302: 2301 movs r3, #1 802c304: 83a3 strh r3, [r4, #28] } LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_bind(): set request timeout %"U32_F" msecs\n", dhcp->offered_t1_renew*1000)); } /* set renewal period timer */ if (dhcp->offered_t2_rebind != 0xffffffffUL) { 802c306: 6ba3 ldr r3, [r4, #56] ; 0x38 802c308: 1c59 adds r1, r3, #1 802c30a: d00d beq.n 802c328 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_bind(): t2 rebind timer %"U32_F" secs\n", dhcp->offered_t2_rebind)); timeout = (dhcp->offered_t2_rebind + DHCP_COARSE_TIMER_SECS / 2) / DHCP_COARSE_TIMER_SECS; 802c30c: 223c movs r2, #60 ; 0x3c 802c30e: 331e adds r3, #30 802c310: fbb3 f3f2 udiv r3, r3, r2 if(timeout > 0xffff) { timeout = 0xffff; } dhcp->t2_timeout = (u16_t)timeout; 802c314: f64f 72ff movw r2, #65535 ; 0xffff 802c318: 4293 cmp r3, r2 802c31a: bf28 it cs 802c31c: 4613 movcs r3, r2 802c31e: b29b uxth r3, r3 802c320: 83e3 strh r3, [r4, #30] if (dhcp->t2_timeout == 0) { 802c322: b90b cbnz r3, 802c328 dhcp->t2_timeout = 1; 802c324: 2301 movs r3, #1 802c326: 83e3 strh r3, [r4, #30] } LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_bind(): set request timeout %"U32_F" msecs\n", dhcp->offered_t2_rebind*1000)); } /* If we have sub 1 minute lease, t2 and t1 will kick in at the same time. */ if ((dhcp->t1_timeout >= dhcp->t2_timeout) && (dhcp->t2_timeout > 0)) { 802c328: 8be3 ldrh r3, [r4, #30] 802c32a: 8ba2 ldrh r2, [r4, #28] 802c32c: 429a cmp r2, r3 802c32e: d302 bcc.n 802c336 802c330: b10b cbz r3, 802c336 dhcp->t1_timeout = 0; 802c332: 2300 movs r3, #0 802c334: 83a3 strh r3, [r4, #28] } if (dhcp->subnet_mask_given) { 802c336: 7ba3 ldrb r3, [r4, #14] 802c338: b10b cbz r3, 802c33e /* copy offered network mask */ ip_addr_copy(sn_mask, dhcp->offered_sn_mask); 802c33a: 6aa3 ldr r3, [r4, #40] ; 0x28 802c33c: e00b b.n 802c356 } else { /* subnet mask not given, choose a safe subnet mask given the network class */ u8_t first_octet = ip4_addr1(&dhcp->offered_ip_addr); 802c33e: f894 3024 ldrb.w r3, [r4, #36] ; 0x24 if (first_octet <= 127) { 802c342: 061a lsls r2, r3, #24 802c344: d401 bmi.n 802c34a ip4_addr_set_u32(&sn_mask, PP_HTONL(0xff000000UL)); 802c346: 23ff movs r3, #255 ; 0xff 802c348: e005 b.n 802c356 } else if (first_octet >= 192) { 802c34a: 2bbf cmp r3, #191 ; 0xbf ip4_addr_set_u32(&sn_mask, PP_HTONL(0xffffff00UL)); 802c34c: bf8c ite hi 802c34e: f06f 437f mvnhi.w r3, #4278190080 ; 0xff000000 } else { ip4_addr_set_u32(&sn_mask, PP_HTONL(0xffff0000UL)); 802c352: f64f 73ff movwls r3, #65535 ; 0xffff 802c356: 9300 str r3, [sp, #0] } } ip_addr_copy(gw_addr, dhcp->offered_gw_addr); 802c358: 6ae3 ldr r3, [r4, #44] ; 0x2c 802c35a: 9301 str r3, [sp, #4] /* gateway address not given? */ if (ip_addr_isany(&gw_addr)) { 802c35c: b92b cbnz r3, 802c36a /* copy network address */ ip_addr_get_network(&gw_addr, &dhcp->offered_ip_addr, &sn_mask); 802c35e: 6a63 ldr r3, [r4, #36] ; 0x24 802c360: 9a00 ldr r2, [sp, #0] 802c362: 4013 ands r3, r2 /* use first host address on network as gateway */ ip4_addr_set_u32(&gw_addr, ip4_addr_get_u32(&gw_addr) | PP_HTONL(0x00000001UL)); 802c364: f043 7380 orr.w r3, r3, #16777216 ; 0x1000000 802c368: 9301 str r3, [sp, #4] } #endif /* LWIP_DHCP_AUTOIP_COOP */ LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_bind(): IP: 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->offered_ip_addr))); netif_set_ipaddr(netif, &dhcp->offered_ip_addr); 802c36a: 4628 mov r0, r5 802c36c: f104 0124 add.w r1, r4, #36 ; 0x24 802c370: f000 fd6a bl 802ce48 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_bind(): SN: 0x%08"X32_F"\n", ip4_addr_get_u32(&sn_mask))); netif_set_netmask(netif, &sn_mask); 802c374: 4628 mov r0, r5 802c376: 4669 mov r1, sp 802c378: f000 fda6 bl 802cec8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_bind(): GW: 0x%08"X32_F"\n", ip4_addr_get_u32(&gw_addr))); netif_set_gw(netif, &gw_addr); 802c37c: a901 add r1, sp, #4 802c37e: 4628 mov r0, r5 802c380: f000 fd9e bl 802cec0 /* bring the interface up */ netif_set_up(netif); 802c384: 4628 mov r0, r5 802c386: f000 fdf5 bl 802cf74 /* netif is now bound to DHCP leased address */ dhcp_set_state(dhcp, DHCP_BOUND); 802c38a: 4620 mov r0, r4 802c38c: 210a movs r1, #10 802c38e: f7ff fd1f bl 802bdd0 } 802c392: bd3e pop {r1, r2, r3, r4, r5, pc} 0802c394 : /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { 802c394: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 802c398: 4692 mov sl, r2 802c39a: b08b sub sp, #44 ; 0x2c LWIP_UNUSED_ARG(addr); LWIP_UNUSED_ARG(port); LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL); if (p->len < DHCP_MIN_REPLY_LEN) { 802c39c: f8ba 300a ldrh.w r3, [sl, #10] */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { struct netif *netif = (struct netif *)arg; struct dhcp *dhcp = netif->dhcp; 802c3a0: f8d0 8020 ldr.w r8, [r0, #32] struct dhcp_msg *reply_msg = (struct dhcp_msg *)p->payload; 802c3a4: 6852 ldr r2, [r2, #4] LWIP_UNUSED_ARG(addr); LWIP_UNUSED_ARG(port); LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL); if (p->len < DHCP_MIN_REPLY_LEN) { 802c3a6: 2b2b cmp r3, #43 ; 0x2b /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { 802c3a8: 4605 mov r5, r0 LWIP_UNUSED_ARG(addr); LWIP_UNUSED_ARG(port); LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL); if (p->len < DHCP_MIN_REPLY_LEN) { 802c3aa: f240 81b8 bls.w 802c71e LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("DHCP reply message or pbuf too short\n")); goto free_pbuf_and_return; } if (reply_msg->op != DHCP_BOOTREPLY) { 802c3ae: 7813 ldrb r3, [r2, #0] 802c3b0: 2b02 cmp r3, #2 802c3b2: f040 81b4 bne.w 802c71e LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("not a DHCP reply message, but type %"U16_F"\n", (u16_t)reply_msg->op)); goto free_pbuf_and_return; } /* iterate through hardware address and match against DHCP message */ for (i = 0; i < netif->hwaddr_len; i++) { 802c3b6: f890 1026 ldrb.w r1, [r0, #38] ; 0x26 802c3ba: 2300 movs r3, #0 802c3bc: e008 b.n 802c3d0 /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c3be: 18e8 adds r0, r5, r3 802c3c0: 3301 adds r3, #1 802c3c2: 18d4 adds r4, r2, r3 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("not a DHCP reply message, but type %"U16_F"\n", (u16_t)reply_msg->op)); goto free_pbuf_and_return; } /* iterate through hardware address and match against DHCP message */ for (i = 0; i < netif->hwaddr_len; i++) { if (netif->hwaddr[i] != reply_msg->chaddr[i]) { 802c3c4: f890 0027 ldrb.w r0, [r0, #39] ; 0x27 802c3c8: 7ee4 ldrb r4, [r4, #27] 802c3ca: 4284 cmp r4, r0 802c3cc: f040 81a7 bne.w 802c71e if (reply_msg->op != DHCP_BOOTREPLY) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("not a DHCP reply message, but type %"U16_F"\n", (u16_t)reply_msg->op)); goto free_pbuf_and_return; } /* iterate through hardware address and match against DHCP message */ for (i = 0; i < netif->hwaddr_len; i++) { 802c3d0: b2d8 uxtb r0, r3 802c3d2: 4288 cmp r0, r1 802c3d4: d3f3 bcc.n 802c3be (u16_t)i, (u16_t)netif->hwaddr[i], (u16_t)i, (u16_t)reply_msg->chaddr[i])); goto free_pbuf_and_return; } } /* match transaction ID against what we expected */ if (ntohl(reply_msg->xid) != dhcp->xid) { 802c3d6: 6850 ldr r0, [r2, #4] 802c3d8: f7ff fcf8 bl 802bdcc 802c3dc: f8d8 3000 ldr.w r3, [r8] 802c3e0: 4298 cmp r0, r3 802c3e2: f040 819c bne.w 802c71e struct pbuf *q; int parse_file_as_options = 0; int parse_sname_as_options = 0; /* clear received options */ dhcp_clear_all_options(dhcp); 802c3e6: 2100 movs r1, #0 802c3e8: 220a movs r2, #10 802c3ea: 489d ldr r0, [pc, #628] ; (802c660 ) 802c3ec: f7f5 fb68 bl 8021ac0 /* check that beginning of dhcp_msg (up to and including chaddr) is in first pbuf */ if (p->len < DHCP_SNAME_OFS) { 802c3f0: f8ba 300a ldrh.w r3, [sl, #10] 802c3f4: 2b2b cmp r3, #43 ; 0x2b 802c3f6: f240 8192 bls.w 802c71e return ERR_BUF; } dhcp->msg_in = (struct dhcp_msg *)p->payload; 802c3fa: f8da 3004 ldr.w r3, [sl, #4] /* parse options */ /* start with options field */ options_idx = DHCP_OPTIONS_OFS; /* parse options to the end of the received packet */ options_idx_max = p->tot_len; 802c3fe: f8ba 9008 ldrh.w r9, [sl, #8] dhcp_clear_all_options(dhcp); /* check that beginning of dhcp_msg (up to and including chaddr) is in first pbuf */ if (p->len < DHCP_SNAME_OFS) { return ERR_BUF; } dhcp->msg_in = (struct dhcp_msg *)p->payload; 802c402: f8c8 3008 str.w r3, [r8, #8] u16_t offset_max; u16_t options_idx; u16_t options_idx_max; struct pbuf *q; int parse_file_as_options = 0; int parse_sname_as_options = 0; 802c406: f04f 0b00 mov.w fp, #0 #endif /* LWIP_DHCP_BOOTP_FILE */ /* parse options */ /* start with options field */ options_idx = DHCP_OPTIONS_OFS; 802c40a: 22f0 movs r2, #240 ; 0xf0 802c40c: e004 b.n 802c418 parse_file_as_options = 0; options_idx = DHCP_FILE_OFS; options_idx_max = DHCP_FILE_OFS + DHCP_FILE_LEN; goto again; } else if (parse_sname_as_options) { parse_sname_as_options = 0; 802c40e: f04f 0b00 mov.w fp, #0 options_idx = DHCP_SNAME_OFS; options_idx_max = DHCP_SNAME_OFS + DHCP_SNAME_LEN; 802c412: f04f 096c mov.w r9, #108 ; 0x6c options_idx = DHCP_FILE_OFS; options_idx_max = DHCP_FILE_OFS + DHCP_FILE_LEN; goto again; } else if (parse_sname_as_options) { parse_sname_as_options = 0; options_idx = DHCP_SNAME_OFS; 802c416: 222c movs r2, #44 ; 0x2c #endif /* LWIP_DHCP_BOOTP_FILE */ /* parse options */ /* start with options field */ options_idx = DHCP_OPTIONS_OFS; 802c418: 4657 mov r7, sl 802c41a: e009 b.n 802c430 again: q = p; while((q != NULL) && (options_idx >= q->len)) { options_idx -= q->len; options_idx_max -= q->len; q = q->next; 802c41c: 683f ldr r7, [r7, #0] /* parse options to the end of the received packet */ options_idx_max = p->tot_len; again: q = p; while((q != NULL) && (options_idx >= q->len)) { options_idx -= q->len; 802c41e: 1ad2 subs r2, r2, r3 options_idx_max -= q->len; 802c420: ebc3 0909 rsb r9, r3, r9 /* parse options to the end of the received packet */ options_idx_max = p->tot_len; again: q = p; while((q != NULL) && (options_idx >= q->len)) { options_idx -= q->len; 802c424: b292 uxth r2, r2 options_idx_max -= q->len; 802c426: fa1f f989 uxth.w r9, r9 options_idx = DHCP_OPTIONS_OFS; /* parse options to the end of the received packet */ options_idx_max = p->tot_len; again: q = p; while((q != NULL) && (options_idx >= q->len)) { 802c42a: 2f00 cmp r7, #0 802c42c: f000 8177 beq.w 802c71e 802c430: 897b ldrh r3, [r7, #10] 802c432: 429a cmp r2, r3 802c434: d2f2 bcs.n 802c41c if (q == NULL) { return ERR_BUF; } offset = options_idx; offset_max = options_idx_max; options = (u8_t*)q->payload; 802c436: 6878 ldr r0, [r7, #4] 802c438: 9003 str r0, [sp, #12] 802c43a: e0db b.n 802c5f4 u8_t len; u8_t decode_len = 0; int decode_idx = -1; u16_t val_offset = offset + 2; /* len byte might be in the next pbuf */ if (offset + 1 < q->len) { 802c43c: 897b ldrh r3, [r7, #10] 802c43e: 1c50 adds r0, r2, #1 802c440: 4298 cmp r0, r3 802c442: da03 bge.n 802c44c len = options[offset + 1]; 802c444: 9803 ldr r0, [sp, #12] 802c446: 1883 adds r3, r0, r2 802c448: 785b ldrb r3, [r3, #1] 802c44a: e003 b.n 802c454 } else { len = (q->next != NULL ? ((u8_t*)q->next->payload)[0] : 0); 802c44c: 683b ldr r3, [r7, #0] 802c44e: b10b cbz r3, 802c454 802c450: 685b ldr r3, [r3, #4] 802c452: 781b ldrb r3, [r3, #0] } /* LWIP_DEBUGF(DHCP_DEBUG, ("msg_offset=%"U16_F", q->len=%"U16_F, msg_offset, q->len)); */ decode_len = len; switch(op) { 802c454: 2933 cmp r1, #51 ; 0x33 802c456: d038 beq.n 802c4ca 802c458: d807 bhi.n 802c46a 802c45a: 2901 cmp r1, #1 802c45c: d019 beq.n 802c492 802c45e: d311 bcc.n 802c484 802c460: 2903 cmp r1, #3 802c462: d01d beq.n 802c4a0 802c464: 2906 cmp r1, #6 802c466: d155 bne.n 802c514 802c468: e021 b.n 802c4ae 802c46a: 2936 cmp r1, #54 ; 0x36 802c46c: d03d beq.n 802c4ea 802c46e: d804 bhi.n 802c47a 802c470: 2934 cmp r1, #52 ; 0x34 802c472: d031 beq.n 802c4d8 802c474: 2935 cmp r1, #53 ; 0x35 802c476: d14d bne.n 802c514 802c478: e035 b.n 802c4e6 802c47a: 293a cmp r1, #58 ; 0x3a 802c47c: d03c beq.n 802c4f8 802c47e: 293b cmp r1, #59 ; 0x3b 802c480: d148 bne.n 802c514 802c482: e040 b.n 802c506 /* case(DHCP_OPTION_END): handled above */ case(DHCP_OPTION_PAD): /* special option: no len encoded */ decode_len = len = 0; /* will be increased below */ offset--; 802c484: 1e51 subs r1, r2, #1 decode_len = len; switch(op) { /* case(DHCP_OPTION_END): handled above */ case(DHCP_OPTION_PAD): /* special option: no len encoded */ decode_len = len = 0; 802c486: 2300 movs r3, #0 /* will be increased below */ offset--; 802c488: b289 uxth r1, r1 /* at least 1 byte to read and no end marker, then at least 3 bytes to read? */ while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) { u8_t op = options[offset]; u8_t len; u8_t decode_len = 0; int decode_idx = -1; 802c48a: f04f 34ff mov.w r4, #4294967295 decode_len = len; switch(op) { /* case(DHCP_OPTION_END): handled above */ case(DHCP_OPTION_PAD): /* special option: no len encoded */ decode_len = len = 0; 802c48e: 461e mov r6, r3 802c490: e044 b.n 802c51c /* will be increased below */ offset--; break; case(DHCP_OPTION_SUBNET_MASK): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); 802c492: 2b04 cmp r3, #4 802c494: f040 8143 bne.w 802c71e 802c498: 461e mov r6, r3 802c49a: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_SUBNET_MASK; 802c49c: 2406 movs r4, #6 802c49e: e03d b.n 802c51c break; case(DHCP_OPTION_ROUTER): decode_len = 4; /* only copy the first given router */ LWIP_ERROR("len >= decode_len", len >= decode_len, return ERR_VAL;); 802c4a0: 2b03 cmp r3, #3 802c4a2: f240 813c bls.w 802c71e 802c4a6: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_ROUTER; 802c4a8: 2407 movs r4, #7 case(DHCP_OPTION_SUBNET_MASK): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); decode_idx = DHCP_OPTION_IDX_SUBNET_MASK; break; case(DHCP_OPTION_ROUTER): decode_len = 4; /* only copy the first given router */ 802c4aa: 2604 movs r6, #4 802c4ac: e036 b.n 802c51c LWIP_ERROR("len >= decode_len", len >= decode_len, return ERR_VAL;); decode_idx = DHCP_OPTION_IDX_ROUTER; break; case(DHCP_OPTION_DNS_SERVER): /* special case: there might be more than one server */ LWIP_ERROR("len % 4 == 0", len % 4 == 0, return ERR_VAL;); 802c4ae: 0799 lsls r1, r3, #30 802c4b0: f040 8135 bne.w 802c71e /* limit number of DNS servers */ decode_len = LWIP_MIN(len, 4 * DNS_MAX_SERVERS); 802c4b4: 2b08 cmp r3, #8 802c4b6: bf34 ite cc 802c4b8: 461e movcc r6, r3 802c4ba: 2608 movcs r6, #8 802c4bc: b2f6 uxtb r6, r6 LWIP_ERROR("len >= decode_len", len >= decode_len, return ERR_VAL;); 802c4be: 42b3 cmp r3, r6 802c4c0: f0c0 812d bcc.w 802c71e 802c4c4: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_DNS_SERVER; 802c4c6: 2408 movs r4, #8 802c4c8: e028 b.n 802c51c break; case(DHCP_OPTION_LEASE_TIME): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); 802c4ca: 2b04 cmp r3, #4 802c4cc: f040 8127 bne.w 802c71e 802c4d0: 461e mov r6, r3 802c4d2: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_LEASE_TIME; 802c4d4: 2403 movs r4, #3 802c4d6: e021 b.n 802c51c break; case(DHCP_OPTION_OVERLOAD): LWIP_ERROR("len == 1", len == 1, return ERR_VAL;); 802c4d8: 2b01 cmp r3, #1 802c4da: f040 8120 bne.w 802c71e 802c4de: 461e mov r6, r3 802c4e0: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_OVERLOAD; 802c4e2: 2400 movs r4, #0 802c4e4: e01a b.n 802c51c break; case(DHCP_OPTION_MESSAGE_TYPE): LWIP_ERROR("len == 1", len == 1, return ERR_VAL;); 802c4e6: 2b01 cmp r3, #1 802c4e8: e007 b.n 802c4fa decode_idx = DHCP_OPTION_IDX_MSG_TYPE; break; case(DHCP_OPTION_SERVER_ID): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); 802c4ea: 2b04 cmp r3, #4 802c4ec: f040 8117 bne.w 802c71e 802c4f0: 461e mov r6, r3 802c4f2: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_SERVER_ID; 802c4f4: 2402 movs r4, #2 802c4f6: e011 b.n 802c51c break; case(DHCP_OPTION_T1): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); 802c4f8: 2b04 cmp r3, #4 802c4fa: f040 8110 bne.w 802c71e 802c4fe: 461e mov r6, r3 802c500: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_T1; 802c502: 461c mov r4, r3 802c504: e00a b.n 802c51c break; case(DHCP_OPTION_T2): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); 802c506: 2b04 cmp r3, #4 802c508: f040 8109 bne.w 802c71e 802c50c: 461e mov r6, r3 802c50e: 4611 mov r1, r2 decode_idx = DHCP_OPTION_IDX_T2; 802c510: 2405 movs r4, #5 802c512: e003 b.n 802c51c } else { len = (q->next != NULL ? ((u8_t*)q->next->payload)[0] : 0); } /* LWIP_DEBUGF(DHCP_DEBUG, ("msg_offset=%"U16_F", q->len=%"U16_F, msg_offset, q->len)); */ decode_len = len; switch(op) { 802c514: 4611 mov r1, r2 /* at least 1 byte to read and no end marker, then at least 3 bytes to read? */ while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) { u8_t op = options[offset]; u8_t len; u8_t decode_len = 0; int decode_idx = -1; 802c516: f04f 34ff mov.w r4, #4294967295 case(DHCP_OPTION_T2): LWIP_ERROR("len == 4", len == 4, return ERR_VAL;); decode_idx = DHCP_OPTION_IDX_T2; break; default: decode_len = 0; 802c51a: 2600 movs r6, #0 LWIP_DEBUGF(DHCP_DEBUG, ("skipping option %"U16_F" in options\n", op)); break; } offset += len + 2; 802c51c: 3102 adds r1, #2 802c51e: fa13 f381 uxtah r3, r3, r1 802c522: b29b uxth r3, r3 802c524: 9301 str r3, [sp, #4] if (decode_len > 0) { 802c526: 2e00 cmp r6, #0 802c528: d04f beq.n 802c5ca while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) { u8_t op = options[offset]; u8_t len; u8_t decode_len = 0; int decode_idx = -1; u16_t val_offset = offset + 2; 802c52a: 3202 adds r2, #2 802c52c: b292 uxth r2, r2 LWIP_DEBUGF(DHCP_DEBUG, ("skipping option %"U16_F" in options\n", op)); break; } offset += len + 2; if (decode_len > 0) { u32_t value = 0; 802c52e: a90a add r1, sp, #40 ; 0x28 while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) { u8_t op = options[offset]; u8_t len; u8_t decode_len = 0; int decode_idx = -1; u16_t val_offset = offset + 2; 802c530: 9205 str r2, [sp, #20] LWIP_DEBUGF(DHCP_DEBUG, ("skipping option %"U16_F" in options\n", op)); break; } offset += len + 2; if (decode_len > 0) { u32_t value = 0; 802c532: 2300 movs r3, #0 /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c534: 4a4b ldr r2, [pc, #300] ; (802c664 ) LWIP_DEBUGF(DHCP_DEBUG, ("skipping option %"U16_F" in options\n", op)); break; } offset += len + 2; if (decode_len > 0) { u32_t value = 0; 802c536: f841 3d04 str.w r3, [r1, #-4]! /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c53a: eb02 0284 add.w r2, r2, r4, lsl #2 LWIP_DEBUGF(DHCP_DEBUG, ("skipping option %"U16_F" in options\n", op)); break; } offset += len + 2; if (decode_len > 0) { u32_t value = 0; 802c53e: 9104 str r1, [sp, #16] /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c540: 9206 str r2, [sp, #24] 802c542: 9302 str r3, [sp, #8] 802c544: 9805 ldr r0, [sp, #20] 802c546: 9902 ldr r1, [sp, #8] if (decode_len > 0) { u32_t value = 0; u16_t copy_len; decode_next: LWIP_ASSERT("check decode_idx", decode_idx >= 0 && decode_idx < DHCP_OPTION_IDX_MAX); if (!dhcp_option_given(dhcp, decode_idx)) { 802c548: 4a45 ldr r2, [pc, #276] ; (802c660 ) /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c54a: 1843 adds r3, r0, r1 if (decode_len > 0) { u32_t value = 0; u16_t copy_len; decode_next: LWIP_ASSERT("check decode_idx", decode_idx >= 0 && decode_idx < DHCP_OPTION_IDX_MAX); if (!dhcp_option_given(dhcp, decode_idx)) { 802c54c: 4844 ldr r0, [pc, #272] ; (802c660 ) 802c54e: 18a2 adds r2, r4, r2 802c550: 9207 str r2, [sp, #28] 802c552: 5c22 ldrb r2, [r4, r0] /** * If an incoming DHCP message is in response to us, then trigger the state machine */ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) 802c554: ebc1 0c06 rsb ip, r1, r6 802c558: b29b uxth r3, r3 802c55a: fa5f fc8c uxtb.w ip, ip if (decode_len > 0) { u32_t value = 0; u16_t copy_len; decode_next: LWIP_ASSERT("check decode_idx", decode_idx >= 0 && decode_idx < DHCP_OPTION_IDX_MAX); if (!dhcp_option_given(dhcp, decode_idx)) { 802c55e: 2a00 cmp r2, #0 802c560: d133 bne.n 802c5ca copy_len = LWIP_MIN(decode_len, 4); pbuf_copy_partial(q, &value, copy_len, val_offset); 802c562: f1bc 0f03 cmp.w ip, #3 802c566: bf94 ite ls 802c568: 4662 movls r2, ip 802c56a: 2204 movhi r2, #4 802c56c: 4638 mov r0, r7 802c56e: 9904 ldr r1, [sp, #16] 802c570: f8cd c000 str.w ip, [sp] 802c574: f000 feaa bl 802d2cc if (decode_len > 4) { 802c578: f8dd c000 ldr.w ip, [sp] 802c57c: f1bc 0f04 cmp.w ip, #4 802c580: d90f bls.n 802c5a2 /* decode more than one u32_t */ LWIP_ERROR("decode_len % 4 == 0", decode_len % 4 == 0, return ERR_VAL;); 802c582: f01c 0f03 tst.w ip, #3 802c586: f040 80ca bne.w 802c71e dhcp_got_option(dhcp, decode_idx); 802c58a: 9907 ldr r1, [sp, #28] dhcp_set_option_value(dhcp, decode_idx, htonl(value)); 802c58c: 9809 ldr r0, [sp, #36] ; 0x24 copy_len = LWIP_MIN(decode_len, 4); pbuf_copy_partial(q, &value, copy_len, val_offset); if (decode_len > 4) { /* decode more than one u32_t */ LWIP_ERROR("decode_len % 4 == 0", decode_len % 4 == 0, return ERR_VAL;); dhcp_got_option(dhcp, decode_idx); 802c58e: 2201 movs r2, #1 802c590: 700a strb r2, [r1, #0] dhcp_set_option_value(dhcp, decode_idx, htonl(value)); 802c592: f7ff fc19 bl 802bdc8 802c596: 9b02 ldr r3, [sp, #8] 802c598: 9906 ldr r1, [sp, #24] decode_len -= 4; val_offset += 4; decode_idx++; 802c59a: 3401 adds r4, #1 pbuf_copy_partial(q, &value, copy_len, val_offset); if (decode_len > 4) { /* decode more than one u32_t */ LWIP_ERROR("decode_len % 4 == 0", decode_len % 4 == 0, return ERR_VAL;); dhcp_got_option(dhcp, decode_idx); dhcp_set_option_value(dhcp, decode_idx, htonl(value)); 802c59c: 50c8 str r0, [r1, r3] 802c59e: 3304 adds r3, #4 802c5a0: e7cf b.n 802c542 decode_len -= 4; val_offset += 4; decode_idx++; goto decode_next; } else if (decode_len == 4) { 802c5a2: d104 bne.n 802c5ae value = ntohl(value); 802c5a4: 9809 ldr r0, [sp, #36] ; 0x24 802c5a6: f7ff fc11 bl 802bdcc 802c5aa: 9009 str r0, [sp, #36] ; 0x24 802c5ac: e006 b.n 802c5bc } else { LWIP_ERROR("invalid decode_len", decode_len == 1, return ERR_VAL;); 802c5ae: f1bc 0f01 cmp.w ip, #1 802c5b2: f040 80b4 bne.w 802c71e value = ((u8_t*)&value)[0]; 802c5b6: f89d 3024 ldrb.w r3, [sp, #36] ; 0x24 802c5ba: 9309 str r3, [sp, #36] ; 0x24 } dhcp_got_option(dhcp, decode_idx); 802c5bc: 4a28 ldr r2, [pc, #160] ; (802c660 ) dhcp_set_option_value(dhcp, decode_idx, value); 802c5be: 4829 ldr r0, [pc, #164] ; (802c664 ) value = ntohl(value); } else { LWIP_ERROR("invalid decode_len", decode_len == 1, return ERR_VAL;); value = ((u8_t*)&value)[0]; } dhcp_got_option(dhcp, decode_idx); 802c5c0: 2301 movs r3, #1 802c5c2: 5513 strb r3, [r2, r4] dhcp_set_option_value(dhcp, decode_idx, value); 802c5c4: 9b09 ldr r3, [sp, #36] ; 0x24 802c5c6: f840 3024 str.w r3, [r0, r4, lsl #2] } } if (offset >= q->len) { 802c5ca: 897b ldrh r3, [r7, #10] 802c5cc: 9901 ldr r1, [sp, #4] 802c5ce: 4299 cmp r1, r3 802c5d0: d30f bcc.n 802c5f2 offset -= q->len; 802c5d2: 1aca subs r2, r1, r3 offset_max -= q->len; 802c5d4: ebc3 0909 rsb r9, r3, r9 dhcp_got_option(dhcp, decode_idx); dhcp_set_option_value(dhcp, decode_idx, value); } } if (offset >= q->len) { offset -= q->len; 802c5d8: b292 uxth r2, r2 offset_max -= q->len; 802c5da: fa1f f989 uxth.w r9, r9 if ((offset < offset_max) && offset_max) { 802c5de: 454a cmp r2, r9 dhcp_got_option(dhcp, decode_idx); dhcp_set_option_value(dhcp, decode_idx, value); } } if (offset >= q->len) { offset -= q->len; 802c5e0: 9201 str r2, [sp, #4] offset_max -= q->len; if ((offset < offset_max) && offset_max) { 802c5e2: d303 bcc.n 802c5ec break; } } } /* is this an overloaded message? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_OVERLOAD)) { 802c5e4: 4a1e ldr r2, [pc, #120] ; (802c660 ) 802c5e6: 7813 ldrb r3, [r2, #0] 802c5e8: b963 cbnz r3, 802c604 802c5ea: e09f b.n 802c72c } if (offset >= q->len) { offset -= q->len; offset_max -= q->len; if ((offset < offset_max) && offset_max) { q = q->next; 802c5ec: 683f ldr r7, [r7, #0] LWIP_ASSERT("next pbuf was null", q); options = (u8_t*)q->payload; 802c5ee: 687b ldr r3, [r7, #4] 802c5f0: 9303 str r3, [sp, #12] u32_t value = 0; u16_t copy_len; decode_next: LWIP_ASSERT("check decode_idx", decode_idx >= 0 && decode_idx < DHCP_OPTION_IDX_MAX); if (!dhcp_option_given(dhcp, decode_idx)) { copy_len = LWIP_MIN(decode_len, 4); 802c5f2: 9a01 ldr r2, [sp, #4] } offset = options_idx; offset_max = options_idx_max; options = (u8_t*)q->payload; /* at least 1 byte to read and no end marker, then at least 3 bytes to read? */ while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) { 802c5f4: 9803 ldr r0, [sp, #12] 802c5f6: 5c81 ldrb r1, [r0, r2] 802c5f8: 29ff cmp r1, #255 ; 0xff 802c5fa: d0f3 beq.n 802c5e4 802c5fc: 454a cmp r2, r9 802c5fe: f4ff af1d bcc.w 802c43c 802c602: e7ef b.n 802c5e4 } } } /* is this an overloaded message? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_OVERLOAD)) { u32_t overload = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_OVERLOAD); 802c604: 4b17 ldr r3, [pc, #92] ; (802c664 ) dhcp_clear_option(dhcp, DHCP_OPTION_IDX_OVERLOAD); 802c606: 4916 ldr r1, [pc, #88] ; (802c660 ) } } } /* is this an overloaded message? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_OVERLOAD)) { u32_t overload = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_OVERLOAD); 802c608: 681b ldr r3, [r3, #0] dhcp_clear_option(dhcp, DHCP_OPTION_IDX_OVERLOAD); 802c60a: 2200 movs r2, #0 if (overload == DHCP_OVERLOAD_FILE) { 802c60c: 2b01 cmp r3, #1 } } /* is this an overloaded message? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_OVERLOAD)) { u32_t overload = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_OVERLOAD); dhcp_clear_option(dhcp, DHCP_OPTION_IDX_OVERLOAD); 802c60e: 700a strb r2, [r1, #0] if (overload == DHCP_OVERLOAD_FILE) { 802c610: f000 8093 beq.w 802c73a parse_file_as_options = 1; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("overloaded file field\n")); } else if (overload == DHCP_OVERLOAD_SNAME) { 802c614: 2b02 cmp r3, #2 802c616: f43f aefa beq.w 802c40e parse_sname_as_options = 1; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("overloaded sname field\n")); } else if (overload == DHCP_OVERLOAD_SNAME_FILE) { 802c61a: 2b03 cmp r3, #3 802c61c: f040 8086 bne.w 802c72c 802c620: e089 b.n 802c736 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("DHCP_OPTION_MESSAGE_TYPE option not found\n")); goto free_pbuf_and_return; } /* read DHCP message type */ msg_type = (u8_t)dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_MSG_TYPE); 802c622: 4a10 ldr r2, [pc, #64] ; (802c664 ) 802c624: 7911 ldrb r1, [r2, #4] /* message type is DHCP ACK? */ if (msg_type == DHCP_ACK) { 802c626: 2905 cmp r1, #5 802c628: d140 bne.n 802c6ac LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("DHCP_ACK received\n")); /* in requesting state? */ if (dhcp->state == DHCP_REQUESTING) { 802c62a: f898 100c ldrb.w r1, [r8, #12] 802c62e: 2901 cmp r1, #1 802c630: d135 bne.n 802c69e * @param netif the netif under DHCP control */ static void dhcp_handle_ack(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; 802c632: 6a2c ldr r4, [r5, #32] #if LWIP_DHCP_BOOTP_FILE ip_addr_set_zero(&dhcp->offered_si_addr); #endif /* LWIP_DHCP_BOOTP_FILE */ /* lease time given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_LEASE_TIME)) { 802c634: 78db ldrb r3, [r3, #3] #if LWIP_DNS u8_t n; #endif /* LWIP_DNS */ /* clear options we might not get from the ACK */ ip_addr_set_zero(&dhcp->offered_sn_mask); 802c636: f8c4 b028 str.w fp, [r4, #40] ; 0x28 ip_addr_set_zero(&dhcp->offered_gw_addr); 802c63a: f8c4 b02c str.w fp, [r4, #44] ; 0x2c #if LWIP_DHCP_BOOTP_FILE ip_addr_set_zero(&dhcp->offered_si_addr); #endif /* LWIP_DHCP_BOOTP_FILE */ /* lease time given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_LEASE_TIME)) { 802c63e: b10b cbz r3, 802c644 /* remember offered lease time */ dhcp->offered_t0_lease = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_LEASE_TIME); 802c640: 68d3 ldr r3, [r2, #12] 802c642: 6323 str r3, [r4, #48] ; 0x30 } /* renewal period given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_T1)) { 802c644: 4b06 ldr r3, [pc, #24] ; (802c660 ) 802c646: 791a ldrb r2, [r3, #4] 802c648: b112 cbz r2, 802c650 /* remember given renewal period */ dhcp->offered_t1_renew = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_T1); 802c64a: 4a06 ldr r2, [pc, #24] ; (802c664 ) 802c64c: 6912 ldr r2, [r2, #16] 802c64e: e001 b.n 802c654 } else { /* calculate safe periods for renewal */ dhcp->offered_t1_renew = dhcp->offered_t0_lease / 2; 802c650: 6b22 ldr r2, [r4, #48] ; 0x30 802c652: 0852 lsrs r2, r2, #1 } /* renewal period given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_T2)) { 802c654: 795b ldrb r3, [r3, #5] if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_T1)) { /* remember given renewal period */ dhcp->offered_t1_renew = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_T1); } else { /* calculate safe periods for renewal */ dhcp->offered_t1_renew = dhcp->offered_t0_lease / 2; 802c656: 6362 str r2, [r4, #52] ; 0x34 } /* renewal period given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_T2)) { 802c658: b133 cbz r3, 802c668 /* remember given rebind period */ dhcp->offered_t2_rebind = dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_T2); 802c65a: 4b02 ldr r3, [pc, #8] ; (802c664 ) 802c65c: 695b ldr r3, [r3, #20] 802c65e: e004 b.n 802c66a 802c660: 2000fb88 .word 0x2000fb88 802c664: 2000fb94 .word 0x2000fb94 } else { /* calculate safe periods for rebinding */ dhcp->offered_t2_rebind = dhcp->offered_t0_lease; 802c668: 6b23 ldr r3, [r4, #48] ; 0x30 802c66a: 63a3 str r3, [r4, #56] ; 0x38 } /* (y)our internet address */ ip_addr_copy(dhcp->offered_ip_addr, dhcp->msg_in->yiaddr); 802c66c: 68a3 ldr r3, [r4, #8] boot file name copied in dhcp_parse_reply if not overloaded */ ip_addr_copy(dhcp->offered_si_addr, dhcp->msg_in->siaddr); #endif /* LWIP_DHCP_BOOTP_FILE */ /* subnet mask given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SUBNET_MASK)) { 802c66e: 4a39 ldr r2, [pc, #228] ; (802c754 ) /* calculate safe periods for rebinding */ dhcp->offered_t2_rebind = dhcp->offered_t0_lease; } /* (y)our internet address */ ip_addr_copy(dhcp->offered_ip_addr, dhcp->msg_in->yiaddr); 802c670: 691b ldr r3, [r3, #16] 802c672: 6263 str r3, [r4, #36] ; 0x24 boot file name copied in dhcp_parse_reply if not overloaded */ ip_addr_copy(dhcp->offered_si_addr, dhcp->msg_in->siaddr); #endif /* LWIP_DHCP_BOOTP_FILE */ /* subnet mask given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SUBNET_MASK)) { 802c674: 7993 ldrb r3, [r2, #6] 802c676: 4616 mov r6, r2 802c678: b12b cbz r3, 802c686 /* remember given subnet mask */ ip4_addr_set_u32(&dhcp->offered_sn_mask, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_SUBNET_MASK))); 802c67a: 4b37 ldr r3, [pc, #220] ; (802c758 ) 802c67c: 6998 ldr r0, [r3, #24] 802c67e: f7ff fba3 bl 802bdc8 dhcp->subnet_mask_given = 1; 802c682: 2301 movs r3, #1 #endif /* LWIP_DHCP_BOOTP_FILE */ /* subnet mask given? */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SUBNET_MASK)) { /* remember given subnet mask */ ip4_addr_set_u32(&dhcp->offered_sn_mask, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_SUBNET_MASK))); 802c684: 62a0 str r0, [r4, #40] ; 0x28 dhcp->subnet_mask_given = 1; } else { dhcp->subnet_mask_given = 0; 802c686: 73a3 strb r3, [r4, #14] } /* gateway router */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_ROUTER)) { 802c688: 79f3 ldrb r3, [r6, #7] 802c68a: b123 cbz r3, 802c696 ip4_addr_set_u32(&dhcp->offered_gw_addr, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_ROUTER))); 802c68c: 4b32 ldr r3, [pc, #200] ; (802c758 ) 802c68e: 69d8 ldr r0, [r3, #28] 802c690: f7ff fb9a bl 802bdc8 802c694: 62e0 str r0, [r4, #44] ; 0x2c /* in requesting state? */ if (dhcp->state == DHCP_REQUESTING) { dhcp_handle_ack(netif); #if DHCP_DOES_ARP_CHECK /* check if the acknowledged lease address is already in use */ dhcp_check(netif); 802c696: 4628 mov r0, r5 802c698: f7ff fe0a bl 802c2b0 802c69c: e03f b.n 802c71e /* bind interface to the acknowledged lease address */ dhcp_bind(netif); #endif } /* already bound to the given lease address? */ else if ((dhcp->state == DHCP_REBOOTING) || (dhcp->state == DHCP_REBINDING) || (dhcp->state == DHCP_RENEWING)) { 802c69e: 3903 subs r1, #3 802c6a0: 2902 cmp r1, #2 802c6a2: d83c bhi.n 802c71e dhcp_bind(netif); 802c6a4: 4628 mov r0, r5 802c6a6: f7ff fe16 bl 802c2d6 802c6aa: e038 b.n 802c71e } } /* received a DHCP_NAK in appropriate state? */ else if ((msg_type == DHCP_NAK) && 802c6ac: 2906 cmp r1, #6 802c6ae: d121 bne.n 802c6f4 802c6b0: f898 300c ldrb.w r3, [r8, #12] 802c6b4: 2b05 cmp r3, #5 802c6b6: d832 bhi.n 802c71e 802c6b8: f998 300c ldrsb.w r3, [r8, #12] 802c6bc: f04f 42b8 mov.w r2, #1543503872 ; 0x5c000000 802c6c0: 409a lsls r2, r3 802c6c2: d52c bpl.n 802c71e { struct dhcp *dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_handle_nak(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* Set the interface down since the address must no longer be used, as per RFC2131 */ netif_set_down(netif); 802c6c4: 4628 mov r0, r5 * @param netif the netif under DHCP control */ static void dhcp_handle_nak(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; 802c6c6: 6a2c ldr r4, [r5, #32] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_handle_nak(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* Set the interface down since the address must no longer be used, as per RFC2131 */ netif_set_down(netif); 802c6c8: f000 fc6e bl 802cfa8 /* remove IP address from interface */ netif_set_ipaddr(netif, IP_ADDR_ANY); 802c6cc: 4628 mov r0, r5 802c6ce: 4923 ldr r1, [pc, #140] ; (802c75c ) 802c6d0: f000 fbba bl 802ce48 netif_set_gw(netif, IP_ADDR_ANY); 802c6d4: 4628 mov r0, r5 802c6d6: 4921 ldr r1, [pc, #132] ; (802c75c ) 802c6d8: f000 fbf2 bl 802cec0 netif_set_netmask(netif, IP_ADDR_ANY); 802c6dc: 4628 mov r0, r5 802c6de: 491f ldr r1, [pc, #124] ; (802c75c ) 802c6e0: f000 fbf2 bl 802cec8 /* Change to a defined state */ dhcp_set_state(dhcp, DHCP_BACKING_OFF); 802c6e4: 4620 mov r0, r4 802c6e6: 210c movs r1, #12 802c6e8: f7ff fb72 bl 802bdd0 /* We can immediately restart discovery */ dhcp_discover(netif); 802c6ec: 4628 mov r0, r5 802c6ee: f7ff fc7f bl 802bff0 802c6f2: e014 b.n 802c71e (dhcp->state == DHCP_REBINDING) || (dhcp->state == DHCP_RENEWING ))) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("DHCP_NAK received\n")); dhcp_handle_nak(netif); } /* received a DHCP_OFFER in DHCP_SELECTING state? */ else if ((msg_type == DHCP_OFFER) && (dhcp->state == DHCP_SELECTING)) { 802c6f4: 2902 cmp r1, #2 802c6f6: d112 bne.n 802c71e 802c6f8: f898 100c ldrb.w r1, [r8, #12] 802c6fc: 2906 cmp r1, #6 802c6fe: d10e bne.n 802c71e { struct dhcp *dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_handle_offer(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* obtain the server address */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SERVER_ID)) { 802c700: 789b ldrb r3, [r3, #2] dhcp_handle_nak(netif); } /* received a DHCP_OFFER in DHCP_SELECTING state? */ else if ((msg_type == DHCP_OFFER) && (dhcp->state == DHCP_SELECTING)) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("DHCP_OFFER received in DHCP_SELECTING state\n")); dhcp->request_timeout = 0; 802c702: f8a8 b01a strh.w fp, [r8, #26] * @param netif the netif under DHCP control */ static void dhcp_handle_offer(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; 802c706: 6a2c ldr r4, [r5, #32] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_handle_offer(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* obtain the server address */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SERVER_ID)) { 802c708: b14b cbz r3, 802c71e ip4_addr_set_u32(&dhcp->server_ip_addr, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_SERVER_ID))); 802c70a: 6890 ldr r0, [r2, #8] 802c70c: f7ff fb5c bl 802bdc8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_handle_offer(): server 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->server_ip_addr))); /* remember offered address */ ip_addr_copy(dhcp->offered_ip_addr, dhcp->msg_in->yiaddr); 802c710: 68a3 ldr r3, [r4, #8] struct dhcp *dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_handle_offer(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* obtain the server address */ if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SERVER_ID)) { ip4_addr_set_u32(&dhcp->server_ip_addr, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_SERVER_ID))); 802c712: 6220 str r0, [r4, #32] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_handle_offer(): server 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->server_ip_addr))); /* remember offered address */ ip_addr_copy(dhcp->offered_ip_addr, dhcp->msg_in->yiaddr); 802c714: 691b ldr r3, [r3, #16] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_handle_offer(): offer for 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->offered_ip_addr))); dhcp_select(netif); 802c716: 4628 mov r0, r5 if (dhcp_option_given(dhcp, DHCP_OPTION_IDX_SERVER_ID)) { ip4_addr_set_u32(&dhcp->server_ip_addr, htonl(dhcp_get_option_value(dhcp, DHCP_OPTION_IDX_SERVER_ID))); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_handle_offer(): server 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->server_ip_addr))); /* remember offered address */ ip_addr_copy(dhcp->offered_ip_addr, dhcp->msg_in->yiaddr); 802c718: 6263 str r3, [r4, #36] ; 0x24 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_handle_offer(): offer for 0x%08"X32_F"\n", ip4_addr_get_u32(&dhcp->offered_ip_addr))); dhcp_select(netif); 802c71a: f7ff fd57 bl 802c1cc dhcp->request_timeout = 0; /* remember offered lease */ dhcp_handle_offer(netif); } free_pbuf_and_return: dhcp->msg_in = NULL; 802c71e: 2300 movs r3, #0 802c720: f8c8 3008 str.w r3, [r8, #8] pbuf_free(p); 802c724: 4650 mov r0, sl 802c726: f000 fc83 bl 802d030 802c72a: e010 b.n 802c74e /* if both are overloaded, parse file first and then sname (RFC 2131 ch. 4.1) */ parse_file_as_options = 0; options_idx = DHCP_FILE_OFS; options_idx_max = DHCP_FILE_OFS + DHCP_FILE_LEN; goto again; } else if (parse_sname_as_options) { 802c72c: f1bb 0f00 cmp.w fp, #0 802c730: f47f ae6d bne.w 802c40e 802c734: e005 b.n 802c742 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("overloaded file field\n")); } else if (overload == DHCP_OVERLOAD_SNAME) { parse_sname_as_options = 1; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("overloaded sname field\n")); } else if (overload == DHCP_OVERLOAD_SNAME_FILE) { parse_sname_as_options = 1; 802c736: f04f 0b01 mov.w fp, #1 } if (parse_file_as_options) { /* if both are overloaded, parse file first and then sname (RFC 2131 ch. 4.1) */ parse_file_as_options = 0; options_idx = DHCP_FILE_OFS; options_idx_max = DHCP_FILE_OFS + DHCP_FILE_LEN; 802c73a: f04f 09ec mov.w r9, #236 ; 0xec #endif /* LWIP_DHCP_BOOTP_FILE */ } if (parse_file_as_options) { /* if both are overloaded, parse file first and then sname (RFC 2131 ch. 4.1) */ parse_file_as_options = 0; options_idx = DHCP_FILE_OFS; 802c73e: 226c movs r2, #108 ; 0x6c 802c740: e66a b.n 802c418 goto free_pbuf_and_return; } LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("searching DHCP_OPTION_MESSAGE_TYPE\n")); /* obtain pointer to DHCP message type */ if (!dhcp_option_given(dhcp, DHCP_OPTION_IDX_MSG_TYPE)) { 802c742: 4b04 ldr r3, [pc, #16] ; (802c754 ) 802c744: 785a ldrb r2, [r3, #1] 802c746: 2a00 cmp r2, #0 802c748: f47f af6b bne.w 802c622 802c74c: e7e7 b.n 802c71e dhcp_handle_offer(netif); } free_pbuf_and_return: dhcp->msg_in = NULL; pbuf_free(p); } 802c74e: b00b add sp, #44 ; 0x2c 802c750: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802c754: 2000fb88 .word 0x2000fb88 802c758: 2000fb94 .word 0x2000fb94 802c75c: 0803fe88 .word 0x0803fe88 0802c760 : * * @param netif the network interface on which the reply was received * @param addr The IP address we received a reply from */ void dhcp_arp_reply(struct netif *netif, ip_addr_t *addr) { 802c760: b537 push {r0, r1, r2, r4, r5, lr} LWIP_ERROR("netif != NULL", (netif != NULL), return;); 802c762: 4605 mov r5, r0 802c764: 2800 cmp r0, #0 802c766: d037 beq.n 802c7d8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_arp_reply()\n")); /* is a DHCP client doing an ARP check? */ if ((netif->dhcp != NULL) && (netif->dhcp->state == DHCP_CHECKING)) { 802c768: 6a04 ldr r4, [r0, #32] 802c76a: 2c00 cmp r4, #0 802c76c: d034 beq.n 802c7d8 802c76e: 7b23 ldrb r3, [r4, #12] 802c770: 2b08 cmp r3, #8 802c772: d131 bne.n 802c7d8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_arp_reply(): CHECKING, arp reply for 0x%08"X32_F"\n", ip4_addr_get_u32(addr))); /* did a host respond with the address we were offered by the DHCP server? */ if (ip_addr_cmp(addr, &netif->dhcp->offered_ip_addr)) { 802c774: 680a ldr r2, [r1, #0] 802c776: 6a63 ldr r3, [r4, #36] ; 0x24 802c778: 429a cmp r2, r3 802c77a: d12d bne.n 802c7d8 { struct dhcp *dhcp = netif->dhcp; err_t result = ERR_OK; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_decline()\n")); dhcp_set_state(dhcp, DHCP_BACKING_OFF); 802c77c: 4620 mov r0, r4 802c77e: 210c movs r1, #12 802c780: f7ff fb26 bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_DECLINE); 802c784: 4628 mov r0, r5 802c786: 4621 mov r1, r4 802c788: 2204 movs r2, #4 802c78a: f7ff fb85 bl 802be98 if (result == ERR_OK) { 802c78e: b9f0 cbnz r0, 802c7ce dhcp_option(dhcp, DHCP_OPTION_REQUESTED_IP, 4); 802c790: 2204 movs r2, #4 802c792: 2132 movs r1, #50 ; 0x32 802c794: 4620 mov r0, r4 802c796: f7ff fb23 bl 802bde0 dhcp_option_long(dhcp, ntohl(ip4_addr_get_u32(&dhcp->offered_ip_addr))); 802c79a: 6a60 ldr r0, [r4, #36] ; 0x24 802c79c: f7ff fb16 bl 802bdcc 802c7a0: 4601 mov r1, r0 802c7a2: 4620 mov r0, r4 802c7a4: f7ff fb43 bl 802be2e dhcp_option_trailer(dhcp); 802c7a8: 4620 mov r0, r4 802c7aa: f7ff fb60 bl 802be6e /* resize pbuf to reflect true size of options */ pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c7ae: 8b21 ldrh r1, [r4, #24] 802c7b0: 6920 ldr r0, [r4, #16] 802c7b2: 31f0 adds r1, #240 ; 0xf0 802c7b4: b289 uxth r1, r1 802c7b6: f000 fc62 bl 802d07e /* per section 4.4.4, broadcast DECLINE messages */ udp_sendto_if(dhcp->pcb, dhcp->p_out, IP_ADDR_BROADCAST, DHCP_SERVER_PORT, netif); 802c7ba: 9500 str r5, [sp, #0] 802c7bc: 6860 ldr r0, [r4, #4] 802c7be: 6921 ldr r1, [r4, #16] 802c7c0: 4a06 ldr r2, [pc, #24] ; (802c7dc ) 802c7c2: 2343 movs r3, #67 ; 0x43 802c7c4: f003 f8d4 bl 802f970 dhcp_delete_msg(dhcp); 802c7c8: 4620 mov r0, r4 802c7ca: f7ff fc05 bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_decline: BACKING OFF\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_decline: could not allocate DHCP request\n")); } dhcp->tries++; 802c7ce: 7b63 ldrb r3, [r4, #13] 802c7d0: 3301 adds r3, #1 802c7d2: 7363 strb r3, [r4, #13] msecs = 10*1000; dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c7d4: 2314 movs r3, #20 802c7d6: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE | LWIP_DBG_LEVEL_WARNING, ("dhcp_arp_reply(): arp reply matched with offered address, declining\n")); dhcp_decline(netif); } } } 802c7d8: bd3e pop {r1, r2, r3, r4, r5, pc} 802c7da: bf00 nop 802c7dc: 0803fe84 .word 0x0803fe84 0802c7e0 : * * @param netif network interface which must renew its lease */ err_t dhcp_renew(struct netif *netif) { 802c7e0: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802c7e2: 6a04 ldr r4, [r0, #32] * * @param netif network interface which must renew its lease */ err_t dhcp_renew(struct netif *netif) { 802c7e4: 4605 mov r5, r0 struct dhcp *dhcp = netif->dhcp; err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_renew()\n")); dhcp_set_state(dhcp, DHCP_RENEWING); 802c7e6: 2105 movs r1, #5 802c7e8: 4620 mov r0, r4 802c7ea: f7ff faf1 bl 802bdd0 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_REQUEST); 802c7ee: 4628 mov r0, r5 802c7f0: 4621 mov r1, r4 802c7f2: 2203 movs r2, #3 802c7f4: f7ff fb50 bl 802be98 if (result == ERR_OK) { 802c7f8: 4606 mov r6, r0 802c7fa: b9e0 cbnz r0, 802c836 dhcp_option(dhcp, DHCP_OPTION_MAX_MSG_SIZE, DHCP_OPTION_MAX_MSG_SIZE_LEN); 802c7fc: 2202 movs r2, #2 802c7fe: 4620 mov r0, r4 802c800: 2139 movs r1, #57 ; 0x39 802c802: f7ff faed bl 802bde0 dhcp_option_short(dhcp, DHCP_MAX_MSG_LEN(netif)); 802c806: 8ca9 ldrh r1, [r5, #36] ; 0x24 802c808: 4620 mov r0, r4 802c80a: f7ff fb00 bl 802be0e #if LWIP_NETIF_HOSTNAME dhcp_option_hostname(dhcp, netif); #endif /* LWIP_NETIF_HOSTNAME */ /* append DHCP message trailer */ dhcp_option_trailer(dhcp); 802c80e: 4620 mov r0, r4 802c810: f7ff fb2d bl 802be6e pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c814: 8b21 ldrh r1, [r4, #24] 802c816: 6920 ldr r0, [r4, #16] 802c818: 31f0 adds r1, #240 ; 0xf0 802c81a: b289 uxth r1, r1 802c81c: f000 fc2f bl 802d07e udp_sendto_if(dhcp->pcb, dhcp->p_out, &dhcp->server_ip_addr, DHCP_SERVER_PORT, netif); 802c820: 9500 str r5, [sp, #0] 802c822: 6860 ldr r0, [r4, #4] 802c824: 6921 ldr r1, [r4, #16] 802c826: f104 0220 add.w r2, r4, #32 802c82a: 2343 movs r3, #67 ; 0x43 802c82c: f003 f8a0 bl 802f970 dhcp_delete_msg(dhcp); 802c830: 4620 mov r0, r4 802c832: f7ff fbd1 bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_renew: RENEWING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_renew: could not allocate DHCP request\n")); } dhcp->tries++; 802c836: 7b63 ldrb r3, [r4, #13] 802c838: 3301 adds r3, #1 802c83a: b2db uxtb r3, r3 /* back-off on retries, but to a maximum of 20 seconds */ msecs = dhcp->tries < 10 ? dhcp->tries * 2000 : 20 * 1000; 802c83c: 2b09 cmp r3, #9 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_renew: RENEWING\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_renew: could not allocate DHCP request\n")); } dhcp->tries++; 802c83e: 7363 strb r3, [r4, #13] /* back-off on retries, but to a maximum of 20 seconds */ msecs = dhcp->tries < 10 ? dhcp->tries * 2000 : 20 * 1000; 802c840: d804 bhi.n 802c84c 802c842: f44f 62fa mov.w r2, #2000 ; 0x7d0 802c846: 4353 muls r3, r2 802c848: b29b uxth r3, r3 802c84a: e001 b.n 802c850 802c84c: f644 6320 movw r3, #20000 ; 0x4e20 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c850: f44f 72fa mov.w r2, #500 ; 0x1f4 802c854: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c858: fb93 f3f2 sdiv r3, r3, r2 802c85c: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_renew(): set request timeout %"U16_F" msecs\n", msecs)); return result; } 802c85e: 4630 mov r0, r6 802c860: bd7c pop {r2, r3, r4, r5, r6, pc} 802c862: 0000 movs r0, r0 0802c864 : /** * The DHCP timer that checks for lease renewal/rebind timeouts. */ void dhcp_coarse_tmr() { 802c864: b538 push {r3, r4, r5, lr} struct netif *netif = netif_list; 802c866: 4b15 ldr r3, [pc, #84] ; (802c8bc ) 802c868: 4d15 ldr r5, [pc, #84] ; (802c8c0 ) 802c86a: 681c ldr r4, [r3, #0] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_coarse_tmr()\n")); /* iterate through all network interfaces */ while (netif != NULL) { 802c86c: e023 b.n 802c8b6 /* only act on DHCP configured interfaces */ if (netif->dhcp != NULL) { 802c86e: 6a23 ldr r3, [r4, #32] 802c870: b303 cbz r3, 802c8b4 /* timer is active (non zero), and triggers (zeroes) now? */ if (netif->dhcp->t2_timeout-- == 1) { 802c872: 8bda ldrh r2, [r3, #30] 802c874: 1e51 subs r1, r2, #1 802c876: 2a01 cmp r2, #1 802c878: 83d9 strh r1, [r3, #30] 802c87a: d10b bne.n 802c894 802c87c: 7b1a ldrb r2, [r3, #12] 802c87e: 2a0a cmp r2, #10 802c880: d818 bhi.n 802c8b4 802c882: f993 300c ldrsb.w r3, [r3, #12] 802c886: fa15 f303 lsls.w r3, r5, r3 802c88a: d513 bpl.n 802c8b4 /* just retry to rebind */ LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_t2_timeout(): must rebind\n")); /* This slightly different to RFC2131: DHCPREQUEST will be sent from state DHCP_REBINDING, not DHCP_BOUND */ dhcp_rebind(netif); 802c88c: 4620 mov r0, r4 802c88e: f7ff fc0b bl 802c0a8 802c892: e00f b.n 802c8b4 if (netif->dhcp->t2_timeout-- == 1) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_coarse_tmr(): t2 timeout\n")); /* this clients' rebind timeout triggered */ dhcp_t2_timeout(netif); /* timer is active (non zero), and triggers (zeroes) now */ } else if (netif->dhcp->t1_timeout-- == 1) { 802c894: 8b9a ldrh r2, [r3, #28] 802c896: 1e51 subs r1, r2, #1 802c898: 2a01 cmp r2, #1 802c89a: 8399 strh r1, [r3, #28] 802c89c: d10a bne.n 802c8b4 802c89e: 7b1a ldrb r2, [r3, #12] 802c8a0: 2a0a cmp r2, #10 802c8a2: d807 bhi.n 802c8b4 802c8a4: f993 300c ldrsb.w r3, [r3, #12] 802c8a8: fa15 f303 lsls.w r3, r5, r3 802c8ac: d502 bpl.n 802c8b4 * eventually time-out if renew tries fail. */ LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_t1_timeout(): must renew\n")); /* This slightly different to RFC2131: DHCPREQUEST will be sent from state DHCP_RENEWING, not DHCP_BOUND */ dhcp_renew(netif); 802c8ae: 4620 mov r0, r4 802c8b0: f7ff ff96 bl 802c7e0 /* this clients' renewal timeout triggered */ dhcp_t1_timeout(netif); } } /* proceed to next netif */ netif = netif->next; 802c8b4: 6824 ldr r4, [r4, #0] dhcp_coarse_tmr() { struct netif *netif = netif_list; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_coarse_tmr()\n")); /* iterate through all network interfaces */ while (netif != NULL) { 802c8b6: 2c00 cmp r4, #0 802c8b8: d1d9 bne.n 802c86e } } /* proceed to next netif */ netif = netif->next; } } 802c8ba: bd38 pop {r3, r4, r5, pc} 802c8bc: 20010fd0 .word 0x20010fd0 802c8c0: 44200000 .word 0x44200000 0802c8c4 : * * @param netif network interface which must release its lease */ err_t dhcp_release(struct netif *netif) { 802c8c4: b573 push {r0, r1, r4, r5, r6, lr} struct dhcp *dhcp = netif->dhcp; 802c8c6: 6a04 ldr r4, [r0, #32] * * @param netif network interface which must release its lease */ err_t dhcp_release(struct netif *netif) { 802c8c8: 4605 mov r5, r0 err_t result; u16_t msecs; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_release()\n")); /* idle DHCP client */ dhcp_set_state(dhcp, DHCP_OFF); 802c8ca: 2100 movs r1, #0 802c8cc: 4620 mov r0, r4 802c8ce: f7ff fa7f bl 802bdd0 /* clean old DHCP offer */ ip_addr_set_zero(&dhcp->server_ip_addr); 802c8d2: 2300 movs r3, #0 802c8d4: 6223 str r3, [r4, #32] ip_addr_set_zero(&dhcp->offered_ip_addr); 802c8d6: 6263 str r3, [r4, #36] ; 0x24 ip_addr_set_zero(&dhcp->offered_sn_mask); 802c8d8: 62a3 str r3, [r4, #40] ; 0x28 ip_addr_set_zero(&dhcp->offered_gw_addr); 802c8da: 62e3 str r3, [r4, #44] ; 0x2c #if LWIP_DHCP_BOOTP_FILE ip_addr_set_zero(&dhcp->offered_si_addr); #endif /* LWIP_DHCP_BOOTP_FILE */ dhcp->offered_t0_lease = dhcp->offered_t1_renew = dhcp->offered_t2_rebind = 0; 802c8dc: 63a3 str r3, [r4, #56] ; 0x38 802c8de: 6363 str r3, [r4, #52] ; 0x34 802c8e0: 6323 str r3, [r4, #48] ; 0x30 /* create and initialize the DHCP message header */ result = dhcp_create_msg(netif, dhcp, DHCP_RELEASE); 802c8e2: 4628 mov r0, r5 802c8e4: 4621 mov r1, r4 802c8e6: 2207 movs r2, #7 802c8e8: f7ff fad6 bl 802be98 if (result == ERR_OK) { 802c8ec: 4606 mov r6, r0 802c8ee: b998 cbnz r0, 802c918 dhcp_option_trailer(dhcp); 802c8f0: 4620 mov r0, r4 802c8f2: f7ff fabc bl 802be6e pbuf_realloc(dhcp->p_out, sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + dhcp->options_out_len); 802c8f6: 8b21 ldrh r1, [r4, #24] 802c8f8: 6920 ldr r0, [r4, #16] 802c8fa: 31f0 adds r1, #240 ; 0xf0 802c8fc: b289 uxth r1, r1 802c8fe: f000 fbbe bl 802d07e udp_sendto_if(dhcp->pcb, dhcp->p_out, &dhcp->server_ip_addr, DHCP_SERVER_PORT, netif); 802c902: 9500 str r5, [sp, #0] 802c904: 6860 ldr r0, [r4, #4] 802c906: 6921 ldr r1, [r4, #16] 802c908: f104 0220 add.w r2, r4, #32 802c90c: 2343 movs r3, #67 ; 0x43 802c90e: f003 f82f bl 802f970 dhcp_delete_msg(dhcp); 802c912: 4620 mov r0, r4 802c914: f7ff fb60 bl 802bfd8 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_release: RELEASED, DHCP_OFF\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_release: could not allocate DHCP request\n")); } dhcp->tries++; 802c918: 7b63 ldrb r3, [r4, #13] 802c91a: 3301 adds r3, #1 802c91c: b2db uxtb r3, r3 msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c91e: 2b09 cmp r3, #9 dhcp_delete_msg(dhcp); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_release: RELEASED, DHCP_OFF\n")); } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("dhcp_release: could not allocate DHCP request\n")); } dhcp->tries++; 802c920: 7363 strb r3, [r4, #13] msecs = dhcp->tries < 10 ? dhcp->tries * 1000 : 10 * 1000; 802c922: d804 bhi.n 802c92e 802c924: f44f 727a mov.w r2, #1000 ; 0x3e8 802c928: 4353 muls r3, r2 802c92a: b29b uxth r3, r3 802c92c: e001 b.n 802c932 802c92e: f242 7310 movw r3, #10000 ; 0x2710 dhcp->request_timeout = (msecs + DHCP_FINE_TIMER_MSECS - 1) / DHCP_FINE_TIMER_MSECS; 802c932: f44f 72fa mov.w r2, #500 ; 0x1f4 802c936: f203 13f3 addw r3, r3, #499 ; 0x1f3 802c93a: fb93 f3f2 sdiv r3, r3, r2 802c93e: 8363 strh r3, [r4, #26] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_release(): set request timeout %"U16_F" msecs\n", msecs)); /* bring the interface down */ netif_set_down(netif); 802c940: 4628 mov r0, r5 802c942: f000 fb31 bl 802cfa8 /* remove IP address from interface */ netif_set_ipaddr(netif, IP_ADDR_ANY); 802c946: 4628 mov r0, r5 802c948: 4906 ldr r1, [pc, #24] ; (802c964 ) 802c94a: f000 fa7d bl 802ce48 netif_set_gw(netif, IP_ADDR_ANY); 802c94e: 4628 mov r0, r5 802c950: 4904 ldr r1, [pc, #16] ; (802c964 ) 802c952: f000 fab5 bl 802cec0 netif_set_netmask(netif, IP_ADDR_ANY); 802c956: 4628 mov r0, r5 802c958: 4902 ldr r1, [pc, #8] ; (802c964 ) 802c95a: f000 fab5 bl 802cec8 return result; } 802c95e: 4630 mov r0, r6 802c960: bd7c pop {r2, r3, r4, r5, r6, pc} 802c962: bf00 nop 802c964: 0803fe88 .word 0x0803fe88 0802c968 : * A DHCP server is expected to respond within a short period of time. * This timer checks whether an outstanding DHCP request is timed out. */ void dhcp_fine_tmr() { 802c968: b538 push {r3, r4, r5, lr} struct netif *netif = netif_list; 802c96a: 4b26 ldr r3, [pc, #152] ; (802ca04 ) /* timer is active (non zero), and is about to trigger now */ if (netif->dhcp->request_timeout > 1) { netif->dhcp->request_timeout--; } else if (netif->dhcp->request_timeout == 1) { netif->dhcp->request_timeout--; 802c96c: 2500 movs r5, #0 * This timer checks whether an outstanding DHCP request is timed out. */ void dhcp_fine_tmr() { struct netif *netif = netif_list; 802c96e: 681c ldr r4, [r3, #0] /* loop through netif's */ while (netif != NULL) { 802c970: e044 b.n 802c9fc /* only act on DHCP configured interfaces */ if (netif->dhcp != NULL) { 802c972: 6a23 ldr r3, [r4, #32] 802c974: 2b00 cmp r3, #0 802c976: d040 beq.n 802c9fa /* timer is active (non zero), and is about to trigger now */ if (netif->dhcp->request_timeout > 1) { 802c978: 8b5a ldrh r2, [r3, #26] 802c97a: 2a01 cmp r2, #1 802c97c: d902 bls.n 802c984 netif->dhcp->request_timeout--; 802c97e: 3a01 subs r2, #1 802c980: 835a strh r2, [r3, #26] 802c982: e03a b.n 802c9fa } else if (netif->dhcp->request_timeout == 1) { 802c984: d139 bne.n 802c9fa dhcp_timeout(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_timeout()\n")); /* back-off period has passed, or server selection timed out */ if ((dhcp->state == DHCP_BACKING_OFF) || (dhcp->state == DHCP_SELECTING)) { 802c986: 7b1a ldrb r2, [r3, #12] /* timer is active (non zero), and is about to trigger now */ if (netif->dhcp->request_timeout > 1) { netif->dhcp->request_timeout--; } else if (netif->dhcp->request_timeout == 1) { netif->dhcp->request_timeout--; 802c988: 835d strh r5, [r3, #26] dhcp_timeout(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_timeout()\n")); /* back-off period has passed, or server selection timed out */ if ((dhcp->state == DHCP_BACKING_OFF) || (dhcp->state == DHCP_SELECTING)) { 802c98a: 2a0c cmp r2, #12 802c98c: d028 beq.n 802c9e0 802c98e: 2a06 cmp r2, #6 802c990: d100 bne.n 802c994 802c992: e025 b.n 802c9e0 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_timeout(): restarting discovery\n")); dhcp_discover(netif); /* receiving the requested lease timed out */ } else if (dhcp->state == DHCP_REQUESTING) { 802c994: 2a01 cmp r2, #1 802c996: d106 bne.n 802c9a6 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): REQUESTING, DHCP request timed out\n")); if (dhcp->tries <= 5) { 802c998: 7b5b ldrb r3, [r3, #13] 802c99a: 2b05 cmp r3, #5 dhcp_select(netif); 802c99c: 4620 mov r0, r4 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_timeout(): restarting discovery\n")); dhcp_discover(netif); /* receiving the requested lease timed out */ } else if (dhcp->state == DHCP_REQUESTING) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): REQUESTING, DHCP request timed out\n")); if (dhcp->tries <= 5) { 802c99e: d81d bhi.n 802c9dc dhcp_select(netif); 802c9a0: f7ff fc14 bl 802c1cc 802c9a4: e029 b.n 802c9fa dhcp_release(netif); dhcp_discover(netif); } #if DHCP_DOES_ARP_CHECK /* received no ARP reply for the offered address (which is good) */ } else if (dhcp->state == DHCP_CHECKING) { 802c9a6: 2a08 cmp r2, #8 802c9a8: d109 bne.n 802c9be LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): CHECKING, ARP request timed out\n")); if (dhcp->tries <= 1) { 802c9aa: 7b5b ldrb r3, [r3, #13] 802c9ac: 2b01 cmp r3, #1 dhcp_check(netif); 802c9ae: 4620 mov r0, r4 } #if DHCP_DOES_ARP_CHECK /* received no ARP reply for the offered address (which is good) */ } else if (dhcp->state == DHCP_CHECKING) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): CHECKING, ARP request timed out\n")); if (dhcp->tries <= 1) { 802c9b0: d802 bhi.n 802c9b8 dhcp_check(netif); 802c9b2: f7ff fc7d bl 802c2b0 802c9b6: e020 b.n 802c9fa /* no ARP replies on the offered address, looks like the IP address is indeed free */ } else { /* bind the interface to the offered address */ dhcp_bind(netif); 802c9b8: f7ff fc8d bl 802c2d6 802c9bc: e01d b.n 802c9fa } #endif /* DHCP_DOES_ARP_CHECK */ } /* did not get response to renew request? */ else if (dhcp->state == DHCP_RENEWING) { 802c9be: 2a05 cmp r2, #5 802c9c0: d103 bne.n 802c9ca LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): RENEWING, DHCP request timed out\n")); /* just retry renewal */ /* note that the rebind timer will eventually time-out if renew does not work */ dhcp_renew(netif); 802c9c2: 4620 mov r0, r4 802c9c4: f7ff ff0c bl 802c7e0 802c9c8: e017 b.n 802c9fa /* did not get response to rebind request? */ } else if (dhcp->state == DHCP_REBINDING) { 802c9ca: 2a04 cmp r2, #4 802c9cc: d10a bne.n 802c9e4 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): REBINDING, DHCP request timed out\n")); if (dhcp->tries <= 8) { 802c9ce: 7b5b ldrb r3, [r3, #13] 802c9d0: 2b08 cmp r3, #8 dhcp_rebind(netif); 802c9d2: 4620 mov r0, r4 /* note that the rebind timer will eventually time-out if renew does not work */ dhcp_renew(netif); /* did not get response to rebind request? */ } else if (dhcp->state == DHCP_REBINDING) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): REBINDING, DHCP request timed out\n")); if (dhcp->tries <= 8) { 802c9d4: d802 bhi.n 802c9dc dhcp_rebind(netif); 802c9d6: f7ff fb67 bl 802c0a8 802c9da: e00e b.n 802c9fa } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): RELEASING, DISCOVERING\n")); dhcp_release(netif); 802c9dc: f7ff ff72 bl 802c8c4 dhcp_discover(netif); 802c9e0: 4620 mov r0, r4 802c9e2: e008 b.n 802c9f6 } } else if (dhcp->state == DHCP_REBOOTING) { 802c9e4: 2a03 cmp r2, #3 802c9e6: d108 bne.n 802c9fa if (dhcp->tries < REBOOT_TRIES) { 802c9e8: 7b5b ldrb r3, [r3, #13] 802c9ea: 2b01 cmp r3, #1 dhcp_reboot(netif); 802c9ec: 4620 mov r0, r4 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_timeout(): RELEASING, DISCOVERING\n")); dhcp_release(netif); dhcp_discover(netif); } } else if (dhcp->state == DHCP_REBOOTING) { if (dhcp->tries < REBOOT_TRIES) { 802c9ee: d802 bhi.n 802c9f6 dhcp_reboot(netif); 802c9f0: f7ff fb9c bl 802c12c 802c9f4: e001 b.n 802c9fa } else { dhcp_discover(netif); 802c9f6: f7ff fafb bl 802bff0 /* this client's request timeout triggered */ dhcp_timeout(netif); } } /* proceed to next network interface */ netif = netif->next; 802c9fa: 6824 ldr r4, [r4, #0] void dhcp_fine_tmr() { struct netif *netif = netif_list; /* loop through netif's */ while (netif != NULL) { 802c9fc: 2c00 cmp r4, #0 802c9fe: d1b8 bne.n 802c972 } } /* proceed to next network interface */ netif = netif->next; } } 802ca00: bd38 pop {r3, r4, r5, pc} 802ca02: bf00 nop 802ca04: 20010fd0 .word 0x20010fd0 0802ca08 : * * @param netif The network interface to stop DHCP on */ void dhcp_stop(struct netif *netif) { 802ca08: b510 push {r4, lr} struct dhcp *dhcp; LWIP_ERROR("dhcp_stop: netif != NULL", (netif != NULL), return;); 802ca0a: b198 cbz r0, 802ca34 dhcp = netif->dhcp; /* Remove the flag that says this netif is handled by DHCP. */ netif->flags &= ~NETIF_FLAG_DHCP; 802ca0c: f890 302d ldrb.w r3, [r0, #45] ; 0x2d void dhcp_stop(struct netif *netif) { struct dhcp *dhcp; LWIP_ERROR("dhcp_stop: netif != NULL", (netif != NULL), return;); dhcp = netif->dhcp; 802ca10: 6a04 ldr r4, [r0, #32] /* Remove the flag that says this netif is handled by DHCP. */ netif->flags &= ~NETIF_FLAG_DHCP; 802ca12: f023 0308 bic.w r3, r3, #8 802ca16: f880 302d strb.w r3, [r0, #45] ; 0x2d LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_stop()\n")); /* netif is DHCP configured? */ if (dhcp != NULL) { 802ca1a: b15c cbz r4, 802ca34 autoip_stop(netif); dhcp->autoip_coop_state = DHCP_AUTOIP_COOP_STATE_OFF; } #endif /* LWIP_DHCP_AUTOIP_COOP */ if (dhcp->pcb != NULL) { 802ca1c: 6860 ldr r0, [r4, #4] 802ca1e: b118 cbz r0, 802ca28 udp_remove(dhcp->pcb); 802ca20: f003 f852 bl 802fac8 dhcp->pcb = NULL; 802ca24: 2300 movs r3, #0 802ca26: 6063 str r3, [r4, #4] } LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL); dhcp_set_state(dhcp, DHCP_OFF); 802ca28: 4620 mov r0, r4 802ca2a: 2100 movs r1, #0 } } 802ca2c: e8bd 4010 ldmia.w sp!, {r4, lr} if (dhcp->pcb != NULL) { udp_remove(dhcp->pcb); dhcp->pcb = NULL; } LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL); dhcp_set_state(dhcp, DHCP_OFF); 802ca30: f7ff b9ce b.w 802bdd0 802ca34: bd10 pop {r4, pc} 802ca36: 0000 movs r0, r0 0802ca38 : * - ERR_OK - No error * - ERR_MEM - Out of memory */ err_t dhcp_start(struct netif *netif) { 802ca38: b538 push {r3, r4, r5, lr} struct dhcp *dhcp; err_t result = ERR_OK; LWIP_ERROR("netif != NULL", (netif != NULL), return ERR_ARG;); 802ca3a: 4604 mov r4, r0 802ca3c: b908 cbnz r0, 802ca42 802ca3e: 20f2 movs r0, #242 ; 0xf2 802ca40: e047 b.n 802cad2 dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_start(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* Remove the flag that says this netif is handled by DHCP, it is set when we succeeded starting. */ netif->flags &= ~NETIF_FLAG_DHCP; 802ca42: f890 302d ldrb.w r3, [r0, #45] ; 0x2d { struct dhcp *dhcp; err_t result = ERR_OK; LWIP_ERROR("netif != NULL", (netif != NULL), return ERR_ARG;); dhcp = netif->dhcp; 802ca46: 6a05 ldr r5, [r0, #32] LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_start(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* Remove the flag that says this netif is handled by DHCP, it is set when we succeeded starting. */ netif->flags &= ~NETIF_FLAG_DHCP; 802ca48: f023 0208 bic.w r2, r3, #8 /* check hwtype of the netif */ if ((netif->flags & NETIF_FLAG_ETHARP) == 0) { 802ca4c: f003 0320 and.w r3, r3, #32 802ca50: b2db uxtb r3, r3 LWIP_ERROR("netif != NULL", (netif != NULL), return ERR_ARG;); dhcp = netif->dhcp; LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_start(netif=%p) %c%c%"U16_F"\n", (void*)netif, netif->name[0], netif->name[1], (u16_t)netif->num)); /* Remove the flag that says this netif is handled by DHCP, it is set when we succeeded starting. */ netif->flags &= ~NETIF_FLAG_DHCP; 802ca52: f880 202d strb.w r2, [r0, #45] ; 0x2d /* check hwtype of the netif */ if ((netif->flags & NETIF_FLAG_ETHARP) == 0) { 802ca56: 2b00 cmp r3, #0 802ca58: d0f1 beq.n 802ca3e LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): No ETHARP netif\n")); return ERR_ARG; } /* check MTU of the netif */ if (netif->mtu < DHCP_MAX_MSG_LEN_MIN_REQUIRED) { 802ca5a: 8c83 ldrh r3, [r0, #36] ; 0x24 802ca5c: f5b3 7f10 cmp.w r3, #576 ; 0x240 802ca60: d200 bcs.n 802ca64 802ca62: e02e b.n 802cac2 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): Cannot use this netif with DHCP: MTU is too small\n")); return ERR_MEM; } /* no DHCP client attached yet? */ if (dhcp == NULL) { 802ca64: b935 cbnz r5, 802ca74 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): starting new DHCP client\n")); dhcp = (struct dhcp *)mem_malloc(sizeof(struct dhcp)); 802ca66: 203c movs r0, #60 ; 0x3c 802ca68: f000 f938 bl 802ccdc if (dhcp == NULL) { 802ca6c: 4605 mov r5, r0 802ca6e: b340 cbz r0, 802cac2 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): could not allocate dhcp\n")); return ERR_MEM; } /* store this dhcp client in the netif */ netif->dhcp = dhcp; 802ca70: 6220 str r0, [r4, #32] 802ca72: e003 b.n 802ca7c LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): allocated dhcp")); /* already has DHCP client attached */ } else { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_start(): restarting DHCP configuration\n")); if (dhcp->pcb != NULL) { 802ca74: 6868 ldr r0, [r5, #4] 802ca76: b108 cbz r0, 802ca7c udp_remove(dhcp->pcb); 802ca78: f003 f826 bl 802fac8 LWIP_ASSERT("pbuf p_out wasn't freed", dhcp->p_out == NULL); LWIP_ASSERT("reply wasn't freed", dhcp->msg_in == NULL ); } /* clear data structure */ memset(dhcp, 0, sizeof(struct dhcp)); 802ca7c: 2100 movs r1, #0 802ca7e: 223c movs r2, #60 ; 0x3c 802ca80: 4628 mov r0, r5 802ca82: f7f5 f81d bl 8021ac0 /* dhcp_set_state(&dhcp, DHCP_OFF); */ /* allocate UDP PCB */ dhcp->pcb = udp_new(); 802ca86: f003 f83b bl 802fb00 802ca8a: 6068 str r0, [r5, #4] if (dhcp->pcb == NULL) { 802ca8c: b1c8 cbz r0, 802cac2 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): could not obtain pcb\n")); return ERR_MEM; } ip_set_option(dhcp->pcb, SOF_BROADCAST); 802ca8e: 7a03 ldrb r3, [r0, #8] /* set up local and remote port for the pcb */ udp_bind(dhcp->pcb, IP_ADDR_ANY, DHCP_CLIENT_PORT); 802ca90: 4911 ldr r1, [pc, #68] ; (802cad8 ) dhcp->pcb = udp_new(); if (dhcp->pcb == NULL) { LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): could not obtain pcb\n")); return ERR_MEM; } ip_set_option(dhcp->pcb, SOF_BROADCAST); 802ca92: f043 0320 orr.w r3, r3, #32 802ca96: 7203 strb r3, [r0, #8] /* set up local and remote port for the pcb */ udp_bind(dhcp->pcb, IP_ADDR_ANY, DHCP_CLIENT_PORT); 802ca98: 2244 movs r2, #68 ; 0x44 802ca9a: 6868 ldr r0, [r5, #4] 802ca9c: f002 ff18 bl 802f8d0 udp_connect(dhcp->pcb, IP_ADDR_ANY, DHCP_SERVER_PORT); 802caa0: 490d ldr r1, [pc, #52] ; (802cad8 ) 802caa2: 6868 ldr r0, [r5, #4] 802caa4: 2243 movs r2, #67 ; 0x43 802caa6: f002 ffdd bl 802fa64 /* set up the recv callback and argument */ udp_recv(dhcp->pcb, dhcp_recv, netif); 802caaa: 6868 ldr r0, [r5, #4] 802caac: 490b ldr r1, [pc, #44] ; (802cadc ) 802caae: 4622 mov r2, r4 802cab0: f003 f806 bl 802fac0 LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE, ("dhcp_start(): starting DHCP configuration\n")); /* (re)start the DHCP negotiation */ result = dhcp_discover(netif); 802cab4: 4620 mov r0, r4 802cab6: f7ff fa9b bl 802bff0 if (result != ERR_OK) { 802caba: b120 cbz r0, 802cac6 /* free resources allocated above */ dhcp_stop(netif); 802cabc: 4620 mov r0, r4 802cabe: f7ff ffa3 bl 802ca08 return ERR_MEM; 802cac2: 20ff movs r0, #255 ; 0xff 802cac4: e005 b.n 802cad2 } /* Set the flag that says this netif is handled by DHCP. */ netif->flags |= NETIF_FLAG_DHCP; 802cac6: f894 302d ldrb.w r3, [r4, #45] ; 0x2d 802caca: f043 0308 orr.w r3, r3, #8 802cace: f884 302d strb.w r3, [r4, #45] ; 0x2d return result; } 802cad2: b240 sxtb r0, r0 802cad4: bd38 pop {r3, r4, r5, pc} 802cad6: bf00 nop 802cad8: 0803fe88 .word 0x0803fe88 802cadc: 0802c395 .word 0x0802c395 0802cae0 : /** * Perform Sanity check of user-configurable values, and initialize all modules. */ void lwip_init(void) { 802cae0: b508 push {r3, lr} /* Modules initialization */ stats_init(); #if !NO_SYS sys_init(); 802cae2: f007 ff0f bl 8034904 #endif /* !NO_SYS */ mem_init(); 802cae6: f000 f80f bl 802cb08 memp_init(); 802caea: f000 f95b bl 802cda4 pbuf_init(); netif_init(); 802caee: f000 f9a9 bl 802ce44 #endif /* LWIP_ARP */ #if LWIP_RAW raw_init(); #endif /* LWIP_RAW */ #if LWIP_UDP udp_init(); 802caf2: f002 fe27 bl 802f744 #endif /* LWIP_UDP */ #if LWIP_TCP tcp_init(); 802caf6: f000 fc8b bl 802d410 #endif /* LWIP_TCP */ #if LWIP_SNMP snmp_init(); 802cafa: f005 fdc5 bl 8032688 #endif /* LWIP_DNS */ #if LWIP_TIMERS sys_timeouts_init(); #endif /* LWIP_TIMERS */ } 802cafe: e8bd 4008 ldmia.w sp!, {r3, lr} #if LWIP_DNS dns_init(); #endif /* LWIP_DNS */ #if LWIP_TIMERS sys_timeouts_init(); 802cb02: f002 bd49 b.w 802f598 802cb06: 0000 movs r0, r0 0802cb08 : LWIP_ASSERT("Sanity check alignment", (SIZEOF_STRUCT_MEM & (MEM_ALIGNMENT-1)) == 0); /* align the heap */ ram = (u8_t *)LWIP_MEM_ALIGN(LWIP_RAM_HEAP_POINTER); 802cb08: 4b0b ldr r3, [pc, #44] ; (802cb38 ) 802cb0a: 4a0c ldr r2, [pc, #48] ; (802cb3c ) mem = (struct mem *)(void *)ram; mem->next = MEM_SIZE_ALIGNED; mem->prev = 0; mem->used = 0; /* initialize the end of the heap */ ram_end = (struct mem *)(void *)&ram[MEM_SIZE_ALIGNED]; 802cb0c: 480c ldr r0, [pc, #48] ; (802cb40 ) LWIP_ASSERT("Sanity check alignment", (SIZEOF_STRUCT_MEM & (MEM_ALIGNMENT-1)) == 0); /* align the heap */ ram = (u8_t *)LWIP_MEM_ALIGN(LWIP_RAM_HEAP_POINTER); 802cb0e: f023 0303 bic.w r3, r3, #3 802cb12: 6013 str r3, [r2, #0] /* initialize the start of the heap */ mem = (struct mem *)(void *)ram; mem->next = MEM_SIZE_ALIGNED; 802cb14: f44f 51a0 mov.w r1, #5120 ; 0x1400 mem->prev = 0; 802cb18: 2200 movs r2, #0 802cb1a: 805a strh r2, [r3, #2] mem->used = 0; 802cb1c: 711a strb r2, [r3, #4] /* initialize the end of the heap */ ram_end = (struct mem *)(void *)&ram[MEM_SIZE_ALIGNED]; 802cb1e: 185a adds r2, r3, r1 802cb20: 6002 str r2, [r0, #0] ram_end->used = 1; 802cb22: 2001 movs r0, #1 802cb24: 7110 strb r0, [r2, #4] ram_end->next = MEM_SIZE_ALIGNED; ram_end->prev = MEM_SIZE_ALIGNED; 802cb26: 8051 strh r1, [r2, #2] /* align the heap */ ram = (u8_t *)LWIP_MEM_ALIGN(LWIP_RAM_HEAP_POINTER); /* initialize the start of the heap */ mem = (struct mem *)(void *)ram; mem->next = MEM_SIZE_ALIGNED; 802cb28: 8019 strh r1, [r3, #0] /* initialize the lowest-free pointer to the start of the heap */ lfree = (struct mem *)(void *)ram; MEM_STATS_AVAIL(avail, MEM_SIZE_ALIGNED); if(sys_mutex_new(&mem_mutex) != ERR_OK) { 802cb2a: 4806 ldr r0, [pc, #24] ; (802cb44 ) mem->prev = 0; mem->used = 0; /* initialize the end of the heap */ ram_end = (struct mem *)(void *)&ram[MEM_SIZE_ALIGNED]; ram_end->used = 1; ram_end->next = MEM_SIZE_ALIGNED; 802cb2c: 8011 strh r1, [r2, #0] ram_end->prev = MEM_SIZE_ALIGNED; /* initialize the lowest-free pointer to the start of the heap */ lfree = (struct mem *)(void *)ram; 802cb2e: 4a06 ldr r2, [pc, #24] ; (802cb48 ) 802cb30: 6013 str r3, [r2, #0] MEM_STATS_AVAIL(avail, MEM_SIZE_ALIGNED); if(sys_mutex_new(&mem_mutex) != ERR_OK) { 802cb32: f007 bec9 b.w 80348c8 802cb36: bf00 nop 802cb38: 2000fbbf .word 0x2000fbbf 802cb3c: 20002a60 .word 0x20002a60 802cb40: 20002a58 .word 0x20002a58 802cb44: 20002a5c .word 0x20002a5c 802cb48: 20002a54 .word 0x20002a54 0802cb4c : * @param rmem is the data portion of a struct mem as returned by a previous * call to mem_malloc() */ void mem_free(void *rmem) { 802cb4c: b570 push {r4, r5, r6, lr} struct mem *mem; LWIP_MEM_FREE_DECL_PROTECT(); if (rmem == NULL) { 802cb4e: 4604 mov r4, r0 802cb50: 2800 cmp r0, #0 802cb52: d04c beq.n 802cbee LWIP_ASSERT("mem_free: sanity check alignment", (((mem_ptr_t)rmem) & (MEM_ALIGNMENT-1)) == 0); LWIP_ASSERT("mem_free: legal memory", (u8_t *)rmem >= (u8_t *)ram && (u8_t *)rmem < (u8_t *)ram_end); if ((u8_t *)rmem < (u8_t *)ram || (u8_t *)rmem >= (u8_t *)ram_end) { 802cb54: 4b26 ldr r3, [pc, #152] ; (802cbf0 ) 802cb56: 681b ldr r3, [r3, #0] 802cb58: 4298 cmp r0, r3 802cb5a: d303 bcc.n 802cb64 802cb5c: 4b25 ldr r3, [pc, #148] ; (802cbf4 ) 802cb5e: 681b ldr r3, [r3, #0] 802cb60: 4298 cmp r0, r3 802cb62: d305 bcc.n 802cb70 SYS_ARCH_DECL_PROTECT(lev); LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SEVERE, ("mem_free: illegal memory\n")); /* protect mem stats from concurrent access */ SYS_ARCH_PROTECT(lev); 802cb64: f007 fee8 bl 8034938 plug_holes(mem); #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_free_count = 1; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_FREE_UNPROTECT(); } 802cb68: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} SYS_ARCH_DECL_PROTECT(lev); LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SEVERE, ("mem_free: illegal memory\n")); /* protect mem stats from concurrent access */ SYS_ARCH_PROTECT(lev); MEM_STATS_INC(illegal); SYS_ARCH_UNPROTECT(lev); 802cb6c: f007 beee b.w 803494c return; } /* protect the heap from concurrent access */ LWIP_MEM_FREE_PROTECT(); 802cb70: 4821 ldr r0, [pc, #132] ; (802cbf8 ) 802cb72: f007 feb5 bl 80348e0 /* Get the corresponding struct mem ... */ mem = (struct mem *)(void *)((u8_t *)rmem - SIZEOF_STRUCT_MEM); /* ... which has to be in a used state ... */ LWIP_ASSERT("mem_free: mem->used", mem->used); /* ... and is now unused. */ mem->used = 0; 802cb76: 2300 movs r3, #0 802cb78: f804 3c04 strb.w r3, [r4, #-4] if (mem < lfree) { 802cb7c: 4b1f ldr r3, [pc, #124] ; (802cbfc ) LWIP_ASSERT("plug_holes: mem->used == 0", mem->used == 0); /* plug hole forward */ LWIP_ASSERT("plug_holes: mem->next <= MEM_SIZE_ALIGNED", mem->next <= MEM_SIZE_ALIGNED); nmem = (struct mem *)(void *)&ram[mem->next]; 802cb7e: f834 0c08 ldrh.w r0, [r4, #-8] /* ... which has to be in a used state ... */ LWIP_ASSERT("mem_free: mem->used", mem->used); /* ... and is now unused. */ mem->used = 0; if (mem < lfree) { 802cb82: 6819 ldr r1, [r3, #0] return; } /* protect the heap from concurrent access */ LWIP_MEM_FREE_PROTECT(); /* Get the corresponding struct mem ... */ mem = (struct mem *)(void *)((u8_t *)rmem - SIZEOF_STRUCT_MEM); 802cb84: f1a4 0208 sub.w r2, r4, #8 /* ... which has to be in a used state ... */ LWIP_ASSERT("mem_free: mem->used", mem->used); /* ... and is now unused. */ mem->used = 0; if (mem < lfree) { 802cb88: 428a cmp r2, r1 /* the newly freed struct is now the lowest */ lfree = mem; 802cb8a: bf38 it cc 802cb8c: 601a strcc r2, [r3, #0] LWIP_ASSERT("plug_holes: mem->used == 0", mem->used == 0); /* plug hole forward */ LWIP_ASSERT("plug_holes: mem->next <= MEM_SIZE_ALIGNED", mem->next <= MEM_SIZE_ALIGNED); nmem = (struct mem *)(void *)&ram[mem->next]; 802cb8e: 4b18 ldr r3, [pc, #96] ; (802cbf0 ) 802cb90: 681b ldr r3, [r3, #0] 802cb92: 1819 adds r1, r3, r0 if (mem != nmem && nmem->used == 0 && (u8_t *)nmem != (u8_t *)ram_end) { 802cb94: 428a cmp r2, r1 802cb96: d011 beq.n 802cbbc 802cb98: 790d ldrb r5, [r1, #4] 802cb9a: b97d cbnz r5, 802cbbc 802cb9c: 4d15 ldr r5, [pc, #84] ; (802cbf4 ) 802cb9e: 682d ldr r5, [r5, #0] 802cba0: 42a9 cmp r1, r5 802cba2: d00b beq.n 802cbbc /* if mem->next is unused and not end of ram, combine mem and mem->next */ if (lfree == nmem) { 802cba4: 4d15 ldr r5, [pc, #84] ; (802cbfc ) 802cba6: 682e ldr r6, [r5, #0] 802cba8: 428e cmp r6, r1 lfree = mem; } mem->next = nmem->next; 802cbaa: 5a19 ldrh r1, [r3, r0] nmem = (struct mem *)(void *)&ram[mem->next]; if (mem != nmem && nmem->used == 0 && (u8_t *)nmem != (u8_t *)ram_end) { /* if mem->next is unused and not end of ram, combine mem and mem->next */ if (lfree == nmem) { lfree = mem; 802cbac: bf08 it eq 802cbae: 602a streq r2, [r5, #0] } mem->next = nmem->next; 802cbb0: f824 1c08 strh.w r1, [r4, #-8] ((struct mem *)(void *)&ram[nmem->next])->prev = (mem_size_t)((u8_t *)mem - ram); 802cbb4: 5a19 ldrh r1, [r3, r0] 802cbb6: 1859 adds r1, r3, r1 802cbb8: 1ad0 subs r0, r2, r3 802cbba: 8048 strh r0, [r1, #2] } /* plug hole backward */ pmem = (struct mem *)(void *)&ram[mem->prev]; 802cbbc: f834 0c06 ldrh.w r0, [r4, #-6] 802cbc0: 1819 adds r1, r3, r0 if (pmem != mem && pmem->used == 0) { 802cbc2: 4291 cmp r1, r2 802cbc4: d00e beq.n 802cbe4 802cbc6: 790d ldrb r5, [r1, #4] 802cbc8: b965 cbnz r5, 802cbe4 /* if mem->prev is unused, combine mem and mem->prev */ if (lfree == mem) { 802cbca: 4d0c ldr r5, [pc, #48] ; (802cbfc ) 802cbcc: 682e ldr r6, [r5, #0] 802cbce: 4296 cmp r6, r2 lfree = pmem; } pmem->next = mem->next; 802cbd0: f834 2c08 ldrh.w r2, [r4, #-8] /* plug hole backward */ pmem = (struct mem *)(void *)&ram[mem->prev]; if (pmem != mem && pmem->used == 0) { /* if mem->prev is unused, combine mem and mem->prev */ if (lfree == mem) { lfree = pmem; 802cbd4: bf08 it eq 802cbd6: 6029 streq r1, [r5, #0] } pmem->next = mem->next; 802cbd8: 521a strh r2, [r3, r0] ((struct mem *)(void *)&ram[mem->next])->prev = (mem_size_t)((u8_t *)pmem - ram); 802cbda: f834 2c08 ldrh.w r2, [r4, #-8] 802cbde: 189a adds r2, r3, r2 802cbe0: 1acb subs r3, r1, r3 802cbe2: 8053 strh r3, [r2, #2] /* finally, see if prev or next are free also */ plug_holes(mem); #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_free_count = 1; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_FREE_UNPROTECT(); 802cbe4: 4804 ldr r0, [pc, #16] ; (802cbf8 ) } 802cbe6: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} /* finally, see if prev or next are free also */ plug_holes(mem); #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_free_count = 1; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_FREE_UNPROTECT(); 802cbea: f007 be85 b.w 80348f8 802cbee: bd70 pop {r4, r5, r6, pc} 802cbf0: 20002a60 .word 0x20002a60 802cbf4: 20002a58 .word 0x20002a58 802cbf8: 20002a5c .word 0x20002a5c 802cbfc: 20002a54 .word 0x20002a54 0802cc00 : * or NULL if newsize is > old size, in which case rmem is NOT touched * or freed! */ void * mem_trim(void *rmem, mem_size_t newsize) { 802cc00: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} /* use the FREE_PROTECT here: it protects with sem OR SYS_ARCH_PROTECT */ LWIP_MEM_FREE_DECL_PROTECT(); /* Expand the size of the allocated memory region so that we can adjust for alignment. */ newsize = LWIP_MEM_ALIGN_SIZE(newsize); 802cc04: 3103 adds r1, #3 802cc06: f64f 75fc movw r5, #65532 ; 0xfffc 802cc0a: 400d ands r5, r1 if(newsize < MIN_SIZE_ALIGNED) { 802cc0c: 2d0b cmp r5, #11 * or NULL if newsize is > old size, in which case rmem is NOT touched * or freed! */ void * mem_trim(void *rmem, mem_size_t newsize) { 802cc0e: 4604 mov r4, r0 /* Expand the size of the allocated memory region so that we can adjust for alignment. */ newsize = LWIP_MEM_ALIGN_SIZE(newsize); if(newsize < MIN_SIZE_ALIGNED) { 802cc10: d903 bls.n 802cc1a /* every data block must be at least MIN_SIZE_ALIGNED long */ newsize = MIN_SIZE_ALIGNED; } if (newsize > MEM_SIZE_ALIGNED) { 802cc12: f5b5 5fa0 cmp.w r5, #5120 ; 0x1400 802cc16: d901 bls.n 802cc1c 802cc18: e053 b.n 802ccc2 adjust for alignment. */ newsize = LWIP_MEM_ALIGN_SIZE(newsize); if(newsize < MIN_SIZE_ALIGNED) { /* every data block must be at least MIN_SIZE_ALIGNED long */ newsize = MIN_SIZE_ALIGNED; 802cc1a: 250c movs r5, #12 } LWIP_ASSERT("mem_trim: legal memory", (u8_t *)rmem >= (u8_t *)ram && (u8_t *)rmem < (u8_t *)ram_end); if ((u8_t *)rmem < (u8_t *)ram || (u8_t *)rmem >= (u8_t *)ram_end) { 802cc1c: f8df 80b8 ldr.w r8, [pc, #184] ; 802ccd8 802cc20: f8d8 3000 ldr.w r3, [r8] 802cc24: 429c cmp r4, r3 802cc26: d303 bcc.n 802cc30 802cc28: 4a28 ldr r2, [pc, #160] ; (802cccc ) 802cc2a: 6812 ldr r2, [r2, #0] 802cc2c: 4294 cmp r4, r2 802cc2e: d304 bcc.n 802cc3a SYS_ARCH_DECL_PROTECT(lev); LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SEVERE, ("mem_trim: illegal memory\n")); /* protect mem stats from concurrent access */ SYS_ARCH_PROTECT(lev); 802cc30: f007 fe82 bl 8034938 MEM_STATS_INC(illegal); SYS_ARCH_UNPROTECT(lev); 802cc34: f007 fe8a bl 803494c return rmem; 802cc38: e044 b.n 802ccc4 } /* Get the corresponding struct mem ... */ mem = (struct mem *)(void *)((u8_t *)rmem - SIZEOF_STRUCT_MEM); 802cc3a: f1a4 0608 sub.w r6, r4, #8 /* ... and its offset pointer */ ptr = (mem_size_t)((u8_t *)mem - ram); size = mem->next - ptr - SIZEOF_STRUCT_MEM; 802cc3e: f834 7c08 ldrh.w r7, [r4, #-8] return rmem; } /* Get the corresponding struct mem ... */ mem = (struct mem *)(void *)((u8_t *)rmem - SIZEOF_STRUCT_MEM); /* ... and its offset pointer */ ptr = (mem_size_t)((u8_t *)mem - ram); 802cc42: 1af6 subs r6, r6, r3 size = mem->next - ptr - SIZEOF_STRUCT_MEM; 802cc44: 3f08 subs r7, #8 return rmem; } /* Get the corresponding struct mem ... */ mem = (struct mem *)(void *)((u8_t *)rmem - SIZEOF_STRUCT_MEM); /* ... and its offset pointer */ ptr = (mem_size_t)((u8_t *)mem - ram); 802cc46: b2b6 uxth r6, r6 size = mem->next - ptr - SIZEOF_STRUCT_MEM; 802cc48: 1bbf subs r7, r7, r6 802cc4a: b2bf uxth r7, r7 LWIP_ASSERT("mem_trim can only shrink memory", newsize <= size); if (newsize > size) { 802cc4c: 42bd cmp r5, r7 802cc4e: d838 bhi.n 802ccc2 /* not supported */ return NULL; } if (newsize == size) { 802cc50: d038 beq.n 802ccc4 /* No change in size, simply return */ return rmem; } /* protect the heap from concurrent access */ LWIP_MEM_FREE_PROTECT(); 802cc52: 481f ldr r0, [pc, #124] ; (802ccd0 ) 802cc54: f007 fe44 bl 80348e0 mem2 = (struct mem *)(void *)&ram[mem->next]; 802cc58: f8d8 3000 ldr.w r3, [r8] 802cc5c: f834 1c08 ldrh.w r1, [r4, #-8] 802cc60: 185a adds r2, r3, r1 if(mem2->used == 0) { 802cc62: 7910 ldrb r0, [r2, #4] 802cc64: b978 cbnz r0, 802cc86 /* The next struct is unused, we can simply move it at little */ mem_size_t next; /* remember the old next pointer */ next = mem2->next; 802cc66: 5a5f ldrh r7, [r3, r1] /* create new struct mem which is moved directly after the shrinked mem */ ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; 802cc68: f106 0108 add.w r1, r6, #8 802cc6c: 186d adds r5, r5, r1 if (lfree == mem2) { 802cc6e: 4919 ldr r1, [pc, #100] ; (802ccd4 ) 802cc70: 6808 ldr r0, [r1, #0] /* The next struct is unused, we can simply move it at little */ mem_size_t next; /* remember the old next pointer */ next = mem2->next; /* create new struct mem which is moved directly after the shrinked mem */ ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; 802cc72: b2ad uxth r5, r5 if (lfree == mem2) { 802cc74: 4290 cmp r0, r2 802cc76: eb03 0205 add.w r2, r3, r5 lfree = (struct mem *)(void *)&ram[ptr2]; 802cc7a: bf08 it eq 802cc7c: 600a streq r2, [r1, #0] } mem2 = (struct mem *)(void *)&ram[ptr2]; mem2->used = 0; 802cc7e: 2100 movs r1, #0 802cc80: 7111 strb r1, [r2, #4] /* restore the next pointer */ mem2->next = next; 802cc82: 535f strh r7, [r3, r5] 802cc84: e010 b.n 802cca8 if (mem2->next != MEM_SIZE_ALIGNED) { ((struct mem *)(void *)&ram[mem2->next])->prev = ptr2; } MEM_STATS_DEC_USED(used, (size - newsize)); /* no need to plug holes, we've already done that */ } else if (newsize + SIZEOF_STRUCT_MEM + MIN_SIZE_ALIGNED <= size) { 802cc86: f105 0214 add.w r2, r5, #20 802cc8a: 42ba cmp r2, r7 802cc8c: d815 bhi.n 802ccba * @todo we could leave out MIN_SIZE_ALIGNED. We would create an empty * region that couldn't hold data, but when mem->next gets freed, * the 2 regions would be combined, resulting in more free memory */ ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; mem2 = (struct mem *)(void *)&ram[ptr2]; if (mem2 < lfree) { 802cc8e: 4811 ldr r0, [pc, #68] ; (802ccd4 ) * Old size ('size') must be big enough to contain at least 'newsize' plus a struct mem * ('SIZEOF_STRUCT_MEM') with some data ('MIN_SIZE_ALIGNED'). * @todo we could leave out MIN_SIZE_ALIGNED. We would create an empty * region that couldn't hold data, but when mem->next gets freed, * the 2 regions would be combined, resulting in more free memory */ ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; 802cc90: f106 0208 add.w r2, r6, #8 802cc94: 18ad adds r5, r5, r2 mem2 = (struct mem *)(void *)&ram[ptr2]; if (mem2 < lfree) { 802cc96: 6807 ldr r7, [r0, #0] * Old size ('size') must be big enough to contain at least 'newsize' plus a struct mem * ('SIZEOF_STRUCT_MEM') with some data ('MIN_SIZE_ALIGNED'). * @todo we could leave out MIN_SIZE_ALIGNED. We would create an empty * region that couldn't hold data, but when mem->next gets freed, * the 2 regions would be combined, resulting in more free memory */ ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; 802cc98: b2ad uxth r5, r5 mem2 = (struct mem *)(void *)&ram[ptr2]; 802cc9a: 195a adds r2, r3, r5 if (mem2 < lfree) { 802cc9c: 42ba cmp r2, r7 lfree = mem2; 802cc9e: bf38 it cc 802cca0: 6002 strcc r2, [r0, #0] } mem2->used = 0; mem2->next = mem->next; 802cca2: 5359 strh r1, [r3, r5] ptr2 = ptr + SIZEOF_STRUCT_MEM + newsize; mem2 = (struct mem *)(void *)&ram[ptr2]; if (mem2 < lfree) { lfree = mem2; } mem2->used = 0; 802cca4: 2000 movs r0, #0 802cca6: 7110 strb r0, [r2, #4] mem2->next = mem->next; mem2->prev = ptr; 802cca8: 8056 strh r6, [r2, #2] mem->next = ptr2; 802ccaa: f824 5c08 strh.w r5, [r4, #-8] if (mem2->next != MEM_SIZE_ALIGNED) { 802ccae: 5b5a ldrh r2, [r3, r5] 802ccb0: f5b2 5fa0 cmp.w r2, #5120 ; 0x1400 ((struct mem *)(void *)&ram[mem2->next])->prev = ptr2; 802ccb4: bf1c itt ne 802ccb6: 189b addne r3, r3, r2 802ccb8: 805d strhne r5, [r3, #2] -> the remaining space stays unused since it is too small } */ #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_free_count = 1; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_FREE_UNPROTECT(); 802ccba: 4805 ldr r0, [pc, #20] ; (802ccd0 ) 802ccbc: f007 fe1c bl 80348f8 return rmem; 802ccc0: e000 b.n 802ccc4 /* every data block must be at least MIN_SIZE_ALIGNED long */ newsize = MIN_SIZE_ALIGNED; } if (newsize > MEM_SIZE_ALIGNED) { return NULL; 802ccc2: 2400 movs r4, #0 #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_free_count = 1; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_FREE_UNPROTECT(); return rmem; } 802ccc4: 4620 mov r0, r4 802ccc6: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802ccca: bf00 nop 802cccc: 20002a58 .word 0x20002a58 802ccd0: 20002a5c .word 0x20002a5c 802ccd4: 20002a54 .word 0x20002a54 802ccd8: 20002a60 .word 0x20002a60 0802ccdc : * * Note that the returned value will always be aligned (as defined by MEM_ALIGNMENT). */ void * mem_malloc(mem_size_t size) { 802ccdc: b5f8 push {r3, r4, r5, r6, r7, lr} #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT u8_t local_mem_free_count = 0; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_ALLOC_DECL_PROTECT(); if (size == 0) { 802ccde: 2800 cmp r0, #0 802cce0: d056 beq.n 802cd90 return NULL; } /* Expand the size of the allocated memory region so that we can adjust for alignment. */ size = LWIP_MEM_ALIGN_SIZE(size); 802cce2: 3003 adds r0, #3 802cce4: f64f 74fc movw r4, #65532 ; 0xfffc 802cce8: 4004 ands r4, r0 if(size < MIN_SIZE_ALIGNED) { 802ccea: 2c0b cmp r4, #11 802ccec: d903 bls.n 802ccf6 /* every data block must be at least MIN_SIZE_ALIGNED long */ size = MIN_SIZE_ALIGNED; } if (size > MEM_SIZE_ALIGNED) { 802ccee: f5b4 5fa0 cmp.w r4, #5120 ; 0x1400 802ccf2: d901 bls.n 802ccf8 802ccf4: e04b b.n 802cd8e adjust for alignment. */ size = LWIP_MEM_ALIGN_SIZE(size); if(size < MIN_SIZE_ALIGNED) { /* every data block must be at least MIN_SIZE_ALIGNED long */ size = MIN_SIZE_ALIGNED; 802ccf6: 240c movs r4, #12 if (size > MEM_SIZE_ALIGNED) { return NULL; } /* protect the heap from concurrent access */ sys_mutex_lock(&mem_mutex); 802ccf8: 4826 ldr r0, [pc, #152] ; (802cd94 ) 802ccfa: f007 fdf1 bl 80348e0 #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ /* Scan through the heap searching for a free block that is big enough, * beginning with the lowest free block. */ for (ptr = (mem_size_t)((u8_t *)lfree - ram); ptr < MEM_SIZE_ALIGNED - size; 802ccfe: 4b26 ldr r3, [pc, #152] ; (802cd98 ) 802cd00: 6819 ldr r1, [r3, #0] 802cd02: 4b26 ldr r3, [pc, #152] ; (802cd9c ) 802cd04: 681a ldr r2, [r3, #0] 802cd06: 1a8b subs r3, r1, r2 802cd08: b29b uxth r3, r3 802cd0a: f5c4 5ea0 rsb lr, r4, #5120 ; 0x1400 802cd0e: e039 b.n 802cd84 ptr = ((struct mem *)(void *)&ram[ptr])->next) { mem = (struct mem *)(void *)&ram[ptr]; 802cd10: 18d5 adds r5, r2, r3 local_mem_free_count = 1; break; } #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ if ((!mem->used) && 802cd12: 792f ldrb r7, [r5, #4] 802cd14: 2f00 cmp r7, #0 802cd16: d134 bne.n 802cd82 (mem->next - (ptr + SIZEOF_STRUCT_MEM)) >= size) { 802cd18: 5ad6 ldrh r6, [r2, r3] 802cd1a: f1a6 0008 sub.w r0, r6, #8 802cd1e: 1ac0 subs r0, r0, r3 local_mem_free_count = 1; break; } #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ if ((!mem->used) && 802cd20: 42a0 cmp r0, r4 802cd22: d32e bcc.n 802cd82 (mem->next - (ptr + SIZEOF_STRUCT_MEM)) >= size) { /* mem is not used and at least perfect fit is possible: * mem->next - (ptr + SIZEOF_STRUCT_MEM) gives us the 'user data size' of mem */ if (mem->next - (ptr + SIZEOF_STRUCT_MEM) >= (size + SIZEOF_STRUCT_MEM + MIN_SIZE_ALIGNED)) { 802cd24: f104 0e14 add.w lr, r4, #20 802cd28: 4570 cmp r0, lr 802cd2a: d310 bcc.n 802cd4e * struct mem would fit in but no data between mem2 and mem2->next * @todo we could leave out MIN_SIZE_ALIGNED. We would create an empty * region that couldn't hold data, but when mem->next gets freed, * the 2 regions would be combined, resulting in more free memory */ ptr2 = ptr + SIZEOF_STRUCT_MEM + size; 802cd2c: 3408 adds r4, #8 802cd2e: 191c adds r4, r3, r4 802cd30: b2a4 uxth r4, r4 /* create mem2 struct */ mem2 = (struct mem *)(void *)&ram[ptr2]; 802cd32: 1910 adds r0, r2, r4 mem2->used = 0; mem2->next = mem->next; 802cd34: 5316 strh r6, [r2, r4] mem2->prev = ptr; 802cd36: 8043 strh r3, [r0, #2] /* and insert it between mem and mem->next */ mem->next = ptr2; 802cd38: 802c strh r4, [r5, #0] mem->used = 1; 802cd3a: 2301 movs r3, #1 * the 2 regions would be combined, resulting in more free memory */ ptr2 = ptr + SIZEOF_STRUCT_MEM + size; /* create mem2 struct */ mem2 = (struct mem *)(void *)&ram[ptr2]; mem2->used = 0; 802cd3c: 7107 strb r7, [r0, #4] mem2->next = mem->next; mem2->prev = ptr; /* and insert it between mem and mem->next */ mem->next = ptr2; mem->used = 1; 802cd3e: 712b strb r3, [r5, #4] if (mem2->next != MEM_SIZE_ALIGNED) { 802cd40: 5b13 ldrh r3, [r2, r4] 802cd42: f5b3 5fa0 cmp.w r3, #5120 ; 0x1400 802cd46: d004 beq.n 802cd52 ((struct mem *)(void *)&ram[mem2->next])->prev = ptr2; 802cd48: 18d2 adds r2, r2, r3 802cd4a: 8054 strh r4, [r2, #2] 802cd4c: e001 b.n 802cd52 * take care of this). * -> near fit or excact fit: do not split, no mem2 creation * also can't move mem->next directly behind mem, since mem->next * will always be used at this point! */ mem->used = 1; 802cd4e: 2301 movs r3, #1 802cd50: 712b strb r3, [r5, #4] MEM_STATS_INC_USED(used, mem->next - (mem_size_t)((u8_t *)mem - ram)); } #if LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT mem_malloc_adjust_lfree: #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ if (mem == lfree) { 802cd52: 428d cmp r5, r1 802cd54: d10f bne.n 802cd76 struct mem *cur = lfree; /* Find next free block after mem and update lowest free pointer */ while (cur->used && cur != ram_end) { 802cd56: 4b12 ldr r3, [pc, #72] ; (802cda0 ) 802cd58: 681a ldr r2, [r3, #0] /* If mem_free or mem_trim have run, we have to restart since they could have altered our current struct mem or lfree. */ goto mem_malloc_adjust_lfree; } #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ cur = (struct mem *)(void *)&ram[cur->next]; 802cd5a: 4b10 ldr r3, [pc, #64] ; (802cd9c ) 802cd5c: 6819 ldr r1, [r3, #0] 802cd5e: 462b mov r3, r5 802cd60: e001 b.n 802cd66 802cd62: 881b ldrh r3, [r3, #0] 802cd64: 18cb adds r3, r1, r3 mem_malloc_adjust_lfree: #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ if (mem == lfree) { struct mem *cur = lfree; /* Find next free block after mem and update lowest free pointer */ while (cur->used && cur != ram_end) { 802cd66: 7918 ldrb r0, [r3, #4] 802cd68: b910 cbnz r0, 802cd70 goto mem_malloc_adjust_lfree; } #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ cur = (struct mem *)(void *)&ram[cur->next]; } lfree = cur; 802cd6a: 4a0b ldr r2, [pc, #44] ; (802cd98 ) 802cd6c: 6013 str r3, [r2, #0] 802cd6e: e002 b.n 802cd76 mem_malloc_adjust_lfree: #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ if (mem == lfree) { struct mem *cur = lfree; /* Find next free block after mem and update lowest free pointer */ while (cur->used && cur != ram_end) { 802cd70: 4293 cmp r3, r2 802cd72: d1f6 bne.n 802cd62 802cd74: e7f9 b.n 802cd6a } lfree = cur; LWIP_ASSERT("mem_malloc: !lfree->used", ((lfree == ram_end) || (!lfree->used))); } LWIP_MEM_ALLOC_UNPROTECT(); sys_mutex_unlock(&mem_mutex); 802cd76: 4807 ldr r0, [pc, #28] ; (802cd94 ) 802cd78: f007 fdbe bl 80348f8 LWIP_ASSERT("mem_malloc: allocated memory properly aligned.", ((mem_ptr_t)mem + SIZEOF_STRUCT_MEM) % MEM_ALIGNMENT == 0); LWIP_ASSERT("mem_malloc: sanity check alignment", (((mem_ptr_t)mem) & (MEM_ALIGNMENT-1)) == 0); return (u8_t *)mem + SIZEOF_STRUCT_MEM; 802cd7c: f105 0008 add.w r0, r5, #8 802cd80: bdf8 pop {r3, r4, r5, r6, r7, pc} /* Scan through the heap searching for a free block that is big enough, * beginning with the lowest free block. */ for (ptr = (mem_size_t)((u8_t *)lfree - ram); ptr < MEM_SIZE_ALIGNED - size; ptr = ((struct mem *)(void *)&ram[ptr])->next) { 802cd82: 882b ldrh r3, [r5, #0] #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ /* Scan through the heap searching for a free block that is big enough, * beginning with the lowest free block. */ for (ptr = (mem_size_t)((u8_t *)lfree - ram); ptr < MEM_SIZE_ALIGNED - size; 802cd84: 4573 cmp r3, lr 802cd86: dbc3 blt.n 802cd10 } while(local_mem_free_count != 0); #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("mem_malloc: could not allocate %"S16_F" bytes\n", (s16_t)size)); MEM_STATS_INC(err); LWIP_MEM_ALLOC_UNPROTECT(); sys_mutex_unlock(&mem_mutex); 802cd88: 4802 ldr r0, [pc, #8] ; (802cd94 ) 802cd8a: f007 fdb5 bl 80348f8 u8_t local_mem_free_count = 0; #endif /* LWIP_ALLOW_MEM_FREE_FROM_OTHER_CONTEXT */ LWIP_MEM_ALLOC_DECL_PROTECT(); if (size == 0) { return NULL; 802cd8e: 2000 movs r0, #0 LWIP_DEBUGF(MEM_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("mem_malloc: could not allocate %"S16_F" bytes\n", (s16_t)size)); MEM_STATS_INC(err); LWIP_MEM_ALLOC_UNPROTECT(); sys_mutex_unlock(&mem_mutex); return NULL; } 802cd90: bdf8 pop {r3, r4, r5, r6, r7, pc} 802cd92: bf00 nop 802cd94: 20002a5c .word 0x20002a5c 802cd98: 20002a54 .word 0x20002a54 802cd9c: 20002a60 .word 0x20002a60 802cda0: 20002a58 .word 0x20002a58 0802cda4 : MEMP_STATS_AVAIL(err, i, 0); MEMP_STATS_AVAIL(avail, i, memp_num[i]); } #if !MEMP_SEPARATE_POOLS memp = (struct memp *)LWIP_MEM_ALIGN(memp_memory); 802cda4: 4a0e ldr r2, [pc, #56] ; (802cde0 ) 802cda6: 490f ldr r1, [pc, #60] ; (802cde4 ) * * Carves out memp_memory into linked lists for each pool-type. */ void memp_init(void) { 802cda8: b5f0 push {r4, r5, r6, r7, lr} MEMP_STATS_AVAIL(err, i, 0); MEMP_STATS_AVAIL(avail, i, memp_num[i]); } #if !MEMP_SEPARATE_POOLS memp = (struct memp *)LWIP_MEM_ALIGN(memp_memory); 802cdaa: 2300 movs r3, #0 memp_tab[i] = NULL; #if MEMP_SEPARATE_POOLS memp = (struct memp*)memp_bases[i]; #endif /* MEMP_SEPARATE_POOLS */ /* create a linked list of memp elements */ for (j = 0; j < memp_num[i]; ++j) { 802cdac: 4e0e ldr r6, [pc, #56] ; (802cde8 ) memp->next = memp_tab[i]; memp_tab[i] = memp; memp = (struct memp *)(void *)((u8_t *)memp + MEMP_SIZE + memp_sizes[i] 802cdae: 4f0f ldr r7, [pc, #60] ; (802cdec ) MEMP_STATS_AVAIL(err, i, 0); MEMP_STATS_AVAIL(avail, i, memp_num[i]); } #if !MEMP_SEPARATE_POOLS memp = (struct memp *)LWIP_MEM_ALIGN(memp_memory); 802cdb0: f022 0203 bic.w r2, r2, #3 #endif /* !MEMP_SEPARATE_POOLS */ /* for every pool: */ for (i = 0; i < MEMP_MAX; ++i) { memp_tab[i] = NULL; 802cdb4: 461d mov r5, r3 802cdb6: f841 5b04 str.w r5, [r1], #4 #if MEMP_SEPARATE_POOLS memp = (struct memp*)memp_bases[i]; #endif /* MEMP_SEPARATE_POOLS */ /* create a linked list of memp elements */ for (j = 0; j < memp_num[i]; ++j) { 802cdba: f833 c006 ldrh.w ip, [r3, r6] 802cdbe: 2000 movs r0, #0 802cdc0: e008 b.n 802cdd4 memp->next = memp_tab[i]; 802cdc2: f851 4c04 ldr.w r4, [r1, #-4] 802cdc6: 6014 str r4, [r2, #0] memp_tab[i] = memp; memp = (struct memp *)(void *)((u8_t *)memp + MEMP_SIZE + memp_sizes[i] 802cdc8: 5bdc ldrh r4, [r3, r7] memp = (struct memp*)memp_bases[i]; #endif /* MEMP_SEPARATE_POOLS */ /* create a linked list of memp elements */ for (j = 0; j < memp_num[i]; ++j) { memp->next = memp_tab[i]; memp_tab[i] = memp; 802cdca: f841 2c04 str.w r2, [r1, #-4] memp_tab[i] = NULL; #if MEMP_SEPARATE_POOLS memp = (struct memp*)memp_bases[i]; #endif /* MEMP_SEPARATE_POOLS */ /* create a linked list of memp elements */ for (j = 0; j < memp_num[i]; ++j) { 802cdce: 3001 adds r0, #1 memp->next = memp_tab[i]; memp_tab[i] = memp; memp = (struct memp *)(void *)((u8_t *)memp + MEMP_SIZE + memp_sizes[i] 802cdd0: 1912 adds r2, r2, r4 memp_tab[i] = NULL; #if MEMP_SEPARATE_POOLS memp = (struct memp*)memp_bases[i]; #endif /* MEMP_SEPARATE_POOLS */ /* create a linked list of memp elements */ for (j = 0; j < memp_num[i]; ++j) { 802cdd2: b280 uxth r0, r0 802cdd4: 4560 cmp r0, ip 802cdd6: d1f4 bne.n 802cdc2 802cdd8: 3302 adds r3, #2 #if !MEMP_SEPARATE_POOLS memp = (struct memp *)LWIP_MEM_ALIGN(memp_memory); #endif /* !MEMP_SEPARATE_POOLS */ /* for every pool: */ for (i = 0; i < MEMP_MAX; ++i) { 802cdda: 2b20 cmp r3, #32 802cddc: d1eb bne.n 802cdb6 #if MEMP_OVERFLOW_CHECK memp_overflow_init(); /* check everything a first time to see if it worked */ memp_overflow_check_all(); #endif /* MEMP_OVERFLOW_CHECK */ } 802cdde: bdf0 pop {r4, r5, r6, r7, pc} 802cde0: 20002a67 .word 0x20002a67 802cde4: 2000e0a4 .word 0x2000e0a4 802cde8: 0803fe1e .word 0x0803fe1e 802cdec: 0803fe3e .word 0x0803fe3e 0802cdf0 : #endif { struct memp *memp; SYS_ARCH_DECL_PROTECT(old_level); LWIP_ERROR("memp_malloc: type < MEMP_MAX", (type < MEMP_MAX), return NULL;); 802cdf0: 280f cmp r0, #15 #if !MEMP_OVERFLOW_CHECK memp_malloc(memp_t type) #else memp_malloc_fn(memp_t type, const char* file, const int line) #endif { 802cdf2: b538 push {r3, r4, r5, lr} 802cdf4: 4605 mov r5, r0 struct memp *memp; SYS_ARCH_DECL_PROTECT(old_level); LWIP_ERROR("memp_malloc: type < MEMP_MAX", (type < MEMP_MAX), return NULL;); 802cdf6: d80b bhi.n 802ce10 SYS_ARCH_PROTECT(old_level); 802cdf8: f007 fd9e bl 8034938 #if MEMP_OVERFLOW_CHECK >= 2 memp_overflow_check_all(); #endif /* MEMP_OVERFLOW_CHECK >= 2 */ memp = memp_tab[type]; 802cdfc: 4b06 ldr r3, [pc, #24] ; (802ce18 ) 802cdfe: f853 4025 ldr.w r4, [r3, r5, lsl #2] if (memp != NULL) { 802ce02: b114 cbz r4, 802ce0a memp_tab[type] = memp->next; 802ce04: 6822 ldr r2, [r4, #0] 802ce06: f843 2025 str.w r2, [r3, r5, lsl #2] } else { LWIP_DEBUGF(MEMP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("memp_malloc: out of memory in pool %s\n", memp_desc[type])); MEMP_STATS_INC(err, type); } SYS_ARCH_UNPROTECT(old_level); 802ce0a: f007 fd9f bl 803494c return memp; 802ce0e: e000 b.n 802ce12 #endif { struct memp *memp; SYS_ARCH_DECL_PROTECT(old_level); LWIP_ERROR("memp_malloc: type < MEMP_MAX", (type < MEMP_MAX), return NULL;); 802ce10: 2400 movs r4, #0 } SYS_ARCH_UNPROTECT(old_level); return memp; } 802ce12: 4620 mov r0, r4 802ce14: bd38 pop {r3, r4, r5, pc} 802ce16: bf00 nop 802ce18: 2000e0a4 .word 0x2000e0a4 0802ce1c : * @param type the pool where to put mem * @param mem the memp element to free */ void memp_free(memp_t type, void *mem) { 802ce1c: b538 push {r3, r4, r5, lr} 802ce1e: 4605 mov r5, r0 struct memp *memp; SYS_ARCH_DECL_PROTECT(old_level); if (mem == NULL) { 802ce20: 460c mov r4, r1 802ce22: b159 cbz r1, 802ce3c LWIP_ASSERT("memp_free: mem properly aligned", ((mem_ptr_t)mem % MEM_ALIGNMENT) == 0); memp = (struct memp *)(void *)((u8_t*)mem - MEMP_SIZE); SYS_ARCH_PROTECT(old_level); 802ce24: f007 fd88 bl 8034938 #endif /* MEMP_OVERFLOW_CHECK >= 2 */ #endif /* MEMP_OVERFLOW_CHECK */ MEMP_STATS_DEC(used, type); memp->next = memp_tab[type]; 802ce28: 4b05 ldr r3, [pc, #20] ; (802ce40 ) 802ce2a: f853 2025 ldr.w r2, [r3, r5, lsl #2] 802ce2e: 6022 str r2, [r4, #0] memp_tab[type] = memp; 802ce30: f843 4025 str.w r4, [r3, r5, lsl #2] #if MEMP_SANITY_CHECK LWIP_ASSERT("memp sanity", memp_sanity()); #endif /* MEMP_SANITY_CHECK */ SYS_ARCH_UNPROTECT(old_level); } 802ce34: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} #if MEMP_SANITY_CHECK LWIP_ASSERT("memp sanity", memp_sanity()); #endif /* MEMP_SANITY_CHECK */ SYS_ARCH_UNPROTECT(old_level); 802ce38: f007 bd88 b.w 803494c 802ce3c: bd38 pop {r3, r4, r5, pc} 802ce3e: bf00 nop 802ce40: 2000e0a4 .word 0x2000e0a4 0802ce44 : } #endif /* LWIP_HAVE_LOOPIF */ void netif_init(void) { 802ce44: 4770 bx lr 802ce46: 0000 movs r0, r0 0802ce48 : * @note call netif_set_addr() if you also want to change netmask and * default gateway */ void netif_set_ipaddr(struct netif *netif, ip_addr_t *ipaddr) { 802ce48: b570 push {r4, r5, r6, lr} 802ce4a: 4604 mov r4, r0 #if LWIP_TCP struct tcp_pcb *pcb; struct tcp_pcb_listen *lpcb; /* address is actually being changed? */ if (ipaddr && (ip_addr_cmp(ipaddr, &(netif->ip_addr))) == 0) { 802ce4c: 460d mov r5, r1 802ce4e: b941 cbnz r1, 802ce62 ip_addr_set(&(lpcb->local_ip), ipaddr); } } } #endif snmp_delete_ipaddridx_tree(netif); 802ce50: 4620 mov r0, r4 802ce52: f004 fd99 bl 8031988 snmp_delete_iprteidx_tree(0,netif); 802ce56: 2000 movs r0, #0 802ce58: 4621 mov r1, r4 802ce5a: f004 fe2b bl 8031ab4 /* set new IP address to netif */ ip_addr_set(&(netif->ip_addr), ipaddr); 802ce5e: b9fd cbnz r5, 802cea0 802ce60: e01f b.n 802cea2 #if LWIP_TCP struct tcp_pcb *pcb; struct tcp_pcb_listen *lpcb; /* address is actually being changed? */ if (ipaddr && (ip_addr_cmp(ipaddr, &(netif->ip_addr))) == 0) { 802ce62: 680a ldr r2, [r1, #0] 802ce64: 6843 ldr r3, [r0, #4] 802ce66: 429a cmp r2, r3 802ce68: d0f2 beq.n 802ce50 /* extern struct tcp_pcb *tcp_active_pcbs; defined by tcp.h */ LWIP_DEBUGF(NETIF_DEBUG | LWIP_DBG_STATE, ("netif_set_ipaddr: netif address being changed\n")); pcb = tcp_active_pcbs; 802ce6a: 4b13 ldr r3, [pc, #76] ; (802ceb8 ) 802ce6c: 6818 ldr r0, [r3, #0] while (pcb != NULL) { 802ce6e: e007 b.n 802ce80 /* PCB bound to current local interface address? */ if (ip_addr_cmp(&(pcb->local_ip), &(netif->ip_addr)) 802ce70: 6802 ldr r2, [r0, #0] 802ce72: 6863 ldr r3, [r4, #4] 802ce74: 68c6 ldr r6, [r0, #12] 802ce76: 429a cmp r2, r3 802ce78: d101 bne.n 802ce7e #endif /* LWIP_AUTOIP */ ) { /* this connection must be aborted */ struct tcp_pcb *next = pcb->next; LWIP_DEBUGF(NETIF_DEBUG | LWIP_DBG_STATE, ("netif_set_ipaddr: aborting TCP pcb %p\n", (void *)pcb)); tcp_abort(pcb); 802ce7a: f000 fd89 bl 802d990 pcb = next; } else { pcb = pcb->next; 802ce7e: 4630 mov r0, r6 /* address is actually being changed? */ if (ipaddr && (ip_addr_cmp(ipaddr, &(netif->ip_addr))) == 0) { /* extern struct tcp_pcb *tcp_active_pcbs; defined by tcp.h */ LWIP_DEBUGF(NETIF_DEBUG | LWIP_DBG_STATE, ("netif_set_ipaddr: netif address being changed\n")); pcb = tcp_active_pcbs; while (pcb != NULL) { 802ce80: 2800 cmp r0, #0 802ce82: d1f5 bne.n 802ce70 pcb = next; } else { pcb = pcb->next; } } for (lpcb = tcp_listen_pcbs.listen_pcbs; lpcb != NULL; lpcb = lpcb->next) { 802ce84: 4b0d ldr r3, [pc, #52] ; (802cebc ) 802ce86: 681b ldr r3, [r3, #0] 802ce88: e007 b.n 802ce9a /* PCB bound to current local interface address? */ if ((!(ip_addr_isany(&(lpcb->local_ip)))) && 802ce8a: 681a ldr r2, [r3, #0] 802ce8c: b122 cbz r2, 802ce98 802ce8e: 6861 ldr r1, [r4, #4] 802ce90: 428a cmp r2, r1 (ip_addr_cmp(&(lpcb->local_ip), &(netif->ip_addr)))) { /* The PCB is listening to the old ipaddr and * is set to listen to the new one instead */ ip_addr_set(&(lpcb->local_ip), ipaddr); 802ce92: bf04 itt eq 802ce94: 682a ldreq r2, [r5, #0] 802ce96: 601a streq r2, [r3, #0] pcb = next; } else { pcb = pcb->next; } } for (lpcb = tcp_listen_pcbs.listen_pcbs; lpcb != NULL; lpcb = lpcb->next) { 802ce98: 68db ldr r3, [r3, #12] 802ce9a: 2b00 cmp r3, #0 802ce9c: d1f5 bne.n 802ce8a 802ce9e: e7d7 b.n 802ce50 } #endif snmp_delete_ipaddridx_tree(netif); snmp_delete_iprteidx_tree(0,netif); /* set new IP address to netif */ ip_addr_set(&(netif->ip_addr), ipaddr); 802cea0: 682d ldr r5, [r5, #0] snmp_insert_ipaddridx_tree(netif); 802cea2: 4620 mov r0, r4 } #endif snmp_delete_ipaddridx_tree(netif); snmp_delete_iprteidx_tree(0,netif); /* set new IP address to netif */ ip_addr_set(&(netif->ip_addr), ipaddr); 802cea4: 6065 str r5, [r4, #4] snmp_insert_ipaddridx_tree(netif); 802cea6: f004 fd2d bl 8031904 snmp_insert_iprteidx_tree(0,netif); 802ceaa: 2000 movs r0, #0 802ceac: 4621 mov r1, r4 netif->name[0], netif->name[1], ip4_addr1_16(&netif->ip_addr), ip4_addr2_16(&netif->ip_addr), ip4_addr3_16(&netif->ip_addr), ip4_addr4_16(&netif->ip_addr))); } 802ceae: e8bd 4070 ldmia.w sp!, {r4, r5, r6, lr} snmp_delete_ipaddridx_tree(netif); snmp_delete_iprteidx_tree(0,netif); /* set new IP address to netif */ ip_addr_set(&(netif->ip_addr), ipaddr); snmp_insert_ipaddridx_tree(netif); snmp_insert_iprteidx_tree(0,netif); 802ceb2: f004 bdb3 b.w 8031a1c 802ceb6: bf00 nop 802ceb8: 20010fdc .word 0x20010fdc 802cebc: 20010fe4 .word 0x20010fe4 0802cec0 : * @note call netif_set_addr() if you also want to change ip address and netmask */ void netif_set_gw(struct netif *netif, ip_addr_t *gw) { ip_addr_set(&(netif->gw), gw); 802cec0: b101 cbz r1, 802cec4 802cec2: 6809 ldr r1, [r1, #0] 802cec4: 60c1 str r1, [r0, #12] 802cec6: 4770 bx lr 0802cec8 : * @note call netif_set_addr() if you also want to change ip address and * default gateway */ void netif_set_netmask(struct netif *netif, ip_addr_t *netmask) { 802cec8: b538 push {r3, r4, r5, lr} 802ceca: 4604 mov r4, r0 802cecc: 460d mov r5, r1 snmp_delete_iprteidx_tree(0, netif); 802cece: 2000 movs r0, #0 802ced0: 4621 mov r1, r4 802ced2: f004 fdef bl 8031ab4 /* set new netmask to netif */ ip_addr_set(&(netif->netmask), netmask); 802ced6: b105 cbz r5, 802ceda 802ced8: 682d ldr r5, [r5, #0] snmp_insert_iprteidx_tree(0, netif); 802ceda: 2000 movs r0, #0 802cedc: 4621 mov r1, r4 void netif_set_netmask(struct netif *netif, ip_addr_t *netmask) { snmp_delete_iprteidx_tree(0, netif); /* set new netmask to netif */ ip_addr_set(&(netif->netmask), netmask); 802cede: 60a5 str r5, [r4, #8] netif->name[0], netif->name[1], ip4_addr1_16(&netif->netmask), ip4_addr2_16(&netif->netmask), ip4_addr3_16(&netif->netmask), ip4_addr4_16(&netif->netmask))); } 802cee0: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} netif_set_netmask(struct netif *netif, ip_addr_t *netmask) { snmp_delete_iprteidx_tree(0, netif); /* set new netmask to netif */ ip_addr_set(&(netif->netmask), netmask); snmp_insert_iprteidx_tree(0, netif); 802cee4: f004 bd9a b.w 8031a1c 0802cee8 : * @param gw the new default gateway */ void netif_set_addr(struct netif *netif, ip_addr_t *ipaddr, ip_addr_t *netmask, ip_addr_t *gw) { 802cee8: b570 push {r4, r5, r6, lr} 802ceea: 4605 mov r5, r0 802ceec: 4616 mov r6, r2 802ceee: 461c mov r4, r3 netif_set_ipaddr(netif, ipaddr); 802cef0: f7ff ffaa bl 802ce48 netif_set_netmask(netif, netmask); 802cef4: 4628 mov r0, r5 802cef6: 4631 mov r1, r6 802cef8: f7ff ffe6 bl 802cec8 * @note call netif_set_addr() if you also want to change ip address and netmask */ void netif_set_gw(struct netif *netif, ip_addr_t *gw) { ip_addr_set(&(netif->gw), gw); 802cefc: b104 cbz r4, 802cf00 802cefe: 6824 ldr r4, [r4, #0] 802cf00: 60ec str r4, [r5, #12] 802cf02: bd70 pop {r4, r5, r6, pc} 0802cf04 : * @return netif, or NULL if failed. */ struct netif * netif_add(struct netif *netif, ip_addr_t *ipaddr, ip_addr_t *netmask, ip_addr_t *gw, void *state, netif_init_fn init, netif_input_fn input) { 802cf04: b5f8 push {r3, r4, r5, r6, r7, lr} netif->loop_first = NULL; netif->loop_last = NULL; #endif /* ENABLE_LOOPBACK */ /* remember netif specific state information data */ netif->state = state; 802cf06: 9e06 ldr r6, [sp, #24] 802cf08: 61c6 str r6, [r0, #28] netif->num = netif_num++; 802cf0a: 4e10 ldr r6, [pc, #64] ; (802cf4c ) 802cf0c: 7837 ldrb r7, [r6, #0] 802cf0e: f880 7030 strb.w r7, [r0, #48] ; 0x30 802cf12: 3701 adds r7, #1 802cf14: 7037 strb r7, [r6, #0] netif->input = input; 802cf16: 9e08 ldr r6, [sp, #32] { LWIP_ASSERT("No init function given", init != NULL); /* reset new interface configuration state */ ip_addr_set_zero(&netif->ip_addr); 802cf18: 2500 movs r5, #0 * @return netif, or NULL if failed. */ struct netif * netif_add(struct netif *netif, ip_addr_t *ipaddr, ip_addr_t *netmask, ip_addr_t *gw, void *state, netif_init_fn init, netif_input_fn input) { 802cf1a: 4604 mov r4, r0 LWIP_ASSERT("No init function given", init != NULL); /* reset new interface configuration state */ ip_addr_set_zero(&netif->ip_addr); 802cf1c: 6045 str r5, [r0, #4] ip_addr_set_zero(&netif->netmask); 802cf1e: 6085 str r5, [r0, #8] ip_addr_set_zero(&netif->gw); 802cf20: 60c5 str r5, [r0, #12] netif->flags = 0; 802cf22: f880 502d strb.w r5, [r0, #45] ; 0x2d #if LWIP_DHCP /* netif not under DHCP control by default */ netif->dhcp = NULL; 802cf26: 6205 str r5, [r0, #32] #endif /* ENABLE_LOOPBACK */ /* remember netif specific state information data */ netif->state = state; netif->num = netif_num++; netif->input = input; 802cf28: 6106 str r6, [r0, #16] NETIF_SET_HWADDRHINT(netif, NULL); #if ENABLE_LOOPBACK && LWIP_LOOPBACK_MAX_PBUFS netif->loop_cnt_current = 0; #endif /* ENABLE_LOOPBACK && LWIP_LOOPBACK_MAX_PBUFS */ netif_set_addr(netif, ipaddr, netmask, gw); 802cf2a: f7ff ffdd bl 802cee8 /* call user specified initialization function for netif */ if (init(netif) != ERR_OK) { 802cf2e: 4620 mov r0, r4 802cf30: 9b07 ldr r3, [sp, #28] 802cf32: 4798 blx r3 802cf34: b930 cbnz r0, 802cf44 return NULL; } /* add this netif to the list */ netif->next = netif_list; 802cf36: 4b06 ldr r3, [pc, #24] ; (802cf50 ) 802cf38: 681a ldr r2, [r3, #0] 802cf3a: 6022 str r2, [r4, #0] netif_list = netif; 802cf3c: 601c str r4, [r3, #0] snmp_inc_iflist(); 802cf3e: f004 fbc5 bl 80316cc LWIP_DEBUGF(NETIF_DEBUG, (" netmask ")); ip_addr_debug_print(NETIF_DEBUG, netmask); LWIP_DEBUGF(NETIF_DEBUG, (" gw ")); ip_addr_debug_print(NETIF_DEBUG, gw); LWIP_DEBUGF(NETIF_DEBUG, ("\n")); return netif; 802cf42: e000 b.n 802cf46 netif_set_addr(netif, ipaddr, netmask, gw); /* call user specified initialization function for netif */ if (init(netif) != ERR_OK) { return NULL; 802cf44: 462c mov r4, r5 ip_addr_debug_print(NETIF_DEBUG, netmask); LWIP_DEBUGF(NETIF_DEBUG, (" gw ")); ip_addr_debug_print(NETIF_DEBUG, gw); LWIP_DEBUGF(NETIF_DEBUG, ("\n")); return netif; } 802cf46: 4620 mov r0, r4 802cf48: bdf8 pop {r3, r4, r5, r6, r7, pc} 802cf4a: bf00 nop 802cf4c: 2000e0e4 .word 0x2000e0e4 802cf50: 20010fd0 .word 0x20010fd0 0802cf54 : * * @param netif the default network interface */ void netif_set_default(struct netif *netif) { 802cf54: b510 push {r4, lr} if (netif == NULL) { 802cf56: 4604 mov r4, r0 /* remove default route */ snmp_delete_iprteidx_tree(1, netif); 802cf58: 4621 mov r1, r4 802cf5a: 2001 movs r0, #1 * @param netif the default network interface */ void netif_set_default(struct netif *netif) { if (netif == NULL) { 802cf5c: b914 cbnz r4, 802cf64 /* remove default route */ snmp_delete_iprteidx_tree(1, netif); 802cf5e: f004 fda9 bl 8031ab4 802cf62: e001 b.n 802cf68 } else { /* install default route */ snmp_insert_iprteidx_tree(1, netif); 802cf64: f004 fd5a bl 8031a1c } netif_default = netif; 802cf68: 4b01 ldr r3, [pc, #4] ; (802cf70 ) 802cf6a: 601c str r4, [r3, #0] 802cf6c: bd10 pop {r4, pc} 802cf6e: bf00 nop 802cf70: 20010fd4 .word 0x20010fd4 0802cf74 : * up once configured. * * @see dhcp_start() */ void netif_set_up(struct netif *netif) { 802cf74: b510 push {r4, lr} if (!(netif->flags & NETIF_FLAG_UP)) { 802cf76: f890 302d ldrb.w r3, [r0, #45] ; 0x2d 802cf7a: 07da lsls r2, r3, #31 * up once configured. * * @see dhcp_start() */ void netif_set_up(struct netif *netif) { 802cf7c: 4604 mov r4, r0 if (!(netif->flags & NETIF_FLAG_UP)) { 802cf7e: d412 bmi.n 802cfa6 netif->flags |= NETIF_FLAG_UP; 802cf80: f043 0301 orr.w r3, r3, #1 802cf84: f880 302d strb.w r3, [r0, #45] ; 0x2d #if LWIP_SNMP snmp_get_sysuptime(&netif->ts); 802cf88: 3038 adds r0, #56 ; 0x38 802cf8a: f004 fb43 bl 8031614 * @note: Enabling DHCP on a down interface will make it come * up once configured. * * @see dhcp_start() */ void netif_set_up(struct netif *netif) 802cf8e: f894 302d ldrb.w r3, [r4, #45] ; 0x2d NETIF_STATUS_CALLBACK(netif); if (netif->flags & NETIF_FLAG_LINK_UP) { #if LWIP_ARP /* For Ethernet network interfaces, we would like to send a "gratuitous ARP" */ if (netif->flags & (NETIF_FLAG_ETHARP)) { 802cf92: f003 0330 and.w r3, r3, #48 ; 0x30 802cf96: 2b30 cmp r3, #48 ; 0x30 802cf98: d105 bne.n 802cfa6 etharp_gratuitous(netif); 802cf9a: 4620 mov r0, r4 802cf9c: 1d21 adds r1, r4, #4 igmp_report_groups( netif); } #endif /* LWIP_IGMP */ } } } 802cf9e: e8bd 4010 ldmia.w sp!, {r4, lr} if (netif->flags & NETIF_FLAG_LINK_UP) { #if LWIP_ARP /* For Ethernet network interfaces, we would like to send a "gratuitous ARP" */ if (netif->flags & (NETIF_FLAG_ETHARP)) { etharp_gratuitous(netif); 802cfa2: f007 b87d b.w 80340a0 802cfa6: bd10 pop {r4, pc} 0802cfa8 : * up once configured. * * @see dhcp_start() */ void netif_set_down(struct netif *netif) { 802cfa8: b510 push {r4, lr} if (netif->flags & NETIF_FLAG_UP) { 802cfaa: f890 302d ldrb.w r3, [r0, #45] ; 0x2d 802cfae: 07d9 lsls r1, r3, #31 * up once configured. * * @see dhcp_start() */ void netif_set_down(struct netif *netif) { 802cfb0: 4604 mov r4, r0 if (netif->flags & NETIF_FLAG_UP) { 802cfb2: d511 bpl.n 802cfd8 netif->flags &= ~NETIF_FLAG_UP; 802cfb4: f023 0301 bic.w r3, r3, #1 802cfb8: f880 302d strb.w r3, [r0, #45] ; 0x2d #if LWIP_SNMP snmp_get_sysuptime(&netif->ts); 802cfbc: 3038 adds r0, #56 ; 0x38 802cfbe: f004 fb29 bl 8031614 #endif #if LWIP_ARP if (netif->flags & NETIF_FLAG_ETHARP) { 802cfc2: f894 302d ldrb.w r3, [r4, #45] ; 0x2d 802cfc6: f003 0320 and.w r3, r3, #32 802cfca: b2db uxtb r3, r3 802cfcc: b123 cbz r3, 802cfd8 etharp_cleanup_netif(netif); 802cfce: 4620 mov r0, r4 } #endif /* LWIP_ARP */ NETIF_STATUS_CALLBACK(netif); } } 802cfd0: e8bd 4010 ldmia.w sp!, {r4, lr} snmp_get_sysuptime(&netif->ts); #endif #if LWIP_ARP if (netif->flags & NETIF_FLAG_ETHARP) { etharp_cleanup_netif(netif); 802cfd4: f007 b834 b.w 8034040 802cfd8: bd10 pop {r4, pc} 0802cfda : * @return non-zero on failure, zero on success. * */ u8_t pbuf_header(struct pbuf *p, s16_t header_size_increment) { 802cfda: b510 push {r4, lr} u16_t type; void *payload; u16_t increment_magnitude; LWIP_ASSERT("p != NULL", p != NULL); if ((header_size_increment == 0) || (p == NULL)) { 802cfdc: b321 cbz r1, 802d028 802cfde: b330 cbz r0, 802d02e return 0; } if (header_size_increment < 0){ 802cfe0: 2900 cmp r1, #0 802cfe2: da05 bge.n 802cff0 increment_magnitude = -header_size_increment; 802cfe4: 424b negs r3, r1 /* Check that we aren't going to move off the end of the pbuf */ LWIP_ERROR("increment_magnitude <= p->len", (increment_magnitude <= p->len), return 1;); 802cfe6: 8942 ldrh r2, [r0, #10] if ((header_size_increment == 0) || (p == NULL)) { return 0; } if (header_size_increment < 0){ increment_magnitude = -header_size_increment; 802cfe8: b29b uxth r3, r3 /* Check that we aren't going to move off the end of the pbuf */ LWIP_ERROR("increment_magnitude <= p->len", (increment_magnitude <= p->len), return 1;); 802cfea: 429a cmp r2, r3 802cfec: d201 bcs.n 802cff2 802cfee: e01d b.n 802d02c } else { increment_magnitude = header_size_increment; 802cff0: b28b uxth r3, r1 LWIP_ASSERT("p->payload - increment_magnitude >= p + SIZEOF_STRUCT_PBUF", (u8_t *)p->payload - increment_magnitude >= (u8_t *)p + SIZEOF_STRUCT_PBUF); #endif } type = p->type; 802cff2: 7b02 ldrb r2, [r0, #12] /* remember current payload pointer */ payload = p->payload; 802cff4: 6844 ldr r4, [r0, #4] /* pbuf types containing payloads? */ if (type == PBUF_RAM || type == PBUF_POOL) { 802cff6: b10a cbz r2, 802cffc 802cff8: 2a03 cmp r2, #3 802cffa: d105 bne.n 802d008 /* set new payload pointer */ p->payload = (u8_t *)p->payload - header_size_increment; 802cffc: 1a64 subs r4, r4, r1 /* boundary check fails? */ if ((u8_t *)p->payload < (u8_t *)p + SIZEOF_STRUCT_PBUF) { 802cffe: f100 0310 add.w r3, r0, #16 802d002: 429c cmp r4, r3 802d004: d312 bcc.n 802d02c 802d006: e008 b.n 802d01a p->payload = payload; /* bail out unsuccesfully */ return 1; } /* pbuf types refering to external payloads? */ } else if (type == PBUF_REF || type == PBUF_ROM) { 802d008: 3a01 subs r2, #1 802d00a: 2a01 cmp r2, #1 802d00c: d80e bhi.n 802d02c /* hide a header in the payload? */ if ((header_size_increment < 0) && (increment_magnitude <= p->len)) { 802d00e: 2900 cmp r1, #0 802d010: da0c bge.n 802d02c 802d012: 8942 ldrh r2, [r0, #10] 802d014: 429a cmp r2, r3 802d016: d309 bcc.n 802d02c /* increase payload pointer */ p->payload = (u8_t *)p->payload - header_size_increment; 802d018: 1a64 subs r4, r4, r1 /* Unknown type */ LWIP_ASSERT("bad pbuf type", 0); return 1; } /* modify pbuf length fields */ p->len += header_size_increment; 802d01a: 8943 ldrh r3, [r0, #10] /* pbuf types refering to external payloads? */ } else if (type == PBUF_REF || type == PBUF_ROM) { /* hide a header in the payload? */ if ((header_size_increment < 0) && (increment_magnitude <= p->len)) { /* increase payload pointer */ p->payload = (u8_t *)p->payload - header_size_increment; 802d01c: 6044 str r4, [r0, #4] /* Unknown type */ LWIP_ASSERT("bad pbuf type", 0); return 1; } /* modify pbuf length fields */ p->len += header_size_increment; 802d01e: 18cb adds r3, r1, r3 802d020: 8143 strh r3, [r0, #10] p->tot_len += header_size_increment; 802d022: 8903 ldrh r3, [r0, #8] 802d024: 18c9 adds r1, r1, r3 802d026: 8101 strh r1, [r0, #8] LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_header: old %p new %p (%"S16_F")\n", (void *)payload, (void *)p->payload, header_size_increment)); return 0; 802d028: 2000 movs r0, #0 802d02a: bd10 pop {r4, pc} } if (header_size_increment < 0){ increment_magnitude = -header_size_increment; /* Check that we aren't going to move off the end of the pbuf */ LWIP_ERROR("increment_magnitude <= p->len", (increment_magnitude <= p->len), return 1;); 802d02c: 2001 movs r0, #1 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_header: old %p new %p (%"S16_F")\n", (void *)payload, (void *)p->payload, header_size_increment)); return 0; } 802d02e: bd10 pop {r4, pc} 0802d030 : * 1->1->1 becomes ....... * */ u8_t pbuf_free(struct pbuf *p) { 802d030: b570 push {r4, r5, r6, lr} u16_t type; struct pbuf *q; u8_t count; if (p == NULL) { 802d032: 4604 mov r4, r0 802d034: b300 cbz r0, 802d078 802d036: 2500 movs r5, #0 u16_t ref; SYS_ARCH_DECL_PROTECT(old_level); /* Since decrementing ref cannot be guaranteed to be a single machine operation * we must protect it. We put the new ref into a local variable to prevent * further protection. */ SYS_ARCH_PROTECT(old_level); 802d038: f007 fc7e bl 8034938 /* all pbufs in a chain are referenced at least once */ LWIP_ASSERT("pbuf_free: p->ref > 0", p->ref > 0); /* decrease reference count (number of pointers to pbuf) */ ref = --(p->ref); 802d03c: 89e6 ldrh r6, [r4, #14] 802d03e: 3e01 subs r6, #1 802d040: b2b6 uxth r6, r6 802d042: 81e6 strh r6, [r4, #14] SYS_ARCH_UNPROTECT(old_level); 802d044: f007 fc82 bl 803494c /* this pbuf is no longer referenced to? */ if (ref == 0) { 802d048: b9be cbnz r6, 802d07a /* remember next pbuf in chain for next iteration */ q = p->next; LWIP_DEBUGF( PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_free: deallocating %p\n", (void *)p)); type = p->type; 802d04a: 7b23 ldrb r3, [r4, #12] ref = --(p->ref); SYS_ARCH_UNPROTECT(old_level); /* this pbuf is no longer referenced to? */ if (ref == 0) { /* remember next pbuf in chain for next iteration */ q = p->next; 802d04c: 6826 ldr r6, [r4, #0] pc->custom_free_function(p); } else #endif /* LWIP_SUPPORT_CUSTOM_PBUF */ { /* is this a pbuf from the pool? */ if (type == PBUF_POOL) { 802d04e: 2b03 cmp r3, #3 802d050: d101 bne.n 802d056 memp_free(MEMP_PBUF_POOL, p); 802d052: 200f movs r0, #15 802d054: e003 b.n 802d05e /* is this a ROM or RAM referencing pbuf? */ } else if (type == PBUF_ROM || type == PBUF_REF) { 802d056: 3b01 subs r3, #1 802d058: 2b01 cmp r3, #1 802d05a: d804 bhi.n 802d066 memp_free(MEMP_PBUF, p); 802d05c: 200e movs r0, #14 802d05e: 4621 mov r1, r4 802d060: f7ff fedc bl 802ce1c 802d064: e002 b.n 802d06c /* type == PBUF_RAM */ } else { mem_free(p); 802d066: 4620 mov r0, r4 802d068: f7ff fd70 bl 802cb4c } } count++; 802d06c: 3501 adds r5, #1 802d06e: b2ed uxtb r5, r5 p->type == PBUF_REF || p->type == PBUF_POOL); count = 0; /* de-allocate all consecutive pbufs from the head of the chain that * obtain a zero reference count after decrementing*/ while (p != NULL) { 802d070: 4634 mov r4, r6 802d072: 2e00 cmp r6, #0 802d074: d1e0 bne.n 802d038 802d076: e000 b.n 802d07a if (p == NULL) { LWIP_ASSERT("p != NULL", p != NULL); /* if assertions are disabled, proceed with debug output */ LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("pbuf_free(p == NULL) was called.\n")); return 0; 802d078: 4605 mov r5, r0 } } PERF_STOP("pbuf_free"); /* return number of de-allocated pbufs */ return count; } 802d07a: 4628 mov r0, r5 802d07c: bd70 pop {r4, r5, r6, pc} 0802d07e : * * @note Despite its name, pbuf_realloc cannot grow the size of a pbuf (chain). */ void pbuf_realloc(struct pbuf *p, u16_t new_len) { 802d07e: b538 push {r3, r4, r5, lr} p->type == PBUF_ROM || p->type == PBUF_RAM || p->type == PBUF_REF); /* desired length larger than current length? */ if (new_len >= p->tot_len) { 802d080: 8903 ldrh r3, [r0, #8] 802d082: 4299 cmp r1, r3 802d084: d220 bcs.n 802d0c8 return; } /* the pbuf chain grows by (new_len - p->tot_len) bytes * (which may be negative in case of shrinking) */ grow = new_len - p->tot_len; 802d086: 1aca subs r2, r1, r3 /* first, step over any pbufs that should remain in the chain */ rem_len = new_len; q = p; /* should this pbuf be kept? */ while (rem_len > q->len) { 802d088: 460d mov r5, r1 802d08a: 4604 mov r4, r0 802d08c: e005 b.n 802d09a /* decrease remaining length by pbuf length */ rem_len -= q->len; 802d08e: 1aed subs r5, r5, r3 /* decrease total length indicator */ LWIP_ASSERT("grow < max_u16_t", grow < 0xffff); q->tot_len += (u16_t)grow; 802d090: 8923 ldrh r3, [r4, #8] 802d092: 18d3 adds r3, r2, r3 802d094: 8123 strh r3, [r4, #8] /* proceed to next pbuf in chain */ q = q->next; 802d096: 6824 ldr r4, [r4, #0] rem_len = new_len; q = p; /* should this pbuf be kept? */ while (rem_len > q->len) { /* decrease remaining length by pbuf length */ rem_len -= q->len; 802d098: b2ad uxth r5, r5 /* first, step over any pbufs that should remain in the chain */ rem_len = new_len; q = p; /* should this pbuf be kept? */ while (rem_len > q->len) { 802d09a: 8963 ldrh r3, [r4, #10] 802d09c: 429d cmp r5, r3 802d09e: d8f6 bhi.n 802d08e /* we have now reached the new last pbuf (in q) */ /* rem_len == desired length for pbuf q */ /* shrink allocated memory for PBUF_RAM */ /* (other types merely adjust their length fields */ if ((q->type == PBUF_RAM) && (rem_len != q->len)) { 802d0a0: 7b22 ldrb r2, [r4, #12] 802d0a2: b94a cbnz r2, 802d0b8 802d0a4: 429d cmp r5, r3 802d0a6: d007 beq.n 802d0b8 /* reallocate and adjust the length of the pbuf that will be split */ q = (struct pbuf *)mem_trim(q, (u16_t)((u8_t *)q->payload - (u8_t *)q) + rem_len); 802d0a8: 6863 ldr r3, [r4, #4] 802d0aa: 1b1b subs r3, r3, r4 802d0ac: 18e9 adds r1, r5, r3 802d0ae: 4620 mov r0, r4 802d0b0: b289 uxth r1, r1 802d0b2: f7ff fda5 bl 802cc00 802d0b6: 4604 mov r4, r0 /* adjust length fields for new last pbuf */ q->len = rem_len; q->tot_len = q->len; /* any remaining pbufs in chain? */ if (q->next != NULL) { 802d0b8: 6820 ldr r0, [r4, #0] /* reallocate and adjust the length of the pbuf that will be split */ q = (struct pbuf *)mem_trim(q, (u16_t)((u8_t *)q->payload - (u8_t *)q) + rem_len); LWIP_ASSERT("mem_trim returned q == NULL", q != NULL); } /* adjust length fields for new last pbuf */ q->len = rem_len; 802d0ba: 8165 strh r5, [r4, #10] q->tot_len = q->len; 802d0bc: 8125 strh r5, [r4, #8] /* any remaining pbufs in chain? */ if (q->next != NULL) { 802d0be: b108 cbz r0, 802d0c4 /* free remaining pbufs in chain */ pbuf_free(q->next); 802d0c0: f7ff ffb6 bl 802d030 } /* q is last packet in chain */ q->next = NULL; 802d0c4: 2300 movs r3, #0 802d0c6: 6023 str r3, [r4, #0] 802d0c8: bd38 pop {r3, r4, r5, pc} 0802d0ca : * @return the allocated pbuf. If multiple pbufs where allocated, this * is the first pbuf of a pbuf chain. */ struct pbuf * pbuf_alloc(pbuf_layer layer, u16_t length, pbuf_type type) { 802d0ca: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 802d0ce: 460d mov r5, r1 802d0d0: 4617 mov r7, r2 u16_t offset; s32_t rem_len; /* remaining length */ LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc(length=%"U16_F")\n", length)); /* determine header offset */ switch (layer) { 802d0d2: 2803 cmp r0, #3 802d0d4: d87c bhi.n 802d1d0 802d0d6: e8df f000 tbb [pc, r0] 802d0da: 0802 .short 0x0802 802d0dc: 0604 .short 0x0604 case PBUF_TRANSPORT: /* add room for transport (often TCP) layer header */ offset = PBUF_LINK_HLEN + PBUF_IP_HLEN + PBUF_TRANSPORT_HLEN; 802d0de: 2636 movs r6, #54 ; 0x36 802d0e0: e004 b.n 802d0ec /* add room for IP layer header */ offset = PBUF_LINK_HLEN + PBUF_IP_HLEN; break; case PBUF_LINK: /* add room for link layer header */ offset = PBUF_LINK_HLEN; 802d0e2: 260e movs r6, #14 break; 802d0e4: e002 b.n 802d0ec case PBUF_RAW: offset = 0; 802d0e6: 2600 movs r6, #0 break; 802d0e8: e000 b.n 802d0ec /* add room for transport (often TCP) layer header */ offset = PBUF_LINK_HLEN + PBUF_IP_HLEN + PBUF_TRANSPORT_HLEN; break; case PBUF_IP: /* add room for IP layer header */ offset = PBUF_LINK_HLEN + PBUF_IP_HLEN; 802d0ea: 2622 movs r6, #34 ; 0x22 default: LWIP_ASSERT("pbuf_alloc: bad pbuf layer", 0); return NULL; } switch (type) { 802d0ec: 2f03 cmp r7, #3 802d0ee: d86f bhi.n 802d1d0 802d0f0: e8df f007 tbb [pc, r7] 802d0f4: 025e5e46 .word 0x025e5e46 case PBUF_POOL: /* allocate head of pbuf chain into p */ p = (struct pbuf *)memp_malloc(MEMP_PBUF_POOL); 802d0f8: 200f movs r0, #15 802d0fa: f7ff fe79 bl 802cdf0 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc: allocated pbuf %p\n", (void *)p)); if (p == NULL) { 802d0fe: 4604 mov r4, r0 802d100: b900 cbnz r0, 802d104 802d102: e065 b.n 802d1d0 } p->type = type; p->next = NULL; /* make the payload pointer point 'offset' bytes into pbuf data memory */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset))); 802d104: 1982 adds r2, r0, r6 LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned", ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0); /* the total length of the pbuf chain is the requested size */ p->tot_len = length; /* set the length of the first pbuf in the chain */ p->len = LWIP_MIN(length, PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)); 802d106: 3603 adds r6, #3 802d108: f026 0603 bic.w r6, r6, #3 } p->type = type; p->next = NULL; /* make the payload pointer point 'offset' bytes into pbuf data memory */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset))); 802d10c: 3213 adds r2, #19 LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned", ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0); /* the total length of the pbuf chain is the requested size */ p->tot_len = length; /* set the length of the first pbuf in the chain */ p->len = LWIP_MIN(length, PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)); 802d10e: f5c6 66c0 rsb r6, r6, #1536 ; 0x600 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc: allocated pbuf %p\n", (void *)p)); if (p == NULL) { PBUF_POOL_IS_EMPTY(); return NULL; } p->type = type; 802d112: 2303 movs r3, #3 p->next = NULL; /* make the payload pointer point 'offset' bytes into pbuf data memory */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset))); 802d114: f022 0203 bic.w r2, r2, #3 LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned", ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0); /* the total length of the pbuf chain is the requested size */ p->tot_len = length; /* set the length of the first pbuf in the chain */ p->len = LWIP_MIN(length, PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)); 802d118: 3604 adds r6, #4 802d11a: 42ae cmp r6, r5 802d11c: bfa8 it ge 802d11e: 462e movge r6, r5 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc: allocated pbuf %p\n", (void *)p)); if (p == NULL) { PBUF_POOL_IS_EMPTY(); return NULL; } p->type = type; 802d120: 7303 strb r3, [r0, #12] p->next = NULL; /* make the payload pointer point 'offset' bytes into pbuf data memory */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset))); 802d122: 6042 str r2, [r0, #4] if (p == NULL) { PBUF_POOL_IS_EMPTY(); return NULL; } p->type = type; p->next = NULL; 802d124: 2300 movs r3, #0 ((u8_t*)p->payload + p->len <= (u8_t*)p + SIZEOF_STRUCT_PBUF + PBUF_POOL_BUFSIZE_ALIGNED)); LWIP_ASSERT("PBUF_POOL_BUFSIZE must be bigger than MEM_ALIGNMENT", (PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)) > 0 ); /* set reference count (needed here in case we fail) */ p->ref = 1; 802d126: 2201 movs r2, #1 LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned", ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0); /* the total length of the pbuf chain is the requested size */ p->tot_len = length; /* set the length of the first pbuf in the chain */ p->len = LWIP_MIN(length, PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)); 802d128: 8146 strh r6, [r0, #10] if (p == NULL) { PBUF_POOL_IS_EMPTY(); return NULL; } p->type = type; p->next = NULL; 802d12a: 6003 str r3, [r0, #0] /* make the payload pointer point 'offset' bytes into pbuf data memory */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset))); LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned", ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0); /* the total length of the pbuf chain is the requested size */ p->tot_len = length; 802d12c: 8105 strh r5, [r0, #8] ((u8_t*)p->payload + p->len <= (u8_t*)p + SIZEOF_STRUCT_PBUF + PBUF_POOL_BUFSIZE_ALIGNED)); LWIP_ASSERT("PBUF_POOL_BUFSIZE must be bigger than MEM_ALIGNMENT", (PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)) > 0 ); /* set reference count (needed here in case we fail) */ p->ref = 1; 802d12e: 81c2 strh r2, [r0, #14] /* now allocate the tail of the pbuf chain */ /* remember first pbuf for linkage in next iteration */ r = p; /* remaining length to be allocated */ rem_len = length - p->len; 802d130: 1bae subs r6, r5, r6 /* any remaining pbufs to be allocated? */ while (rem_len > 0) { 802d132: 4607 mov r7, r0 802d134: 4698 mov r8, r3 r->next = q; /* set total length of this pbuf and next in chain */ LWIP_ASSERT("rem_len < max_u16_t", rem_len < 0xffff); q->tot_len = (u16_t)rem_len; /* this pbuf length is pool size, unless smaller sized tail */ q->len = LWIP_MIN((u16_t)rem_len, PBUF_POOL_BUFSIZE_ALIGNED); 802d136: f240 6903 movw r9, #1539 ; 0x603 802d13a: f240 6a04 movw sl, #1540 ; 0x604 /* remember first pbuf for linkage in next iteration */ r = p; /* remaining length to be allocated */ rem_len = length - p->len; /* any remaining pbufs to be allocated? */ while (rem_len > 0) { 802d13e: e01c b.n 802d17a q = (struct pbuf *)memp_malloc(MEMP_PBUF_POOL); 802d140: 200f movs r0, #15 802d142: f7ff fe55 bl 802cdf0 if (q == NULL) { 802d146: 4605 mov r5, r0 802d148: b918 cbnz r0, 802d152 PBUF_POOL_IS_EMPTY(); /* free chain so far allocated */ pbuf_free(p); 802d14a: 4620 mov r0, r4 802d14c: f7ff ff70 bl 802d030 802d150: e03e b.n 802d1d0 /* bail out unsuccesfully */ return NULL; } q->type = type; 802d152: 2303 movs r3, #3 /* set total length of this pbuf and next in chain */ LWIP_ASSERT("rem_len < max_u16_t", rem_len < 0xffff); q->tot_len = (u16_t)rem_len; /* this pbuf length is pool size, unless smaller sized tail */ q->len = LWIP_MIN((u16_t)rem_len, PBUF_POOL_BUFSIZE_ALIGNED); q->payload = (void *)((u8_t *)q + SIZEOF_STRUCT_PBUF); 802d154: f100 0210 add.w r2, r0, #16 /* free chain so far allocated */ pbuf_free(p); /* bail out unsuccesfully */ return NULL; } q->type = type; 802d158: 7303 strb r3, [r0, #12] q->next = NULL; /* make previous pbuf point to this pbuf */ r->next = q; /* set total length of this pbuf and next in chain */ LWIP_ASSERT("rem_len < max_u16_t", rem_len < 0xffff); q->tot_len = (u16_t)rem_len; 802d15a: b2b3 uxth r3, r6 802d15c: 8103 strh r3, [r0, #8] /* this pbuf length is pool size, unless smaller sized tail */ q->len = LWIP_MIN((u16_t)rem_len, PBUF_POOL_BUFSIZE_ALIGNED); q->payload = (void *)((u8_t *)q + SIZEOF_STRUCT_PBUF); 802d15e: 6042 str r2, [r0, #4] r->next = q; /* set total length of this pbuf and next in chain */ LWIP_ASSERT("rem_len < max_u16_t", rem_len < 0xffff); q->tot_len = (u16_t)rem_len; /* this pbuf length is pool size, unless smaller sized tail */ q->len = LWIP_MIN((u16_t)rem_len, PBUF_POOL_BUFSIZE_ALIGNED); 802d160: 454b cmp r3, r9 802d162: bf88 it hi 802d164: 4653 movhi r3, sl LWIP_ASSERT("pbuf_alloc: pbuf q->payload properly aligned", ((mem_ptr_t)q->payload % MEM_ALIGNMENT) == 0); LWIP_ASSERT("check p->payload + p->len does not overflow pbuf", ((u8_t*)p->payload + p->len <= (u8_t*)p + SIZEOF_STRUCT_PBUF + PBUF_POOL_BUFSIZE_ALIGNED)); q->ref = 1; 802d166: 2201 movs r2, #1 /* bail out unsuccesfully */ return NULL; } q->type = type; q->flags = 0; q->next = NULL; 802d168: f8c0 8000 str.w r8, [r0] pbuf_free(p); /* bail out unsuccesfully */ return NULL; } q->type = type; q->flags = 0; 802d16c: f880 800d strb.w r8, [r0, #13] q->next = NULL; /* make previous pbuf point to this pbuf */ r->next = q; 802d170: 6038 str r0, [r7, #0] /* set total length of this pbuf and next in chain */ LWIP_ASSERT("rem_len < max_u16_t", rem_len < 0xffff); q->tot_len = (u16_t)rem_len; /* this pbuf length is pool size, unless smaller sized tail */ q->len = LWIP_MIN((u16_t)rem_len, PBUF_POOL_BUFSIZE_ALIGNED); 802d172: 8143 strh r3, [r0, #10] LWIP_ASSERT("pbuf_alloc: pbuf q->payload properly aligned", ((mem_ptr_t)q->payload % MEM_ALIGNMENT) == 0); LWIP_ASSERT("check p->payload + p->len does not overflow pbuf", ((u8_t*)p->payload + p->len <= (u8_t*)p + SIZEOF_STRUCT_PBUF + PBUF_POOL_BUFSIZE_ALIGNED)); q->ref = 1; 802d174: 81c2 strh r2, [r0, #14] /* calculate remaining length to be allocated */ rem_len -= q->len; 802d176: 1af6 subs r6, r6, r3 802d178: 4607 mov r7, r0 /* remember first pbuf for linkage in next iteration */ r = p; /* remaining length to be allocated */ rem_len = length - p->len; /* any remaining pbufs to be allocated? */ while (rem_len > 0) { 802d17a: 2e00 cmp r6, #0 802d17c: dce0 bgt.n 802d140 802d17e: e022 b.n 802d1c6 /*r->next = NULL;*/ break; case PBUF_RAM: /* If pbuf is to be allocated in RAM, allocate memory for it. */ p = (struct pbuf*)mem_malloc(LWIP_MEM_ALIGN_SIZE(SIZEOF_STRUCT_PBUF + offset) + LWIP_MEM_ALIGN_SIZE(length)); 802d180: f106 0013 add.w r0, r6, #19 802d184: 1ceb adds r3, r5, #3 802d186: f023 0303 bic.w r3, r3, #3 802d18a: f020 0003 bic.w r0, r0, #3 802d18e: 18c0 adds r0, r0, r3 802d190: b280 uxth r0, r0 802d192: f7ff fda3 bl 802ccdc if (p == NULL) { 802d196: 4604 mov r4, r0 802d198: b1d0 cbz r0, 802d1d0 return NULL; } /* Set up internal structure of the pbuf. */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + SIZEOF_STRUCT_PBUF + offset)); 802d19a: 1986 adds r6, r0, r6 802d19c: 3613 adds r6, #19 p->len = p->tot_len = length; p->next = NULL; 802d19e: 2300 movs r3, #0 p = (struct pbuf*)mem_malloc(LWIP_MEM_ALIGN_SIZE(SIZEOF_STRUCT_PBUF + offset) + LWIP_MEM_ALIGN_SIZE(length)); if (p == NULL) { return NULL; } /* Set up internal structure of the pbuf. */ p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + SIZEOF_STRUCT_PBUF + offset)); 802d1a0: f026 0603 bic.w r6, r6, #3 802d1a4: 6046 str r6, [r0, #4] p->len = p->tot_len = length; 802d1a6: 8105 strh r5, [r0, #8] 802d1a8: 8145 strh r5, [r0, #10] p->next = NULL; 802d1aa: 6003 str r3, [r0, #0] p->type = type; 802d1ac: 7303 strb r3, [r0, #12] 802d1ae: e00a b.n 802d1c6 /* pbuf references existing (non-volatile static constant) ROM payload? */ case PBUF_ROM: /* pbuf references existing (externally allocated) RAM payload? */ case PBUF_REF: /* only allocate memory for the pbuf structure */ p = (struct pbuf *)memp_malloc(MEMP_PBUF); 802d1b0: 200e movs r0, #14 802d1b2: f7ff fe1d bl 802cdf0 if (p == NULL) { 802d1b6: 4604 mov r4, r0 802d1b8: b150 cbz r0, 802d1d0 ("pbuf_alloc: Could not allocate MEMP_PBUF for PBUF_%s.\n", (type == PBUF_ROM) ? "ROM" : "REF")); return NULL; } /* caller must set this field properly, afterwards */ p->payload = NULL; 802d1ba: 2300 movs r3, #0 802d1bc: 6043 str r3, [r0, #4] p->len = p->tot_len = length; 802d1be: 8105 strh r5, [r0, #8] 802d1c0: 8145 strh r5, [r0, #10] p->next = NULL; 802d1c2: 6003 str r3, [r0, #0] p->type = type; 802d1c4: 7307 strb r7, [r0, #12] default: LWIP_ASSERT("pbuf_alloc: erroneous type", 0); return NULL; } /* set reference count */ p->ref = 1; 802d1c6: 2301 movs r3, #1 802d1c8: 81e3 strh r3, [r4, #14] /* set flags */ p->flags = 0; 802d1ca: 2300 movs r3, #0 802d1cc: 7363 strb r3, [r4, #13] LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc(length=%"U16_F") == %p\n", length, (void *)p)); return p; 802d1ce: e000 b.n 802d1d2 p->next = NULL; p->type = type; break; default: LWIP_ASSERT("pbuf_alloc: erroneous type", 0); return NULL; 802d1d0: 2400 movs r4, #0 p->ref = 1; /* set flags */ p->flags = 0; LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_alloc(length=%"U16_F") == %p\n", length, (void *)p)); return p; } 802d1d2: 4620 mov r0, r4 802d1d4: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 0802d1d8 : * @return the number of pbufs in a chain */ u8_t pbuf_clen(struct pbuf *p) { 802d1d8: 4603 mov r3, r0 u8_t len; len = 0; 802d1da: 2000 movs r0, #0 while (p != NULL) { 802d1dc: e002 b.n 802d1e4 ++len; 802d1de: 3001 adds r0, #1 p = p->next; 802d1e0: 681b ldr r3, [r3, #0] { u8_t len; len = 0; while (p != NULL) { ++len; 802d1e2: b2c0 uxtb r0, r0 pbuf_clen(struct pbuf *p) { u8_t len; len = 0; while (p != NULL) { 802d1e4: 2b00 cmp r3, #0 802d1e6: d1fa bne.n 802d1de ++len; p = p->next; } return len; } 802d1e8: 4770 bx lr 0802d1ea : * @param p pbuf to increase reference counter of * */ void pbuf_ref(struct pbuf *p) { 802d1ea: b510 push {r4, lr} SYS_ARCH_DECL_PROTECT(old_level); /* pbuf given? */ if (p != NULL) { 802d1ec: 4604 mov r4, r0 802d1ee: b140 cbz r0, 802d202 SYS_ARCH_PROTECT(old_level); 802d1f0: f007 fba2 bl 8034938 ++(p->ref); 802d1f4: 89e3 ldrh r3, [r4, #14] 802d1f6: 3301 adds r3, #1 802d1f8: 81e3 strh r3, [r4, #14] SYS_ARCH_UNPROTECT(old_level); } } 802d1fa: e8bd 4010 ldmia.w sp!, {r4, lr} SYS_ARCH_DECL_PROTECT(old_level); /* pbuf given? */ if (p != NULL) { SYS_ARCH_PROTECT(old_level); ++(p->ref); SYS_ARCH_UNPROTECT(old_level); 802d1fe: f007 bba5 b.w 803494c 802d202: bd10 pop {r4, pc} 0802d204 : * @see pbuf_chain() */ void pbuf_cat(struct pbuf *h, struct pbuf *t) { 802d204: b510 push {r4, lr} struct pbuf *p; LWIP_ERROR("(h != NULL) && (t != NULL) (programmer violates API)", 802d206: b168 cbz r0, 802d224 802d208: b161 cbz r1, 802d224 802d20a: e003 b.n 802d214 ((h != NULL) && (t != NULL)), return;); /* proceed to last pbuf of chain */ for (p = h; p->next != NULL; p = p->next) { /* add total length of second chain to all totals of first chain */ p->tot_len += t->tot_len; 802d20c: 8904 ldrh r4, [r0, #8] 802d20e: 191b adds r3, r3, r4 802d210: 8103 strh r3, [r0, #8] LWIP_ERROR("(h != NULL) && (t != NULL) (programmer violates API)", ((h != NULL) && (t != NULL)), return;); /* proceed to last pbuf of chain */ for (p = h; p->next != NULL; p = p->next) { 802d212: 4610 mov r0, r2 802d214: 6802 ldr r2, [r0, #0] 802d216: 890b ldrh r3, [r1, #8] 802d218: 2a00 cmp r2, #0 802d21a: d1f7 bne.n 802d20c } /* { p is last pbuf of first h chain, p->next == NULL } */ LWIP_ASSERT("p->tot_len == p->len (of last pbuf in chain)", p->tot_len == p->len); LWIP_ASSERT("p->next == NULL", p->next == NULL); /* add total length of second chain to last pbuf total of first chain */ p->tot_len += t->tot_len; 802d21c: 8902 ldrh r2, [r0, #8] /* chain last pbuf of head (p) with first of tail (t) */ p->next = t; 802d21e: 6001 str r1, [r0, #0] } /* { p is last pbuf of first h chain, p->next == NULL } */ LWIP_ASSERT("p->tot_len == p->len (of last pbuf in chain)", p->tot_len == p->len); LWIP_ASSERT("p->next == NULL", p->next == NULL); /* add total length of second chain to last pbuf total of first chain */ p->tot_len += t->tot_len; 802d220: 189b adds r3, r3, r2 802d222: 8103 strh r3, [r0, #8] 802d224: bd10 pop {r4, pc} 0802d226 : * The ->ref field of the first pbuf of the tail chain is adjusted. * */ void pbuf_chain(struct pbuf *h, struct pbuf *t) { 802d226: b510 push {r4, lr} 802d228: 460c mov r4, r1 pbuf_cat(h, t); 802d22a: f7ff ffeb bl 802d204 /* t is now referenced by h */ pbuf_ref(t); 802d22e: 4620 mov r0, r4 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_chain: %p references %p\n", (void *)h, (void *)t)); } 802d230: e8bd 4010 ldmia.w sp!, {r4, lr} void pbuf_chain(struct pbuf *h, struct pbuf *t) { pbuf_cat(h, t); /* t is now referenced by h */ pbuf_ref(t); 802d234: f7ff bfd9 b.w 802d1ea 0802d238 : * ERR_ARG if one of the pbufs is NULL or p_to is not big * enough to hold p_from */ err_t pbuf_copy(struct pbuf *p_to, struct pbuf *p_from) { 802d238: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 802d23c: 460c mov r4, r1 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_copy(%p, %p)\n", (void*)p_to, (void*)p_from)); /* is the target big enough to hold the source? */ LWIP_ERROR("pbuf_copy: target not big enough to hold source", ((p_to != NULL) && 802d23e: 4605 mov r5, r0 802d240: b908 cbnz r0, 802d246 802d242: 20f2 movs r0, #242 ; 0xf2 802d244: e03f b.n 802d2c6 802d246: 2900 cmp r1, #0 802d248: d0fb beq.n 802d242 802d24a: 8902 ldrh r2, [r0, #8] 802d24c: 890b ldrh r3, [r1, #8] 802d24e: 429a cmp r2, r3 802d250: d3f7 bcc.n 802d242 802d252: 2600 movs r6, #0 802d254: 4637 mov r7, r6 /* iterate through pbuf chain */ do { /* copy one part of the original chain */ if ((p_to->len - offset_to) >= (p_from->len - offset_from)) { 802d256: f8b4 800a ldrh.w r8, [r4, #10] 802d25a: 896b ldrh r3, [r5, #10] len = p_from->len - offset_from; } else { /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; } MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len); 802d25c: 6861 ldr r1, [r4, #4] 802d25e: 6868 ldr r0, [r5, #4] /* iterate through pbuf chain */ do { /* copy one part of the original chain */ if ((p_to->len - offset_to) >= (p_from->len - offset_from)) { 802d260: ebc6 0808 rsb r8, r6, r8 802d264: 1bdb subs r3, r3, r7 802d266: 4543 cmp r3, r8 /* complete current p_from fits into current p_to */ len = p_from->len - offset_from; } else { /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; 802d268: bfb4 ite lt 802d26a: fa1f f883 uxthlt.w r8, r3 do { /* copy one part of the original chain */ if ((p_to->len - offset_to) >= (p_from->len - offset_from)) { /* complete current p_from fits into current p_to */ len = p_from->len - offset_from; 802d26e: fa1f f888 uxthge.w r8, r8 } else { /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; } MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len); 802d272: 19c0 adds r0, r0, r7 802d274: 1989 adds r1, r1, r6 802d276: 4642 mov r2, r8 802d278: f7f4 fb68 bl 802194c offset_to += len; offset_from += len; 802d27c: 4446 add r6, r8 LWIP_ASSERT("offset_to <= p_to->len", offset_to <= p_to->len); LWIP_ASSERT("offset_from <= p_from->len", offset_from <= p_from->len); if (offset_from >= p_from->len) { 802d27e: 8963 ldrh r3, [r4, #10] /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; } MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len); offset_to += len; offset_from += len; 802d280: b2b6 uxth r6, r6 LWIP_ASSERT("offset_to <= p_to->len", offset_to <= p_to->len); LWIP_ASSERT("offset_from <= p_from->len", offset_from <= p_from->len); if (offset_from >= p_from->len) { 802d282: 42b3 cmp r3, r6 } else { /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; } MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len); offset_to += len; 802d284: 4447 add r7, r8 if (offset_from >= p_from->len) { /* on to next p_from (if any) */ offset_from = 0; p_from = p_from->next; } if (offset_to == p_to->len) { 802d286: 896b ldrh r3, [r5, #10] LWIP_ASSERT("offset_to <= p_to->len", offset_to <= p_to->len); LWIP_ASSERT("offset_from <= p_from->len", offset_from <= p_from->len); if (offset_from >= p_from->len) { /* on to next p_from (if any) */ offset_from = 0; p_from = p_from->next; 802d288: bf98 it ls 802d28a: 6824 ldrls r4, [r4, #0] } else { /* current p_from does not fit into current p_to */ len = p_to->len - offset_to; } MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len); offset_to += len; 802d28c: b2bf uxth r7, r7 offset_from += len; LWIP_ASSERT("offset_to <= p_to->len", offset_to <= p_to->len); LWIP_ASSERT("offset_from <= p_from->len", offset_from <= p_from->len); if (offset_from >= p_from->len) { /* on to next p_from (if any) */ offset_from = 0; 802d28e: bf98 it ls 802d290: 2600 movls r6, #0 p_from = p_from->next; } if (offset_to == p_to->len) { 802d292: 42bb cmp r3, r7 802d294: d105 bne.n 802d2a2 /* on to next p_to (if any) */ offset_to = 0; p_to = p_to->next; 802d296: 682d ldr r5, [r5, #0] LWIP_ERROR("p_to != NULL", (p_to != NULL) || (p_from == NULL) , return ERR_ARG;); 802d298: b915 cbnz r5, 802d2a0 802d29a: 2c00 cmp r4, #0 802d29c: d1d1 bne.n 802d242 802d29e: e00f b.n 802d2c0 offset_from = 0; p_from = p_from->next; } if (offset_to == p_to->len) { /* on to next p_to (if any) */ offset_to = 0; 802d2a0: 2700 movs r7, #0 p_to = p_to->next; LWIP_ERROR("p_to != NULL", (p_to != NULL) || (p_from == NULL) , return ERR_ARG;); } if((p_from != NULL) && (p_from->len == p_from->tot_len)) { 802d2a2: b12c cbz r4, 802d2b0 802d2a4: 8962 ldrh r2, [r4, #10] 802d2a6: 8923 ldrh r3, [r4, #8] 802d2a8: 429a cmp r2, r3 802d2aa: d101 bne.n 802d2b0 /* don't copy more than one packet! */ LWIP_ERROR("pbuf_copy() does not allow packet queues!\n", 802d2ac: 6823 ldr r3, [r4, #0] 802d2ae: b94b cbnz r3, 802d2c4 (p_from->next == NULL), return ERR_VAL;); } if((p_to != NULL) && (p_to->len == p_to->tot_len)) { 802d2b0: 896a ldrh r2, [r5, #10] 802d2b2: 892b ldrh r3, [r5, #8] 802d2b4: 429a cmp r2, r3 802d2b6: d101 bne.n 802d2bc /* don't copy more than one packet! */ LWIP_ERROR("pbuf_copy() does not allow packet queues!\n", 802d2b8: 682b ldr r3, [r5, #0] 802d2ba: b91b cbnz r3, 802d2c4 (p_to->next == NULL), return ERR_VAL;); } } while (p_from); 802d2bc: 2c00 cmp r4, #0 802d2be: d1ca bne.n 802d256 LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_copy: end of chain reached.\n")); return ERR_OK; 802d2c0: 4620 mov r0, r4 802d2c2: e000 b.n 802d2c6 LWIP_ERROR("p_to != NULL", (p_to != NULL) || (p_from == NULL) , return ERR_ARG;); } if((p_from != NULL) && (p_from->len == p_from->tot_len)) { /* don't copy more than one packet! */ LWIP_ERROR("pbuf_copy() does not allow packet queues!\n", 802d2c4: 20fa movs r0, #250 ; 0xfa (p_to->next == NULL), return ERR_VAL;); } } while (p_from); LWIP_DEBUGF(PBUF_DEBUG | LWIP_DBG_TRACE, ("pbuf_copy: end of chain reached.\n")); return ERR_OK; } 802d2c6: b240 sxtb r0, r0 802d2c8: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 0802d2cc : * @param offset offset into the packet buffer from where to begin copying len bytes * @return the number of bytes copied, or 0 on failure */ u16_t pbuf_copy_partial(struct pbuf *buf, void *dataptr, u16_t len, u16_t offset) { 802d2cc: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 802d2d0: 4688 mov r8, r1 802d2d2: 4616 mov r6, r2 struct pbuf *p; u16_t left; u16_t buf_copy_len; u16_t copied_total = 0; LWIP_ERROR("pbuf_copy_partial: invalid buf", (buf != NULL), return 0;); 802d2d4: b328 cbz r0, 802d322 LWIP_ERROR("pbuf_copy_partial: invalid dataptr", (dataptr != NULL), return 0;); 802d2d6: b331 cbz r1, 802d326 802d2d8: 2400 movs r4, #0 802d2da: 4605 mov r5, r0 802d2dc: 46a1 mov r9, r4 802d2de: e01c b.n 802d31a return 0; } /* Note some systems use byte copy if dataptr or one of the pbuf payload pointers are unaligned. */ for(p = buf; len != 0 && p != NULL; p = p->next) { if ((offset != 0) && (offset >= p->len)) { 802d2e0: b12b cbz r3, 802d2ee 802d2e2: 896a ldrh r2, [r5, #10] 802d2e4: 4293 cmp r3, r2 802d2e6: d302 bcc.n 802d2ee /* don't copy from this buffer -> on to the next */ offset -= p->len; 802d2e8: 1a9b subs r3, r3, r2 802d2ea: b29b uxth r3, r3 802d2ec: e014 b.n 802d318 } else { /* copy from this buffer. maybe only partially. */ buf_copy_len = p->len - offset; 802d2ee: 896f ldrh r7, [r5, #10] if (buf_copy_len > len) buf_copy_len = len; /* copy the necessary parts of the buffer */ MEMCPY(&((char*)dataptr)[left], &((char*)p->payload)[offset], buf_copy_len); 802d2f0: 6869 ldr r1, [r5, #4] if ((offset != 0) && (offset >= p->len)) { /* don't copy from this buffer -> on to the next */ offset -= p->len; } else { /* copy from this buffer. maybe only partially. */ buf_copy_len = p->len - offset; 802d2f2: 1aff subs r7, r7, r3 802d2f4: b2bf uxth r7, r7 802d2f6: 42b7 cmp r7, r6 802d2f8: bf28 it cs 802d2fa: 4637 movcs r7, r6 if (buf_copy_len > len) buf_copy_len = len; /* copy the necessary parts of the buffer */ MEMCPY(&((char*)dataptr)[left], &((char*)p->payload)[offset], buf_copy_len); 802d2fc: eb08 0009 add.w r0, r8, r9 802d300: 18c9 adds r1, r1, r3 802d302: 463a mov r2, r7 copied_total += buf_copy_len; 802d304: 193c adds r4, r7, r4 left += buf_copy_len; 802d306: 44b9 add r9, r7 len -= buf_copy_len; 802d308: 1bf6 subs r6, r6, r7 /* copy from this buffer. maybe only partially. */ buf_copy_len = p->len - offset; if (buf_copy_len > len) buf_copy_len = len; /* copy the necessary parts of the buffer */ MEMCPY(&((char*)dataptr)[left], &((char*)p->payload)[offset], buf_copy_len); 802d30a: f7f4 fb1f bl 802194c copied_total += buf_copy_len; 802d30e: b2a4 uxth r4, r4 left += buf_copy_len; 802d310: fa1f f989 uxth.w r9, r9 len -= buf_copy_len; 802d314: b2b6 uxth r6, r6 offset = 0; 802d316: 2300 movs r3, #0 if((buf == NULL) || (dataptr == NULL)) { return 0; } /* Note some systems use byte copy if dataptr or one of the pbuf payload pointers are unaligned. */ for(p = buf; len != 0 && p != NULL; p = p->next) { 802d318: 682d ldr r5, [r5, #0] 802d31a: b12e cbz r6, 802d328 802d31c: 2d00 cmp r5, #0 802d31e: d1df bne.n 802d2e0 802d320: e002 b.n 802d328 struct pbuf *p; u16_t left; u16_t buf_copy_len; u16_t copied_total = 0; LWIP_ERROR("pbuf_copy_partial: invalid buf", (buf != NULL), return 0;); 802d322: 4604 mov r4, r0 802d324: e000 b.n 802d328 802d326: 460c mov r4, r1 len -= buf_copy_len; offset = 0; } } return copied_total; } 802d328: 4620 mov r0, r4 802d32a: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 802d32e: 0000 movs r0, r0 0802d330 : * caller). * */ u8_t raw_input(struct pbuf *p, struct netif *inp) { 802d330: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} u8_t eaten = 0; LWIP_UNUSED_ARG(inp); iphdr = (struct ip_hdr *)p->payload; proto = IPH_PROTO(iphdr); 802d334: 6843 ldr r3, [r0, #4] /* loop through all raw pcbs until the packet is eaten by one */ /* this allows multiple pcbs to match against the packet by design */ while ((eaten == 0) && (pcb != NULL)) { if ((pcb->protocol == proto) && (ip_addr_isany(&pcb->local_ip) || ip_addr_cmp(&(pcb->local_ip), ¤t_iphdr_dest))) { 802d336: f8df a074 ldr.w sl, [pc, #116] ; 802d3ac u8_t eaten = 0; LWIP_UNUSED_ARG(inp); iphdr = (struct ip_hdr *)p->payload; proto = IPH_PROTO(iphdr); 802d33a: f893 9009 ldrb.w r9, [r3, #9] prev = NULL; pcb = raw_pcbs; 802d33e: 4b19 ldr r3, [pc, #100] ; (802d3a4 ) * caller). * */ u8_t raw_input(struct pbuf *p, struct netif *inp) { 802d340: 4606 mov r6, r0 iphdr = (struct ip_hdr *)p->payload; proto = IPH_PROTO(iphdr); prev = NULL; pcb = raw_pcbs; 802d342: 681c ldr r4, [r3, #0] LWIP_UNUSED_ARG(inp); iphdr = (struct ip_hdr *)p->payload; proto = IPH_PROTO(iphdr); prev = NULL; 802d344: 2500 movs r5, #0 eaten = 1; if (prev != NULL) { /* move the pcb to the front of raw_pcbs so that is found faster next time */ prev->next = pcb->next; pcb->next = raw_pcbs; 802d346: 4698 mov r8, r3 802d348: e023 b.n 802d392 prev = NULL; pcb = raw_pcbs; /* loop through all raw pcbs until the packet is eaten by one */ /* this allows multiple pcbs to match against the packet by design */ while ((eaten == 0) && (pcb != NULL)) { if ((pcb->protocol == proto) && 802d34a: 7c23 ldrb r3, [r4, #16] 802d34c: 454b cmp r3, r9 802d34e: d118 bne.n 802d382 (ip_addr_isany(&pcb->local_ip) || 802d350: 6823 ldr r3, [r4, #0] 802d352: b11b cbz r3, 802d35c 802d354: f8da 2000 ldr.w r2, [sl] 802d358: 4293 cmp r3, r2 802d35a: d112 bne.n 802d382 /* broadcast filter? */ if (ip_get_option(pcb, SOF_BROADCAST) || !ip_addr_isbroadcast(¤t_iphdr_dest, inp)) #endif /* IP_SOF_BROADCAST_RECV */ { /* receive callback function available? */ if (pcb->recv != NULL) { 802d35c: 6967 ldr r7, [r4, #20] 802d35e: b187 cbz r7, 802d382 /* the receive callback function did not eat the packet? */ if (pcb->recv(pcb->recv_arg, pcb, p, ip_current_src_addr()) != 0) { 802d360: 69a0 ldr r0, [r4, #24] 802d362: 4b11 ldr r3, [pc, #68] ; (802d3a8 ) 802d364: 4621 mov r1, r4 802d366: 4632 mov r2, r6 802d368: 47b8 blx r7 802d36a: b150 cbz r0, 802d382 /* receive function ate the packet */ p = NULL; eaten = 1; if (prev != NULL) { 802d36c: b15d cbz r5, 802d386 /* move the pcb to the front of raw_pcbs so that is found faster next time */ prev->next = pcb->next; 802d36e: 68e3 ldr r3, [r4, #12] 802d370: 60eb str r3, [r5, #12] pcb->next = raw_pcbs; 802d372: f8d8 3000 ldr.w r3, [r8] raw_pcbs = pcb; 802d376: f8c8 4000 str.w r4, [r8] eaten = 1; if (prev != NULL) { /* move the pcb to the front of raw_pcbs so that is found faster next time */ prev->next = pcb->next; pcb->next = raw_pcbs; 802d37a: 60e3 str r3, [r4, #12] /* receive callback function available? */ if (pcb->recv != NULL) { /* the receive callback function did not eat the packet? */ if (pcb->recv(pcb->recv_arg, pcb, p, ip_current_src_addr()) != 0) { /* receive function ate the packet */ p = NULL; 802d37c: 2600 movs r6, #0 eaten = 1; 802d37e: 2301 movs r3, #1 802d380: e003 b.n 802d38a pcb = raw_pcbs; /* loop through all raw pcbs until the packet is eaten by one */ /* this allows multiple pcbs to match against the packet by design */ while ((eaten == 0) && (pcb != NULL)) { if ((pcb->protocol == proto) && (ip_addr_isany(&pcb->local_ip) || 802d382: 2300 movs r3, #0 802d384: e001 b.n 802d38a if (pcb->recv != NULL) { /* the receive callback function did not eat the packet? */ if (pcb->recv(pcb->recv_arg, pcb, p, ip_current_src_addr()) != 0) { /* receive function ate the packet */ p = NULL; eaten = 1; 802d386: 2301 movs r3, #1 /* receive callback function available? */ if (pcb->recv != NULL) { /* the receive callback function did not eat the packet? */ if (pcb->recv(pcb->recv_arg, pcb, p, ip_current_src_addr()) != 0) { /* receive function ate the packet */ p = NULL; 802d388: 462e mov r6, r5 /* no receive callback function was set for this raw PCB */ } /* drop the packet */ } prev = pcb; pcb = pcb->next; 802d38a: 68e2 ldr r2, [r4, #12] 802d38c: 4625 mov r5, r4 prev = NULL; pcb = raw_pcbs; /* loop through all raw pcbs until the packet is eaten by one */ /* this allows multiple pcbs to match against the packet by design */ while ((eaten == 0) && (pcb != NULL)) { 802d38e: b92b cbnz r3, 802d39c /* no receive callback function was set for this raw PCB */ } /* drop the packet */ } prev = pcb; pcb = pcb->next; 802d390: 4614 mov r4, r2 prev = NULL; pcb = raw_pcbs; /* loop through all raw pcbs until the packet is eaten by one */ /* this allows multiple pcbs to match against the packet by design */ while ((eaten == 0) && (pcb != NULL)) { 802d392: 2c00 cmp r4, #0 802d394: d1d9 bne.n 802d34a 802d396: 4620 mov r0, r4 802d398: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 802d39c: 2001 movs r0, #1 } prev = pcb; pcb = pcb->next; } return eaten; } 802d39e: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 802d3a2: bf00 nop 802d3a4: 2000e0e8 .word 0x2000e0e8 802d3a8: 20010ffc .word 0x20010ffc 802d3ac: 20011004 .word 0x20011004 0802d3b0 : LWIP_UNUSED_ARG(arg); LWIP_UNUSED_ARG(pcb); LWIP_UNUSED_ARG(err); return ERR_ABRT; } 802d3b0: f06f 0009 mvn.w r0, #9 802d3b4: 4770 bx lr 802d3b6: 0000 movs r0, r0 0802d3b8 : * * @return a new (free) local TCP port number */ static u16_t tcp_new_port(void) { 802d3b8: 4b13 ldr r3, [pc, #76] ; (802d408 ) 802d3ba: b570 push {r4, r5, r6, lr} 802d3bc: 8818 ldrh r0, [r3, #0] if (tcp_port++ == TCP_LOCAL_PORT_RANGE_END) { tcp_port = TCP_LOCAL_PORT_RANGE_START; } /* Check all PCB lists. */ for (i = 0; i < NUM_TCP_PCB_LISTS; i++) { for(pcb = *tcp_pcb_lists[i]; pcb != NULL; pcb = pcb->next) { 802d3be: 4d13 ldr r5, [pc, #76] ; (802d40c ) * * @return a new (free) local TCP port number */ static u16_t tcp_new_port(void) { 802d3c0: f44f 4280 mov.w r2, #16384 ; 0x4000 u8_t i; u16_t n = 0; struct tcp_pcb *pcb; again: if (tcp_port++ == TCP_LOCAL_PORT_RANGE_END) { 802d3c4: f64f 74ff movw r4, #65535 ; 0xffff 802d3c8: 42a0 cmp r0, r4 802d3ca: d002 beq.n 802d3d2 802d3cc: 3001 adds r0, #1 802d3ce: b280 uxth r0, r0 802d3d0: e001 b.n 802d3d6 tcp_port = TCP_LOCAL_PORT_RANGE_START; 802d3d2: f44f 4040 mov.w r0, #49152 ; 0xc000 802d3d6: 2300 movs r3, #0 } /* Check all PCB lists. */ for (i = 0; i < NUM_TCP_PCB_LISTS; i++) { for(pcb = *tcp_pcb_lists[i]; pcb != NULL; pcb = pcb->next) { 802d3d8: 5959 ldr r1, [r3, r5] 802d3da: 6809 ldr r1, [r1, #0] 802d3dc: e00b b.n 802d3f6 if (pcb->local_port == tcp_port) { 802d3de: 8b4e ldrh r6, [r1, #26] 802d3e0: 4286 cmp r6, r0 802d3e2: d107 bne.n 802d3f4 802d3e4: 3a01 subs r2, #1 802d3e6: b292 uxth r2, r2 if (++n > (TCP_LOCAL_PORT_RANGE_END - TCP_LOCAL_PORT_RANGE_START)) { 802d3e8: 2a00 cmp r2, #0 802d3ea: d1ed bne.n 802d3c8 802d3ec: 4b06 ldr r3, [pc, #24] ; (802d408 ) 802d3ee: 8018 strh r0, [r3, #0] return 0; 802d3f0: 4610 mov r0, r2 802d3f2: bd70 pop {r4, r5, r6, pc} if (tcp_port++ == TCP_LOCAL_PORT_RANGE_END) { tcp_port = TCP_LOCAL_PORT_RANGE_START; } /* Check all PCB lists. */ for (i = 0; i < NUM_TCP_PCB_LISTS; i++) { for(pcb = *tcp_pcb_lists[i]; pcb != NULL; pcb = pcb->next) { 802d3f4: 68c9 ldr r1, [r1, #12] 802d3f6: 2900 cmp r1, #0 802d3f8: d1f1 bne.n 802d3de 802d3fa: 3304 adds r3, #4 again: if (tcp_port++ == TCP_LOCAL_PORT_RANGE_END) { tcp_port = TCP_LOCAL_PORT_RANGE_START; } /* Check all PCB lists. */ for (i = 0; i < NUM_TCP_PCB_LISTS; i++) { 802d3fc: 2b10 cmp r3, #16 802d3fe: d1eb bne.n 802d3d8 802d400: 4b01 ldr r3, [pc, #4] ; (802d408 ) 802d402: 8018 strh r0, [r3, #0] goto again; } } } return tcp_port; } 802d404: bd70 pop {r4, r5, r6, pc} 802d406: bf00 nop 802d408: 200015ec .word 0x200015ec 802d40c: 0803fe60 .word 0x0803fe60 0802d410 : /** * Initialize this module. */ void tcp_init(void) { 802d410: 4770 bx lr 802d412: 0000 movs r0, r0 0802d414 : * ERR_VAL if bind failed because the PCB is not in a valid state * ERR_OK if bound */ err_t tcp_bind(struct tcp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802d414: b5f8 push {r3, r4, r5, r6, r7, lr} int i; int max_pcb_list = NUM_TCP_PCB_LISTS; struct tcp_pcb *cpcb; LWIP_ERROR("tcp_bind: can only bind in state CLOSED", pcb->state == CLOSED, return ERR_VAL); 802d416: 7e03 ldrb r3, [r0, #24] * ERR_VAL if bind failed because the PCB is not in a valid state * ERR_OK if bound */ err_t tcp_bind(struct tcp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802d418: 4604 mov r4, r0 802d41a: 460d mov r5, r1 int i; int max_pcb_list = NUM_TCP_PCB_LISTS; struct tcp_pcb *cpcb; LWIP_ERROR("tcp_bind: can only bind in state CLOSED", pcb->state == CLOSED, return ERR_VAL); 802d41c: bb33 cbnz r3, 802d46c if (ip_get_option(pcb, SOF_REUSEADDR)) { max_pcb_list = NUM_TCP_PCB_LISTS_NO_TIME_WAIT; } #endif /* SO_REUSE */ if (port == 0) { 802d41e: b91a cbnz r2, 802d428 port = tcp_new_port(); 802d420: f7ff ffca bl 802d3b8 if (port == 0) { 802d424: 4602 mov r2, r0 802d426: b318 cbz r0, 802d470 } } /* Check if the address already is in use (on all lists) */ for (i = 0; i < max_pcb_list; i++) { for(cpcb = *tcp_pcb_lists[i]; cpcb != NULL; cpcb = cpcb->next) { 802d428: 4f14 ldr r7, [pc, #80] ; (802d47c ) * ERR_VAL if bind failed because the PCB is not in a valid state * ERR_OK if bound */ err_t tcp_bind(struct tcp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802d42a: 2100 movs r1, #0 } } /* Check if the address already is in use (on all lists) */ for (i = 0; i < max_pcb_list; i++) { for(cpcb = *tcp_pcb_lists[i]; cpcb != NULL; cpcb = cpcb->next) { 802d42c: 59cb ldr r3, [r1, r7] 802d42e: 681b ldr r3, [r3, #0] 802d430: e00a b.n 802d448 if (cpcb->local_port == port) { 802d432: 8b58 ldrh r0, [r3, #26] 802d434: 4290 cmp r0, r2 802d436: d106 bne.n 802d446 tcp_connect. */ if (!ip_get_option(pcb, SOF_REUSEADDR) || !ip_get_option(cpcb, SOF_REUSEADDR)) #endif /* SO_REUSE */ { if (ip_addr_isany(&(cpcb->local_ip)) || 802d438: 681e ldr r6, [r3, #0] 802d43a: b1de cbz r6, 802d474 802d43c: b1d5 cbz r5, 802d474 ip_addr_isany(ipaddr) || 802d43e: 6828 ldr r0, [r5, #0] 802d440: b1c0 cbz r0, 802d474 802d442: 4286 cmp r6, r0 802d444: d016 beq.n 802d474 } } /* Check if the address already is in use (on all lists) */ for (i = 0; i < max_pcb_list; i++) { for(cpcb = *tcp_pcb_lists[i]; cpcb != NULL; cpcb = cpcb->next) { 802d446: 68db ldr r3, [r3, #12] 802d448: 2b00 cmp r3, #0 802d44a: d1f2 bne.n 802d432 802d44c: 3104 adds r1, #4 return ERR_BUF; } } /* Check if the address already is in use (on all lists) */ for (i = 0; i < max_pcb_list; i++) { 802d44e: 2910 cmp r1, #16 802d450: d1ec bne.n 802d42c } } } } if (!ip_addr_isany(ipaddr)) { 802d452: b115 cbz r5, 802d45a 802d454: 682b ldr r3, [r5, #0] 802d456: b103 cbz r3, 802d45a pcb->local_ip = *ipaddr; 802d458: 6023 str r3, [r4, #0] } pcb->local_port = port; TCP_REG(&tcp_bound_pcbs, pcb); 802d45a: 4b09 ldr r3, [pc, #36] ; (802d480 ) } if (!ip_addr_isany(ipaddr)) { pcb->local_ip = *ipaddr; } pcb->local_port = port; 802d45c: 8362 strh r2, [r4, #26] TCP_REG(&tcp_bound_pcbs, pcb); 802d45e: 681a ldr r2, [r3, #0] 802d460: 601c str r4, [r3, #0] 802d462: 60e2 str r2, [r4, #12] 802d464: f002 f8de bl 802f624 LWIP_DEBUGF(TCP_DEBUG, ("tcp_bind: bind to port %"U16_F"\n", port)); return ERR_OK; 802d468: 2000 movs r0, #0 802d46a: e004 b.n 802d476 { int i; int max_pcb_list = NUM_TCP_PCB_LISTS; struct tcp_pcb *cpcb; LWIP_ERROR("tcp_bind: can only bind in state CLOSED", pcb->state == CLOSED, return ERR_VAL); 802d46c: 20fa movs r0, #250 ; 0xfa 802d46e: e002 b.n 802d476 #endif /* SO_REUSE */ if (port == 0) { port = tcp_new_port(); if (port == 0) { return ERR_BUF; 802d470: 20fe movs r0, #254 ; 0xfe 802d472: e000 b.n 802d476 #endif /* SO_REUSE */ { if (ip_addr_isany(&(cpcb->local_ip)) || ip_addr_isany(ipaddr) || ip_addr_cmp(&(cpcb->local_ip), ipaddr)) { return ERR_USE; 802d474: 20f8 movs r0, #248 ; 0xf8 } pcb->local_port = port; TCP_REG(&tcp_bound_pcbs, pcb); LWIP_DEBUGF(TCP_DEBUG, ("tcp_bind: bind to port %"U16_F"\n", port)); return ERR_OK; } 802d476: b240 sxtb r0, r0 802d478: bdf8 pop {r3, r4, r5, r6, r7, pc} 802d47a: bf00 nop 802d47c: 0803fe60 .word 0x0803fe60 802d480: 20010fec .word 0x20010fec 0802d484 : * called like this: * tpcb = tcp_listen(tpcb); */ struct tcp_pcb * tcp_listen_with_backlog(struct tcp_pcb *pcb, u8_t backlog) { 802d484: b538 push {r3, r4, r5, lr} struct tcp_pcb_listen *lpcb; LWIP_UNUSED_ARG(backlog); LWIP_ERROR("tcp_listen: pcb already connected", pcb->state == CLOSED, return NULL); 802d486: 7e03 ldrb r3, [r0, #24] * called like this: * tpcb = tcp_listen(tpcb); */ struct tcp_pcb * tcp_listen_with_backlog(struct tcp_pcb *pcb, u8_t backlog) { 802d488: 4604 mov r4, r0 struct tcp_pcb_listen *lpcb; LWIP_UNUSED_ARG(backlog); LWIP_ERROR("tcp_listen: pcb already connected", pcb->state == CLOSED, return NULL); 802d48a: b10b cbz r3, 802d490 802d48c: 2000 movs r0, #0 802d48e: bd38 pop {r3, r4, r5, pc} } } } } #endif /* SO_REUSE */ lpcb = (struct tcp_pcb_listen *)memp_malloc(MEMP_TCP_PCB_LISTEN); 802d490: 2003 movs r0, #3 802d492: f7ff fcad bl 802cdf0 if (lpcb == NULL) { 802d496: 4605 mov r5, r0 802d498: 2800 cmp r0, #0 802d49a: d0f7 beq.n 802d48c return NULL; } lpcb->callback_arg = pcb->callback_arg; 802d49c: 6923 ldr r3, [r4, #16] 802d49e: 6103 str r3, [r0, #16] lpcb->local_port = pcb->local_port; 802d4a0: 8b63 ldrh r3, [r4, #26] 802d4a2: 8343 strh r3, [r0, #26] lpcb->state = LISTEN; 802d4a4: 2301 movs r3, #1 802d4a6: 7603 strb r3, [r0, #24] lpcb->prio = pcb->prio; 802d4a8: 7e63 ldrb r3, [r4, #25] 802d4aa: 7643 strb r3, [r0, #25] lpcb->so_options = pcb->so_options; ip_set_option(lpcb, SOF_ACCEPTCONN); 802d4ac: 7a23 ldrb r3, [r4, #8] 802d4ae: f043 0302 orr.w r3, r3, #2 802d4b2: 7203 strb r3, [r0, #8] lpcb->ttl = pcb->ttl; 802d4b4: 7aa3 ldrb r3, [r4, #10] 802d4b6: 7283 strb r3, [r0, #10] lpcb->tos = pcb->tos; 802d4b8: 7a63 ldrb r3, [r4, #9] 802d4ba: 7243 strb r3, [r0, #9] ip_addr_copy(lpcb->local_ip, pcb->local_ip); 802d4bc: 6823 ldr r3, [r4, #0] 802d4be: 6003 str r3, [r0, #0] if (pcb->local_port != 0) { 802d4c0: 8b63 ldrh r3, [r4, #26] 802d4c2: b1ab cbz r3, 802d4f0 TCP_RMV(&tcp_bound_pcbs, pcb); 802d4c4: 4a11 ldr r2, [pc, #68] ; (802d50c ) 802d4c6: 6813 ldr r3, [r2, #0] 802d4c8: 42a3 cmp r3, r4 802d4ca: d101 bne.n 802d4d0 802d4cc: 68e3 ldr r3, [r4, #12] 802d4ce: e00c b.n 802d4ea 802d4d0: 4a0f ldr r2, [pc, #60] ; (802d510 ) 802d4d2: 6013 str r3, [r2, #0] 802d4d4: e007 b.n 802d4e6 802d4d6: 68d9 ldr r1, [r3, #12] 802d4d8: 42a1 cmp r1, r4 802d4da: d103 bne.n 802d4e4 802d4dc: 6013 str r3, [r2, #0] 802d4de: 68e2 ldr r2, [r4, #12] 802d4e0: 60da str r2, [r3, #12] 802d4e2: e003 b.n 802d4ec 802d4e4: 460b mov r3, r1 802d4e6: 2b00 cmp r3, #0 802d4e8: d1f5 bne.n 802d4d6 802d4ea: 6013 str r3, [r2, #0] 802d4ec: 2300 movs r3, #0 802d4ee: 60e3 str r3, [r4, #12] } memp_free(MEMP_TCP_PCB, pcb); 802d4f0: 2002 movs r0, #2 802d4f2: 4621 mov r1, r4 802d4f4: f7ff fc92 bl 802ce1c #if LWIP_CALLBACK_API lpcb->accept = tcp_accept_null; 802d4f8: 4b06 ldr r3, [pc, #24] ; (802d514 ) 802d4fa: 616b str r3, [r5, #20] #endif /* LWIP_CALLBACK_API */ #if TCP_LISTEN_BACKLOG lpcb->accepts_pending = 0; lpcb->backlog = (backlog ? backlog : 1); #endif /* TCP_LISTEN_BACKLOG */ TCP_REG(&tcp_listen_pcbs.pcbs, (struct tcp_pcb *)lpcb); 802d4fc: 4b06 ldr r3, [pc, #24] ; (802d518 ) 802d4fe: 681a ldr r2, [r3, #0] 802d500: 601d str r5, [r3, #0] 802d502: 60ea str r2, [r5, #12] 802d504: f002 f88e bl 802f624 return (struct tcp_pcb *)lpcb; 802d508: 4628 mov r0, r5 } 802d50a: bd38 pop {r3, r4, r5, pc} 802d50c: 20010fec .word 0x20010fec 802d510: 20010fe8 .word 0x20010fe8 802d514: 0802d3b1 .word 0x0802d3b1 802d518: 20010fe4 .word 0x20010fe4 0802d51c : * * Returns how much extra window would be advertised if we sent an * update now. */ u32_t tcp_update_rcv_ann_wnd(struct tcp_pcb *pcb) { 802d51c: b530 push {r4, r5, lr} u32_t new_right_edge = pcb->rcv_nxt + pcb->rcv_wnd; if (TCP_SEQ_GEQ(new_right_edge, pcb->rcv_ann_right_edge + LWIP_MIN((TCP_WND / 2), pcb->mss))) { 802d51e: 6b01 ldr r1, [r0, #48] ; 0x30 * Returns how much extra window would be advertised if we sent an * update now. */ u32_t tcp_update_rcv_ann_wnd(struct tcp_pcb *pcb) { u32_t new_right_edge = pcb->rcv_nxt + pcb->rcv_wnd; 802d520: 8d84 ldrh r4, [r0, #44] ; 0x2c if (TCP_SEQ_GEQ(new_right_edge, pcb->rcv_ann_right_edge + LWIP_MIN((TCP_WND / 2), pcb->mss))) { 802d522: 8ec5 ldrh r5, [r0, #54] ; 0x36 * Returns how much extra window would be advertised if we sent an * update now. */ u32_t tcp_update_rcv_ann_wnd(struct tcp_pcb *pcb) { u32_t new_right_edge = pcb->rcv_nxt + pcb->rcv_wnd; 802d524: 6a82 ldr r2, [r0, #40] ; 0x28 * * Returns how much extra window would be advertised if we sent an * update now. */ u32_t tcp_update_rcv_ann_wnd(struct tcp_pcb *pcb) { 802d526: 4603 mov r3, r0 u32_t new_right_edge = pcb->rcv_nxt + pcb->rcv_wnd; if (TCP_SEQ_GEQ(new_right_edge, pcb->rcv_ann_right_edge + LWIP_MIN((TCP_WND / 2), pcb->mss))) { 802d528: f640 3068 movw r0, #2920 ; 0xb68 802d52c: 4285 cmp r5, r0 802d52e: bf28 it cs 802d530: 4605 movcs r5, r0 * Returns how much extra window would be advertised if we sent an * update now. */ u32_t tcp_update_rcv_ann_wnd(struct tcp_pcb *pcb) { u32_t new_right_edge = pcb->rcv_nxt + pcb->rcv_wnd; 802d532: 1a60 subs r0, r4, r1 if (TCP_SEQ_GEQ(new_right_edge, pcb->rcv_ann_right_edge + LWIP_MIN((TCP_WND / 2), pcb->mss))) { 802d534: 1880 adds r0, r0, r2 802d536: 1b45 subs r5, r0, r5 802d538: 2d00 cmp r5, #0 802d53a: db01 blt.n 802d540 /* we can advertise more window */ pcb->rcv_ann_wnd = pcb->rcv_wnd; 802d53c: 85dc strh r4, [r3, #46] ; 0x2e return new_right_edge - pcb->rcv_ann_right_edge; 802d53e: bd30 pop {r4, r5, pc} } else { if (TCP_SEQ_GT(pcb->rcv_nxt, pcb->rcv_ann_right_edge)) { 802d540: 1a50 subs r0, r2, r1 802d542: 2800 cmp r0, #0 802d544: f04f 0000 mov.w r0, #0 802d548: dd01 ble.n 802d54e /* Can happen due to other end sending out of advertised window, * but within actual available (but not yet advertised) window */ pcb->rcv_ann_wnd = 0; 802d54a: 85d8 strh r0, [r3, #46] ; 0x2e 802d54c: bd30 pop {r4, r5, pc} } else { /* keep the right edge of window constant */ u32_t new_rcv_ann_wnd = pcb->rcv_ann_right_edge - pcb->rcv_nxt; 802d54e: 1a8a subs r2, r1, r2 LWIP_ASSERT("new_rcv_ann_wnd <= 0xffff", new_rcv_ann_wnd <= 0xffff); pcb->rcv_ann_wnd = (u16_t)new_rcv_ann_wnd; 802d550: 85da strh r2, [r3, #46] ; 0x2e } return 0; } } 802d552: bd30 pop {r4, r5, pc} 0802d554 : LWIP_ASSERT("don't call tcp_recved for listen-pcbs", pcb->state != LISTEN); LWIP_ASSERT("tcp_recved: len would wrap rcv_wnd\n", len <= 0xffff - pcb->rcv_wnd ); pcb->rcv_wnd += len; 802d554: 8d83 ldrh r3, [r0, #44] ; 0x2c 802d556: 18c9 adds r1, r1, r3 802d558: b289 uxth r1, r1 if (pcb->rcv_wnd > TCP_WND) { 802d55a: f241 63d0 movw r3, #5840 ; 0x16d0 802d55e: 4299 cmp r1, r3 * @param pcb the tcp_pcb for which data is read * @param len the amount of bytes that have been read by the application */ void tcp_recved(struct tcp_pcb *pcb, u16_t len) { 802d560: b510 push {r4, lr} LWIP_ASSERT("tcp_recved: len would wrap rcv_wnd\n", len <= 0xffff - pcb->rcv_wnd ); pcb->rcv_wnd += len; if (pcb->rcv_wnd > TCP_WND) { pcb->rcv_wnd = TCP_WND; 802d562: bf8c ite hi 802d564: 8583 strhhi r3, [r0, #44] ; 0x2c LWIP_ASSERT("don't call tcp_recved for listen-pcbs", pcb->state != LISTEN); LWIP_ASSERT("tcp_recved: len would wrap rcv_wnd\n", len <= 0xffff - pcb->rcv_wnd ); pcb->rcv_wnd += len; 802d566: 8581 strhls r1, [r0, #44] ; 0x2c * @param pcb the tcp_pcb for which data is read * @param len the amount of bytes that have been read by the application */ void tcp_recved(struct tcp_pcb *pcb, u16_t len) { 802d568: 4604 mov r4, r0 pcb->rcv_wnd += len; if (pcb->rcv_wnd > TCP_WND) { pcb->rcv_wnd = TCP_WND; } wnd_inflation = tcp_update_rcv_ann_wnd(pcb); 802d56a: f7ff ffd7 bl 802d51c /* If the change in the right edge of window is significant (default * watermark is TCP_WND/4), then send an explicit update now. * Otherwise wait for a packet to be sent in the normal course of * events (or more window to be available later) */ if (wnd_inflation >= TCP_WND_UPDATE_THRESHOLD) { 802d56e: f240 53b3 movw r3, #1459 ; 0x5b3 802d572: 4298 cmp r0, r3 802d574: dd08 ble.n 802d588 tcp_ack_now(pcb); 802d576: 7fa3 ldrb r3, [r4, #30] tcp_output(pcb); 802d578: 4620 mov r0, r4 /* If the change in the right edge of window is significant (default * watermark is TCP_WND/4), then send an explicit update now. * Otherwise wait for a packet to be sent in the normal course of * events (or more window to be available later) */ if (wnd_inflation >= TCP_WND_UPDATE_THRESHOLD) { tcp_ack_now(pcb); 802d57a: f043 0302 orr.w r3, r3, #2 802d57e: 77a3 strb r3, [r4, #30] tcp_output(pcb); } LWIP_DEBUGF(TCP_DEBUG, ("tcp_recved: recveived %"U16_F" bytes, wnd %"U16_F" (%"U16_F").\n", len, pcb->rcv_wnd, TCP_WND - pcb->rcv_wnd)); } 802d580: e8bd 4010 ldmia.w sp!, {r4, lr} * watermark is TCP_WND/4), then send an explicit update now. * Otherwise wait for a packet to be sent in the normal course of * events (or more window to be available later) */ if (wnd_inflation >= TCP_WND_UPDATE_THRESHOLD) { tcp_ack_now(pcb); tcp_output(pcb); 802d584: f001 bd90 b.w 802f0a8 802d588: bd10 pop {r4, pc} 0802d58a : * * @param seg single tcp_seg to free */ void tcp_seg_free(struct tcp_seg *seg) { 802d58a: b510 push {r4, lr} if (seg != NULL) { 802d58c: 4604 mov r4, r0 802d58e: b148 cbz r0, 802d5a4 if (seg->p != NULL) { 802d590: 6840 ldr r0, [r0, #4] 802d592: b108 cbz r0, 802d598 pbuf_free(seg->p); 802d594: f7ff fd4c bl 802d030 #if TCP_DEBUG seg->p = NULL; #endif /* TCP_DEBUG */ } memp_free(MEMP_TCP_SEG, seg); 802d598: 2004 movs r0, #4 802d59a: 4621 mov r1, r4 } } 802d59c: e8bd 4010 ldmia.w sp!, {r4, lr} pbuf_free(seg->p); #if TCP_DEBUG seg->p = NULL; #endif /* TCP_DEBUG */ } memp_free(MEMP_TCP_SEG, seg); 802d5a0: f7ff bc3c b.w 802ce1c 802d5a4: bd10 pop {r4, pc} 0802d5a6 : * * @param seg tcp_seg list of TCP segments to free */ void tcp_segs_free(struct tcp_seg *seg) { 802d5a6: b510 push {r4, lr} while (seg != NULL) { 802d5a8: e003 b.n 802d5b2 struct tcp_seg *next = seg->next; 802d5aa: 6804 ldr r4, [r0, #0] tcp_seg_free(seg); 802d5ac: f7ff ffed bl 802d58a seg = next; 802d5b0: 4620 mov r0, r4 * @param seg tcp_seg list of TCP segments to free */ void tcp_segs_free(struct tcp_seg *seg) { while (seg != NULL) { 802d5b2: 2800 cmp r0, #0 802d5b4: d1f9 bne.n 802d5aa struct tcp_seg *next = seg->next; tcp_seg_free(seg); seg = next; } } 802d5b6: bd10 pop {r4, pc} 0802d5b8 : void tcp_arg(struct tcp_pcb *pcb, void *arg) { /* This function is allowed to be called for both listen pcbs and connection pcbs. */ pcb->callback_arg = arg; 802d5b8: 6101 str r1, [r0, #16] 802d5ba: 4770 bx lr 0802d5bc : */ void tcp_recv(struct tcp_pcb *pcb, tcp_recv_fn recv) { LWIP_ASSERT("invalid socket state for recv callback", pcb->state != LISTEN); pcb->recv = recv; 802d5bc: 67c1 str r1, [r0, #124] ; 0x7c 802d5be: 4770 bx lr 0802d5c0 : */ void tcp_sent(struct tcp_pcb *pcb, tcp_sent_fn sent) { LWIP_ASSERT("invalid socket state for sent callback", pcb->state != LISTEN); pcb->sent = sent; 802d5c0: 6781 str r1, [r0, #120] ; 0x78 802d5c2: 4770 bx lr 0802d5c4 : */ void tcp_err(struct tcp_pcb *pcb, tcp_err_fn err) { LWIP_ASSERT("invalid socket state for err callback", pcb->state != LISTEN); pcb->errf = err; 802d5c4: f8c0 1088 str.w r1, [r0, #136] ; 0x88 802d5c8: 4770 bx lr 0802d5ca : void tcp_accept(struct tcp_pcb *pcb, tcp_accept_fn accept) { /* This function is allowed to be called for both listen pcbs and connection pcbs. */ pcb->accept = accept; 802d5ca: 6141 str r1, [r0, #20] 802d5cc: 4770 bx lr 0802d5ce : void tcp_poll(struct tcp_pcb *pcb, tcp_poll_fn poll, u8_t interval) { LWIP_ASSERT("invalid socket state for poll", pcb->state != LISTEN); #if LWIP_CALLBACK_API pcb->poll = poll; 802d5ce: f8c0 1084 str.w r1, [r0, #132] ; 0x84 #else /* LWIP_CALLBACK_API */ LWIP_UNUSED_ARG(poll); #endif /* LWIP_CALLBACK_API */ pcb->pollinterval = interval; 802d5d2: f880 2020 strb.w r2, [r0, #32] 802d5d6: 4770 bx lr 0802d5d8 : * @param pcb tcp_pcb to purge. The pcb itself is not deallocated! */ void tcp_pcb_purge(struct tcp_pcb *pcb) { if (pcb->state != CLOSED && 802d5d8: 7e03 ldrb r3, [r0, #24] * * @param pcb tcp_pcb to purge. The pcb itself is not deallocated! */ void tcp_pcb_purge(struct tcp_pcb *pcb) { 802d5da: b510 push {r4, lr} 802d5dc: 4604 mov r4, r0 if (pcb->state != CLOSED && 802d5de: b1bb cbz r3, 802d610 802d5e0: 2b0a cmp r3, #10 802d5e2: d015 beq.n 802d610 pcb->state != TIME_WAIT && 802d5e4: 2b01 cmp r3, #1 802d5e6: d013 beq.n 802d610 } } #endif /* TCP_LISTEN_BACKLOG */ if (pcb->refused_data != NULL) { 802d5e8: 6f40 ldr r0, [r0, #116] ; 0x74 802d5ea: b118 cbz r0, 802d5f4 LWIP_DEBUGF(TCP_DEBUG, ("tcp_pcb_purge: data left on ->refused_data\n")); pbuf_free(pcb->refused_data); 802d5ec: f7ff fd20 bl 802d030 pcb->refused_data = NULL; 802d5f0: 2300 movs r3, #0 802d5f2: 6763 str r3, [r4, #116] ; 0x74 pcb->ooseq = NULL; #endif /* TCP_QUEUE_OOSEQ */ /* Stop the retransmission timer as it will expect data on unacked queue if it fires */ pcb->rtime = -1; 802d5f4: f64f 73ff movw r3, #65535 ; 0xffff 802d5f8: 86a3 strh r3, [r4, #52] ; 0x34 tcp_segs_free(pcb->unsent); 802d5fa: 6ee0 ldr r0, [r4, #108] ; 0x6c 802d5fc: f7ff ffd3 bl 802d5a6 tcp_segs_free(pcb->unacked); 802d600: 6f20 ldr r0, [r4, #112] ; 0x70 802d602: f7ff ffd0 bl 802d5a6 pcb->unacked = pcb->unsent = NULL; 802d606: 2300 movs r3, #0 802d608: 66e3 str r3, [r4, #108] ; 0x6c 802d60a: 6723 str r3, [r4, #112] ; 0x70 #if TCP_OVERSIZE pcb->unsent_oversize = 0; 802d60c: f8a4 306a strh.w r3, [r4, #106] ; 0x6a 802d610: bd10 pop {r4, pc} 802d612: 0000 movs r0, r0 0802d614 : u8_t pcb_reset; /* flag if a RST should be sent when removing */ err_t err; err = ERR_OK; ++tcp_ticks; 802d614: 4b9c ldr r3, [pc, #624] ; (802d888 ) * * Automatically called from tcp_tmr(). */ void tcp_slowtmr(void) { 802d616: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} u8_t pcb_reset; /* flag if a RST should be sent when removing */ err_t err; err = ERR_OK; ++tcp_ticks; 802d61a: 681a ldr r2, [r3, #0] err_arg = pcb->callback_arg; pcb2 = pcb; pcb = pcb->next; memp_free(MEMP_TCP_PCB, pcb2); tcp_active_pcbs_changed = 0; 802d61c: f8df 8284 ldr.w r8, [pc, #644] ; 802d8a4 u8_t pcb_reset; /* flag if a RST should be sent when removing */ err_t err; err = ERR_OK; ++tcp_ticks; 802d620: 3201 adds r2, #1 802d622: 601a str r2, [r3, #0] ++tcp_timer_ctr; 802d624: 4b99 ldr r3, [pc, #612] ; (802d88c ) 802d626: 781a ldrb r2, [r3, #0] 802d628: 3201 adds r2, #1 802d62a: 701a strb r2, [r3, #0] 802d62c: 46c1 mov r9, r8 tcp_slowtmr_start: /* Steps through all of the active PCBs. */ prev = NULL; pcb = tcp_active_pcbs; 802d62e: 4b98 ldr r3, [pc, #608] ; (802d890 ) while (pcb != NULL) { LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: processing active pcb\n")); LWIP_ASSERT("tcp_slowtmr: active pcb->state != CLOSED\n", pcb->state != CLOSED); LWIP_ASSERT("tcp_slowtmr: active pcb->state != LISTEN\n", pcb->state != LISTEN); LWIP_ASSERT("tcp_slowtmr: active pcb->state != TIME-WAIT\n", pcb->state != TIME_WAIT); if (pcb->last_timer == tcp_timer_ctr) { 802d630: f8df a258 ldr.w sl, [pc, #600] ; 802d88c ++tcp_timer_ctr; tcp_slowtmr_start: /* Steps through all of the active PCBs. */ prev = NULL; pcb = tcp_active_pcbs; 802d634: 681c ldr r4, [r3, #0] ++tcp_ticks; ++tcp_timer_ctr; tcp_slowtmr_start: /* Steps through all of the active PCBs. */ prev = NULL; 802d636: 2600 movs r6, #0 pcb = tcp_active_pcbs; if (pcb == NULL) { LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: no active pcbs\n")); } while (pcb != NULL) { 802d638: e0ff b.n 802d83a LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: processing active pcb\n")); LWIP_ASSERT("tcp_slowtmr: active pcb->state != CLOSED\n", pcb->state != CLOSED); LWIP_ASSERT("tcp_slowtmr: active pcb->state != LISTEN\n", pcb->state != LISTEN); LWIP_ASSERT("tcp_slowtmr: active pcb->state != TIME-WAIT\n", pcb->state != TIME_WAIT); if (pcb->last_timer == tcp_timer_ctr) { 802d63a: f89a 3000 ldrb.w r3, [sl] 802d63e: f894 2021 ldrb.w r2, [r4, #33] ; 0x21 802d642: 429a cmp r2, r3 802d644: d101 bne.n 802d64a /* skip this pcb, we have already processed it */ pcb = pcb->next; 802d646: 68e7 ldr r7, [r4, #12] continue; 802d648: e0f6 b.n 802d838 pcb->last_timer = tcp_timer_ctr; pcb_remove = 0; pcb_reset = 0; if (pcb->state == SYN_SENT && pcb->nrtx == TCP_SYNMAXRTX) { 802d64a: 7e21 ldrb r1, [r4, #24] if (pcb->last_timer == tcp_timer_ctr) { /* skip this pcb, we have already processed it */ pcb = pcb->next; continue; } pcb->last_timer = tcp_timer_ctr; 802d64c: f884 3021 strb.w r3, [r4, #33] ; 0x21 pcb_remove = 0; pcb_reset = 0; if (pcb->state == SYN_SENT && pcb->nrtx == TCP_SYNMAXRTX) { 802d650: 2902 cmp r1, #2 802d652: f894 2046 ldrb.w r2, [r4, #70] ; 0x46 802d656: d101 bne.n 802d65c 802d658: 2a06 cmp r2, #6 802d65a: d051 beq.n 802d700 ++pcb_remove; LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max SYN retries reached\n")); } else if (pcb->nrtx == TCP_MAXRTX) { 802d65c: 2a0c cmp r2, #12 802d65e: d04f beq.n 802d700 ++pcb_remove; LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max DATA retries reached\n")); } else { if (pcb->persist_backoff > 0) { 802d660: f894 3091 ldrb.w r3, [r4, #145] ; 0x91 802d664: b1c3 cbz r3, 802d698 /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { 802d666: 498b ldr r1, [pc, #556] ; (802d894 ) LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max DATA retries reached\n")); } else { if (pcb->persist_backoff > 0) { /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; 802d668: f894 2090 ldrb.w r2, [r4, #144] ; 0x90 if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { 802d66c: 18c9 adds r1, r1, r3 LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max DATA retries reached\n")); } else { if (pcb->persist_backoff > 0) { /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; 802d66e: 3201 adds r2, #1 if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { 802d670: f811 1c01 ldrb.w r1, [r1, #-1] LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max DATA retries reached\n")); } else { if (pcb->persist_backoff > 0) { /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; 802d674: b2d2 uxtb r2, r2 if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { 802d676: 4291 cmp r1, r2 LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: max DATA retries reached\n")); } else { if (pcb->persist_backoff > 0) { /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; 802d678: f884 2090 strb.w r2, [r4, #144] ; 0x90 if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { 802d67c: d900 bls.n 802d680 802d67e: e03d b.n 802d6fc pcb->persist_cnt = 0; 802d680: 2200 movs r2, #0 if (pcb->persist_backoff < sizeof(tcp_persist_backoff)) { 802d682: 2b06 cmp r3, #6 if (pcb->persist_backoff > 0) { /* If snd_wnd is zero, use persist timer to send 1 byte probes * instead of using the standard retransmission mechanism. */ pcb->persist_cnt++; if (pcb->persist_cnt >= tcp_persist_backoff[pcb->persist_backoff-1]) { pcb->persist_cnt = 0; 802d684: f884 2090 strb.w r2, [r4, #144] ; 0x90 if (pcb->persist_backoff < sizeof(tcp_persist_backoff)) { 802d688: d802 bhi.n 802d690 pcb->persist_backoff++; 802d68a: 3301 adds r3, #1 802d68c: f884 3091 strb.w r3, [r4, #145] ; 0x91 } tcp_zero_window_probe(pcb); 802d690: 4620 mov r0, r4 802d692: f001 ff04 bl 802f49e 802d696: e031 b.n 802d6fc } } else { /* Increase the retransmission timer if it is running */ if(pcb->rtime >= 0) { 802d698: 8ea3 ldrh r3, [r4, #52] ; 0x34 802d69a: 0418 lsls r0, r3, #16 802d69c: d401 bmi.n 802d6a2 ++pcb->rtime; 802d69e: 3301 adds r3, #1 802d6a0: 86a3 strh r3, [r4, #52] ; 0x34 } if (pcb->unacked != NULL && pcb->rtime >= pcb->rto) { 802d6a2: 6f23 ldr r3, [r4, #112] ; 0x70 802d6a4: b353 cbz r3, 802d6fc 802d6a6: f9b4 0034 ldrsh.w r0, [r4, #52] ; 0x34 802d6aa: f9b4 3044 ldrsh.w r3, [r4, #68] ; 0x44 802d6ae: 4298 cmp r0, r3 802d6b0: db24 blt.n 802d6fc " pcb->rto %"S16_F"\n", pcb->rtime, pcb->rto)); /* Double retransmission time-out unless we are trying to * connect to somebody (i.e., we are in SYN_SENT). */ if (pcb->state != SYN_SENT) { 802d6b2: 2902 cmp r1, #2 802d6b4: d00b beq.n 802d6ce pcb->rto = ((pcb->sa >> 3) + pcb->sv) << tcp_backoff[pcb->nrtx]; 802d6b6: f9b4 1040 ldrsh.w r1, [r4, #64] ; 0x40 802d6ba: f9b4 3042 ldrsh.w r3, [r4, #66] ; 0x42 802d6be: eb03 03e1 add.w r3, r3, r1, asr #3 802d6c2: 4975 ldr r1, [pc, #468] ; (802d898 ) 802d6c4: 5c8a ldrb r2, [r1, r2] 802d6c6: fa03 f302 lsl.w r3, r3, r2 802d6ca: f8a4 3044 strh.w r3, [r4, #68] ; 0x44 } /* Reset the retransmission timer. */ pcb->rtime = 0; 802d6ce: 2300 movs r3, #0 /* Reduce congestion window and ssthresh. */ eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd); 802d6d0: f8b4 104c ldrh.w r1, [r4, #76] ; 0x4c if (pcb->state != SYN_SENT) { pcb->rto = ((pcb->sa >> 3) + pcb->sv) << tcp_backoff[pcb->nrtx]; } /* Reset the retransmission timer. */ pcb->rtime = 0; 802d6d4: 86a3 strh r3, [r4, #52] ; 0x34 /* Reduce congestion window and ssthresh. */ eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd); 802d6d6: f8b4 3060 ldrh.w r3, [r4, #96] ; 0x60 pcb->ssthresh = eff_wnd >> 1; 802d6da: 4299 cmp r1, r3 802d6dc: bf28 it cs 802d6de: 4619 movcs r1, r3 if (pcb->ssthresh < (pcb->mss << 1)) { 802d6e0: 8ee3 ldrh r3, [r4, #54] ; 0x36 /* Reset the retransmission timer. */ pcb->rtime = 0; /* Reduce congestion window and ssthresh. */ eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd); pcb->ssthresh = eff_wnd >> 1; 802d6e2: 0849 lsrs r1, r1, #1 if (pcb->ssthresh < (pcb->mss << 1)) { 802d6e4: 005a lsls r2, r3, #1 802d6e6: 4291 cmp r1, r2 /* Reset the retransmission timer. */ pcb->rtime = 0; /* Reduce congestion window and ssthresh. */ eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd); pcb->ssthresh = eff_wnd >> 1; 802d6e8: f8a4 104e strh.w r1, [r4, #78] ; 0x4e if (pcb->ssthresh < (pcb->mss << 1)) { pcb->ssthresh = (pcb->mss << 1); } pcb->cwnd = pcb->mss; 802d6ec: f8a4 304c strh.w r3, [r4, #76] ; 0x4c /* Reduce congestion window and ssthresh. */ eff_wnd = LWIP_MIN(pcb->cwnd, pcb->snd_wnd); pcb->ssthresh = eff_wnd >> 1; if (pcb->ssthresh < (pcb->mss << 1)) { pcb->ssthresh = (pcb->mss << 1); 802d6f0: bfb8 it lt 802d6f2: f8a4 204e strhlt.w r2, [r4, #78] ; 0x4e " ssthresh %"U16_F"\n", pcb->cwnd, pcb->ssthresh)); /* The following needs to be called AFTER cwnd is set to one mss - STJ */ tcp_rexmit_rto(pcb); 802d6f6: 4620 mov r0, r4 802d6f8: f001 fe40 bl 802f37c pcb = pcb->next; continue; } pcb->last_timer = tcp_timer_ctr; pcb_remove = 0; 802d6fc: 2500 movs r5, #0 802d6fe: e000 b.n 802d702 pcb_reset = 0; if (pcb->state == SYN_SENT && pcb->nrtx == TCP_SYNMAXRTX) { ++pcb_remove; 802d700: 2501 movs r5, #1 tcp_rexmit_rto(pcb); } } } /* Check if this PCB has stayed too long in FIN-WAIT-2 */ if (pcb->state == FIN_WAIT_2) { 802d702: 7e23 ldrb r3, [r4, #24] 802d704: 2b06 cmp r3, #6 802d706: d10c bne.n 802d722 /* If this PCB is in FIN_WAIT_2 because of SHUT_WR don't let it time out. */ if (pcb->flags & TF_RXCLOSED) { 802d708: 7fa2 ldrb r2, [r4, #30] 802d70a: f002 0210 and.w r2, r2, #16 802d70e: b2d2 uxtb r2, r2 802d710: b13a cbz r2, 802d722 /* PCB was fully closed (either through close() or SHUT_RDWR): normal FIN-WAIT timeout handling. */ if ((u32_t)(tcp_ticks - pcb->tmr) > 802d712: 4a5d ldr r2, [pc, #372] ; (802d888 ) 802d714: 6811 ldr r1, [r2, #0] 802d716: 6a62 ldr r2, [r4, #36] ; 0x24 802d718: 1a8a subs r2, r1, r2 802d71a: 2a28 cmp r2, #40 ; 0x28 802d71c: d901 bls.n 802d722 TCP_FIN_WAIT_TIMEOUT / TCP_SLOW_INTERVAL) { ++pcb_remove; 802d71e: 3501 adds r5, #1 802d720: b2ed uxtb r5, r5 } } } /* Check if KEEPALIVE should be sent */ if(ip_get_option(pcb, SOF_KEEPALIVE) && 802d722: 7a27 ldrb r7, [r4, #8] 802d724: f007 0708 and.w r7, r7, #8 802d728: b2ff uxtb r7, r7 802d72a: b34f cbz r7, 802d780 802d72c: 2b04 cmp r3, #4 802d72e: d001 beq.n 802d734 ((pcb->state == ESTABLISHED) || 802d730: 2b07 cmp r3, #7 802d732: d124 bne.n 802d77e (pcb->state == CLOSE_WAIT))) { if((u32_t)(tcp_ticks - pcb->tmr) > 802d734: 4b54 ldr r3, [pc, #336] ; (802d888 ) (pcb->keep_idle + TCP_KEEP_DUR(pcb)) / TCP_SLOW_INTERVAL) 802d736: f8d4 008c ldr.w r0, [r4, #140] ; 0x8c /* Check if KEEPALIVE should be sent */ if(ip_get_option(pcb, SOF_KEEPALIVE) && ((pcb->state == ESTABLISHED) || (pcb->state == CLOSE_WAIT))) { if((u32_t)(tcp_ticks - pcb->tmr) > 802d73a: 681a ldr r2, [r3, #0] 802d73c: 6a63 ldr r3, [r4, #36] ; 0x24 802d73e: 1ad2 subs r2, r2, r3 (pcb->keep_idle + TCP_KEEP_DUR(pcb)) / TCP_SLOW_INTERVAL) 802d740: f500 2324 add.w r3, r0, #671744 ; 0xa4000 802d744: f603 43b8 addw r3, r3, #3256 ; 0xcb8 802d748: f44f 71fa mov.w r1, #500 ; 0x1f4 802d74c: fbb3 f3f1 udiv r3, r3, r1 /* Check if KEEPALIVE should be sent */ if(ip_get_option(pcb, SOF_KEEPALIVE) && ((pcb->state == ESTABLISHED) || (pcb->state == CLOSE_WAIT))) { if((u32_t)(tcp_ticks - pcb->tmr) > 802d750: 429a cmp r2, r3 802d752: d903 bls.n 802d75c { LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: KEEPALIVE timeout. Aborting connection to %"U16_F".%"U16_F".%"U16_F".%"U16_F".\n", ip4_addr1_16(&pcb->remote_ip), ip4_addr2_16(&pcb->remote_ip), ip4_addr3_16(&pcb->remote_ip), ip4_addr4_16(&pcb->remote_ip))); ++pcb_remove; 802d754: 3501 adds r5, #1 802d756: b2ed uxtb r5, r5 ++pcb_reset; 802d758: 2701 movs r7, #1 802d75a: e011 b.n 802d780 } else if((u32_t)(tcp_ticks - pcb->tmr) > (pcb->keep_idle + pcb->keep_cnt_sent * TCP_KEEP_INTVL(pcb)) 802d75c: f894 3092 ldrb.w r3, [r4, #146] ; 0x92 802d760: 4f4e ldr r7, [pc, #312] ; (802d89c ) 802d762: fb07 0003 mla r0, r7, r3, r0 / TCP_SLOW_INTERVAL) 802d766: fbb0 f1f1 udiv r1, r0, r1 ip4_addr3_16(&pcb->remote_ip), ip4_addr4_16(&pcb->remote_ip))); ++pcb_remove; ++pcb_reset; } else if((u32_t)(tcp_ticks - pcb->tmr) > 802d76a: 428a cmp r2, r1 802d76c: d907 bls.n 802d77e (pcb->keep_idle + pcb->keep_cnt_sent * TCP_KEEP_INTVL(pcb)) / TCP_SLOW_INTERVAL) { tcp_keepalive(pcb); 802d76e: 4620 mov r0, r4 802d770: f001 fe76 bl 802f460 pcb->keep_cnt_sent++; 802d774: f894 3092 ldrb.w r3, [r4, #146] ; 0x92 802d778: 3301 adds r3, #1 802d77a: f884 3092 strb.w r3, [r4, #146] ; 0x92 continue; } pcb->last_timer = tcp_timer_ctr; pcb_remove = 0; pcb_reset = 0; 802d77e: 2700 movs r7, #0 LWIP_DEBUGF(TCP_CWND_DEBUG, ("tcp_slowtmr: dropping OOSEQ queued data\n")); } #endif /* TCP_QUEUE_OOSEQ */ /* Check if this PCB has stayed too long in SYN-RCVD */ if (pcb->state == SYN_RCVD) { 802d780: 7e23 ldrb r3, [r4, #24] 802d782: 2b03 cmp r3, #3 802d784: d108 bne.n 802d798 if ((u32_t)(tcp_ticks - pcb->tmr) > 802d786: 4b40 ldr r3, [pc, #256] ; (802d888 ) 802d788: 681a ldr r2, [r3, #0] 802d78a: 6a63 ldr r3, [r4, #36] ; 0x24 802d78c: 1ad3 subs r3, r2, r3 802d78e: 2b28 cmp r3, #40 ; 0x28 802d790: d90a bls.n 802d7a8 TCP_SYN_RCVD_TIMEOUT / TCP_SLOW_INTERVAL) { ++pcb_remove; 802d792: 3501 adds r5, #1 802d794: b2ed uxtb r5, r5 802d796: e007 b.n 802d7a8 LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: removing pcb stuck in SYN-RCVD\n")); } } /* Check if this PCB has stayed too long in LAST-ACK */ if (pcb->state == LAST_ACK) { 802d798: 2b09 cmp r3, #9 802d79a: d105 bne.n 802d7a8 if ((u32_t)(tcp_ticks - pcb->tmr) > 2 * TCP_MSL / TCP_SLOW_INTERVAL) { 802d79c: 4b3a ldr r3, [pc, #232] ; (802d888 ) 802d79e: 681a ldr r2, [r3, #0] 802d7a0: 6a63 ldr r3, [r4, #36] ; 0x24 802d7a2: 1ad3 subs r3, r2, r3 802d7a4: 2bf0 cmp r3, #240 ; 0xf0 802d7a6: d800 bhi.n 802d7aa LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: removing pcb stuck in LAST-ACK\n")); } } /* If the PCB should be removed, do it. */ if (pcb_remove) { 802d7a8: b345 cbz r5, 802d7fc struct tcp_pcb *pcb2; tcp_err_fn err_fn; void *err_arg; tcp_pcb_purge(pcb); 802d7aa: 4620 mov r0, r4 802d7ac: f7ff ff14 bl 802d5d8 802d7b0: 68e3 ldr r3, [r4, #12] /* Remove PCB from tcp_active_pcbs list. */ if (prev != NULL) { 802d7b2: b10e cbz r6, 802d7b8 LWIP_ASSERT("tcp_slowtmr: middle tcp != tcp_active_pcbs", pcb != tcp_active_pcbs); prev->next = pcb->next; 802d7b4: 60f3 str r3, [r6, #12] 802d7b6: e001 b.n 802d7bc } else { /* This PCB was the first. */ LWIP_ASSERT("tcp_slowtmr: first pcb == tcp_active_pcbs", tcp_active_pcbs == pcb); tcp_active_pcbs = pcb->next; 802d7b8: 4a35 ldr r2, [pc, #212] ; (802d890 ) 802d7ba: 6013 str r3, [r2, #0] } if (pcb_reset) { 802d7bc: b14f cbz r7, 802d7d2 tcp_rst(pcb->snd_nxt, pcb->rcv_nxt, &pcb->local_ip, &pcb->remote_ip, 802d7be: 8b63 ldrh r3, [r4, #26] 802d7c0: 9300 str r3, [sp, #0] 802d7c2: 8ba3 ldrh r3, [r4, #28] 802d7c4: 9301 str r3, [sp, #4] 802d7c6: 6d20 ldr r0, [r4, #80] ; 0x50 802d7c8: 6aa1 ldr r1, [r4, #40] ; 0x28 802d7ca: 4622 mov r2, r4 802d7cc: 1d23 adds r3, r4, #4 802d7ce: f001 fd8f bl 802f2f0 pcb->local_port, pcb->remote_port); } err_fn = pcb->errf; 802d7d2: f8d4 5088 ldr.w r5, [r4, #136] ; 0x88 err_arg = pcb->callback_arg; 802d7d6: f8d4 b010 ldr.w fp, [r4, #16] pcb2 = pcb; pcb = pcb->next; 802d7da: 68e7 ldr r7, [r4, #12] memp_free(MEMP_TCP_PCB, pcb2); 802d7dc: 2002 movs r0, #2 802d7de: 4621 mov r1, r4 802d7e0: f7ff fb1c bl 802ce1c tcp_active_pcbs_changed = 0; 802d7e4: 2300 movs r3, #0 802d7e6: f888 3000 strb.w r3, [r8] TCP_EVENT_ERR(err_fn, err_arg, ERR_ABRT); 802d7ea: b11d cbz r5, 802d7f4 802d7ec: 4658 mov r0, fp 802d7ee: f06f 0109 mvn.w r1, #9 802d7f2: 47a8 blx r5 if (tcp_active_pcbs_changed) { 802d7f4: f899 3000 ldrb.w r3, [r9] 802d7f8: b1f3 cbz r3, 802d838 802d7fa: e718 b.n 802d62e /* get the 'next' element now and work with 'prev' below (in case of abort) */ prev = pcb; pcb = pcb->next; /* We check if we should poll the connection. */ ++prev->polltmr; 802d7fc: 7fe3 ldrb r3, [r4, #31] if (prev->polltmr >= prev->pollinterval) { 802d7fe: f894 2020 ldrb.w r2, [r4, #32] goto tcp_slowtmr_start; } } else { /* get the 'next' element now and work with 'prev' below (in case of abort) */ prev = pcb; pcb = pcb->next; 802d802: 68e7 ldr r7, [r4, #12] /* We check if we should poll the connection. */ ++prev->polltmr; 802d804: 3301 adds r3, #1 802d806: b2db uxtb r3, r3 if (prev->polltmr >= prev->pollinterval) { 802d808: 429a cmp r2, r3 /* get the 'next' element now and work with 'prev' below (in case of abort) */ prev = pcb; pcb = pcb->next; /* We check if we should poll the connection. */ ++prev->polltmr; 802d80a: 77e3 strb r3, [r4, #31] if (prev->polltmr >= prev->pollinterval) { 802d80c: d813 bhi.n 802d836 prev->polltmr = 0; LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: polling application\n")); tcp_active_pcbs_changed = 0; TCP_EVENT_POLL(prev, err); 802d80e: f8d4 3084 ldr.w r3, [r4, #132] ; 0x84 pcb = pcb->next; /* We check if we should poll the connection. */ ++prev->polltmr; if (prev->polltmr >= prev->pollinterval) { prev->polltmr = 0; 802d812: 77e5 strb r5, [r4, #31] LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: polling application\n")); tcp_active_pcbs_changed = 0; 802d814: f888 5000 strb.w r5, [r8] TCP_EVENT_POLL(prev, err); 802d818: b11b cbz r3, 802d822 802d81a: 6920 ldr r0, [r4, #16] 802d81c: 4621 mov r1, r4 802d81e: 4798 blx r3 802d820: e000 b.n 802d824 802d822: 4628 mov r0, r5 if (tcp_active_pcbs_changed) { 802d824: f899 3000 ldrb.w r3, [r9] 802d828: 2b00 cmp r3, #0 802d82a: f47f af00 bne.w 802d62e goto tcp_slowtmr_start; } /* if err == ERR_ABRT, 'prev' is already deallocated */ if (err == ERR_OK) { 802d82e: b910 cbnz r0, 802d836 tcp_output(prev); 802d830: 4620 mov r0, r4 802d832: f001 fc39 bl 802f0a8 TCP_EVENT_POLL(prev, err); if (tcp_active_pcbs_changed) { goto tcp_slowtmr_start; } /* if err == ERR_ABRT, 'prev' is already deallocated */ if (err == ERR_OK) { 802d836: 4626 mov r6, r4 prev = pcb; pcb = pcb->next; /* We check if we should poll the connection. */ ++prev->polltmr; if (prev->polltmr >= prev->pollinterval) { 802d838: 463c mov r4, r7 prev = NULL; pcb = tcp_active_pcbs; if (pcb == NULL) { LWIP_DEBUGF(TCP_DEBUG, ("tcp_slowtmr: no active pcbs\n")); } while (pcb != NULL) { 802d83a: 2c00 cmp r4, #0 802d83c: f47f aefd bne.w 802d63a } /* Steps through all of the TIME-WAIT PCBs. */ prev = NULL; pcb = tcp_tw_pcbs; 802d840: 4b17 ldr r3, [pc, #92] ; (802d8a0 ) while (pcb != NULL) { LWIP_ASSERT("tcp_slowtmr: TIME-WAIT pcb->state == TIME-WAIT", pcb->state == TIME_WAIT); pcb_remove = 0; /* Check if this PCB has stayed long enough in TIME-WAIT */ if ((u32_t)(tcp_ticks - pcb->tmr) > 2 * TCP_MSL / TCP_SLOW_INTERVAL) { 802d842: 4e11 ldr r6, [pc, #68] ; (802d888 ) } /* Steps through all of the TIME-WAIT PCBs. */ prev = NULL; pcb = tcp_tw_pcbs; 802d844: 681d ldr r5, [r3, #0] LWIP_ASSERT("tcp_slowtmr: middle tcp != tcp_tw_pcbs", pcb != tcp_tw_pcbs); prev->next = pcb->next; } else { /* This PCB was the first. */ LWIP_ASSERT("tcp_slowtmr: first pcb == tcp_tw_pcbs", tcp_tw_pcbs == pcb); tcp_tw_pcbs = pcb->next; 802d846: 461f mov r7, r3 /* Steps through all of the TIME-WAIT PCBs. */ prev = NULL; pcb = tcp_tw_pcbs; while (pcb != NULL) { 802d848: e00f b.n 802d86a LWIP_ASSERT("tcp_slowtmr: TIME-WAIT pcb->state == TIME-WAIT", pcb->state == TIME_WAIT); pcb_remove = 0; /* Check if this PCB has stayed long enough in TIME-WAIT */ if ((u32_t)(tcp_ticks - pcb->tmr) > 2 * TCP_MSL / TCP_SLOW_INTERVAL) { 802d84a: 6832 ldr r2, [r6, #0] 802d84c: 6a6b ldr r3, [r5, #36] ; 0x24 802d84e: 1ad3 subs r3, r2, r3 802d850: 2bf0 cmp r3, #240 ; 0xf0 802d852: d810 bhi.n 802d876 802d854: e00c b.n 802d870 struct tcp_pcb *pcb2; tcp_pcb_purge(pcb); /* Remove PCB from tcp_tw_pcbs list. */ if (prev != NULL) { LWIP_ASSERT("tcp_slowtmr: middle tcp != tcp_tw_pcbs", pcb != tcp_tw_pcbs); prev->next = pcb->next; 802d856: 60e2 str r2, [r4, #12] 802d858: e000 b.n 802d85c } else { /* This PCB was the first. */ LWIP_ASSERT("tcp_slowtmr: first pcb == tcp_tw_pcbs", tcp_tw_pcbs == pcb); tcp_tw_pcbs = pcb->next; 802d85a: 603a str r2, [r7, #0] } pcb2 = pcb; pcb = pcb->next; memp_free(MEMP_TCP_PCB, pcb2); 802d85c: 4629 mov r1, r5 802d85e: 2002 movs r0, #2 /* This PCB was the first. */ LWIP_ASSERT("tcp_slowtmr: first pcb == tcp_tw_pcbs", tcp_tw_pcbs == pcb); tcp_tw_pcbs = pcb->next; } pcb2 = pcb; pcb = pcb->next; 802d860: f8d5 800c ldr.w r8, [r5, #12] memp_free(MEMP_TCP_PCB, pcb2); 802d864: f7ff fada bl 802ce1c /* This PCB was the first. */ LWIP_ASSERT("tcp_slowtmr: first pcb == tcp_tw_pcbs", tcp_tw_pcbs == pcb); tcp_tw_pcbs = pcb->next; } pcb2 = pcb; pcb = pcb->next; 802d868: 4645 mov r5, r8 /* Steps through all of the TIME-WAIT PCBs. */ prev = NULL; pcb = tcp_tw_pcbs; while (pcb != NULL) { 802d86a: 2d00 cmp r5, #0 802d86c: d1ed bne.n 802d84a 802d86e: e009 b.n 802d884 pcb2 = pcb; pcb = pcb->next; memp_free(MEMP_TCP_PCB, pcb2); } else { prev = pcb; pcb = pcb->next; 802d870: 462c mov r4, r5 802d872: 68ed ldr r5, [r5, #12] 802d874: e7f9 b.n 802d86a /* If the PCB should be removed, do it. */ if (pcb_remove) { struct tcp_pcb *pcb2; tcp_pcb_purge(pcb); 802d876: 4628 mov r0, r5 802d878: f7ff feae bl 802d5d8 802d87c: 68ea ldr r2, [r5, #12] /* Remove PCB from tcp_tw_pcbs list. */ if (prev != NULL) { 802d87e: 2c00 cmp r4, #0 802d880: d1e9 bne.n 802d856 802d882: e7ea b.n 802d85a } else { prev = pcb; pcb = pcb->next; } } } 802d884: e8bd 8ffe ldmia.w sp!, {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 802d888: 20010fe0 .word 0x20010fe0 802d88c: 2000e0ed .word 0x2000e0ed 802d890: 20010fdc .word 0x20010fdc 802d894: 0803fe7d .word 0x0803fe7d 802d898: 0803fe70 .word 0x0803fe70 802d89c: 000124f8 .word 0x000124f8 802d8a0: 20010ff0 .word 0x20010ff0 802d8a4: 20010fd8 .word 0x20010fd8 0802d8a8 : * @param pcb tcp_pcb to purge. The pcb itself is NOT deallocated! */ void tcp_pcb_remove(struct tcp_pcb **pcblist, struct tcp_pcb *pcb) { TCP_RMV(pcblist, pcb); 802d8a8: 6803 ldr r3, [r0, #0] 802d8aa: 428b cmp r3, r1 * @param pcblist PCB list to purge. * @param pcb tcp_pcb to purge. The pcb itself is NOT deallocated! */ void tcp_pcb_remove(struct tcp_pcb **pcblist, struct tcp_pcb *pcb) { 802d8ac: b510 push {r4, lr} 802d8ae: 460c mov r4, r1 TCP_RMV(pcblist, pcb); 802d8b0: d102 bne.n 802d8b8 802d8b2: 68cb ldr r3, [r1, #12] 802d8b4: 6003 str r3, [r0, #0] 802d8b6: e00d b.n 802d8d4 802d8b8: 4a11 ldr r2, [pc, #68] ; (802d900 ) 802d8ba: 6013 str r3, [r2, #0] 802d8bc: e007 b.n 802d8ce 802d8be: 68d9 ldr r1, [r3, #12] 802d8c0: 42a1 cmp r1, r4 802d8c2: d103 bne.n 802d8cc 802d8c4: 6013 str r3, [r2, #0] 802d8c6: 68e2 ldr r2, [r4, #12] 802d8c8: 60da str r2, [r3, #12] 802d8ca: e003 b.n 802d8d4 802d8cc: 460b mov r3, r1 802d8ce: 2b00 cmp r3, #0 802d8d0: d1f5 bne.n 802d8be 802d8d2: 6013 str r3, [r2, #0] 802d8d4: 2300 movs r3, #0 802d8d6: 60e3 str r3, [r4, #12] tcp_pcb_purge(pcb); 802d8d8: 4620 mov r0, r4 802d8da: f7ff fe7d bl 802d5d8 /* if there is an outstanding delayed ACKs, send it */ if (pcb->state != TIME_WAIT && 802d8de: 7e23 ldrb r3, [r4, #24] 802d8e0: 2b0a cmp r3, #10 802d8e2: d00a beq.n 802d8fa 802d8e4: 2b01 cmp r3, #1 802d8e6: d008 beq.n 802d8fa pcb->state != LISTEN && pcb->flags & TF_ACK_DELAY) { 802d8e8: 7fa3 ldrb r3, [r4, #30] tcp_pcb_purge(pcb); /* if there is an outstanding delayed ACKs, send it */ if (pcb->state != TIME_WAIT && pcb->state != LISTEN && 802d8ea: 07da lsls r2, r3, #31 802d8ec: d505 bpl.n 802d8fa pcb->flags & TF_ACK_DELAY) { pcb->flags |= TF_ACK_NOW; 802d8ee: f043 0302 orr.w r3, r3, #2 802d8f2: 77a3 strb r3, [r4, #30] tcp_output(pcb); 802d8f4: 4620 mov r0, r4 802d8f6: f001 fbd7 bl 802f0a8 #if TCP_QUEUE_OOSEQ LWIP_ASSERT("ooseq segments leaking", pcb->ooseq == NULL); #endif /* TCP_QUEUE_OOSEQ */ } pcb->state = CLOSED; 802d8fa: 2300 movs r3, #0 802d8fc: 7623 strb r3, [r4, #24] 802d8fe: bd10 pop {r4, pc} 802d900: 20010fe8 .word 0x20010fe8 0802d904 : LWIP_ASSERT("don't call tcp_abort/tcp_abandon for listen-pcbs", pcb->state != LISTEN); /* Figure out on which TCP PCB list we are, and remove us. If we are in an active state, call the receive function associated with the PCB with a NULL argument, and send an RST to the remote end. */ if (pcb->state == TIME_WAIT) { 802d904: 7e03 ldrb r3, [r0, #24] 802d906: 2b0a cmp r3, #10 * @param pcb the tcp_pcb to abort * @param reset boolean to indicate whether a reset should be sent */ void tcp_abandon(struct tcp_pcb *pcb, int reset) { 802d908: e92d 43f7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, lr} 802d90c: 4604 mov r4, r0 802d90e: 4689 mov r9, r1 LWIP_ASSERT("don't call tcp_abort/tcp_abandon for listen-pcbs", pcb->state != LISTEN); /* Figure out on which TCP PCB list we are, and remove us. If we are in an active state, call the receive function associated with the PCB with a NULL argument, and send an RST to the remote end. */ if (pcb->state == TIME_WAIT) { 802d910: d10a bne.n 802d928 tcp_pcb_remove(&tcp_tw_pcbs, pcb); 802d912: 4621 mov r1, r4 802d914: 481b ldr r0, [pc, #108] ; (802d984 ) 802d916: f7ff ffc7 bl 802d8a8 memp_free(MEMP_TCP_PCB, pcb); 802d91a: 2002 movs r0, #2 802d91c: 4621 mov r1, r4 tcp_rst(seqno, ackno, &pcb->local_ip, &pcb->remote_ip, pcb->local_port, pcb->remote_port); } memp_free(MEMP_TCP_PCB, pcb); TCP_EVENT_ERR(errf, errf_arg, ERR_ABRT); } } 802d91e: b003 add sp, #12 802d920: e8bd 43f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, lr} /* Figure out on which TCP PCB list we are, and remove us. If we are in an active state, call the receive function associated with the PCB with a NULL argument, and send an RST to the remote end. */ if (pcb->state == TIME_WAIT) { tcp_pcb_remove(&tcp_tw_pcbs, pcb); memp_free(MEMP_TCP_PCB, pcb); 802d924: f7ff ba7a b.w 802ce1c } else { seqno = pcb->snd_nxt; 802d928: f8d0 8050 ldr.w r8, [r0, #80] ; 0x50 ackno = pcb->rcv_nxt; 802d92c: 6a87 ldr r7, [r0, #40] ; 0x28 #if LWIP_CALLBACK_API errf = pcb->errf; 802d92e: f8d0 5088 ldr.w r5, [r0, #136] ; 0x88 #endif /* LWIP_CALLBACK_API */ errf_arg = pcb->callback_arg; 802d932: 6906 ldr r6, [r0, #16] TCP_PCB_REMOVE_ACTIVE(pcb); 802d934: 4814 ldr r0, [pc, #80] ; (802d988 ) 802d936: 4621 mov r1, r4 802d938: f7ff ffb6 bl 802d8a8 802d93c: 4b13 ldr r3, [pc, #76] ; (802d98c ) if (pcb->unacked != NULL) { 802d93e: 6f20 ldr r0, [r4, #112] ; 0x70 ackno = pcb->rcv_nxt; #if LWIP_CALLBACK_API errf = pcb->errf; #endif /* LWIP_CALLBACK_API */ errf_arg = pcb->callback_arg; TCP_PCB_REMOVE_ACTIVE(pcb); 802d940: 2201 movs r2, #1 802d942: 701a strb r2, [r3, #0] if (pcb->unacked != NULL) { 802d944: b108 cbz r0, 802d94a tcp_segs_free(pcb->unacked); 802d946: f7ff fe2e bl 802d5a6 } if (pcb->unsent != NULL) { 802d94a: 6ee0 ldr r0, [r4, #108] ; 0x6c 802d94c: b108 cbz r0, 802d952 tcp_segs_free(pcb->unsent); 802d94e: f7ff fe2a bl 802d5a6 #if TCP_QUEUE_OOSEQ if (pcb->ooseq != NULL) { tcp_segs_free(pcb->ooseq); } #endif /* TCP_QUEUE_OOSEQ */ if (reset) { 802d952: f1b9 0f00 cmp.w r9, #0 802d956: d009 beq.n 802d96c LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_abandon: sending RST\n")); tcp_rst(seqno, ackno, &pcb->local_ip, &pcb->remote_ip, pcb->local_port, pcb->remote_port); 802d958: 8b63 ldrh r3, [r4, #26] 802d95a: 9300 str r3, [sp, #0] 802d95c: 8ba3 ldrh r3, [r4, #28] 802d95e: 4640 mov r0, r8 802d960: 9301 str r3, [sp, #4] 802d962: 4639 mov r1, r7 802d964: 4622 mov r2, r4 802d966: 1d23 adds r3, r4, #4 802d968: f001 fcc2 bl 802f2f0 } memp_free(MEMP_TCP_PCB, pcb); 802d96c: 2002 movs r0, #2 802d96e: 4621 mov r1, r4 802d970: f7ff fa54 bl 802ce1c TCP_EVENT_ERR(errf, errf_arg, ERR_ABRT); 802d974: b11d cbz r5, 802d97e 802d976: 4630 mov r0, r6 802d978: f06f 0109 mvn.w r1, #9 802d97c: 47a8 blx r5 } } 802d97e: b003 add sp, #12 802d980: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 802d984: 20010ff0 .word 0x20010ff0 802d988: 20010fdc .word 0x20010fdc 802d98c: 20010fd8 .word 0x20010fd8 0802d990 : * @param pcb the tcp pcb to abort */ void tcp_abort(struct tcp_pcb *pcb) { tcp_abandon(pcb, 1); 802d990: 2101 movs r1, #1 802d992: f7ff bfb7 b.w 802d904 802d996: 0000 movs r0, r0 0802d998 : * @return ERR_OK if connection has been closed * another err_t if closing failed and pcb is not freed */ static err_t tcp_close_shutdown(struct tcp_pcb *pcb, u8_t rst_on_unacked_data) { 802d998: b537 push {r0, r1, r2, r4, r5, lr} 802d99a: 4604 mov r4, r0 err_t err; if (rst_on_unacked_data && ((pcb->state == ESTABLISHED) || (pcb->state == CLOSE_WAIT))) { 802d99c: 2900 cmp r1, #0 802d99e: d043 beq.n 802da28 802d9a0: 7e03 ldrb r3, [r0, #24] 802d9a2: 2b04 cmp r3, #4 802d9a4: d001 beq.n 802d9aa 802d9a6: 2b07 cmp r3, #7 802d9a8: d13e bne.n 802da28 if ((pcb->refused_data != NULL) || (pcb->rcv_wnd != TCP_WND)) { 802d9aa: 6f63 ldr r3, [r4, #116] ; 0x74 802d9ac: b923 cbnz r3, 802d9b8 802d9ae: 8da2 ldrh r2, [r4, #44] ; 0x2c 802d9b0: f241 63d0 movw r3, #5840 ; 0x16d0 802d9b4: 429a cmp r2, r3 802d9b6: d037 beq.n 802da28 side about this. */ LWIP_ASSERT("pcb->flags & TF_RXCLOSED", pcb->flags & TF_RXCLOSED); /* don't call tcp_abort here: we must not deallocate the pcb since that might not be expected when calling tcp_close */ tcp_rst(pcb->snd_nxt, pcb->rcv_nxt, &pcb->local_ip, &pcb->remote_ip, 802d9b8: 8b63 ldrh r3, [r4, #26] 802d9ba: 6d20 ldr r0, [r4, #80] ; 0x50 802d9bc: 9300 str r3, [sp, #0] 802d9be: 8ba3 ldrh r3, [r4, #28] 802d9c0: 6aa1 ldr r1, [r4, #40] ; 0x28 802d9c2: 9301 str r3, [sp, #4] 802d9c4: 4622 mov r2, r4 802d9c6: 1d23 adds r3, r4, #4 802d9c8: f001 fc92 bl 802f2f0 pcb->local_port, pcb->remote_port); tcp_pcb_purge(pcb); 802d9cc: 4620 mov r0, r4 802d9ce: f7ff fe03 bl 802d5d8 TCP_RMV_ACTIVE(pcb); 802d9d2: 4a42 ldr r2, [pc, #264] ; (802dadc ) 802d9d4: 6813 ldr r3, [r2, #0] 802d9d6: 42a3 cmp r3, r4 802d9d8: d101 bne.n 802d9de 802d9da: 68e3 ldr r3, [r4, #12] 802d9dc: e00c b.n 802d9f8 802d9de: 4a40 ldr r2, [pc, #256] ; (802dae0 ) 802d9e0: 6013 str r3, [r2, #0] 802d9e2: e007 b.n 802d9f4 802d9e4: 68d9 ldr r1, [r3, #12] 802d9e6: 42a1 cmp r1, r4 802d9e8: d103 bne.n 802d9f2 802d9ea: 6013 str r3, [r2, #0] 802d9ec: 68e2 ldr r2, [r4, #12] 802d9ee: 60da str r2, [r3, #12] 802d9f0: e003 b.n 802d9fa 802d9f2: 460b mov r3, r1 802d9f4: 2b00 cmp r3, #0 802d9f6: d1f5 bne.n 802d9e4 802d9f8: 6013 str r3, [r2, #0] 802d9fa: 4b3a ldr r3, [pc, #232] ; (802dae4 ) 802d9fc: 2201 movs r2, #1 802d9fe: 701a strb r2, [r3, #0] if (pcb->state == ESTABLISHED) { 802da00: 7e23 ldrb r3, [r4, #24] that might not be expected when calling tcp_close */ tcp_rst(pcb->snd_nxt, pcb->rcv_nxt, &pcb->local_ip, &pcb->remote_ip, pcb->local_port, pcb->remote_port); tcp_pcb_purge(pcb); TCP_RMV_ACTIVE(pcb); 802da02: 2500 movs r5, #0 if (pcb->state == ESTABLISHED) { 802da04: 2b04 cmp r3, #4 that might not be expected when calling tcp_close */ tcp_rst(pcb->snd_nxt, pcb->rcv_nxt, &pcb->local_ip, &pcb->remote_ip, pcb->local_port, pcb->remote_port); tcp_pcb_purge(pcb); TCP_RMV_ACTIVE(pcb); 802da06: 60e5 str r5, [r4, #12] if (pcb->state == ESTABLISHED) { 802da08: d108 bne.n 802da1c /* move to TIME_WAIT since we close actively */ pcb->state = TIME_WAIT; 802da0a: 230a movs r3, #10 802da0c: 7623 strb r3, [r4, #24] TCP_REG(&tcp_tw_pcbs, pcb); 802da0e: 4b36 ldr r3, [pc, #216] ; (802dae8 ) 802da10: 681a ldr r2, [r3, #0] 802da12: 601c str r4, [r3, #0] 802da14: 60e2 str r2, [r4, #12] 802da16: f001 fe05 bl 802f624 802da1a: e003 b.n 802da24 } else { /* CLOSE_WAIT: deallocate the pcb since we already sent a RST for it */ memp_free(MEMP_TCP_PCB, pcb); 802da1c: 2002 movs r0, #2 802da1e: 4621 mov r1, r4 802da20: f7ff f9fc bl 802ce1c } return ERR_OK; 802da24: 4628 mov r0, r5 802da26: e051 b.n 802dacc } } switch (pcb->state) { 802da28: 7e23 ldrb r3, [r4, #24] 802da2a: 2b07 cmp r3, #7 802da2c: d853 bhi.n 802dad6 802da2e: e8df f003 tbb [pc, r3] 802da32: 1e04 .short 0x1e04 802da34: 523c3527 .word 0x523c3527 802da38: 4452 .short 0x4452 * Calling tcp_close() with a pcb that has already been closed, (i.e. twice) * or for a pcb that has been used and then entered the CLOSED state * is erroneous, but this should never happen as the pcb has in those cases * been freed, and so any remaining handles are bogus. */ err = ERR_OK; if (pcb->local_port != 0) { 802da3a: 8b63 ldrh r3, [r4, #26] 802da3c: b1ab cbz r3, 802da6a TCP_RMV(&tcp_bound_pcbs, pcb); 802da3e: 4a2b ldr r2, [pc, #172] ; (802daec ) 802da40: 6813 ldr r3, [r2, #0] 802da42: 42a3 cmp r3, r4 802da44: d101 bne.n 802da4a 802da46: 68e3 ldr r3, [r4, #12] 802da48: e00c b.n 802da64 802da4a: 4a25 ldr r2, [pc, #148] ; (802dae0 ) 802da4c: 6013 str r3, [r2, #0] 802da4e: e007 b.n 802da60 802da50: 68d9 ldr r1, [r3, #12] 802da52: 42a1 cmp r1, r4 802da54: d103 bne.n 802da5e 802da56: 6013 str r3, [r2, #0] 802da58: 68e2 ldr r2, [r4, #12] 802da5a: 60da str r2, [r3, #12] 802da5c: e003 b.n 802da66 802da5e: 460b mov r3, r1 802da60: 2b00 cmp r3, #0 802da62: d1f5 bne.n 802da50 802da64: 6013 str r3, [r2, #0] 802da66: 2300 movs r3, #0 802da68: 60e3 str r3, [r4, #12] } memp_free(MEMP_TCP_PCB, pcb); 802da6a: 2002 movs r0, #2 802da6c: e004 b.n 802da78 pcb = NULL; break; case LISTEN: err = ERR_OK; tcp_pcb_remove(&tcp_listen_pcbs.pcbs, pcb); 802da6e: 4820 ldr r0, [pc, #128] ; (802daf0 ) 802da70: 4621 mov r1, r4 802da72: f7ff ff19 bl 802d8a8 memp_free(MEMP_TCP_PCB_LISTEN, pcb); 802da76: 2003 movs r0, #3 802da78: 4621 mov r1, r4 802da7a: f7ff f9cf bl 802ce1c pcb = NULL; break; 802da7e: e02a b.n 802dad6 case SYN_SENT: err = ERR_OK; TCP_PCB_REMOVE_ACTIVE(pcb); 802da80: 4621 mov r1, r4 802da82: 4816 ldr r0, [pc, #88] ; (802dadc ) 802da84: f7ff ff10 bl 802d8a8 802da88: 4b16 ldr r3, [pc, #88] ; (802dae4 ) 802da8a: 2201 movs r2, #1 memp_free(MEMP_TCP_PCB, pcb); 802da8c: 2002 movs r0, #2 802da8e: 4621 mov r1, r4 memp_free(MEMP_TCP_PCB_LISTEN, pcb); pcb = NULL; break; case SYN_SENT: err = ERR_OK; TCP_PCB_REMOVE_ACTIVE(pcb); 802da90: 701a strb r2, [r3, #0] memp_free(MEMP_TCP_PCB, pcb); 802da92: f7ff f9c3 bl 802ce1c pcb = NULL; snmp_inc_tcpattemptfails(); 802da96: f004 f893 bl 8031bc0 break; 802da9a: e01c b.n 802dad6 case SYN_RCVD: err = tcp_send_fin(pcb); 802da9c: 4620 mov r0, r4 802da9e: f001 fabe bl 802f01e if (err == ERR_OK) { 802daa2: b998 cbnz r0, 802dacc snmp_inc_tcpattemptfails(); 802daa4: f004 f88c bl 8031bc0 802daa8: e005 b.n 802dab6 pcb->state = FIN_WAIT_1; } break; case ESTABLISHED: err = tcp_send_fin(pcb); 802daaa: 4620 mov r0, r4 802daac: f001 fab7 bl 802f01e if (err == ERR_OK) { 802dab0: b960 cbnz r0, 802dacc snmp_inc_tcpestabresets(); 802dab2: f004 f88d bl 8031bd0 pcb->state = FIN_WAIT_1; 802dab6: 2305 movs r3, #5 802dab8: e006 b.n 802dac8 } break; case CLOSE_WAIT: err = tcp_send_fin(pcb); 802daba: 4620 mov r0, r4 802dabc: f001 faaf bl 802f01e if (err == ERR_OK) { 802dac0: b920 cbnz r0, 802dacc snmp_inc_tcpestabresets(); 802dac2: f004 f885 bl 8031bd0 pcb->state = LAST_ACK; 802dac6: 2309 movs r3, #9 802dac8: 7623 strb r3, [r4, #24] 802daca: e001 b.n 802dad0 802dacc: b240 sxtb r0, r0 802dace: e004 b.n 802dada returns (unsent data is sent from tcp timer functions, also), we don't care for the return value of tcp_output for now. */ /* @todo: When implementing SO_LINGER, this must be changed somehow: If SOF_LINGER is set, the data should be sent and acked before close returns. This can only be valid for sequential APIs, not for the raw API. */ tcp_output(pcb); 802dad0: 4620 mov r0, r4 802dad2: f001 fae9 bl 802f0a8 802dad6: 2000 movs r0, #0 802dad8: e7f8 b.n 802dacc } return err; } 802dada: bd3e pop {r1, r2, r3, r4, r5, pc} 802dadc: 20010fdc .word 0x20010fdc 802dae0: 20010fe8 .word 0x20010fe8 802dae4: 20010fd8 .word 0x20010fd8 802dae8: 20010ff0 .word 0x20010ff0 802daec: 20010fec .word 0x20010fec 802daf0: 20010fe4 .word 0x20010fe4 0802daf4 : #if TCP_DEBUG LWIP_DEBUGF(TCP_DEBUG, ("tcp_close: closing in ")); tcp_debug_print_state(pcb->state); #endif /* TCP_DEBUG */ if (pcb->state != LISTEN) { 802daf4: 7e03 ldrb r3, [r0, #24] 802daf6: 2b01 cmp r3, #1 802daf8: d003 beq.n 802db02 /* Set a flag not to receive any more data... */ pcb->flags |= TF_RXCLOSED; 802dafa: 7f83 ldrb r3, [r0, #30] 802dafc: f043 0310 orr.w r3, r3, #16 802db00: 7783 strb r3, [r0, #30] } /* ... and close */ return tcp_close_shutdown(pcb, 1); 802db02: 2101 movs r1, #1 802db04: f7ff bf48 b.w 802d998 0802db08 : * Default receive callback that is called if the user didn't register * a recv callback for the pcb. */ err_t tcp_recv_null(void *arg, struct tcp_pcb *pcb, struct pbuf *p, err_t err) { 802db08: b510 push {r4, lr} 802db0a: 4608 mov r0, r1 LWIP_UNUSED_ARG(arg); if (p != NULL) { 802db0c: 4614 mov r4, r2 802db0e: b132 cbz r2, 802db1e tcp_recved(pcb, p->tot_len); 802db10: 8911 ldrh r1, [r2, #8] 802db12: f7ff fd1f bl 802d554 pbuf_free(p); 802db16: 4620 mov r0, r4 802db18: f7ff fa8a bl 802d030 802db1c: e004 b.n 802db28 } else if (err == ERR_OK) { 802db1e: b91b cbnz r3, 802db28 return tcp_close(pcb); } return ERR_OK; } 802db20: e8bd 4010 ldmia.w sp!, {r4, lr} LWIP_UNUSED_ARG(arg); if (p != NULL) { tcp_recved(pcb, p->tot_len); pbuf_free(p); } else if (err == ERR_OK) { return tcp_close(pcb); 802db24: f7ff bfe6 b.w 802daf4 } return ERR_OK; } 802db28: 2000 movs r0, #0 802db2a: bd10 pop {r4, pc} 0802db2c : } /** Pass pcb->refused_data to the recv callback */ err_t tcp_process_refused_data(struct tcp_pcb *pcb) { 802db2c: b5f8 push {r3, r4, r5, r6, r7, lr} err_t err; u8_t refused_flags = pcb->refused_data->flags; 802db2e: 6f45 ldr r5, [r0, #116] ; 0x74 closes the pcb */ struct pbuf *refused_data = pcb->refused_data; pcb->refused_data = NULL; /* Notify again application with data previously received. */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_input: notify kept packet\n")); TCP_EVENT_RECV(pcb, refused_data, ERR_OK, err); 802db30: 6fc6 ldr r6, [r0, #124] ; 0x7c /** Pass pcb->refused_data to the recv callback */ err_t tcp_process_refused_data(struct tcp_pcb *pcb) { err_t err; u8_t refused_flags = pcb->refused_data->flags; 802db32: 7b6f ldrb r7, [r5, #13] /* set pcb->refused_data to NULL in case the callback frees it and then closes the pcb */ struct pbuf *refused_data = pcb->refused_data; pcb->refused_data = NULL; 802db34: 2300 movs r3, #0 } /** Pass pcb->refused_data to the recv callback */ err_t tcp_process_refused_data(struct tcp_pcb *pcb) { 802db36: 4604 mov r4, r0 err_t err; u8_t refused_flags = pcb->refused_data->flags; /* set pcb->refused_data to NULL in case the callback frees it and then closes the pcb */ struct pbuf *refused_data = pcb->refused_data; pcb->refused_data = NULL; 802db38: 6743 str r3, [r0, #116] ; 0x74 /* Notify again application with data previously received. */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_input: notify kept packet\n")); TCP_EVENT_RECV(pcb, refused_data, ERR_OK, err); 802db3a: b126 cbz r6, 802db46 802db3c: 4621 mov r1, r4 802db3e: 462a mov r2, r5 802db40: 6900 ldr r0, [r0, #16] 802db42: 47b0 blx r6 802db44: e005 b.n 802db52 802db46: 4630 mov r0, r6 802db48: 4621 mov r1, r4 802db4a: 462a mov r2, r5 802db4c: 4633 mov r3, r6 802db4e: f7ff ffdb bl 802db08 if (err == ERR_OK) { 802db52: b9b0 cbnz r0, 802db82 /* did refused_data include a FIN? */ if (refused_flags & PBUF_FLAG_TCP_FIN) { 802db54: f007 0720 and.w r7, r7, #32 802db58: b2ff uxtb r7, r7 802db5a: b1bf cbz r7, 802db8c /* correct rcv_wnd as the application won't call tcp_recved() for the FIN's seqno */ if (pcb->rcv_wnd != TCP_WND) { 802db5c: 8da3 ldrh r3, [r4, #44] ; 0x2c 802db5e: f241 62d0 movw r2, #5840 ; 0x16d0 802db62: 4293 cmp r3, r2 802db64: d001 beq.n 802db6a pcb->rcv_wnd++; 802db66: 3301 adds r3, #1 802db68: 85a3 strh r3, [r4, #44] ; 0x2c } TCP_EVENT_CLOSED(pcb, err); 802db6a: 6fe5 ldr r5, [r4, #124] ; 0x7c 802db6c: b905 cbnz r5, 802db70 802db6e: e00c b.n 802db8a 802db70: 2200 movs r2, #0 802db72: 6920 ldr r0, [r4, #16] 802db74: 4621 mov r1, r4 802db76: 4613 mov r3, r2 802db78: 47a8 blx r5 if (err == ERR_ABRT) { 802db7a: 300a adds r0, #10 802db7c: d105 bne.n 802db8a return ERR_ABRT; 802db7e: 20f6 movs r0, #246 ; 0xf6 802db80: e004 b.n 802db8c } } } else if (err == ERR_ABRT) { 802db82: b240 sxtb r0, r0 802db84: 300a adds r0, #10 802db86: d0fa beq.n 802db7e segment contains data). */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_input: drop incoming packets, because pcb is \"full\"\n")); return ERR_ABRT; } else { /* data is still refused, pbuf is still valid (go on for ACK-only packets) */ pcb->refused_data = refused_data; 802db88: 6765 str r5, [r4, #116] ; 0x74 } return ERR_OK; 802db8a: 2000 movs r0, #0 } 802db8c: b240 sxtb r0, r0 802db8e: bdf8 pop {r3, r4, r5, r6, r7, pc} 0802db90 : * * Automatically called from tcp_tmr(). */ void tcp_fasttmr(void) { 802db90: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} struct tcp_pcb *pcb; ++tcp_timer_ctr; 802db94: 4b18 ldr r3, [pc, #96] ; (802dbf8 ) tcp_fasttmr_start: pcb = tcp_active_pcbs; 802db96: 4f19 ldr r7, [pc, #100] ; (802dbfc ) void tcp_fasttmr(void) { struct tcp_pcb *pcb; ++tcp_timer_ctr; 802db98: 781a ldrb r2, [r3, #0] 802db9a: 3201 adds r2, #1 802db9c: 701a strb r2, [r3, #0] tcp_fasttmr_start: pcb = tcp_active_pcbs; while(pcb != NULL) { if (pcb->last_timer != tcp_timer_ctr) { 802db9e: 4698 mov r8, r3 struct tcp_pcb *pcb; ++tcp_timer_ctr; tcp_fasttmr_start: pcb = tcp_active_pcbs; 802dba0: 683c ldr r4, [r7, #0] next = pcb->next; /* If there is data which was previously "refused" by upper layer */ if (pcb->refused_data != NULL) { tcp_active_pcbs_changed = 0; 802dba2: 4d17 ldr r5, [pc, #92] ; (802dc00 ) 802dba4: 2600 movs r6, #0 ++tcp_timer_ctr; tcp_fasttmr_start: pcb = tcp_active_pcbs; while(pcb != NULL) { 802dba6: e022 b.n 802dbee if (pcb->last_timer != tcp_timer_ctr) { 802dba8: f898 2000 ldrb.w r2, [r8] 802dbac: f894 3021 ldrb.w r3, [r4, #33] ; 0x21 802dbb0: 4293 cmp r3, r2 802dbb2: d020 beq.n 802dbf6 struct tcp_pcb *next; pcb->last_timer = tcp_timer_ctr; 802dbb4: f884 2021 strb.w r2, [r4, #33] ; 0x21 /* send delayed ACKs */ if (pcb->flags & TF_ACK_DELAY) { 802dbb8: 7fa2 ldrb r2, [r4, #30] 802dbba: 07d1 lsls r1, r2, #31 802dbbc: d509 bpl.n 802dbd2 LWIP_DEBUGF(TCP_DEBUG, ("tcp_fasttmr: delayed ACK\n")); tcp_ack_now(pcb); 802dbbe: f042 0202 orr.w r2, r2, #2 802dbc2: 77a2 strb r2, [r4, #30] tcp_output(pcb); 802dbc4: 4620 mov r0, r4 802dbc6: f001 fa6f bl 802f0a8 pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); 802dbca: 7fa3 ldrb r3, [r4, #30] 802dbcc: f023 0303 bic.w r3, r3, #3 802dbd0: 77a3 strb r3, [r4, #30] } next = pcb->next; /* If there is data which was previously "refused" by upper layer */ if (pcb->refused_data != NULL) { 802dbd2: 6f63 ldr r3, [r4, #116] ; 0x74 tcp_ack_now(pcb); tcp_output(pcb); pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); } next = pcb->next; 802dbd4: f8d4 900c ldr.w r9, [r4, #12] /* If there is data which was previously "refused" by upper layer */ if (pcb->refused_data != NULL) { 802dbd8: b90b cbnz r3, 802dbde 802dbda: 464c mov r4, r9 802dbdc: e007 b.n 802dbee tcp_active_pcbs_changed = 0; tcp_process_refused_data(pcb); 802dbde: 4620 mov r0, r4 next = pcb->next; /* If there is data which was previously "refused" by upper layer */ if (pcb->refused_data != NULL) { tcp_active_pcbs_changed = 0; 802dbe0: 702e strb r6, [r5, #0] tcp_process_refused_data(pcb); 802dbe2: f7ff ffa3 bl 802db2c if (tcp_active_pcbs_changed) { 802dbe6: 782b ldrb r3, [r5, #0] 802dbe8: 2b00 cmp r3, #0 802dbea: d1d9 bne.n 802dba0 802dbec: e7f5 b.n 802dbda ++tcp_timer_ctr; tcp_fasttmr_start: pcb = tcp_active_pcbs; while(pcb != NULL) { 802dbee: 2c00 cmp r4, #0 802dbf0: d1da bne.n 802dba8 802dbf2: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 802dbf6: e7fe b.n 802dbf6 802dbf8: 2000e0ed .word 0x2000e0ed 802dbfc: 20010fdc .word 0x20010fdc 802dc00: 20010fd8 .word 0x20010fd8 0802dc04 : /** * Called periodically to dispatch TCP timers. */ void tcp_tmr(void) { 802dc04: b508 push {r3, lr} /* Call tcp_fasttmr() every 250 ms */ tcp_fasttmr(); 802dc06: f7ff ffc3 bl 802db90 if (++tcp_timer & 1) { 802dc0a: 4a06 ldr r2, [pc, #24] ; (802dc24 ) 802dc0c: 7813 ldrb r3, [r2, #0] 802dc0e: 3301 adds r3, #1 802dc10: b2db uxtb r3, r3 802dc12: 07d8 lsls r0, r3, #31 802dc14: 7013 strb r3, [r2, #0] 802dc16: d503 bpl.n 802dc20 /* Call tcp_tmr() every 500 ms, i.e., every other timer tcp_tmr() is called. */ tcp_slowtmr(); } } 802dc18: e8bd 4008 ldmia.w sp!, {r3, lr} tcp_fasttmr(); if (++tcp_timer & 1) { /* Call tcp_tmr() every 500 ms, i.e., every other timer tcp_tmr() is called. */ tcp_slowtmr(); 802dc1c: f7ff bcfa b.w 802d614 802dc20: bd08 pop {r3, pc} 802dc22: bf00 nop 802dc24: 2000e0ec .word 0x2000e0ec 0802dc28 : u32_t tcp_next_iss(void) { static u32_t iss = 6510; iss += tcp_ticks; /* XXX */ 802dc28: 4b03 ldr r3, [pc, #12] ; (802dc38 ) 802dc2a: 4a04 ldr r2, [pc, #16] ; (802dc3c ) 802dc2c: 6810 ldr r0, [r2, #0] 802dc2e: 681a ldr r2, [r3, #0] 802dc30: 1880 adds r0, r0, r2 802dc32: 6018 str r0, [r3, #0] return iss; } 802dc34: 4770 bx lr 802dc36: bf00 nop 802dc38: 200015e8 .word 0x200015e8 802dc3c: 20010fe0 .word 0x20010fe0 0802dc40 : * @param prio priority for the new pcb * @return a new tcp_pcb that initially is in state CLOSED */ struct tcp_pcb * tcp_alloc(u8_t prio) { 802dc40: b5f8 push {r3, r4, r5, r6, r7, lr} 802dc42: 4605 mov r5, r0 struct tcp_pcb *pcb; u32_t iss; pcb = (struct tcp_pcb *)memp_malloc(MEMP_TCP_PCB); 802dc44: 2002 movs r0, #2 802dc46: f7ff f8d3 bl 802cdf0 if (pcb == NULL) { 802dc4a: 4604 mov r4, r0 802dc4c: 2800 cmp r0, #0 802dc4e: d136 bne.n 802dcbe u32_t inactivity; inactivity = 0; inactive = NULL; /* Go through the list of TIME_WAIT pcbs and get the oldest pcb. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { 802dc50: 4b39 ldr r3, [pc, #228] ; (802dd38 ) if ((u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { 802dc52: 4a3a ldr r2, [pc, #232] ; (802dd3c ) u32_t inactivity; inactivity = 0; inactive = NULL; /* Go through the list of TIME_WAIT pcbs and get the oldest pcb. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { 802dc54: 681b ldr r3, [r3, #0] if ((u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { 802dc56: 6811 ldr r1, [r2, #0] 802dc58: e007 b.n 802dc6a 802dc5a: 6a5a ldr r2, [r3, #36] ; 0x24 802dc5c: 1a8a subs r2, r1, r2 802dc5e: 42a2 cmp r2, r4 802dc60: bf34 ite cc 802dc62: 4622 movcc r2, r4 802dc64: 4618 movcs r0, r3 u32_t inactivity; inactivity = 0; inactive = NULL; /* Go through the list of TIME_WAIT pcbs and get the oldest pcb. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { 802dc66: 68db ldr r3, [r3, #12] 802dc68: 4614 mov r4, r2 802dc6a: 2b00 cmp r3, #0 802dc6c: d1f5 bne.n 802dc5a if ((u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { inactivity = tcp_ticks - pcb->tmr; inactive = pcb; } } if (inactive != NULL) { 802dc6e: b108 cbz r0, 802dc74 LWIP_DEBUGF(TCP_DEBUG, ("tcp_kill_timewait: killing oldest TIME-WAIT PCB %p (%"S32_F")\n", (void *)inactive, inactivity)); tcp_abort(inactive); 802dc70: f7ff fe8e bl 802d990 if (pcb == NULL) { /* Try killing oldest connection in TIME-WAIT. */ LWIP_DEBUGF(TCP_DEBUG, ("tcp_alloc: killing off oldest TIME-WAIT connection\n")); tcp_kill_timewait(); /* Try to allocate a tcp_pcb again. */ pcb = (struct tcp_pcb *)memp_malloc(MEMP_TCP_PCB); 802dc74: 2002 movs r0, #2 802dc76: f7ff f8bb bl 802cdf0 if (pcb == NULL) { 802dc7a: 4604 mov r4, r0 802dc7c: b9f8 cbnz r0, 802dcbe inactivity = 0; inactive = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { if (pcb->prio <= prio && pcb->prio <= mprio && (u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { 802dc7e: 4a2f ldr r2, [pc, #188] ; (802dd3c ) mprio = TCP_PRIO_MAX; /* We kill the oldest active connection that has lower priority than prio. */ inactivity = 0; inactive = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802dc80: 4b2f ldr r3, [pc, #188] ; (802dd40 ) if (pcb->prio <= prio && pcb->prio <= mprio && (u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { 802dc82: 6817 ldr r7, [r2, #0] mprio = TCP_PRIO_MAX; /* We kill the oldest active connection that has lower priority than prio. */ inactivity = 0; inactive = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802dc84: 681b ldr r3, [r3, #0] struct tcp_pcb *pcb, *inactive; u32_t inactivity; u8_t mprio; mprio = TCP_PRIO_MAX; 802dc86: 207f movs r0, #127 ; 0x7f /* We kill the oldest active connection that has lower priority than prio. */ inactivity = 0; inactive = NULL; 802dc88: 4622 mov r2, r4 802dc8a: e00c b.n 802dca6 for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { if (pcb->prio <= prio && 802dc8c: 7e59 ldrb r1, [r3, #25] 802dc8e: 42a9 cmp r1, r5 802dc90: d808 bhi.n 802dca4 802dc92: 4281 cmp r1, r0 802dc94: d806 bhi.n 802dca4 pcb->prio <= mprio && (u32_t)(tcp_ticks - pcb->tmr) >= inactivity) { 802dc96: 6a5e ldr r6, [r3, #36] ; 0x24 802dc98: 1bbe subs r6, r7, r6 /* We kill the oldest active connection that has lower priority than prio. */ inactivity = 0; inactive = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { if (pcb->prio <= prio && pcb->prio <= mprio && 802dc9a: 42a6 cmp r6, r4 802dc9c: d302 bcc.n 802dca4 802dc9e: 4608 mov r0, r1 802dca0: 4634 mov r4, r6 802dca2: 461a mov r2, r3 mprio = TCP_PRIO_MAX; /* We kill the oldest active connection that has lower priority than prio. */ inactivity = 0; inactive = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802dca4: 68db ldr r3, [r3, #12] 802dca6: 2b00 cmp r3, #0 802dca8: d1f0 bne.n 802dc8c inactivity = tcp_ticks - pcb->tmr; inactive = pcb; mprio = pcb->prio; } } if (inactive != NULL) { 802dcaa: b112 cbz r2, 802dcb2 LWIP_DEBUGF(TCP_DEBUG, ("tcp_kill_prio: killing oldest PCB %p (%"S32_F")\n", (void *)inactive, inactivity)); tcp_abort(inactive); 802dcac: 4610 mov r0, r2 802dcae: f7ff fe6f bl 802d990 if (pcb == NULL) { /* Try killing active connections with lower priority than the new one. */ LWIP_DEBUGF(TCP_DEBUG, ("tcp_alloc: killing connection with prio lower than %d\n", prio)); tcp_kill_prio(prio); /* Try to allocate a tcp_pcb again. */ pcb = (struct tcp_pcb *)memp_malloc(MEMP_TCP_PCB); 802dcb2: 2002 movs r0, #2 802dcb4: f7ff f89c bl 802cdf0 if (pcb != NULL) { /* adjust err stats: timewait PCB was freed above */ MEMP_STATS_DEC(err, MEMP_TCP_PCB); } } if (pcb != NULL) { 802dcb8: 4604 mov r4, r0 802dcba: 2800 cmp r0, #0 802dcbc: d039 beq.n 802dd32 memset(pcb, 0, sizeof(struct tcp_pcb)); 802dcbe: 2100 movs r1, #0 802dcc0: 2294 movs r2, #148 ; 0x94 802dcc2: 4620 mov r0, r4 802dcc4: f7f3 fefc bl 8021ac0 pcb->prio = prio; pcb->snd_buf = TCP_SND_BUF; pcb->snd_queuelen = 0; pcb->rcv_wnd = TCP_WND; 802dcc8: f241 62d0 movw r2, #5840 ; 0x16d0 } } if (pcb != NULL) { memset(pcb, 0, sizeof(struct tcp_pcb)); pcb->prio = prio; pcb->snd_buf = TCP_SND_BUF; 802dccc: f246 63a8 movw r3, #26280 ; 0x66a8 802dcd0: f8a4 3066 strh.w r3, [r4, #102] ; 0x66 pcb->snd_queuelen = 0; pcb->rcv_wnd = TCP_WND; 802dcd4: 85a2 strh r2, [r4, #44] ; 0x2c } if (pcb != NULL) { memset(pcb, 0, sizeof(struct tcp_pcb)); pcb->prio = prio; pcb->snd_buf = TCP_SND_BUF; pcb->snd_queuelen = 0; 802dcd6: 2300 movs r3, #0 pcb->rcv_wnd = TCP_WND; pcb->rcv_ann_wnd = TCP_WND; 802dcd8: 85e2 strh r2, [r4, #46] ; 0x2e pcb->tos = 0; pcb->ttl = TCP_TTL; 802dcda: 22ff movs r2, #255 ; 0xff MEMP_STATS_DEC(err, MEMP_TCP_PCB); } } if (pcb != NULL) { memset(pcb, 0, sizeof(struct tcp_pcb)); pcb->prio = prio; 802dcdc: 7665 strb r5, [r4, #25] pcb->snd_buf = TCP_SND_BUF; pcb->snd_queuelen = 0; 802dcde: f8a4 3068 strh.w r3, [r4, #104] ; 0x68 802dce2: 461d mov r5, r3 pcb->rcv_wnd = TCP_WND; pcb->rcv_ann_wnd = TCP_WND; pcb->tos = 0; 802dce4: 7263 strb r3, [r4, #9] pcb->ttl = TCP_TTL; 802dce6: 72a2 strb r2, [r4, #10] /* As initial send MSS, we use TCP_MSS but limit it to 536. The send MSS is updated when an MSS option is received. */ pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS; pcb->rto = 3000 / TCP_SLOW_INTERVAL; pcb->sa = 0; 802dce8: f8a4 3040 strh.w r3, [r4, #64] ; 0x40 pcb->rcv_ann_wnd = TCP_WND; pcb->tos = 0; pcb->ttl = TCP_TTL; /* As initial send MSS, we use TCP_MSS but limit it to 536. The send MSS is updated when an MSS option is received. */ pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS; 802dcec: f44f 7206 mov.w r2, #536 ; 0x218 pcb->rto = 3000 / TCP_SLOW_INTERVAL; pcb->sa = 0; pcb->sv = 3000 / TCP_SLOW_INTERVAL; pcb->rtime = -1; 802dcf0: f64f 73ff movw r3, #65535 ; 0xffff pcb->rcv_ann_wnd = TCP_WND; pcb->tos = 0; pcb->ttl = TCP_TTL; /* As initial send MSS, we use TCP_MSS but limit it to 536. The send MSS is updated when an MSS option is received. */ pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS; 802dcf4: 86e2 strh r2, [r4, #54] ; 0x36 pcb->rto = 3000 / TCP_SLOW_INTERVAL; pcb->sa = 0; pcb->sv = 3000 / TCP_SLOW_INTERVAL; pcb->rtime = -1; 802dcf6: 86a3 strh r3, [r4, #52] ; 0x34 pcb->tos = 0; pcb->ttl = TCP_TTL; /* As initial send MSS, we use TCP_MSS but limit it to 536. The send MSS is updated when an MSS option is received. */ pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS; pcb->rto = 3000 / TCP_SLOW_INTERVAL; 802dcf8: 2206 movs r2, #6 pcb->sa = 0; pcb->sv = 3000 / TCP_SLOW_INTERVAL; pcb->rtime = -1; pcb->cwnd = 1; 802dcfa: 2301 movs r3, #1 802dcfc: f8a4 304c strh.w r3, [r4, #76] ; 0x4c pcb->tos = 0; pcb->ttl = TCP_TTL; /* As initial send MSS, we use TCP_MSS but limit it to 536. The send MSS is updated when an MSS option is received. */ pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS; pcb->rto = 3000 / TCP_SLOW_INTERVAL; 802dd00: f8a4 2044 strh.w r2, [r4, #68] ; 0x44 pcb->sa = 0; pcb->sv = 3000 / TCP_SLOW_INTERVAL; 802dd04: f8a4 2042 strh.w r2, [r4, #66] ; 0x42 pcb->rtime = -1; pcb->cwnd = 1; iss = tcp_next_iss(); 802dd08: f7ff ff8e bl 802dc28 pcb->snd_wl2 = iss; pcb->snd_nxt = iss; pcb->lastack = iss; pcb->snd_lbb = iss; pcb->tmr = tcp_ticks; 802dd0c: 4b0b ldr r3, [pc, #44] ; (802dd3c ) pcb->sa = 0; pcb->sv = 3000 / TCP_SLOW_INTERVAL; pcb->rtime = -1; pcb->cwnd = 1; iss = tcp_next_iss(); pcb->snd_wl2 = iss; 802dd0e: 65a0 str r0, [r4, #88] ; 0x58 pcb->snd_nxt = iss; pcb->lastack = iss; pcb->snd_lbb = iss; pcb->tmr = tcp_ticks; 802dd10: 681b ldr r3, [r3, #0] pcb->sv = 3000 / TCP_SLOW_INTERVAL; pcb->rtime = -1; pcb->cwnd = 1; iss = tcp_next_iss(); pcb->snd_wl2 = iss; pcb->snd_nxt = iss; 802dd12: 6520 str r0, [r4, #80] ; 0x50 pcb->lastack = iss; pcb->snd_lbb = iss; pcb->tmr = tcp_ticks; 802dd14: 6263 str r3, [r4, #36] ; 0x24 pcb->last_timer = tcp_timer_ctr; 802dd16: 4b0b ldr r3, [pc, #44] ; (802dd44 ) pcb->rtime = -1; pcb->cwnd = 1; iss = tcp_next_iss(); pcb->snd_wl2 = iss; pcb->snd_nxt = iss; pcb->lastack = iss; 802dd18: 64a0 str r0, [r4, #72] ; 0x48 pcb->snd_lbb = iss; pcb->tmr = tcp_ticks; pcb->last_timer = tcp_timer_ctr; 802dd1a: 781b ldrb r3, [r3, #0] pcb->cwnd = 1; iss = tcp_next_iss(); pcb->snd_wl2 = iss; pcb->snd_nxt = iss; pcb->lastack = iss; pcb->snd_lbb = iss; 802dd1c: 65e0 str r0, [r4, #92] ; 0x5c pcb->tmr = tcp_ticks; pcb->last_timer = tcp_timer_ctr; 802dd1e: f884 3021 strb.w r3, [r4, #33] ; 0x21 pcb->polltmr = 0; #if LWIP_CALLBACK_API pcb->recv = tcp_recv_null; 802dd22: 4b09 ldr r3, [pc, #36] ; (802dd48 ) pcb->lastack = iss; pcb->snd_lbb = iss; pcb->tmr = tcp_ticks; pcb->last_timer = tcp_timer_ctr; pcb->polltmr = 0; 802dd24: 77e5 strb r5, [r4, #31] #if LWIP_CALLBACK_API pcb->recv = tcp_recv_null; 802dd26: 67e3 str r3, [r4, #124] ; 0x7c #endif /* LWIP_CALLBACK_API */ /* Init KEEPALIVE timer */ pcb->keep_idle = TCP_KEEPIDLE_DEFAULT; 802dd28: 4b08 ldr r3, [pc, #32] ; (802dd4c ) #if LWIP_TCP_KEEPALIVE pcb->keep_intvl = TCP_KEEPINTVL_DEFAULT; pcb->keep_cnt = TCP_KEEPCNT_DEFAULT; #endif /* LWIP_TCP_KEEPALIVE */ pcb->keep_cnt_sent = 0; 802dd2a: f884 5092 strb.w r5, [r4, #146] ; 0x92 #if LWIP_CALLBACK_API pcb->recv = tcp_recv_null; #endif /* LWIP_CALLBACK_API */ /* Init KEEPALIVE timer */ pcb->keep_idle = TCP_KEEPIDLE_DEFAULT; 802dd2e: f8c4 308c str.w r3, [r4, #140] ; 0x8c #endif /* LWIP_TCP_KEEPALIVE */ pcb->keep_cnt_sent = 0; } return pcb; } 802dd32: 4620 mov r0, r4 802dd34: bdf8 pop {r3, r4, r5, r6, r7, pc} 802dd36: bf00 nop 802dd38: 20010ff0 .word 0x20010ff0 802dd3c: 20010fe0 .word 0x20010fe0 802dd40: 20010fdc .word 0x20010fdc 802dd44: 2000e0ed .word 0x2000e0ed 802dd48: 0802db09 .word 0x0802db09 802dd4c: 006ddd00 .word 0x006ddd00 0802dd50 : * @return a new tcp_pcb that initially is in state CLOSED */ struct tcp_pcb * tcp_new(void) { return tcp_alloc(TCP_PRIO_NORMAL); 802dd50: 2040 movs r0, #64 ; 0x40 802dd52: f7ff bf75 b.w 802dc40 0802dd56 : * by using ip_route to determin the netif used to send to the address and * calculating the minimum of TCP_MSS and that netif's mtu (if set). */ u16_t tcp_eff_send_mss(u16_t sendmss, ip_addr_t *addr) { 802dd56: b510 push {r4, lr} 802dd58: 4604 mov r4, r0 u16_t mss_s; struct netif *outif; outif = ip_route(addr); 802dd5a: 4608 mov r0, r1 802dd5c: f002 f8f2 bl 802ff44 if ((outif != NULL) && (outif->mtu != 0)) { 802dd60: b130 cbz r0, 802dd70 802dd62: 8c83 ldrh r3, [r0, #36] ; 0x24 802dd64: b123 cbz r3, 802dd70 mss_s = outif->mtu - IP_HLEN - TCP_HLEN; 802dd66: 3b28 subs r3, #40 ; 0x28 /* RFC 1122, chap 4.2.2.6: * Eff.snd.MSS = min(SendMSS+20, MMS_S) - TCPhdrsize - IPoptionsize * We correct for TCP options in tcp_write(), and don't support IP options. */ sendmss = LWIP_MIN(sendmss, mss_s); 802dd68: b29b uxth r3, r3 802dd6a: 429c cmp r4, r3 802dd6c: bf28 it cs 802dd6e: 461c movcs r4, r3 } return sendmss; } 802dd70: 4620 mov r0, r4 802dd72: bd10 pop {r4, pc} 0802dd74 : * * @param pcb the tcp_pcb for which a segment arrived */ static void tcp_parseopt(struct tcp_pcb *pcb) { 802dd74: b5f8 push {r3, r4, r5, r6, r7, lr} u8_t *opts, opt; #if LWIP_TCP_TIMESTAMPS u32_t tsval; #endif opts = (u8_t *)tcphdr + TCP_HLEN; 802dd76: 4d1e ldr r5, [pc, #120] ; (802ddf0 ) 802dd78: 682c ldr r4, [r5, #0] * * @param pcb the tcp_pcb for which a segment arrived */ static void tcp_parseopt(struct tcp_pcb *pcb) { 802dd7a: 4606 mov r6, r0 #endif opts = (u8_t *)tcphdr + TCP_HLEN; /* Parse the TCP MSS option, if present. */ if(TCPH_HDRLEN(tcphdr) > 0x5) { 802dd7c: 89a0 ldrh r0, [r4, #12] 802dd7e: f7fe f81e bl 802bdbe 802dd82: f3c0 300f ubfx r0, r0, #12, #16 802dd86: 2805 cmp r0, #5 802dd88: d931 bls.n 802ddee max_c = (TCPH_HDRLEN(tcphdr) - 5) << 2; 802dd8a: 682b ldr r3, [r5, #0] 802dd8c: 8998 ldrh r0, [r3, #12] 802dd8e: f7fe f816 bl 802bdbe 802dd92: 0b00 lsrs r0, r0, #12 802dd94: 1f41 subs r1, r0, #5 802dd96: 0089 lsls r1, r1, #2 u8_t *opts, opt; #if LWIP_TCP_TIMESTAMPS u32_t tsval; #endif opts = (u8_t *)tcphdr + TCP_HLEN; 802dd98: 3414 adds r4, #20 /* Parse the TCP MSS option, if present. */ if(TCPH_HDRLEN(tcphdr) > 0x5) { max_c = (TCPH_HDRLEN(tcphdr) - 5) << 2; 802dd9a: b289 uxth r1, r1 for (c = 0; c < max_c; ) { 802dd9c: 2300 movs r3, #0 return; } /* An MSS option with the right option length. */ mss = (opts[c + 2] << 8) | opts[c + 3]; /* Limit the mss to the configured TCP_MSS and prevent division by zero */ pcb->mss = ((mss > TCP_MSS) || (mss == 0)) ? TCP_MSS : mss; 802dd9e: f240 50b3 movw r0, #1459 ; 0x5b3 802dda2: f240 55b4 movw r5, #1460 ; 0x5b4 opts = (u8_t *)tcphdr + TCP_HLEN; /* Parse the TCP MSS option, if present. */ if(TCPH_HDRLEN(tcphdr) > 0x5) { max_c = (TCPH_HDRLEN(tcphdr) - 5) << 2; for (c = 0; c < max_c; ) { 802dda6: e020 b.n 802ddea opt = opts[c]; switch (opt) { 802dda8: 5ce2 ldrb r2, [r4, r3] 802ddaa: 2a01 cmp r2, #1 802ddac: d005 beq.n 802ddba 802ddae: d31e bcc.n 802ddee 802ddb0: 2a02 cmp r2, #2 802ddb2: eb04 0203 add.w r2, r4, r3 802ddb6: d114 bne.n 802dde2 802ddb8: e001 b.n 802ddbe /* End of options. */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_parseopt: EOL\n")); return; case 0x01: /* NOP option. */ ++c; 802ddba: 3301 adds r3, #1 802ddbc: e014 b.n 802dde8 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_parseopt: NOP\n")); break; case 0x02: LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_parseopt: MSS\n")); if (opts[c + 1] != 0x04 || c + 0x04 > max_c) { 802ddbe: 7857 ldrb r7, [r2, #1] 802ddc0: 2f04 cmp r7, #4 802ddc2: d114 bne.n 802ddee 802ddc4: 1cdf adds r7, r3, #3 802ddc6: 428f cmp r7, r1 802ddc8: da11 bge.n 802ddee /* Bad length */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_parseopt: bad length\n")); return; } /* An MSS option with the right option length. */ mss = (opts[c + 2] << 8) | opts[c + 3]; 802ddca: 7897 ldrb r7, [r2, #2] 802ddcc: 78d2 ldrb r2, [r2, #3] 802ddce: ea42 2207 orr.w r2, r2, r7, lsl #8 /* Limit the mss to the configured TCP_MSS and prevent division by zero */ pcb->mss = ((mss > TCP_MSS) || (mss == 0)) ? TCP_MSS : mss; 802ddd2: 1e57 subs r7, r2, #1 802ddd4: b2bf uxth r7, r7 802ddd6: 4287 cmp r7, r0 802ddd8: bf88 it hi 802ddda: 462a movhi r2, r5 802dddc: 86f2 strh r2, [r6, #54] ; 0x36 /* Advance to next option */ c += 0x04; 802ddde: 3304 adds r3, #4 802dde0: e002 b.n 802dde8 c += 0x0A; break; #endif default: LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_parseopt: other\n")); if (opts[c + 1] == 0) { 802dde2: 7852 ldrb r2, [r2, #1] 802dde4: b11a cbz r2, 802ddee and we don't process them further. */ return; } /* All other options have a length field, so that we easily can skip past them. */ c += opts[c + 1]; 802dde6: 18d3 adds r3, r2, r3 802dde8: b29b uxth r3, r3 opts = (u8_t *)tcphdr + TCP_HLEN; /* Parse the TCP MSS option, if present. */ if(TCPH_HDRLEN(tcphdr) > 0x5) { max_c = (TCPH_HDRLEN(tcphdr) - 5) << 2; for (c = 0; c < max_c; ) { 802ddea: 428b cmp r3, r1 802ddec: d3dc bcc.n 802dda8 802ddee: bdf8 pop {r3, r4, r5, r6, r7, pc} 802ddf0: 2000e0f0 .word 0x2000e0f0 0802ddf4 : * * Called from tcp_process(). */ static void tcp_receive(struct tcp_pcb *pcb) { 802ddf4: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} u16_t ooseq_qlen; #endif /* TCP_OOSEQ_MAX_BYTES || TCP_OOSEQ_MAX_PBUFS */ LWIP_ASSERT("tcp_receive: wrong state", pcb->state >= ESTABLISHED); if (flags & TCP_ACK) { 802ddf8: 4ba0 ldr r3, [pc, #640] ; (802e07c ) 802ddfa: 781b ldrb r3, [r3, #0] 802ddfc: f003 0310 and.w r3, r3, #16 802de00: b2db uxtb r3, r3 * * Called from tcp_process(). */ static void tcp_receive(struct tcp_pcb *pcb) { 802de02: 4604 mov r4, r0 u16_t ooseq_qlen; #endif /* TCP_OOSEQ_MAX_BYTES || TCP_OOSEQ_MAX_PBUFS */ LWIP_ASSERT("tcp_receive: wrong state", pcb->state >= ESTABLISHED); if (flags & TCP_ACK) { 802de04: 2b00 cmp r3, #0 802de06: f000 816b beq.w 802e0e0 right_wnd_edge = pcb->snd_wnd + pcb->snd_wl2; /* Update window. */ if (TCP_SEQ_LT(pcb->snd_wl1, seqno) || 802de0a: 4a9d ldr r2, [pc, #628] ; (802e080 ) 802de0c: 6d43 ldr r3, [r0, #84] ; 0x54 802de0e: 6812 ldr r2, [r2, #0] #endif /* TCP_OOSEQ_MAX_BYTES || TCP_OOSEQ_MAX_PBUFS */ LWIP_ASSERT("tcp_receive: wrong state", pcb->state >= ESTABLISHED); if (flags & TCP_ACK) { right_wnd_edge = pcb->snd_wnd + pcb->snd_wl2; 802de10: f8b0 5060 ldrh.w r5, [r0, #96] ; 0x60 802de14: 6d81 ldr r1, [r0, #88] ; 0x58 /* Update window. */ if (TCP_SEQ_LT(pcb->snd_wl1, seqno) || 802de16: 1a98 subs r0, r3, r2 802de18: 2800 cmp r0, #0 802de1a: db0e blt.n 802de3a 802de1c: 4293 cmp r3, r2 802de1e: 4b99 ldr r3, [pc, #612] ; (802e084 ) 802de20: d103 bne.n 802de2a (pcb->snd_wl1 == seqno && TCP_SEQ_LT(pcb->snd_wl2, ackno)) || 802de22: 6818 ldr r0, [r3, #0] 802de24: 1a08 subs r0, r1, r0 802de26: 2800 cmp r0, #0 802de28: db07 blt.n 802de3a 802de2a: 681b ldr r3, [r3, #0] 802de2c: 4299 cmp r1, r3 802de2e: d11f bne.n 802de70 (pcb->snd_wl2 == ackno && tcphdr->wnd > pcb->snd_wnd)) { 802de30: 4b95 ldr r3, [pc, #596] ; (802e088 ) 802de32: 681b ldr r3, [r3, #0] 802de34: 89db ldrh r3, [r3, #14] 802de36: 42ab cmp r3, r5 802de38: d91a bls.n 802de70 pcb->snd_wnd = tcphdr->wnd; 802de3a: 4b93 ldr r3, [pc, #588] ; (802e088 ) /* keep track of the biggest window announced by the remote host to calculate the maximum segment size */ if (pcb->snd_wnd_max < tcphdr->wnd) { 802de3c: f8b4 6062 ldrh.w r6, [r4, #98] ; 0x62 /* Update window. */ if (TCP_SEQ_LT(pcb->snd_wl1, seqno) || (pcb->snd_wl1 == seqno && TCP_SEQ_LT(pcb->snd_wl2, ackno)) || (pcb->snd_wl2 == ackno && tcphdr->wnd > pcb->snd_wnd)) { pcb->snd_wnd = tcphdr->wnd; 802de40: 681b ldr r3, [r3, #0] 802de42: 89d8 ldrh r0, [r3, #14] /* keep track of the biggest window announced by the remote host to calculate the maximum segment size */ if (pcb->snd_wnd_max < tcphdr->wnd) { pcb->snd_wnd_max = tcphdr->wnd; } pcb->snd_wl1 = seqno; 802de44: 6562 str r2, [r4, #84] ; 0x54 pcb->snd_wl2 = ackno; 802de46: 4a8f ldr r2, [pc, #572] ; (802e084 ) /* Update window. */ if (TCP_SEQ_LT(pcb->snd_wl1, seqno) || (pcb->snd_wl1 == seqno && TCP_SEQ_LT(pcb->snd_wl2, ackno)) || (pcb->snd_wl2 == ackno && tcphdr->wnd > pcb->snd_wnd)) { pcb->snd_wnd = tcphdr->wnd; 802de48: f8a4 0060 strh.w r0, [r4, #96] ; 0x60 the maximum segment size */ if (pcb->snd_wnd_max < tcphdr->wnd) { pcb->snd_wnd_max = tcphdr->wnd; } pcb->snd_wl1 = seqno; pcb->snd_wl2 = ackno; 802de4c: 6812 ldr r2, [r2, #0] (pcb->snd_wl1 == seqno && TCP_SEQ_LT(pcb->snd_wl2, ackno)) || (pcb->snd_wl2 == ackno && tcphdr->wnd > pcb->snd_wnd)) { pcb->snd_wnd = tcphdr->wnd; /* keep track of the biggest window announced by the remote host to calculate the maximum segment size */ if (pcb->snd_wnd_max < tcphdr->wnd) { 802de4e: 4286 cmp r6, r0 pcb->snd_wnd_max = tcphdr->wnd; } pcb->snd_wl1 = seqno; pcb->snd_wl2 = ackno; 802de50: 65a2 str r2, [r4, #88] ; 0x58 (pcb->snd_wl2 == ackno && tcphdr->wnd > pcb->snd_wnd)) { pcb->snd_wnd = tcphdr->wnd; /* keep track of the biggest window announced by the remote host to calculate the maximum segment size */ if (pcb->snd_wnd_max < tcphdr->wnd) { pcb->snd_wnd_max = tcphdr->wnd; 802de52: bf38 it cc 802de54: f8a4 0062 strhcc.w r0, [r4, #98] ; 0x62 802de58: f894 2091 ldrb.w r2, [r4, #145] ; 0x91 } pcb->snd_wl1 = seqno; pcb->snd_wl2 = ackno; if (pcb->snd_wnd == 0) { 802de5c: b920 cbnz r0, 802de68 if (pcb->persist_backoff == 0) { 802de5e: b93a cbnz r2, 802de70 /* start persist timer */ pcb->persist_cnt = 0; 802de60: f884 0090 strb.w r0, [r4, #144] ; 0x90 pcb->persist_backoff = 1; 802de64: 2301 movs r3, #1 802de66: e001 b.n 802de6c } } else if (pcb->persist_backoff > 0) { 802de68: b112 cbz r2, 802de70 /* stop persist timer */ pcb->persist_backoff = 0; 802de6a: 2300 movs r3, #0 802de6c: f884 3091 strb.w r3, [r4, #145] ; 0x91 * If it only passes 1, should reset dupack counter * */ /* Clause 1 */ if (TCP_SEQ_LEQ(ackno, pcb->lastack)) { 802de70: 4b84 ldr r3, [pc, #528] ; (802e084 ) 802de72: 6ca2 ldr r2, [r4, #72] ; 0x48 802de74: 681b ldr r3, [r3, #0] 802de76: 1a98 subs r0, r3, r2 802de78: 2800 cmp r0, #0 802de7a: dc34 bgt.n 802dee6 pcb->acked = 0; 802de7c: 2000 movs r0, #0 802de7e: f8a4 0064 strh.w r0, [r4, #100] ; 0x64 /* Clause 2 */ if (tcplen == 0) { 802de82: 4882 ldr r0, [pc, #520] ; (802e08c ) 802de84: 8800 ldrh r0, [r0, #0] 802de86: 2800 cmp r0, #0 802de88: f040 81f4 bne.w 802e274 /* Clause 3 */ if (pcb->snd_wl2 + pcb->snd_wnd == right_wnd_edge){ 802de8c: f8b4 6060 ldrh.w r6, [r4, #96] ; 0x60 802de90: 6da0 ldr r0, [r4, #88] ; 0x58 #endif /* TCP_OOSEQ_MAX_BYTES || TCP_OOSEQ_MAX_PBUFS */ LWIP_ASSERT("tcp_receive: wrong state", pcb->state >= ESTABLISHED); if (flags & TCP_ACK) { right_wnd_edge = pcb->snd_wnd + pcb->snd_wl2; 802de92: 1869 adds r1, r5, r1 if (TCP_SEQ_LEQ(ackno, pcb->lastack)) { pcb->acked = 0; /* Clause 2 */ if (tcplen == 0) { /* Clause 3 */ if (pcb->snd_wl2 + pcb->snd_wnd == right_wnd_edge){ 802de94: 1830 adds r0, r6, r0 802de96: 4288 cmp r0, r1 802de98: f040 81ec bne.w 802e274 /* Clause 4 */ if (pcb->rtime >= 0) { 802de9c: f9b4 1034 ldrsh.w r1, [r4, #52] ; 0x34 802dea0: 2900 cmp r1, #0 802dea2: f2c0 81e7 blt.w 802e274 /* Clause 5 */ if (pcb->lastack == ackno) { 802dea6: 429a cmp r2, r3 802dea8: f040 81e4 bne.w 802e274 found_dupack = 1; if ((u8_t)(pcb->dupacks + 1) > pcb->dupacks) { 802deac: f894 2047 ldrb.w r2, [r4, #71] ; 0x47 802deb0: 1c53 adds r3, r2, #1 802deb2: b2db uxtb r3, r3 802deb4: 4293 cmp r3, r2 ++pcb->dupacks; 802deb6: bf88 it hi 802deb8: f884 3047 strbhi.w r3, [r4, #71] ; 0x47 } if (pcb->dupacks > 3) { 802debc: f894 3047 ldrb.w r3, [r4, #71] ; 0x47 802dec0: 2b03 cmp r3, #3 802dec2: d90a bls.n 802deda /* Inflate the congestion window, but not if it means that the value overflows. */ if ((u16_t)(pcb->cwnd + pcb->mss) > pcb->cwnd) { 802dec4: f8b4 204c ldrh.w r2, [r4, #76] ; 0x4c 802dec8: 8ee3 ldrh r3, [r4, #54] ; 0x36 802deca: 18d3 adds r3, r2, r3 802decc: b29b uxth r3, r3 802dece: 4293 cmp r3, r2 802ded0: f240 80b2 bls.w 802e038 pcb->cwnd += pcb->mss; 802ded4: f8a4 304c strh.w r3, [r4, #76] ; 0x4c 802ded8: e0ae b.n 802e038 } } else if (pcb->dupacks == 3) { 802deda: f040 80ad bne.w 802e038 /* Do fast retransmit */ tcp_rexmit_fast(pcb); 802dede: 4620 mov r0, r4 802dee0: f001 fa92 bl 802f408 802dee4: e0a8 b.n 802e038 /* If Clause (1) or more is true, but not a duplicate ack, reset * count of consecutive duplicate acks */ if (!found_dupack) { pcb->dupacks = 0; } } else if (TCP_SEQ_BETWEEN(ackno, pcb->lastack+1, pcb->snd_nxt)){ 802dee6: 43d1 mvns r1, r2 802dee8: 42d9 cmn r1, r3 802deea: d47e bmi.n 802dfea 802deec: 6d21 ldr r1, [r4, #80] ; 0x50 802deee: 1a59 subs r1, r3, r1 802def0: 2900 cmp r1, #0 802def2: dc7a bgt.n 802dfea /* We come here when the ACK acknowledges new data. */ /* Reset the "IN Fast Retransmit" flag, since we are no longer in fast retransmit. Also reset the congestion window to the slow start threshold. */ if (pcb->flags & TF_INFR) { 802def4: 7fa1 ldrb r1, [r4, #30] 802def6: f001 0004 and.w r0, r1, #4 802defa: b2c0 uxtb r0, r0 802defc: b130 cbz r0, 802df0c pcb->flags &= ~TF_INFR; 802defe: f021 0104 bic.w r1, r1, #4 802df02: 77a1 strb r1, [r4, #30] pcb->cwnd = pcb->ssthresh; 802df04: f8b4 104e ldrh.w r1, [r4, #78] ; 0x4e 802df08: f8a4 104c strh.w r1, [r4, #76] ; 0x4c /* Reset the number of retransmissions. */ pcb->nrtx = 0; /* Reset the retransmission time-out. */ pcb->rto = (pcb->sa >> 3) + pcb->sv; 802df0c: f9b4 5040 ldrsh.w r5, [r4, #64] ; 0x40 802df10: f8b4 0042 ldrh.w r0, [r4, #66] ; 0x42 pcb->snd_buf += pcb->acked; /* Reset the fast retransmit variables. */ pcb->dupacks = 0; pcb->lastack = ackno; 802df14: 64a3 str r3, [r4, #72] ; 0x48 /* Reset the number of retransmissions. */ pcb->nrtx = 0; /* Reset the retransmission time-out. */ pcb->rto = (pcb->sa >> 3) + pcb->sv; 802df16: eb00 00e5 add.w r0, r0, r5, asr #3 /* Update the send buffer space. Diff between the two can never exceed 64K? */ pcb->acked = (u16_t)(ackno - pcb->lastack); 802df1a: 1a9a subs r2, r3, r2 /* Reset the number of retransmissions. */ pcb->nrtx = 0; /* Reset the retransmission time-out. */ pcb->rto = (pcb->sa >> 3) + pcb->sv; 802df1c: f8a4 0044 strh.w r0, [r4, #68] ; 0x44 pcb->dupacks = 0; pcb->lastack = ackno; /* Update the congestion control variables (cwnd and ssthresh). */ if (pcb->state >= ESTABLISHED) { 802df20: 7e23 ldrb r3, [r4, #24] pcb->rto = (pcb->sa >> 3) + pcb->sv; /* Update the send buffer space. Diff between the two can never exceed 64K? */ pcb->acked = (u16_t)(ackno - pcb->lastack); pcb->snd_buf += pcb->acked; 802df22: f8b4 0066 ldrh.w r0, [r4, #102] ; 0x66 /* Reset the retransmission time-out. */ pcb->rto = (pcb->sa >> 3) + pcb->sv; /* Update the send buffer space. Diff between the two can never exceed 64K? */ pcb->acked = (u16_t)(ackno - pcb->lastack); 802df26: f8a4 2064 strh.w r2, [r4, #100] ; 0x64 pcb->flags &= ~TF_INFR; pcb->cwnd = pcb->ssthresh; } /* Reset the number of retransmissions. */ pcb->nrtx = 0; 802df2a: 2100 movs r1, #0 pcb->rto = (pcb->sa >> 3) + pcb->sv; /* Update the send buffer space. Diff between the two can never exceed 64K? */ pcb->acked = (u16_t)(ackno - pcb->lastack); pcb->snd_buf += pcb->acked; 802df2c: 1812 adds r2, r2, r0 pcb->dupacks = 0; pcb->lastack = ackno; /* Update the congestion control variables (cwnd and ssthresh). */ if (pcb->state >= ESTABLISHED) { 802df2e: 2b03 cmp r3, #3 pcb->flags &= ~TF_INFR; pcb->cwnd = pcb->ssthresh; } /* Reset the number of retransmissions. */ pcb->nrtx = 0; 802df30: f884 1046 strb.w r1, [r4, #70] ; 0x46 pcb->rto = (pcb->sa >> 3) + pcb->sv; /* Update the send buffer space. Diff between the two can never exceed 64K? */ pcb->acked = (u16_t)(ackno - pcb->lastack); pcb->snd_buf += pcb->acked; 802df34: f8a4 2066 strh.w r2, [r4, #102] ; 0x66 /* Reset the fast retransmit variables. */ pcb->dupacks = 0; 802df38: f884 1047 strb.w r1, [r4, #71] ; 0x47 pcb->lastack = ackno; /* Update the congestion control variables (cwnd and ssthresh). */ if (pcb->state >= ESTABLISHED) { 802df3c: d931 bls.n 802dfa2 if (pcb->cwnd < pcb->ssthresh) { 802df3e: f8b4 204e ldrh.w r2, [r4, #78] ; 0x4e 802df42: f8b4 304c ldrh.w r3, [r4, #76] ; 0x4c 802df46: 429a cmp r2, r3 if ((u16_t)(pcb->cwnd + pcb->mss) > pcb->cwnd) { 802df48: 8ee2 ldrh r2, [r4, #54] ; 0x36 pcb->lastack = ackno; /* Update the congestion control variables (cwnd and ssthresh). */ if (pcb->state >= ESTABLISHED) { if (pcb->cwnd < pcb->ssthresh) { 802df4a: d900 bls.n 802df4e 802df4c: e002 b.n 802df54 if ((u16_t)(pcb->cwnd + pcb->mss) > pcb->cwnd) { pcb->cwnd += pcb->mss; } LWIP_DEBUGF(TCP_CWND_DEBUG, ("tcp_receive: slow start cwnd %"U16_F"\n", pcb->cwnd)); } else { u16_t new_cwnd = (pcb->cwnd + pcb->mss * pcb->mss / pcb->cwnd); 802df4e: 4352 muls r2, r2 802df50: fb92 f2f3 sdiv r2, r2, r3 802df54: 189a adds r2, r3, r2 802df56: b292 uxth r2, r2 if (new_cwnd > pcb->cwnd) { 802df58: 429a cmp r2, r3 802df5a: d922 bls.n 802dfa2 pcb->cwnd = new_cwnd; 802df5c: f8a4 204c strh.w r2, [r4, #76] ; 0x4c 802df60: e01f b.n 802dfa2 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_receive: removing %"U32_F":%"U32_F" from pcb->unacked\n", ntohl(pcb->unacked->tcphdr->seqno), ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked))); next = pcb->unacked; 802df62: 6f25 ldr r5, [r4, #112] ; 0x70 pcb->unacked = pcb->unacked->next; 802df64: 682b ldr r3, [r5, #0] LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_receive: queuelen %"U16_F" ... ", (u16_t)pcb->snd_queuelen)); LWIP_ASSERT("pcb->snd_queuelen >= pbuf_clen(next->p)", (pcb->snd_queuelen >= pbuf_clen(next->p))); 802df66: 6868 ldr r0, [r5, #4] ntohl(pcb->unacked->tcphdr->seqno), ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked))); next = pcb->unacked; pcb->unacked = pcb->unacked->next; 802df68: 6723 str r3, [r4, #112] ; 0x70 LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_receive: queuelen %"U16_F" ... ", (u16_t)pcb->snd_queuelen)); LWIP_ASSERT("pcb->snd_queuelen >= pbuf_clen(next->p)", (pcb->snd_queuelen >= pbuf_clen(next->p))); 802df6a: f7ff f935 bl 802d1d8 /* Prevent ACK for FIN to generate a sent event */ if ((pcb->acked != 0) && ((TCPH_FLAGS(next->tcphdr) & TCP_FIN) != 0)) { 802df6e: f8b4 3064 ldrh.w r3, [r4, #100] ; 0x64 802df72: b153 cbz r3, 802df8a 802df74: 68eb ldr r3, [r5, #12] 802df76: 8998 ldrh r0, [r3, #12] 802df78: f7fd ff21 bl 802bdbe 802df7c: 07c3 lsls r3, r0, #31 802df7e: d504 bpl.n 802df8a pcb->acked--; 802df80: f8b4 3064 ldrh.w r3, [r4, #100] ; 0x64 802df84: 3b01 subs r3, #1 802df86: f8a4 3064 strh.w r3, [r4, #100] ; 0x64 } pcb->snd_queuelen -= pbuf_clen(next->p); 802df8a: 6868 ldr r0, [r5, #4] 802df8c: f8b4 7068 ldrh.w r7, [r4, #104] ; 0x68 802df90: f7ff f922 bl 802d1d8 802df94: 1a38 subs r0, r7, r0 802df96: f8a4 0068 strh.w r0, [r4, #104] ; 0x68 tcp_seg_free(next); 802df9a: 4628 mov r0, r5 802df9c: f7ff faf5 bl 802d58a 802dfa0: e000 b.n 802dfa4 ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked): 0)); /* Remove segment from the unacknowledged list if the incoming ACK acknowlegdes them. */ while (pcb->unacked != NULL && TCP_SEQ_LEQ(ntohl(pcb->unacked->tcphdr->seqno) + 802dfa2: 4e38 ldr r6, [pc, #224] ; (802e084 ) pcb->unacked != NULL? ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked): 0)); /* Remove segment from the unacknowledged list if the incoming ACK acknowlegdes them. */ while (pcb->unacked != NULL && 802dfa4: 6f23 ldr r3, [r4, #112] ; 0x70 802dfa6: b91b cbnz r3, 802dfb0 } } /* If there's nothing left to acknowledge, stop the retransmit timer, otherwise reset it to start again */ if(pcb->unacked == NULL) 802dfa8: 6f22 ldr r2, [r4, #112] ; 0x70 802dfaa: 2300 movs r3, #0 802dfac: b9d2 cbnz r2, 802dfe4 802dfae: e015 b.n 802dfdc ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked): 0)); /* Remove segment from the unacknowledged list if the incoming ACK acknowlegdes them. */ while (pcb->unacked != NULL && TCP_SEQ_LEQ(ntohl(pcb->unacked->tcphdr->seqno) + 802dfb0: 68db ldr r3, [r3, #12] 802dfb2: 6858 ldr r0, [r3, #4] 802dfb4: f7fd ff0a bl 802bdcc 802dfb8: 6f23 ldr r3, [r4, #112] ; 0x70 802dfba: 891d ldrh r5, [r3, #8] 802dfbc: 68db ldr r3, [r3, #12] 802dfbe: 4607 mov r7, r0 802dfc0: 8998 ldrh r0, [r3, #12] 802dfc2: f7fd fefc bl 802bdbe 802dfc6: 6833 ldr r3, [r6, #0] 802dfc8: f010 0003 ands.w r0, r0, #3 802dfcc: bf18 it ne 802dfce: 2001 movne r0, #1 802dfd0: 1afb subs r3, r7, r3 802dfd2: 1828 adds r0, r5, r0 802dfd4: 181b adds r3, r3, r0 pcb->unacked != NULL? ntohl(pcb->unacked->tcphdr->seqno) + TCP_TCPLEN(pcb->unacked): 0)); /* Remove segment from the unacknowledged list if the incoming ACK acknowlegdes them. */ while (pcb->unacked != NULL && 802dfd6: 2b00 cmp r3, #0 802dfd8: ddc3 ble.n 802df62 802dfda: e7e5 b.n 802dfa8 } /* If there's nothing left to acknowledge, stop the retransmit timer, otherwise reset it to start again */ if(pcb->unacked == NULL) pcb->rtime = -1; 802dfdc: f64f 72ff movw r2, #65535 ; 0xffff 802dfe0: 86a2 strh r2, [r4, #52] ; 0x34 802dfe2: e000 b.n 802dfe6 else pcb->rtime = 0; 802dfe4: 86a3 strh r3, [r4, #52] ; 0x34 pcb->polltmr = 0; 802dfe6: 77e3 strb r3, [r4, #31] 802dfe8: e026 b.n 802e038 } else { /* Fix bug bug #21582: out of sequence ACK, didn't really ack anything */ pcb->acked = 0; 802dfea: 2300 movs r3, #0 802dfec: f8a4 3064 strh.w r3, [r4, #100] ; 0x64 802dff0: e022 b.n 802e038 TCP_TCPLEN(pcb->unsent), pcb->snd_nxt)) { LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_receive: removing %"U32_F":%"U32_F" from pcb->unsent\n", ntohl(pcb->unsent->tcphdr->seqno), ntohl(pcb->unsent->tcphdr->seqno) + TCP_TCPLEN(pcb->unsent))); next = pcb->unsent; 802dff2: 6ee5 ldr r5, [r4, #108] ; 0x6c pcb->unsent = pcb->unsent->next; 802dff4: 682b ldr r3, [r5, #0] 802dff6: 66e3 str r3, [r4, #108] ; 0x6c #if TCP_OVERSIZE if (pcb->unsent == NULL) { 802dff8: b90b cbnz r3, 802dffe pcb->unsent_oversize = 0; 802dffa: f8a4 306a strh.w r3, [r4, #106] ; 0x6a } #endif /* TCP_OVERSIZE */ LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_receive: queuelen %"U16_F" ... ", (u16_t)pcb->snd_queuelen)); LWIP_ASSERT("pcb->snd_queuelen >= pbuf_clen(next->p)", (pcb->snd_queuelen >= pbuf_clen(next->p))); 802dffe: 6868 ldr r0, [r5, #4] 802e000: f7ff f8ea bl 802d1d8 /* Prevent ACK for FIN to generate a sent event */ if ((pcb->acked != 0) && ((TCPH_FLAGS(next->tcphdr) & TCP_FIN) != 0)) { 802e004: f8b4 3064 ldrh.w r3, [r4, #100] ; 0x64 802e008: b153 cbz r3, 802e020 802e00a: 68eb ldr r3, [r5, #12] 802e00c: 8998 ldrh r0, [r3, #12] 802e00e: f7fd fed6 bl 802bdbe 802e012: 07c7 lsls r7, r0, #31 802e014: d504 bpl.n 802e020 pcb->acked--; 802e016: f8b4 3064 ldrh.w r3, [r4, #100] ; 0x64 802e01a: 3b01 subs r3, #1 802e01c: f8a4 3064 strh.w r3, [r4, #100] ; 0x64 } pcb->snd_queuelen -= pbuf_clen(next->p); 802e020: 6868 ldr r0, [r5, #4] 802e022: f8b4 7068 ldrh.w r7, [r4, #104] ; 0x68 802e026: f7ff f8d7 bl 802d1d8 802e02a: 1a38 subs r0, r7, r0 802e02c: f8a4 0068 strh.w r0, [r4, #104] ; 0x68 tcp_seg_free(next); 802e030: 4628 mov r0, r5 802e032: f7ff faaa bl 802d58a 802e036: e000 b.n 802e03a strange since an "unsent" segment shouldn't be acked. The rationale is that lwIP puts all outstanding segments on the ->unsent list after a retransmission, so these segments may in fact have been sent once. */ while (pcb->unsent != NULL && TCP_SEQ_BETWEEN(ackno, ntohl(pcb->unsent->tcphdr->seqno) + 802e038: 4e12 ldr r6, [pc, #72] ; (802e084 ) on the list are acknowledged by the ACK. This may seem strange since an "unsent" segment shouldn't be acked. The rationale is that lwIP puts all outstanding segments on the ->unsent list after a retransmission, so these segments may in fact have been sent once. */ while (pcb->unsent != NULL && 802e03a: 6ee3 ldr r3, [r4, #108] ; 0x6c 802e03c: b913 cbnz r3, 802e044 pcb->rttest, pcb->rtseq, ackno)); /* RTT estimation calculations. This is done by checking if the incoming segment acknowledges the segment we use to take a round-trip time measurement. */ if (pcb->rttest && TCP_SEQ_LT(pcb->rtseq, ackno)) { 802e03e: 6ba3 ldr r3, [r4, #56] ; 0x38 802e040: bb33 cbnz r3, 802e090 802e042: e04d b.n 802e0e0 strange since an "unsent" segment shouldn't be acked. The rationale is that lwIP puts all outstanding segments on the ->unsent list after a retransmission, so these segments may in fact have been sent once. */ while (pcb->unsent != NULL && TCP_SEQ_BETWEEN(ackno, ntohl(pcb->unsent->tcphdr->seqno) + 802e044: 68db ldr r3, [r3, #12] 802e046: 6835 ldr r5, [r6, #0] 802e048: 6858 ldr r0, [r3, #4] 802e04a: f7fd febf bl 802bdcc 802e04e: 6ee3 ldr r3, [r4, #108] ; 0x6c 802e050: 891f ldrh r7, [r3, #8] 802e052: 68db ldr r3, [r3, #12] 802e054: 4680 mov r8, r0 802e056: 8998 ldrh r0, [r3, #12] 802e058: f7fd feb1 bl 802bdbe 802e05c: f010 0003 ands.w r0, r0, #3 802e060: bf18 it ne 802e062: 2001 movne r0, #1 802e064: ebc8 0505 rsb r5, r8, r5 802e068: 1838 adds r0, r7, r0 802e06a: 1a2d subs r5, r5, r0 on the list are acknowledged by the ACK. This may seem strange since an "unsent" segment shouldn't be acked. The rationale is that lwIP puts all outstanding segments on the ->unsent list after a retransmission, so these segments may in fact have been sent once. */ while (pcb->unsent != NULL && 802e06c: 2d00 cmp r5, #0 802e06e: dbe6 blt.n 802e03e TCP_SEQ_BETWEEN(ackno, ntohl(pcb->unsent->tcphdr->seqno) + 802e070: 6832 ldr r2, [r6, #0] 802e072: 6d23 ldr r3, [r4, #80] ; 0x50 802e074: 1ad3 subs r3, r2, r3 802e076: 2b00 cmp r3, #0 802e078: ddbb ble.n 802dff2 802e07a: e7e0 b.n 802e03e 802e07c: 2000e100 .word 0x2000e100 802e080: 2000e0f4 .word 0x2000e0f4 802e084: 2000e0fc .word 0x2000e0fc 802e088: 2000e0f0 .word 0x2000e0f0 802e08c: 2000e0f8 .word 0x2000e0f8 pcb->rttest, pcb->rtseq, ackno)); /* RTT estimation calculations. This is done by checking if the incoming segment acknowledges the segment we use to take a round-trip time measurement. */ if (pcb->rttest && TCP_SEQ_LT(pcb->rtseq, ackno)) { 802e090: 497b ldr r1, [pc, #492] ; (802e280 ) 802e092: 6be2 ldr r2, [r4, #60] ; 0x3c 802e094: 6809 ldr r1, [r1, #0] 802e096: 1a52 subs r2, r2, r1 802e098: 2a00 cmp r2, #0 802e09a: da21 bge.n 802e0e0 /* diff between this shouldn't exceed 32K since this are tcp timer ticks and a round-trip shouldn't be that long... */ m = (s16_t)(tcp_ticks - pcb->rttest); 802e09c: 4a79 ldr r2, [pc, #484] ; (802e284 ) LWIP_DEBUGF(TCP_RTO_DEBUG, ("tcp_receive: experienced rtt %"U16_F" ticks (%"U16_F" msec).\n", m, m * TCP_SLOW_INTERVAL)); /* This is taken directly from VJs original code in his paper */ m = m - (pcb->sa >> 3); 802e09e: f8b4 1040 ldrh.w r1, [r4, #64] ; 0x40 incoming segment acknowledges the segment we use to take a round-trip time measurement. */ if (pcb->rttest && TCP_SEQ_LT(pcb->rtseq, ackno)) { /* diff between this shouldn't exceed 32K since this are tcp timer ticks and a round-trip shouldn't be that long... */ m = (s16_t)(tcp_ticks - pcb->rttest); 802e0a2: 6812 ldr r2, [r2, #0] LWIP_DEBUGF(TCP_RTO_DEBUG, ("tcp_receive: experienced rtt %"U16_F" ticks (%"U16_F" msec).\n", m, m * TCP_SLOW_INTERVAL)); /* This is taken directly from VJs original code in his paper */ m = m - (pcb->sa >> 3); 802e0a4: f341 00cc sbfx r0, r1, #3, #13 incoming segment acknowledges the segment we use to take a round-trip time measurement. */ if (pcb->rttest && TCP_SEQ_LT(pcb->rtseq, ackno)) { /* diff between this shouldn't exceed 32K since this are tcp timer ticks and a round-trip shouldn't be that long... */ m = (s16_t)(tcp_ticks - pcb->rttest); 802e0a8: 1ad2 subs r2, r2, r3 LWIP_DEBUGF(TCP_RTO_DEBUG, ("tcp_receive: experienced rtt %"U16_F" ticks (%"U16_F" msec).\n", m, m * TCP_SLOW_INTERVAL)); /* This is taken directly from VJs original code in his paper */ m = m - (pcb->sa >> 3); 802e0aa: 1a12 subs r2, r2, r0 802e0ac: b292 uxth r2, r2 802e0ae: b293 uxth r3, r2 pcb->sa += m; 802e0b0: 1851 adds r1, r2, r1 802e0b2: b289 uxth r1, r1 if (m < 0) { 802e0b4: 0418 lsls r0, r3, #16 LWIP_DEBUGF(TCP_RTO_DEBUG, ("tcp_receive: experienced rtt %"U16_F" ticks (%"U16_F" msec).\n", m, m * TCP_SLOW_INTERVAL)); /* This is taken directly from VJs original code in his paper */ m = m - (pcb->sa >> 3); pcb->sa += m; 802e0b6: f8a4 1040 strh.w r1, [r4, #64] ; 0x40 if (m < 0) { 802e0ba: d501 bpl.n 802e0c0 m = -m; 802e0bc: 4253 negs r3, r2 802e0be: b29b uxth r3, r3 } m = m - (pcb->sv >> 2); 802e0c0: f8b4 2042 ldrh.w r2, [r4, #66] ; 0x42 802e0c4: f342 008d sbfx r0, r2, #2, #14 802e0c8: 1a12 subs r2, r2, r0 pcb->sv += m; 802e0ca: 18d3 adds r3, r2, r3 802e0cc: b29b uxth r3, r3 pcb->rto = (pcb->sa >> 3) + pcb->sv; 802e0ce: f341 01cc sbfx r1, r1, #3, #13 pcb->sa += m; if (m < 0) { m = -m; } m = m - (pcb->sv >> 2); pcb->sv += m; 802e0d2: f8a4 3042 strh.w r3, [r4, #66] ; 0x42 pcb->rto = (pcb->sa >> 3) + pcb->sv; 802e0d6: 185b adds r3, r3, r1 802e0d8: f8a4 3044 strh.w r3, [r4, #68] ; 0x44 LWIP_DEBUGF(TCP_RTO_DEBUG, ("tcp_receive: RTO %"U16_F" (%"U16_F" milliseconds)\n", pcb->rto, pcb->rto * TCP_SLOW_INTERVAL)); pcb->rttest = 0; 802e0dc: 2300 movs r3, #0 802e0de: 63a3 str r3, [r4, #56] ; 0x38 /* If the incoming segment contains data, we must process it further unless the pcb already received a FIN. (RFC 793, chapeter 3.9, "SEGMENT ARRIVES" in states CLOSE-WAIT, CLOSING, LAST-ACK and TIME-WAIT: "Ignore the segment text.") */ if ((tcplen > 0) && (pcb->state < CLOSE_WAIT)) { 802e0e0: 4b69 ldr r3, [pc, #420] ; (802e288 ) 802e0e2: 4a6a ldr r2, [pc, #424] ; (802e28c ) 802e0e4: 8818 ldrh r0, [r3, #0] 802e0e6: 2800 cmp r0, #0 802e0e8: f000 80b3 beq.w 802e252 802e0ec: 7e23 ldrb r3, [r4, #24] 802e0ee: 2b06 cmp r3, #6 802e0f0: f200 80af bhi.w 802e252 this if the sequence number of the incoming segment is less than rcv_nxt, and the sequence number plus the length of the segment is larger than rcv_nxt. */ /* if (TCP_SEQ_LT(seqno, pcb->rcv_nxt)){ if (TCP_SEQ_LT(pcb->rcv_nxt, seqno + tcplen)) {*/ if (TCP_SEQ_BETWEEN(pcb->rcv_nxt, seqno + 1, seqno + tcplen - 1)){ 802e0f4: 6811 ldr r1, [r2, #0] 802e0f6: 6aa3 ldr r3, [r4, #40] ; 0x28 802e0f8: 43ca mvns r2, r1 802e0fa: 42da cmn r2, r3 802e0fc: d425 bmi.n 802e14a 802e0fe: 1c5a adds r2, r3, #1 802e100: 1a52 subs r2, r2, r1 802e102: 1a10 subs r0, r2, r0 802e104: 2800 cmp r0, #0 802e106: dc20 bgt.n 802e14a After we are done with adjusting the pbuf pointers we must adjust the ->data pointer in the seg and the segment length.*/ off = pcb->rcv_nxt - seqno; 802e108: 1a59 subs r1, r3, r1 p = inseg.p; 802e10a: 4b61 ldr r3, [pc, #388] ; (802e290 ) 802e10c: 6858 ldr r0, [r3, #4] LWIP_ASSERT("inseg.p != NULL", inseg.p); LWIP_ASSERT("insane offset!", (off < 0x7fff)); if (inseg.p->len < off) { 802e10e: 8943 ldrh r3, [r0, #10] 802e110: 428b cmp r3, r1 802e112: da0a bge.n 802e12a LWIP_ASSERT("pbuf too short!", (((s32_t)inseg.p->tot_len) >= off)); new_tot_len = (u16_t)(inseg.p->tot_len - off); 802e114: 8902 ldrh r2, [r0, #8] off -= p->len; /* KJM following line changed (with addition of new_tot_len var) to fix bug #9076 inseg.p->tot_len -= p->len; */ p->tot_len = new_tot_len; p->len = 0; 802e116: 2500 movs r5, #0 p = inseg.p; LWIP_ASSERT("inseg.p != NULL", inseg.p); LWIP_ASSERT("insane offset!", (off < 0x7fff)); if (inseg.p->len < off) { LWIP_ASSERT("pbuf too short!", (((s32_t)inseg.p->tot_len) >= off)); new_tot_len = (u16_t)(inseg.p->tot_len - off); 802e118: 1a52 subs r2, r2, r1 while (p->len < off) { 802e11a: e003 b.n 802e124 off -= p->len; /* KJM following line changed (with addition of new_tot_len var) to fix bug #9076 inseg.p->tot_len -= p->len; */ p->tot_len = new_tot_len; 802e11c: 8102 strh r2, [r0, #8] p->len = 0; 802e11e: 8145 strh r5, [r0, #10] p = p->next; 802e120: 6800 ldr r0, [r0, #0] LWIP_ASSERT("insane offset!", (off < 0x7fff)); if (inseg.p->len < off) { LWIP_ASSERT("pbuf too short!", (((s32_t)inseg.p->tot_len) >= off)); new_tot_len = (u16_t)(inseg.p->tot_len - off); while (p->len < off) { off -= p->len; 802e122: 1ac9 subs r1, r1, r3 LWIP_ASSERT("inseg.p != NULL", inseg.p); LWIP_ASSERT("insane offset!", (off < 0x7fff)); if (inseg.p->len < off) { LWIP_ASSERT("pbuf too short!", (((s32_t)inseg.p->tot_len) >= off)); new_tot_len = (u16_t)(inseg.p->tot_len - off); while (p->len < off) { 802e124: 8943 ldrh r3, [r0, #10] 802e126: 428b cmp r3, r1 802e128: dbf8 blt.n 802e11c if(pbuf_header(p, (s16_t)-off)) { /* Do we need to cope with this failing? Assert for now */ LWIP_ASSERT("pbuf_header failed", 0); } } else { if(pbuf_header(inseg.p, (s16_t)-off)) { 802e12a: 4249 negs r1, r1 802e12c: b209 sxth r1, r1 802e12e: f7fe ff54 bl 802cfda /* Do we need to cope with this failing? Assert for now */ LWIP_ASSERT("pbuf_header failed", 0); } } inseg.len -= (u16_t)(pcb->rcv_nxt - seqno); 802e132: 4a57 ldr r2, [pc, #348] ; (802e290 ) 802e134: 4955 ldr r1, [pc, #340] ; (802e28c ) 802e136: 8915 ldrh r5, [r2, #8] 802e138: 6808 ldr r0, [r1, #0] 802e13a: 6aa3 ldr r3, [r4, #40] ; 0x28 802e13c: 1940 adds r0, r0, r5 802e13e: 1ac0 subs r0, r0, r3 802e140: 8110 strh r0, [r2, #8] inseg.tcphdr->seqno = seqno = pcb->rcv_nxt; 802e142: 68d2 ldr r2, [r2, #12] 802e144: 600b str r3, [r1, #0] 802e146: 6053 str r3, [r2, #4] 802e148: e006 b.n 802e158 } else { if (TCP_SEQ_LT(seqno, pcb->rcv_nxt)){ 802e14a: 1ac9 subs r1, r1, r3 802e14c: 2900 cmp r1, #0 802e14e: da03 bge.n 802e158 /* the whole segment is < rcv_nxt */ /* must be a duplicate of a packet that has already been correctly handled */ LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_receive: duplicate seqno %"U32_F"\n", seqno)); tcp_ack_now(pcb); 802e150: 7fa3 ldrb r3, [r4, #30] 802e152: f043 0302 orr.w r3, r3, #2 802e156: 77a3 strb r3, [r4, #30] } /* The sequence number must be within the window (above rcv_nxt and below rcv_nxt + rcv_wnd) in order to be further processed. */ if (TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, 802e158: 4b4c ldr r3, [pc, #304] ; (802e28c ) 802e15a: 6aa2 ldr r2, [r4, #40] ; 0x28 802e15c: 681b ldr r3, [r3, #0] 802e15e: 1a99 subs r1, r3, r2 802e160: 2900 cmp r1, #0 802e162: db71 blt.n 802e248 802e164: 1c59 adds r1, r3, #1 802e166: 8da0 ldrh r0, [r4, #44] ; 0x2c 802e168: 1a89 subs r1, r1, r2 802e16a: 1a09 subs r1, r1, r0 802e16c: 2900 cmp r1, #0 802e16e: dc6b bgt.n 802e248 pcb->rcv_nxt + pcb->rcv_wnd - 1)){ if (pcb->rcv_nxt == seqno) { 802e170: 429a cmp r2, r3 802e172: d169 bne.n 802e248 /* The incoming segment is the next in sequence. We check if we have to trim the end of the segment and update rcv_nxt and pass the data to the application. */ tcplen = TCP_TCPLEN(&inseg); 802e174: 4d46 ldr r5, [pc, #280] ; (802e290 ) 802e176: 68eb ldr r3, [r5, #12] 802e178: 892e ldrh r6, [r5, #8] 802e17a: 8998 ldrh r0, [r3, #12] 802e17c: f7fd fe1f bl 802bdbe 802e180: f010 0003 ands.w r0, r0, #3 802e184: bf18 it ne 802e186: 2001 movne r0, #1 802e188: 4b3f ldr r3, [pc, #252] ; (802e288 ) 802e18a: 1830 adds r0, r6, r0 802e18c: b280 uxth r0, r0 802e18e: 8018 strh r0, [r3, #0] if (tcplen > pcb->rcv_wnd) { 802e190: 8da3 ldrh r3, [r4, #44] ; 0x2c 802e192: 4283 cmp r3, r0 802e194: d230 bcs.n 802e1f8 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_receive: other end overran receive window" "seqno %"U32_F" len %"U16_F" right edge %"U32_F"\n", seqno, tcplen, pcb->rcv_nxt + pcb->rcv_wnd)); if (TCPH_FLAGS(inseg.tcphdr) & TCP_FIN) { 802e196: 68eb ldr r3, [r5, #12] 802e198: 8998 ldrh r0, [r3, #12] 802e19a: f7fd fe10 bl 802bdbe 802e19e: 07c0 lsls r0, r0, #31 802e1a0: d50c bpl.n 802e1bc /* Must remove the FIN from the header as we're trimming * that byte of sequence-space from the packet */ TCPH_FLAGS_SET(inseg.tcphdr, TCPH_FLAGS(inseg.tcphdr) &~ TCP_FIN); 802e1a2: 68ed ldr r5, [r5, #12] 802e1a4: 89ae ldrh r6, [r5, #12] 802e1a6: 4630 mov r0, r6 802e1a8: f7fd fe09 bl 802bdbe 802e1ac: f000 003e and.w r0, r0, #62 ; 0x3e 802e1b0: f7fd fe00 bl 802bdb4 802e1b4: f426 567c bic.w r6, r6, #16128 ; 0x3f00 802e1b8: 4330 orrs r0, r6 802e1ba: 81a8 strh r0, [r5, #12] } /* Adjust length of segment to fit in the window. */ inseg.len = pcb->rcv_wnd; 802e1bc: 8da3 ldrh r3, [r4, #44] ; 0x2c 802e1be: 4d34 ldr r5, [pc, #208] ; (802e290 ) 802e1c0: 812b strh r3, [r5, #8] if (TCPH_FLAGS(inseg.tcphdr) & TCP_SYN) { 802e1c2: 68eb ldr r3, [r5, #12] 802e1c4: 8998 ldrh r0, [r3, #12] 802e1c6: f7fd fdfa bl 802bdbe 802e1ca: f000 0002 and.w r0, r0, #2 802e1ce: b280 uxth r0, r0 802e1d0: b110 cbz r0, 802e1d8 inseg.len -= 1; 802e1d2: 892b ldrh r3, [r5, #8] 802e1d4: 3b01 subs r3, #1 802e1d6: 812b strh r3, [r5, #8] } pbuf_realloc(inseg.p, inseg.len); 802e1d8: 6868 ldr r0, [r5, #4] 802e1da: 8929 ldrh r1, [r5, #8] 802e1dc: f7fe ff4f bl 802d07e tcplen = TCP_TCPLEN(&inseg); 802e1e0: 68eb ldr r3, [r5, #12] 802e1e2: 892e ldrh r6, [r5, #8] 802e1e4: 8998 ldrh r0, [r3, #12] 802e1e6: f7fd fdea bl 802bdbe 802e1ea: f010 0003 ands.w r0, r0, #3 802e1ee: bf18 it ne 802e1f0: 2001 movne r0, #1 802e1f2: 4b25 ldr r3, [pc, #148] ; (802e288 ) 802e1f4: 1830 adds r0, r6, r0 802e1f6: 8018 strh r0, [r3, #0] pcb->ooseq = next; } } #endif /* TCP_QUEUE_OOSEQ */ pcb->rcv_nxt = seqno + tcplen; 802e1f8: 4b23 ldr r3, [pc, #140] ; (802e288 ) 802e1fa: 4a24 ldr r2, [pc, #144] ; (802e28c ) 802e1fc: 881b ldrh r3, [r3, #0] 802e1fe: 6812 ldr r2, [r2, #0] 802e200: 189a adds r2, r3, r2 802e202: 62a2 str r2, [r4, #40] ; 0x28 /* Update the receiver's (our) window. */ LWIP_ASSERT("tcp_receive: tcplen > rcv_wnd\n", pcb->rcv_wnd >= tcplen); pcb->rcv_wnd -= tcplen; 802e204: 8da2 ldrh r2, [r4, #44] ; 0x2c 802e206: 1ad3 subs r3, r2, r3 802e208: 85a3 strh r3, [r4, #44] ; 0x2c tcp_update_rcv_ann_wnd(pcb); 802e20a: 4620 mov r0, r4 802e20c: f7ff f986 bl 802d51c chains its data on this pbuf as well. If the segment was a FIN, we set the TF_GOT_FIN flag that will be used to indicate to the application that the remote side has closed its end of the connection. */ if (inseg.p->tot_len > 0) { 802e210: 4b1f ldr r3, [pc, #124] ; (802e290 ) 802e212: 685a ldr r2, [r3, #4] 802e214: 8911 ldrh r1, [r2, #8] 802e216: b119 cbz r1, 802e220 recv_data = inseg.p; 802e218: 491e ldr r1, [pc, #120] ; (802e294 ) 802e21a: 600a str r2, [r1, #0] /* Since this pbuf now is the responsibility of the application, we delete our reference to it so that we won't (mistakingly) deallocate it. */ inseg.p = NULL; 802e21c: 2200 movs r2, #0 802e21e: 605a str r2, [r3, #4] } if (TCPH_FLAGS(inseg.tcphdr) & TCP_FIN) { 802e220: 68db ldr r3, [r3, #12] 802e222: 8998 ldrh r0, [r3, #12] 802e224: f7fd fdcb bl 802bdbe 802e228: 07c1 lsls r1, r0, #31 802e22a: d504 bpl.n 802e236 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_receive: received FIN.\n")); recv_flags |= TF_GOT_FIN; 802e22c: 4b1a ldr r3, [pc, #104] ; (802e298 ) 802e22e: 781a ldrb r2, [r3, #0] 802e230: f042 0220 orr.w r2, r2, #32 802e234: 701a strb r2, [r3, #0] } #endif /* TCP_QUEUE_OOSEQ */ /* Acknowledge the segment(s). */ tcp_ack(pcb); 802e236: 7fa3 ldrb r3, [r4, #30] 802e238: 07da lsls r2, r3, #31 802e23a: d502 bpl.n 802e242 802e23c: f023 0301 bic.w r3, r3, #1 802e240: e013 b.n 802e26a 802e242: f043 0301 orr.w r3, r3, #1 802e246: e012 b.n 802e26e } else { /* We get here if the incoming segment is out-of-sequence. */ tcp_send_empty_ack(pcb); 802e248: 4620 mov r0, r4 TCP_SEQ_GEQ(seqno, pcb->rcv_nxt + pcb->rcv_wnd)) {*/ if(!TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, pcb->rcv_nxt + pcb->rcv_wnd-1)){ tcp_ack_now(pcb); } } } 802e24a: e8bd 41f0 ldmia.w sp!, {r4, r5, r6, r7, r8, lr} /* Acknowledge the segment(s). */ tcp_ack(pcb); } else { /* We get here if the incoming segment is out-of-sequence. */ tcp_send_empty_ack(pcb); 802e24e: f000 bf09 b.w 802f064 } else { /* Segments with length 0 is taken care of here. Segments that fall out of the window are ACKed. */ /*if (TCP_SEQ_GT(pcb->rcv_nxt, seqno) || TCP_SEQ_GEQ(seqno, pcb->rcv_nxt + pcb->rcv_wnd)) {*/ if(!TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, pcb->rcv_nxt + pcb->rcv_wnd-1)){ 802e252: 6812 ldr r2, [r2, #0] 802e254: 6aa3 ldr r3, [r4, #40] ; 0x28 802e256: 1ad1 subs r1, r2, r3 802e258: 2900 cmp r1, #0 802e25a: db05 blt.n 802e268 802e25c: 3201 adds r2, #1 802e25e: 8da1 ldrh r1, [r4, #44] ; 0x2c 802e260: 1ad3 subs r3, r2, r3 802e262: 1a5b subs r3, r3, r1 802e264: 2b00 cmp r3, #0 802e266: dd09 ble.n 802e27c tcp_ack_now(pcb); 802e268: 7fa3 ldrb r3, [r4, #30] 802e26a: f043 0302 orr.w r3, r3, #2 802e26e: 77a3 strb r3, [r4, #30] 802e270: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} } } /* If Clause (1) or more is true, but not a duplicate ack, reset * count of consecutive duplicate acks */ if (!found_dupack) { pcb->dupacks = 0; 802e274: 2300 movs r3, #0 802e276: f884 3047 strb.w r3, [r4, #71] ; 0x47 802e27a: e6dd b.n 802e038 802e27c: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802e280: 2000e0fc .word 0x2000e0fc 802e284: 20010fe0 .word 0x20010fe0 802e288: 2000e0f8 .word 0x2000e0f8 802e28c: 2000e0f4 .word 0x2000e0f4 802e290: 2000e10c .word 0x2000e10c 802e294: 2000e104 .word 0x2000e104 802e298: 2000e101 .word 0x2000e101 0802e29c : * @param p received TCP segment to process (p->payload pointing to the IP header) * @param inp network interface on which this segment was received */ void tcp_input(struct pbuf *p, struct netif *inp) { 802e29c: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} 802e2a0: 4606 mov r6, r0 802e2a2: 460f mov r7, r1 err_t err; PERF_START; TCP_STATS_INC(tcp.recv); snmp_inc_tcpinsegs(); 802e2a4: f003 fc9c bl 8031be0 iphdr = (struct ip_hdr *)p->payload; 802e2a8: 6873 ldr r3, [r6, #4] 802e2aa: 4aa7 ldr r2, [pc, #668] ; (802e548 ) tcphdr = (struct tcp_hdr *)((u8_t *)p->payload + IPH_HL(iphdr) * 4); 802e2ac: 4ca7 ldr r4, [pc, #668] ; (802e54c ) PERF_START; TCP_STATS_INC(tcp.recv); snmp_inc_tcpinsegs(); iphdr = (struct ip_hdr *)p->payload; 802e2ae: 6013 str r3, [r2, #0] tcphdr = (struct tcp_hdr *)((u8_t *)p->payload + IPH_HL(iphdr) * 4); 802e2b0: 781a ldrb r2, [r3, #0] 802e2b2: f002 020f and.w r2, r2, #15 #if TCP_INPUT_DEBUG tcp_debug_print(tcphdr); #endif /* remove header from payload */ if (pbuf_header(p, -((s16_t)(IPH_HL(iphdr) * 4))) || (p->tot_len < sizeof(struct tcp_hdr))) { 802e2b6: 0091 lsls r1, r2, #2 TCP_STATS_INC(tcp.recv); snmp_inc_tcpinsegs(); iphdr = (struct ip_hdr *)p->payload; tcphdr = (struct tcp_hdr *)((u8_t *)p->payload + IPH_HL(iphdr) * 4); 802e2b8: eb03 0382 add.w r3, r3, r2, lsl #2 #if TCP_INPUT_DEBUG tcp_debug_print(tcphdr); #endif /* remove header from payload */ if (pbuf_header(p, -((s16_t)(IPH_HL(iphdr) * 4))) || (p->tot_len < sizeof(struct tcp_hdr))) { 802e2bc: 4630 mov r0, r6 802e2be: 4249 negs r1, r1 TCP_STATS_INC(tcp.recv); snmp_inc_tcpinsegs(); iphdr = (struct ip_hdr *)p->payload; tcphdr = (struct tcp_hdr *)((u8_t *)p->payload + IPH_HL(iphdr) * 4); 802e2c0: 6023 str r3, [r4, #0] #if TCP_INPUT_DEBUG tcp_debug_print(tcphdr); #endif /* remove header from payload */ if (pbuf_header(p, -((s16_t)(IPH_HL(iphdr) * 4))) || (p->tot_len < sizeof(struct tcp_hdr))) { 802e2c2: f7fe fe8a bl 802cfda 802e2c6: 2800 cmp r0, #0 802e2c8: f040 83ce bne.w 802ea68 802e2cc: 8933 ldrh r3, [r6, #8] 802e2ce: 2b13 cmp r3, #19 802e2d0: f240 83ca bls.w 802ea68 TCP_STATS_INC(tcp.lenerr); goto dropped; } /* Don't even process incoming broadcasts/multicasts. */ if (ip_addr_isbroadcast(¤t_iphdr_dest, inp) || 802e2d4: 4d9e ldr r5, [pc, #632] ; (802e550 ) 802e2d6: 4639 mov r1, r7 802e2d8: 6828 ldr r0, [r5, #0] 802e2da: f001 fd43 bl 802fd64 802e2de: 2800 cmp r0, #0 802e2e0: f040 83c2 bne.w 802ea68 ip_addr_ismulticast(¤t_iphdr_dest)) { 802e2e4: 682b ldr r3, [r5, #0] 802e2e6: f003 03f0 and.w r3, r3, #240 ; 0xf0 TCP_STATS_INC(tcp.lenerr); goto dropped; } /* Don't even process incoming broadcasts/multicasts. */ if (ip_addr_isbroadcast(¤t_iphdr_dest, inp) || 802e2ea: 2be0 cmp r3, #224 ; 0xe0 802e2ec: f000 83bc beq.w 802ea68 } #endif /* Move the payload pointer in the pbuf so that it points to the TCP data instead of the TCP header. */ hdrlen = TCPH_HDRLEN(tcphdr); 802e2f0: 6823 ldr r3, [r4, #0] 802e2f2: 8998 ldrh r0, [r3, #12] 802e2f4: f7fd fd63 bl 802bdbe if(pbuf_header(p, -(hdrlen * 4))){ 802e2f8: f06f 0103 mvn.w r1, #3 802e2fc: f3c0 3307 ubfx r3, r0, #12, #8 802e300: 4359 muls r1, r3 802e302: 4630 mov r0, r6 802e304: f7fe fe69 bl 802cfda 802e308: 4683 mov fp, r0 802e30a: 2800 cmp r0, #0 802e30c: f040 83ac bne.w 802ea68 TCP_STATS_INC(tcp.lenerr); goto dropped; } /* Convert fields in TCP header to host byte order. */ tcphdr->src = ntohs(tcphdr->src); 802e310: 6827 ldr r7, [r4, #0] 802e312: 8838 ldrh r0, [r7, #0] 802e314: f7fd fd53 bl 802bdbe 802e318: 8038 strh r0, [r7, #0] tcphdr->dest = ntohs(tcphdr->dest); 802e31a: 6827 ldr r7, [r4, #0] 802e31c: 8878 ldrh r0, [r7, #2] 802e31e: f7fd fd4e bl 802bdbe 802e322: 8078 strh r0, [r7, #2] seqno = tcphdr->seqno = ntohl(tcphdr->seqno); 802e324: 6827 ldr r7, [r4, #0] 802e326: 6878 ldr r0, [r7, #4] 802e328: f7fd fd50 bl 802bdcc 802e32c: 4b89 ldr r3, [pc, #548] ; (802e554 ) 802e32e: 6078 str r0, [r7, #4] ackno = tcphdr->ackno = ntohl(tcphdr->ackno); 802e330: 6827 ldr r7, [r4, #0] } /* Convert fields in TCP header to host byte order. */ tcphdr->src = ntohs(tcphdr->src); tcphdr->dest = ntohs(tcphdr->dest); seqno = tcphdr->seqno = ntohl(tcphdr->seqno); 802e332: 6018 str r0, [r3, #0] ackno = tcphdr->ackno = ntohl(tcphdr->ackno); 802e334: 68b8 ldr r0, [r7, #8] 802e336: f7fd fd49 bl 802bdcc 802e33a: 4b87 ldr r3, [pc, #540] ; (802e558 ) 802e33c: 60b8 str r0, [r7, #8] tcphdr->wnd = ntohs(tcphdr->wnd); 802e33e: 6827 ldr r7, [r4, #0] /* Convert fields in TCP header to host byte order. */ tcphdr->src = ntohs(tcphdr->src); tcphdr->dest = ntohs(tcphdr->dest); seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); 802e340: 6018 str r0, [r3, #0] tcphdr->wnd = ntohs(tcphdr->wnd); 802e342: 89f8 ldrh r0, [r7, #14] 802e344: f7fd fd3b bl 802bdbe 802e348: 81f8 strh r0, [r7, #14] flags = TCPH_FLAGS(tcphdr); 802e34a: 6823 ldr r3, [r4, #0] 802e34c: 8998 ldrh r0, [r3, #12] 802e34e: f7fd fd36 bl 802bdbe 802e352: 4b82 ldr r3, [pc, #520] ; (802e55c ) tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); 802e354: f8b6 8008 ldrh.w r8, [r6, #8] for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { LWIP_ASSERT("tcp_input: active pcb->state != CLOSED", pcb->state != CLOSED); LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); LWIP_ASSERT("tcp_input: active pcb->state != LISTEN", pcb->state != LISTEN); if (pcb->remote_port == tcphdr->src && 802e358: 6827 ldr r7, [r4, #0] seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); tcphdr->wnd = ntohs(tcphdr->wnd); flags = TCPH_FLAGS(tcphdr); tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); 802e35a: f010 0c03 ands.w ip, r0, #3 tcphdr->dest = ntohs(tcphdr->dest); seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); tcphdr->wnd = ntohs(tcphdr->wnd); flags = TCPH_FLAGS(tcphdr); 802e35e: f000 013f and.w r1, r0, #63 ; 0x3f tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); 802e362: bf18 it ne 802e364: f04f 0c01 movne.w ip, #1 tcphdr->dest = ntohs(tcphdr->dest); seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); tcphdr->wnd = ntohs(tcphdr->wnd); flags = TCPH_FLAGS(tcphdr); 802e368: 7019 strb r1, [r3, #0] tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); 802e36a: 44c4 add ip, r8 802e36c: 4b7c ldr r3, [pc, #496] ; (802e560 ) LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); LWIP_ASSERT("tcp_input: active pcb->state != LISTEN", pcb->state != LISTEN); if (pcb->remote_port == tcphdr->src && pcb->local_port == tcphdr->dest && ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src) && ip_addr_cmp(&(pcb->local_ip), ¤t_iphdr_dest)) { 802e36e: 6829 ldr r1, [r5, #0] seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); tcphdr->wnd = ntohs(tcphdr->wnd); flags = TCPH_FLAGS(tcphdr); tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); 802e370: fa1f fc8c uxth.w ip, ip 802e374: f8a3 c000 strh.w ip, [r3] /* Demultiplex an incoming segment. First, we check if it is destined for an active connection. */ prev = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802e378: 4b7a ldr r3, [pc, #488] ; (802e564 ) 802e37a: f8d3 a000 ldr.w sl, [r3] LWIP_ASSERT("tcp_input: active pcb->state != CLOSED", pcb->state != CLOSED); LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); LWIP_ASSERT("tcp_input: active pcb->state != LISTEN", pcb->state != LISTEN); if (pcb->remote_port == tcphdr->src && pcb->local_port == tcphdr->dest && ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src) && 802e37e: 4b7a ldr r3, [pc, #488] ; (802e568 ) tcphdr->dest = ntohs(tcphdr->dest); seqno = tcphdr->seqno = ntohl(tcphdr->seqno); ackno = tcphdr->ackno = ntohl(tcphdr->ackno); tcphdr->wnd = ntohs(tcphdr->wnd); flags = TCPH_FLAGS(tcphdr); 802e380: 4602 mov r2, r0 LWIP_ASSERT("tcp_input: active pcb->state != CLOSED", pcb->state != CLOSED); LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); LWIP_ASSERT("tcp_input: active pcb->state != LISTEN", pcb->state != LISTEN); if (pcb->remote_port == tcphdr->src && pcb->local_port == tcphdr->dest && ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src) && 802e382: f8d3 9000 ldr.w r9, [r3] /* Demultiplex an incoming segment. First, we check if it is destined for an active connection. */ prev = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802e386: 4654 mov r4, sl flags = TCPH_FLAGS(tcphdr); tcplen = p->tot_len + ((flags & (TCP_FIN | TCP_SYN)) ? 1 : 0); /* Demultiplex an incoming segment. First, we check if it is destined for an active connection. */ prev = NULL; 802e388: 4658 mov r0, fp for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802e38a: e019 b.n 802e3c0 LWIP_ASSERT("tcp_input: active pcb->state != CLOSED", pcb->state != CLOSED); LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); LWIP_ASSERT("tcp_input: active pcb->state != LISTEN", pcb->state != LISTEN); if (pcb->remote_port == tcphdr->src && 802e38c: 8ba5 ldrh r5, [r4, #28] 802e38e: 883b ldrh r3, [r7, #0] 802e390: 429d cmp r5, r3 802e392: d113 bne.n 802e3bc 802e394: 8b65 ldrh r5, [r4, #26] 802e396: 887b ldrh r3, [r7, #2] 802e398: 429d cmp r5, r3 802e39a: d10f bne.n 802e3bc pcb->local_port == tcphdr->dest && 802e39c: 6863 ldr r3, [r4, #4] 802e39e: 454b cmp r3, r9 802e3a0: d10c bne.n 802e3bc ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src) && 802e3a2: 6823 ldr r3, [r4, #0] 802e3a4: 428b cmp r3, r1 802e3a6: d109 bne.n 802e3bc /* Move this PCB to the front of the list so that subsequent lookups will be faster (we exploit locality in TCP segment arrivals). */ LWIP_ASSERT("tcp_input: pcb->next != pcb (before cache)", pcb->next != pcb); if (prev != NULL) { 802e3a8: 2800 cmp r0, #0 802e3aa: f000 8382 beq.w 802eab2 prev->next = pcb->next; 802e3ae: 68e3 ldr r3, [r4, #12] 802e3b0: 60c3 str r3, [r0, #12] pcb->next = tcp_active_pcbs; tcp_active_pcbs = pcb; 802e3b2: 4b6c ldr r3, [pc, #432] ; (802e564 ) lookups will be faster (we exploit locality in TCP segment arrivals). */ LWIP_ASSERT("tcp_input: pcb->next != pcb (before cache)", pcb->next != pcb); if (prev != NULL) { prev->next = pcb->next; pcb->next = tcp_active_pcbs; 802e3b4: f8c4 a00c str.w sl, [r4, #12] tcp_active_pcbs = pcb; 802e3b8: 601c str r4, [r3, #0] 802e3ba: e37a b.n 802eab2 802e3bc: 4620 mov r0, r4 /* Demultiplex an incoming segment. First, we check if it is destined for an active connection. */ prev = NULL; for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { 802e3be: 68e4 ldr r4, [r4, #12] 802e3c0: 2c00 cmp r4, #0 802e3c2: d1e3 bne.n 802e38c 802e3c4: e372 b.n 802eaac if (pcb == NULL) { /* If it did not go to an active connection, we check the connections in the TIME-WAIT state. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { LWIP_ASSERT("tcp_input: TIME-WAIT pcb->state == TIME-WAIT", pcb->state == TIME_WAIT); if (pcb->remote_port == tcphdr->src && 802e3c6: 8b98 ldrh r0, [r3, #28] 802e3c8: 883c ldrh r4, [r7, #0] 802e3ca: 4284 cmp r4, r0 802e3cc: d130 bne.n 802e430 pcb->local_port == tcphdr->dest && 802e3ce: 8b58 ldrh r0, [r3, #26] if (pcb == NULL) { /* If it did not go to an active connection, we check the connections in the TIME-WAIT state. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { LWIP_ASSERT("tcp_input: TIME-WAIT pcb->state == TIME-WAIT", pcb->state == TIME_WAIT); if (pcb->remote_port == tcphdr->src && 802e3d0: 887d ldrh r5, [r7, #2] 802e3d2: 4285 cmp r5, r0 802e3d4: d12c bne.n 802e430 pcb->local_port == tcphdr->dest && 802e3d6: 6858 ldr r0, [r3, #4] 802e3d8: 4548 cmp r0, r9 802e3da: d129 bne.n 802e430 ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src) && 802e3dc: 6818 ldr r0, [r3, #0] 802e3de: 4288 cmp r0, r1 802e3e0: d126 bne.n 802e430 /* RFC 1337: in TIME_WAIT, ignore RST and ACK FINs + any 'acceptable' segments */ /* RFC 793 3.9 Event Processing - Segment Arrives: * - first check sequence number - we skip that one in TIME_WAIT (always * acceptable since we only send ACKs) * - second check the RST bit (... return) */ if (flags & TCP_RST) { 802e3e2: f002 0104 and.w r1, r2, #4 802e3e6: b2c9 uxtb r1, r1 802e3e8: 2900 cmp r1, #0 802e3ea: f040 833f bne.w 802ea6c return ERR_OK; } /* - fourth, check the SYN bit, */ if (flags & TCP_SYN) { 802e3ee: f002 0102 and.w r1, r2, #2 802e3f2: b2c9 uxtb r1, r1 802e3f4: b159 cbz r1, 802e40e /* If an incoming segment is not acceptable, an acknowledgment should be sent in reply */ if (TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, pcb->rcv_nxt+pcb->rcv_wnd)) { 802e3f6: 4a57 ldr r2, [pc, #348] ; (802e554 ) 802e3f8: 6811 ldr r1, [r2, #0] 802e3fa: 6a9a ldr r2, [r3, #40] ; 0x28 802e3fc: 1a8a subs r2, r1, r2 802e3fe: d40b bmi.n 802e418 802e400: 8d98 ldrh r0, [r3, #44] ; 0x2c 802e402: 1a12 subs r2, r2, r0 802e404: 2a00 cmp r2, #0 802e406: dc07 bgt.n 802e418 /* If the SYN is in the window it is an error, send a reset */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), 802e408: 9500 str r5, [sp, #0] 802e40a: 9401 str r4, [sp, #4] 802e40c: e041 b.n 802e492 tcphdr->dest, tcphdr->src); return ERR_OK; } } else if (flags & TCP_FIN) { 802e40e: 07d2 lsls r2, r2, #31 802e410: d502 bpl.n 802e418 /* - eighth, check the FIN bit: Remain in the TIME-WAIT state. Restart the 2 MSL time-wait timeout.*/ pcb->tmr = tcp_ticks; 802e412: 4a56 ldr r2, [pc, #344] ; (802e56c ) 802e414: 6812 ldr r2, [r2, #0] 802e416: 625a str r2, [r3, #36] ; 0x24 } if ((tcplen > 0)) { 802e418: f1bc 0f00 cmp.w ip, #0 802e41c: f000 8326 beq.w 802ea6c /* Acknowledge data, FIN or out-of-window SYN */ pcb->flags |= TF_ACK_NOW; 802e420: 7f9a ldrb r2, [r3, #30] 802e422: f042 0202 orr.w r2, r2, #2 802e426: 779a strb r2, [r3, #30] return tcp_output(pcb); 802e428: 4618 mov r0, r3 802e42a: f000 fe3d bl 802f0a8 802e42e: e31d b.n 802ea6c } if (pcb == NULL) { /* If it did not go to an active connection, we check the connections in the TIME-WAIT state. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { 802e430: 68db ldr r3, [r3, #12] 802e432: 2b00 cmp r3, #0 802e434: d1c7 bne.n 802e3c6 } /* Finally, if we still did not get a match, we check all PCBs that are LISTENing for incoming connections. */ prev = NULL; for(lpcb = tcp_listen_pcbs.listen_pcbs; lpcb != NULL; lpcb = lpcb->next) { 802e436: 484e ldr r0, [pc, #312] ; (802e570 ) 802e438: 6804 ldr r4, [r0, #0] 802e43a: 4625 mov r5, r4 802e43c: e00f b.n 802e45e if (lpcb->local_port == tcphdr->dest) { 802e43e: 8b68 ldrh r0, [r5, #26] 802e440: f8b7 8002 ldrh.w r8, [r7, #2] 802e444: 4580 cmp r8, r0 802e446: d108 bne.n 802e45a /* found an ANY-match */ lpcb_any = lpcb; lpcb_prev = prev; } #else /* SO_REUSE */ if (ip_addr_cmp(&(lpcb->local_ip), ¤t_iphdr_dest) || 802e448: f8d5 8000 ldr.w r8, [r5] 802e44c: 4588 cmp r8, r1 802e44e: f000 8342 beq.w 802ead6 ip_addr_isany(&(lpcb->local_ip))) { 802e452: f1b8 0f00 cmp.w r8, #0 802e456: f000 833e beq.w 802ead6 802e45a: 462b mov r3, r5 } /* Finally, if we still did not get a match, we check all PCBs that are LISTENing for incoming connections. */ prev = NULL; for(lpcb = tcp_listen_pcbs.listen_pcbs; lpcb != NULL; lpcb = lpcb->next) { 802e45c: 68ed ldr r5, [r5, #12] 802e45e: 2d00 cmp r5, #0 802e460: d1ed bne.n 802e43e 802e462: e33c b.n 802eade if (lpcb != NULL) { /* Move this PCB to the front of the list so that subsequent lookups will be faster (we exploit locality in TCP segment arrivals). */ if (prev != NULL) { ((struct tcp_pcb_listen *)prev)->next = lpcb->next; 802e464: 68e9 ldr r1, [r5, #12] 802e466: 60d9 str r1, [r3, #12] /* our successor is the remainder of the listening list */ lpcb->next = tcp_listen_pcbs.listen_pcbs; /* put this listening pcb at the head of the listening list */ tcp_listen_pcbs.listen_pcbs = lpcb; 802e468: 4b41 ldr r3, [pc, #260] ; (802e570 ) lookups will be faster (we exploit locality in TCP segment arrivals). */ if (prev != NULL) { ((struct tcp_pcb_listen *)prev)->next = lpcb->next; /* our successor is the remainder of the listening list */ lpcb->next = tcp_listen_pcbs.listen_pcbs; 802e46a: 60ec str r4, [r5, #12] /* put this listening pcb at the head of the listening list */ tcp_listen_pcbs.listen_pcbs = lpcb; 802e46c: 601d str r5, [r3, #0] tcp_listen_input(struct tcp_pcb_listen *pcb) { struct tcp_pcb *npcb; err_t rc; if (flags & TCP_RST) { 802e46e: f002 0304 and.w r3, r2, #4 802e472: b2db uxtb r3, r3 802e474: 2b00 cmp r3, #0 802e476: f040 82f9 bne.w 802ea6c return ERR_OK; } /* In the LISTEN state, we check for incoming SYN segments, creates a new PCB, and responds with a SYN|ACK. */ if (flags & TCP_ACK) { 802e47a: f002 0810 and.w r8, r2, #16 802e47e: fa5f f888 uxtb.w r8, r8 802e482: f1b8 0f00 cmp.w r8, #0 802e486: d00c beq.n 802e4a2 /* For incoming segments with the ACK flag set, respond with a RST. */ LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_listen_input: ACK in LISTEN, sending reset\n")); tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), 802e488: 4b32 ldr r3, [pc, #200] ; (802e554 ) 802e48a: 6819 ldr r1, [r3, #0] 802e48c: 9000 str r0, [sp, #0] 802e48e: 883b ldrh r3, [r7, #0] 802e490: 9301 str r3, [sp, #4] 802e492: 4b31 ldr r3, [pc, #196] ; (802e558 ) 802e494: 6818 ldr r0, [r3, #0] 802e496: 4461 add r1, ip 802e498: 4a2d ldr r2, [pc, #180] ; (802e550 ) 802e49a: 4b33 ldr r3, [pc, #204] ; (802e568 ) 802e49c: f000 ff28 bl 802f2f0 802e4a0: e2e4 b.n 802ea6c ip_current_src_addr(), tcphdr->dest, tcphdr->src); } else if (flags & TCP_SYN) { 802e4a2: f002 0202 and.w r2, r2, #2 802e4a6: b2d2 uxtb r2, r2 802e4a8: 2a00 cmp r2, #0 802e4aa: f000 82df beq.w 802ea6c if (pcb->accepts_pending >= pcb->backlog) { LWIP_DEBUGF(TCP_DEBUG, ("tcp_listen_input: listen backlog exceeded for port %"U16_F"\n", tcphdr->dest)); return ERR_ABRT; } #endif /* TCP_LISTEN_BACKLOG */ npcb = tcp_alloc(pcb->prio); 802e4ae: 7e68 ldrb r0, [r5, #25] 802e4b0: f7ff fbc6 bl 802dc40 /* If a new PCB could not be created (probably due to lack of memory), we don't do anything, but rely on the sender will retransmit the SYN at a time when we have more memory available. */ if (npcb == NULL) { 802e4b4: 4604 mov r4, r0 802e4b6: 2800 cmp r0, #0 802e4b8: f000 82d8 beq.w 802ea6c } #if TCP_LISTEN_BACKLOG pcb->accepts_pending++; #endif /* TCP_LISTEN_BACKLOG */ /* Set up the new PCB. */ ip_addr_copy(npcb->local_ip, current_iphdr_dest); 802e4bc: 4b24 ldr r3, [pc, #144] ; (802e550 ) 802e4be: 681b ldr r3, [r3, #0] 802e4c0: 6003 str r3, [r0, #0] npcb->local_port = pcb->local_port; 802e4c2: 8b6b ldrh r3, [r5, #26] 802e4c4: 8343 strh r3, [r0, #26] ip_addr_copy(npcb->remote_ip, current_iphdr_src); 802e4c6: 4b28 ldr r3, [pc, #160] ; (802e568 ) 802e4c8: 681b ldr r3, [r3, #0] 802e4ca: 6043 str r3, [r0, #4] npcb->remote_port = tcphdr->src; 802e4cc: 4b1f ldr r3, [pc, #124] ; (802e54c ) 802e4ce: 681b ldr r3, [r3, #0] 802e4d0: 7859 ldrb r1, [r3, #1] 802e4d2: 781a ldrb r2, [r3, #0] 802e4d4: ea42 2201 orr.w r2, r2, r1, lsl #8 802e4d8: 8382 strh r2, [r0, #28] npcb->state = SYN_RCVD; 802e4da: 2203 movs r2, #3 802e4dc: 7602 strb r2, [r0, #24] npcb->rcv_nxt = seqno + 1; 802e4de: 4a1d ldr r2, [pc, #116] ; (802e554 ) 802e4e0: 6812 ldr r2, [r2, #0] 802e4e2: 1c51 adds r1, r2, #1 802e4e4: 6281 str r1, [r0, #40] ; 0x28 npcb->rcv_ann_right_edge = npcb->rcv_nxt; 802e4e6: 6301 str r1, [r0, #48] ; 0x30 npcb->snd_wnd = tcphdr->wnd; 802e4e8: 89db ldrh r3, [r3, #14] 802e4ea: f8a0 3060 strh.w r3, [r0, #96] ; 0x60 npcb->snd_wnd_max = tcphdr->wnd; 802e4ee: f8a0 3062 strh.w r3, [r0, #98] ; 0x62 npcb->ssthresh = npcb->snd_wnd; 802e4f2: f8a0 304e strh.w r3, [r0, #78] ; 0x4e npcb->snd_wl1 = seqno - 1;/* initialise to seqno-1 to force window update */ npcb->callback_arg = pcb->callback_arg; 802e4f6: 692b ldr r3, [r5, #16] 802e4f8: 6103 str r3, [r0, #16] #if LWIP_CALLBACK_API npcb->accept = pcb->accept; 802e4fa: 696b ldr r3, [r5, #20] npcb->rcv_nxt = seqno + 1; npcb->rcv_ann_right_edge = npcb->rcv_nxt; npcb->snd_wnd = tcphdr->wnd; npcb->snd_wnd_max = tcphdr->wnd; npcb->ssthresh = npcb->snd_wnd; npcb->snd_wl1 = seqno - 1;/* initialise to seqno-1 to force window update */ 802e4fc: 3a01 subs r2, #1 802e4fe: 6542 str r2, [r0, #84] ; 0x54 npcb->callback_arg = pcb->callback_arg; #if LWIP_CALLBACK_API npcb->accept = pcb->accept; 802e500: 6143 str r3, [r0, #20] #endif /* LWIP_CALLBACK_API */ /* inherit socket options */ npcb->so_options = pcb->so_options & SOF_INHERITED; 802e502: 7a2b ldrb r3, [r5, #8] 802e504: f023 0373 bic.w r3, r3, #115 ; 0x73 802e508: 7203 strb r3, [r0, #8] /* Register the new PCB so that we can begin receiving segments for it. */ TCP_REG_ACTIVE(npcb); 802e50a: 4b16 ldr r3, [pc, #88] ; (802e564 ) 802e50c: 681a ldr r2, [r3, #0] 802e50e: 6018 str r0, [r3, #0] 802e510: 60c2 str r2, [r0, #12] 802e512: f001 f887 bl 802f624 802e516: 4b17 ldr r3, [pc, #92] ; (802e574 ) 802e518: 2201 movs r2, #1 /* Parse any options in the SYN. */ tcp_parseopt(npcb); 802e51a: 4620 mov r0, r4 #endif /* LWIP_CALLBACK_API */ /* inherit socket options */ npcb->so_options = pcb->so_options & SOF_INHERITED; /* Register the new PCB so that we can begin receiving segments for it. */ TCP_REG_ACTIVE(npcb); 802e51c: 701a strb r2, [r3, #0] /* Parse any options in the SYN. */ tcp_parseopt(npcb); 802e51e: f7ff fc29 bl 802dd74 #if TCP_CALCULATE_EFF_SEND_MSS npcb->mss = tcp_eff_send_mss(npcb->mss, &(npcb->remote_ip)); 802e522: 1d21 adds r1, r4, #4 802e524: 8ee0 ldrh r0, [r4, #54] ; 0x36 802e526: f7ff fc16 bl 802dd56 802e52a: 86e0 strh r0, [r4, #54] ; 0x36 #endif /* TCP_CALCULATE_EFF_SEND_MSS */ snmp_inc_tcppassiveopens(); 802e52c: f003 fb40 bl 8031bb0 /* Send a SYN|ACK together with the MSS option. */ rc = tcp_enqueue_flags(npcb, TCP_SYN | TCP_ACK); 802e530: 4620 mov r0, r4 802e532: 2112 movs r1, #18 802e534: f000 fd28 bl 802ef88 if (rc != ERR_OK) { 802e538: b120 cbz r0, 802e544 tcp_abandon(npcb, 0); 802e53a: 4620 mov r0, r4 802e53c: 4641 mov r1, r8 802e53e: f7ff f9e1 bl 802d904 802e542: e293 b.n 802ea6c return rc; } return tcp_output(npcb); 802e544: 4620 mov r0, r4 802e546: e770 b.n 802e42a 802e548: 2000e108 .word 0x2000e108 802e54c: 2000e0f0 .word 0x2000e0f0 802e550: 20011004 .word 0x20011004 802e554: 2000e0f4 .word 0x2000e0f4 802e558: 2000e0fc .word 0x2000e0fc 802e55c: 2000e100 .word 0x2000e100 802e560: 2000e0f8 .word 0x2000e0f8 802e564: 20010fdc .word 0x20010fdc 802e568: 20010ffc .word 0x20010ffc 802e56c: 20010fe0 .word 0x20010fe0 802e570: 20010fe4 .word 0x20010fe4 802e574: 20010fd8 .word 0x20010fd8 recv_data = NULL; recv_flags = 0; if (flags & TCP_PSH) { p->flags |= PBUF_FLAG_PUSH; 802e578: 7b73 ldrb r3, [r6, #13] 802e57a: f043 0301 orr.w r3, r3, #1 802e57e: 7373 strb r3, [r6, #13] } /* If there is data which was previously "refused" by upper layer */ if (pcb->refused_data != NULL) { 802e580: 6f63 ldr r3, [r4, #116] ; 0x74 802e582: b163 cbz r3, 802e59e if ((tcp_process_refused_data(pcb) == ERR_ABRT) || 802e584: 4620 mov r0, r4 802e586: f7ff fad1 bl 802db2c 802e58a: 300a adds r0, #10 802e58c: d004 beq.n 802e598 802e58e: 6f63 ldr r3, [r4, #116] ; 0x74 802e590: b12b cbz r3, 802e59e ((pcb->refused_data != NULL) && (tcplen > 0))) { 802e592: 4b9f ldr r3, [pc, #636] ; (802e810 ) 802e594: 881b ldrh r3, [r3, #0] 802e596: b113 cbz r3, 802e59e /* pcb has been aborted or refused data is still refused and the new segment contains data */ TCP_STATS_INC(tcp.drop); snmp_inc_tcpinerrs(); 802e598: f003 fb3a bl 8031c10 goto aborted; 802e59c: e249 b.n 802ea32 } } tcp_input_pcb = pcb; 802e59e: 4b9d ldr r3, [pc, #628] ; (802e814 ) 802e5a0: 601c str r4, [r3, #0] err_t err; err = ERR_OK; /* Process incoming RST segments. */ if (flags & TCP_RST) { 802e5a2: 4b9d ldr r3, [pc, #628] ; (802e818 ) 802e5a4: 781b ldrb r3, [r3, #0] 802e5a6: f003 0204 and.w r2, r3, #4 802e5aa: b2d2 uxtb r2, r2 802e5ac: b1aa cbz r2, 802e5da /* First, determine if the reset is acceptable. */ if (pcb->state == SYN_SENT) { 802e5ae: 7e23 ldrb r3, [r4, #24] 802e5b0: 2b02 cmp r3, #2 802e5b2: d106 bne.n 802e5c2 if (ackno == pcb->snd_nxt) { 802e5b4: 4b99 ldr r3, [pc, #612] ; (802e81c ) 802e5b6: 681a ldr r2, [r3, #0] 802e5b8: 6d23 ldr r3, [r4, #80] ; 0x50 802e5ba: 429a cmp r2, r3 802e5bc: f040 82a1 bne.w 802eb02 802e5c0: e296 b.n 802eaf0 acceptable = 1; } } else { if (TCP_SEQ_BETWEEN(seqno, pcb->rcv_nxt, 802e5c2: 4b97 ldr r3, [pc, #604] ; (802e820 ) 802e5c4: 681a ldr r2, [r3, #0] 802e5c6: 6aa3 ldr r3, [r4, #40] ; 0x28 802e5c8: 1ad3 subs r3, r2, r3 802e5ca: f100 829a bmi.w 802eb02 802e5ce: 8da1 ldrh r1, [r4, #44] ; 0x2c 802e5d0: 1a5b subs r3, r3, r1 802e5d2: 2b00 cmp r3, #0 802e5d4: f300 8295 bgt.w 802eb02 802e5d8: e28a b.n 802eaf0 seqno, pcb->rcv_nxt)); return ERR_OK; } } if ((flags & TCP_SYN) && (pcb->state != SYN_SENT && pcb->state != SYN_RCVD)) { 802e5da: f003 0302 and.w r3, r3, #2 802e5de: b2db uxtb r3, r3 802e5e0: b123 cbz r3, 802e5ec 802e5e2: 7e23 ldrb r3, [r4, #24] 802e5e4: 3b02 subs r3, #2 802e5e6: 2b01 cmp r3, #1 802e5e8: d900 bls.n 802e5ec 802e5ea: e06b b.n 802e6c4 /* Cope with new connection attempt after remote end crashed */ tcp_ack_now(pcb); return ERR_OK; } if ((pcb->flags & TF_RXCLOSED) == 0) { 802e5ec: 7fa3 ldrb r3, [r4, #30] 802e5ee: f003 0310 and.w r3, r3, #16 802e5f2: b2db uxtb r3, r3 802e5f4: b913 cbnz r3, 802e5fc /* Update the PCB (in)activity timer unless rx is closed (see tcp_shutdown) */ pcb->tmr = tcp_ticks; 802e5f6: 4b8b ldr r3, [pc, #556] ; (802e824 ) 802e5f8: 681b ldr r3, [r3, #0] 802e5fa: 6263 str r3, [r4, #36] ; 0x24 } pcb->keep_cnt_sent = 0; 802e5fc: 2300 movs r3, #0 802e5fe: f884 3092 strb.w r3, [r4, #146] ; 0x92 tcp_parseopt(pcb); 802e602: 4620 mov r0, r4 802e604: f7ff fbb6 bl 802dd74 /* Do different things depending on the TCP state. */ switch (pcb->state) { 802e608: 7e23 ldrb r3, [r4, #24] 802e60a: 3b02 subs r3, #2 802e60c: 2b07 cmp r3, #7 802e60e: f200 8278 bhi.w 802eb02 802e612: e8df f013 tbh [pc, r3, lsl #1] 802e616: 0008 .short 0x0008 802e618: 00c90077 .word 0x00c90077 802e61c: 013000da .word 0x013000da 802e620: 015200c9 .word 0x015200c9 802e624: 0186 .short 0x0186 case SYN_SENT: LWIP_DEBUGF(TCP_INPUT_DEBUG, ("SYN-SENT: ackno %"U32_F" pcb->snd_nxt %"U32_F" unacked %"U32_F"\n", ackno, pcb->snd_nxt, ntohl(pcb->unacked->tcphdr->seqno))); /* received SYN ACK with expected sequence number? */ if ((flags & TCP_ACK) && (flags & TCP_SYN) 802e626: 4b7c ldr r3, [pc, #496] ; (802e818 ) 802e628: 781b ldrb r3, [r3, #0] 802e62a: f003 0312 and.w r3, r3, #18 802e62e: 2b12 cmp r3, #18 802e630: d153 bne.n 802e6da && ackno == ntohl(pcb->unacked->tcphdr->seqno) + 1) { 802e632: 6f23 ldr r3, [r4, #112] ; 0x70 802e634: 4d79 ldr r5, [pc, #484] ; (802e81c ) 802e636: 68db ldr r3, [r3, #12] 802e638: 682e ldr r6, [r5, #0] 802e63a: 6858 ldr r0, [r3, #4] 802e63c: f7fd fbc6 bl 802bdcc 802e640: 3001 adds r0, #1 802e642: 4286 cmp r6, r0 802e644: d149 bne.n 802e6da pcb->snd_buf++; 802e646: f8b4 3066 ldrh.w r3, [r4, #102] ; 0x66 pcb->snd_wnd_max = tcphdr->wnd; pcb->snd_wl1 = seqno - 1; /* initialise to seqno - 1 to force window update */ pcb->state = ESTABLISHED; #if TCP_CALCULATE_EFF_SEND_MSS pcb->mss = tcp_eff_send_mss(pcb->mss, &(pcb->remote_ip)); 802e64a: 8ee0 ldrh r0, [r4, #54] ; 0x36 LWIP_DEBUGF(TCP_INPUT_DEBUG, ("SYN-SENT: ackno %"U32_F" pcb->snd_nxt %"U32_F" unacked %"U32_F"\n", ackno, pcb->snd_nxt, ntohl(pcb->unacked->tcphdr->seqno))); /* received SYN ACK with expected sequence number? */ if ((flags & TCP_ACK) && (flags & TCP_SYN) && ackno == ntohl(pcb->unacked->tcphdr->seqno) + 1) { pcb->snd_buf++; 802e64c: 3301 adds r3, #1 802e64e: f8a4 3066 strh.w r3, [r4, #102] ; 0x66 pcb->rcv_nxt = seqno + 1; 802e652: 4b73 ldr r3, [pc, #460] ; (802e820 ) 802e654: 681b ldr r3, [r3, #0] 802e656: 1c5a adds r2, r3, #1 802e658: 62a2 str r2, [r4, #40] ; 0x28 pcb->rcv_ann_right_edge = pcb->rcv_nxt; 802e65a: 6322 str r2, [r4, #48] ; 0x30 pcb->lastack = ackno; 802e65c: 682a ldr r2, [r5, #0] 802e65e: 64a2 str r2, [r4, #72] ; 0x48 pcb->snd_wnd = tcphdr->wnd; 802e660: 4a71 ldr r2, [pc, #452] ; (802e828 ) 802e662: 6812 ldr r2, [r2, #0] pcb->snd_wnd_max = tcphdr->wnd; pcb->snd_wl1 = seqno - 1; /* initialise to seqno - 1 to force window update */ 802e664: 3b01 subs r3, #1 && ackno == ntohl(pcb->unacked->tcphdr->seqno) + 1) { pcb->snd_buf++; pcb->rcv_nxt = seqno + 1; pcb->rcv_ann_right_edge = pcb->rcv_nxt; pcb->lastack = ackno; pcb->snd_wnd = tcphdr->wnd; 802e666: 89d2 ldrh r2, [r2, #14] pcb->snd_wnd_max = tcphdr->wnd; pcb->snd_wl1 = seqno - 1; /* initialise to seqno - 1 to force window update */ 802e668: 6563 str r3, [r4, #84] ; 0x54 pcb->state = ESTABLISHED; 802e66a: 2304 movs r3, #4 802e66c: 7623 strb r3, [r4, #24] #if TCP_CALCULATE_EFF_SEND_MSS pcb->mss = tcp_eff_send_mss(pcb->mss, &(pcb->remote_ip)); 802e66e: 18e1 adds r1, r4, r3 && ackno == ntohl(pcb->unacked->tcphdr->seqno) + 1) { pcb->snd_buf++; pcb->rcv_nxt = seqno + 1; pcb->rcv_ann_right_edge = pcb->rcv_nxt; pcb->lastack = ackno; pcb->snd_wnd = tcphdr->wnd; 802e670: f8a4 2060 strh.w r2, [r4, #96] ; 0x60 pcb->snd_wnd_max = tcphdr->wnd; 802e674: f8a4 2062 strh.w r2, [r4, #98] ; 0x62 pcb->snd_wl1 = seqno - 1; /* initialise to seqno - 1 to force window update */ pcb->state = ESTABLISHED; #if TCP_CALCULATE_EFF_SEND_MSS pcb->mss = tcp_eff_send_mss(pcb->mss, &(pcb->remote_ip)); 802e678: f7ff fb6d bl 802dd56 #endif /* TCP_CALCULATE_EFF_SEND_MSS */ /* Set ssthresh again after changing pcb->mss (already set in tcp_connect * but for the default value of pcb->mss) */ pcb->ssthresh = pcb->mss * 10; 802e67c: 230a movs r3, #10 802e67e: 4343 muls r3, r0 802e680: f8a4 304e strh.w r3, [r4, #78] ; 0x4e pcb->cwnd = ((pcb->cwnd == 1) ? (pcb->mss * 2) : pcb->mss); 802e684: f8b4 304c ldrh.w r3, [r4, #76] ; 0x4c pcb->snd_wnd_max = tcphdr->wnd; pcb->snd_wl1 = seqno - 1; /* initialise to seqno - 1 to force window update */ pcb->state = ESTABLISHED; #if TCP_CALCULATE_EFF_SEND_MSS pcb->mss = tcp_eff_send_mss(pcb->mss, &(pcb->remote_ip)); 802e688: 86e0 strh r0, [r4, #54] ; 0x36 /* Set ssthresh again after changing pcb->mss (already set in tcp_connect * but for the default value of pcb->mss) */ pcb->ssthresh = pcb->mss * 10; pcb->cwnd = ((pcb->cwnd == 1) ? (pcb->mss * 2) : pcb->mss); 802e68a: 2b01 cmp r3, #1 802e68c: d101 bne.n 802e692 802e68e: 0040 lsls r0, r0, #1 802e690: b280 uxth r0, r0 LWIP_ASSERT("pcb->snd_queuelen > 0", (pcb->snd_queuelen > 0)); --pcb->snd_queuelen; 802e692: f8b4 3068 ldrh.w r3, [r4, #104] ; 0x68 /* Set ssthresh again after changing pcb->mss (already set in tcp_connect * but for the default value of pcb->mss) */ pcb->ssthresh = pcb->mss * 10; pcb->cwnd = ((pcb->cwnd == 1) ? (pcb->mss * 2) : pcb->mss); 802e696: f8a4 004c strh.w r0, [r4, #76] ; 0x4c LWIP_ASSERT("pcb->snd_queuelen > 0", (pcb->snd_queuelen > 0)); --pcb->snd_queuelen; LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_process: SYN-SENT --queuelen %"U16_F"\n", (u16_t)pcb->snd_queuelen)); rseg = pcb->unacked; 802e69a: 6f20 ldr r0, [r4, #112] ; 0x70 * but for the default value of pcb->mss) */ pcb->ssthresh = pcb->mss * 10; pcb->cwnd = ((pcb->cwnd == 1) ? (pcb->mss * 2) : pcb->mss); LWIP_ASSERT("pcb->snd_queuelen > 0", (pcb->snd_queuelen > 0)); --pcb->snd_queuelen; 802e69c: 3b01 subs r3, #1 802e69e: f8a4 3068 strh.w r3, [r4, #104] ; 0x68 LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_process: SYN-SENT --queuelen %"U16_F"\n", (u16_t)pcb->snd_queuelen)); rseg = pcb->unacked; pcb->unacked = rseg->next; 802e6a2: 6803 ldr r3, [r0, #0] 802e6a4: 6723 str r3, [r4, #112] ; 0x70 tcp_seg_free(rseg); 802e6a6: f7fe ff70 bl 802d58a /* If there's nothing left to acknowledge, stop the retransmit timer, otherwise reset it to start again */ if(pcb->unacked == NULL) 802e6aa: 6f23 ldr r3, [r4, #112] ; 0x70 802e6ac: b91b cbnz r3, 802e6b6 pcb->rtime = -1; 802e6ae: f64f 73ff movw r3, #65535 ; 0xffff 802e6b2: 86a3 strh r3, [r4, #52] ; 0x34 802e6b4: e003 b.n 802e6be else { pcb->rtime = 0; 802e6b6: 2300 movs r3, #0 802e6b8: 86a3 strh r3, [r4, #52] ; 0x34 pcb->nrtx = 0; 802e6ba: f884 3046 strb.w r3, [r4, #70] ; 0x46 } /* Call the user specified function to call when sucessfully * connected. */ TCP_EVENT_CONNECTED(pcb, ERR_OK, err); 802e6be: f8d4 3080 ldr.w r3, [r4, #128] ; 0x80 802e6c2: b91b cbnz r3, 802e6cc if (err == ERR_ABRT) { return ERR_ABRT; } tcp_ack_now(pcb); 802e6c4: 7fa3 ldrb r3, [r4, #30] 802e6c6: f043 0302 orr.w r3, r3, #2 802e6ca: e219 b.n 802eb00 pcb->nrtx = 0; } /* Call the user specified function to call when sucessfully * connected. */ TCP_EVENT_CONNECTED(pcb, ERR_OK, err); 802e6cc: 2200 movs r2, #0 802e6ce: 6920 ldr r0, [r4, #16] 802e6d0: 4621 mov r1, r4 802e6d2: 4798 blx r3 if (err == ERR_ABRT) { 802e6d4: 300a adds r0, #10 802e6d6: d1f5 bne.n 802e6c4 802e6d8: e1ab b.n 802ea32 return ERR_ABRT; } tcp_ack_now(pcb); } /* received ACK? possibly a half-open connection */ else if (flags & TCP_ACK) { 802e6da: 4b4f ldr r3, [pc, #316] ; (802e818 ) 802e6dc: 781b ldrb r3, [r3, #0] 802e6de: f003 0310 and.w r3, r3, #16 802e6e2: b2db uxtb r3, r3 802e6e4: 2b00 cmp r3, #0 802e6e6: f000 820c beq.w 802eb02 /* send a RST to bring the other side in a non-synchronized state. */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), tcphdr->dest, tcphdr->src); 802e6ea: 4b4f ldr r3, [pc, #316] ; (802e828 ) tcp_ack_now(pcb); } /* received ACK? possibly a half-open connection */ else if (flags & TCP_ACK) { /* send a RST to bring the other side in a non-synchronized state. */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), 802e6ec: 4a48 ldr r2, [pc, #288] ; (802e810 ) tcphdr->dest, tcphdr->src); 802e6ee: 681b ldr r3, [r3, #0] tcp_ack_now(pcb); } /* received ACK? possibly a half-open connection */ else if (flags & TCP_ACK) { /* send a RST to bring the other side in a non-synchronized state. */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), 802e6f0: 8811 ldrh r1, [r2, #0] 802e6f2: 8858 ldrh r0, [r3, #2] 802e6f4: 4a4a ldr r2, [pc, #296] ; (802e820 ) 802e6f6: 6812 ldr r2, [r2, #0] 802e6f8: 9000 str r0, [sp, #0] 802e6fa: 881b ldrh r3, [r3, #0] 802e6fc: 9301 str r3, [sp, #4] 802e6fe: 4b47 ldr r3, [pc, #284] ; (802e81c ) 802e700: 6818 ldr r0, [r3, #0] 802e702: e03a b.n 802e77a tcphdr->dest, tcphdr->src); } break; case SYN_RCVD: if (flags & TCP_ACK) { 802e704: 4b44 ldr r3, [pc, #272] ; (802e818 ) 802e706: 781b ldrb r3, [r3, #0] 802e708: f003 0210 and.w r2, r3, #16 802e70c: b2d2 uxtb r2, r2 802e70e: 2a00 cmp r2, #0 802e710: d039 beq.n 802e786 /* expected ACK number? */ if (TCP_SEQ_BETWEEN(ackno, pcb->lastack+1, pcb->snd_nxt)) { 802e712: 4b42 ldr r3, [pc, #264] ; (802e81c ) 802e714: 6818 ldr r0, [r3, #0] 802e716: 6ca3 ldr r3, [r4, #72] ; 0x48 802e718: 43db mvns r3, r3 802e71a: 42c3 cmn r3, r0 802e71c: d423 bmi.n 802e766 802e71e: 6d23 ldr r3, [r4, #80] ; 0x50 802e720: 1ac3 subs r3, r0, r3 802e722: 2b00 cmp r3, #0 802e724: dc1f bgt.n 802e766 u16_t old_cwnd; pcb->state = ESTABLISHED; 802e726: 2304 movs r3, #4 802e728: 7623 strb r3, [r4, #24] LWIP_DEBUGF(TCP_DEBUG, ("TCP connection established %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest)); #if LWIP_CALLBACK_API LWIP_ASSERT("pcb->accept != NULL", pcb->accept != NULL); #endif /* Call the accept function. */ TCP_EVENT_ACCEPT(pcb, ERR_OK, err); 802e72a: 6963 ldr r3, [r4, #20] 802e72c: b903 cbnz r3, 802e730 802e72e: e147 b.n 802e9c0 802e730: 6920 ldr r0, [r4, #16] 802e732: 4621 mov r1, r4 802e734: 2200 movs r2, #0 802e736: 4798 blx r3 if (err != ERR_OK) { 802e738: b118 cbz r0, 802e742 /* If the accept function returns with an error, we abort * the connection. */ /* Already aborted? */ if (err != ERR_ABRT) { 802e73a: 300a adds r0, #10 802e73c: f040 8140 bne.w 802e9c0 802e740: e177 b.n 802ea32 return ERR_ABRT; } old_cwnd = pcb->cwnd; /* If there was any data contained within this ACK, * we'd better pass it on to the application as well. */ tcp_receive(pcb); 802e742: 4620 mov r0, r4 if (err != ERR_ABRT) { tcp_abort(pcb); } return ERR_ABRT; } old_cwnd = pcb->cwnd; 802e744: f8b4 504c ldrh.w r5, [r4, #76] ; 0x4c /* If there was any data contained within this ACK, * we'd better pass it on to the application as well. */ tcp_receive(pcb); 802e748: f7ff fb54 bl 802ddf4 /* Prevent ACK for SYN to generate a sent event */ if (pcb->acked != 0) { 802e74c: f8b4 3064 ldrh.w r3, [r4, #100] ; 0x64 802e750: b113 cbz r3, 802e758 pcb->acked--; 802e752: 3b01 subs r3, #1 802e754: f8a4 3064 strh.w r3, [r4, #100] ; 0x64 } pcb->cwnd = ((old_cwnd == 1) ? (pcb->mss * 2) : pcb->mss); 802e758: 8ee3 ldrh r3, [r4, #54] ; 0x36 802e75a: 2d01 cmp r5, #1 802e75c: bf08 it eq 802e75e: 005b lsleq r3, r3, #1 802e760: f8a4 304c strh.w r3, [r4, #76] ; 0x4c 802e764: e023 b.n 802e7ae pcb->state = CLOSE_WAIT; } } else { /* incorrect ACK number, send RST */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), tcphdr->dest, tcphdr->src); 802e766: 4b30 ldr r3, [pc, #192] ; (802e828 ) tcp_ack_now(pcb); pcb->state = CLOSE_WAIT; } } else { /* incorrect ACK number, send RST */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), 802e768: 4a29 ldr r2, [pc, #164] ; (802e810 ) tcphdr->dest, tcphdr->src); 802e76a: 681b ldr r3, [r3, #0] tcp_ack_now(pcb); pcb->state = CLOSE_WAIT; } } else { /* incorrect ACK number, send RST */ tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), 802e76c: 8811 ldrh r1, [r2, #0] 802e76e: 885d ldrh r5, [r3, #2] 802e770: 4a2b ldr r2, [pc, #172] ; (802e820 ) 802e772: 6812 ldr r2, [r2, #0] 802e774: 9500 str r5, [sp, #0] 802e776: 881b ldrh r3, [r3, #0] 802e778: 9301 str r3, [sp, #4] 802e77a: 1889 adds r1, r1, r2 802e77c: 4b2b ldr r3, [pc, #172] ; (802e82c ) 802e77e: 4a2c ldr r2, [pc, #176] ; (802e830 ) 802e780: f000 fdb6 bl 802f2f0 802e784: e1bd b.n 802eb02 tcphdr->dest, tcphdr->src); } } else if ((flags & TCP_SYN) && (seqno == pcb->rcv_nxt - 1)) { 802e786: f003 0302 and.w r3, r3, #2 802e78a: b2db uxtb r3, r3 802e78c: 2b00 cmp r3, #0 802e78e: f000 81b8 beq.w 802eb02 802e792: 4a23 ldr r2, [pc, #140] ; (802e820 ) 802e794: 6aa3 ldr r3, [r4, #40] ; 0x28 802e796: 6812 ldr r2, [r2, #0] 802e798: 3b01 subs r3, #1 802e79a: 429a cmp r2, r3 802e79c: f040 81b1 bne.w 802eb02 /* Looks like another copy of the SYN - retransmit our SYN-ACK */ tcp_rexmit(pcb); 802e7a0: 4620 mov r0, r4 802e7a2: f000 fe03 bl 802f3ac 802e7a6: e1ac b.n 802eb02 } break; case CLOSE_WAIT: /* FALLTHROUGH */ case ESTABLISHED: tcp_receive(pcb); 802e7a8: 4620 mov r0, r4 802e7aa: f7ff fb23 bl 802ddf4 if (recv_flags & TF_GOT_FIN) { /* passive close */ 802e7ae: 4b21 ldr r3, [pc, #132] ; (802e834 ) 802e7b0: 781b ldrb r3, [r3, #0] 802e7b2: f003 0320 and.w r3, r3, #32 802e7b6: b2db uxtb r3, r3 802e7b8: 2b00 cmp r3, #0 802e7ba: f000 81a2 beq.w 802eb02 tcp_ack_now(pcb); 802e7be: 7fa3 ldrb r3, [r4, #30] 802e7c0: f043 0302 orr.w r3, r3, #2 802e7c4: 77a3 strb r3, [r4, #30] pcb->state = CLOSE_WAIT; 802e7c6: 2307 movs r3, #7 802e7c8: e053 b.n 802e872 } break; case FIN_WAIT_1: tcp_receive(pcb); 802e7ca: 4620 mov r0, r4 802e7cc: f7ff fb12 bl 802ddf4 if (recv_flags & TF_GOT_FIN) { 802e7d0: 4b18 ldr r3, [pc, #96] ; (802e834 ) 802e7d2: 781a ldrb r2, [r3, #0] 802e7d4: 4b10 ldr r3, [pc, #64] ; (802e818 ) if ((flags & TCP_ACK) && (ackno == pcb->snd_nxt)) { 802e7d6: 781b ldrb r3, [r3, #0] pcb->state = CLOSE_WAIT; } break; case FIN_WAIT_1: tcp_receive(pcb); if (recv_flags & TF_GOT_FIN) { 802e7d8: f002 0220 and.w r2, r2, #32 if ((flags & TCP_ACK) && (ackno == pcb->snd_nxt)) { 802e7dc: f003 0310 and.w r3, r3, #16 pcb->state = CLOSE_WAIT; } break; case FIN_WAIT_1: tcp_receive(pcb); if (recv_flags & TF_GOT_FIN) { 802e7e0: b2d2 uxtb r2, r2 if ((flags & TCP_ACK) && (ackno == pcb->snd_nxt)) { 802e7e2: b2db uxtb r3, r3 pcb->state = CLOSE_WAIT; } break; case FIN_WAIT_1: tcp_receive(pcb); if (recv_flags & TF_GOT_FIN) { 802e7e4: 2a00 cmp r2, #0 802e7e6: d03a beq.n 802e85e if ((flags & TCP_ACK) && (ackno == pcb->snd_nxt)) { 802e7e8: 2b00 cmp r3, #0 802e7ea: d032 beq.n 802e852 802e7ec: 4b0b ldr r3, [pc, #44] ; (802e81c ) 802e7ee: 681a ldr r2, [r3, #0] 802e7f0: 6d23 ldr r3, [r4, #80] ; 0x50 802e7f2: 429a cmp r2, r3 802e7f4: d12d bne.n 802e852 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: FIN_WAIT_1 %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest)); tcp_ack_now(pcb); 802e7f6: 7fa3 ldrb r3, [r4, #30] 802e7f8: f043 0302 orr.w r3, r3, #2 802e7fc: 77a3 strb r3, [r4, #30] tcp_pcb_purge(pcb); 802e7fe: 4620 mov r0, r4 802e800: f7fe feea bl 802d5d8 TCP_RMV_ACTIVE(pcb); 802e804: 4a0c ldr r2, [pc, #48] ; (802e838 ) 802e806: 6813 ldr r3, [r2, #0] 802e808: 42a3 cmp r3, r4 802e80a: d117 bne.n 802e83c 802e80c: e06d b.n 802e8ea 802e80e: bf00 nop 802e810: 2000e0f8 .word 0x2000e0f8 802e814: 20010ff4 .word 0x20010ff4 802e818: 2000e100 .word 0x2000e100 802e81c: 2000e0fc .word 0x2000e0fc 802e820: 2000e0f4 .word 0x2000e0f4 802e824: 20010fe0 .word 0x20010fe0 802e828: 2000e0f0 .word 0x2000e0f0 802e82c: 20010ffc .word 0x20010ffc 802e830: 20011004 .word 0x20011004 802e834: 2000e101 .word 0x2000e101 802e838: 20010fdc .word 0x20010fdc 802e83c: 4a8e ldr r2, [pc, #568] ; (802ea78 ) 802e83e: 6013 str r3, [r2, #0] 802e840: e004 b.n 802e84c 802e842: 68d9 ldr r1, [r3, #12] 802e844: 42a1 cmp r1, r4 802e846: d100 bne.n 802e84a 802e848: e057 b.n 802e8fa 802e84a: 460b mov r3, r1 802e84c: 2b00 cmp r3, #0 802e84e: d1f8 bne.n 802e842 802e850: e05a b.n 802e908 pcb->state = TIME_WAIT; TCP_REG(&tcp_tw_pcbs, pcb); } else { tcp_ack_now(pcb); 802e852: 7fa3 ldrb r3, [r4, #30] 802e854: f043 0302 orr.w r3, r3, #2 802e858: 77a3 strb r3, [r4, #30] pcb->state = CLOSING; 802e85a: 2308 movs r3, #8 802e85c: e009 b.n 802e872 } } else if ((flags & TCP_ACK) && (ackno == pcb->snd_nxt)) { 802e85e: 2b00 cmp r3, #0 802e860: f000 814f beq.w 802eb02 802e864: 4b85 ldr r3, [pc, #532] ; (802ea7c ) 802e866: 681a ldr r2, [r3, #0] 802e868: 6d23 ldr r3, [r4, #80] ; 0x50 802e86a: 429a cmp r2, r3 802e86c: f040 8149 bne.w 802eb02 pcb->state = FIN_WAIT_2; 802e870: 2306 movs r3, #6 802e872: 7623 strb r3, [r4, #24] 802e874: e145 b.n 802eb02 } break; case FIN_WAIT_2: tcp_receive(pcb); 802e876: 4620 mov r0, r4 802e878: f7ff fabc bl 802ddf4 if (recv_flags & TF_GOT_FIN) { 802e87c: 4b80 ldr r3, [pc, #512] ; (802ea80 ) 802e87e: 781b ldrb r3, [r3, #0] 802e880: f003 0320 and.w r3, r3, #32 802e884: b2db uxtb r3, r3 802e886: 2b00 cmp r3, #0 802e888: f000 813b beq.w 802eb02 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: FIN_WAIT_2 %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest)); tcp_ack_now(pcb); 802e88c: 7fa3 ldrb r3, [r4, #30] 802e88e: f043 0302 orr.w r3, r3, #2 802e892: 77a3 strb r3, [r4, #30] tcp_pcb_purge(pcb); 802e894: 4620 mov r0, r4 802e896: f7fe fe9f bl 802d5d8 TCP_RMV_ACTIVE(pcb); 802e89a: 4a7a ldr r2, [pc, #488] ; (802ea84 ) 802e89c: 6813 ldr r3, [r2, #0] 802e89e: 42a3 cmp r3, r4 802e8a0: d100 bne.n 802e8a4 802e8a2: e022 b.n 802e8ea 802e8a4: 4a74 ldr r2, [pc, #464] ; (802ea78 ) 802e8a6: 6013 str r3, [r2, #0] 802e8a8: e004 b.n 802e8b4 802e8aa: 68d9 ldr r1, [r3, #12] 802e8ac: 42a1 cmp r1, r4 802e8ae: d100 bne.n 802e8b2 802e8b0: e023 b.n 802e8fa 802e8b2: 460b mov r3, r1 802e8b4: 2b00 cmp r3, #0 802e8b6: d1f8 bne.n 802e8aa 802e8b8: e026 b.n 802e908 pcb->state = TIME_WAIT; TCP_REG(&tcp_tw_pcbs, pcb); } break; case CLOSING: tcp_receive(pcb); 802e8ba: 4620 mov r0, r4 802e8bc: f7ff fa9a bl 802ddf4 if (flags & TCP_ACK && ackno == pcb->snd_nxt) { 802e8c0: 4b71 ldr r3, [pc, #452] ; (802ea88 ) 802e8c2: 781b ldrb r3, [r3, #0] 802e8c4: f003 0310 and.w r3, r3, #16 802e8c8: b2db uxtb r3, r3 802e8ca: 2b00 cmp r3, #0 802e8cc: f000 8119 beq.w 802eb02 802e8d0: 4b6a ldr r3, [pc, #424] ; (802ea7c ) 802e8d2: 681a ldr r2, [r3, #0] 802e8d4: 6d23 ldr r3, [r4, #80] ; 0x50 802e8d6: 429a cmp r2, r3 802e8d8: f040 8113 bne.w 802eb02 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: CLOSING %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest)); tcp_pcb_purge(pcb); 802e8dc: 4620 mov r0, r4 802e8de: f7fe fe7b bl 802d5d8 TCP_RMV_ACTIVE(pcb); 802e8e2: 4a68 ldr r2, [pc, #416] ; (802ea84 ) 802e8e4: 6813 ldr r3, [r2, #0] 802e8e6: 42a3 cmp r3, r4 802e8e8: d101 bne.n 802e8ee 802e8ea: 68e3 ldr r3, [r4, #12] 802e8ec: e00c b.n 802e908 802e8ee: 4a62 ldr r2, [pc, #392] ; (802ea78 ) 802e8f0: 6013 str r3, [r2, #0] 802e8f2: e007 b.n 802e904 802e8f4: 68d9 ldr r1, [r3, #12] 802e8f6: 42a1 cmp r1, r4 802e8f8: d103 bne.n 802e902 802e8fa: 6013 str r3, [r2, #0] 802e8fc: 68e2 ldr r2, [r4, #12] 802e8fe: 60da str r2, [r3, #12] 802e900: e003 b.n 802e90a 802e902: 460b mov r3, r1 802e904: 2b00 cmp r3, #0 802e906: d1f5 bne.n 802e8f4 802e908: 6013 str r3, [r2, #0] 802e90a: 4b60 ldr r3, [pc, #384] ; (802ea8c ) 802e90c: 2201 movs r2, #1 802e90e: 701a strb r2, [r3, #0] pcb->state = TIME_WAIT; 802e910: 230a movs r3, #10 802e912: 7623 strb r3, [r4, #24] TCP_REG(&tcp_tw_pcbs, pcb); 802e914: 4b5e ldr r3, [pc, #376] ; (802ea90 ) 802e916: 681a ldr r2, [r3, #0] 802e918: 601c str r4, [r3, #0] 802e91a: 60e2 str r2, [r4, #12] 802e91c: f000 fe82 bl 802f624 802e920: e0ef b.n 802eb02 } break; case LAST_ACK: tcp_receive(pcb); 802e922: 4620 mov r0, r4 802e924: f7ff fa66 bl 802ddf4 if (flags & TCP_ACK && ackno == pcb->snd_nxt) { 802e928: 4b57 ldr r3, [pc, #348] ; (802ea88 ) 802e92a: 781b ldrb r3, [r3, #0] 802e92c: f003 0310 and.w r3, r3, #16 802e930: b2db uxtb r3, r3 802e932: 2b00 cmp r3, #0 802e934: f000 80e5 beq.w 802eb02 802e938: 4b50 ldr r3, [pc, #320] ; (802ea7c ) 802e93a: 681a ldr r2, [r3, #0] 802e93c: 6d23 ldr r3, [r4, #80] ; 0x50 802e93e: 429a cmp r2, r3 802e940: f040 80df bne.w 802eb02 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: LAST_ACK %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest)); /* bugfix #21699: don't set pcb->state to CLOSED here or we risk leaking segments */ recv_flags |= TF_CLOSED; 802e944: 4b4e ldr r3, [pc, #312] ; (802ea80 ) 802e946: 781a ldrb r2, [r3, #0] 802e948: f042 0210 orr.w r2, r2, #16 802e94c: 701a strb r2, [r3, #0] 802e94e: e0d8 b.n 802eb02 if (recv_flags & TF_RESET) { /* TF_RESET means that the connection was reset by the other end. We then call the error callback to inform the application that the connection is dead before we deallocate the PCB. */ TCP_EVENT_ERR(pcb->errf, pcb->callback_arg, ERR_RST); 802e950: f8d4 3088 ldr.w r3, [r4, #136] ; 0x88 802e954: b19b cbz r3, 802e97e 802e956: 6920 ldr r0, [r4, #16] 802e958: f06f 010a mvn.w r1, #10 802e95c: e00e b.n 802e97c tcp_pcb_remove(&tcp_active_pcbs, pcb); memp_free(MEMP_TCP_PCB, pcb); } else if (recv_flags & TF_CLOSED) { 802e95e: f003 0310 and.w r3, r3, #16 802e962: b2db uxtb r3, r3 802e964: b1a3 cbz r3, 802e990 /* The connection has been closed and we will deallocate the PCB. */ if (!(pcb->flags & TF_RXCLOSED)) { 802e966: 7fa3 ldrb r3, [r4, #30] 802e968: f003 0310 and.w r3, r3, #16 802e96c: b2db uxtb r3, r3 802e96e: b933 cbnz r3, 802e97e /* Connection closed although the application has only shut down the tx side: call the PCB's err callback and indicate the closure to ensure the application doesn't continue using the PCB. */ TCP_EVENT_ERR(pcb->errf, pcb->callback_arg, ERR_CLSD); 802e970: f8d4 3088 ldr.w r3, [r4, #136] ; 0x88 802e974: b11b cbz r3, 802e97e 802e976: 6920 ldr r0, [r4, #16] 802e978: f06f 010b mvn.w r1, #11 802e97c: 4798 blx r3 } tcp_pcb_remove(&tcp_active_pcbs, pcb); 802e97e: 4621 mov r1, r4 802e980: 4840 ldr r0, [pc, #256] ; (802ea84 ) 802e982: f7fe ff91 bl 802d8a8 memp_free(MEMP_TCP_PCB, pcb); 802e986: 2002 movs r0, #2 802e988: 4621 mov r1, r4 802e98a: f7fe fa47 bl 802ce1c 802e98e: e050 b.n 802ea32 } else { err = ERR_OK; /* If the application has registered a "sent" function to be called when new send buffer space is available, we call it now. */ if (pcb->acked > 0) { 802e990: f8b4 2064 ldrh.w r2, [r4, #100] ; 0x64 802e994: b91a cbnz r2, 802e99e if (err == ERR_ABRT) { goto aborted; } } if (recv_data != NULL) { 802e996: 4b3f ldr r3, [pc, #252] ; (802ea94 ) 802e998: 681a ldr r2, [r3, #0] 802e99a: b94a cbnz r2, 802e9b0 802e99c: e026 b.n 802e9ec err = ERR_OK; /* If the application has registered a "sent" function to be called when new send buffer space is available, we call it now. */ if (pcb->acked > 0) { TCP_EVENT_SENT(pcb, pcb->acked, err); 802e99e: 6fa3 ldr r3, [r4, #120] ; 0x78 802e9a0: 2b00 cmp r3, #0 802e9a2: d0f8 beq.n 802e996 802e9a4: 6920 ldr r0, [r4, #16] 802e9a6: 4621 mov r1, r4 802e9a8: 4798 blx r3 if (err == ERR_ABRT) { 802e9aa: 300a adds r0, #10 802e9ac: d1f3 bne.n 802e996 802e9ae: e040 b.n 802ea32 } } if (recv_data != NULL) { LWIP_ASSERT("pcb->refused_data == NULL", pcb->refused_data == NULL); if (pcb->flags & TF_RXCLOSED) { 802e9b0: 7fa3 ldrb r3, [r4, #30] 802e9b2: f003 0310 and.w r3, r3, #16 802e9b6: b2db uxtb r3, r3 802e9b8: b133 cbz r3, 802e9c8 /* received data although already closed -> abort (send RST) to notify the remote host that not all data has been processed */ pbuf_free(recv_data); 802e9ba: 4610 mov r0, r2 802e9bc: f7fe fb38 bl 802d030 tcp_abort(pcb); 802e9c0: 4620 mov r0, r4 802e9c2: f7fe ffe5 bl 802d990 goto aborted; 802e9c6: e034 b.n 802ea32 } /* Notify application that data has been received. */ TCP_EVENT_RECV(pcb, recv_data, ERR_OK, err); 802e9c8: 6fe5 ldr r5, [r4, #124] ; 0x7c 802e9ca: b11d cbz r5, 802e9d4 802e9cc: 6920 ldr r0, [r4, #16] 802e9ce: 4621 mov r1, r4 802e9d0: 47a8 blx r5 802e9d2: e004 b.n 802e9de 802e9d4: 4628 mov r0, r5 802e9d6: 4621 mov r1, r4 802e9d8: 462b mov r3, r5 802e9da: f7ff f895 bl 802db08 if (err == ERR_ABRT) { 802e9de: b243 sxtb r3, r0 802e9e0: 330a adds r3, #10 802e9e2: d026 beq.n 802ea32 goto aborted; } /* If the upper layer can't receive this data, store it */ if (err != ERR_OK) { 802e9e4: b110 cbz r0, 802e9ec pcb->refused_data = recv_data; 802e9e6: 4b2b ldr r3, [pc, #172] ; (802ea94 ) 802e9e8: 681b ldr r3, [r3, #0] 802e9ea: 6763 str r3, [r4, #116] ; 0x74 } } /* If a FIN segment was received, we call the callback function with a NULL buffer to indicate EOF. */ if (recv_flags & TF_GOT_FIN) { 802e9ec: 4b24 ldr r3, [pc, #144] ; (802ea80 ) 802e9ee: 781b ldrb r3, [r3, #0] 802e9f0: f003 0320 and.w r3, r3, #32 802e9f4: b2db uxtb r3, r3 802e9f6: b1b3 cbz r3, 802ea26 if (pcb->refused_data != NULL) { 802e9f8: 6f63 ldr r3, [r4, #116] ; 0x74 802e9fa: b123 cbz r3, 802ea06 /* Delay this if we have refused data. */ pcb->refused_data->flags |= PBUF_FLAG_TCP_FIN; 802e9fc: 7b5a ldrb r2, [r3, #13] 802e9fe: f042 0220 orr.w r2, r2, #32 802ea02: 735a strb r2, [r3, #13] 802ea04: e00f b.n 802ea26 } else { /* correct rcv_wnd as the application won't call tcp_recved() for the FIN's seqno */ if (pcb->rcv_wnd != TCP_WND) { 802ea06: 8da3 ldrh r3, [r4, #44] ; 0x2c 802ea08: f241 62d0 movw r2, #5840 ; 0x16d0 802ea0c: 4293 cmp r3, r2 802ea0e: d001 beq.n 802ea14 pcb->rcv_wnd++; 802ea10: 3301 adds r3, #1 802ea12: 85a3 strh r3, [r4, #44] ; 0x2c } TCP_EVENT_CLOSED(pcb, err); 802ea14: 6fe5 ldr r5, [r4, #124] ; 0x7c 802ea16: b135 cbz r5, 802ea26 802ea18: 2200 movs r2, #0 802ea1a: 6920 ldr r0, [r4, #16] 802ea1c: 4621 mov r1, r4 802ea1e: 4613 mov r3, r2 802ea20: 47a8 blx r5 if (err == ERR_ABRT) { 802ea22: 300a adds r0, #10 802ea24: d005 beq.n 802ea32 goto aborted; } } } tcp_input_pcb = NULL; 802ea26: 4b1c ldr r3, [pc, #112] ; (802ea98 ) 802ea28: 2200 movs r2, #0 /* Try to send something out. */ tcp_output(pcb); 802ea2a: 4620 mov r0, r4 goto aborted; } } } tcp_input_pcb = NULL; 802ea2c: 601a str r2, [r3, #0] /* Try to send something out. */ tcp_output(pcb); 802ea2e: f000 fb3b bl 802f0a8 } } /* Jump target if pcb has been aborted in a callback (by calling tcp_abort()). Below this line, 'pcb' may not be dereferenced! */ aborted: tcp_input_pcb = NULL; 802ea32: 4b19 ldr r3, [pc, #100] ; (802ea98 ) recv_data = NULL; /* give up our reference to inseg.p */ if (inseg.p != NULL) 802ea34: 4d19 ldr r5, [pc, #100] ; (802ea9c ) } } /* Jump target if pcb has been aborted in a callback (by calling tcp_abort()). Below this line, 'pcb' may not be dereferenced! */ aborted: tcp_input_pcb = NULL; 802ea36: 2400 movs r4, #0 802ea38: 601c str r4, [r3, #0] recv_data = NULL; /* give up our reference to inseg.p */ if (inseg.p != NULL) 802ea3a: 6868 ldr r0, [r5, #4] } /* Jump target if pcb has been aborted in a callback (by calling tcp_abort()). Below this line, 'pcb' may not be dereferenced! */ aborted: tcp_input_pcb = NULL; recv_data = NULL; 802ea3c: 4b15 ldr r3, [pc, #84] ; (802ea94 ) 802ea3e: 601c str r4, [r3, #0] /* give up our reference to inseg.p */ if (inseg.p != NULL) 802ea40: 2800 cmp r0, #0 802ea42: d067 beq.n 802eb14 { pbuf_free(inseg.p); 802ea44: f7fe faf4 bl 802d030 inseg.p = NULL; 802ea48: 606c str r4, [r5, #4] 802ea4a: e063 b.n 802eb14 if (!(TCPH_FLAGS(tcphdr) & TCP_RST)) { TCP_STATS_INC(tcp.proterr); TCP_STATS_INC(tcp.drop); tcp_rst(ackno, seqno + tcplen, ip_current_dest_addr(), ip_current_src_addr(), tcphdr->dest, tcphdr->src); 802ea4c: 4b14 ldr r3, [pc, #80] ; (802eaa0 ) sender. */ LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_input: no PCB match found, resetting.\n")); if (!(TCPH_FLAGS(tcphdr) & TCP_RST)) { TCP_STATS_INC(tcp.proterr); TCP_STATS_INC(tcp.drop); tcp_rst(ackno, seqno + tcplen, 802ea4e: 4a15 ldr r2, [pc, #84] ; (802eaa4 ) ip_current_dest_addr(), ip_current_src_addr(), tcphdr->dest, tcphdr->src); 802ea50: 681b ldr r3, [r3, #0] sender. */ LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_input: no PCB match found, resetting.\n")); if (!(TCPH_FLAGS(tcphdr) & TCP_RST)) { TCP_STATS_INC(tcp.proterr); TCP_STATS_INC(tcp.drop); tcp_rst(ackno, seqno + tcplen, 802ea52: 8811 ldrh r1, [r2, #0] 802ea54: 8858 ldrh r0, [r3, #2] 802ea56: 4a14 ldr r2, [pc, #80] ; (802eaa8 ) 802ea58: 6812 ldr r2, [r2, #0] 802ea5a: 9000 str r0, [sp, #0] 802ea5c: 881b ldrh r3, [r3, #0] 802ea5e: 9301 str r3, [sp, #4] 802ea60: 4b06 ldr r3, [pc, #24] ; (802ea7c ) 802ea62: 1889 adds r1, r1, r2 802ea64: 6818 ldr r0, [r3, #0] 802ea66: e517 b.n 802e498 LWIP_ASSERT("tcp_input: tcp_pcbs_sane()", tcp_pcbs_sane()); PERF_STOP("tcp_input"); return; dropped: TCP_STATS_INC(tcp.drop); snmp_inc_tcpinerrs(); 802ea68: f003 f8d2 bl 8031c10 pbuf_free(p); 802ea6c: 4630 mov r0, r6 } 802ea6e: b003 add sp, #12 802ea70: e8bd 4ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} PERF_STOP("tcp_input"); return; dropped: TCP_STATS_INC(tcp.drop); snmp_inc_tcpinerrs(); pbuf_free(p); 802ea74: f7fe badc b.w 802d030 802ea78: 20010fe8 .word 0x20010fe8 802ea7c: 2000e0fc .word 0x2000e0fc 802ea80: 2000e101 .word 0x2000e101 802ea84: 20010fdc .word 0x20010fdc 802ea88: 2000e100 .word 0x2000e100 802ea8c: 20010fd8 .word 0x20010fd8 802ea90: 20010ff0 .word 0x20010ff0 802ea94: 2000e104 .word 0x2000e104 802ea98: 20010ff4 .word 0x20010ff4 802ea9c: 2000e10c .word 0x2000e10c 802eaa0: 2000e0f0 .word 0x2000e0f0 802eaa4: 2000e0f8 .word 0x2000e0f8 802eaa8: 2000e0f4 .word 0x2000e0f4 } if (pcb == NULL) { /* If it did not go to an active connection, we check the connections in the TIME-WAIT state. */ for(pcb = tcp_tw_pcbs; pcb != NULL; pcb = pcb->next) { 802eaac: 4b1b ldr r3, [pc, #108] ; (802eb1c ) 802eaae: 681b ldr r3, [r3, #0] 802eab0: e4bf b.n 802e432 tcp_debug_print_state(pcb->state); #endif /* TCP_DEBUG */ #endif /* TCP_INPUT_DEBUG */ /* Set up a tcp_seg structure. */ inseg.next = NULL; 802eab2: 4b1b ldr r3, [pc, #108] ; (802eb20 ) 802eab4: 2100 movs r1, #0 802eab6: 6019 str r1, [r3, #0] inseg.len = p->tot_len; 802eab8: f8a3 8008 strh.w r8, [r3, #8] inseg.p = p; 802eabc: 605e str r6, [r3, #4] inseg.tcphdr = tcphdr; 802eabe: 60df str r7, [r3, #12] recv_data = NULL; 802eac0: 4b18 ldr r3, [pc, #96] ; (802eb24 ) recv_flags = 0; if (flags & TCP_PSH) { 802eac2: f002 0208 and.w r2, r2, #8 inseg.next = NULL; inseg.len = p->tot_len; inseg.p = p; inseg.tcphdr = tcphdr; recv_data = NULL; 802eac6: 6019 str r1, [r3, #0] recv_flags = 0; 802eac8: 4b17 ldr r3, [pc, #92] ; (802eb28 ) if (flags & TCP_PSH) { 802eaca: b2d2 uxtb r2, r2 inseg.len = p->tot_len; inseg.p = p; inseg.tcphdr = tcphdr; recv_data = NULL; recv_flags = 0; 802eacc: 7019 strb r1, [r3, #0] if (flags & TCP_PSH) { 802eace: 2a00 cmp r2, #0 802ead0: f47f ad52 bne.w 802e578 802ead4: e554 b.n 802e580 #endif /* SO_REUSE */ if (lpcb != NULL) { /* Move this PCB to the front of the list so that subsequent lookups will be faster (we exploit locality in TCP segment arrivals). */ if (prev != NULL) { 802ead6: 2b00 cmp r3, #0 802ead8: f47f acc4 bne.w 802e464 802eadc: e4c7 b.n 802e46e } else { /* If no matching PCB was found, send a TCP RST (reset) to the sender. */ LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_input: no PCB match found, resetting.\n")); if (!(TCPH_FLAGS(tcphdr) & TCP_RST)) { 802eade: 89b8 ldrh r0, [r7, #12] 802eae0: f7fd f96d bl 802bdbe 802eae4: f000 0004 and.w r0, r0, #4 802eae8: b280 uxth r0, r0 802eaea: 2800 cmp r0, #0 802eaec: d1be bne.n 802ea6c 802eaee: e7ad b.n 802ea4c } if (acceptable) { LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_process: Connection RESET\n")); LWIP_ASSERT("tcp_input: pcb->state != CLOSED", pcb->state != CLOSED); recv_flags |= TF_RESET; 802eaf0: 4b0d ldr r3, [pc, #52] ; (802eb28 ) 802eaf2: 781a ldrb r2, [r3, #0] 802eaf4: f042 0208 orr.w r2, r2, #8 802eaf8: 701a strb r2, [r3, #0] pcb->flags &= ~TF_ACK_DELAY; 802eafa: 7fa3 ldrb r3, [r4, #30] 802eafc: f023 0301 bic.w r3, r3, #1 802eb00: 77a3 strb r3, [r4, #30] tcp_input_pcb = pcb; err = tcp_process(pcb); /* A return value of ERR_ABRT means that tcp_abort() was called and that the pcb has been freed. If so, we don't do anything. */ if (err != ERR_ABRT) { if (recv_flags & TF_RESET) { 802eb02: 4b09 ldr r3, [pc, #36] ; (802eb28 ) 802eb04: 781b ldrb r3, [r3, #0] 802eb06: f003 0208 and.w r2, r3, #8 802eb0a: b2d2 uxtb r2, r2 802eb0c: 2a00 cmp r2, #0 802eb0e: f47f af1f bne.w 802e950 802eb12: e724 b.n 802e95e return; dropped: TCP_STATS_INC(tcp.drop); snmp_inc_tcpinerrs(); pbuf_free(p); } 802eb14: b003 add sp, #12 802eb16: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802eb1a: bf00 nop 802eb1c: 20010ff0 .word 0x20010ff0 802eb20: 2000e10c .word 0x2000e10c 802eb24: 2000e104 .word 0x2000e104 802eb28: 2000e101 .word 0x2000e101 0802eb2c : #if TCP_OVERSIZE static struct pbuf * tcp_pbuf_prealloc(pbuf_layer layer, u16_t length, u16_t max_length, u16_t *oversize, struct tcp_pcb *pcb, u8_t apiflags, u8_t first_seg) { 802eb2c: b570 push {r4, r5, r6, lr} LWIP_UNUSED_ARG(apiflags); LWIP_UNUSED_ARG(first_seg); /* always create MSS-sized pbufs */ alloc = max_length; #else /* LWIP_NETIF_TX_SINGLE_PBUF */ if (length < max_length) { 802eb2e: 4291 cmp r1, r2 #if TCP_OVERSIZE static struct pbuf * tcp_pbuf_prealloc(pbuf_layer layer, u16_t length, u16_t max_length, u16_t *oversize, struct tcp_pcb *pcb, u8_t apiflags, u8_t first_seg) { 802eb30: 460c mov r4, r1 802eb32: 461e mov r6, r3 802eb34: 9d04 ldr r5, [sp, #16] LWIP_UNUSED_ARG(apiflags); LWIP_UNUSED_ARG(first_seg); /* always create MSS-sized pbufs */ alloc = max_length; #else /* LWIP_NETIF_TX_SINGLE_PBUF */ if (length < max_length) { 802eb36: d21a bcs.n 802eb6e * * Did the user set TCP_WRITE_FLAG_MORE? * * Will the Nagle algorithm defer transmission of this segment? */ if ((apiflags & TCP_WRITE_FLAG_MORE) || 802eb38: f89d 3014 ldrb.w r3, [sp, #20] 802eb3c: f003 0302 and.w r3, r3, #2 802eb40: b2db uxtb r3, r3 802eb42: b95b cbnz r3, 802eb5c (!(pcb->flags & TF_NODELAY) && 802eb44: 7fab ldrb r3, [r5, #30] * * Did the user set TCP_WRITE_FLAG_MORE? * * Will the Nagle algorithm defer transmission of this segment? */ if ((apiflags & TCP_WRITE_FLAG_MORE) || 802eb46: f003 0340 and.w r3, r3, #64 ; 0x40 802eb4a: b2db uxtb r3, r3 802eb4c: b97b cbnz r3, 802eb6e (!(pcb->flags & TF_NODELAY) && 802eb4e: f89d 3018 ldrb.w r3, [sp, #24] 802eb52: b11b cbz r3, 802eb5c (!first_seg || 802eb54: 6ee9 ldr r1, [r5, #108] ; 0x6c 802eb56: b909 cbnz r1, 802eb5c pcb->unsent != NULL || 802eb58: 6f2b ldr r3, [r5, #112] ; 0x70 802eb5a: b143 cbz r3, 802eb6e pcb->unacked != NULL))) { alloc = LWIP_MIN(max_length, LWIP_MEM_ALIGN_SIZE(length + TCP_OVERSIZE)); 802eb5c: f204 51b7 addw r1, r4, #1463 ; 0x5b7 802eb60: f021 0103 bic.w r1, r1, #3 802eb64: 4291 cmp r1, r2 802eb66: bfa8 it ge 802eb68: 4611 movge r1, r2 802eb6a: b289 uxth r1, r1 802eb6c: e000 b.n 802eb70 * Will the Nagle algorithm defer transmission of this segment? */ if ((apiflags & TCP_WRITE_FLAG_MORE) || (!(pcb->flags & TF_NODELAY) && (!first_seg || pcb->unsent != NULL || 802eb6e: 4621 mov r1, r4 pcb->unacked != NULL))) { alloc = LWIP_MIN(max_length, LWIP_MEM_ALIGN_SIZE(length + TCP_OVERSIZE)); } } #endif /* LWIP_NETIF_TX_SINGLE_PBUF */ p = pbuf_alloc(layer, alloc, PBUF_RAM); 802eb70: 2200 movs r2, #0 802eb72: f7fe faaa bl 802d0ca if (p == NULL) { 802eb76: b120 cbz r0, 802eb82 return NULL; } LWIP_ASSERT("need unchained pbuf", p->next == NULL); *oversize = p->len - length; 802eb78: 8943 ldrh r3, [r0, #10] 802eb7a: 1b1b subs r3, r3, r4 802eb7c: 8033 strh r3, [r6, #0] /* trim p->len to the currently used size */ p->len = p->tot_len = length; 802eb7e: 8104 strh r4, [r0, #8] 802eb80: 8144 strh r4, [r0, #10] return p; } 802eb82: bd70 pop {r4, r5, r6, pc} 0802eb84 : * The TCP header is filled in except ackno and wnd. * p is freed on failure. */ static struct tcp_seg * tcp_create_segment(struct tcp_pcb *pcb, struct pbuf *p, u8_t flags, u32_t seqno, u8_t optflags) { 802eb84: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 802eb88: f89d 6020 ldrb.w r6, [sp, #32] struct tcp_seg *seg; u8_t optlen = LWIP_TCP_OPT_LENGTH(optflags); 802eb8c: f006 0702 and.w r7, r6, #2 802eb90: f016 0f01 tst.w r6, #1 802eb94: b2ff uxtb r7, r7 * The TCP header is filled in except ackno and wnd. * p is freed on failure. */ static struct tcp_seg * tcp_create_segment(struct tcp_pcb *pcb, struct pbuf *p, u8_t flags, u32_t seqno, u8_t optflags) { 802eb96: 4680 mov r8, r0 802eb98: 469a mov sl, r3 struct tcp_seg *seg; u8_t optlen = LWIP_TCP_OPT_LENGTH(optflags); 802eb9a: bf0c ite eq 802eb9c: 2300 moveq r3, #0 802eb9e: 2304 movne r3, #4 802eba0: 2f00 cmp r7, #0 802eba2: bf14 ite ne 802eba4: 270c movne r7, #12 802eba6: 2700 moveq r7, #0 if ((seg = (struct tcp_seg *)memp_malloc(MEMP_TCP_SEG)) == NULL) { 802eba8: 2004 movs r0, #4 * The TCP header is filled in except ackno and wnd. * p is freed on failure. */ static struct tcp_seg * tcp_create_segment(struct tcp_pcb *pcb, struct pbuf *p, u8_t flags, u32_t seqno, u8_t optflags) { 802ebaa: 460d mov r5, r1 802ebac: 4691 mov r9, r2 struct tcp_seg *seg; u8_t optlen = LWIP_TCP_OPT_LENGTH(optflags); 802ebae: 18ff adds r7, r7, r3 if ((seg = (struct tcp_seg *)memp_malloc(MEMP_TCP_SEG)) == NULL) { 802ebb0: f7fe f91e bl 802cdf0 802ebb4: 4604 mov r4, r0 802ebb6: b918 cbnz r0, 802ebc0 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_create_segment: no memory.\n")); pbuf_free(p); 802ebb8: 4628 mov r0, r5 802ebba: f7fe fa39 bl 802d030 return NULL; 802ebbe: e030 b.n 802ec22 } seg->flags = optflags; 802ebc0: 7286 strb r6, [r0, #10] seg->next = NULL; seg->p = p; seg->len = p->tot_len - optlen; 802ebc2: 892b ldrh r3, [r5, #8] pbuf_free(p); return NULL; } seg->flags = optflags; seg->next = NULL; seg->p = p; 802ebc4: 6045 str r5, [r0, #4] seg->len = p->tot_len - optlen; 802ebc6: 1bdb subs r3, r3, r7 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_create_segment: no memory.\n")); pbuf_free(p); return NULL; } seg->flags = optflags; seg->next = NULL; 802ebc8: 2600 movs r6, #0 802ebca: 6006 str r6, [r0, #0] seg->p = p; seg->len = p->tot_len - optlen; 802ebcc: 8103 strh r3, [r0, #8] LWIP_ASSERT("invalid optflags passed: TF_SEG_DATA_CHECKSUMMED", (optflags & TF_SEG_DATA_CHECKSUMMED) == 0); #endif /* TCP_CHECKSUM_ON_COPY */ /* build TCP header */ if (pbuf_header(p, TCP_HLEN)) { 802ebce: 2114 movs r1, #20 802ebd0: 4628 mov r0, r5 802ebd2: f7fe fa02 bl 802cfda 802ebd6: 4605 mov r5, r0 802ebd8: b120 cbz r0, 802ebe4 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_create_segment: no room for TCP header in pbuf.\n")); TCP_STATS_INC(tcp.err); tcp_seg_free(seg); 802ebda: 4620 mov r0, r4 802ebdc: f7fe fcd5 bl 802d58a return NULL; 802ebe0: 4634 mov r4, r6 802ebe2: e01e b.n 802ec22 } seg->tcphdr = (struct tcp_hdr *)seg->p->payload; 802ebe4: 6863 ldr r3, [r4, #4] seg->tcphdr->src = htons(pcb->local_port); 802ebe6: f8b8 001a ldrh.w r0, [r8, #26] LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_create_segment: no room for TCP header in pbuf.\n")); TCP_STATS_INC(tcp.err); tcp_seg_free(seg); return NULL; } seg->tcphdr = (struct tcp_hdr *)seg->p->payload; 802ebea: 685e ldr r6, [r3, #4] 802ebec: 60e6 str r6, [r4, #12] seg->tcphdr->src = htons(pcb->local_port); 802ebee: f7fd f8e1 bl 802bdb4 802ebf2: 8030 strh r0, [r6, #0] seg->tcphdr->dest = htons(pcb->remote_port); 802ebf4: f8b8 001c ldrh.w r0, [r8, #28] 802ebf8: 68e6 ldr r6, [r4, #12] 802ebfa: f7fd f8db bl 802bdb4 802ebfe: 8070 strh r0, [r6, #2] seg->tcphdr->seqno = htonl(seqno); 802ec00: 4650 mov r0, sl 802ec02: 68e6 ldr r6, [r4, #12] 802ec04: f7fd f8e0 bl 802bdc8 /* ackno is set in tcp_output */ TCPH_HDRLEN_FLAGS_SET(seg->tcphdr, (5 + optlen / 4), flags); 802ec08: 02bf lsls r7, r7, #10 return NULL; } seg->tcphdr = (struct tcp_hdr *)seg->p->payload; seg->tcphdr->src = htons(pcb->local_port); seg->tcphdr->dest = htons(pcb->remote_port); seg->tcphdr->seqno = htonl(seqno); 802ec0a: 6070 str r0, [r6, #4] /* ackno is set in tcp_output */ TCPH_HDRLEN_FLAGS_SET(seg->tcphdr, (5 + optlen / 4), flags); 802ec0c: f507 40a0 add.w r0, r7, #20480 ; 0x5000 802ec10: ea40 0009 orr.w r0, r0, r9 802ec14: 68e6 ldr r6, [r4, #12] 802ec16: f7fd f8cd bl 802bdb4 802ec1a: 81b0 strh r0, [r6, #12] /* wnd and chksum are set in tcp_output */ seg->tcphdr->urgp = 0; 802ec1c: 68e3 ldr r3, [r4, #12] 802ec1e: 749d strb r5, [r3, #18] 802ec20: 74dd strb r5, [r3, #19] return seg; } 802ec22: 4620 mov r0, r4 802ec24: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 0802ec28 : static struct pbuf * tcp_output_alloc_header(struct tcp_pcb *pcb, u16_t optlen, u16_t datalen, u32_t seqno_be /* already in network byte order */) { struct tcp_hdr *tcphdr; struct pbuf *p = pbuf_alloc(PBUF_IP, TCP_HLEN + optlen + datalen, PBUF_RAM); 802ec28: 3114 adds r1, #20 * @param datalen length of tcp data to reserve in pbuf * @param seqno_be seqno in network byte order (big-endian) * @return pbuf with p->payload being the tcp_hdr */ static struct pbuf * tcp_output_alloc_header(struct tcp_pcb *pcb, u16_t optlen, u16_t datalen, 802ec2a: b5f8 push {r3, r4, r5, r6, r7, lr} u32_t seqno_be /* already in network byte order */) { struct tcp_hdr *tcphdr; struct pbuf *p = pbuf_alloc(PBUF_IP, TCP_HLEN + optlen + datalen, PBUF_RAM); 802ec2c: b289 uxth r1, r1 * @param datalen length of tcp data to reserve in pbuf * @param seqno_be seqno in network byte order (big-endian) * @return pbuf with p->payload being the tcp_hdr */ static struct pbuf * tcp_output_alloc_header(struct tcp_pcb *pcb, u16_t optlen, u16_t datalen, 802ec2e: 4605 mov r5, r0 802ec30: 4617 mov r7, r2 u32_t seqno_be /* already in network byte order */) { struct tcp_hdr *tcphdr; struct pbuf *p = pbuf_alloc(PBUF_IP, TCP_HLEN + optlen + datalen, PBUF_RAM); 802ec32: 2001 movs r0, #1 802ec34: 2200 movs r2, #0 802ec36: f7fe fa48 bl 802d0ca if (p != NULL) { 802ec3a: 4606 mov r6, r0 802ec3c: b1f8 cbz r0, 802ec7e LWIP_ASSERT("check that first pbuf can hold struct tcp_hdr", (p->len >= TCP_HLEN + optlen)); tcphdr = (struct tcp_hdr *)p->payload; 802ec3e: 6844 ldr r4, [r0, #4] tcphdr->src = htons(pcb->local_port); 802ec40: 8b68 ldrh r0, [r5, #26] 802ec42: f7fd f8b7 bl 802bdb4 802ec46: 8020 strh r0, [r4, #0] tcphdr->dest = htons(pcb->remote_port); 802ec48: 8ba8 ldrh r0, [r5, #28] 802ec4a: f7fd f8b3 bl 802bdb4 tcphdr->seqno = seqno_be; 802ec4e: 6067 str r7, [r4, #4] if (p != NULL) { LWIP_ASSERT("check that first pbuf can hold struct tcp_hdr", (p->len >= TCP_HLEN + optlen)); tcphdr = (struct tcp_hdr *)p->payload; tcphdr->src = htons(pcb->local_port); tcphdr->dest = htons(pcb->remote_port); 802ec50: 8060 strh r0, [r4, #2] tcphdr->seqno = seqno_be; tcphdr->ackno = htonl(pcb->rcv_nxt); 802ec52: 6aa8 ldr r0, [r5, #40] ; 0x28 802ec54: f7fd f8b8 bl 802bdc8 802ec58: 60a0 str r0, [r4, #8] TCPH_HDRLEN_FLAGS_SET(tcphdr, (5 + optlen / 4), TCP_ACK); 802ec5a: f245 0010 movw r0, #20496 ; 0x5010 802ec5e: f7fd f8a9 bl 802bdb4 802ec62: 81a0 strh r0, [r4, #12] tcphdr->wnd = htons(pcb->rcv_ann_wnd); 802ec64: 8de8 ldrh r0, [r5, #46] ; 0x2e 802ec66: f7fd f8a5 bl 802bdb4 tcphdr->chksum = 0; 802ec6a: 2300 movs r3, #0 tcphdr->src = htons(pcb->local_port); tcphdr->dest = htons(pcb->remote_port); tcphdr->seqno = seqno_be; tcphdr->ackno = htonl(pcb->rcv_nxt); TCPH_HDRLEN_FLAGS_SET(tcphdr, (5 + optlen / 4), TCP_ACK); tcphdr->wnd = htons(pcb->rcv_ann_wnd); 802ec6c: 81e0 strh r0, [r4, #14] tcphdr->chksum = 0; 802ec6e: 7423 strb r3, [r4, #16] 802ec70: 7463 strb r3, [r4, #17] tcphdr->urgp = 0; 802ec72: 74a3 strb r3, [r4, #18] 802ec74: 74e3 strb r3, [r4, #19] /* If we're sending a packet, update the announced right window edge */ pcb->rcv_ann_right_edge = pcb->rcv_nxt + pcb->rcv_ann_wnd; 802ec76: 8dea ldrh r2, [r5, #46] ; 0x2e 802ec78: 6aab ldr r3, [r5, #40] ; 0x28 802ec7a: 18d3 adds r3, r2, r3 802ec7c: 632b str r3, [r5, #48] ; 0x30 } return p; } 802ec7e: 4630 mov r0, r6 802ec80: bdf8 pop {r3, r4, r5, r6, r7, pc} 0802ec82 : * - TCP_WRITE_FLAG_MORE (0x02) for TCP connection, PSH flag will be set on last segment sent, * @return ERR_OK if enqueued, another err_t on error */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { 802ec82: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 802ec86: b08f sub sp, #60 ; 0x3c 802ec88: 4691 mov r9, r2 802ec8a: 9307 str r3, [sp, #28] u16_t pos = 0; /* position in 'arg' data */ u16_t queuelen; u8_t optlen = 0; u8_t optflags = 0; #if TCP_OVERSIZE u16_t oversize = 0; 802ec8c: 2300 movs r3, #0 802ec8e: f8ad 3036 strh.w r3, [sp, #54] ; 0x36 * - TCP_WRITE_FLAG_MORE (0x02) for TCP connection, PSH flag will be set on last segment sent, * @return ERR_OK if enqueued, another err_t on error */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { 802ec92: 4604 mov r4, r0 u8_t concat_chksum_swapped = 0; u16_t concat_chksummed = 0; #endif /* TCP_CHECKSUM_ON_COPY */ err_t err; /* don't allocate segments bigger than half the maximum window we ever received */ u16_t mss_local = LWIP_MIN(pcb->mss, pcb->snd_wnd_max/2); 802ec94: f8b0 2062 ldrh.w r2, [r0, #98] ; 0x62 802ec98: 8ec3 ldrh r3, [r0, #54] ; 0x36 apiflags |= TCP_WRITE_FLAG_COPY; #endif /* LWIP_NETIF_TX_SINGLE_PBUF */ LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_write(pcb=%p, data=%p, len=%"U16_F", apiflags=%"U16_F")\n", (void *)pcb, arg, len, (u16_t)apiflags)); LWIP_ERROR("tcp_write: arg == NULL (programmer violates API)", 802ec9a: 9106 str r1, [sp, #24] 802ec9c: 2900 cmp r1, #0 802ec9e: f000 8168 beq.w 802ef72 802eca2: 7e01 ldrb r1, [r0, #24] 802eca4: 2907 cmp r1, #7 802eca6: f200 8166 bhi.w 802ef76 802ecaa: f990 1018 ldrsb.w r1, [r0, #24] 802ecae: f04f 5064 mov.w r0, #956301312 ; 0x39000000 802ecb2: 4088 lsls r0, r1 802ecb4: f140 815f bpl.w 802ef76 (pcb->state != CLOSE_WAIT) && (pcb->state != SYN_SENT) && (pcb->state != SYN_RCVD)) { LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_STATE | LWIP_DBG_LEVEL_SEVERE, ("tcp_write() called in invalid state\n")); return ERR_CONN; } else if (len == 0) { 802ecb8: f1b9 0f00 cmp.w r9, #0 802ecbc: d00d beq.n 802ecda return ERR_OK; } /* fail on too much data */ if (len > pcb->snd_buf) { 802ecbe: f8b4 1066 ldrh.w r1, [r4, #102] ; 0x66 802ecc2: 4549 cmp r1, r9 802ecc4: d200 bcs.n 802ecc8 802ecc6: e003 b.n 802ecd0 LWIP_DEBUGF(TCP_QLEN_DEBUG, ("tcp_write: queuelen: %"U16_F"\n", (u16_t)pcb->snd_queuelen)); /* If total number of pbufs on the unsent/unacked queues exceeds the * configured maximum, return an error */ /* check for configured max queuelen and possible overflow */ if ((pcb->snd_queuelen >= TCP_SND_QUEUELEN) || (pcb->snd_queuelen > TCP_SNDQUEUELEN_OVERFLOW)) { 802ecc8: f8b4 1068 ldrh.w r1, [r4, #104] ; 0x68 802eccc: 2947 cmp r1, #71 ; 0x47 802ecce: d904 bls.n 802ecda LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 3, ("tcp_write: too long queue %"U16_F" (max %"U16_F")\n", pcb->snd_queuelen, TCP_SND_QUEUELEN)); TCP_STATS_INC(tcp.memerr); pcb->flags |= TF_NAGLEMEMERR; 802ecd0: 7fa3 ldrb r3, [r4, #30] 802ecd2: f063 037f orn r3, r3, #127 ; 0x7f 802ecd6: 77a3 strb r3, [r4, #30] 802ecd8: e151 b.n 802ef7e u8_t concat_chksum_swapped = 0; u16_t concat_chksummed = 0; #endif /* TCP_CHECKSUM_ON_COPY */ err_t err; /* don't allocate segments bigger than half the maximum window we ever received */ u16_t mss_local = LWIP_MIN(pcb->mss, pcb->snd_wnd_max/2); 802ecda: 0852 lsrs r2, r2, #1 * * pos records progress as data is segmented. */ /* Find the tail of the unsent queue. */ if (pcb->unsent != NULL) { 802ecdc: 6ee6 ldr r6, [r4, #108] ; 0x6c err = tcp_write_checks(pcb, len); if (err != ERR_OK) { return err; } queuelen = pcb->snd_queuelen; 802ecde: f8b4 b068 ldrh.w fp, [r4, #104] ; 0x68 u8_t concat_chksum_swapped = 0; u16_t concat_chksummed = 0; #endif /* TCP_CHECKSUM_ON_COPY */ err_t err; /* don't allocate segments bigger than half the maximum window we ever received */ u16_t mss_local = LWIP_MIN(pcb->mss, pcb->snd_wnd_max/2); 802ece2: 429a cmp r2, r3 802ece4: bf28 it cs 802ece6: 461a movcs r2, r3 802ece8: 920a str r2, [sp, #40] ; 0x28 * * pos records progress as data is segmented. */ /* Find the tail of the unsent queue. */ if (pcb->unsent != NULL) { 802ecea: b90e cbnz r6, 802ecf0 802ecec: e066 b.n 802edbc u16_t space; u16_t unsent_optlen; /* @todo: this could be sped up by keeping last_unsent in the pcb */ for (last_unsent = pcb->unsent; last_unsent->next != NULL; last_unsent = last_unsent->next); 802ecee: 461e mov r6, r3 if (pcb->unsent != NULL) { u16_t space; u16_t unsent_optlen; /* @todo: this could be sped up by keeping last_unsent in the pcb */ for (last_unsent = pcb->unsent; last_unsent->next != NULL; 802ecf0: 6833 ldr r3, [r6, #0] 802ecf2: 2b00 cmp r3, #0 802ecf4: d1fb bne.n 802ecee last_unsent = last_unsent->next); /* Usable space at the end of the last unsent segment */ unsent_optlen = LWIP_TCP_OPT_LENGTH(last_unsent->flags); 802ecf6: 7ab3 ldrb r3, [r6, #10] space = mss_local - (last_unsent->len + unsent_optlen); 802ecf8: 8937 ldrh r7, [r6, #8] /* @todo: this could be sped up by keeping last_unsent in the pcb */ for (last_unsent = pcb->unsent; last_unsent->next != NULL; last_unsent = last_unsent->next); /* Usable space at the end of the last unsent segment */ unsent_optlen = LWIP_TCP_OPT_LENGTH(last_unsent->flags); 802ecfa: 980a ldr r0, [sp, #40] ; 0x28 #if TCP_OVERSIZE_DBGCHECK /* check that pcb->unsent_oversize matches last_unsent->unsent_oversize */ LWIP_ASSERT("unsent_oversize mismatch (pcb vs. last_unsent)", pcb->unsent_oversize == last_unsent->oversize_left); #endif /* TCP_OVERSIZE_DBGCHECK */ oversize = pcb->unsent_oversize; 802ecfc: f8b4 506a ldrh.w r5, [r4, #106] ; 0x6a /* @todo: this could be sped up by keeping last_unsent in the pcb */ for (last_unsent = pcb->unsent; last_unsent->next != NULL; last_unsent = last_unsent->next); /* Usable space at the end of the last unsent segment */ unsent_optlen = LWIP_TCP_OPT_LENGTH(last_unsent->flags); 802ed00: f013 0f01 tst.w r3, #1 802ed04: f003 0302 and.w r3, r3, #2 802ed08: bf0c ite eq 802ed0a: 2100 moveq r1, #0 802ed0c: 2104 movne r1, #4 802ed0e: b2db uxtb r3, r3 802ed10: 1bc2 subs r2, r0, r7 802ed12: 2b00 cmp r3, #0 802ed14: bf14 ite ne 802ed16: 230c movne r3, #12 802ed18: 2300 moveq r3, #0 space = mss_local - (last_unsent->len + unsent_optlen); 802ed1a: 1a52 subs r2, r2, r1 802ed1c: 1ad2 subs r2, r2, r3 802ed1e: b292 uxth r2, r2 /* check that pcb->unsent_oversize matches last_unsent->unsent_oversize */ LWIP_ASSERT("unsent_oversize mismatch (pcb vs. last_unsent)", pcb->unsent_oversize == last_unsent->oversize_left); #endif /* TCP_OVERSIZE_DBGCHECK */ oversize = pcb->unsent_oversize; if (oversize > 0) { 802ed20: b91d cbnz r5, 802ed2a #if TCP_OVERSIZE_DBGCHECK /* check that pcb->unsent_oversize matches last_unsent->unsent_oversize */ LWIP_ASSERT("unsent_oversize mismatch (pcb vs. last_unsent)", pcb->unsent_oversize == last_unsent->oversize_left); #endif /* TCP_OVERSIZE_DBGCHECK */ oversize = pcb->unsent_oversize; 802ed22: f8ad 5036 strh.w r5, [sp, #54] ; 0x36 */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { struct pbuf *concat_p = NULL; struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; 802ed26: 462b mov r3, r5 802ed28: e00a b.n 802ed40 #endif /* TCP_OVERSIZE_DBGCHECK */ oversize = pcb->unsent_oversize; if (oversize > 0) { LWIP_ASSERT("inconsistent oversize vs. space", oversize_used <= space); seg = last_unsent; oversize_used = oversize < len ? oversize : len; 802ed2a: 45a9 cmp r9, r5 802ed2c: bf34 ite cc 802ed2e: 464b movcc r3, r9 802ed30: 462b movcs r3, r5 pos += oversize_used; oversize -= oversize_used; 802ed32: 1aed subs r5, r5, r3 space -= oversize_used; 802ed34: 1ad2 subs r2, r2, r3 if (oversize > 0) { LWIP_ASSERT("inconsistent oversize vs. space", oversize_used <= space); seg = last_unsent; oversize_used = oversize < len ? oversize : len; pos += oversize_used; oversize -= oversize_used; 802ed36: f8ad 5036 strh.w r5, [sp, #54] ; 0x36 space -= oversize_used; 802ed3a: b292 uxth r2, r2 oversize = pcb->unsent_oversize; if (oversize > 0) { LWIP_ASSERT("inconsistent oversize vs. space", oversize_used <= space); seg = last_unsent; oversize_used = oversize < len ? oversize : len; pos += oversize_used; 802ed3c: 461d mov r5, r3 oversize -= oversize_used; space -= oversize_used; 802ed3e: 4633 mov r3, r6 * * We don't extend segments containing SYN/FIN flags or options * (len==0). The new pbuf is kept in concat_p and pbuf_cat'ed at * the end. */ if ((pos < len) && (space > 0) && (last_unsent->len > 0)) { 802ed40: 454d cmp r5, r9 802ed42: d23f bcs.n 802edc4 802ed44: 2a00 cmp r2, #0 802ed46: d03d beq.n 802edc4 802ed48: 2f00 cmp r7, #0 802ed4a: d03e beq.n 802edca seg = last_unsent; /* Create a pbuf with a copy or reference to seglen bytes. We * can use PBUF_RAW here since the data appears in the middle of * a segment. A header will never be prepended. */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802ed4c: 9907 ldr r1, [sp, #28] * We don't extend segments containing SYN/FIN flags or options * (len==0). The new pbuf is kept in concat_p and pbuf_cat'ed at * the end. */ if ((pos < len) && (space > 0) && (last_unsent->len > 0)) { u16_t seglen = space < len - pos ? space : len - pos; 802ed4e: ebc5 0a09 rsb sl, r5, r9 802ed52: 4592 cmp sl, r2 802ed54: bfa8 it ge 802ed56: 4692 movge sl, r2 seg = last_unsent; /* Create a pbuf with a copy or reference to seglen bytes. We * can use PBUF_RAW here since the data appears in the middle of * a segment. A header will never be prepended. */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802ed58: 07cb lsls r3, r1, #31 * We don't extend segments containing SYN/FIN flags or options * (len==0). The new pbuf is kept in concat_p and pbuf_cat'ed at * the end. */ if ((pos < len) && (space > 0) && (last_unsent->len > 0)) { u16_t seglen = space < len - pos ? space : len - pos; 802ed5a: fa1f f88a uxth.w r8, sl seg = last_unsent; /* Create a pbuf with a copy or reference to seglen bytes. We * can use PBUF_RAW here since the data appears in the middle of * a segment. A header will never be prepended. */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802ed5e: d514 bpl.n 802ed8a /* Data is copied */ if ((concat_p = tcp_pbuf_prealloc(PBUF_RAW, seglen, space, &oversize, pcb, apiflags, 1)) == NULL) { 802ed60: 2301 movs r3, #1 802ed62: 9101 str r1, [sp, #4] 802ed64: 9302 str r3, [sp, #8] 802ed66: 9400 str r4, [sp, #0] 802ed68: 2003 movs r0, #3 802ed6a: 4641 mov r1, r8 802ed6c: f10d 0336 add.w r3, sp, #54 ; 0x36 802ed70: f7ff fedc bl 802eb2c 802ed74: 4607 mov r7, r0 802ed76: 2800 cmp r0, #0 802ed78: f000 80e9 beq.w 802ef4e goto memerr; } #if TCP_OVERSIZE_DBGCHECK last_unsent->oversize_left += oversize; #endif /* TCP_OVERSIZE_DBGCHECK */ TCP_DATA_COPY2(concat_p->payload, (u8_t*)arg + pos, seglen, &concat_chksum, &concat_chksum_swapped); 802ed7c: 9a06 ldr r2, [sp, #24] 802ed7e: 6840 ldr r0, [r0, #4] 802ed80: 1951 adds r1, r2, r5 802ed82: 4642 mov r2, r8 802ed84: f7f2 fde2 bl 802194c 802ed88: e00b b.n 802eda2 #if TCP_CHECKSUM_ON_COPY concat_chksummed += seglen; #endif /* TCP_CHECKSUM_ON_COPY */ } else { /* Data is not copied */ if ((concat_p = pbuf_alloc(PBUF_RAW, seglen, PBUF_ROM)) == NULL) { 802ed8a: 2003 movs r0, #3 802ed8c: 4641 mov r1, r8 802ed8e: 2201 movs r2, #1 802ed90: f7fe f99b bl 802d0ca 802ed94: 4607 mov r7, r0 802ed96: 2800 cmp r0, #0 802ed98: f000 80d9 beq.w 802ef4e tcp_seg_add_chksum(~inet_chksum((u8_t*)arg + pos, seglen), seglen, &concat_chksum, &concat_chksum_swapped); concat_chksummed += seglen; #endif /* TCP_CHECKSUM_ON_COPY */ /* reference the non-volatile payload data */ concat_p->payload = (u8_t*)arg + pos; 802ed9c: 9806 ldr r0, [sp, #24] 802ed9e: 1943 adds r3, r0, r5 802eda0: 607b str r3, [r7, #4] } pos += seglen; queuelen += pbuf_clen(concat_p); 802eda2: 4638 mov r0, r7 802eda4: f7fe fa18 bl 802d1d8 #endif /* TCP_CHECKSUM_ON_COPY */ /* reference the non-volatile payload data */ concat_p->payload = (u8_t*)arg + pos; } pos += seglen; 802eda8: 44a8 add r8, r5 802edaa: fa1f f888 uxth.w r8, r8 queuelen += pbuf_clen(concat_p); 802edae: 4458 add r0, fp 802edb0: 46aa mov sl, r5 802edb2: fa1f fb80 uxth.w fp, r0 #endif /* TCP_CHECKSUM_ON_COPY */ /* reference the non-volatile payload data */ concat_p->payload = (u8_t*)arg + pos; } pos += seglen; 802edb6: 4645 mov r5, r8 queuelen += pbuf_clen(concat_p); 802edb8: 4633 mov r3, r6 802edba: e007 b.n 802edcc u16_t queuelen; u8_t optlen = 0; u8_t optflags = 0; #if TCP_OVERSIZE u16_t oversize = 0; u16_t oversize_used = 0; 802edbc: 46b2 mov sl, r6 err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { struct pbuf *concat_p = NULL; struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; u16_t pos = 0; /* position in 'arg' data */ 802edbe: 4635 mov r5, r6 */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { struct pbuf *concat_p = NULL; struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; 802edc0: 4633 mov r3, r6 802edc2: e000 b.n 802edc6 * * We don't extend segments containing SYN/FIN flags or options * (len==0). The new pbuf is kept in concat_p and pbuf_cat'ed at * the end. */ if ((pos < len) && (space > 0) && (last_unsent->len > 0)) { 802edc4: 46aa mov sl, r5 * @return ERR_OK if enqueued, another err_t on error */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { struct pbuf *concat_p = NULL; 802edc6: 2700 movs r7, #0 802edc8: e000 b.n 802edcc * * We don't extend segments containing SYN/FIN flags or options * (len==0). The new pbuf is kept in concat_p and pbuf_cat'ed at * the end. */ if ((pos < len) && (space > 0) && (last_unsent->len > 0)) { 802edca: 46aa mov sl, r5 #if TCP_CHECKSUM_ON_COPY u16_t chksum = 0; u8_t chksum_swapped = 0; #endif /* TCP_CHECKSUM_ON_COPY */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802edcc: 9907 ldr r1, [sp, #28] seg->chksum_swapped = chksum_swapped; seg->flags |= TF_SEG_DATA_CHECKSUMMED; #endif /* TCP_CHECKSUM_ON_COPY */ /* first segment of to-be-queued data? */ if (queue == NULL) { 802edce: f04f 0800 mov.w r8, #0 #if TCP_CHECKSUM_ON_COPY u16_t chksum = 0; u8_t chksum_swapped = 0; #endif /* TCP_CHECKSUM_ON_COPY */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802edd2: f001 0101 and.w r1, r1, #1 seg->chksum_swapped = chksum_swapped; seg->flags |= TF_SEG_DATA_CHECKSUMMED; #endif /* TCP_CHECKSUM_ON_COPY */ /* first segment of to-be-queued data? */ if (queue == NULL) { 802edd6: f8cd 802c str.w r8, [sp, #44] ; 0x2c #if TCP_CHECKSUM_ON_COPY u16_t chksum = 0; u8_t chksum_swapped = 0; #endif /* TCP_CHECKSUM_ON_COPY */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802edda: 9108 str r1, [sp, #32] 802eddc: e068 b.n 802eeb0 * The new segments are chained together in the local 'queue' * variable, ready to be appended to pcb->unsent. */ while (pos < len) { struct pbuf *p; u16_t left = len - pos; 802edde: ebc5 0309 rsb r3, r5, r9 u16_t max_len = mss_local - optlen; u16_t seglen = left > max_len ? max_len : left; 802ede2: 9a0a ldr r2, [sp, #40] ; 0x28 802ede4: b29b uxth r3, r3 802ede6: 4293 cmp r3, r2 802ede8: bf38 it cc 802edea: 461a movcc r2, r3 #if TCP_CHECKSUM_ON_COPY u16_t chksum = 0; u8_t chksum_swapped = 0; #endif /* TCP_CHECKSUM_ON_COPY */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802edec: 9b08 ldr r3, [sp, #32] */ while (pos < len) { struct pbuf *p; u16_t left = len - pos; u16_t max_len = mss_local - optlen; u16_t seglen = left > max_len ? max_len : left; 802edee: 9209 str r2, [sp, #36] ; 0x24 #if TCP_CHECKSUM_ON_COPY u16_t chksum = 0; u8_t chksum_swapped = 0; #endif /* TCP_CHECKSUM_ON_COPY */ if (apiflags & TCP_WRITE_FLAG_COPY) { 802edf0: b1db cbz r3, 802ee2a /* If copy is set, memory should be allocated and data copied * into pbuf */ if ((p = tcp_pbuf_prealloc(PBUF_TRANSPORT, seglen + optlen, mss_local, &oversize, pcb, apiflags, queue == NULL)) == NULL) { 802edf2: f1d8 0301 rsbs r3, r8, #1 802edf6: 9807 ldr r0, [sp, #28] 802edf8: 9400 str r4, [sp, #0] 802edfa: bf38 it cc 802edfc: 2300 movcc r3, #0 802edfe: 9001 str r0, [sp, #4] 802ee00: 9302 str r3, [sp, #8] 802ee02: 4611 mov r1, r2 802ee04: 2000 movs r0, #0 802ee06: 9a0a ldr r2, [sp, #40] ; 0x28 802ee08: f10d 0336 add.w r3, sp, #54 ; 0x36 802ee0c: f7ff fe8e bl 802eb2c 802ee10: 4684 mov ip, r0 802ee12: 2800 cmp r0, #0 802ee14: f000 809e beq.w 802ef54 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_write : could not allocate memory for pbuf copy size %"U16_F"\n", seglen)); goto memerr; } LWIP_ASSERT("tcp_write: check that first pbuf can hold the complete seglen", (p->len >= seglen)); TCP_DATA_COPY2((char *)p->payload + optlen, (u8_t*)arg + pos, seglen, &chksum, &chksum_swapped); 802ee18: 9a06 ldr r2, [sp, #24] 802ee1a: 6840 ldr r0, [r0, #4] 802ee1c: f8cd c014 str.w ip, [sp, #20] 802ee20: 1951 adds r1, r2, r5 802ee22: 9a09 ldr r2, [sp, #36] ; 0x24 802ee24: f7f2 fd92 bl 802194c 802ee28: e019 b.n 802ee5e */ struct pbuf *p2; #if TCP_OVERSIZE LWIP_ASSERT("oversize == 0", oversize == 0); #endif /* TCP_OVERSIZE */ if ((p2 = pbuf_alloc(PBUF_TRANSPORT, seglen, PBUF_ROM)) == NULL) { 802ee2a: 9808 ldr r0, [sp, #32] 802ee2c: 9909 ldr r1, [sp, #36] ; 0x24 802ee2e: 2201 movs r2, #1 802ee30: f7fe f94b bl 802d0ca 802ee34: 4603 mov r3, r0 802ee36: 2800 cmp r0, #0 802ee38: f000 808c beq.w 802ef54 #if TCP_CHECKSUM_ON_COPY /* calculate the checksum of nocopy-data */ chksum = ~inet_chksum((u8_t*)arg + pos, seglen); #endif /* TCP_CHECKSUM_ON_COPY */ /* reference the non-volatile payload data */ p2->payload = (u8_t*)arg + pos; 802ee3c: 9806 ldr r0, [sp, #24] 802ee3e: 1942 adds r2, r0, r5 /* Second, allocate a pbuf for the headers. */ if ((p = pbuf_alloc(PBUF_TRANSPORT, optlen, PBUF_RAM)) == NULL) { 802ee40: 9808 ldr r0, [sp, #32] #if TCP_CHECKSUM_ON_COPY /* calculate the checksum of nocopy-data */ chksum = ~inet_chksum((u8_t*)arg + pos, seglen); #endif /* TCP_CHECKSUM_ON_COPY */ /* reference the non-volatile payload data */ p2->payload = (u8_t*)arg + pos; 802ee42: 605a str r2, [r3, #4] /* Second, allocate a pbuf for the headers. */ if ((p = pbuf_alloc(PBUF_TRANSPORT, optlen, PBUF_RAM)) == NULL) { 802ee44: 4601 mov r1, r0 802ee46: 4602 mov r2, r0 802ee48: 9305 str r3, [sp, #20] 802ee4a: f7fe f93e bl 802d0ca 802ee4e: 9b05 ldr r3, [sp, #20] 802ee50: b908 cbnz r0, 802ee56 /* If allocation fails, we have to deallocate the data pbuf as * well. */ pbuf_free(p2); 802ee52: 4618 mov r0, r3 802ee54: e013 b.n 802ee7e LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_write: could not allocate memory for header pbuf\n")); goto memerr; } /* Concatenate the headers and data pbufs together. */ pbuf_cat(p/*header*/, p2/*data*/); 802ee56: 4619 mov r1, r3 802ee58: 9005 str r0, [sp, #20] 802ee5a: f7fe f9d3 bl 802d204 802ee5e: f8dd c014 ldr.w ip, [sp, #20] } queuelen += pbuf_clen(p); 802ee62: 4660 mov r0, ip 802ee64: f8cd c014 str.w ip, [sp, #20] 802ee68: f7fe f9b6 bl 802d1d8 802ee6c: 4458 add r0, fp 802ee6e: fa1f fb80 uxth.w fp, r0 /* Now that there are more segments queued, we check again if the * length of the queue exceeds the configured maximum or * overflows. */ if ((queuelen > TCP_SND_QUEUELEN) || (queuelen > TCP_SNDQUEUELEN_OVERFLOW)) { 802ee72: f1bb 0f48 cmp.w fp, #72 ; 0x48 802ee76: f8dd c014 ldr.w ip, [sp, #20] 802ee7a: d903 bls.n 802ee84 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_write: queue too long %"U16_F" (%"U16_F")\n", queuelen, TCP_SND_QUEUELEN)); pbuf_free(p); 802ee7c: 4660 mov r0, ip 802ee7e: f7fe f8d7 bl 802d030 goto memerr; 802ee82: e067 b.n 802ef54 } if ((seg = tcp_create_segment(pcb, p, 0, pcb->snd_lbb + pos, optflags)) == NULL) { 802ee84: 6de3 ldr r3, [r4, #92] ; 0x5c 802ee86: 2200 movs r2, #0 802ee88: 18eb adds r3, r5, r3 802ee8a: 9200 str r2, [sp, #0] 802ee8c: 4620 mov r0, r4 802ee8e: 4661 mov r1, ip 802ee90: f7ff fe78 bl 802eb84 802ee94: 4603 mov r3, r0 802ee96: 2800 cmp r0, #0 802ee98: d05c beq.n 802ef54 seg->chksum_swapped = chksum_swapped; seg->flags |= TF_SEG_DATA_CHECKSUMMED; #endif /* TCP_CHECKSUM_ON_COPY */ /* first segment of to-be-queued data? */ if (queue == NULL) { 802ee9a: f1b8 0f00 cmp.w r8, #0 802ee9e: d002 beq.n 802eea6 queue = seg; } else { /* Attach the segment to the end of the queued segments */ LWIP_ASSERT("prev_seg != NULL", prev_seg != NULL); prev_seg->next = seg; 802eea0: 990b ldr r1, [sp, #44] ; 0x2c 802eea2: 6008 str r0, [r1, #0] 802eea4: e000 b.n 802eea8 seg->chksum_swapped = chksum_swapped; seg->flags |= TF_SEG_DATA_CHECKSUMMED; #endif /* TCP_CHECKSUM_ON_COPY */ /* first segment of to-be-queued data? */ if (queue == NULL) { 802eea6: 4680 mov r8, r0 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_TRACE, ("tcp_write: queueing %"U32_F":%"U32_F"\n", ntohl(seg->tcphdr->seqno), ntohl(seg->tcphdr->seqno) + TCP_TCPLEN(seg))); pos += seglen; 802eea8: 9a09 ldr r2, [sp, #36] ; 0x24 802eeaa: 930b str r3, [sp, #44] ; 0x2c 802eeac: 1955 adds r5, r2, r5 802eeae: b2ad uxth r5, r5 * Phase 3: Create new segments. * * The new segments are chained together in the local 'queue' * variable, ready to be appended to pcb->unsent. */ while (pos < len) { 802eeb0: 454d cmp r5, r9 802eeb2: d394 bcc.n 802edde /* * Phase 1: If data has been added to the preallocated tail of * last_unsent, we update the length fields of the pbuf chain. */ #if TCP_OVERSIZE if (oversize_used > 0) { 802eeb4: f1ba 0f00 cmp.w sl, #0 802eeb8: d019 beq.n 802eeee struct pbuf *p; /* Bump tot_len of whole chain, len of tail */ for (p = last_unsent->p; p; p = p->next) { 802eeba: 6875 ldr r5, [r6, #4] 802eebc: e011 b.n 802eee2 p->tot_len += oversize_used; 802eebe: 892a ldrh r2, [r5, #8] 802eec0: 4452 add r2, sl 802eec2: 812a strh r2, [r5, #8] if (p->next == NULL) { 802eec4: 682a ldr r2, [r5, #0] 802eec6: b95a cbnz r2, 802eee0 TCP_DATA_COPY((char *)p->payload + p->len, arg, oversize_used, last_unsent); 802eec8: 686a ldr r2, [r5, #4] 802eeca: 8968 ldrh r0, [r5, #10] 802eecc: 9906 ldr r1, [sp, #24] 802eece: 9305 str r3, [sp, #20] 802eed0: 1810 adds r0, r2, r0 802eed2: 4652 mov r2, sl 802eed4: f7f2 fd3a bl 802194c p->len += oversize_used; 802eed8: 896a ldrh r2, [r5, #10] 802eeda: 9b05 ldr r3, [sp, #20] 802eedc: 4452 add r2, sl 802eede: 816a strh r2, [r5, #10] */ #if TCP_OVERSIZE if (oversize_used > 0) { struct pbuf *p; /* Bump tot_len of whole chain, len of tail */ for (p = last_unsent->p; p; p = p->next) { 802eee0: 682d ldr r5, [r5, #0] 802eee2: 2d00 cmp r5, #0 802eee4: d1eb bne.n 802eebe if (p->next == NULL) { TCP_DATA_COPY((char *)p->payload + p->len, arg, oversize_used, last_unsent); p->len += oversize_used; } } last_unsent->len += oversize_used; 802eee6: 8932 ldrh r2, [r6, #8] 802eee8: 4492 add sl, r2 802eeea: f8a6 a008 strh.w sl, [r6, #8] LWIP_ASSERT("last_unsent->oversize_left >= oversize_used", last_unsent->oversize_left >= oversize_used); last_unsent->oversize_left -= oversize_used; #endif /* TCP_OVERSIZE_DBGCHECK */ } pcb->unsent_oversize = oversize; 802eeee: f8bd 2036 ldrh.w r2, [sp, #54] ; 0x36 802eef2: f8a4 206a strh.w r2, [r4, #106] ; 0x6a #endif /* TCP_OVERSIZE */ /* * Phase 2: concat_p can be concatenated onto last_unsent->p */ if (concat_p != NULL) { 802eef6: b157 cbz r7, 802ef0e LWIP_ASSERT("tcp_write: cannot concatenate when pcb->unsent is empty", (last_unsent != NULL)); pbuf_cat(last_unsent->p, concat_p); 802eef8: 6870 ldr r0, [r6, #4] 802eefa: 9305 str r3, [sp, #20] 802eefc: 4639 mov r1, r7 802eefe: f7fe f981 bl 802d204 last_unsent->len += concat_p->tot_len; 802ef02: 8939 ldrh r1, [r7, #8] 802ef04: 8932 ldrh r2, [r6, #8] 802ef06: 9b05 ldr r3, [sp, #20] 802ef08: 188a adds r2, r1, r2 802ef0a: 8132 strh r2, [r6, #8] 802ef0c: e003 b.n 802ef16 /* * Phase 3: Append queue to pcb->unsent. Queue may be NULL, but that * is harmless */ if (last_unsent == NULL) { 802ef0e: b916 cbnz r6, 802ef16 pcb->unsent = queue; 802ef10: f8c4 806c str.w r8, [r4, #108] ; 0x6c 802ef14: e001 b.n 802ef1a } else { last_unsent->next = queue; 802ef16: f8c6 8000 str.w r8, [r6] } /* * Finally update the pcb state. */ pcb->snd_lbb += len; 802ef1a: 6de2 ldr r2, [r4, #92] ; 0x5c pcb->snd_buf -= len; pcb->snd_queuelen = queuelen; 802ef1c: f8a4 b068 strh.w fp, [r4, #104] ; 0x68 } /* * Finally update the pcb state. */ pcb->snd_lbb += len; 802ef20: 444a add r2, r9 802ef22: 65e2 str r2, [r4, #92] ; 0x5c pcb->snd_buf -= len; 802ef24: f8b4 2066 ldrh.w r2, [r4, #102] ; 0x66 802ef28: ebc9 0902 rsb r9, r9, r2 802ef2c: f8a4 9066 strh.w r9, [r4, #102] ; 0x66 LWIP_ASSERT("tcp_write: valid queue length", pcb->unacked != NULL || pcb->unsent != NULL); } /* Set the PSH flag in the last segment that we enqueued. */ if (seg != NULL && seg->tcphdr != NULL && ((apiflags & TCP_WRITE_FLAG_MORE)==0)) { 802ef30: b333 cbz r3, 802ef80 802ef32: 68dc ldr r4, [r3, #12] 802ef34: b30c cbz r4, 802ef7a 802ef36: 9b07 ldr r3, [sp, #28] 802ef38: f003 0502 and.w r5, r3, #2 802ef3c: b2ed uxtb r5, r5 802ef3e: b9e5 cbnz r5, 802ef7a TCPH_SET_FLAG(seg->tcphdr, TCP_PSH); 802ef40: 2008 movs r0, #8 802ef42: 89a6 ldrh r6, [r4, #12] 802ef44: f7fc ff36 bl 802bdb4 802ef48: 4330 orrs r0, r6 802ef4a: 81a0 strh r0, [r4, #12] 802ef4c: e015 b.n 802ef7a */ err_t tcp_write(struct tcp_pcb *pcb, const void *arg, u16_t len, u8_t apiflags) { struct pbuf *concat_p = NULL; struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; 802ef4e: f04f 0800 mov.w r8, #0 802ef52: 4647 mov r7, r8 TCPH_SET_FLAG(seg->tcphdr, TCP_PSH); } return ERR_OK; memerr: pcb->flags |= TF_NAGLEMEMERR; 802ef54: 7fa3 ldrb r3, [r4, #30] 802ef56: f063 037f orn r3, r3, #127 ; 0x7f 802ef5a: 77a3 strb r3, [r4, #30] TCP_STATS_INC(tcp.memerr); if (concat_p != NULL) { 802ef5c: b117 cbz r7, 802ef64 pbuf_free(concat_p); 802ef5e: 4638 mov r0, r7 802ef60: f7fe f866 bl 802d030 } if (queue != NULL) { 802ef64: f1b8 0f00 cmp.w r8, #0 802ef68: d009 beq.n 802ef7e tcp_segs_free(queue); 802ef6a: 4640 mov r0, r8 802ef6c: f7fe fb1b bl 802d5a6 802ef70: e005 b.n 802ef7e apiflags |= TCP_WRITE_FLAG_COPY; #endif /* LWIP_NETIF_TX_SINGLE_PBUF */ LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_write(pcb=%p, data=%p, len=%"U16_F", apiflags=%"U16_F")\n", (void *)pcb, arg, len, (u16_t)apiflags)); LWIP_ERROR("tcp_write: arg == NULL (programmer violates API)", 802ef72: 23f2 movs r3, #242 ; 0xf2 802ef74: e004 b.n 802ef80 if ((pcb->state != ESTABLISHED) && (pcb->state != CLOSE_WAIT) && (pcb->state != SYN_SENT) && (pcb->state != SYN_RCVD)) { LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_STATE | LWIP_DBG_LEVEL_SEVERE, ("tcp_write() called in invalid state\n")); return ERR_CONN; 802ef76: 23f3 movs r3, #243 ; 0xf3 802ef78: e002 b.n 802ef80 /* Set the PSH flag in the last segment that we enqueued. */ if (seg != NULL && seg->tcphdr != NULL && ((apiflags & TCP_WRITE_FLAG_MORE)==0)) { TCPH_SET_FLAG(seg->tcphdr, TCP_PSH); } return ERR_OK; 802ef7a: 2300 movs r3, #0 802ef7c: e000 b.n 802ef80 if (pcb->snd_queuelen != 0) { LWIP_ASSERT("tcp_write: valid queue length", pcb->unacked != NULL || pcb->unsent != NULL); } LWIP_DEBUGF(TCP_QLEN_DEBUG | LWIP_DBG_STATE, ("tcp_write: %"S16_F" (with mem err)\n", pcb->snd_queuelen)); return ERR_MEM; 802ef7e: 23ff movs r3, #255 ; 0xff 802ef80: b258 sxtb r0, r3 } 802ef82: b00f add sp, #60 ; 0x3c 802ef84: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 0802ef88 : LWIP_ASSERT("tcp_enqueue_flags: need either TCP_SYN or TCP_FIN in flags (programmer violates API)", (flags & (TCP_SYN | TCP_FIN)) != 0); /* check for configured max queuelen and possible overflow */ if ((pcb->snd_queuelen >= TCP_SND_QUEUELEN) || (pcb->snd_queuelen > TCP_SNDQUEUELEN_OVERFLOW)) { 802ef88: f8b0 3068 ldrh.w r3, [r0, #104] ; 0x68 802ef8c: 2b47 cmp r3, #71 ; 0x47 * @param optdata pointer to TCP options, or NULL. * @param optlen length of TCP options in bytes. */ err_t tcp_enqueue_flags(struct tcp_pcb *pcb, u8_t flags) { 802ef8e: b573 push {r0, r1, r4, r5, r6, lr} 802ef90: 4604 mov r4, r0 802ef92: 460d mov r5, r1 LWIP_ASSERT("tcp_enqueue_flags: need either TCP_SYN or TCP_FIN in flags (programmer violates API)", (flags & (TCP_SYN | TCP_FIN)) != 0); /* check for configured max queuelen and possible overflow */ if ((pcb->snd_queuelen >= TCP_SND_QUEUELEN) || (pcb->snd_queuelen > TCP_SNDQUEUELEN_OVERFLOW)) { 802ef94: d900 bls.n 802ef98 802ef96: e014 b.n 802efc2 /* tcp_enqueue_flags is always called with either SYN or FIN in flags. * We need one available snd_buf byte to do that. * This means we can't send FIN while snd_buf==0. A better fix would be to * not include SYN and FIN sequence numbers in the snd_buf count. */ if (pcb->snd_buf == 0) { 802ef98: f8b0 3066 ldrh.w r3, [r0, #102] ; 0x66 err_t tcp_enqueue_flags(struct tcp_pcb *pcb, u8_t flags) { struct pbuf *p; struct tcp_seg *seg; u8_t optflags = 0; 802ef9c: f3c1 0640 ubfx r6, r1, #1, #1 #if LWIP_TCP_TIMESTAMPS if ((pcb->flags & TF_TIMESTAMP)) { optflags |= TF_SEG_OPTS_TS; } #endif /* LWIP_TCP_TIMESTAMPS */ optlen = LWIP_TCP_OPT_LENGTH(optflags); 802efa0: 00b1 lsls r1, r6, #2 /* tcp_enqueue_flags is always called with either SYN or FIN in flags. * We need one available snd_buf byte to do that. * This means we can't send FIN while snd_buf==0. A better fix would be to * not include SYN and FIN sequence numbers in the snd_buf count. */ if (pcb->snd_buf == 0) { 802efa2: 2b00 cmp r3, #0 802efa4: d038 beq.n 802f018 TCP_STATS_INC(tcp.memerr); return ERR_MEM; } /* Allocate pbuf with room for TCP header + options */ if ((p = pbuf_alloc(PBUF_TRANSPORT, optlen, PBUF_RAM)) == NULL) { 802efa6: 2000 movs r0, #0 802efa8: 4602 mov r2, r0 802efaa: f7fe f88e bl 802d0ca 802efae: 4601 mov r1, r0 802efb0: b900 cbnz r0, 802efb4 802efb2: e006 b.n 802efc2 } LWIP_ASSERT("tcp_enqueue_flags: check that first pbuf can hold optlen", (p->len >= optlen)); /* Allocate memory for tcp_seg, and fill in fields. */ if ((seg = tcp_create_segment(pcb, p, flags, pcb->snd_lbb, optflags)) == NULL) { 802efb4: 9600 str r6, [sp, #0] 802efb6: 4620 mov r0, r4 802efb8: 462a mov r2, r5 802efba: 6de3 ldr r3, [r4, #92] ; 0x5c 802efbc: f7ff fde2 bl 802eb84 802efc0: b920 cbnz r0, 802efcc pcb->flags |= TF_NAGLEMEMERR; 802efc2: 7fa3 ldrb r3, [r4, #30] 802efc4: f063 037f orn r3, r3, #127 ; 0x7f 802efc8: 77a3 strb r3, [r4, #30] 802efca: e025 b.n 802f018 ntohl(seg->tcphdr->seqno), ntohl(seg->tcphdr->seqno) + TCP_TCPLEN(seg), (u16_t)flags)); /* Now append seg to pcb->unsent queue */ if (pcb->unsent == NULL) { 802efcc: 6ee3 ldr r3, [r4, #108] ; 0x6c 802efce: b913 cbnz r3, 802efd6 pcb->unsent = seg; 802efd0: 66e0 str r0, [r4, #108] ; 0x6c 802efd2: e004 b.n 802efde } else { struct tcp_seg *useg; for (useg = pcb->unsent; useg->next != NULL; useg = useg->next); 802efd4: 4613 mov r3, r2 802efd6: 681a ldr r2, [r3, #0] 802efd8: 2a00 cmp r2, #0 802efda: d1fb bne.n 802efd4 useg->next = seg; 802efdc: 6018 str r0, [r3, #0] } #if TCP_OVERSIZE /* The new unsent tail has no space */ pcb->unsent_oversize = 0; 802efde: 2300 movs r3, #0 #endif /* TCP_OVERSIZE */ /* SYN and FIN bump the sequence number */ if ((flags & TCP_SYN) || (flags & TCP_FIN)) { 802efe0: 07a9 lsls r1, r5, #30 for (useg = pcb->unsent; useg->next != NULL; useg = useg->next); useg->next = seg; } #if TCP_OVERSIZE /* The new unsent tail has no space */ pcb->unsent_oversize = 0; 802efe2: f8a4 306a strh.w r3, [r4, #106] ; 0x6a #endif /* TCP_OVERSIZE */ /* SYN and FIN bump the sequence number */ if ((flags & TCP_SYN) || (flags & TCP_FIN)) { 802efe6: d007 beq.n 802eff8 pcb->snd_lbb++; 802efe8: 6de3 ldr r3, [r4, #92] ; 0x5c 802efea: 3301 adds r3, #1 802efec: 65e3 str r3, [r4, #92] ; 0x5c /* optlen does not influence snd_buf */ pcb->snd_buf--; 802efee: f8b4 3066 ldrh.w r3, [r4, #102] ; 0x66 802eff2: 3b01 subs r3, #1 802eff4: f8a4 3066 strh.w r3, [r4, #102] ; 0x66 } if (flags & TCP_FIN) { 802eff8: 07ea lsls r2, r5, #31 802effa: d503 bpl.n 802f004 pcb->flags |= TF_FIN; 802effc: 7fa3 ldrb r3, [r4, #30] 802effe: f043 0320 orr.w r3, r3, #32 802f002: 77a3 strb r3, [r4, #30] } /* update number of segments on the queues */ pcb->snd_queuelen += pbuf_clen(seg->p); 802f004: 6840 ldr r0, [r0, #4] 802f006: f8b4 5068 ldrh.w r5, [r4, #104] ; 0x68 802f00a: f7fe f8e5 bl 802d1d8 802f00e: 1940 adds r0, r0, r5 802f010: f8a4 0068 strh.w r0, [r4, #104] ; 0x68 if (pcb->snd_queuelen != 0) { LWIP_ASSERT("tcp_enqueue_flags: invalid queue length", pcb->unacked != NULL || pcb->unsent != NULL); } return ERR_OK; 802f014: 2000 movs r0, #0 802f016: e000 b.n 802f01a * This means we can't send FIN while snd_buf==0. A better fix would be to * not include SYN and FIN sequence numbers in the snd_buf count. */ if (pcb->snd_buf == 0) { LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 3, ("tcp_enqueue_flags: no send buffer available\n")); TCP_STATS_INC(tcp.memerr); return ERR_MEM; 802f018: 20ff movs r0, #255 ; 0xff LWIP_ASSERT("tcp_enqueue_flags: invalid queue length", pcb->unacked != NULL || pcb->unsent != NULL); } return ERR_OK; } 802f01a: b240 sxtb r0, r0 802f01c: bd7c pop {r2, r3, r4, r5, r6, pc} 0802f01e : * @param pcb the tcp_pcb over which to send a segment * @return ERR_OK if sent, another err_t otherwise */ err_t tcp_send_fin(struct tcp_pcb *pcb) { 802f01e: b5f8 push {r3, r4, r5, r6, r7, lr} /* first, try to add the fin to the last unsent segment */ if (pcb->unsent != NULL) { 802f020: 6ec4 ldr r4, [r0, #108] ; 0x6c * @param pcb the tcp_pcb over which to send a segment * @return ERR_OK if sent, another err_t otherwise */ err_t tcp_send_fin(struct tcp_pcb *pcb) { 802f022: 4605 mov r5, r0 /* first, try to add the fin to the last unsent segment */ if (pcb->unsent != NULL) { 802f024: b90c cbnz r4, 802f02a 802f026: e00a b.n 802f03e struct tcp_seg *last_unsent; for (last_unsent = pcb->unsent; last_unsent->next != NULL; last_unsent = last_unsent->next); 802f028: 461c mov r4, r3 tcp_send_fin(struct tcp_pcb *pcb) { /* first, try to add the fin to the last unsent segment */ if (pcb->unsent != NULL) { struct tcp_seg *last_unsent; for (last_unsent = pcb->unsent; last_unsent->next != NULL; 802f02a: 6823 ldr r3, [r4, #0] 802f02c: 2b00 cmp r3, #0 802f02e: d1fb bne.n 802f028 last_unsent = last_unsent->next); if ((TCPH_FLAGS(last_unsent->tcphdr) & (TCP_SYN | TCP_FIN | TCP_RST)) == 0) { 802f030: 68e3 ldr r3, [r4, #12] 802f032: 8998 ldrh r0, [r3, #12] 802f034: f7fc fec3 bl 802bdbe 802f038: f010 0607 ands.w r6, r0, #7 802f03c: d005 beq.n 802f04a pcb->flags |= TF_FIN; return ERR_OK; } } /* no data, no length, flags, copy=1, no optdata */ return tcp_enqueue_flags(pcb, TCP_FIN); 802f03e: 4628 mov r0, r5 802f040: 2101 movs r1, #1 } 802f042: e8bd 40f8 ldmia.w sp!, {r3, r4, r5, r6, r7, lr} pcb->flags |= TF_FIN; return ERR_OK; } } /* no data, no length, flags, copy=1, no optdata */ return tcp_enqueue_flags(pcb, TCP_FIN); 802f046: f7ff bf9f b.w 802ef88 for (last_unsent = pcb->unsent; last_unsent->next != NULL; last_unsent = last_unsent->next); if ((TCPH_FLAGS(last_unsent->tcphdr) & (TCP_SYN | TCP_FIN | TCP_RST)) == 0) { /* no SYN/FIN/RST flag in the header, we can add the FIN flag */ TCPH_SET_FLAG(last_unsent->tcphdr, TCP_FIN); 802f04a: 68e4 ldr r4, [r4, #12] 802f04c: 2001 movs r0, #1 802f04e: 89a7 ldrh r7, [r4, #12] 802f050: f7fc feb0 bl 802bdb4 802f054: 4338 orrs r0, r7 802f056: 81a0 strh r0, [r4, #12] pcb->flags |= TF_FIN; 802f058: 7fab ldrb r3, [r5, #30] 802f05a: f043 0320 orr.w r3, r3, #32 802f05e: 77ab strb r3, [r5, #30] return ERR_OK; } } /* no data, no length, flags, copy=1, no optdata */ return tcp_enqueue_flags(pcb, TCP_FIN); } 802f060: 4630 mov r0, r6 802f062: bdf8 pop {r3, r4, r5, r6, r7, pc} 0802f064 : * * @param pcb Protocol control block for the TCP connection to send the ACK */ err_t tcp_send_empty_ack(struct tcp_pcb *pcb) { 802f064: b537 push {r0, r1, r2, r4, r5, lr} 802f066: 4604 mov r4, r0 if (pcb->flags & TF_TIMESTAMP) { optlen = LWIP_TCP_OPT_LENGTH(TF_SEG_OPTS_TS); } #endif p = tcp_output_alloc_header(pcb, optlen, 0, htonl(pcb->snd_nxt)); 802f068: 6d00 ldr r0, [r0, #80] ; 0x50 802f06a: f7fc fead bl 802bdc8 802f06e: 2100 movs r1, #0 802f070: 4602 mov r2, r0 802f072: 4620 mov r0, r4 802f074: f7ff fdd8 bl 802ec28 if (p == NULL) { 802f078: 4605 mov r5, r0 802f07a: b188 cbz r0, 802f0a0 } tcphdr = (struct tcp_hdr *)p->payload; LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output: sending ACK for %"U32_F"\n", pcb->rcv_nxt)); /* remove ACK flags from the PCB, as we send an empty ACK now */ pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); 802f07c: 7fa3 ldrb r3, [r4, #30] #endif #if LWIP_NETIF_HWADDRHINT ip_output_hinted(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, 802f07e: 7a62 ldrb r2, [r4, #9] } tcphdr = (struct tcp_hdr *)p->payload; LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output: sending ACK for %"U32_F"\n", pcb->rcv_nxt)); /* remove ACK flags from the PCB, as we send an empty ACK now */ pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); 802f080: f023 0303 bic.w r3, r3, #3 #endif #if LWIP_NETIF_HWADDRHINT ip_output_hinted(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, 802f084: 9200 str r2, [sp, #0] 802f086: 2206 movs r2, #6 } tcphdr = (struct tcp_hdr *)p->payload; LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output: sending ACK for %"U32_F"\n", pcb->rcv_nxt)); /* remove ACK flags from the PCB, as we send an empty ACK now */ pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); 802f088: 77a3 strb r3, [r4, #30] #endif #if LWIP_NETIF_HWADDRHINT ip_output_hinted(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, 802f08a: 9201 str r2, [sp, #4] 802f08c: 7aa3 ldrb r3, [r4, #10] 802f08e: 4621 mov r1, r4 802f090: 1d22 adds r2, r4, #4 802f092: f001 f8ab bl 80301ec IP_PROTO_TCP); #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); 802f096: 4628 mov r0, r5 802f098: f7fd ffca bl 802d030 return ERR_OK; 802f09c: 2000 movs r0, #0 802f09e: e000 b.n 802f0a2 #endif p = tcp_output_alloc_header(pcb, optlen, 0, htonl(pcb->snd_nxt)); if (p == NULL) { LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output: (ACK) could not allocate pbuf\n")); return ERR_BUF; 802f0a0: 20fe movs r0, #254 ; 0xfe IP_PROTO_TCP); #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); return ERR_OK; } 802f0a2: b240 sxtb r0, r0 802f0a4: bd3e pop {r1, r2, r3, r4, r5, pc} 802f0a6: 0000 movs r0, r0 0802f0a8 : /* First, check if we are invoked by the TCP input processing code. If so, we do not output anything. Instead, we rely on the input processing code to call us when input processing is done with. */ if (tcp_input_pcb == pcb) { 802f0a8: 4b8f ldr r3, [pc, #572] ; (802f2e8 ) 802f0aa: 681b ldr r3, [r3, #0] 802f0ac: 4283 cmp r3, r0 * @return ERR_OK if data has been sent or nothing to send * another err_t on error */ err_t tcp_output(struct tcp_pcb *pcb) { 802f0ae: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} 802f0b2: 4604 mov r4, r0 /* First, check if we are invoked by the TCP input processing code. If so, we do not output anything. Instead, we rely on the input processing code to call us when input processing is done with. */ if (tcp_input_pcb == pcb) { 802f0b4: f000 8113 beq.w 802f2de return ERR_OK; } wnd = LWIP_MIN(pcb->snd_wnd, pcb->cwnd); 802f0b8: f8b0 304c ldrh.w r3, [r0, #76] ; 0x4c 802f0bc: f8b0 9060 ldrh.w r9, [r0, #96] ; 0x60 seg = pcb->unsent; 802f0c0: 6ec5 ldr r5, [r0, #108] ; 0x6c with. */ if (tcp_input_pcb == pcb) { return ERR_OK; } wnd = LWIP_MIN(pcb->snd_wnd, pcb->cwnd); 802f0c2: 4599 cmp r9, r3 802f0c4: bf28 it cs 802f0c6: 4699 movcs r9, r3 * because the ->unsent queue is empty or because the window does * not allow it), construct an empty ACK segment and send it. * * If data is to be sent, we will just piggyback the ACK (see below). */ if (pcb->flags & TF_ACK_NOW && 802f0c8: 7f83 ldrb r3, [r0, #30] 802f0ca: f003 0302 and.w r3, r3, #2 802f0ce: b2db uxtb r3, r3 802f0d0: b183 cbz r3, 802f0f4 802f0d2: b92d cbnz r5, 802f0e0 (seg == NULL || ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len > wnd)) { return tcp_send_empty_ack(pcb); 802f0d4: 4620 mov r0, r4 } #endif /* TCP_OVERSIZE */ pcb->flags &= ~TF_NAGLEMEMERR; return ERR_OK; } 802f0d6: b003 add sp, #12 802f0d8: e8bd 4ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} * If data is to be sent, we will just piggyback the ACK (see below). */ if (pcb->flags & TF_ACK_NOW && (seg == NULL || ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len > wnd)) { return tcp_send_empty_ack(pcb); 802f0dc: f7ff bfc2 b.w 802f064 * * If data is to be sent, we will just piggyback the ACK (see below). */ if (pcb->flags & TF_ACK_NOW && (seg == NULL || ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len > wnd)) { 802f0e0: 68eb ldr r3, [r5, #12] 802f0e2: 6858 ldr r0, [r3, #4] 802f0e4: f7fc fe72 bl 802bdcc 802f0e8: 892a ldrh r2, [r5, #8] 802f0ea: 6ca3 ldr r3, [r4, #72] ; 0x48 802f0ec: 1ad3 subs r3, r2, r3 802f0ee: 1818 adds r0, r3, r0 * not allow it), construct an empty ACK segment and send it. * * If data is to be sent, we will just piggyback the ACK (see below). */ if (pcb->flags & TF_ACK_NOW && (seg == NULL || 802f0f0: 4548 cmp r0, r9 802f0f2: d8ef bhi.n 802f0d4 ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len > wnd)) { return tcp_send_empty_ack(pcb); } /* useg should point to last segment on unacked queue */ useg = pcb->unacked; 802f0f4: 6f26 ldr r6, [r4, #112] ; 0x70 if (useg != NULL) { 802f0f6: b90e cbnz r6, 802f0fc 802f0f8: e0d1 b.n 802f29e for (; useg->next != NULL; useg = useg->next); 802f0fa: 461e mov r6, r3 802f0fc: 6833 ldr r3, [r6, #0] 802f0fe: 2b00 cmp r3, #0 802f100: d1fb bne.n 802f0fa 802f102: e0cc b.n 802f29e } #endif /* TCP_CWND_DEBUG */ /* data available and window allows it to be sent? */ while (seg != NULL && ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len <= wnd) { LWIP_ASSERT("RST not expected here!", 802f104: 68eb ldr r3, [r5, #12] 802f106: 8998 ldrh r0, [r3, #12] 802f108: f7fc fe59 bl 802bdbe * - if tcp_write had a memory error before (prevent delayed ACK timeout) or * - if FIN was already enqueued for this PCB (SYN is always alone in a segment - * either seg->next != NULL or pcb->unacked == NULL; * RST is no sent using tcp_write/tcp_output. */ if((tcp_do_output_nagle(pcb) == 0) && 802f10c: 6f23 ldr r3, [r4, #112] ; 0x70 802f10e: b19b cbz r3, 802f138 802f110: 7fa2 ldrb r2, [r4, #30] 802f112: f012 0f44 tst.w r2, #68 ; 0x44 802f116: d10f bne.n 802f138 802f118: 6ee3 ldr r3, [r4, #108] ; 0x6c 802f11a: b12b cbz r3, 802f128 802f11c: 6819 ldr r1, [r3, #0] 802f11e: b959 cbnz r1, 802f138 802f120: 8919 ldrh r1, [r3, #8] 802f122: 8ee3 ldrh r3, [r4, #54] ; 0x36 802f124: 4299 cmp r1, r3 802f126: d207 bcs.n 802f138 802f128: f8b4 3066 ldrh.w r3, [r4, #102] ; 0x66 802f12c: b123 cbz r3, 802f138 802f12e: f8b4 3068 ldrh.w r3, [r4, #104] ; 0x68 802f132: 2b47 cmp r3, #71 ; 0x47 802f134: f240 80ce bls.w 802f2d4 pcb->lastack, ntohl(seg->tcphdr->seqno), pcb->lastack, i)); ++i; #endif /* TCP_CWND_DEBUG */ pcb->unsent = seg->next; 802f138: 682b ldr r3, [r5, #0] 802f13a: 66e3 str r3, [r4, #108] ; 0x6c if (pcb->state != SYN_SENT) { 802f13c: 7e23 ldrb r3, [r4, #24] 802f13e: 2b02 cmp r3, #2 802f140: d00c beq.n 802f15c TCPH_SET_FLAG(seg->tcphdr, TCP_ACK); 802f142: 68ef ldr r7, [r5, #12] 802f144: 2010 movs r0, #16 802f146: f8b7 b00c ldrh.w fp, [r7, #12] 802f14a: f7fc fe33 bl 802bdb4 802f14e: ea40 000b orr.w r0, r0, fp 802f152: 81b8 strh r0, [r7, #12] pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); 802f154: 7fa3 ldrb r3, [r4, #30] 802f156: f023 0303 bic.w r3, r3, #3 802f15a: 77a3 strb r3, [r4, #30] u16_t len; struct netif *netif; u32_t *opts; /** @bug Exclude retransmitted segments from this count. */ snmp_inc_tcpoutsegs(); 802f15c: f002 fd48 bl 8031bf0 /* The TCP header has already been constructed, but the ackno and wnd fields remain. */ seg->tcphdr->ackno = htonl(pcb->rcv_nxt); 802f160: 6aa0 ldr r0, [r4, #40] ; 0x28 802f162: 68ef ldr r7, [r5, #12] 802f164: f7fc fe30 bl 802bdc8 802f168: 60b8 str r0, [r7, #8] /* advertise our receive window size in this TCP segment */ seg->tcphdr->wnd = htons(pcb->rcv_ann_wnd); 802f16a: 8de0 ldrh r0, [r4, #46] ; 0x2e 802f16c: 68ef ldr r7, [r5, #12] 802f16e: f7fc fe21 bl 802bdb4 802f172: 81f8 strh r0, [r7, #14] pcb->rcv_ann_right_edge = pcb->rcv_nxt + pcb->rcv_ann_wnd; 802f174: 8de2 ldrh r2, [r4, #46] ; 0x2e 802f176: 6aa3 ldr r3, [r4, #40] ; 0x28 /* Add any requested options. NB MSS option is only set on SYN packets, so ignore it here */ opts = (u32_t *)(void *)(seg->tcphdr + 1); 802f178: 68ef ldr r7, [r5, #12] seg->tcphdr->ackno = htonl(pcb->rcv_nxt); /* advertise our receive window size in this TCP segment */ seg->tcphdr->wnd = htons(pcb->rcv_ann_wnd); pcb->rcv_ann_right_edge = pcb->rcv_nxt + pcb->rcv_ann_wnd; 802f17a: 18d3 adds r3, r2, r3 802f17c: 6323 str r3, [r4, #48] ; 0x30 /* Add any requested options. NB MSS option is only set on SYN packets, so ignore it here */ opts = (u32_t *)(void *)(seg->tcphdr + 1); if (seg->flags & TF_SEG_OPTS_MSS) { 802f17e: 7aab ldrb r3, [r5, #10] 802f180: 07d8 lsls r0, r3, #31 802f182: d509 bpl.n 802f198 u16_t mss; #if TCP_CALCULATE_EFF_SEND_MSS mss = tcp_eff_send_mss(TCP_MSS, &pcb->remote_ip); 802f184: 4641 mov r1, r8 802f186: f240 50b4 movw r0, #1460 ; 0x5b4 802f18a: f7fe fde4 bl 802dd56 #else /* TCP_CALCULATE_EFF_SEND_MSS */ mss = TCP_MSS; #endif /* TCP_CALCULATE_EFF_SEND_MSS */ *opts = TCP_BUILD_MSS_OPTION(mss); 802f18e: f040 7001 orr.w r0, r0, #33816576 ; 0x2040000 802f192: f7fc fe19 bl 802bdc8 802f196: 6178 str r0, [r7, #20] } #endif /* Set retransmission timer running if it is not currently enabled This must be set before checking the route. */ if (pcb->rtime == -1) { 802f198: f9b4 3034 ldrsh.w r3, [r4, #52] ; 0x34 802f19c: 3301 adds r3, #1 802f19e: d101 bne.n 802f1a4 pcb->rtime = 0; 802f1a0: 2300 movs r3, #0 802f1a2: 86a3 strh r3, [r4, #52] ; 0x34 } /* If we don't have a local IP address, we get one by calling ip_route(). */ if (ip_addr_isany(&(pcb->local_ip))) { 802f1a4: 6823 ldr r3, [r4, #0] 802f1a6: b92b cbnz r3, 802f1b4 netif = ip_route(&(pcb->remote_ip)); 802f1a8: 4640 mov r0, r8 802f1aa: f000 fecb bl 802ff44 if (netif == NULL) { 802f1ae: b310 cbz r0, 802f1f6 return; } ip_addr_copy(pcb->local_ip, netif->ip_addr); 802f1b0: 6843 ldr r3, [r0, #4] 802f1b2: 6023 str r3, [r4, #0] } if (pcb->rttest == 0) { 802f1b4: 6ba3 ldr r3, [r4, #56] ; 0x38 802f1b6: b93b cbnz r3, 802f1c8 pcb->rttest = tcp_ticks; 802f1b8: f8da 3000 ldr.w r3, [sl] 802f1bc: 63a3 str r3, [r4, #56] ; 0x38 pcb->rtseq = ntohl(seg->tcphdr->seqno); 802f1be: 68eb ldr r3, [r5, #12] 802f1c0: 6858 ldr r0, [r3, #4] 802f1c2: f7fc fe03 bl 802bdcc 802f1c6: 63e0 str r0, [r4, #60] ; 0x3c } LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output_segment: %"U32_F":%"U32_F"\n", htonl(seg->tcphdr->seqno), htonl(seg->tcphdr->seqno) + seg->len)); len = (u16_t)((u8_t *)seg->tcphdr - (u8_t *)seg->p->payload); 802f1c8: 6868 ldr r0, [r5, #4] 802f1ca: 68eb ldr r3, [r5, #12] 802f1cc: 6842 ldr r2, [r0, #4] seg->p->len -= len; 802f1ce: 8941 ldrh r1, [r0, #10] seg->p->tot_len -= len; seg->p->payload = seg->tcphdr; 802f1d0: 6043 str r3, [r0, #4] } LWIP_DEBUGF(TCP_OUTPUT_DEBUG, ("tcp_output_segment: %"U32_F":%"U32_F"\n", htonl(seg->tcphdr->seqno), htonl(seg->tcphdr->seqno) + seg->len)); len = (u16_t)((u8_t *)seg->tcphdr - (u8_t *)seg->p->payload); 802f1d2: 1a9a subs r2, r3, r2 seg->p->len -= len; 802f1d4: 1a89 subs r1, r1, r2 802f1d6: 8141 strh r1, [r0, #10] seg->p->tot_len -= len; 802f1d8: 8901 ldrh r1, [r0, #8] 802f1da: 1a8a subs r2, r1, r2 802f1dc: 8102 strh r2, [r0, #8] seg->p->payload = seg->tcphdr; seg->tcphdr->chksum = 0; 802f1de: 2200 movs r2, #0 802f1e0: 741a strb r2, [r3, #16] 802f1e2: 745a strb r2, [r3, #17] #if LWIP_NETIF_HWADDRHINT ip_output_hinted(seg->p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(seg->p, &(pcb->local_ip), &(pcb->remote_ip), pcb->ttl, pcb->tos, 802f1e4: 7a62 ldrb r2, [r4, #9] 802f1e6: 7aa3 ldrb r3, [r4, #10] 802f1e8: 9200 str r2, [sp, #0] 802f1ea: 2206 movs r2, #6 802f1ec: 9201 str r2, [sp, #4] 802f1ee: 4621 mov r1, r4 802f1f0: 4642 mov r2, r8 802f1f2: f000 fffb bl 80301ec TCPH_SET_FLAG(seg->tcphdr, TCP_ACK); pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); } tcp_output_segment(seg, pcb); snd_nxt = ntohl(seg->tcphdr->seqno) + TCP_TCPLEN(seg); 802f1f6: 68eb ldr r3, [r5, #12] 802f1f8: 6858 ldr r0, [r3, #4] 802f1fa: f7fc fde7 bl 802bdcc 802f1fe: 68ea ldr r2, [r5, #12] 802f200: f8b5 b008 ldrh.w fp, [r5, #8] 802f204: 4607 mov r7, r0 802f206: 8990 ldrh r0, [r2, #12] 802f208: f7fc fdd9 bl 802bdbe 802f20c: f010 0003 ands.w r0, r0, #3 802f210: bf18 it ne 802f212: 2001 movne r0, #1 if (TCP_SEQ_LT(pcb->snd_nxt, snd_nxt)) { 802f214: 6d22 ldr r2, [r4, #80] ; 0x50 TCPH_SET_FLAG(seg->tcphdr, TCP_ACK); pcb->flags &= ~(TF_ACK_DELAY | TF_ACK_NOW); } tcp_output_segment(seg, pcb); snd_nxt = ntohl(seg->tcphdr->seqno) + TCP_TCPLEN(seg); 802f216: eb0b 0300 add.w r3, fp, r0 802f21a: 19db adds r3, r3, r7 if (TCP_SEQ_LT(pcb->snd_nxt, snd_nxt)) { 802f21c: 1ad2 subs r2, r2, r3 802f21e: 2a00 cmp r2, #0 pcb->snd_nxt = snd_nxt; 802f220: bfb8 it lt 802f222: 6523 strlt r3, [r4, #80] ; 0x50 } /* put segment on unacknowledged list if length > 0 */ if (TCP_TCPLEN(seg) > 0) { 802f224: 68eb ldr r3, [r5, #12] 802f226: 892f ldrh r7, [r5, #8] 802f228: 8998 ldrh r0, [r3, #12] 802f22a: f7fc fdc8 bl 802bdbe 802f22e: f010 0003 ands.w r0, r0, #3 802f232: bf18 it ne 802f234: 2001 movne r0, #1 802f236: 1838 adds r0, r7, r0 802f238: b360 cbz r0, 802f294 seg->next = NULL; 802f23a: 2300 movs r3, #0 802f23c: 602b str r3, [r5, #0] /* unacked list is empty? */ if (pcb->unacked == NULL) { 802f23e: 6f23 ldr r3, [r4, #112] ; 0x70 802f240: b90b cbnz r3, 802f246 pcb->unacked = seg; 802f242: 6725 str r5, [r4, #112] ; 0x70 802f244: e024 b.n 802f290 /* unacked list is not empty? */ } else { /* In the case of fast retransmit, the packet should not go to the tail * of the unacked queue, but rather somewhere before it. We need to check for * this case. -STJ Jul 27, 2004 */ if (TCP_SEQ_LT(ntohl(seg->tcphdr->seqno), ntohl(useg->tcphdr->seqno))) { 802f246: 68eb ldr r3, [r5, #12] 802f248: 6858 ldr r0, [r3, #4] 802f24a: f7fc fdbf bl 802bdcc 802f24e: 68f3 ldr r3, [r6, #12] 802f250: 4607 mov r7, r0 802f252: 6858 ldr r0, [r3, #4] 802f254: f7fc fdba bl 802bdcc 802f258: 1a38 subs r0, r7, r0 802f25a: 2800 cmp r0, #0 802f25c: da17 bge.n 802f28e /* add segment to before tail of unacked list, keeping the list sorted */ struct tcp_seg **cur_seg = &(pcb->unacked); 802f25e: f104 0770 add.w r7, r4, #112 ; 0x70 while (*cur_seg && 802f262: e000 b.n 802f266 TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { cur_seg = &((*cur_seg)->next ); 802f264: 683f ldr r7, [r7, #0] * of the unacked queue, but rather somewhere before it. We need to check for * this case. -STJ Jul 27, 2004 */ if (TCP_SEQ_LT(ntohl(seg->tcphdr->seqno), ntohl(useg->tcphdr->seqno))) { /* add segment to before tail of unacked list, keeping the list sorted */ struct tcp_seg **cur_seg = &(pcb->unacked); while (*cur_seg && 802f266: 683b ldr r3, [r7, #0] 802f268: b91b cbnz r3, 802f272 TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { cur_seg = &((*cur_seg)->next ); } seg->next = (*cur_seg); 802f26a: 683b ldr r3, [r7, #0] 802f26c: 602b str r3, [r5, #0] (*cur_seg) = seg; 802f26e: 603d str r5, [r7, #0] 802f270: e013 b.n 802f29a * this case. -STJ Jul 27, 2004 */ if (TCP_SEQ_LT(ntohl(seg->tcphdr->seqno), ntohl(useg->tcphdr->seqno))) { /* add segment to before tail of unacked list, keeping the list sorted */ struct tcp_seg **cur_seg = &(pcb->unacked); while (*cur_seg && TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { 802f272: 68db ldr r3, [r3, #12] 802f274: 6858 ldr r0, [r3, #4] 802f276: f7fc fda9 bl 802bdcc 802f27a: 68eb ldr r3, [r5, #12] 802f27c: 4683 mov fp, r0 802f27e: 6858 ldr r0, [r3, #4] 802f280: f7fc fda4 bl 802bdcc 802f284: ebc0 000b rsb r0, r0, fp * of the unacked queue, but rather somewhere before it. We need to check for * this case. -STJ Jul 27, 2004 */ if (TCP_SEQ_LT(ntohl(seg->tcphdr->seqno), ntohl(useg->tcphdr->seqno))) { /* add segment to before tail of unacked list, keeping the list sorted */ struct tcp_seg **cur_seg = &(pcb->unacked); while (*cur_seg && 802f288: 2800 cmp r0, #0 802f28a: dbeb blt.n 802f264 802f28c: e7ed b.n 802f26a } seg->next = (*cur_seg); (*cur_seg) = seg; } else { /* add segment to tail of unacked list */ useg->next = seg; 802f28e: 6035 str r5, [r6, #0] 802f290: 462e mov r6, r5 802f292: e002 b.n 802f29a useg = useg->next; } } /* do not queue empty segments on the unacked list */ } else { tcp_seg_free(seg); 802f294: 4628 mov r0, r5 802f296: f7fe f978 bl 802d58a } seg = pcb->unsent; 802f29a: 6ee5 ldr r5, [r4, #108] ; 0x6c 802f29c: e003 b.n 802f2a6 } ip_addr_copy(pcb->local_ip, netif->ip_addr); } if (pcb->rttest == 0) { pcb->rttest = tcp_ticks; 802f29e: f8df a04c ldr.w sl, [pc, #76] ; 802f2ec packets, so ignore it here */ opts = (u32_t *)(void *)(seg->tcphdr + 1); if (seg->flags & TF_SEG_OPTS_MSS) { u16_t mss; #if TCP_CALCULATE_EFF_SEND_MSS mss = tcp_eff_send_mss(TCP_MSS, &pcb->remote_ip); 802f2a2: f104 0804 add.w r8, r4, #4 ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len, ntohl(seg->tcphdr->seqno), pcb->lastack)); } #endif /* TCP_CWND_DEBUG */ /* data available and window allows it to be sent? */ while (seg != NULL && 802f2a6: b915 cbnz r5, 802f2ae tcp_seg_free(seg); } seg = pcb->unsent; } #if TCP_OVERSIZE if (pcb->unsent == NULL) { 802f2a8: 6ee3 ldr r3, [r4, #108] ; 0x6c 802f2aa: b973 cbnz r3, 802f2ca 802f2ac: e00b b.n 802f2c6 ntohl(seg->tcphdr->seqno), pcb->lastack)); } #endif /* TCP_CWND_DEBUG */ /* data available and window allows it to be sent? */ while (seg != NULL && ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len <= wnd) { 802f2ae: 68eb ldr r3, [r5, #12] 802f2b0: 6858 ldr r0, [r3, #4] 802f2b2: f7fc fd8b bl 802bdcc 802f2b6: 892a ldrh r2, [r5, #8] 802f2b8: 6ca3 ldr r3, [r4, #72] ; 0x48 802f2ba: 1ad3 subs r3, r2, r3 802f2bc: 1818 adds r0, r3, r0 ntohl(seg->tcphdr->seqno) - pcb->lastack + seg->len, ntohl(seg->tcphdr->seqno), pcb->lastack)); } #endif /* TCP_CWND_DEBUG */ /* data available and window allows it to be sent? */ while (seg != NULL && 802f2be: 4548 cmp r0, r9 802f2c0: f67f af20 bls.w 802f104 802f2c4: e7f0 b.n 802f2a8 seg = pcb->unsent; } #if TCP_OVERSIZE if (pcb->unsent == NULL) { /* last unsent has been removed, reset unsent_oversize */ pcb->unsent_oversize = 0; 802f2c6: f8a4 306a strh.w r3, [r4, #106] ; 0x6a } #endif /* TCP_OVERSIZE */ pcb->flags &= ~TF_NAGLEMEMERR; 802f2ca: 7fa3 ldrb r3, [r4, #30] 802f2cc: f003 037f and.w r3, r3, #127 ; 0x7f 802f2d0: 77a3 strb r3, [r4, #30] return ERR_OK; 802f2d2: e004 b.n 802f2de * - if tcp_write had a memory error before (prevent delayed ACK timeout) or * - if FIN was already enqueued for this PCB (SYN is always alone in a segment - * either seg->next != NULL or pcb->unacked == NULL; * RST is no sent using tcp_write/tcp_output. */ if((tcp_do_output_nagle(pcb) == 0) && 802f2d4: f012 0fa0 tst.w r2, #160 ; 0xa0 802f2d8: f47f af2e bne.w 802f138 802f2dc: e7e4 b.n 802f2a8 } #endif /* TCP_OVERSIZE */ pcb->flags &= ~TF_NAGLEMEMERR; return ERR_OK; } 802f2de: 2000 movs r0, #0 802f2e0: b003 add sp, #12 802f2e2: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802f2e6: bf00 nop 802f2e8: 20010ff4 .word 0x20010ff4 802f2ec: 20010fe0 .word 0x20010fe0 0802f2f0 : */ void tcp_rst(u32_t seqno, u32_t ackno, ip_addr_t *local_ip, ip_addr_t *remote_ip, u16_t local_port, u16_t remote_port) { 802f2f0: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} 802f2f4: 4681 mov r9, r0 802f2f6: 460d mov r5, r1 802f2f8: 4690 mov r8, r2 struct pbuf *p; struct tcp_hdr *tcphdr; p = pbuf_alloc(PBUF_IP, TCP_HLEN, PBUF_RAM); 802f2fa: 2001 movs r0, #1 802f2fc: 2114 movs r1, #20 802f2fe: 2200 movs r2, #0 */ void tcp_rst(u32_t seqno, u32_t ackno, ip_addr_t *local_ip, ip_addr_t *remote_ip, u16_t local_port, u16_t remote_port) { 802f300: 461f mov r7, r3 802f302: f8bd b030 ldrh.w fp, [sp, #48] ; 0x30 802f306: f8bd a034 ldrh.w sl, [sp, #52] ; 0x34 struct pbuf *p; struct tcp_hdr *tcphdr; p = pbuf_alloc(PBUF_IP, TCP_HLEN, PBUF_RAM); 802f30a: f7fd fede bl 802d0ca if (p == NULL) { 802f30e: 4606 mov r6, r0 802f310: 2800 cmp r0, #0 802f312: d030 beq.n 802f376 return; } LWIP_ASSERT("check that first pbuf can hold struct tcp_hdr", (p->len >= sizeof(struct tcp_hdr))); tcphdr = (struct tcp_hdr *)p->payload; 802f314: 6844 ldr r4, [r0, #4] tcphdr->src = htons(local_port); 802f316: 4658 mov r0, fp 802f318: f7fc fd4c bl 802bdb4 802f31c: 8020 strh r0, [r4, #0] tcphdr->dest = htons(remote_port); 802f31e: 4650 mov r0, sl 802f320: f7fc fd48 bl 802bdb4 802f324: 8060 strh r0, [r4, #2] tcphdr->seqno = htonl(seqno); 802f326: 4648 mov r0, r9 802f328: f7fc fd4e bl 802bdc8 802f32c: 6060 str r0, [r4, #4] tcphdr->ackno = htonl(ackno); 802f32e: 4628 mov r0, r5 802f330: f7fc fd4a bl 802bdc8 802f334: 60a0 str r0, [r4, #8] TCPH_HDRLEN_FLAGS_SET(tcphdr, TCP_HLEN/4, TCP_RST | TCP_ACK); 802f336: f245 0014 movw r0, #20500 ; 0x5014 802f33a: f7fc fd3b bl 802bdb4 tcphdr->wnd = PP_HTONS(TCP_WND); 802f33e: 2316 movs r3, #22 802f340: 2500 movs r5, #0 802f342: 73a3 strb r3, [r4, #14] 802f344: f06f 032f mvn.w r3, #47 ; 0x2f tcphdr = (struct tcp_hdr *)p->payload; tcphdr->src = htons(local_port); tcphdr->dest = htons(remote_port); tcphdr->seqno = htonl(seqno); tcphdr->ackno = htonl(ackno); TCPH_HDRLEN_FLAGS_SET(tcphdr, TCP_HLEN/4, TCP_RST | TCP_ACK); 802f348: 81a0 strh r0, [r4, #12] tcphdr->wnd = PP_HTONS(TCP_WND); 802f34a: 73e3 strb r3, [r4, #15] tcphdr->chksum = 0; 802f34c: 7425 strb r5, [r4, #16] 802f34e: 7465 strb r5, [r4, #17] tcphdr->urgp = 0; 802f350: 74a5 strb r5, [r4, #18] 802f352: 74e5 strb r5, [r4, #19] #if CHECKSUM_GEN_TCP tcphdr->chksum = inet_chksum_pseudo(p, local_ip, remote_ip, IP_PROTO_TCP, p->tot_len); #endif TCP_STATS_INC(tcp.xmit); snmp_inc_tcpoutrsts(); 802f354: f002 fc64 bl 8031c20 /* Send output with hardcoded TTL since we have no access to the pcb */ ip_output(p, local_ip, remote_ip, TCP_TTL, 0, IP_PROTO_TCP); 802f358: 2306 movs r3, #6 802f35a: 9301 str r3, [sp, #4] 802f35c: 9500 str r5, [sp, #0] 802f35e: 4630 mov r0, r6 802f360: 4641 mov r1, r8 802f362: 463a mov r2, r7 802f364: 23ff movs r3, #255 ; 0xff 802f366: f000 ff41 bl 80301ec pbuf_free(p); 802f36a: 4630 mov r0, r6 LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_rst: seqno %"U32_F" ackno %"U32_F".\n", seqno, ackno)); } 802f36c: b003 add sp, #12 802f36e: e8bd 4ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} #endif TCP_STATS_INC(tcp.xmit); snmp_inc_tcpoutrsts(); /* Send output with hardcoded TTL since we have no access to the pcb */ ip_output(p, local_ip, remote_ip, TCP_TTL, 0, IP_PROTO_TCP); pbuf_free(p); 802f372: f7fd be5d b.w 802d030 LWIP_DEBUGF(TCP_RST_DEBUG, ("tcp_rst: seqno %"U32_F" ackno %"U32_F".\n", seqno, ackno)); } 802f376: b003 add sp, #12 802f378: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 0802f37c : void tcp_rexmit_rto(struct tcp_pcb *pcb) { struct tcp_seg *seg; if (pcb->unacked == NULL) { 802f37c: 6f02 ldr r2, [r0, #112] ; 0x70 * * @param pcb the tcp_pcb for which to re-enqueue all unacked segments */ void tcp_rexmit_rto(struct tcp_pcb *pcb) { 802f37e: b510 push {r4, lr} struct tcp_seg *seg; if (pcb->unacked == NULL) { 802f380: b19a cbz r2, 802f3aa 802f382: 4611 mov r1, r2 802f384: e000 b.n 802f388 return; } /* Move all unacked segments to the head of the unsent queue */ for (seg = pcb->unacked; seg->next != NULL; seg = seg->next); 802f386: 4619 mov r1, r3 802f388: 680b ldr r3, [r1, #0] 802f38a: 2b00 cmp r3, #0 802f38c: d1fb bne.n 802f386 /* concatenate unsent queue after unacked queue */ seg->next = pcb->unsent; 802f38e: 6ec4 ldr r4, [r0, #108] ; 0x6c 802f390: 600c str r4, [r1, #0] /* unsent queue is the concatenated queue (of unacked, unsent) */ pcb->unsent = pcb->unacked; 802f392: 66c2 str r2, [r0, #108] ; 0x6c /* unacked queue is now empty */ pcb->unacked = NULL; /* last unsent hasn't changed, no need to reset unsent_oversize */ /* increment number of retransmissions */ ++pcb->nrtx; 802f394: f890 2046 ldrb.w r2, [r0, #70] ; 0x46 /* concatenate unsent queue after unacked queue */ seg->next = pcb->unsent; /* unsent queue is the concatenated queue (of unacked, unsent) */ pcb->unsent = pcb->unacked; /* unacked queue is now empty */ pcb->unacked = NULL; 802f398: 6703 str r3, [r0, #112] ; 0x70 /* last unsent hasn't changed, no need to reset unsent_oversize */ /* increment number of retransmissions */ ++pcb->nrtx; 802f39a: 3201 adds r2, #1 802f39c: f880 2046 strb.w r2, [r0, #70] ; 0x46 /* Don't take any RTT measurements after retransmitting. */ pcb->rttest = 0; 802f3a0: 6383 str r3, [r0, #56] ; 0x38 /* Do the actual retransmission */ tcp_output(pcb); } 802f3a2: e8bd 4010 ldmia.w sp!, {r4, lr} /* Don't take any RTT measurements after retransmitting. */ pcb->rttest = 0; /* Do the actual retransmission */ tcp_output(pcb); 802f3a6: f7ff be7f b.w 802f0a8 802f3aa: bd10 pop {r4, pc} 0802f3ac : * * @param pcb the tcp_pcb for which to retransmit the first unacked segment */ void tcp_rexmit(struct tcp_pcb *pcb) { 802f3ac: b5f8 push {r3, r4, r5, r6, r7, lr} struct tcp_seg *seg; struct tcp_seg **cur_seg; if (pcb->unacked == NULL) { 802f3ae: 6f05 ldr r5, [r0, #112] ; 0x70 * * @param pcb the tcp_pcb for which to retransmit the first unacked segment */ void tcp_rexmit(struct tcp_pcb *pcb) { 802f3b0: 4604 mov r4, r0 struct tcp_seg *seg; struct tcp_seg **cur_seg; if (pcb->unacked == NULL) { 802f3b2: 2d00 cmp r5, #0 802f3b4: d027 beq.n 802f406 } /* Move the first unacked segment to the unsent queue */ /* Keep the unsent queue sorted. */ seg = pcb->unacked; pcb->unacked = seg->next; 802f3b6: 682b ldr r3, [r5, #0] cur_seg = &(pcb->unsent); 802f3b8: f100 066c add.w r6, r0, #108 ; 0x6c } /* Move the first unacked segment to the unsent queue */ /* Keep the unsent queue sorted. */ seg = pcb->unacked; pcb->unacked = seg->next; 802f3bc: 6703 str r3, [r0, #112] ; 0x70 cur_seg = &(pcb->unsent); while (*cur_seg && 802f3be: e000 b.n 802f3c2 TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { cur_seg = &((*cur_seg)->next ); 802f3c0: 6836 ldr r6, [r6, #0] /* Keep the unsent queue sorted. */ seg = pcb->unacked; pcb->unacked = seg->next; cur_seg = &(pcb->unsent); while (*cur_seg && 802f3c2: 6833 ldr r3, [r6, #0] 802f3c4: b92b cbnz r3, 802f3d2 TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { cur_seg = &((*cur_seg)->next ); } seg->next = *cur_seg; 802f3c6: 6833 ldr r3, [r6, #0] 802f3c8: 602b str r3, [r5, #0] *cur_seg = seg; 802f3ca: 6035 str r5, [r6, #0] #if TCP_OVERSIZE if (seg->next == NULL) { 802f3cc: 682b ldr r3, [r5, #0] 802f3ce: b97b cbnz r3, 802f3f0 802f3d0: e00c b.n 802f3ec seg = pcb->unacked; pcb->unacked = seg->next; cur_seg = &(pcb->unsent); while (*cur_seg && TCP_SEQ_LT(ntohl((*cur_seg)->tcphdr->seqno), ntohl(seg->tcphdr->seqno))) { 802f3d2: 68db ldr r3, [r3, #12] 802f3d4: 6858 ldr r0, [r3, #4] 802f3d6: f7fc fcf9 bl 802bdcc 802f3da: 68eb ldr r3, [r5, #12] 802f3dc: 4607 mov r7, r0 802f3de: 6858 ldr r0, [r3, #4] 802f3e0: f7fc fcf4 bl 802bdcc 802f3e4: 1a38 subs r0, r7, r0 /* Keep the unsent queue sorted. */ seg = pcb->unacked; pcb->unacked = seg->next; cur_seg = &(pcb->unsent); while (*cur_seg && 802f3e6: 2800 cmp r0, #0 802f3e8: dbea blt.n 802f3c0 802f3ea: e7ec b.n 802f3c6 seg->next = *cur_seg; *cur_seg = seg; #if TCP_OVERSIZE if (seg->next == NULL) { /* the retransmitted segment is last in unsent, so reset unsent_oversize */ pcb->unsent_oversize = 0; 802f3ec: f8a4 306a strh.w r3, [r4, #106] ; 0x6a } #endif /* TCP_OVERSIZE */ ++pcb->nrtx; 802f3f0: f894 3046 ldrb.w r3, [r4, #70] ; 0x46 802f3f4: 3301 adds r3, #1 802f3f6: f884 3046 strb.w r3, [r4, #70] ; 0x46 /* Don't take any rtt measurements after retransmitting. */ pcb->rttest = 0; 802f3fa: 2300 movs r3, #0 802f3fc: 63a3 str r3, [r4, #56] ; 0x38 /* Do the actual retransmission. */ snmp_inc_tcpretranssegs(); /* No need to call tcp_output: we are always called from tcp_input() and thus tcp_output directly returns. */ } 802f3fe: e8bd 40f8 ldmia.w sp!, {r3, r4, r5, r6, r7, lr} /* Don't take any rtt measurements after retransmitting. */ pcb->rttest = 0; /* Do the actual retransmission. */ snmp_inc_tcpretranssegs(); 802f402: f002 bbfd b.w 8031c00 802f406: bdf8 pop {r3, r4, r5, r6, r7, pc} 0802f408 : * @param pcb the tcp_pcb for which to retransmit the first unacked segment */ void tcp_rexmit_fast(struct tcp_pcb *pcb) { if (pcb->unacked != NULL && !(pcb->flags & TF_INFR)) { 802f408: 6f03 ldr r3, [r0, #112] ; 0x70 * * @param pcb the tcp_pcb for which to retransmit the first unacked segment */ void tcp_rexmit_fast(struct tcp_pcb *pcb) { 802f40a: b510 push {r4, lr} 802f40c: 4604 mov r4, r0 if (pcb->unacked != NULL && !(pcb->flags & TF_INFR)) { 802f40e: b333 cbz r3, 802f45e 802f410: 7f83 ldrb r3, [r0, #30] 802f412: f003 0304 and.w r3, r3, #4 802f416: b2db uxtb r3, r3 802f418: bb0b cbnz r3, 802f45e LWIP_DEBUGF(TCP_FR_DEBUG, ("tcp_receive: dupacks %"U16_F" (%"U32_F "), fast retransmit %"U32_F"\n", (u16_t)pcb->dupacks, pcb->lastack, ntohl(pcb->unacked->tcphdr->seqno))); tcp_rexmit(pcb); 802f41a: f7ff ffc7 bl 802f3ac /* Set ssthresh to half of the minimum of the current * cwnd and the advertised window */ if (pcb->cwnd > pcb->snd_wnd) { 802f41e: f8b4 304c ldrh.w r3, [r4, #76] ; 0x4c 802f422: f8b4 2060 ldrh.w r2, [r4, #96] ; 0x60 802f426: 4293 cmp r3, r2 802f428: d903 bls.n 802f432 pcb->ssthresh = pcb->snd_wnd / 2; 802f42a: 0852 lsrs r2, r2, #1 802f42c: f8a4 204e strh.w r2, [r4, #78] ; 0x4e 802f430: e002 b.n 802f438 } else { pcb->ssthresh = pcb->cwnd / 2; 802f432: 085b lsrs r3, r3, #1 802f434: f8a4 304e strh.w r3, [r4, #78] ; 0x4e } /* The minimum value for ssthresh should be 2 MSS */ if (pcb->ssthresh < 2*pcb->mss) { 802f438: 8ee3 ldrh r3, [r4, #54] ; 0x36 802f43a: f8b4 104e ldrh.w r1, [r4, #78] ; 0x4e 802f43e: 005a lsls r2, r3, #1 802f440: 4291 cmp r1, r2 LWIP_DEBUGF(TCP_FR_DEBUG, ("tcp_receive: The minimum value for ssthresh %"U16_F " should be min 2 mss %"U16_F"...\n", pcb->ssthresh, 2*pcb->mss)); pcb->ssthresh = 2*pcb->mss; 802f442: bfb8 it lt 802f444: f8a4 204e strhlt.w r2, [r4, #78] ; 0x4e } pcb->cwnd = pcb->ssthresh + 3 * pcb->mss; 802f448: f8b4 204e ldrh.w r2, [r4, #78] ; 0x4e 802f44c: 2103 movs r1, #3 802f44e: fb01 2303 mla r3, r1, r3, r2 802f452: f8a4 304c strh.w r3, [r4, #76] ; 0x4c pcb->flags |= TF_INFR; 802f456: 7fa3 ldrb r3, [r4, #30] 802f458: f043 0304 orr.w r3, r3, #4 802f45c: 77a3 strb r3, [r4, #30] 802f45e: bd10 pop {r4, pc} 0802f460 : * * @param pcb the tcp_pcb for which to send a keepalive packet */ void tcp_keepalive(struct tcp_pcb *pcb) { 802f460: b537 push {r0, r1, r2, r4, r5, lr} 802f462: 4604 mov r4, r0 ip4_addr3_16(&pcb->remote_ip), ip4_addr4_16(&pcb->remote_ip))); LWIP_DEBUGF(TCP_DEBUG, ("tcp_keepalive: tcp_ticks %"U32_F" pcb->tmr %"U32_F" pcb->keep_cnt_sent %"U16_F"\n", tcp_ticks, pcb->tmr, pcb->keep_cnt_sent)); p = tcp_output_alloc_header(pcb, 0, 0, htonl(pcb->snd_nxt - 1)); 802f464: 6d00 ldr r0, [r0, #80] ; 0x50 802f466: 3801 subs r0, #1 802f468: f7fc fcae bl 802bdc8 802f46c: 2100 movs r1, #0 802f46e: 4602 mov r2, r0 802f470: 4620 mov r0, r4 802f472: f7ff fbd9 bl 802ec28 if(p == NULL) { 802f476: 4605 mov r5, r0 802f478: b178 cbz r0, 802f49a /* Send output to IP */ #if LWIP_NETIF_HWADDRHINT ip_output_hinted(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP); 802f47a: 2200 movs r2, #0 802f47c: f04f 0e06 mov.w lr, #6 802f480: e88d 4004 stmia.w sp, {r2, lr} 802f484: 7aa3 ldrb r3, [r4, #10] 802f486: 4621 mov r1, r4 802f488: 1d22 adds r2, r4, #4 802f48a: f000 feaf bl 80301ec #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); 802f48e: 4628 mov r0, r5 LWIP_DEBUGF(TCP_DEBUG, ("tcp_keepalive: seqno %"U32_F" ackno %"U32_F".\n", pcb->snd_nxt - 1, pcb->rcv_nxt)); } 802f490: b003 add sp, #12 802f492: e8bd 4030 ldmia.w sp!, {r4, r5, lr} &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP); #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); 802f496: f7fd bdcb b.w 802d030 LWIP_DEBUGF(TCP_DEBUG, ("tcp_keepalive: seqno %"U32_F" ackno %"U32_F".\n", pcb->snd_nxt - 1, pcb->rcv_nxt)); } 802f49a: b003 add sp, #12 802f49c: bd30 pop {r4, r5, pc} 0802f49e : * * @param pcb the tcp_pcb for which to send a zero-window probe packet */ void tcp_zero_window_probe(struct tcp_pcb *pcb) { 802f49e: e92d 41f3 stmdb sp!, {r0, r1, r4, r5, r6, r7, r8, lr} LWIP_DEBUGF(TCP_DEBUG, ("tcp_zero_window_probe: tcp_ticks %"U32_F " pcb->tmr %"U32_F" pcb->keep_cnt_sent %"U16_F"\n", tcp_ticks, pcb->tmr, pcb->keep_cnt_sent)); seg = pcb->unacked; 802f4a2: 6f04 ldr r4, [r0, #112] ; 0x70 * * @param pcb the tcp_pcb for which to send a zero-window probe packet */ void tcp_zero_window_probe(struct tcp_pcb *pcb) { 802f4a4: 4605 mov r5, r0 " pcb->tmr %"U32_F" pcb->keep_cnt_sent %"U16_F"\n", tcp_ticks, pcb->tmr, pcb->keep_cnt_sent)); seg = pcb->unacked; if(seg == NULL) { 802f4a6: b914 cbnz r4, 802f4ae seg = pcb->unsent; 802f4a8: 6ec4 ldr r4, [r0, #108] ; 0x6c } if(seg == NULL) { 802f4aa: 2c00 cmp r4, #0 802f4ac: d042 beq.n 802f534 return; } is_fin = ((TCPH_FLAGS(seg->tcphdr) & TCP_FIN) != 0) && (seg->len == 0); 802f4ae: 68e3 ldr r3, [r4, #12] 802f4b0: 8998 ldrh r0, [r3, #12] 802f4b2: f7fc fc84 bl 802bdbe 802f4b6: f010 0001 ands.w r0, r0, #1 802f4ba: d005 beq.n 802f4c8 802f4bc: 8921 ldrh r1, [r4, #8] 802f4be: f1d1 0101 rsbs r1, r1, #1 802f4c2: bf38 it cc 802f4c4: 2100 movcc r1, #0 802f4c6: e000 b.n 802f4ca 802f4c8: 4601 mov r1, r0 /* we want to send one seqno: either FIN or data (no options) */ len = is_fin ? 0 : 1; p = tcp_output_alloc_header(pcb, 0, len, seg->tcphdr->seqno); 802f4ca: 68e3 ldr r3, [r4, #12] } if(seg == NULL) { return; } is_fin = ((TCPH_FLAGS(seg->tcphdr) & TCP_FIN) != 0) && (seg->len == 0); 802f4cc: fa5f f881 uxtb.w r8, r1 /* we want to send one seqno: either FIN or data (no options) */ len = is_fin ? 0 : 1; p = tcp_output_alloc_header(pcb, 0, len, seg->tcphdr->seqno); 802f4d0: 4628 mov r0, r5 802f4d2: f081 0101 eor.w r1, r1, #1 802f4d6: 685a ldr r2, [r3, #4] 802f4d8: f7ff fba6 bl 802ec28 if(p == NULL) { 802f4dc: 4606 mov r6, r0 802f4de: 2800 cmp r0, #0 802f4e0: d028 beq.n 802f534 LWIP_DEBUGF(TCP_DEBUG, ("tcp_zero_window_probe: no memory for pbuf\n")); return; } tcphdr = (struct tcp_hdr *)p->payload; 802f4e2: 6847 ldr r7, [r0, #4] if (is_fin) { 802f4e4: f1b8 0f00 cmp.w r8, #0 802f4e8: d009 beq.n 802f4fe /* FIN segment, no data */ TCPH_FLAGS_SET(tcphdr, TCP_ACK | TCP_FIN); 802f4ea: 89bc ldrh r4, [r7, #12] 802f4ec: 2011 movs r0, #17 802f4ee: f7fc fc61 bl 802bdb4 802f4f2: f424 547c bic.w r4, r4, #16128 ; 0x3f00 802f4f6: b2a4 uxth r4, r4 802f4f8: 4320 orrs r0, r4 802f4fa: 81b8 strh r0, [r7, #12] 802f4fc: e009 b.n 802f512 /* Data segment, copy in one byte from the head of the unacked queue */ char *d = ((char *)p->payload + TCP_HLEN); /* Depending on whether the segment has already been sent (unacked) or not (unsent), seg->p->payload points to the IP header or TCP header. Ensure we copy the first TCP data byte: */ pbuf_copy_partial(seg->p, d, 1, seg->p->tot_len - seg->len); 802f4fe: 6860 ldr r0, [r4, #4] 802f500: 8923 ldrh r3, [r4, #8] 802f502: 8902 ldrh r2, [r0, #8] 802f504: 1ad3 subs r3, r2, r3 802f506: f107 0114 add.w r1, r7, #20 802f50a: 2201 movs r2, #1 802f50c: b29b uxth r3, r3 802f50e: f7fd fedd bl 802d2cc /* Send output to IP */ #if LWIP_NETIF_HWADDRHINT ip_output_hinted(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP, &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP); 802f512: 2200 movs r2, #0 802f514: f04f 0c06 mov.w ip, #6 802f518: e88d 1004 stmia.w sp, {r2, ip} 802f51c: 7aab ldrb r3, [r5, #10] 802f51e: 4630 mov r0, r6 802f520: 4629 mov r1, r5 802f522: 1d2a adds r2, r5, #4 802f524: f000 fe62 bl 80301ec #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); 802f528: 4630 mov r0, r6 LWIP_DEBUGF(TCP_DEBUG, ("tcp_zero_window_probe: seqno %"U32_F " ackno %"U32_F".\n", pcb->snd_nxt - 1, pcb->rcv_nxt)); } 802f52a: b002 add sp, #8 802f52c: e8bd 41f0 ldmia.w sp!, {r4, r5, r6, r7, r8, lr} &(pcb->addr_hint)); #else /* LWIP_NETIF_HWADDRHINT*/ ip_output(p, &pcb->local_ip, &pcb->remote_ip, pcb->ttl, 0, IP_PROTO_TCP); #endif /* LWIP_NETIF_HWADDRHINT*/ pbuf_free(p); 802f530: f7fd bd7e b.w 802d030 LWIP_DEBUGF(TCP_DEBUG, ("tcp_zero_window_probe: seqno %"U32_F " ackno %"U32_F".\n", pcb->snd_nxt - 1, pcb->rcv_nxt)); } 802f534: b002 add sp, #8 802f536: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 802f53a: 0000 movs r0, r0 0802f53c : sys_timeout_debug(u32_t msecs, sys_timeout_handler handler, void *arg, const char* handler_name) #else /* LWIP_DEBUG_TIMERNAMES */ void sys_timeout(u32_t msecs, sys_timeout_handler handler, void *arg) #endif /* LWIP_DEBUG_TIMERNAMES */ { 802f53c: b570 push {r4, r5, r6, lr} 802f53e: 4604 mov r4, r0 struct sys_timeo *timeout, *t; timeout = (struct sys_timeo *)memp_malloc(MEMP_SYS_TIMEOUT); 802f540: 2009 movs r0, #9 sys_timeout_debug(u32_t msecs, sys_timeout_handler handler, void *arg, const char* handler_name) #else /* LWIP_DEBUG_TIMERNAMES */ void sys_timeout(u32_t msecs, sys_timeout_handler handler, void *arg) #endif /* LWIP_DEBUG_TIMERNAMES */ { 802f542: 460d mov r5, r1 802f544: 4616 mov r6, r2 struct sys_timeo *timeout, *t; timeout = (struct sys_timeo *)memp_malloc(MEMP_SYS_TIMEOUT); 802f546: f7fd fc53 bl 802cdf0 if (timeout == NULL) { 802f54a: 4603 mov r3, r0 802f54c: b308 cbz r0, 802f592 timeout->handler_name = handler_name; LWIP_DEBUGF(TIMERS_DEBUG, ("sys_timeout: %p msecs=%"U32_F" handler=%s arg=%p\n", (void *)timeout, msecs, handler_name, (void *)arg)); #endif /* LWIP_DEBUG_TIMERNAMES */ if (next_timeout == NULL) { 802f54e: 4911 ldr r1, [pc, #68] ; (802f594 ) timeout = (struct sys_timeo *)memp_malloc(MEMP_SYS_TIMEOUT); if (timeout == NULL) { LWIP_ASSERT("sys_timeout: timeout != NULL, pool MEMP_SYS_TIMEOUT is empty", timeout != NULL); return; } timeout->next = NULL; 802f550: 2200 movs r2, #0 timeout->h = handler; timeout->arg = arg; timeout->time = msecs; 802f552: e880 0074 stmia.w r0, {r2, r4, r5, r6} timeout->handler_name = handler_name; LWIP_DEBUGF(TIMERS_DEBUG, ("sys_timeout: %p msecs=%"U32_F" handler=%s arg=%p\n", (void *)timeout, msecs, handler_name, (void *)arg)); #endif /* LWIP_DEBUG_TIMERNAMES */ if (next_timeout == NULL) { 802f556: 680a ldr r2, [r1, #0] 802f558: b902 cbnz r2, 802f55c 802f55a: e005 b.n 802f568 next_timeout = timeout; return; } if (next_timeout->time > msecs) { 802f55c: 6850 ldr r0, [r2, #4] 802f55e: 42a0 cmp r0, r4 802f560: d90c bls.n 802f57c next_timeout->time -= msecs; 802f562: 1b04 subs r4, r0, r4 802f564: 6054 str r4, [r2, #4] timeout->next = next_timeout; 802f566: 601a str r2, [r3, #0] next_timeout = timeout; 802f568: 600b str r3, [r1, #0] 802f56a: bd70 pop {r4, r5, r6, pc} } else { for(t = next_timeout; t != NULL; t = t->next) { timeout->time -= t->time; if (t->next == NULL || t->next->time > timeout->time) { 802f56c: 684c ldr r4, [r1, #4] 802f56e: 4284 cmp r4, r0 802f570: d80c bhi.n 802f58c 802f572: 460a mov r2, r1 802f574: e002 b.n 802f57c if (t->next != NULL) { t->next->time -= timeout->time; } timeout->next = t->next; 802f576: 6019 str r1, [r3, #0] t->next = timeout; 802f578: 6013 str r3, [r2, #0] break; 802f57a: bd70 pop {r4, r5, r6, pc} next_timeout->time -= msecs; timeout->next = next_timeout; next_timeout = timeout; } else { for(t = next_timeout; t != NULL; t = t->next) { timeout->time -= t->time; 802f57c: 6851 ldr r1, [r2, #4] 802f57e: 6858 ldr r0, [r3, #4] 802f580: 1a40 subs r0, r0, r1 if (t->next == NULL || t->next->time > timeout->time) { 802f582: 6811 ldr r1, [r2, #0] next_timeout->time -= msecs; timeout->next = next_timeout; next_timeout = timeout; } else { for(t = next_timeout; t != NULL; t = t->next) { timeout->time -= t->time; 802f584: 6058 str r0, [r3, #4] if (t->next == NULL || t->next->time > timeout->time) { 802f586: 2900 cmp r1, #0 802f588: d1f0 bne.n 802f56c 802f58a: e7f4 b.n 802f576 if (t->next != NULL) { t->next->time -= timeout->time; 802f58c: 1a20 subs r0, r4, r0 802f58e: 6048 str r0, [r1, #4] 802f590: e7f1 b.n 802f576 802f592: bd70 pop {r4, r5, r6, pc} 802f594: 2000e120 .word 0x2000e120 0802f598 : } #endif /* LWIP_DNS */ /** Initialize this module */ void sys_timeouts_init(void) { 802f598: b508 push {r3, lr} #if IP_REASSEMBLY sys_timeout(IP_TMR_INTERVAL, ip_reass_timer, NULL); #endif /* IP_REASSEMBLY */ #if LWIP_ARP sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 802f59a: 2200 movs r2, #0 802f59c: f241 3088 movw r0, #5000 ; 0x1388 802f5a0: 4908 ldr r1, [pc, #32] ; (802f5c4 ) 802f5a2: f7ff ffcb bl 802f53c #endif /* LWIP_ARP */ #if LWIP_DHCP sys_timeout(DHCP_COARSE_TIMER_MSECS, dhcp_timer_coarse, NULL); 802f5a6: 2200 movs r2, #0 802f5a8: f64e 2060 movw r0, #60000 ; 0xea60 802f5ac: 4906 ldr r1, [pc, #24] ; (802f5c8 ) 802f5ae: f7ff ffc5 bl 802f53c sys_timeout(DHCP_FINE_TIMER_MSECS, dhcp_timer_fine, NULL); 802f5b2: 4906 ldr r1, [pc, #24] ; (802f5cc ) 802f5b4: f44f 70fa mov.w r0, #500 ; 0x1f4 802f5b8: 2200 movs r2, #0 #if NO_SYS /* Initialise timestamp for sys_check_timeouts */ timeouts_last_time = sys_now(); #endif } 802f5ba: e8bd 4008 ldmia.w sp!, {r3, lr} #if LWIP_ARP sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); #endif /* LWIP_ARP */ #if LWIP_DHCP sys_timeout(DHCP_COARSE_TIMER_MSECS, dhcp_timer_coarse, NULL); sys_timeout(DHCP_FINE_TIMER_MSECS, dhcp_timer_fine, NULL); 802f5be: f7ff bfbd b.w 802f53c 802f5c2: bf00 nop 802f5c4: 0802f609 .word 0x0802f609 802f5c8: 0802f5ed .word 0x0802f5ed 802f5cc: 0802f5d1 .word 0x0802f5d1 0802f5d0 : * * @param arg unused argument */ static void dhcp_timer_fine(void *arg) { 802f5d0: b508 push {r3, lr} LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: dhcp_fine_tmr()\n")); dhcp_fine_tmr(); 802f5d2: f7fd f9c9 bl 802c968 sys_timeout(DHCP_FINE_TIMER_MSECS, dhcp_timer_fine, NULL); 802f5d6: 4904 ldr r1, [pc, #16] ; (802f5e8 ) 802f5d8: f44f 70fa mov.w r0, #500 ; 0x1f4 802f5dc: 2200 movs r2, #0 } 802f5de: e8bd 4008 ldmia.w sp!, {r3, lr} dhcp_timer_fine(void *arg) { LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: dhcp_fine_tmr()\n")); dhcp_fine_tmr(); sys_timeout(DHCP_FINE_TIMER_MSECS, dhcp_timer_fine, NULL); 802f5e2: f7ff bfab b.w 802f53c 802f5e6: bf00 nop 802f5e8: 0802f5d1 .word 0x0802f5d1 0802f5ec : * * @param arg unused argument */ static void dhcp_timer_coarse(void *arg) { 802f5ec: b508 push {r3, lr} LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: dhcp_coarse_tmr()\n")); dhcp_coarse_tmr(); 802f5ee: f7fd f939 bl 802c864 sys_timeout(DHCP_COARSE_TIMER_MSECS, dhcp_timer_coarse, NULL); 802f5f2: 4904 ldr r1, [pc, #16] ; (802f604 ) 802f5f4: f64e 2060 movw r0, #60000 ; 0xea60 802f5f8: 2200 movs r2, #0 } 802f5fa: e8bd 4008 ldmia.w sp!, {r3, lr} dhcp_timer_coarse(void *arg) { LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: dhcp_coarse_tmr()\n")); dhcp_coarse_tmr(); sys_timeout(DHCP_COARSE_TIMER_MSECS, dhcp_timer_coarse, NULL); 802f5fe: f7ff bf9d b.w 802f53c 802f602: bf00 nop 802f604: 0802f5ed .word 0x0802f5ed 0802f608 : * * @param arg unused argument */ static void arp_timer(void *arg) { 802f608: b508 push {r3, lr} LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: etharp_tmr()\n")); etharp_tmr(); 802f60a: f004 fcfb bl 8034004 sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 802f60e: 4904 ldr r1, [pc, #16] ; (802f620 ) 802f610: f241 3088 movw r0, #5000 ; 0x1388 802f614: 2200 movs r2, #0 } 802f616: e8bd 4008 ldmia.w sp!, {r3, lr} arp_timer(void *arg) { LWIP_UNUSED_ARG(arg); LWIP_DEBUGF(TIMERS_DEBUG, ("tcpip: etharp_tmr()\n")); etharp_tmr(); sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 802f61a: f7ff bf8f b.w 802f53c 802f61e: bf00 nop 802f620: 0802f609 .word 0x0802f609 0802f624 : */ void tcp_timer_needed(void) { /* timer is off but needed again? */ if (!tcpip_tcp_timer_active && (tcp_active_pcbs || tcp_tw_pcbs)) { 802f624: 4b08 ldr r3, [pc, #32] ; (802f648 ) 802f626: 681b ldr r3, [r3, #0] 802f628: b96b cbnz r3, 802f646 802f62a: 4b08 ldr r3, [pc, #32] ; (802f64c ) 802f62c: 681b ldr r3, [r3, #0] 802f62e: b913 cbnz r3, 802f636 802f630: 4b07 ldr r3, [pc, #28] ; (802f650 ) 802f632: 681b ldr r3, [r3, #0] 802f634: b13b cbz r3, 802f646 /* enable and start timer */ tcpip_tcp_timer_active = 1; 802f636: 4b04 ldr r3, [pc, #16] ; (802f648 ) sys_timeout(TCP_TMR_INTERVAL, tcpip_tcp_timer, NULL); 802f638: 4906 ldr r1, [pc, #24] ; (802f654 ) tcp_timer_needed(void) { /* timer is off but needed again? */ if (!tcpip_tcp_timer_active && (tcp_active_pcbs || tcp_tw_pcbs)) { /* enable and start timer */ tcpip_tcp_timer_active = 1; 802f63a: 2201 movs r2, #1 802f63c: 601a str r2, [r3, #0] sys_timeout(TCP_TMR_INTERVAL, tcpip_tcp_timer, NULL); 802f63e: 20fa movs r0, #250 ; 0xfa 802f640: 2200 movs r2, #0 802f642: f7ff bf7b b.w 802f53c 802f646: 4770 bx lr 802f648: 2000e11c .word 0x2000e11c 802f64c: 20010fdc .word 0x20010fdc 802f650: 20010ff0 .word 0x20010ff0 802f654: 0802f659 .word 0x0802f659 0802f658 : * * @param arg unused argument */ static void tcpip_tcp_timer(void *arg) { 802f658: b508 push {r3, lr} LWIP_UNUSED_ARG(arg); /* call TCP timer handler */ tcp_tmr(); 802f65a: f7fe fad3 bl 802dc04 /* timer still needed? */ if (tcp_active_pcbs || tcp_tw_pcbs) { 802f65e: 4b08 ldr r3, [pc, #32] ; (802f680 ) 802f660: 681b ldr r3, [r3, #0] 802f662: b913 cbnz r3, 802f66a 802f664: 4b07 ldr r3, [pc, #28] ; (802f684 ) 802f666: 681b ldr r3, [r3, #0] 802f668: b133 cbz r3, 802f678 /* restart timer */ sys_timeout(TCP_TMR_INTERVAL, tcpip_tcp_timer, NULL); 802f66a: 4907 ldr r1, [pc, #28] ; (802f688 ) 802f66c: 20fa movs r0, #250 ; 0xfa 802f66e: 2200 movs r2, #0 } else { /* disable timer */ tcpip_tcp_timer_active = 0; } } 802f670: e8bd 4008 ldmia.w sp!, {r3, lr} /* call TCP timer handler */ tcp_tmr(); /* timer still needed? */ if (tcp_active_pcbs || tcp_tw_pcbs) { /* restart timer */ sys_timeout(TCP_TMR_INTERVAL, tcpip_tcp_timer, NULL); 802f674: f7ff bf62 b.w 802f53c } else { /* disable timer */ tcpip_tcp_timer_active = 0; 802f678: 4a04 ldr r2, [pc, #16] ; (802f68c ) 802f67a: 6013 str r3, [r2, #0] 802f67c: bd08 pop {r3, pc} 802f67e: bf00 nop 802f680: 20010fdc .word 0x20010fdc 802f684: 20010ff0 .word 0x20010ff0 802f688: 0802f659 .word 0x0802f659 802f68c: 2000e11c .word 0x2000e11c 0802f690 : void sys_untimeout(sys_timeout_handler handler, void *arg) { struct sys_timeo *prev_t, *t; if (next_timeout == NULL) { 802f690: 4b10 ldr r3, [pc, #64] ; (802f6d4 ) 802f692: 681b ldr r3, [r3, #0] * @param handler callback function that would be called by the timeout * @param arg callback argument that would be passed to handler */ void sys_untimeout(sys_timeout_handler handler, void *arg) { 802f694: b510 push {r4, lr} struct sys_timeo *prev_t, *t; if (next_timeout == NULL) { 802f696: b1e3 cbz r3, 802f6d2 802f698: 2200 movs r2, #0 802f69a: e000 b.n 802f69e return; } for (t = next_timeout, prev_t = NULL; t != NULL; prev_t = t, t = t->next) { 802f69c: 4623 mov r3, r4 if ((t->h == handler) && (t->arg == arg)) { 802f69e: 689c ldr r4, [r3, #8] 802f6a0: 4284 cmp r4, r0 802f6a2: d112 bne.n 802f6ca 802f6a4: 68dc ldr r4, [r3, #12] 802f6a6: 428c cmp r4, r1 802f6a8: d10f bne.n 802f6ca 802f6aa: 6819 ldr r1, [r3, #0] /* We have a match */ /* Unlink from previous in list */ if (prev_t == NULL) { 802f6ac: b902 cbnz r2, 802f6b0 next_timeout = t->next; 802f6ae: 4a09 ldr r2, [pc, #36] ; (802f6d4 ) } else { prev_t->next = t->next; 802f6b0: 6011 str r1, [r2, #0] } /* If not the last one, add time of this one back to next */ if (t->next != NULL) { 802f6b2: 681a ldr r2, [r3, #0] 802f6b4: b11a cbz r2, 802f6be t->next->time += t->time; 802f6b6: 6850 ldr r0, [r2, #4] 802f6b8: 6859 ldr r1, [r3, #4] 802f6ba: 1841 adds r1, r0, r1 802f6bc: 6051 str r1, [r2, #4] } memp_free(MEMP_SYS_TIMEOUT, t); 802f6be: 2009 movs r0, #9 802f6c0: 4619 mov r1, r3 return; } } return; } 802f6c2: e8bd 4010 ldmia.w sp!, {r4, lr} } /* If not the last one, add time of this one back to next */ if (t->next != NULL) { t->next->time += t->time; } memp_free(MEMP_SYS_TIMEOUT, t); 802f6c6: f7fd bba9 b.w 802ce1c if (next_timeout == NULL) { return; } for (t = next_timeout, prev_t = NULL; t != NULL; prev_t = t, t = t->next) { 802f6ca: 681c ldr r4, [r3, #0] 802f6cc: 461a mov r2, r3 802f6ce: 2c00 cmp r4, #0 802f6d0: d1e4 bne.n 802f69c 802f6d2: bd10 pop {r4, pc} 802f6d4: 2000e120 .word 0x2000e120 0802f6d8 : * @param mbox the mbox to fetch the message from * @param msg the place to store the message */ void sys_timeouts_mbox_fetch(sys_mbox_t *mbox, void **msg) { 802f6d8: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} struct sys_timeo *tmptimeout; sys_timeout_handler handler; void *arg; again: if (!next_timeout) { 802f6dc: 4e18 ldr r6, [pc, #96] ; (802f740 ) * @param mbox the mbox to fetch the message from * @param msg the place to store the message */ void sys_timeouts_mbox_fetch(sys_mbox_t *mbox, void **msg) { 802f6de: 4604 mov r4, r0 802f6e0: 460d mov r5, r1 802f6e2: 4637 mov r7, r6 struct sys_timeo *tmptimeout; sys_timeout_handler handler; void *arg; again: if (!next_timeout) { 802f6e4: 6832 ldr r2, [r6, #0] 802f6e6: b92a cbnz r2, 802f6f4 time_needed = sys_arch_mbox_fetch(mbox, msg, 0); 802f6e8: 4620 mov r0, r4 802f6ea: 4629 mov r1, r5 } else { next_timeout->time = 0; } } } } 802f6ec: e8bd 43f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, lr} sys_timeout_handler handler; void *arg; again: if (!next_timeout) { time_needed = sys_arch_mbox_fetch(mbox, msg, 0); 802f6f0: f005 b8b4 b.w 803485c } else { if (next_timeout->time > 0) { 802f6f4: 6852 ldr r2, [r2, #4] 802f6f6: b96a cbnz r2, 802f714 if (time_needed == SYS_ARCH_TIMEOUT) { /* If time == SYS_ARCH_TIMEOUT, a timeout occured before a message could be fetched. We should now call the timeout handler and deallocate the memory allocated for the timeout. */ tmptimeout = next_timeout; 802f6f8: 6839 ldr r1, [r7, #0] next_timeout = tmptimeout->next; 802f6fa: 680a ldr r2, [r1, #0] handler = tmptimeout->h; 802f6fc: f8d1 8008 ldr.w r8, [r1, #8] if (time_needed == SYS_ARCH_TIMEOUT) { /* If time == SYS_ARCH_TIMEOUT, a timeout occured before a message could be fetched. We should now call the timeout handler and deallocate the memory allocated for the timeout. */ tmptimeout = next_timeout; next_timeout = tmptimeout->next; 802f700: 603a str r2, [r7, #0] if (handler != NULL) { LWIP_DEBUGF(TIMERS_DEBUG, ("stmf calling h=%s arg=%p\n", tmptimeout->handler_name, arg)); } #endif /* LWIP_DEBUG_TIMERNAMES */ memp_free(MEMP_SYS_TIMEOUT, tmptimeout); 802f702: 2009 movs r0, #9 could be fetched. We should now call the timeout handler and deallocate the memory allocated for the timeout. */ tmptimeout = next_timeout; next_timeout = tmptimeout->next; handler = tmptimeout->h; arg = tmptimeout->arg; 802f704: f8d1 900c ldr.w r9, [r1, #12] if (handler != NULL) { LWIP_DEBUGF(TIMERS_DEBUG, ("stmf calling h=%s arg=%p\n", tmptimeout->handler_name, arg)); } #endif /* LWIP_DEBUG_TIMERNAMES */ memp_free(MEMP_SYS_TIMEOUT, tmptimeout); 802f708: f7fd fb88 bl 802ce1c if (handler != NULL) { 802f70c: f1b8 0f00 cmp.w r8, #0 802f710: d0e8 beq.n 802f6e4 802f712: e006 b.n 802f722 again: if (!next_timeout) { time_needed = sys_arch_mbox_fetch(mbox, msg, 0); } else { if (next_timeout->time > 0) { time_needed = sys_arch_mbox_fetch(mbox, msg, next_timeout->time); 802f714: 4620 mov r0, r4 802f716: 4629 mov r1, r5 802f718: f005 f8a0 bl 803485c } else { time_needed = SYS_ARCH_TIMEOUT; } if (time_needed == SYS_ARCH_TIMEOUT) { 802f71c: 1c43 adds r3, r0, #1 802f71e: d0eb beq.n 802f6f8 802f720: e002 b.n 802f728 memp_free(MEMP_SYS_TIMEOUT, tmptimeout); if (handler != NULL) { /* For LWIP_TCPIP_CORE_LOCKING, lock the core before calling the timeout handler function. */ LOCK_TCPIP_CORE(); handler(arg); 802f722: 4648 mov r0, r9 802f724: 47c0 blx r8 802f726: e7dd b.n 802f6e4 goto again; } else { /* If time != SYS_ARCH_TIMEOUT, a message was received before the timeout occured. The time variable is set to the number of milliseconds we waited for the message. */ if (time_needed < next_timeout->time) { 802f728: 4b05 ldr r3, [pc, #20] ; (802f740 ) 802f72a: 681b ldr r3, [r3, #0] 802f72c: 6859 ldr r1, [r3, #4] 802f72e: 4288 cmp r0, r1 next_timeout->time -= time_needed; 802f730: bf34 ite cc 802f732: ebc0 0201 rsbcc r2, r0, r1 } else { next_timeout->time = 0; 802f736: 2200 movcs r2, #0 802f738: 605a str r2, [r3, #4] 802f73a: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 802f73e: bf00 nop 802f740: 2000e120 .word 0x2000e120 0802f744 : /** * Initialize this module. */ void udp_init(void) { 802f744: 4770 bx lr 802f746: 0000 movs r0, r0 0802f748 : * @param inp network interface on which the datagram was received. * */ void udp_input(struct pbuf *p, struct netif *inp) { 802f748: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} PERF_START; UDP_STATS_INC(udp.recv); iphdr = (struct ip_hdr *)p->payload; 802f74c: f8d0 9004 ldr.w r9, [r0, #4] /* Check minimum length (IP header + UDP header) * and move payload pointer to UDP header */ if (p->tot_len < (IPH_HL(iphdr) * 4 + UDP_HLEN) || pbuf_header(p, -(s16_t)(IPH_HL(iphdr) * 4))) { 802f750: 8903 ldrh r3, [r0, #8] * @param inp network interface on which the datagram was received. * */ void udp_input(struct pbuf *p, struct netif *inp) { 802f752: 460e mov r6, r1 iphdr = (struct ip_hdr *)p->payload; /* Check minimum length (IP header + UDP header) * and move payload pointer to UDP header */ if (p->tot_len < (IPH_HL(iphdr) * 4 + UDP_HLEN) || pbuf_header(p, -(s16_t)(IPH_HL(iphdr) * 4))) { 802f754: f899 1000 ldrb.w r1, [r9] 802f758: f001 010f and.w r1, r1, #15 802f75c: 1c8a adds r2, r1, #2 802f75e: ebb3 0f82 cmp.w r3, r2, lsl #2 * @param inp network interface on which the datagram was received. * */ void udp_input(struct pbuf *p, struct netif *inp) { 802f762: b085 sub sp, #20 802f764: 4605 mov r5, r0 iphdr = (struct ip_hdr *)p->payload; /* Check minimum length (IP header + UDP header) * and move payload pointer to UDP header */ if (p->tot_len < (IPH_HL(iphdr) * 4 + UDP_HLEN) || pbuf_header(p, -(s16_t)(IPH_HL(iphdr) * 4))) { 802f766: db05 blt.n 802f774 802f768: 0089 lsls r1, r1, #2 802f76a: 4249 negs r1, r1 802f76c: f7fd fc35 bl 802cfda 802f770: 4683 mov fp, r0 802f772: b110 cbz r0, 802f77a /* drop short packets */ LWIP_DEBUGF(UDP_DEBUG, ("udp_input: short UDP datagram (%"U16_F" bytes) discarded\n", p->tot_len)); UDP_STATS_INC(udp.lenerr); UDP_STATS_INC(udp.drop); snmp_inc_udpinerrors(); 802f774: f002 fa6c bl 8031c50 802f778: e096 b.n 802f8a8 } udphdr = (struct udp_hdr *)p->payload; /* is broadcast packet ? */ broadcast = ip_addr_isbroadcast(¤t_iphdr_dest, inp); 802f77a: f8df a150 ldr.w sl, [pc, #336] ; 802f8cc snmp_inc_udpinerrors(); pbuf_free(p); goto end; } udphdr = (struct udp_hdr *)p->payload; 802f77e: 686c ldr r4, [r5, #4] /* is broadcast packet ? */ broadcast = ip_addr_isbroadcast(¤t_iphdr_dest, inp); 802f780: f8da 0000 ldr.w r0, [sl] 802f784: 4631 mov r1, r6 802f786: f000 faed bl 802fd64 802f78a: 4680 mov r8, r0 LWIP_DEBUGF(UDP_DEBUG, ("udp_input: received datagram of length %"U16_F"\n", p->tot_len)); /* convert src and dest ports to host byte order */ src = ntohs(udphdr->src); 802f78c: 8820 ldrh r0, [r4, #0] 802f78e: f7fc fb16 bl 802bdbe 802f792: 4607 mov r7, r0 dest = ntohs(udphdr->dest); 802f794: 8860 ldrh r0, [r4, #2] 802f796: f7fc fb12 bl 802bdbe #if LWIP_DHCP pcb = NULL; /* when LWIP_DHCP is active, packets to DHCP_CLIENT_PORT may only be processed by the dhcp module, no other UDP pcb may use the local UDP port DHCP_CLIENT_PORT */ if (dest == DHCP_CLIENT_PORT) { 802f79a: 2844 cmp r0, #68 ; 0x44 802f79c: d10f bne.n 802f7be /* all packets for DHCP_CLIENT_PORT not coming from DHCP_SERVER_PORT are dropped! */ if (src == DHCP_SERVER_PORT) { 802f79e: 2f43 cmp r7, #67 ; 0x43 802f7a0: d14f bne.n 802f842 if ((inp->dhcp != NULL) && (inp->dhcp->pcb != NULL)) { 802f7a2: 6a33 ldr r3, [r6, #32] 802f7a4: 2b00 cmp r3, #0 802f7a6: d04c beq.n 802f842 802f7a8: 685c ldr r4, [r3, #4] 802f7aa: 2c00 cmp r4, #0 802f7ac: d049 beq.n 802f842 /* accept the packe if (- broadcast or directed to us) -> DHCP is link-layer-addressed, local ip is always ANY! - inp->dhcp->pcb->remote == ANY or iphdr->src */ if ((ip_addr_isany(&inp->dhcp->pcb->remote_ip) || 802f7ae: 6863 ldr r3, [r4, #4] 802f7b0: 2b00 cmp r3, #0 802f7b2: d04e beq.n 802f852 ip_addr_cmp(&(inp->dhcp->pcb->remote_ip), ¤t_iphdr_src))) { 802f7b4: 4a43 ldr r2, [pc, #268] ; (802f8c4 ) if (src == DHCP_SERVER_PORT) { if ((inp->dhcp != NULL) && (inp->dhcp->pcb != NULL)) { /* accept the packe if (- broadcast or directed to us) -> DHCP is link-layer-addressed, local ip is always ANY! - inp->dhcp->pcb->remote == ANY or iphdr->src */ if ((ip_addr_isany(&inp->dhcp->pcb->remote_ip) || 802f7b6: 6812 ldr r2, [r2, #0] 802f7b8: 4293 cmp r3, r2 802f7ba: d142 bne.n 802f842 802f7bc: e049 b.n 802f852 uncon_pcb = NULL; /* Iterate through the UDP pcb list for a matching pcb. * 'Perfect match' pcbs (connected to the remote port & ip address) are * preferred. If no perfect match is found, the first unconnected pcb that * matches the local port and ip address gets the datagram. */ for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f7be: 4b42 ldr r3, [pc, #264] ; (802f8c8 ) /* compare PCB local addr+port to UDP destination addr+port */ if (pcb->local_port == dest) { if ( (!broadcast && ip_addr_isany(&pcb->local_ip)) || ip_addr_cmp(&(pcb->local_ip), ¤t_iphdr_dest) || 802f7c0: f8da a000 ldr.w sl, [sl] uncon_pcb = NULL; /* Iterate through the UDP pcb list for a matching pcb. * 'Perfect match' pcbs (connected to the remote port & ip address) are * preferred. If no perfect match is found, the first unconnected pcb that * matches the local port and ip address gets the datagram. */ for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f7c4: f8d3 c000 ldr.w ip, [r3] } /* compare PCB remote addr+port to UDP source addr+port */ if ((local_match != 0) && (pcb->remote_port == src) && (ip_addr_isany(&pcb->remote_ip) || ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src))) { 802f7c8: 4b3e ldr r3, [pc, #248] ; (802f8c4 ) 802f7ca: 681b ldr r3, [r3, #0] uncon_pcb = NULL; /* Iterate through the UDP pcb list for a matching pcb. * 'Perfect match' pcbs (connected to the remote port & ip address) are * preferred. If no perfect match is found, the first unconnected pcb that * matches the local port and ip address gets the datagram. */ for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f7cc: 4664 mov r4, ip } /* compare PCB remote addr+port to UDP source addr+port */ if ((local_match != 0) && (pcb->remote_port == src) && (ip_addr_isany(&pcb->remote_ip) || ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src))) { 802f7ce: 9303 str r3, [sp, #12] } } } else #endif /* LWIP_DHCP */ { prev = NULL; 802f7d0: 4659 mov r1, fp local_match = 0; uncon_pcb = NULL; 802f7d2: 465b mov r3, fp /* Iterate through the UDP pcb list for a matching pcb. * 'Perfect match' pcbs (connected to the remote port & ip address) are * preferred. If no perfect match is found, the first unconnected pcb that * matches the local port and ip address gets the datagram. */ for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f7d4: e032 b.n 802f83c ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port, ip4_addr1_16(&pcb->remote_ip), ip4_addr2_16(&pcb->remote_ip), ip4_addr3_16(&pcb->remote_ip), ip4_addr4_16(&pcb->remote_ip), pcb->remote_port)); /* compare PCB local addr+port to UDP destination addr+port */ if (pcb->local_port == dest) { 802f7d6: 8a62 ldrh r2, [r4, #18] 802f7d8: 4282 cmp r2, r0 802f7da: d12d bne.n 802f838 802f7dc: 6822 ldr r2, [r4, #0] if ( 802f7de: f1b8 0f00 cmp.w r8, #0 802f7e2: d100 bne.n 802f7e6 (!broadcast && ip_addr_isany(&pcb->local_ip)) || 802f7e4: b15a cbz r2, 802f7fe 802f7e6: 4552 cmp r2, sl 802f7e8: d009 beq.n 802f7fe ip_addr_cmp(&(pcb->local_ip), ¤t_iphdr_dest) || 802f7ea: f1b8 0f00 cmp.w r8, #0 802f7ee: d023 beq.n 802f838 (broadcast && ip_get_option(pcb, SOF_BROADCAST) && (ip_addr_isany(&pcb->local_ip) || ip_addr_netcmp(&pcb->local_ip, ip_current_dest_addr(), &inp->netmask)))) { #else /* IP_SOF_BROADCAST_RECV */ (broadcast && (ip_addr_isany(&pcb->local_ip) || 802f7f0: b12a cbz r2, 802f7fe ip_addr_netcmp(&pcb->local_ip, ip_current_dest_addr(), &inp->netmask)))) { 802f7f2: ea8a 0b02 eor.w fp, sl, r2 802f7f6: 68b2 ldr r2, [r6, #8] (broadcast && ip_get_option(pcb, SOF_BROADCAST) && (ip_addr_isany(&pcb->local_ip) || ip_addr_netcmp(&pcb->local_ip, ip_current_dest_addr(), &inp->netmask)))) { #else /* IP_SOF_BROADCAST_RECV */ (broadcast && (ip_addr_isany(&pcb->local_ip) || 802f7f8: ea1b 0f02 tst.w fp, r2 802f7fc: d11c bne.n 802f838 ip_addr_netcmp(&pcb->local_ip, ip_current_dest_addr(), &inp->netmask)))) { #endif /* IP_SOF_BROADCAST_RECV */ local_match = 1; if ((uncon_pcb == NULL) && 802f7fe: 2b00 cmp r3, #0 802f800: d158 bne.n 802f8b4 ((pcb->flags & UDP_FLAGS_CONNECTED) == 0)) { 802f802: 7c23 ldrb r3, [r4, #16] (broadcast && (ip_addr_isany(&pcb->local_ip) || ip_addr_netcmp(&pcb->local_ip, ip_current_dest_addr(), &inp->netmask)))) { #endif /* IP_SOF_BROADCAST_RECV */ local_match = 1; if ((uncon_pcb == NULL) && 802f804: f003 0304 and.w r3, r3, #4 802f808: b2db uxtb r3, r3 802f80a: 2b00 cmp r3, #0 802f80c: bf0c ite eq 802f80e: 4623 moveq r3, r4 802f810: 2300 movne r3, #0 802f812: e04f b.n 802f8b4 } } /* compare PCB remote addr+port to UDP source addr+port */ if ((local_match != 0) && (pcb->remote_port == src) && (ip_addr_isany(&pcb->remote_ip) || 802f814: f8d4 b004 ldr.w fp, [r4, #4] 802f818: f1bb 0f00 cmp.w fp, #0 802f81c: d101 bne.n 802f822 ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src))) { /* the first fully matching PCB */ if (prev != NULL) { 802f81e: b921 cbnz r1, 802f82a 802f820: e017 b.n 802f852 } } /* compare PCB remote addr+port to UDP source addr+port */ if ((local_match != 0) && (pcb->remote_port == src) && (ip_addr_isany(&pcb->remote_ip) || 802f822: 9a03 ldr r2, [sp, #12] 802f824: 4593 cmp fp, r2 802f826: d107 bne.n 802f838 802f828: e7f9 b.n 802f81e ip_addr_cmp(&(pcb->remote_ip), ¤t_iphdr_src))) { /* the first fully matching PCB */ if (prev != NULL) { /* move the pcb to the front of udp_pcbs so that is found faster next time */ prev->next = pcb->next; 802f82a: 68e3 ldr r3, [r4, #12] 802f82c: 60cb str r3, [r1, #12] pcb->next = udp_pcbs; udp_pcbs = pcb; 802f82e: 4b26 ldr r3, [pc, #152] ; (802f8c8 ) /* the first fully matching PCB */ if (prev != NULL) { /* move the pcb to the front of udp_pcbs so that is found faster next time */ prev->next = pcb->next; pcb->next = udp_pcbs; 802f830: f8c4 c00c str.w ip, [r4, #12] udp_pcbs = pcb; 802f834: 601c str r4, [r3, #0] 802f836: e00c b.n 802f852 802f838: 4621 mov r1, r4 uncon_pcb = NULL; /* Iterate through the UDP pcb list for a matching pcb. * 'Perfect match' pcbs (connected to the remote port & ip address) are * preferred. If no perfect match is found, the first unconnected pcb that * matches the local port and ip address gets the datagram. */ for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f83a: 68e4 ldr r4, [r4, #12] 802f83c: 2c00 cmp r4, #0 802f83e: d1ca bne.n 802f7d6 pcb = uncon_pcb; } } /* Check checksum if this is a match or if it was directed at us. */ if (pcb != NULL || ip_addr_cmp(&inp->ip_addr, ¤t_iphdr_dest)) { 802f840: b933 cbnz r3, 802f850 802f842: 4b22 ldr r3, [pc, #136] ; (802f8cc ) 802f844: 6872 ldr r2, [r6, #4] 802f846: 681b ldr r3, [r3, #0] 802f848: 429a cmp r2, r3 802f84a: d12d bne.n 802f8a8 802f84c: 2400 movs r4, #0 802f84e: e000 b.n 802f852 802f850: 461c mov r4, r3 goto end; } } #endif /* CHECKSUM_CHECK_UDP */ } if(pbuf_header(p, -UDP_HLEN)) { 802f852: 4628 mov r0, r5 802f854: f06f 0107 mvn.w r1, #7 802f858: f7fd fbbf bl 802cfda 802f85c: 2800 cmp r0, #0 802f85e: d189 bne.n 802f774 UDP_STATS_INC(udp.drop); snmp_inc_udpinerrors(); pbuf_free(p); goto end; } if (pcb != NULL) { 802f860: b154 cbz r4, 802f878 snmp_inc_udpindatagrams(); 802f862: f002 f9e5 bl 8031c30 pbuf_header(p, -(s16_t)((IPH_HL(iphdr) * 4) + UDP_HLEN)); } } #endif /* SO_REUSE && SO_REUSE_RXTOALL */ /* callback */ if (pcb->recv != NULL) { 802f866: 69a6 ldr r6, [r4, #24] 802f868: b1f6 cbz r6, 802f8a8 /* now the recv function is responsible for freeing p */ pcb->recv(pcb->recv_arg, pcb, p, ip_current_src_addr(), src); 802f86a: 9700 str r7, [sp, #0] 802f86c: 69e0 ldr r0, [r4, #28] 802f86e: 4b15 ldr r3, [pc, #84] ; (802f8c4 ) 802f870: 4621 mov r1, r4 802f872: 462a mov r2, r5 802f874: 47b0 blx r6 802f876: e021 b.n 802f8bc LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, ("udp_input: not for us.\n")); #if LWIP_ICMP /* No match was found, send ICMP destination port unreachable unless destination address was broadcast/multicast. */ if (!broadcast && 802f878: f1b8 0f00 cmp.w r8, #0 802f87c: d112 bne.n 802f8a4 !ip_addr_ismulticast(¤t_iphdr_dest)) { 802f87e: 4b13 ldr r3, [pc, #76] ; (802f8cc ) 802f880: 681b ldr r3, [r3, #0] 802f882: f003 03f0 and.w r3, r3, #240 ; 0xf0 LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, ("udp_input: not for us.\n")); #if LWIP_ICMP /* No match was found, send ICMP destination port unreachable unless destination address was broadcast/multicast. */ if (!broadcast && 802f886: 2be0 cmp r3, #224 ; 0xe0 802f888: d00c beq.n 802f8a4 !ip_addr_ismulticast(¤t_iphdr_dest)) { /* move payload pointer back to ip header */ pbuf_header(p, (IPH_HL(iphdr) * 4) + UDP_HLEN); 802f88a: f899 1000 ldrb.w r1, [r9] 802f88e: f001 010f and.w r1, r1, #15 802f892: 3102 adds r1, #2 802f894: 0089 lsls r1, r1, #2 802f896: 4628 mov r0, r5 802f898: f7fd fb9f bl 802cfda LWIP_ASSERT("p->payload == iphdr", (p->payload == iphdr)); icmp_dest_unreach(p, ICMP_DUR_PORT); 802f89c: 4628 mov r0, r5 802f89e: 2103 movs r1, #3 802f8a0: f000 f9d2 bl 802fc48 } #endif /* LWIP_ICMP */ UDP_STATS_INC(udp.proterr); UDP_STATS_INC(udp.drop); snmp_inc_udpnoports(); 802f8a4: f002 f9cc bl 8031c40 pbuf_free(p); 802f8a8: 4628 mov r0, r5 } else { pbuf_free(p); } end: PERF_STOP("udp_input"); } 802f8aa: b005 add sp, #20 802f8ac: e8bd 4ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} } #endif /* LWIP_ICMP */ UDP_STATS_INC(udp.proterr); UDP_STATS_INC(udp.drop); snmp_inc_udpnoports(); pbuf_free(p); 802f8b0: f7fd bbbe b.w 802d030 uncon_pcb = pcb; } } } /* compare PCB remote addr+port to UDP source addr+port */ if ((local_match != 0) && 802f8b4: 8aa2 ldrh r2, [r4, #20] 802f8b6: 42ba cmp r2, r7 802f8b8: d1be bne.n 802f838 802f8ba: e7ab b.n 802f814 } else { pbuf_free(p); } end: PERF_STOP("udp_input"); } 802f8bc: b005 add sp, #20 802f8be: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 802f8c2: bf00 nop 802f8c4: 20010ffc .word 0x20010ffc 802f8c8: 20010ff8 .word 0x20010ff8 802f8cc: 20011004 .word 0x20011004 0802f8d0 : * * @see udp_disconnect() */ err_t udp_bind(struct udp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802f8d0: b5f8 push {r3, r4, r5, r6, r7, lr} ip_addr_debug_print(UDP_DEBUG, ipaddr); LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, (", port = %"U16_F")\n", port)); rebind = 0; /* Check for double bind and rebind of the same pcb */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802f8d2: 4b25 ldr r3, [pc, #148] ; (802f968 ) * * @see udp_disconnect() */ err_t udp_bind(struct udp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802f8d4: 4604 mov r4, r0 ip_addr_debug_print(UDP_DEBUG, ipaddr); LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, (", port = %"U16_F")\n", port)); rebind = 0; /* Check for double bind and rebind of the same pcb */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802f8d6: 6818 ldr r0, [r3, #0] LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, ("udp_bind(ipaddr = ")); ip_addr_debug_print(UDP_DEBUG, ipaddr); LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, (", port = %"U16_F")\n", port)); rebind = 0; 802f8d8: 2500 movs r5, #0 /* Check for double bind and rebind of the same pcb */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802f8da: 4603 mov r3, r0 802f8dc: e012 b.n 802f904 /* is this UDP PCB already on active list? */ if (pcb == ipcb) { 802f8de: 429c cmp r4, r3 802f8e0: d00e beq.n 802f900 !ip_get_option(ipcb, SOF_REUSEADDR)) { #else /* SO_REUSE */ /* port matches that of PCB in list and REUSEADDR not set -> reject */ else { #endif /* SO_REUSE */ if ((ipcb->local_port == port) && 802f8e2: 8a5e ldrh r6, [r3, #18] 802f8e4: 4296 cmp r6, r2 802f8e6: d10c bne.n 802f902 /* IP address matches, or one is IP_ADDR_ANY? */ (ip_addr_isany(&(ipcb->local_ip)) || 802f8e8: 681f ldr r7, [r3, #0] 802f8ea: b90f cbnz r7, 802f8f0 ip_addr_isany(ipaddr) || ip_addr_cmp(&(ipcb->local_ip), ipaddr))) { /* other PCB already binds to this local IP and port */ LWIP_DEBUGF(UDP_DEBUG, ("udp_bind: local port %"U16_F" already bound by another pcb\n", port)); return ERR_USE; 802f8ec: 20f8 movs r0, #248 ; 0xf8 802f8ee: e039 b.n 802f964 /* port matches that of PCB in list and REUSEADDR not set -> reject */ else { #endif /* SO_REUSE */ if ((ipcb->local_port == port) && /* IP address matches, or one is IP_ADDR_ANY? */ (ip_addr_isany(&(ipcb->local_ip)) || 802f8f0: 2900 cmp r1, #0 802f8f2: d0fb beq.n 802f8ec ip_addr_isany(ipaddr) || 802f8f4: 680e ldr r6, [r1, #0] 802f8f6: 2e00 cmp r6, #0 802f8f8: d0f8 beq.n 802f8ec 802f8fa: 42b7 cmp r7, r6 802f8fc: d101 bne.n 802f902 802f8fe: e7f5 b.n 802f8ec /* is this UDP PCB already on active list? */ if (pcb == ipcb) { /* pcb may occur at most once in active list */ LWIP_ASSERT("rebind == 0", rebind == 0); /* pcb already in list, just rebind */ rebind = 1; 802f900: 2501 movs r5, #1 ip_addr_debug_print(UDP_DEBUG, ipaddr); LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, (", port = %"U16_F")\n", port)); rebind = 0; /* Check for double bind and rebind of the same pcb */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802f902: 68db ldr r3, [r3, #12] 802f904: 2b00 cmp r3, #0 802f906: d1ea bne.n 802f8de return ERR_USE; } } } ip_addr_set(&pcb->local_ip, ipaddr); 802f908: b101 cbz r1, 802f90c 802f90a: 6809 ldr r1, [r1, #0] 802f90c: 6021 str r1, [r4, #0] /* no port specified? */ if (port == 0) { 802f90e: b9fa cbnz r2, 802f950 802f910: 4b16 ldr r3, [pc, #88] ; (802f96c ) 802f912: 881a ldrh r2, [r3, #0] 802f914: f44f 4180 mov.w r1, #16384 ; 0x4000 { u16_t n = 0; struct udp_pcb *pcb; again: if (udp_port++ == UDP_LOCAL_PORT_RANGE_END) { 802f918: f64f 76ff movw r6, #65535 ; 0xffff 802f91c: 42b2 cmp r2, r6 802f91e: d002 beq.n 802f926 802f920: 3201 adds r2, #1 802f922: b292 uxth r2, r2 802f924: e001 b.n 802f92a udp_port = UDP_LOCAL_PORT_RANGE_START; 802f926: f44f 4240 mov.w r2, #49152 ; 0xc000 } /* Check all PCBs. */ for(pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f92a: 4603 mov r3, r0 802f92c: e00a b.n 802f944 if (pcb->local_port == udp_port) { 802f92e: 8a5f ldrh r7, [r3, #18] 802f930: 4297 cmp r7, r2 802f932: d106 bne.n 802f942 802f934: 3901 subs r1, #1 802f936: b289 uxth r1, r1 if (++n > (UDP_LOCAL_PORT_RANGE_END - UDP_LOCAL_PORT_RANGE_START)) { 802f938: 2900 cmp r1, #0 802f93a: d1ef bne.n 802f91c 802f93c: 4b0b ldr r3, [pc, #44] ; (802f96c ) 802f93e: 801a strh r2, [r3, #0] 802f940: e7d4 b.n 802f8ec again: if (udp_port++ == UDP_LOCAL_PORT_RANGE_END) { udp_port = UDP_LOCAL_PORT_RANGE_START; } /* Check all PCBs. */ for(pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { 802f942: 68db ldr r3, [r3, #12] 802f944: 2b00 cmp r3, #0 802f946: d1f2 bne.n 802f92e 802f948: 4b08 ldr r3, [pc, #32] ; (802f96c ) 802f94a: 801a strh r2, [r3, #0] ip_addr_set(&pcb->local_ip, ipaddr); /* no port specified? */ if (port == 0) { port = udp_new_port(); if (port == 0) { 802f94c: 2a00 cmp r2, #0 802f94e: d0cd beq.n 802f8ec /* no more ports available in local range */ LWIP_DEBUGF(UDP_DEBUG, ("udp_bind: out of free UDP ports\n")); return ERR_USE; } } pcb->local_port = port; 802f950: 8262 strh r2, [r4, #18] snmp_insert_udpidx_tree(pcb); 802f952: 4620 mov r0, r4 802f954: f002 f98c bl 8031c70 /* pcb not active yet? */ if (rebind == 0) { 802f958: b91d cbnz r5, 802f962 /* place the PCB on the active list if not already there */ pcb->next = udp_pcbs; 802f95a: 4b03 ldr r3, [pc, #12] ; (802f968 ) 802f95c: 681a ldr r2, [r3, #0] udp_pcbs = pcb; 802f95e: 601c str r4, [r3, #0] pcb->local_port = port; snmp_insert_udpidx_tree(pcb); /* pcb not active yet? */ if (rebind == 0) { /* place the PCB on the active list if not already there */ pcb->next = udp_pcbs; 802f960: 60e2 str r2, [r4, #12] LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("udp_bind: bound to %"U16_F".%"U16_F".%"U16_F".%"U16_F", port %"U16_F"\n", ip4_addr1_16(&pcb->local_ip), ip4_addr2_16(&pcb->local_ip), ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port)); return ERR_OK; 802f962: 2000 movs r0, #0 } 802f964: b240 sxtb r0, r0 802f966: bdf8 pop {r3, r4, r5, r6, r7, pc} 802f968: 20010ff8 .word 0x20010ff8 802f96c: 200015ee .word 0x200015ee 0802f970 : * @see udp_disconnect() udp_send() */ err_t udp_sendto_if(struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *dst_ip, u16_t dst_port, struct netif *netif) { 802f970: e92d 47ff stmdb sp!, {r0, r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, lr} 802f974: 4692 mov sl, r2 return ERR_VAL; } #endif /* IP_SOF_BROADCAST */ /* if the PCB is not yet bound to a port, bind it here */ if (pcb->local_port == 0) { 802f976: 8a42 ldrh r2, [r0, #18] * @see udp_disconnect() udp_send() */ err_t udp_sendto_if(struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *dst_ip, u16_t dst_port, struct netif *netif) { 802f978: f8dd 8030 ldr.w r8, [sp, #48] ; 0x30 802f97c: 4605 mov r5, r0 802f97e: 460e mov r6, r1 802f980: 4699 mov r9, r3 return ERR_VAL; } #endif /* IP_SOF_BROADCAST */ /* if the PCB is not yet bound to a port, bind it here */ if (pcb->local_port == 0) { 802f982: b132 cbz r2, 802f992 return err; } } /* not enough space to add an UDP header to first pbuf in given p chain? */ if (pbuf_header(p, UDP_HLEN)) { 802f984: 4630 mov r0, r6 802f986: 2108 movs r1, #8 802f988: f7fd fb27 bl 802cfda 802f98c: b940 cbnz r0, 802f9a0 802f98e: 4634 mov r4, r6 802f990: e013 b.n 802f9ba #endif /* IP_SOF_BROADCAST */ /* if the PCB is not yet bound to a port, bind it here */ if (pcb->local_port == 0) { LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE, ("udp_send: not yet bound to a port, binding now\n")); err = udp_bind(pcb, &pcb->local_ip, pcb->local_port); 802f992: 4601 mov r1, r0 802f994: f7ff ff9c bl 802f8d0 if (err != ERR_OK) { 802f998: 4607 mov r7, r0 802f99a: 2800 cmp r0, #0 802f99c: d0f2 beq.n 802f984 802f99e: e044 b.n 802fa2a } /* not enough space to add an UDP header to first pbuf in given p chain? */ if (pbuf_header(p, UDP_HLEN)) { /* allocate header in a separate new pbuf */ q = pbuf_alloc(PBUF_IP, UDP_HLEN, PBUF_RAM); 802f9a0: 2001 movs r0, #1 802f9a2: 2108 movs r1, #8 802f9a4: 2200 movs r2, #0 802f9a6: f7fd fb90 bl 802d0ca /* new header pbuf could not be allocated? */ if (q == NULL) { 802f9aa: 4604 mov r4, r0 802f9ac: 2800 cmp r0, #0 802f9ae: d039 beq.n 802fa24 LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("udp_send: could not allocate header\n")); return ERR_MEM; } if (p->tot_len != 0) { 802f9b0: 8933 ldrh r3, [r6, #8] 802f9b2: b113 cbz r3, 802f9ba /* chain header q in front of given pbuf p (only if p contains data) */ pbuf_chain(q, p); 802f9b4: 4631 mov r1, r6 802f9b6: f7fd fc36 bl 802d226 } LWIP_ASSERT("check that first pbuf can hold struct udp_hdr", (q->len >= sizeof(struct udp_hdr))); /* q now represents the packet to be sent */ udphdr = (struct udp_hdr *)q->payload; udphdr->src = htons(pcb->local_port); 802f9ba: 8a68 ldrh r0, [r5, #18] LWIP_DEBUGF(UDP_DEBUG, ("udp_send: added header in given pbuf %p\n", (void *)p)); } LWIP_ASSERT("check that first pbuf can hold struct udp_hdr", (q->len >= sizeof(struct udp_hdr))); /* q now represents the packet to be sent */ udphdr = (struct udp_hdr *)q->payload; 802f9bc: 6867 ldr r7, [r4, #4] udphdr->src = htons(pcb->local_port); 802f9be: f7fc f9f9 bl 802bdb4 802f9c2: 8038 strh r0, [r7, #0] udphdr->dest = htons(dst_port); 802f9c4: 4648 mov r0, r9 802f9c6: f7fc f9f5 bl 802bdb4 /* in UDP, 0 checksum means 'no checksum' */ udphdr->chksum = 0x0000; 802f9ca: 2300 movs r3, #0 LWIP_ASSERT("check that first pbuf can hold struct udp_hdr", (q->len >= sizeof(struct udp_hdr))); /* q now represents the packet to be sent */ udphdr = (struct udp_hdr *)q->payload; udphdr->src = htons(pcb->local_port); udphdr->dest = htons(dst_port); 802f9cc: 8078 strh r0, [r7, #2] /* in UDP, 0 checksum means 'no checksum' */ udphdr->chksum = 0x0000; 802f9ce: 71bb strb r3, [r7, #6] 802f9d0: 71fb strb r3, [r7, #7] } #endif /* LWIP_IGMP */ /* PCB local address is IP_ANY_ADDR? */ if (ip_addr_isany(&pcb->local_ip)) { 802f9d2: 682b ldr r3, [r5, #0] 802f9d4: b913 cbnz r3, 802f9dc /* use outgoing network interface IP address as source address */ src_ip = &(netif->ip_addr); 802f9d6: f108 0904 add.w r9, r8, #4 802f9da: e00a b.n 802f9f2 } else { /* check if UDP PCB local IP address is correct * this could be an old address if netif->ip_addr has changed */ if (!ip_addr_cmp(&(pcb->local_ip), &(netif->ip_addr))) { 802f9dc: f8d8 2004 ldr.w r2, [r8, #4] 802f9e0: 4293 cmp r3, r2 802f9e2: d005 beq.n 802f9f0 /* local_ip doesn't match, drop the packet */ if (q != p) { 802f9e4: 42b4 cmp r4, r6 802f9e6: d01f beq.n 802fa28 /* free the header pbuf */ pbuf_free(q); 802f9e8: 4620 mov r0, r4 802f9ea: f7fd fb21 bl 802d030 802f9ee: e01b b.n 802fa28 } #endif /* LWIP_IGMP */ /* PCB local address is IP_ANY_ADDR? */ if (ip_addr_isany(&pcb->local_ip)) { 802f9f0: 46a9 mov r9, r5 NETIF_SET_HWADDRHINT(netif, NULL); } else #endif /* LWIP_UDPLITE */ { /* UDP */ LWIP_DEBUGF(UDP_DEBUG, ("udp_send: UDP packet length %"U16_F"\n", q->tot_len)); udphdr->len = htons(q->tot_len); 802f9f2: 8920 ldrh r0, [r4, #8] 802f9f4: f7fc f9de bl 802bdb4 802f9f8: 80b8 strh r0, [r7, #4] #endif /* CHECKSUM_GEN_UDP */ LWIP_DEBUGF(UDP_DEBUG, ("udp_send: UDP checksum 0x%04"X16_F"\n", udphdr->chksum)); LWIP_DEBUGF(UDP_DEBUG, ("udp_send: ip_output_if (,,,,IP_PROTO_UDP,)\n")); /* output to IP */ NETIF_SET_HWADDRHINT(netif, &pcb->addr_hint); err = ip_output_if(q, src_ip, dst_ip, pcb->ttl, pcb->tos, IP_PROTO_UDP, netif); 802f9fa: 7a6a ldrb r2, [r5, #9] 802f9fc: 7aab ldrb r3, [r5, #10] 802f9fe: 9200 str r2, [sp, #0] 802fa00: 2211 movs r2, #17 802fa02: 9201 str r2, [sp, #4] 802fa04: 4649 mov r1, r9 802fa06: 4652 mov r2, sl 802fa08: f8cd 8008 str.w r8, [sp, #8] 802fa0c: 4620 mov r0, r4 802fa0e: f000 fb9d bl 803014c 802fa12: 4607 mov r7, r0 NETIF_SET_HWADDRHINT(netif, NULL); } /* TODO: must this be increased even if error occured? */ snmp_inc_udpoutdatagrams(); 802fa14: f002 f924 bl 8031c60 /* did we chain a separate header pbuf earlier? */ if (q != p) { 802fa18: 42b4 cmp r4, r6 802fa1a: d006 beq.n 802fa2a /* free the header pbuf */ pbuf_free(q); 802fa1c: 4620 mov r0, r4 802fa1e: f7fd fb07 bl 802d030 802fa22: e002 b.n 802fa2a /* allocate header in a separate new pbuf */ q = pbuf_alloc(PBUF_IP, UDP_HLEN, PBUF_RAM); /* new header pbuf could not be allocated? */ if (q == NULL) { LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("udp_send: could not allocate header\n")); return ERR_MEM; 802fa24: 27ff movs r7, #255 ; 0xff 802fa26: e000 b.n 802fa2a /* free the header pbuf */ pbuf_free(q); q = NULL; /* p is still referenced by the caller, and will live on */ } return ERR_VAL; 802fa28: 27fa movs r7, #250 ; 0xfa /* p is still referenced by the caller, and will live on */ } UDP_STATS_INC(udp.xmit); return err; } 802fa2a: b278 sxtb r0, r7 802fa2c: b004 add sp, #16 802fa2e: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 0802fa32 : * @see udp_disconnect() udp_send() */ err_t udp_sendto(struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *dst_ip, u16_t dst_port) { 802fa32: b5f7 push {r0, r1, r2, r4, r5, r6, r7, lr} 802fa34: 4605 mov r5, r0 /* find the outgoing network interface for this packet */ #if LWIP_IGMP netif = ip_route((ip_addr_ismulticast(dst_ip))?(&(pcb->multicast_ip)):(dst_ip)); #else netif = ip_route(dst_ip); 802fa36: 4610 mov r0, r2 * @see udp_disconnect() udp_send() */ err_t udp_sendto(struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *dst_ip, u16_t dst_port) { 802fa38: 460f mov r7, r1 802fa3a: 4614 mov r4, r2 802fa3c: 461e mov r6, r3 /* find the outgoing network interface for this packet */ #if LWIP_IGMP netif = ip_route((ip_addr_ismulticast(dst_ip))?(&(pcb->multicast_ip)):(dst_ip)); #else netif = ip_route(dst_ip); 802fa3e: f000 fa81 bl 802ff44 #endif /* LWIP_IGMP */ /* no outgoing network interface could be found? */ if (netif == NULL) { 802fa42: b138 cbz r0, 802fa54 return ERR_RTE; } #if LWIP_CHECKSUM_ON_COPY return udp_sendto_if_chksum(pcb, p, dst_ip, dst_port, netif, have_chksum, chksum); #else /* LWIP_CHECKSUM_ON_COPY */ return udp_sendto_if(pcb, p, dst_ip, dst_port, netif); 802fa44: 9000 str r0, [sp, #0] 802fa46: 4639 mov r1, r7 802fa48: 4628 mov r0, r5 802fa4a: 4622 mov r2, r4 802fa4c: 4633 mov r3, r6 802fa4e: f7ff ff8f bl 802f970 802fa52: e000 b.n 802fa56 /* no outgoing network interface could be found? */ if (netif == NULL) { LWIP_DEBUGF(UDP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("udp_send: No route to %"U16_F".%"U16_F".%"U16_F".%"U16_F"\n", ip4_addr1_16(dst_ip), ip4_addr2_16(dst_ip), ip4_addr3_16(dst_ip), ip4_addr4_16(dst_ip))); UDP_STATS_INC(udp.rterr); return ERR_RTE; 802fa54: 20fc movs r0, #252 ; 0xfc #if LWIP_CHECKSUM_ON_COPY return udp_sendto_if_chksum(pcb, p, dst_ip, dst_port, netif, have_chksum, chksum); #else /* LWIP_CHECKSUM_ON_COPY */ return udp_sendto_if(pcb, p, dst_ip, dst_port, netif); #endif /* LWIP_CHECKSUM_ON_COPY */ } 802fa56: b240 sxtb r0, r0 802fa58: bdfe pop {r1, r2, r3, r4, r5, r6, r7, pc} 0802fa5a : */ err_t udp_send(struct udp_pcb *pcb, struct pbuf *p) { /* send to the packet using remote ip and port stored in the pcb */ return udp_sendto(pcb, p, &pcb->remote_ip, pcb->remote_port); 802fa5a: 8a83 ldrh r3, [r0, #20] 802fa5c: 1d02 adds r2, r0, #4 802fa5e: f7ff bfe8 b.w 802fa32 802fa62: 0000 movs r0, r0 0802fa64 : * * @see udp_disconnect() */ err_t udp_connect(struct udp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802fa64: b570 push {r4, r5, r6, lr} 802fa66: 4616 mov r6, r2 struct udp_pcb *ipcb; if (pcb->local_port == 0) { 802fa68: 8a42 ldrh r2, [r0, #18] * * @see udp_disconnect() */ err_t udp_connect(struct udp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { 802fa6a: 4604 mov r4, r0 802fa6c: 460d mov r5, r1 struct udp_pcb *ipcb; if (pcb->local_port == 0) { 802fa6e: b10a cbz r2, 802fa74 if (err != ERR_OK) { return err; } } ip_addr_set(&pcb->remote_ip, ipaddr); 802fa70: b935 cbnz r5, 802fa80 802fa72: e006 b.n 802fa82 udp_connect(struct udp_pcb *pcb, ip_addr_t *ipaddr, u16_t port) { struct udp_pcb *ipcb; if (pcb->local_port == 0) { err_t err = udp_bind(pcb, &pcb->local_ip, pcb->local_port); 802fa74: 4601 mov r1, r0 802fa76: f7ff ff2b bl 802f8d0 if (err != ERR_OK) { 802fa7a: 2800 cmp r0, #0 802fa7c: d0f8 beq.n 802fa70 802fa7e: e013 b.n 802faa8 return err; } } ip_addr_set(&pcb->remote_ip, ipaddr); 802fa80: 682d ldr r5, [r5, #0] pcb->remote_port = port; pcb->flags |= UDP_FLAGS_CONNECTED; 802fa82: 7c23 ldrb r3, [r4, #16] ip4_addr1_16(&pcb->local_ip), ip4_addr2_16(&pcb->local_ip), ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port)); /* Insert UDP PCB into the list of active UDP PCBs. */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802fa84: 4a09 ldr r2, [pc, #36] ; (802faac ) if (err != ERR_OK) { return err; } } ip_addr_set(&pcb->remote_ip, ipaddr); 802fa86: 6065 str r5, [r4, #4] pcb->remote_port = port; pcb->flags |= UDP_FLAGS_CONNECTED; 802fa88: f043 0304 orr.w r3, r3, #4 802fa8c: 7423 strb r3, [r4, #16] ip4_addr1_16(&pcb->local_ip), ip4_addr2_16(&pcb->local_ip), ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port)); /* Insert UDP PCB into the list of active UDP PCBs. */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802fa8e: 6813 ldr r3, [r2, #0] return err; } } ip_addr_set(&pcb->remote_ip, ipaddr); pcb->remote_port = port; 802fa90: 82a6 strh r6, [r4, #20] ip4_addr1_16(&pcb->local_ip), ip4_addr2_16(&pcb->local_ip), ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port)); /* Insert UDP PCB into the list of active UDP PCBs. */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802fa92: 4618 mov r0, r3 802fa94: e002 b.n 802fa9c if (pcb == ipcb) { 802fa96: 4284 cmp r4, r0 802fa98: d005 beq.n 802faa6 ip4_addr1_16(&pcb->local_ip), ip4_addr2_16(&pcb->local_ip), ip4_addr3_16(&pcb->local_ip), ip4_addr4_16(&pcb->local_ip), pcb->local_port)); /* Insert UDP PCB into the list of active UDP PCBs. */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { 802fa9a: 68c0 ldr r0, [r0, #12] 802fa9c: 2800 cmp r0, #0 802fa9e: d1fa bne.n 802fa96 /* already on the list, just return */ return ERR_OK; } } /* PCB not yet on the list, add PCB now */ pcb->next = udp_pcbs; 802faa0: 60e3 str r3, [r4, #12] udp_pcbs = pcb; 802faa2: 6014 str r4, [r2, #0] return ERR_OK; 802faa4: e000 b.n 802faa8 /* Insert UDP PCB into the list of active UDP PCBs. */ for (ipcb = udp_pcbs; ipcb != NULL; ipcb = ipcb->next) { if (pcb == ipcb) { /* already on the list, just return */ return ERR_OK; 802faa6: 2000 movs r0, #0 } /* PCB not yet on the list, add PCB now */ pcb->next = udp_pcbs; udp_pcbs = pcb; return ERR_OK; } 802faa8: b240 sxtb r0, r0 802faaa: bd70 pop {r4, r5, r6, pc} 802faac: 20010ff8 .word 0x20010ff8 0802fab0 : */ void udp_disconnect(struct udp_pcb *pcb) { /* reset remote address association */ ip_addr_set_any(&pcb->remote_ip); 802fab0: 2300 movs r3, #0 802fab2: 6043 str r3, [r0, #4] pcb->remote_port = 0; 802fab4: 8283 strh r3, [r0, #20] /* mark PCB as unconnected */ pcb->flags &= ~UDP_FLAGS_CONNECTED; 802fab6: 7c03 ldrb r3, [r0, #16] 802fab8: f023 0304 bic.w r3, r3, #4 802fabc: 7403 strb r3, [r0, #16] 802fabe: 4770 bx lr 0802fac0 : */ void udp_recv(struct udp_pcb *pcb, udp_recv_fn recv, void *recv_arg) { /* remember recv() callback and user data */ pcb->recv = recv; 802fac0: 6181 str r1, [r0, #24] pcb->recv_arg = recv_arg; 802fac2: 61c2 str r2, [r0, #28] 802fac4: 4770 bx lr 802fac6: 0000 movs r0, r0 0802fac8 : * * @see udp_new() */ void udp_remove(struct udp_pcb *pcb) { 802fac8: b510 push {r4, lr} 802faca: 4604 mov r4, r0 struct udp_pcb *pcb2; snmp_delete_udpidx_tree(pcb); 802facc: f002 f914 bl 8031cf8 /* pcb to be removed is first in list? */ if (udp_pcbs == pcb) { 802fad0: 4a0a ldr r2, [pc, #40] ; (802fafc ) 802fad2: 6813 ldr r3, [r2, #0] 802fad4: 42a3 cmp r3, r4 802fad6: d109 bne.n 802faec /* make list start at 2nd pcb */ udp_pcbs = udp_pcbs->next; 802fad8: 68e3 ldr r3, [r4, #12] 802fada: 6013 str r3, [r2, #0] 802fadc: e008 b.n 802faf0 /* pcb not 1st in list */ } else { for (pcb2 = udp_pcbs; pcb2 != NULL; pcb2 = pcb2->next) { /* find pcb in udp_pcbs list */ if (pcb2->next != NULL && pcb2->next == pcb) { 802fade: 68da ldr r2, [r3, #12] 802fae0: b11a cbz r2, 802faea 802fae2: 42a2 cmp r2, r4 /* remove pcb from list */ pcb2->next = pcb->next; 802fae4: bf04 itt eq 802fae6: 68e2 ldreq r2, [r4, #12] 802fae8: 60da streq r2, [r3, #12] if (udp_pcbs == pcb) { /* make list start at 2nd pcb */ udp_pcbs = udp_pcbs->next; /* pcb not 1st in list */ } else { for (pcb2 = udp_pcbs; pcb2 != NULL; pcb2 = pcb2->next) { 802faea: 68db ldr r3, [r3, #12] 802faec: 2b00 cmp r3, #0 802faee: d1f6 bne.n 802fade /* remove pcb from list */ pcb2->next = pcb->next; } } } memp_free(MEMP_UDP_PCB, pcb); 802faf0: 2001 movs r0, #1 802faf2: 4621 mov r1, r4 } 802faf4: e8bd 4010 ldmia.w sp!, {r4, lr} /* remove pcb from list */ pcb2->next = pcb->next; } } } memp_free(MEMP_UDP_PCB, pcb); 802faf8: f7fd b990 b.w 802ce1c 802fafc: 20010ff8 .word 0x20010ff8 0802fb00 : * * @see udp_remove() */ struct udp_pcb * udp_new(void) { 802fb00: b510 push {r4, lr} struct udp_pcb *pcb; pcb = (struct udp_pcb *)memp_malloc(MEMP_UDP_PCB); 802fb02: 2001 movs r0, #1 802fb04: f7fd f974 bl 802cdf0 /* could allocate UDP PCB? */ if (pcb != NULL) { 802fb08: 4604 mov r4, r0 802fb0a: b128 cbz r0, 802fb18 /* UDP Lite: by initializing to all zeroes, chksum_len is set to 0 * which means checksum is generated over the whole datagram per default * (recommended as default by RFC 3828). */ /* initialize PCB to all zeroes */ memset(pcb, 0, sizeof(struct udp_pcb)); 802fb0c: 2100 movs r1, #0 802fb0e: 2220 movs r2, #32 802fb10: f7f1 ffd6 bl 8021ac0 pcb->ttl = UDP_TTL; 802fb14: 23ff movs r3, #255 ; 0xff 802fb16: 72a3 strb r3, [r4, #10] } return pcb; } 802fb18: 4620 mov r0, r4 802fb1a: bd10 pop {r4, pc} 0802fb1c : * @param p the icmp echo request packet, p->payload pointing to the ip header * @param inp the netif on which this packet was received */ void icmp_input(struct pbuf *p, struct netif *inp) { 802fb1c: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} 802fb20: 4604 mov r4, r0 802fb22: b085 sub sp, #20 802fb24: 460f mov r7, r1 struct icmp_echo_hdr *iecho; struct ip_hdr *iphdr; s16_t hlen; ICMP_STATS_INC(icmp.recv); snmp_inc_icmpinmsgs(); 802fb26: f002 f81b bl 8031b60 iphdr = (struct ip_hdr *)p->payload; 802fb2a: 6865 ldr r5, [r4, #4] hlen = IPH_HL(iphdr) * 4; 802fb2c: f895 8000 ldrb.w r8, [r5] 802fb30: f008 080f and.w r8, r8, #15 802fb34: ea4f 0888 mov.w r8, r8, lsl #2 if (pbuf_header(p, -hlen) || (p->tot_len < sizeof(u16_t)*2)) { 802fb38: f1c8 0900 rsb r9, r8, #0 802fb3c: 4620 mov r0, r4 802fb3e: fa0f f189 sxth.w r1, r9 802fb42: f7fd fa4a bl 802cfda 802fb46: 2800 cmp r0, #0 802fb48: d172 bne.n 802fc30 802fb4a: 8923 ldrh r3, [r4, #8] 802fb4c: 2b03 cmp r3, #3 802fb4e: d96f bls.n 802fc30 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: short ICMP (%"U16_F" bytes) received\n", p->tot_len)); goto lenerr; } type = *((u8_t *)p->payload); 802fb50: 6863 ldr r3, [r4, #4] #ifdef LWIP_DEBUG code = *(((u8_t *)p->payload)+1); #endif /* LWIP_DEBUG */ switch (type) { 802fb52: 781b ldrb r3, [r3, #0] 802fb54: 2b08 cmp r3, #8 802fb56: d165 bne.n 802fc24 #if !LWIP_MULTICAST_PING || !LWIP_BROADCAST_PING { int accepted = 1; #if !LWIP_MULTICAST_PING /* multicast destination address? */ if (ip_addr_ismulticast(¤t_iphdr_dest)) { 802fb58: 4b39 ldr r3, [pc, #228] ; (802fc40 ) 802fb5a: 681e ldr r6, [r3, #0] accepted = 0; } #endif /* LWIP_MULTICAST_PING */ #if !LWIP_BROADCAST_PING /* broadcast destination address? */ if (ip_addr_isbroadcast(¤t_iphdr_dest, inp)) { 802fb5c: 4639 mov r1, r7 802fb5e: 4630 mov r0, r6 802fb60: f000 f900 bl 802fd64 802fb64: 2800 cmp r0, #0 802fb66: d15d bne.n 802fc24 #if !LWIP_MULTICAST_PING || !LWIP_BROADCAST_PING { int accepted = 1; #if !LWIP_MULTICAST_PING /* multicast destination address? */ if (ip_addr_ismulticast(¤t_iphdr_dest)) { 802fb68: f006 06f0 and.w r6, r6, #240 ; 0xf0 if (ip_addr_isbroadcast(¤t_iphdr_dest, inp)) { accepted = 0; } #endif /* LWIP_BROADCAST_PING */ /* broadcast or multicast destination address not acceptd? */ if (!accepted) { 802fb6c: 2ee0 cmp r6, #224 ; 0xe0 802fb6e: d100 bne.n 802fb72 802fb70: e058 b.n 802fc24 return; } } #endif /* !LWIP_MULTICAST_PING || !LWIP_BROADCAST_PING */ LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: ping\n")); if (p->tot_len < sizeof(struct icmp_echo_hdr)) { 802fb72: 8923 ldrh r3, [r4, #8] 802fb74: 2b07 cmp r3, #7 802fb76: d95b bls.n 802fc30 LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: bad ICMP echo received\n")); goto lenerr; } if (inet_chksum_pbuf(p) != 0) { 802fb78: 4620 mov r0, r4 802fb7a: f000 f8cf bl 802fd1c 802fb7e: b100 cbz r0, 802fb82 802fb80: e056 b.n 802fc30 ICMP_STATS_INC(icmp.chkerr); snmp_inc_icmpinerrors(); return; } #if LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN if (pbuf_header(p, (PBUF_IP_HLEN + PBUF_LINK_HLEN))) { 802fb82: 4620 mov r0, r4 802fb84: 2122 movs r1, #34 ; 0x22 ICMP_STATS_INC(icmp.recv); snmp_inc_icmpinmsgs(); iphdr = (struct ip_hdr *)p->payload; hlen = IPH_HL(iphdr) * 4; 802fb86: fa1f f888 uxth.w r8, r8 ICMP_STATS_INC(icmp.chkerr); snmp_inc_icmpinerrors(); return; } #if LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN if (pbuf_header(p, (PBUF_IP_HLEN + PBUF_LINK_HLEN))) { 802fb8a: f7fd fa26 bl 802cfda 802fb8e: b1f8 cbz r0, 802fbd0 /* p is not big enough to contain link headers * allocate a new one and copy p into it */ struct pbuf *r; /* switch p->payload to ip header */ if (pbuf_header(p, hlen)) { 802fb90: 4620 mov r0, r4 802fb92: 4641 mov r1, r8 802fb94: f7fd fa21 bl 802cfda 802fb98: 4602 mov r2, r0 802fb9a: 2800 cmp r0, #0 802fb9c: d148 bne.n 802fc30 LWIP_ASSERT("icmp_input: moving p->payload to ip header failed\n", 0); goto memerr; } /* allocate new packet buffer with space for link headers */ r = pbuf_alloc(PBUF_LINK, p->tot_len, PBUF_RAM); 802fb9e: 2002 movs r0, #2 802fba0: 8921 ldrh r1, [r4, #8] 802fba2: f7fd fa92 bl 802d0ca if (r == NULL) { 802fba6: 4606 mov r6, r0 802fba8: 2800 cmp r0, #0 802fbaa: d041 beq.n 802fc30 goto memerr; } LWIP_ASSERT("check that first pbuf can hold struct the ICMP header", (r->len >= hlen + sizeof(struct icmp_echo_hdr))); /* copy the whole packet including ip header */ if (pbuf_copy(r, p) != ERR_OK) { 802fbac: 4621 mov r1, r4 802fbae: f7fd fb43 bl 802d238 802fbb2: 2800 cmp r0, #0 802fbb4: d13c bne.n 802fc30 LWIP_ASSERT("icmp_input: copying to new pbuf failed\n", 0); goto memerr; } iphdr = (struct ip_hdr *)r->payload; /* switch r->payload back to icmp header */ if (pbuf_header(r, -hlen)) { 802fbb6: 4630 mov r0, r6 802fbb8: fa0f f189 sxth.w r1, r9 /* copy the whole packet including ip header */ if (pbuf_copy(r, p) != ERR_OK) { LWIP_ASSERT("icmp_input: copying to new pbuf failed\n", 0); goto memerr; } iphdr = (struct ip_hdr *)r->payload; 802fbbc: 6875 ldr r5, [r6, #4] /* switch r->payload back to icmp header */ if (pbuf_header(r, -hlen)) { 802fbbe: f7fd fa0c bl 802cfda 802fbc2: 2800 cmp r0, #0 802fbc4: d134 bne.n 802fc30 LWIP_ASSERT("icmp_input: restoring original p->payload failed\n", 0); goto memerr; } /* free the original p */ pbuf_free(p); 802fbc6: 4620 mov r0, r4 802fbc8: f7fd fa32 bl 802d030 802fbcc: 4634 mov r4, r6 802fbce: e006 b.n 802fbde /* we now have an identical copy of p that has room for link headers */ p = r; } else { /* restore p->payload to point to icmp header */ if (pbuf_header(p, -(s16_t)(PBUF_IP_HLEN + PBUF_LINK_HLEN))) { 802fbd0: 4620 mov r0, r4 802fbd2: f06f 0121 mvn.w r1, #33 ; 0x21 802fbd6: f7fd fa00 bl 802cfda 802fbda: 2800 cmp r0, #0 802fbdc: d128 bne.n 802fc30 #endif /* LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN */ /* At this point, all checks are OK. */ /* We generate an answer by switching the dest and src ip addresses, * setting the icmp type to ECHO_RESPONSE and updating the checksum. */ iecho = (struct icmp_echo_hdr *)p->payload; ip_addr_copy(iphdr->src, *ip_current_dest_addr()); 802fbde: f8df 9060 ldr.w r9, [pc, #96] ; 802fc40 } #endif /* LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN */ /* At this point, all checks are OK. */ /* We generate an answer by switching the dest and src ip addresses, * setting the icmp type to ECHO_RESPONSE and updating the checksum. */ iecho = (struct icmp_echo_hdr *)p->payload; 802fbe2: 6863 ldr r3, [r4, #4] ip_addr_copy(iphdr->src, *ip_current_dest_addr()); 802fbe4: f8d9 2000 ldr.w r2, [r9] 802fbe8: 60ea str r2, [r5, #12] ip_addr_copy(iphdr->dest, *ip_current_src_addr()); 802fbea: 4a16 ldr r2, [pc, #88] ; (802fc44 ) 802fbec: 6812 ldr r2, [r2, #0] #else // CHECKSUM_GEN_ICMP iecho->chksum = 0; #endif // CHECKSUM_GEN_ICMP */ /* Set the correct TTL and recalculate the header checksum. */ IPH_TTL_SET(iphdr, ICMP_TTL); 802fbee: 26ff movs r6, #255 ; 0xff /* At this point, all checks are OK. */ /* We generate an answer by switching the dest and src ip addresses, * setting the icmp type to ECHO_RESPONSE and updating the checksum. */ iecho = (struct icmp_echo_hdr *)p->payload; ip_addr_copy(iphdr->src, *ip_current_dest_addr()); ip_addr_copy(iphdr->dest, *ip_current_src_addr()); 802fbf0: 612a str r2, [r5, #16] ICMPH_TYPE_SET(iecho, ICMP_ER); 802fbf2: 2200 movs r2, #0 802fbf4: 701a strb r2, [r3, #0] //----------------------------------------------------------- // Добавил фикс 15.08.15. // Фикс исправляет баг с пингом. #ifdef CHECKSUM_BY_HARDWARE iecho->chksum = 0; 802fbf6: 709a strb r2, [r3, #2] 802fbf8: 70da strb r2, [r3, #3] iecho->chksum = 0; #endif // CHECKSUM_GEN_ICMP */ /* Set the correct TTL and recalculate the header checksum. */ IPH_TTL_SET(iphdr, ICMP_TTL); IPH_CHKSUM_SET(iphdr, 0); 802fbfa: 72aa strb r2, [r5, #10] 802fbfc: 72ea strb r2, [r5, #11] #else // CHECKSUM_GEN_ICMP iecho->chksum = 0; #endif // CHECKSUM_GEN_ICMP */ /* Set the correct TTL and recalculate the header checksum. */ IPH_TTL_SET(iphdr, ICMP_TTL); 802fbfe: 722e strb r6, [r5, #8] IPH_CHKSUM_SET(iphdr, inet_chksum(iphdr, IP_HLEN)); #endif /* CHECKSUM_GEN_IP */ ICMP_STATS_INC(icmp.xmit); /* increase number of messages attempted to send */ snmp_inc_icmpoutmsgs(); 802fc00: f001 ffbe bl 8031b80 /* increase number of echo replies attempted to send */ snmp_inc_icmpoutechoreps(); 802fc04: f001 ffcc bl 8031ba0 if(pbuf_header(p, hlen)) { 802fc08: 4620 mov r0, r4 802fc0a: 4641 mov r1, r8 802fc0c: f7fd f9e5 bl 802cfda 802fc10: 4602 mov r2, r0 802fc12: b938 cbnz r0, 802fc24 LWIP_ASSERT("Can't move over header in packet", 0); } else { err_t ret; /* send an ICMP packet, src addr is the dest addr of the curren packet */ ret = ip_output_if(p, ip_current_dest_addr(), IP_HDRINCL, 802fc14: 2301 movs r3, #1 802fc16: e88d 0089 stmia.w sp, {r0, r3, r7} 802fc1a: 4620 mov r0, r4 802fc1c: 4649 mov r1, r9 802fc1e: 4633 mov r3, r6 802fc20: f000 fa94 bl 803014c LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: ICMP type %"S16_F" code %"S16_F" not supported.\n", (s16_t)type, (s16_t)code)); ICMP_STATS_INC(icmp.proterr); ICMP_STATS_INC(icmp.drop); } pbuf_free(p); 802fc24: 4620 mov r0, r4 pbuf_free(p); ICMP_STATS_INC(icmp.err); snmp_inc_icmpinerrors(); return; #endif /* LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN */ } 802fc26: b005 add sp, #20 802fc28: e8bd 43f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, lr} LWIP_DEBUGF(ICMP_DEBUG, ("icmp_input: ICMP type %"S16_F" code %"S16_F" not supported.\n", (s16_t)type, (s16_t)code)); ICMP_STATS_INC(icmp.proterr); ICMP_STATS_INC(icmp.drop); } pbuf_free(p); 802fc2c: f7fd ba00 b.w 802d030 ICMP_STATS_INC(icmp.lenerr); snmp_inc_icmpinerrors(); return; #if LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN memerr: pbuf_free(p); 802fc30: 4620 mov r0, r4 802fc32: f7fd f9fd bl 802d030 ICMP_STATS_INC(icmp.err); snmp_inc_icmpinerrors(); return; #endif /* LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN */ } 802fc36: b005 add sp, #20 802fc38: e8bd 43f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, lr} return; #if LWIP_ICMP_ECHO_CHECK_INPUT_PBUF_LEN memerr: pbuf_free(p); ICMP_STATS_INC(icmp.err); snmp_inc_icmpinerrors(); 802fc3c: f001 bf98 b.w 8031b70 802fc40: 20011004 .word 0x20011004 802fc44: 20010ffc .word 0x20010ffc 0802fc48 : * p->payload pointing to the IP header * @param t type of the 'unreachable' packet */ void icmp_dest_unreach(struct pbuf *p, enum icmp_dur_type t) { 802fc48: e92d 41ff stmdb sp!, {r0, r1, r2, r3, r4, r5, r6, r7, r8, lr} 802fc4c: 4607 mov r7, r0 802fc4e: 460d mov r5, r1 /* we can use the echo header here */ struct icmp_echo_hdr *icmphdr; ip_addr_t iphdr_src; /* ICMP header + IP header + 8 bytes of data */ q = pbuf_alloc(PBUF_IP, sizeof(struct icmp_echo_hdr) + IP_HLEN + ICMP_DEST_UNREACH_DATASIZE, 802fc50: 2001 movs r0, #1 802fc52: 2124 movs r1, #36 ; 0x24 802fc54: 2200 movs r2, #0 802fc56: f7fd fa38 bl 802d0ca PBUF_RAM); if (q == NULL) { 802fc5a: 4606 mov r6, r0 802fc5c: b358 cbz r0, 802fcb6 ip_addr_debug_print(ICMP_DEBUG, &(iphdr->src)); LWIP_DEBUGF(ICMP_DEBUG, (" to ")); ip_addr_debug_print(ICMP_DEBUG, &(iphdr->dest)); LWIP_DEBUGF(ICMP_DEBUG, ("\n")); icmphdr = (struct icmp_echo_hdr *)q->payload; 802fc5e: 6844 ldr r4, [r0, #4] return; } LWIP_ASSERT("check that first pbuf can hold icmp message", (q->len >= (sizeof(struct icmp_echo_hdr) + IP_HLEN + ICMP_DEST_UNREACH_DATASIZE))); iphdr = (struct ip_hdr *)p->payload; 802fc60: f8d7 8004 ldr.w r8, [r7, #4] ip_addr_debug_print(ICMP_DEBUG, &(iphdr->dest)); LWIP_DEBUGF(ICMP_DEBUG, ("\n")); icmphdr = (struct icmp_echo_hdr *)q->payload; icmphdr->type = type; icmphdr->code = code; 802fc64: 7065 strb r5, [r4, #1] LWIP_DEBUGF(ICMP_DEBUG, (" to ")); ip_addr_debug_print(ICMP_DEBUG, &(iphdr->dest)); LWIP_DEBUGF(ICMP_DEBUG, ("\n")); icmphdr = (struct icmp_echo_hdr *)q->payload; icmphdr->type = type; 802fc66: 2303 movs r3, #3 icmphdr->code = code; icmphdr->id = 0; 802fc68: 2500 movs r5, #0 LWIP_DEBUGF(ICMP_DEBUG, (" to ")); ip_addr_debug_print(ICMP_DEBUG, &(iphdr->dest)); LWIP_DEBUGF(ICMP_DEBUG, ("\n")); icmphdr = (struct icmp_echo_hdr *)q->payload; icmphdr->type = type; 802fc6a: 7023 strb r3, [r4, #0] icmphdr->code = code; icmphdr->id = 0; 802fc6c: 7125 strb r5, [r4, #4] 802fc6e: 7165 strb r5, [r4, #5] icmphdr->seqno = 0; 802fc70: 71a5 strb r5, [r4, #6] 802fc72: 71e5 strb r5, [r4, #7] /* copy fields from original packet */ SMEMCPY((u8_t *)q->payload + sizeof(struct icmp_echo_hdr), (u8_t *)p->payload, 802fc74: 6840 ldr r0, [r0, #4] 802fc76: 6879 ldr r1, [r7, #4] 802fc78: 221c movs r2, #28 802fc7a: 3008 adds r0, #8 802fc7c: f7f1 fe66 bl 802194c IP_HLEN + ICMP_DEST_UNREACH_DATASIZE); /* calculate checksum */ icmphdr->chksum = 0; 802fc80: 70a5 strb r5, [r4, #2] 802fc82: 70e5 strb r5, [r4, #3] icmphdr->chksum = inet_chksum(icmphdr, q->len); 802fc84: 8971 ldrh r1, [r6, #10] 802fc86: 4620 mov r0, r4 802fc88: f000 f842 bl 802fd10 802fc8c: 8060 strh r0, [r4, #2] ICMP_STATS_INC(icmp.xmit); /* increase number of messages attempted to send */ snmp_inc_icmpoutmsgs(); 802fc8e: f001 ff77 bl 8031b80 /* increase number of destination unreachable messages attempted to send */ snmp_inc_icmpouttimeexcds(); 802fc92: f001 ff7d bl 8031b90 ip_addr_copy(iphdr_src, iphdr->src); 802fc96: f8d8 300c ldr.w r3, [r8, #12] 802fc9a: aa04 add r2, sp, #16 ip_output(q, NULL, &iphdr_src, ICMP_TTL, 0, IP_PROTO_ICMP); 802fc9c: 4630 mov r0, r6 ICMP_STATS_INC(icmp.xmit); /* increase number of messages attempted to send */ snmp_inc_icmpoutmsgs(); /* increase number of destination unreachable messages attempted to send */ snmp_inc_icmpouttimeexcds(); ip_addr_copy(iphdr_src, iphdr->src); 802fc9e: f842 3d04 str.w r3, [r2, #-4]! ip_output(q, NULL, &iphdr_src, ICMP_TTL, 0, IP_PROTO_ICMP); 802fca2: 2301 movs r3, #1 802fca4: 9301 str r3, [sp, #4] 802fca6: 9500 str r5, [sp, #0] 802fca8: 4629 mov r1, r5 802fcaa: 23ff movs r3, #255 ; 0xff 802fcac: f000 fa9e bl 80301ec pbuf_free(q); 802fcb0: 4630 mov r0, r6 802fcb2: f7fd f9bd bl 802d030 */ void icmp_dest_unreach(struct pbuf *p, enum icmp_dur_type t) { icmp_send_response(p, ICMP_DUR, t); } 802fcb6: e8bd 81ff ldmia.w sp!, {r0, r1, r2, r3, r4, r5, r6, r7, r8, pc} 0802fcba : * @return host order (!) lwip checksum (non-inverted Internet sum) */ static u16_t lwip_standard_chksum(void *dataptr, int len) { 802fcba: b513 push {r0, r1, r4, lr} u8_t *pb = (u8_t *)dataptr; u16_t *ps, t = 0; 802fcbc: 2300 movs r3, #0 u32_t sum = 0; int odd = ((mem_ptr_t)pb & 1); /* Get aligned to u16_t */ if (odd && len > 0) { 802fcbe: f010 0201 ands.w r2, r0, #1 static u16_t lwip_standard_chksum(void *dataptr, int len) { u8_t *pb = (u8_t *)dataptr; u16_t *ps, t = 0; 802fcc2: f8ad 3006 strh.w r3, [sp, #6] u32_t sum = 0; int odd = ((mem_ptr_t)pb & 1); /* Get aligned to u16_t */ if (odd && len > 0) { 802fcc6: d006 beq.n 802fcd6 802fcc8: 4299 cmp r1, r3 802fcca: dd04 ble.n 802fcd6 ((u8_t *)&t)[1] = *pb++; 802fccc: f810 3b01 ldrb.w r3, [r0], #1 len--; 802fcd0: 3901 subs r1, #1 u32_t sum = 0; int odd = ((mem_ptr_t)pb & 1); /* Get aligned to u16_t */ if (odd && len > 0) { ((u8_t *)&t)[1] = *pb++; 802fcd2: f88d 3007 strb.w r3, [sp, #7] static u16_t lwip_standard_chksum(void *dataptr, int len) { u8_t *pb = (u8_t *)dataptr; u16_t *ps, t = 0; u32_t sum = 0; 802fcd6: 2300 movs r3, #0 len--; } /* Add the bulk of the data */ ps = (u16_t *)(void *)pb; while (len > 1) { 802fcd8: e003 b.n 802fce2 sum += *ps++; 802fcda: f830 4b02 ldrh.w r4, [r0], #2 len -= 2; 802fcde: 3902 subs r1, #2 } /* Add the bulk of the data */ ps = (u16_t *)(void *)pb; while (len > 1) { sum += *ps++; 802fce0: 191b adds r3, r3, r4 len--; } /* Add the bulk of the data */ ps = (u16_t *)(void *)pb; while (len > 1) { 802fce2: 2901 cmp r1, #1 802fce4: dcf9 bgt.n 802fcda len -= 2; } /* Consume left-over byte, if any */ if (len > 0) { ((u8_t *)&t)[0] = *(u8_t *)ps; 802fce6: bf04 itt eq 802fce8: 7801 ldrbeq r1, [r0, #0] 802fcea: f88d 1006 strbeq.w r1, [sp, #6] } /* Add end bytes */ sum += t; 802fcee: f8bd 0006 ldrh.w r0, [sp, #6] 802fcf2: 181b adds r3, r3, r0 /* Fold 32-bit sum to 16 bits calling this twice is propably faster than if statements... */ sum = FOLD_U32T(sum); 802fcf4: b298 uxth r0, r3 802fcf6: eb00 4313 add.w r3, r0, r3, lsr #16 sum = FOLD_U32T(sum); 802fcfa: b298 uxth r0, r3 802fcfc: eb00 4013 add.w r0, r0, r3, lsr #16 /* Swap if alignment was odd */ if (odd) { 802fd00: b122 cbz r2, 802fd0c sum = SWAP_BYTES_IN_WORD(sum); 802fd02: 0603 lsls r3, r0, #24 802fd04: f3c0 2007 ubfx r0, r0, #8, #8 802fd08: ea40 4013 orr.w r0, r0, r3, lsr #16 } return (u16_t)sum; } 802fd0c: b280 uxth r0, r0 802fd0e: bd1c pop {r2, r3, r4, pc} 0802fd10 : * @return checksum (as u16_t) to be saved directly in the protocol header */ u16_t inet_chksum(void *dataptr, u16_t len) { 802fd10: b508 push {r3, lr} return ~LWIP_CHKSUM(dataptr, len); 802fd12: f7ff ffd2 bl 802fcba 802fd16: 43c0 mvns r0, r0 } 802fd18: b280 uxth r0, r0 802fd1a: bd08 pop {r3, pc} 0802fd1c : * @param p pbuf chain over that the checksum should be calculated * @return checksum (as u16_t) to be saved directly in the protocol header */ u16_t inet_chksum_pbuf(struct pbuf *p) { 802fd1c: b570 push {r4, r5, r6, lr} u32_t acc; struct pbuf *q; u8_t swapped; acc = 0; swapped = 0; 802fd1e: 2600 movs r6, #0 * @param p pbuf chain over that the checksum should be calculated * @return checksum (as u16_t) to be saved directly in the protocol header */ u16_t inet_chksum_pbuf(struct pbuf *p) { 802fd20: 4605 mov r5, r0 u32_t acc; struct pbuf *q; u8_t swapped; acc = 0; 802fd22: 4634 mov r4, r6 swapped = 0; for(q = p; q != NULL; q = q->next) { 802fd24: e013 b.n 802fd4e acc += LWIP_CHKSUM(q->payload, q->len); 802fd26: 8969 ldrh r1, [r5, #10] 802fd28: 6868 ldr r0, [r5, #4] 802fd2a: f7ff ffc6 bl 802fcba acc = FOLD_U32T(acc); if (q->len % 2 != 0) { 802fd2e: 896b ldrh r3, [r5, #10] u8_t swapped; acc = 0; swapped = 0; for(q = p; q != NULL; q = q->next) { acc += LWIP_CHKSUM(q->payload, q->len); 802fd30: 1900 adds r0, r0, r4 acc = FOLD_U32T(acc); 802fd32: b284 uxth r4, r0 if (q->len % 2 != 0) { 802fd34: 07d9 lsls r1, r3, #31 acc = 0; swapped = 0; for(q = p; q != NULL; q = q->next) { acc += LWIP_CHKSUM(q->payload, q->len); acc = FOLD_U32T(acc); 802fd36: eb04 4410 add.w r4, r4, r0, lsr #16 if (q->len % 2 != 0) { 802fd3a: d507 bpl.n 802fd4c swapped = 1 - swapped; acc = SWAP_BYTES_IN_WORD(acc); 802fd3c: 0623 lsls r3, r4, #24 swapped = 0; for(q = p; q != NULL; q = q->next) { acc += LWIP_CHKSUM(q->payload, q->len); acc = FOLD_U32T(acc); if (q->len % 2 != 0) { swapped = 1 - swapped; 802fd3e: f1c6 0601 rsb r6, r6, #1 acc = SWAP_BYTES_IN_WORD(acc); 802fd42: f3c4 2407 ubfx r4, r4, #8, #8 swapped = 0; for(q = p; q != NULL; q = q->next) { acc += LWIP_CHKSUM(q->payload, q->len); acc = FOLD_U32T(acc); if (q->len % 2 != 0) { swapped = 1 - swapped; 802fd46: b2f6 uxtb r6, r6 acc = SWAP_BYTES_IN_WORD(acc); 802fd48: ea44 4413 orr.w r4, r4, r3, lsr #16 struct pbuf *q; u8_t swapped; acc = 0; swapped = 0; for(q = p; q != NULL; q = q->next) { 802fd4c: 682d ldr r5, [r5, #0] 802fd4e: 2d00 cmp r5, #0 802fd50: d1e9 bne.n 802fd26 swapped = 1 - swapped; acc = SWAP_BYTES_IN_WORD(acc); } } if (swapped) { 802fd52: b126 cbz r6, 802fd5e acc = SWAP_BYTES_IN_WORD(acc); 802fd54: 0623 lsls r3, r4, #24 802fd56: f3c4 2407 ubfx r4, r4, #8, #8 802fd5a: ea44 4413 orr.w r4, r4, r3, lsr #16 } return (u16_t)~(acc & 0xffffUL); 802fd5e: 43e0 mvns r0, r4 } 802fd60: b280 uxth r0, r0 802fd62: bd70 pop {r4, r5, r6, pc} 0802fd64 : { ip_addr_t ipaddr; ip4_addr_set_u32(&ipaddr, addr); /* all ones (broadcast) or all zeroes (old skool broadcast) */ if ((~addr == IPADDR_ANY) || 802fd64: 1e43 subs r3, r0, #1 802fd66: 3303 adds r3, #3 802fd68: d811 bhi.n 802fd8e (addr == IPADDR_ANY)) { return 1; /* no broadcast support on this network interface? */ } else if ((netif->flags & NETIF_FLAG_BROADCAST) == 0) { 802fd6a: f891 302d ldrb.w r3, [r1, #45] ; 0x2d 802fd6e: f003 0302 and.w r3, r3, #2 802fd72: b2db uxtb r3, r3 802fd74: b16b cbz r3, 802fd92 /* the given address cannot be a broadcast address * nor can we check against any broadcast addresses */ return 0; /* address matches network interface address exactly? => no broadcast */ } else if (addr == ip4_addr_get_u32(&netif->ip_addr)) { 802fd76: 684a ldr r2, [r1, #4] 802fd78: 4290 cmp r0, r2 802fd7a: d00a beq.n 802fd92 return 0; /* on the same (sub) network... */ } else if (ip_addr_netcmp(&ipaddr, &(netif->ip_addr), &(netif->netmask)) 802fd7c: 688b ldr r3, [r1, #8] 802fd7e: 4042 eors r2, r0 802fd80: 421a tst r2, r3 802fd82: d000 beq.n 802fd86 802fd84: e005 b.n 802fd92 /* ...and host identifier bits are all ones? =>... */ && ((addr & ~ip4_addr_get_u32(&netif->netmask)) == 802fd86: 43db mvns r3, r3 802fd88: 4018 ands r0, r3 802fd8a: 4298 cmp r0, r3 802fd8c: d101 bne.n 802fd92 ip4_addr_set_u32(&ipaddr, addr); /* all ones (broadcast) or all zeroes (old skool broadcast) */ if ((~addr == IPADDR_ANY) || (addr == IPADDR_ANY)) { return 1; 802fd8e: 2001 movs r0, #1 802fd90: 4770 bx lr /* no broadcast support on this network interface? */ } else if ((netif->flags & NETIF_FLAG_BROADCAST) == 0) { /* the given address cannot be a broadcast address * nor can we check against any broadcast addresses */ return 0; 802fd92: 2000 movs r0, #0 /* => network broadcast address */ return 1; } else { return 0; } } 802fd94: 4770 bx lr 0802fd96 : * @param addr pointer to which to save the ip address in network order * @return 1 if cp could be converted to addr, 0 on failure */ int ipaddr_aton(const char *cp, ip_addr_t *addr) { 802fd96: b5f0 push {r4, r5, r6, r7, lr} u8_t base; char c; u32_t parts[4]; u32_t *pp = parts; c = *cp; 802fd98: 7803 ldrb r3, [r0, #0] * @param addr pointer to which to save the ip address in network order * @return 1 if cp could be converted to addr, 0 on failure */ int ipaddr_aton(const char *cp, ip_addr_t *addr) { 802fd9a: b085 sub sp, #20 802fd9c: 460e mov r6, r1 u8_t base; char c; u32_t parts[4]; u32_t *pp = parts; c = *cp; 802fd9e: 2400 movs r4, #0 * @param cp IP address in ascii represenation (e.g. "127.0.0.1") * @param addr pointer to which to save the ip address in network order * @return 1 if cp could be converted to addr, 0 on failure */ int ipaddr_aton(const char *cp, ip_addr_t *addr) 802fda0: aa00 add r2, sp, #0 802fda2: 18a7 adds r7, r4, r2 /* * Collect number up to ``.''. * Values are specified as for C: * 0x=hex, 0=octal, 1-9=decimal. */ if (!isdigit(c)) 802fda4: f1a3 0230 sub.w r2, r3, #48 ; 0x30 802fda8: 2a09 cmp r2, #9 802fdaa: d86d bhi.n 802fe88 return (0); val = 0; base = 10; if (c == '0') { 802fdac: 2b30 cmp r3, #48 ; 0x30 802fdae: d10b bne.n 802fdc8 c = *++cp; 802fdb0: 7843 ldrb r3, [r0, #1] if (c == 'x' || c == 'X') { 802fdb2: 2b78 cmp r3, #120 ; 0x78 802fdb4: d004 beq.n 802fdc0 802fdb6: 2b58 cmp r3, #88 ; 0x58 802fdb8: d002 beq.n 802fdc0 if (!isdigit(c)) return (0); val = 0; base = 10; if (c == '0') { c = *++cp; 802fdba: 3001 adds r0, #1 if (c == 'x' || c == 'X') { base = 16; c = *++cp; } else base = 8; 802fdbc: 2508 movs r5, #8 802fdbe: e004 b.n 802fdca base = 10; if (c == '0') { c = *++cp; if (c == 'x' || c == 'X') { base = 16; c = *++cp; 802fdc0: 7883 ldrb r3, [r0, #2] val = 0; base = 10; if (c == '0') { c = *++cp; if (c == 'x' || c == 'X') { base = 16; 802fdc2: 2510 movs r5, #16 c = *++cp; 802fdc4: 3002 adds r0, #2 802fdc6: e000 b.n 802fdca * 0x=hex, 0=octal, 1-9=decimal. */ if (!isdigit(c)) return (0); val = 0; base = 10; 802fdc8: 250a movs r5, #10 802fdca: 4602 mov r2, r0 if (c == '0') { c = *++cp; if (c == 'x' || c == 'X') { base = 16; 802fdcc: 2000 movs r0, #0 802fdce: e000 b.n 802fdd2 802fdd0: 3201 adds r2, #1 c = *++cp; } else base = 8; } for (;;) { if (isdigit(c)) { 802fdd2: f1a3 0130 sub.w r1, r3, #48 ; 0x30 802fdd6: 2909 cmp r1, #9 802fdd8: d803 bhi.n 802fde2 val = (val * base) + (int)(c - '0'); 802fdda: fb05 3000 mla r0, r5, r0, r3 802fdde: 3830 subs r0, #48 ; 0x30 802fde0: e013 b.n 802fe0a c = *++cp; } else if (base == 16 && isxdigit(c)) { 802fde2: 2d10 cmp r5, #16 802fde4: d113 bne.n 802fe0e 802fde6: f1a3 0161 sub.w r1, r3, #97 ; 0x61 802fdea: b2c9 uxtb r1, r1 802fdec: 2905 cmp r1, #5 802fdee: d904 bls.n 802fdfa 802fdf0: f1a3 0c41 sub.w ip, r3, #65 ; 0x41 802fdf4: f1bc 0f05 cmp.w ip, #5 802fdf8: d809 bhi.n 802fe0e val = (val << 4) | (int)(c + 10 - (islower(c) ? 'a' : 'A')); 802fdfa: 330a adds r3, #10 802fdfc: 2919 cmp r1, #25 802fdfe: bf8c ite hi 802fe00: 2141 movhi r1, #65 ; 0x41 802fe02: 2161 movls r1, #97 ; 0x61 802fe04: 1a5b subs r3, r3, r1 802fe06: ea43 1000 orr.w r0, r3, r0, lsl #4 c = *++cp; 802fe0a: 7853 ldrb r3, [r2, #1] 802fe0c: e7e0 b.n 802fdd0 } else break; } if (c == '.') { 802fe0e: 2b2e cmp r3, #46 ; 0x2e 802fe10: d107 bne.n 802fe22 * Internet format: * a.b.c.d * a.b.c (with c treated as 16 bits) * a.b (with b treated as 24 bits) */ if (pp >= parts + 3) { 802fe12: 2c0c cmp r4, #12 802fe14: d038 beq.n 802fe88 return (0); } *pp++ = val; 802fe16: f84d 0004 str.w r0, [sp, r4] c = *++cp; 802fe1a: 7853 ldrb r3, [r2, #1] 802fe1c: 1c50 adds r0, r2, #1 802fe1e: 3404 adds r4, #4 } else break; } 802fe20: e7be b.n 802fda0 802fe22: 2b0d cmp r3, #13 802fe24: d803 bhi.n 802fe2e 802fe26: 2b09 cmp r3, #9 802fe28: d203 bcs.n 802fe32 802fe2a: b113 cbz r3, 802fe32 802fe2c: e02c b.n 802fe88 802fe2e: 2b20 cmp r3, #32 802fe30: d12a bne.n 802fe88 } /* * Concoct the address according to * the number of parts specified. */ switch (pp - parts + 1) { 802fe32: 466b mov r3, sp 802fe34: 1afb subs r3, r7, r3 802fe36: 109b asrs r3, r3, #2 802fe38: 3301 adds r3, #1 802fe3a: 2b04 cmp r3, #4 802fe3c: d81f bhi.n 802fe7e 802fe3e: e8df f003 tbb [pc, r3] 802fe42: 1e23 .short 0x1e23 802fe44: 0a03 .short 0x0a03 802fe46: 13 .byte 0x13 802fe47: 00 .byte 0x00 case 1: /* a -- 32 bits */ break; case 2: /* a.b -- 8.24 bits */ if (val > 0xffffffUL) { 802fe48: f1b0 7f80 cmp.w r0, #16777216 ; 0x1000000 802fe4c: d21c bcs.n 802fe88 return (0); } val |= parts[0] << 24; 802fe4e: 9b00 ldr r3, [sp, #0] 802fe50: ea40 6003 orr.w r0, r0, r3, lsl #24 break; 802fe54: e013 b.n 802fe7e case 3: /* a.b.c -- 8.8.16 bits */ if (val > 0xffff) { 802fe56: f5b0 3f80 cmp.w r0, #65536 ; 0x10000 802fe5a: d215 bcs.n 802fe88 return (0); } val |= (parts[0] << 24) | (parts[1] << 16); 802fe5c: 9b00 ldr r3, [sp, #0] 802fe5e: 061a lsls r2, r3, #24 802fe60: 9b01 ldr r3, [sp, #4] 802fe62: ea42 4303 orr.w r3, r2, r3, lsl #16 802fe66: e009 b.n 802fe7c break; case 4: /* a.b.c.d -- 8.8.8.8 bits */ if (val > 0xff) { 802fe68: 28ff cmp r0, #255 ; 0xff 802fe6a: d80d bhi.n 802fe88 return (0); } val |= (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8); 802fe6c: 9b00 ldr r3, [sp, #0] 802fe6e: 061a lsls r2, r3, #24 802fe70: 9b01 ldr r3, [sp, #4] 802fe72: ea42 4203 orr.w r2, r2, r3, lsl #16 802fe76: 9b02 ldr r3, [sp, #8] 802fe78: ea42 2303 orr.w r3, r2, r3, lsl #8 802fe7c: 4318 orrs r0, r3 break; default: LWIP_ASSERT("unhandled", 0); break; } if (addr) { 802fe7e: b12e cbz r6, 802fe8c ip4_addr_set_u32(addr, htonl(val)); 802fe80: f7fb ffa2 bl 802bdc8 802fe84: 6030 str r0, [r6, #0] 802fe86: e001 b.n 802fe8c * Collect number up to ``.''. * Values are specified as for C: * 0x=hex, 0=octal, 1-9=decimal. */ if (!isdigit(c)) return (0); 802fe88: 2000 movs r0, #0 802fe8a: e000 b.n 802fe8e break; } if (addr) { ip4_addr_set_u32(addr, htonl(val)); } return (1); 802fe8c: 2001 movs r0, #1 } 802fe8e: b005 add sp, #20 802fe90: bdf0 pop {r4, r5, r6, r7, pc} 0802fe92 : * @param cp IP address in ascii represenation (e.g. "127.0.0.1") * @return ip address in network order */ u32_t ipaddr_addr(const char *cp) { 802fe92: b507 push {r0, r1, r2, lr} ip_addr_t val; if (ipaddr_aton(cp, &val)) { 802fe94: a901 add r1, sp, #4 802fe96: f7ff ff7e bl 802fd96 802fe9a: b108 cbz r0, 802fea0 return ip4_addr_get_u32(&val); 802fe9c: 9801 ldr r0, [sp, #4] 802fe9e: e001 b.n 802fea4 } return (IPADDR_NONE); 802fea0: f04f 30ff mov.w r0, #4294967295 } 802fea4: bd0e pop {r1, r2, r3, pc} 0802fea6 : * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) { 802fea6: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} u8_t rem; u8_t n; u8_t i; int len = 0; s_addr = ip4_addr_get_u32(addr); 802feaa: 6803 ldr r3, [r0, #0] 802feac: a802 add r0, sp, #8 * @param buf target buffer where the string is stored * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) 802feae: f10d 0807 add.w r8, sp, #7 u8_t rem; u8_t n; u8_t i; int len = 0; s_addr = ip4_addr_get_u32(addr); 802feb2: f840 3d04 str.w r3, [r0, #-4]! rp = buf; 802feb6: 460c mov r4, r1 * @param buf target buffer where the string is stored * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) 802feb8: 3801 subs r0, #1 char *rp; u8_t *ap; u8_t rem; u8_t n; u8_t i; int len = 0; 802feba: 2700 movs r7, #0 rp = buf; ap = (u8_t *)&s_addr; for(n = 0; n < 4; n++) { i = 0; do { rem = *ap % (u8_t)10; 802febc: f04f 0c0a mov.w ip, #10 *rp++ = inv[i]; } if (len++ >= buflen) { return NULL; } *rp++ = '.'; 802fec0: f04f 092e mov.w r9, #46 ; 0x2e 802fec4: 7843 ldrb r3, [r0, #1] * @param buf target buffer where the string is stored * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) 802fec6: 2500 movs r5, #0 rp = buf; ap = (u8_t *)&s_addr; for(n = 0; n < 4; n++) { i = 0; do { rem = *ap % (u8_t)10; 802fec8: fbb3 f6fc udiv r6, r3, ip *ap /= (u8_t)10; inv[i++] = '0' + rem; 802fecc: f10d 0b08 add.w fp, sp, #8 rp = buf; ap = (u8_t *)&s_addr; for(n = 0; n < 4; n++) { i = 0; do { rem = *ap % (u8_t)10; 802fed0: fb0c 3a16 mls sl, ip, r6, r3 *ap /= (u8_t)10; inv[i++] = '0' + rem; 802fed4: eb0b 0305 add.w r3, fp, r5 802fed8: f10a 0a30 add.w sl, sl, #48 ; 0x30 802fedc: 3501 adds r5, #1 802fede: f803 ac08 strb.w sl, [r3, #-8] } while(*ap); 802fee2: f016 03ff ands.w r3, r6, #255 ; 0xff for(n = 0; n < 4; n++) { i = 0; do { rem = *ap % (u8_t)10; *ap /= (u8_t)10; inv[i++] = '0' + rem; 802fee6: b2ed uxtb r5, r5 } while(*ap); 802fee8: d1ee bne.n 802fec8 802feea: 3d01 subs r5, #1 * @param buf target buffer where the string is stored * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) 802feec: 1be6 subs r6, r4, r7 802feee: f800 3f01 strb.w r3, [r0, #1]! 802fef2: b2ed uxtb r5, r5 802fef4: 463b mov r3, r7 802fef6: 4637 mov r7, r6 802fef8: e00b b.n 802ff12 802fefa: 1e6c subs r4, r5, #1 rem = *ap % (u8_t)10; *ap /= (u8_t)10; inv[i++] = '0' + rem; } while(*ap); while(i--) { if (len++ >= buflen) { 802fefc: 4293 cmp r3, r2 802fefe: b2e4 uxtb r4, r4 802ff00: da16 bge.n 802ff30 return NULL; } *rp++ = inv[i]; 802ff02: f10d 0a08 add.w sl, sp, #8 802ff06: 4455 add r5, sl 802ff08: f815 5c08 ldrb.w r5, [r5, #-8] 802ff0c: 54fd strb r5, [r7, r3] 802ff0e: 3301 adds r3, #1 802ff10: 4625 mov r5, r4 do { rem = *ap % (u8_t)10; *ap /= (u8_t)10; inv[i++] = '0' + rem; } while(*ap); while(i--) { 802ff12: 2dff cmp r5, #255 ; 0xff * @param buf target buffer where the string is stored * @param buflen length of buf * @return either pointer to buf which now holds the ASCII * representation of addr or NULL if buf was too small */ char *ipaddr_ntoa_r(const ip_addr_t *addr, char *buf, int buflen) 802ff14: eb06 0403 add.w r4, r6, r3 do { rem = *ap % (u8_t)10; *ap /= (u8_t)10; inv[i++] = '0' + rem; } while(*ap); while(i--) { 802ff18: d1ef bne.n 802fefa if (len++ >= buflen) { return NULL; } *rp++ = inv[i]; } if (len++ >= buflen) { 802ff1a: 1c5f adds r7, r3, #1 802ff1c: 4293 cmp r3, r2 802ff1e: da07 bge.n 802ff30 s_addr = ip4_addr_get_u32(addr); rp = buf; ap = (u8_t *)&s_addr; for(n = 0; n < 4; n++) { 802ff20: 4540 cmp r0, r8 *rp++ = inv[i]; } if (len++ >= buflen) { return NULL; } *rp++ = '.'; 802ff22: f804 9b01 strb.w r9, [r4], #1 s_addr = ip4_addr_get_u32(addr); rp = buf; ap = (u8_t *)&s_addr; for(n = 0; n < 4; n++) { 802ff26: d1cd bne.n 802fec4 return NULL; } *rp++ = '.'; ap++; } *--rp = 0; 802ff28: 2300 movs r3, #0 802ff2a: f804 3c01 strb.w r3, [r4, #-1] 802ff2e: e000 b.n 802ff32 *ap /= (u8_t)10; inv[i++] = '0' + rem; } while(*ap); while(i--) { if (len++ >= buflen) { return NULL; 802ff30: 2100 movs r1, #0 *rp++ = '.'; ap++; } *--rp = 0; return buf; } 802ff32: 4608 mov r0, r1 802ff34: e8bd 8ffe ldmia.w sp!, {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 0802ff38 : */ char * ipaddr_ntoa(const ip_addr_t *addr) { static char str[16]; return ipaddr_ntoa_r(addr, str, 16); 802ff38: 4901 ldr r1, [pc, #4] ; (802ff40 ) 802ff3a: 2210 movs r2, #16 802ff3c: f7ff bfb3 b.w 802fea6 802ff40: 2000e124 .word 0x2000e124 0802ff44 : return netif; } #endif /* iterate through netifs */ for (netif = netif_list; netif != NULL; netif = netif->next) { 802ff44: 4b0f ldr r3, [pc, #60] ; (802ff84 ) * @param dest the destination IP address for which to find the route * @return the netif on which to send to reach dest */ struct netif * ip_route(ip_addr_t *dest) { 802ff46: b510 push {r4, lr} return netif; } #endif /* iterate through netifs */ for (netif = netif_list; netif != NULL; netif = netif->next) { 802ff48: 681c ldr r4, [r3, #0] 802ff4a: e00a b.n 802ff62 /* network mask matches? */ if (netif_is_up(netif)) { 802ff4c: f894 302d ldrb.w r3, [r4, #45] ; 0x2d 802ff50: 07d9 lsls r1, r3, #31 802ff52: d505 bpl.n 802ff60 if (ip_addr_netcmp(dest, &(netif->ip_addr), &(netif->netmask))) { 802ff54: 6803 ldr r3, [r0, #0] 802ff56: 6862 ldr r2, [r4, #4] 802ff58: 405a eors r2, r3 802ff5a: 68a3 ldr r3, [r4, #8] 802ff5c: 421a tst r2, r3 802ff5e: d00e beq.n 802ff7e return netif; } #endif /* iterate through netifs */ for (netif = netif_list; netif != NULL; netif = netif->next) { 802ff60: 6824 ldr r4, [r4, #0] 802ff62: 2c00 cmp r4, #0 802ff64: d1f2 bne.n 802ff4c /* return netif on which to forward IP packet */ return netif; } } } if ((netif_default == NULL) || (!netif_is_up(netif_default))) { 802ff66: 4b08 ldr r3, [pc, #32] ; (802ff88 ) 802ff68: 681b ldr r3, [r3, #0] 802ff6a: b12b cbz r3, 802ff78 802ff6c: f893 202d ldrb.w r2, [r3, #45] ; 0x2d 802ff70: 07d2 lsls r2, r2, #31 802ff72: bf48 it mi 802ff74: 461c movmi r4, r3 802ff76: d402 bmi.n 802ff7e LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("ip_route: No route to %"U16_F".%"U16_F".%"U16_F".%"U16_F"\n", ip4_addr1_16(dest), ip4_addr2_16(dest), ip4_addr3_16(dest), ip4_addr4_16(dest))); IP_STATS_INC(ip.rterr); snmp_inc_ipoutnoroutes(); 802ff78: f001 fcbc bl 80318f4 return NULL; 802ff7c: e7ff b.n 802ff7e } /* no matching netif found, use default netif */ return netif_default; } 802ff7e: 4620 mov r0, r4 802ff80: bd10 pop {r4, pc} 802ff82: bf00 nop 802ff84: 20010fd0 .word 0x20010fd0 802ff88: 20010fd4 .word 0x20010fd4 0802ff8c : * @return ERR_OK if the packet was processed (could return ERR_* if it wasn't * processed, but currently always returns ERR_OK) */ err_t ip_input(struct pbuf *p, struct netif *inp) { 802ff8c: e92d 4ff8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, lr} 802ff90: 4604 mov r4, r0 802ff92: 460f mov r7, r1 #if IP_ACCEPT_LINK_LAYER_ADDRESSING int check_ip_src=1; #endif /* IP_ACCEPT_LINK_LAYER_ADDRESSING */ IP_STATS_INC(ip.recv); snmp_inc_ipinreceives(); 802ff94: f001 fc6e bl 8031874 /* identify the IP header */ iphdr = (struct ip_hdr *)p->payload; 802ff98: 6866 ldr r6, [r4, #4] if (IPH_V(iphdr) != 4) { 802ff9a: f896 8000 ldrb.w r8, [r6] 802ff9e: ea4f 1318 mov.w r3, r8, lsr #4 802ffa2: 2b04 cmp r3, #4 802ffa4: d005 beq.n 802ffb2 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_WARNING, ("IP packet dropped due to bad version number %"U16_F"\n", IPH_V(iphdr))); ip_debug_print(p); pbuf_free(p); 802ffa6: 4620 mov r0, r4 802ffa8: f7fd f842 bl 802d030 IP_STATS_INC(ip.err); IP_STATS_INC(ip.drop); snmp_inc_ipinhdrerrors(); 802ffac: f001 fc6a bl 8031884 return ERR_OK; 802ffb0: e0be b.n 8030130 /* obtain IP header length in number of 32-bit words */ iphdr_hlen = IPH_HL(iphdr); /* calculate IP header length in bytes */ iphdr_hlen *= 4; /* obtain ip length in bytes */ iphdr_len = ntohs(IPH_LEN(iphdr)); 802ffb2: 8870 ldrh r0, [r6, #2] 802ffb4: f7fb ff03 bl 802bdbe return ERR_OK; } #endif /* obtain IP header length in number of 32-bit words */ iphdr_hlen = IPH_HL(iphdr); 802ffb8: f008 080f and.w r8, r8, #15 iphdr_hlen *= 4; /* obtain ip length in bytes */ iphdr_len = ntohs(IPH_LEN(iphdr)); /* header length exceeds first pbuf length, or ip length exceeds total pbuf length? */ if ((iphdr_hlen > p->len) || (iphdr_len > p->tot_len)) { 802ffbc: 8963 ldrh r3, [r4, #10] #endif /* obtain IP header length in number of 32-bit words */ iphdr_hlen = IPH_HL(iphdr); /* calculate IP header length in bytes */ iphdr_hlen *= 4; 802ffbe: ea4f 0888 mov.w r8, r8, lsl #2 /* obtain ip length in bytes */ iphdr_len = ntohs(IPH_LEN(iphdr)); /* header length exceeds first pbuf length, or ip length exceeds total pbuf length? */ if ((iphdr_hlen > p->len) || (iphdr_len > p->tot_len)) { 802ffc2: 4543 cmp r3, r8 /* obtain IP header length in number of 32-bit words */ iphdr_hlen = IPH_HL(iphdr); /* calculate IP header length in bytes */ iphdr_hlen *= 4; /* obtain ip length in bytes */ iphdr_len = ntohs(IPH_LEN(iphdr)); 802ffc4: 4601 mov r1, r0 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("IP (len %"U16_F") is longer than pbuf (len %"U16_F"), IP packet dropped.\n", iphdr_len, p->tot_len)); } /* free (drop) packet pbufs */ pbuf_free(p); 802ffc6: 4620 mov r0, r4 iphdr_hlen *= 4; /* obtain ip length in bytes */ iphdr_len = ntohs(IPH_LEN(iphdr)); /* header length exceeds first pbuf length, or ip length exceeds total pbuf length? */ if ((iphdr_hlen > p->len) || (iphdr_len > p->tot_len)) { 802ffc8: d302 bcc.n 802ffd0 802ffca: 8923 ldrh r3, [r4, #8] 802ffcc: 428b cmp r3, r1 802ffce: d202 bcs.n 802ffd6 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("IP (len %"U16_F") is longer than pbuf (len %"U16_F"), IP packet dropped.\n", iphdr_len, p->tot_len)); } /* free (drop) packet pbufs */ pbuf_free(p); 802ffd0: f7fd f82e bl 802d030 802ffd4: e045 b.n 8030062 } #endif /* Trim pbuf. This should have been done at the netif layer, * but we'll do it anyway just to be sure that its done. */ pbuf_realloc(p, iphdr_len); 802ffd6: f7fd f852 bl 802d07e /* copy IP addresses to aligned ip_addr_t */ ip_addr_copy(current_iphdr_dest, iphdr->dest); 802ffda: 6932 ldr r2, [r6, #16] 802ffdc: 4b56 ldr r3, [pc, #344] ; (8030138 ) } #endif /* LWIP_AUTOIP */ } if (first) { first = 0; netif = netif_list; 802ffde: f8df b168 ldr.w fp, [pc, #360] ; 8030148 /* Trim pbuf. This should have been done at the netif layer, * but we'll do it anyway just to be sure that its done. */ pbuf_realloc(p, iphdr_len); /* copy IP addresses to aligned ip_addr_t */ ip_addr_copy(current_iphdr_dest, iphdr->dest); 802ffe2: 601a str r2, [r3, #0] ip_addr_copy(current_iphdr_src, iphdr->src); 802ffe4: 68f1 ldr r1, [r6, #12] 802ffe6: 4a55 ldr r2, [pc, #340] ; (803013c ) 802ffe8: 463d mov r5, r7 802ffea: 6011 str r1, [r2, #0] #endif /* LWIP_IGMP */ { /* start trying with inp. if that's not acceptable, start walking the list of configured netifs. 'first' is used as a boolean to mark whether we started walking the list */ int first = 1; 802ffec: f04f 0901 mov.w r9, #1 ip4_addr_get_u32(&iphdr->dest) & ~ip4_addr_get_u32(&netif->netmask))); /* interface is up and configured? */ if ((netif_is_up(netif)) && (!ip_addr_isany(&(netif->ip_addr)))) { /* unicast to this interface address? */ if (ip_addr_cmp(¤t_iphdr_dest, &(netif->ip_addr)) || 802fff0: 469a mov sl, r3 ip4_addr_get_u32(&iphdr->dest) & ip4_addr_get_u32(&netif->netmask), ip4_addr_get_u32(&netif->ip_addr) & ip4_addr_get_u32(&netif->netmask), ip4_addr_get_u32(&iphdr->dest) & ~ip4_addr_get_u32(&netif->netmask))); /* interface is up and configured? */ if ((netif_is_up(netif)) && (!ip_addr_isany(&(netif->ip_addr)))) { 802fff2: f895 302d ldrb.w r3, [r5, #45] ; 0x2d 802fff6: 07d8 lsls r0, r3, #31 802fff8: d403 bmi.n 8030002 /* break out of for loop */ break; } #endif /* LWIP_AUTOIP */ } if (first) { 802fffa: f1b9 0f00 cmp.w r9, #0 802fffe: d10e bne.n 803001e 8030000: e010 b.n 8030024 ip4_addr_get_u32(&iphdr->dest) & ip4_addr_get_u32(&netif->netmask), ip4_addr_get_u32(&netif->ip_addr) & ip4_addr_get_u32(&netif->netmask), ip4_addr_get_u32(&iphdr->dest) & ~ip4_addr_get_u32(&netif->netmask))); /* interface is up and configured? */ if ((netif_is_up(netif)) && (!ip_addr_isany(&(netif->ip_addr)))) { 8030002: 686b ldr r3, [r5, #4] 8030004: 2b00 cmp r3, #0 8030006: d0f8 beq.n 802fffa /* unicast to this interface address? */ if (ip_addr_cmp(¤t_iphdr_dest, &(netif->ip_addr)) || 8030008: f8da 0000 ldr.w r0, [sl] 803000c: 4298 cmp r0, r3 803000e: f000 8088 beq.w 8030122 /* or broadcast on this interface network address? */ ip_addr_isbroadcast(¤t_iphdr_dest, netif)) { 8030012: 4629 mov r1, r5 8030014: f7ff fea6 bl 802fd64 ip4_addr_get_u32(&iphdr->dest) & ~ip4_addr_get_u32(&netif->netmask))); /* interface is up and configured? */ if ((netif_is_up(netif)) && (!ip_addr_isany(&(netif->ip_addr)))) { /* unicast to this interface address? */ if (ip_addr_cmp(¤t_iphdr_dest, &(netif->ip_addr)) || 8030018: 2800 cmp r0, #0 803001a: d0ee beq.n 802fffa 803001c: e081 b.n 8030122 } #endif /* LWIP_AUTOIP */ } if (first) { first = 0; netif = netif_list; 803001e: f8db 5000 ldr.w r5, [fp] 8030022: e000 b.n 8030026 } else { netif = netif->next; 8030024: 682d ldr r5, [r5, #0] } if (netif == inp) { 8030026: 42bd cmp r5, r7 netif = netif->next; 8030028: bf08 it eq 803002a: 682d ldreq r5, [r5, #0] 803002c: f04f 0900 mov.w r9, #0 } } while(netif != NULL); 8030030: 2d00 cmp r5, #0 8030032: d1de bne.n 802fff2 8030034: e072 b.n 803011c /* remote port is DHCP server? */ if (IPH_PROTO(iphdr) == IP_PROTO_UDP) { struct udp_hdr *udphdr = (struct udp_hdr *)((u8_t *)iphdr + iphdr_hlen); LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_TRACE, ("ip_input: UDP packet to DHCP client port %"U16_F"\n", ntohs(udphdr->dest))); if (IP_ACCEPT_LINK_LAYER_ADDRESSED_PORT(udphdr->dest)) { 8030036: eb06 0308 add.w r3, r6, r8 803003a: 885b ldrh r3, [r3, #2] 803003c: f5b3 4f88 cmp.w r3, #17408 ; 0x4400 8030040: d16f bne.n 8030122 8030042: e011 b.n 8030068 /* broadcast or multicast packet source address? Compliant with RFC 1122: 3.2.1.3 */ #if IP_ACCEPT_LINK_LAYER_ADDRESSING /* DHCP servers need 0.0.0.0 to be allowed as source address (RFC 1.1.2.2: 3.2.1.3/a) */ if (check_ip_src && !ip_addr_isany(¤t_iphdr_src)) #endif /* IP_ACCEPT_LINK_LAYER_ADDRESSING */ { if ((ip_addr_isbroadcast(¤t_iphdr_src, inp)) || 8030044: 4639 mov r1, r7 8030046: f7ff fe8d bl 802fd64 803004a: b928 cbnz r0, 8030058 (ip_addr_ismulticast(¤t_iphdr_src))) { 803004c: f8d8 3000 ldr.w r3, [r8] 8030050: f003 03f0 and.w r3, r3, #240 ; 0xf0 /* broadcast or multicast packet source address? Compliant with RFC 1122: 3.2.1.3 */ #if IP_ACCEPT_LINK_LAYER_ADDRESSING /* DHCP servers need 0.0.0.0 to be allowed as source address (RFC 1.1.2.2: 3.2.1.3/a) */ if (check_ip_src && !ip_addr_isany(¤t_iphdr_src)) #endif /* IP_ACCEPT_LINK_LAYER_ADDRESSING */ { if ((ip_addr_isbroadcast(¤t_iphdr_src, inp)) || 8030054: 2be0 cmp r3, #224 ; 0xe0 8030056: d108 bne.n 803006a (ip_addr_ismulticast(¤t_iphdr_src))) { /* packet source is not valid */ LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_WARNING, ("ip_input: packet source is not valid.\n")); /* free (drop) packet pbufs */ pbuf_free(p); 8030058: 4620 mov r0, r4 803005a: f7fc ffe9 bl 802d030 IP_STATS_INC(ip.drop); snmp_inc_ipinaddrerrors(); 803005e: f001 fc19 bl 8031894 snmp_inc_ipindiscards(); 8030062: f001 fc27 bl 80318b4 return ERR_OK; 8030066: e063 b.n 8030130 /* remote port is DHCP server? */ if (IPH_PROTO(iphdr) == IP_PROTO_UDP) { struct udp_hdr *udphdr = (struct udp_hdr *)((u8_t *)iphdr + iphdr_hlen); LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_TRACE, ("ip_input: UDP packet to DHCP client port %"U16_F"\n", ntohs(udphdr->dest))); if (IP_ACCEPT_LINK_LAYER_ADDRESSED_PORT(udphdr->dest)) { 8030068: 463d mov r5, r7 return ERR_OK; } } /* packet not for us? */ if (netif == NULL) { 803006a: b93d cbnz r5, 803007c /* try to forward IP packet on (other) interfaces */ ip_forward(p, iphdr, inp); } else #endif /* IP_FORWARD */ { snmp_inc_ipinaddrerrors(); 803006c: f001 fc12 bl 8031894 snmp_inc_ipindiscards(); 8030070: f001 fc20 bl 80318b4 } pbuf_free(p); 8030074: 4620 mov r0, r4 8030076: f7fc ffdb bl 802d030 return ERR_OK; 803007a: e059 b.n 8030130 } /* packet consists of multiple fragments? */ if ((IPH_OFFSET(iphdr) & PP_HTONS(IP_OFFMASK | IP_MF)) != 0) { 803007c: 88f3 ldrh r3, [r6, #6] 803007e: f023 03c0 bic.w r3, r3, #192 ; 0xc0 8030082: b29b uxth r3, r3 8030084: b12b cbz r3, 8030092 if (p == NULL) { return ERR_OK; } iphdr = (struct ip_hdr *)p->payload; #else /* IP_REASSEMBLY == 0, no packet fragment reassembly code present */ pbuf_free(p); 8030086: 4620 mov r0, r4 8030088: f7fc ffd2 bl 802d030 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("IP packet dropped since it was fragmented (0x%"X16_F") (while IP_REASSEMBLY == 0).\n", ntohs(IPH_OFFSET(iphdr)))); IP_STATS_INC(ip.opterr); IP_STATS_INC(ip.drop); /* unsupported protocol feature */ snmp_inc_ipinunknownprotos(); 803008c: f001 fc0a bl 80318a4 return ERR_OK; 8030090: e04e b.n 8030130 /* send to upper layers */ LWIP_DEBUGF(IP_DEBUG, ("ip_input: \n")); ip_debug_print(p); LWIP_DEBUGF(IP_DEBUG, ("ip_input: p->len %"U16_F" p->tot_len %"U16_F"\n", p->len, p->tot_len)); current_netif = inp; 8030092: 4b2b ldr r3, [pc, #172] ; (8030140 ) 8030094: 601f str r7, [r3, #0] current_header = iphdr; 8030096: 4b2b ldr r3, [pc, #172] ; (8030144 ) #if LWIP_RAW /* raw input did not eat the packet? */ if (raw_input(p, inp) == 0) 8030098: 4620 mov r0, r4 803009a: 4639 mov r1, r7 LWIP_DEBUGF(IP_DEBUG, ("ip_input: \n")); ip_debug_print(p); LWIP_DEBUGF(IP_DEBUG, ("ip_input: p->len %"U16_F" p->tot_len %"U16_F"\n", p->len, p->tot_len)); current_netif = inp; current_header = iphdr; 803009c: 601e str r6, [r3, #0] #if LWIP_RAW /* raw input did not eat the packet? */ if (raw_input(p, inp) == 0) 803009e: f7fd f947 bl 802d330 80300a2: bb88 cbnz r0, 8030108 #endif /* LWIP_RAW */ { switch (IPH_PROTO(iphdr)) { 80300a4: 7a73 ldrb r3, [r6, #9] 80300a6: 2b06 cmp r3, #6 80300a8: d00b beq.n 80300c2 80300aa: 2b11 cmp r3, #17 80300ac: d002 beq.n 80300b4 80300ae: 2b01 cmp r3, #1 80300b0: d115 bne.n 80300de 80300b2: e00d b.n 80300d0 #if LWIP_UDP case IP_PROTO_UDP: #if LWIP_UDPLITE case IP_PROTO_UDPLITE: #endif /* LWIP_UDPLITE */ snmp_inc_ipindelivers(); 80300b4: f001 fc06 bl 80318c4 udp_input(p, inp); 80300b8: 4620 mov r0, r4 80300ba: 4639 mov r1, r7 80300bc: f7ff fb44 bl 802f748 break; 80300c0: e022 b.n 8030108 #endif /* LWIP_UDP */ #if LWIP_TCP case IP_PROTO_TCP: snmp_inc_ipindelivers(); 80300c2: f001 fbff bl 80318c4 tcp_input(p, inp); 80300c6: 4620 mov r0, r4 80300c8: 4639 mov r1, r7 80300ca: f7fe f8e7 bl 802e29c break; 80300ce: e01b b.n 8030108 #endif /* LWIP_TCP */ #if LWIP_ICMP case IP_PROTO_ICMP: snmp_inc_ipindelivers(); 80300d0: f001 fbf8 bl 80318c4 icmp_input(p, inp); 80300d4: 4620 mov r0, r4 80300d6: 4639 mov r1, r7 80300d8: f7ff fd20 bl 802fb1c break; 80300dc: e014 b.n 8030108 break; #endif /* LWIP_IGMP */ default: #if LWIP_ICMP /* send ICMP destination protocol unreachable unless is was a broadcast */ if (!ip_addr_isbroadcast(¤t_iphdr_dest, inp) && 80300de: 4d16 ldr r5, [pc, #88] ; (8030138 ) 80300e0: 4639 mov r1, r7 80300e2: 6828 ldr r0, [r5, #0] 80300e4: f7ff fe3e bl 802fd64 80300e8: b948 cbnz r0, 80300fe !ip_addr_ismulticast(¤t_iphdr_dest)) { 80300ea: 682b ldr r3, [r5, #0] 80300ec: f003 03f0 and.w r3, r3, #240 ; 0xf0 break; #endif /* LWIP_IGMP */ default: #if LWIP_ICMP /* send ICMP destination protocol unreachable unless is was a broadcast */ if (!ip_addr_isbroadcast(¤t_iphdr_dest, inp) && 80300f0: 2be0 cmp r3, #224 ; 0xe0 80300f2: d004 beq.n 80300fe !ip_addr_ismulticast(¤t_iphdr_dest)) { p->payload = iphdr; 80300f4: 6066 str r6, [r4, #4] icmp_dest_unreach(p, ICMP_DUR_PROTO); 80300f6: 4620 mov r0, r4 80300f8: 2102 movs r1, #2 80300fa: f7ff fda5 bl 802fc48 } #endif /* LWIP_ICMP */ pbuf_free(p); 80300fe: 4620 mov r0, r4 8030100: f7fc ff96 bl 802d030 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("Unsupported transport protocol %"U16_F"\n", IPH_PROTO(iphdr))); IP_STATS_INC(ip.proterr); IP_STATS_INC(ip.drop); snmp_inc_ipinunknownprotos(); 8030104: f001 fbce bl 80318a4 } } current_netif = NULL; 8030108: 4a0d ldr r2, [pc, #52] ; (8030140 ) 803010a: 2300 movs r3, #0 803010c: 6013 str r3, [r2, #0] current_header = NULL; 803010e: 4a0d ldr r2, [pc, #52] ; (8030144 ) 8030110: 6013 str r3, [r2, #0] ip_addr_set_any(¤t_iphdr_src); 8030112: 4a0a ldr r2, [pc, #40] ; (803013c ) 8030114: 6013 str r3, [r2, #0] ip_addr_set_any(¤t_iphdr_dest); 8030116: 4a08 ldr r2, [pc, #32] ; (8030138 ) 8030118: 6013 str r3, [r2, #0] return ERR_OK; 803011a: e009 b.n 8030130 * * #define LWIP_IP_ACCEPT_UDP_PORT(dst_port) ((dst_port) == PP_NTOHS(12345)) */ if (netif == NULL) { /* remote port is DHCP server? */ if (IPH_PROTO(iphdr) == IP_PROTO_UDP) { 803011c: 7a73 ldrb r3, [r6, #9] 803011e: 2b11 cmp r3, #17 8030120: d089 beq.n 8030036 #endif /* IP_ACCEPT_LINK_LAYER_ADDRESSING */ /* broadcast or multicast packet source address? Compliant with RFC 1122: 3.2.1.3 */ #if IP_ACCEPT_LINK_LAYER_ADDRESSING /* DHCP servers need 0.0.0.0 to be allowed as source address (RFC 1.1.2.2: 3.2.1.3/a) */ if (check_ip_src && !ip_addr_isany(¤t_iphdr_src)) 8030122: f8df 8018 ldr.w r8, [pc, #24] ; 803013c 8030126: f8d8 0000 ldr.w r0, [r8] 803012a: 2800 cmp r0, #0 803012c: d09d beq.n 803006a 803012e: e789 b.n 8030044 current_header = NULL; ip_addr_set_any(¤t_iphdr_src); ip_addr_set_any(¤t_iphdr_dest); return ERR_OK; } 8030130: 2000 movs r0, #0 8030132: e8bd 8ff8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 8030136: bf00 nop 8030138: 20011004 .word 0x20011004 803013c: 20010ffc .word 0x20010ffc 8030140: 20011000 .word 0x20011000 8030144: 20011008 .word 0x20011008 8030148: 20010fd0 .word 0x20010fd0 0803014c : */ err_t ip_output_if(struct pbuf *p, ip_addr_t *src, ip_addr_t *dest, u8_t ttl, u8_t tos, u8_t proto, struct netif *netif) { 803014c: e92d 47f3 stmdb sp!, {r0, r1, r4, r5, r6, r7, r8, r9, sl, lr} 8030150: 4615 mov r5, r2 8030152: 4606 mov r6, r0 8030154: 4689 mov r9, r1 8030156: 469a mov sl, r3 8030158: 9f0c ldr r7, [sp, #48] ; 0x30 /* pbufs passed to IP must have a ref-count of 1 as their payload pointer gets altered as the packet is passed down the stack */ LWIP_ASSERT("p->ref == 1", p->ref == 1); snmp_inc_ipoutrequests(); 803015a: f001 fbbb bl 80318d4 /* Should the IP header be generated or is it already included in p? */ if (dest != IP_HDRINCL) { 803015e: b3b5 cbz r5, 80301ce } #endif /* CHECKSUM_GEN_IP_INLINE */ } #endif /* IP_OPTIONS_SEND */ /* generate IP header */ if (pbuf_header(p, IP_HLEN)) { 8030160: 4630 mov r0, r6 8030162: 2114 movs r1, #20 8030164: f7fc ff39 bl 802cfda 8030168: 4680 mov r8, r0 803016a: b118 cbz r0, 8030174 LWIP_DEBUGF(IP_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("ip_output: not enough room for IP header in pbuf\n")); IP_STATS_INC(ip.err); snmp_inc_ipoutdiscards(); 803016c: f001 fbba bl 80318e4 return ERR_BUF; 8030170: 20fe movs r0, #254 ; 0xfe 8030172: e036 b.n 80301e2 } iphdr = (struct ip_hdr *)p->payload; 8030174: 6874 ldr r4, [r6, #4] LWIP_ASSERT("check that first pbuf can hold struct ip_hdr", (p->len >= sizeof(struct ip_hdr))); IPH_TTL_SET(iphdr, ttl); IPH_PROTO_SET(iphdr, proto); 8030176: f89d 302c ldrb.w r3, [sp, #44] ; 0x2c iphdr = (struct ip_hdr *)p->payload; LWIP_ASSERT("check that first pbuf can hold struct ip_hdr", (p->len >= sizeof(struct ip_hdr))); IPH_TTL_SET(iphdr, ttl); 803017a: f884 a008 strb.w sl, [r4, #8] IPH_PROTO_SET(iphdr, proto); 803017e: 7263 strb r3, [r4, #9] #if CHECKSUM_GEN_IP_INLINE chk_sum += LWIP_MAKE_U16(proto, ttl); #endif /* CHECKSUM_GEN_IP_INLINE */ /* dest cannot be NULL here */ ip_addr_copy(iphdr->dest, *dest); 8030180: 682b ldr r3, [r5, #0] 8030182: 6123 str r3, [r4, #16] #if CHECKSUM_GEN_IP_INLINE chk_sum += ip4_addr_get_u32(&iphdr->dest) & 0xFFFF; chk_sum += ip4_addr_get_u32(&iphdr->dest) >> 16; #endif /* CHECKSUM_GEN_IP_INLINE */ IPH_VHL_SET(iphdr, 4, ip_hlen / 4); 8030184: 2345 movs r3, #69 ; 0x45 8030186: 7023 strb r3, [r4, #0] IPH_TOS_SET(iphdr, tos); 8030188: f89d 3028 ldrb.w r3, [sp, #40] ; 0x28 803018c: 7063 strb r3, [r4, #1] #if CHECKSUM_GEN_IP_INLINE chk_sum += LWIP_MAKE_U16(tos, iphdr->_v_hl); #endif /* CHECKSUM_GEN_IP_INLINE */ IPH_LEN_SET(iphdr, htons(p->tot_len)); 803018e: 8930 ldrh r0, [r6, #8] 8030190: f7fb fe10 bl 802bdb4 #if CHECKSUM_GEN_IP_INLINE chk_sum += iphdr->_len; #endif /* CHECKSUM_GEN_IP_INLINE */ IPH_OFFSET_SET(iphdr, 0); 8030194: f884 8006 strb.w r8, [r4, #6] 8030198: f884 8007 strb.w r8, [r4, #7] IPH_ID_SET(iphdr, htons(ip_id)); 803019c: f8df 8048 ldr.w r8, [pc, #72] ; 80301e8 IPH_VHL_SET(iphdr, 4, ip_hlen / 4); IPH_TOS_SET(iphdr, tos); #if CHECKSUM_GEN_IP_INLINE chk_sum += LWIP_MAKE_U16(tos, iphdr->_v_hl); #endif /* CHECKSUM_GEN_IP_INLINE */ IPH_LEN_SET(iphdr, htons(p->tot_len)); 80301a0: 8060 strh r0, [r4, #2] #if CHECKSUM_GEN_IP_INLINE chk_sum += iphdr->_len; #endif /* CHECKSUM_GEN_IP_INLINE */ IPH_OFFSET_SET(iphdr, 0); IPH_ID_SET(iphdr, htons(ip_id)); 80301a2: f8b8 0000 ldrh.w r0, [r8] 80301a6: f7fb fe05 bl 802bdb4 80301aa: 80a0 strh r0, [r4, #4] #if CHECKSUM_GEN_IP_INLINE chk_sum += iphdr->_id; #endif /* CHECKSUM_GEN_IP_INLINE */ ++ip_id; 80301ac: f8b8 3000 ldrh.w r3, [r8] 80301b0: 3301 adds r3, #1 80301b2: f8a8 3000 strh.w r3, [r8] if (ip_addr_isany(src)) { 80301b6: f1b9 0f00 cmp.w r9, #0 80301ba: d002 beq.n 80301c2 80301bc: f8d9 3000 ldr.w r3, [r9] 80301c0: b903 cbnz r3, 80301c4 ip_addr_copy(iphdr->src, netif->ip_addr); 80301c2: 687b ldr r3, [r7, #4] } else { /* src cannot be NULL here */ ip_addr_copy(iphdr->src, *src); 80301c4: 60e3 str r3, [r4, #12] chk_sum = (chk_sum >> 16) + (chk_sum & 0xFFFF); chk_sum = (chk_sum >> 16) + chk_sum; chk_sum = ~chk_sum; iphdr->_chksum = chk_sum; /* network order */ #else /* CHECKSUM_GEN_IP_INLINE */ IPH_CHKSUM_SET(iphdr, 0); 80301c6: 2300 movs r3, #0 80301c8: 72a3 strb r3, [r4, #10] 80301ca: 72e3 strb r3, [r4, #11] 80301cc: e004 b.n 80301d8 #endif #endif /* CHECKSUM_GEN_IP_INLINE */ } else { /* IP header already included in p */ iphdr = (struct ip_hdr *)p->payload; ip_addr_copy(dest_addr, iphdr->dest); 80301ce: 6873 ldr r3, [r6, #4] 80301d0: ad02 add r5, sp, #8 80301d2: 691b ldr r3, [r3, #16] 80301d4: f845 3d04 str.w r3, [r5, #-4]! return ip_frag(p, netif, dest); } #endif /* IP_FRAG */ LWIP_DEBUGF(IP_DEBUG, ("netif->output()")); return netif->output(netif, p, dest); 80301d8: 697b ldr r3, [r7, #20] 80301da: 4638 mov r0, r7 80301dc: 4631 mov r1, r6 80301de: 462a mov r2, r5 80301e0: 4798 blx r3 } 80301e2: b240 sxtb r0, r0 80301e4: e8bd 87fc ldmia.w sp!, {r2, r3, r4, r5, r6, r7, r8, r9, sl, pc} 80301e8: 2000e134 .word 0x2000e134 080301ec : * see ip_output_if() for more return values */ err_t ip_output(struct pbuf *p, ip_addr_t *src, ip_addr_t *dest, u8_t ttl, u8_t tos, u8_t proto) { 80301ec: b5f0 push {r4, r5, r6, r7, lr} 80301ee: 4605 mov r5, r0 80301f0: b085 sub sp, #20 /* pbufs passed to IP must have a ref-count of 1 as their payload pointer gets altered as the packet is passed down the stack */ LWIP_ASSERT("p->ref == 1", p->ref == 1); if ((netif = ip_route(dest)) == NULL) { 80301f2: 4610 mov r0, r2 * see ip_output_if() for more return values */ err_t ip_output(struct pbuf *p, ip_addr_t *src, ip_addr_t *dest, u8_t ttl, u8_t tos, u8_t proto) { 80301f4: 460f mov r7, r1 80301f6: 4614 mov r4, r2 80301f8: 461e mov r6, r3 /* pbufs passed to IP must have a ref-count of 1 as their payload pointer gets altered as the packet is passed down the stack */ LWIP_ASSERT("p->ref == 1", p->ref == 1); if ((netif = ip_route(dest)) == NULL) { 80301fa: f7ff fea3 bl 802ff44 80301fe: b168 cbz r0, 803021c ip4_addr1_16(dest), ip4_addr2_16(dest), ip4_addr3_16(dest), ip4_addr4_16(dest))); IP_STATS_INC(ip.rterr); return ERR_RTE; } return ip_output_if(p, src, dest, ttl, tos, proto, netif); 8030200: f89d 3028 ldrb.w r3, [sp, #40] ; 0x28 8030204: 9002 str r0, [sp, #8] 8030206: 9300 str r3, [sp, #0] 8030208: f89d 302c ldrb.w r3, [sp, #44] ; 0x2c 803020c: 4628 mov r0, r5 803020e: 9301 str r3, [sp, #4] 8030210: 4639 mov r1, r7 8030212: 4622 mov r2, r4 8030214: 4633 mov r3, r6 8030216: f7ff ff99 bl 803014c 803021a: e000 b.n 803021e if ((netif = ip_route(dest)) == NULL) { LWIP_DEBUGF(IP_DEBUG, ("ip_output: No route to %"U16_F".%"U16_F".%"U16_F".%"U16_F"\n", ip4_addr1_16(dest), ip4_addr2_16(dest), ip4_addr3_16(dest), ip4_addr4_16(dest))); IP_STATS_INC(ip.rterr); return ERR_RTE; 803021c: 20fc movs r0, #252 ; 0xfc } return ip_output_if(p, src, dest, ttl, tos, proto, netif); } 803021e: b240 sxtb r0, r0 8030220: b005 add sp, #20 8030222: bdf0 pop {r4, r5, r6, r7, pc} 08030224 : * @param type return ASN1 type * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_type(struct pbuf *p, u16_t ofs, u8_t *type) { 8030224: b510 push {r4, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030226: 2300 movs r3, #0 while (p != NULL) 8030228: e00c b.n 8030244 { base = plen; plen += p->len; 803022a: 8944 ldrh r4, [r0, #10] 803022c: 191c adds r4, r3, r4 803022e: b2a4 uxth r4, r4 if (ofs < plen) 8030230: 42a1 cmp r1, r4 8030232: d205 bcs.n 8030240 { msg_ptr = (u8_t*)p->payload; 8030234: 6840 ldr r0, [r0, #4] msg_ptr += ofs - base; 8030236: 1acb subs r3, r1, r3 *type = *msg_ptr; 8030238: 5cc3 ldrb r3, [r0, r3] return ERR_OK; 803023a: 2000 movs r0, #0 plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; *type = *msg_ptr; 803023c: 7013 strb r3, [r2, #0] return ERR_OK; 803023e: e004 b.n 803024a } p = p->next; 8030240: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030242: 4623 mov r3, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 8030244: 2800 cmp r0, #0 8030246: d1f0 bne.n 803022a return ERR_OK; } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; 8030248: 20f2 movs r0, #242 ; 0xf2 } 803024a: b240 sxtb r0, r0 803024c: bd10 pop {r4, pc} 0803024e : * @param length return host order length, upto 64k * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_length(struct pbuf *p, u16_t ofs, u8_t *octets_used, u16_t *length) { 803024e: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030250: 2500 movs r5, #0 while (p != NULL) 8030252: e079 b.n 8030348 { base = plen; plen += p->len; 8030254: 8944 ldrh r4, [r0, #10] 8030256: 192c adds r4, r5, r4 8030258: b2a4 uxth r4, r4 if (ofs < plen) 803025a: 42a1 cmp r1, r4 803025c: d272 bcs.n 8030344 { msg_ptr = (u8_t*)p->payload; 803025e: f8d0 c004 ldr.w ip, [r0, #4] msg_ptr += ofs - base; 8030262: 1b4f subs r7, r1, r5 8030264: eb0c 0507 add.w r5, ip, r7 if (*msg_ptr < 0x80) 8030268: f81c 6007 ldrb.w r6, [ip, r7] 803026c: f016 0f80 tst.w r6, #128 ; 0x80 8030270: d105 bne.n 803027e { /* primitive definite length format */ *octets_used = 1; 8030272: 2101 movs r1, #1 8030274: 7011 strb r1, [r2, #0] *length = *msg_ptr; 8030276: f81c 2007 ldrb.w r2, [ip, r7] 803027a: 801a strh r2, [r3, #0] 803027c: e05a b.n 8030334 return ERR_OK; } else if (*msg_ptr == 0x80) 803027e: 2e80 cmp r6, #128 ; 0x80 8030280: d12a bne.n 80302d8 { /* constructed indefinite length format, termination with two zero octets */ u8_t zeros; u8_t i; *length = 0; 8030282: 2600 movs r6, #0 8030284: 801e strh r6, [r3, #0] 8030286: e022 b.n 80302ce { i = 2; while (i > 0) { i--; (*length) += 1; 8030288: f8b3 c000 ldrh.w ip, [r3] ofs += 1; 803028c: 3101 adds r1, #1 803028e: b289 uxth r1, r1 { i = 2; while (i > 0) { i--; (*length) += 1; 8030290: f10c 0c01 add.w ip, ip, #1 ofs += 1; if (ofs >= plen) 8030294: 42a1 cmp r1, r4 { i = 2; while (i > 0) { i--; (*length) += 1; 8030296: f8a3 c000 strh.w ip, [r3] ofs += 1; if (ofs >= plen) 803029a: d308 bcc.n 80302ae { /* next octet in next pbuf */ p = p->next; 803029c: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 803029e: b900 cbnz r0, 80302a2 80302a0: e04e b.n 8030340 msg_ptr = (u8_t*)p->payload; plen += p->len; 80302a2: f8b0 c00a ldrh.w ip, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80302a6: 6845 ldr r5, [r0, #4] plen += p->len; 80302a8: 4464 add r4, ip 80302aa: b2a4 uxth r4, r4 80302ac: e000 b.n 80302b0 } else { /* next octet in same pbuf */ msg_ptr++; 80302ae: 3501 adds r5, #1 } if (*msg_ptr == 0) 80302b0: f895 c000 ldrb.w ip, [r5] 80302b4: f1bc 0f00 cmp.w ip, #0 80302b8: d104 bne.n 80302c4 { zeros++; 80302ba: 3601 adds r6, #1 80302bc: b2f6 uxtb r6, r6 if (zeros == 2) 80302be: 2e02 cmp r6, #2 80302c0: d101 bne.n 80302c6 80302c2: e007 b.n 80302d4 i = 0; } } else { zeros = 0; 80302c4: 2600 movs r6, #0 *length = 0; zeros = 0; while (zeros != 2) { i = 2; while (i > 0) 80302c6: 42b9 cmp r1, r7 80302c8: d1de bne.n 8030288 u8_t zeros; u8_t i; *length = 0; zeros = 0; while (zeros != 2) 80302ca: 2e02 cmp r6, #2 80302cc: d002 beq.n 80302d4 * @param octets_used returns number of octets used by the length code * @param length return host order length, upto 64k * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_length(struct pbuf *p, u16_t ofs, u8_t *octets_used, u16_t *length) 80302ce: 1c8f adds r7, r1, #2 80302d0: b2bf uxth r7, r7 80302d2: e7d9 b.n 8030288 { zeros = 0; } } } *octets_used = 1; 80302d4: 2301 movs r3, #1 80302d6: e02c b.n 8030332 return ERR_OK; } else if (*msg_ptr == 0x81) 80302d8: 2e81 cmp r6, #129 ; 0x81 80302da: d10c bne.n 80302f6 { /* constructed definite length format, one octet */ ofs += 1; 80302dc: 3101 adds r1, #1 if (ofs >= plen) 80302de: b289 uxth r1, r1 80302e0: 42a1 cmp r1, r4 80302e2: d303 bcc.n 80302ec { /* next octet in next pbuf */ p = p->next; 80302e4: 6801 ldr r1, [r0, #0] if (p == NULL) { return ERR_ARG; } 80302e6: b359 cbz r1, 8030340 msg_ptr = (u8_t*)p->payload; 80302e8: 684d ldr r5, [r1, #4] 80302ea: e000 b.n 80302ee } else { /* next octet in same pbuf */ msg_ptr++; 80302ec: 3501 adds r5, #1 } *length = *msg_ptr; 80302ee: 7829 ldrb r1, [r5, #0] 80302f0: 8019 strh r1, [r3, #0] *octets_used = 2; 80302f2: 2302 movs r3, #2 80302f4: e01d b.n 8030332 return ERR_OK; } else if (*msg_ptr == 0x82) 80302f6: 2e82 cmp r6, #130 ; 0x82 80302f8: d11e bne.n 8030338 /* constructed definite length format, two octets */ i = 2; while (i > 0) { i--; ofs += 1; 80302fa: 1c4e adds r6, r1, #1 if (ofs >= plen) 80302fc: b2b6 uxth r6, r6 80302fe: 42a6 cmp r6, r4 8030300: d201 bcs.n 8030306 plen += p->len; } else { /* next octet in same pbuf */ msg_ptr++; 8030302: 3501 adds r5, #1 8030304: e005 b.n 8030312 i--; ofs += 1; if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; 8030306: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030308: b1d0 cbz r0, 8030340 msg_ptr = (u8_t*)p->payload; plen += p->len; 803030a: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 803030c: 6845 ldr r5, [r0, #4] plen += p->len; 803030e: 19a4 adds r4, r4, r6 8030310: b2a4 uxth r4, r4 *length |= *msg_ptr; } else { /* most significant length octet */ *length = (*msg_ptr) << 8; 8030312: 782e ldrb r6, [r5, #0] /* constructed definite length format, two octets */ i = 2; while (i > 0) { i--; ofs += 1; 8030314: 3102 adds r1, #2 if (ofs >= plen) 8030316: b289 uxth r1, r1 *length |= *msg_ptr; } else { /* most significant length octet */ *length = (*msg_ptr) << 8; 8030318: 0236 lsls r6, r6, #8 i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 803031a: 42a1 cmp r1, r4 *length |= *msg_ptr; } else { /* most significant length octet */ *length = (*msg_ptr) << 8; 803031c: 801e strh r6, [r3, #0] i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 803031e: d201 bcs.n 8030324 plen += p->len; } else { /* next octet in same pbuf */ msg_ptr++; 8030320: 3501 adds r5, #1 8030322: e002 b.n 803032a i--; ofs += 1; if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; 8030324: 6801 ldr r1, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030326: b159 cbz r1, 8030340 msg_ptr = (u8_t*)p->payload; 8030328: 684d ldr r5, [r1, #4] msg_ptr++; } if (i == 0) { /* least significant length octet */ *length |= *msg_ptr; 803032a: 7829 ldrb r1, [r5, #0] 803032c: 430e orrs r6, r1 803032e: 801e strh r6, [r3, #0] { /* most significant length octet */ *length = (*msg_ptr) << 8; } } *octets_used = 3; 8030330: 2303 movs r3, #3 8030332: 7013 strb r3, [r2, #0] return ERR_OK; 8030334: 2000 movs r0, #0 8030336: e00a b.n 803034e } else { /* constructed definite length format 3..127 octets, this is too big (>64k) */ /** @todo: do we need to accept inefficient codings with many leading zero's? */ *octets_used = 1 + ((*msg_ptr) & 0x7f); 8030338: f006 067f and.w r6, r6, #127 ; 0x7f 803033c: 3601 adds r6, #1 803033e: 7016 strb r6, [r2, #0] return ERR_ARG; 8030340: 20f2 movs r0, #242 ; 0xf2 8030342: e004 b.n 803034e } } p = p->next; 8030344: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030346: 4625 mov r5, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 8030348: 2800 cmp r0, #0 803034a: d183 bne.n 8030254 803034c: e7f8 b.n 8030340 p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 803034e: b240 sxtb r0, r0 8030350: bdf0 pop {r4, r5, r6, r7, pc} 08030352 : * as 0x00,0xFF,0xFF. Note the leading sign octet. A positive value * of 0xFFFFFFFF is preceded with 0x00 and the length is 5 octets!! */ err_t snmp_asn1_dec_u32t(struct pbuf *p, u16_t ofs, u16_t len, u32_t *value) { 8030352: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030356: 2500 movs r5, #0 while (p != NULL) 8030358: e049 b.n 80303ee { base = plen; plen += p->len; 803035a: 8944 ldrh r4, [r0, #10] 803035c: 192c adds r4, r5, r4 803035e: b2a4 uxth r4, r4 if (ofs < plen) 8030360: 42a1 cmp r1, r4 8030362: d242 bcs.n 80303ea { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; if ((len > 0) && (len < 6)) 8030364: 1e56 subs r6, r2, #1 { base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; 8030366: f8d0 c004 ldr.w ip, [r0, #4] msg_ptr += ofs - base; if ((len > 0) && (len < 6)) 803036a: b2b6 uxth r6, r6 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 803036c: 1b4f subs r7, r1, r5 if ((len > 0) && (len < 6)) 803036e: 2e04 cmp r6, #4 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 8030370: eb0c 0507 add.w r5, ip, r7 if ((len > 0) && (len < 6)) 8030374: d901 bls.n 803037a *value |= *msg_ptr; return ERR_OK; } else { return ERR_ARG; 8030376: 20f2 movs r0, #242 ; 0xf2 8030378: e03c b.n 80303f4 msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; if ((len > 0) && (len < 6)) { /* start from zero */ *value = 0; 803037a: f04f 0800 mov.w r8, #0 803037e: f8c3 8000 str.w r8, [r3] if (*msg_ptr & 0x80) 8030382: f81c 7007 ldrb.w r7, [ip, r7] 8030386: f017 0f80 tst.w r7, #128 ; 0x80 803038a: d1f4 bne.n 8030376 return ERR_ARG; } else { /* positive */ if ((len > 1) && (*msg_ptr == 0)) 803038c: 2a01 cmp r2, #1 803038e: d00e beq.n 80303ae 8030390: b96f cbnz r7, 80303ae { /* skip leading "sign byte" octet 0x00 */ len--; ofs += 1; 8030392: 3101 adds r1, #1 8030394: b289 uxth r1, r1 if (ofs >= plen) 8030396: 42a1 cmp r1, r4 { /* positive */ if ((len > 1) && (*msg_ptr == 0)) { /* skip leading "sign byte" octet 0x00 */ len--; 8030398: 4632 mov r2, r6 ofs += 1; if (ofs >= plen) 803039a: d307 bcc.n 80303ac { /* next octet in next pbuf */ p = p->next; 803039c: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 803039e: 2800 cmp r0, #0 80303a0: d0e9 beq.n 8030376 msg_ptr = (u8_t*)p->payload; plen += p->len; 80303a2: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80303a4: 6845 ldr r5, [r0, #4] plen += p->len; 80303a6: 19a4 adds r4, r4, r6 80303a8: b2a4 uxth r4, r4 80303aa: e000 b.n 80303ae } else { /* next octet in same pbuf */ msg_ptr++; 80303ac: 3501 adds r5, #1 80303ae: 1c4e adds r6, r1, #1 * @note ASN coded integers are _always_ signed. E.g. +0xFFFF is coded * as 0x00,0xFF,0xFF. Note the leading sign octet. A positive value * of 0xFFFFFFFF is preceded with 0x00 and the length is 5 octets!! */ err_t snmp_asn1_dec_u32t(struct pbuf *p, u16_t ofs, u16_t len, u32_t *value) 80303b0: 188a adds r2, r1, r2 80303b2: b2b6 uxth r6, r6 80303b4: b292 uxth r2, r2 80303b6: e010 b.n 80303da } /* OR octets with value */ while (len > 1) { len--; *value |= *msg_ptr; 80303b8: 7829 ldrb r1, [r5, #0] 80303ba: 430f orrs r7, r1 *value <<= 8; 80303bc: 023f lsls r7, r7, #8 ofs += 1; if (ofs >= plen) 80303be: 42a6 cmp r6, r4 /* OR octets with value */ while (len > 1) { len--; *value |= *msg_ptr; *value <<= 8; 80303c0: 601f str r7, [r3, #0] ofs += 1; if (ofs >= plen) 80303c2: d307 bcc.n 80303d4 { /* next octet in next pbuf */ p = p->next; 80303c4: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 80303c6: 2800 cmp r0, #0 80303c8: d0d5 beq.n 8030376 msg_ptr = (u8_t*)p->payload; plen += p->len; 80303ca: 8941 ldrh r1, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80303cc: 6845 ldr r5, [r0, #4] plen += p->len; 80303ce: 1864 adds r4, r4, r1 80303d0: b2a4 uxth r4, r4 80303d2: e000 b.n 80303d6 } else { /* next octet in same pbuf */ msg_ptr++; 80303d4: 3501 adds r5, #1 80303d6: 3601 adds r6, #1 80303d8: b2b6 uxth r6, r6 msg_ptr++; } } } /* OR octets with value */ while (len > 1) 80303da: 4296 cmp r6, r2 80303dc: 681f ldr r7, [r3, #0] 80303de: d1eb bne.n 80303b8 { /* next octet in same pbuf */ msg_ptr++; } } *value |= *msg_ptr; 80303e0: 782a ldrb r2, [r5, #0] 80303e2: 4317 orrs r7, r2 80303e4: 601f str r7, [r3, #0] return ERR_OK; 80303e6: 2000 movs r0, #0 80303e8: e004 b.n 80303f4 else { return ERR_ARG; } } p = p->next; 80303ea: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 80303ec: 4625 mov r5, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 80303ee: 2800 cmp r0, #0 80303f0: d1b3 bne.n 803035a 80303f2: e7c0 b.n 8030376 } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 80303f4: b240 sxtb r0, r0 80303f6: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 080303fa : * * @note ASN coded integers are _always_ signed! */ err_t snmp_asn1_dec_s32t(struct pbuf *p, u16_t ofs, u16_t len, s32_t *value) { 80303fa: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} #if BYTE_ORDER == BIG_ENDIAN u8_t *lsb_ptr = (u8_t*)value + sizeof(s32_t) - 1; #endif u8_t sign; plen = 0; 80303fe: 2500 movs r5, #0 while (p != NULL) 8030400: e04e b.n 80304a0 { base = plen; plen += p->len; 8030402: 8944 ldrh r4, [r0, #10] 8030404: 192c adds r4, r5, r4 8030406: b2a4 uxth r4, r4 if (ofs < plen) 8030408: 42a1 cmp r1, r4 803040a: d247 bcs.n 803049c { msg_ptr = (u8_t*)p->payload; 803040c: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; if ((len > 0) && (len < 5)) 803040e: f102 3cff add.w ip, r2, #4294967295 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 8030412: 1b4e subs r6, r1, r5 if ((len > 0) && (len < 5)) 8030414: f1bc 0f03 cmp.w ip, #3 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 8030418: eb07 0506 add.w r5, r7, r6 if ((len > 0) && (len < 5)) 803041c: d901 bls.n 8030422 } return ERR_OK; } else { return ERR_ARG; 803041e: 20f2 movs r0, #242 ; 0xf2 8030420: e041 b.n 80304a6 { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; if ((len > 0) && (len < 5)) { if (*msg_ptr & 0x80) 8030422: 57be ldrsb r6, [r7, r6] 8030424: 2e00 cmp r6, #0 8030426: da0b bge.n 8030440 { /* negative, start from -1 */ *value = -1; 8030428: f04f 36ff mov.w r6, #4294967295 803042c: 601e str r6, [r3, #0] sign = 1; 803042e: 2601 movs r6, #1 8030430: f101 0c01 add.w ip, r1, #1 * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode * * @note ASN coded integers are _always_ signed! */ err_t snmp_asn1_dec_s32t(struct pbuf *p, u16_t ofs, u16_t len, s32_t *value) 8030434: 1852 adds r2, r2, r1 8030436: fa1f fc8c uxth.w ip, ip 803043a: b292 uxth r2, r2 len--; if (sign) { *lsb_ptr &= *msg_ptr; *value <<= 8; *lsb_ptr |= 255; 803043c: 21ff movs r1, #255 ; 0xff 803043e: e022 b.n 8030486 sign = 1; } else { /* positive, start from 0 */ *value = 0; 8030440: 2600 movs r6, #0 8030442: 601e str r6, [r3, #0] 8030444: e7f4 b.n 8030430 8030446: f895 8000 ldrb.w r8, [r5] } /* OR/AND octets with value */ while (len > 1) { len--; if (sign) 803044a: b13e cbz r6, 803045c { *lsb_ptr &= *msg_ptr; 803044c: ea08 0707 and.w r7, r8, r7 8030450: 701f strb r7, [r3, #0] *value <<= 8; 8030452: 681f ldr r7, [r3, #0] 8030454: 023f lsls r7, r7, #8 8030456: 601f str r7, [r3, #0] *lsb_ptr |= 255; 8030458: 7019 strb r1, [r3, #0] 803045a: e005 b.n 8030468 } else { *lsb_ptr |= *msg_ptr; 803045c: ea48 0707 orr.w r7, r8, r7 8030460: 701f strb r7, [r3, #0] *value <<= 8; 8030462: 681f ldr r7, [r3, #0] 8030464: 023f lsls r7, r7, #8 8030466: 601f str r7, [r3, #0] } ofs += 1; if (ofs >= plen) 8030468: 45a4 cmp ip, r4 803046a: d307 bcc.n 803047c { /* next octet in next pbuf */ p = p->next; 803046c: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 803046e: 2800 cmp r0, #0 8030470: d0d5 beq.n 803041e msg_ptr = (u8_t*)p->payload; plen += p->len; 8030472: 8947 ldrh r7, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030474: 6845 ldr r5, [r0, #4] plen += p->len; 8030476: 19e4 adds r4, r4, r7 8030478: b2a4 uxth r4, r4 803047a: e000 b.n 803047e } else { /* next octet in same pbuf */ msg_ptr++; 803047c: 3501 adds r5, #1 803047e: f10c 0c01 add.w ip, ip, #1 8030482: fa1f fc8c uxth.w ip, ip /* positive, start from 0 */ *value = 0; sign = 0; } /* OR/AND octets with value */ while (len > 1) 8030486: 4594 cmp ip, r2 8030488: 781f ldrb r7, [r3, #0] 803048a: d1dc bne.n 8030446 803048c: 782a ldrb r2, [r5, #0] { /* next octet in same pbuf */ msg_ptr++; } } if (sign) 803048e: b11e cbz r6, 8030498 { *lsb_ptr &= *msg_ptr; 8030490: 4017 ands r7, r2 8030492: 701f strb r7, [r3, #0] } else { *lsb_ptr |= *msg_ptr; } return ERR_OK; 8030494: 2000 movs r0, #0 8030496: e006 b.n 80304a6 { *lsb_ptr &= *msg_ptr; } else { *lsb_ptr |= *msg_ptr; 8030498: 4317 orrs r7, r2 803049a: e7fa b.n 8030492 else { return ERR_ARG; } } p = p->next; 803049c: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 803049e: 4625 mov r5, r4 u8_t *lsb_ptr = (u8_t*)value + sizeof(s32_t) - 1; #endif u8_t sign; plen = 0; while (p != NULL) 80304a0: 2800 cmp r0, #0 80304a2: d1ae bne.n 8030402 80304a4: e7bb b.n 803041e } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 80304a6: b240 sxtb r0, r0 80304a8: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 080304ac : * @param oid return object identifier struct * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_oid(struct pbuf *p, u16_t ofs, u16_t len, struct snmp_obj_id *oid) { 80304ac: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} u16_t plen, base; u8_t *msg_ptr; s32_t *oid_ptr; plen = 0; 80304b0: 2600 movs r6, #0 while (p != NULL) 80304b2: e08d b.n 80305d0 { base = plen; plen += p->len; 80304b4: 8944 ldrh r4, [r0, #10] 80304b6: 1934 adds r4, r6, r4 80304b8: b2a4 uxth r4, r4 if (ofs < plen) 80304ba: 42a1 cmp r1, r4 80304bc: f080 8086 bcs.w 80305cc { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; oid->len = 0; 80304c0: f04f 0800 mov.w r8, #0 { base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; 80304c4: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; oid->len = 0; 80304c6: f883 8000 strb.w r8, [r3] oid_ptr = &oid->id[0]; if (len > 0) 80304ca: b90a cbnz r2, 80304d0 } else { /* accepting zero length identifiers e.g. for getnext operation. uncommon but valid */ return ERR_OK; 80304cc: 2000 movs r0, #0 80304ce: e083 b.n 80305d8 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 80304d0: 1b8e subs r6, r1, r6 80304d2: 19bd adds r5, r7, r6 oid->len = 0; oid_ptr = &oid->id[0]; if (len > 0) { /* first compressed octet */ if (*msg_ptr == 0x2B) 80304d4: f817 c006 ldrb.w ip, [r7, r6] 80304d8: f1bc 0f2b cmp.w ip, #43 ; 0x2b 80304dc: d103 bne.n 80304e6 { /* (most) common case 1.3 (iso.org) */ *oid_ptr = 1; 80304de: 2601 movs r6, #1 80304e0: 605e str r6, [r3, #4] oid_ptr++; *oid_ptr = 3; 80304e2: 2603 movs r6, #3 80304e4: e016 b.n 8030514 oid_ptr++; } else if (*msg_ptr < 40) 80304e6: f1bc 0f27 cmp.w ip, #39 ; 0x27 80304ea: d803 bhi.n 80304f4 { *oid_ptr = 0; 80304ec: f8c3 8004 str.w r8, [r3, #4] oid_ptr++; *oid_ptr = *msg_ptr; 80304f0: 5dbe ldrb r6, [r7, r6] 80304f2: e00f b.n 8030514 oid_ptr++; } else if (*msg_ptr < 80) 80304f4: f1bc 0f4f cmp.w ip, #79 ; 0x4f 80304f8: d806 bhi.n 8030508 { *oid_ptr = 1; 80304fa: f04f 0c01 mov.w ip, #1 80304fe: f8c3 c004 str.w ip, [r3, #4] oid_ptr++; *oid_ptr = (*msg_ptr) - 40; 8030502: 5dbe ldrb r6, [r7, r6] 8030504: 3e28 subs r6, #40 ; 0x28 8030506: e005 b.n 8030514 oid_ptr++; } else { *oid_ptr = 2; 8030508: f04f 0c02 mov.w ip, #2 803050c: f8c3 c004 str.w ip, [r3, #4] oid_ptr++; *oid_ptr = (*msg_ptr) - 80; 8030510: 5dbe ldrb r6, [r7, r6] 8030512: 3e50 subs r6, #80 ; 0x50 { /* accepting zero length identifiers e.g. for getnext operation. uncommon but valid */ return ERR_OK; } len--; 8030514: 3a01 subs r2, #1 *oid_ptr = 2; oid_ptr++; *oid_ptr = (*msg_ptr) - 80; oid_ptr++; } oid->len = 2; 8030516: 2702 movs r7, #2 { /* accepting zero length identifiers e.g. for getnext operation. uncommon but valid */ return ERR_OK; } len--; 8030518: b292 uxth r2, r2 } else { *oid_ptr = 2; oid_ptr++; *oid_ptr = (*msg_ptr) - 80; 803051a: 609e str r6, [r3, #8] oid_ptr++; } oid->len = 2; 803051c: 701f strb r7, [r3, #0] else { *oid_ptr = 2; oid_ptr++; *oid_ptr = (*msg_ptr) - 80; oid_ptr++; 803051e: f103 060c add.w r6, r3, #12 /* accepting zero length identifiers e.g. for getnext operation. uncommon but valid */ return ERR_OK; } len--; if (len > 0) 8030522: 2a00 cmp r2, #0 8030524: d04b beq.n 80305be { ofs += 1; 8030526: 3101 adds r1, #1 8030528: b289 uxth r1, r1 if (ofs >= plen) 803052a: 42a1 cmp r1, r4 803052c: d308 bcc.n 8030540 { /* next octet in next pbuf */ p = p->next; 803052e: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030530: b908 cbnz r0, 8030536 8030532: 20f2 movs r0, #242 ; 0xf2 8030534: e050 b.n 80305d8 msg_ptr = (u8_t*)p->payload; plen += p->len; 8030536: 8947 ldrh r7, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030538: 6845 ldr r5, [r0, #4] plen += p->len; 803053a: 19e4 adds r4, r4, r7 803053c: b2a4 uxth r4, r4 803053e: e03e b.n 80305be } else { /* next octet in same pbuf */ msg_ptr++; 8030540: 3501 adds r5, #1 8030542: e03c b.n 80305be } } while ((len > 0) && (oid->len < LWIP_SNMP_OBJ_ID_LEN)) { /* sub-identifier uses multiple octets */ if (*msg_ptr & 0x80) 8030544: 782f ldrb r7, [r5, #0] 8030546: f017 0f80 tst.w r7, #128 ; 0x80 803054a: d023 beq.n 8030594 803054c: e014 b.n 8030578 while ((*msg_ptr & 0x80) && (len > 1)) { len--; sub_id = (sub_id << 7) + (*msg_ptr & ~0x80); ofs += 1; 803054e: 3101 adds r1, #1 8030550: b289 uxth r1, r1 { s32_t sub_id = 0; while ((*msg_ptr & 0x80) && (len > 1)) { len--; 8030552: 3a01 subs r2, #1 sub_id = (sub_id << 7) + (*msg_ptr & ~0x80); 8030554: f02c 0c80 bic.w ip, ip, #128 ; 0x80 ofs += 1; if (ofs >= plen) 8030558: 42a1 cmp r1, r4 { s32_t sub_id = 0; while ((*msg_ptr & 0x80) && (len > 1)) { len--; 803055a: b292 uxth r2, r2 sub_id = (sub_id << 7) + (*msg_ptr & ~0x80); 803055c: eb0c 17c7 add.w r7, ip, r7, lsl #7 ofs += 1; if (ofs >= plen) 8030560: d308 bcc.n 8030574 { /* next octet in next pbuf */ p = p->next; 8030562: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030564: 2800 cmp r0, #0 8030566: d0e4 beq.n 8030532 msg_ptr = (u8_t*)p->payload; plen += p->len; 8030568: f8b0 c00a ldrh.w ip, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 803056c: 6845 ldr r5, [r0, #4] plen += p->len; 803056e: 4464 add r4, ip 8030570: b2a4 uxth r4, r4 8030572: e002 b.n 803057a } else { /* next octet in same pbuf */ msg_ptr++; 8030574: 3501 adds r5, #1 8030576: e000 b.n 803057a } } while ((len > 0) && (oid->len < LWIP_SNMP_OBJ_ID_LEN)) { /* sub-identifier uses multiple octets */ if (*msg_ptr & 0x80) 8030578: 2700 movs r7, #0 { s32_t sub_id = 0; while ((*msg_ptr & 0x80) && (len > 1)) 803057a: f895 c000 ldrb.w ip, [r5] 803057e: f01c 0f80 tst.w ip, #128 ; 0x80 8030582: d02c beq.n 80305de 8030584: 2a01 cmp r2, #1 8030586: d1e2 bne.n 803054e 8030588: e009 b.n 803059e } } if (!(*msg_ptr & 0x80) && (len > 0)) { /* last octet sub-identifier */ len--; 803058a: 3a01 subs r2, #1 803058c: b292 uxth r2, r2 sub_id = (sub_id << 7) + *msg_ptr; 803058e: eb0c 17c7 add.w r7, ip, r7, lsl #7 8030592: e001 b.n 8030598 } } else { /* !(*msg_ptr & 0x80) sub-identifier uses single octet */ len--; 8030594: 3a01 subs r2, #1 8030596: b292 uxth r2, r2 *oid_ptr = *msg_ptr; 8030598: f846 7c04 str.w r7, [r6, #-4] } if (len > 0) 803059c: b162 cbz r2, 80305b8 { /* remaining oid bytes available ... */ ofs += 1; 803059e: 3101 adds r1, #1 80305a0: b289 uxth r1, r1 if (ofs >= plen) 80305a2: 42a1 cmp r1, r4 80305a4: d307 bcc.n 80305b6 { /* next octet in next pbuf */ p = p->next; 80305a6: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 80305a8: 2800 cmp r0, #0 80305aa: d0c2 beq.n 8030532 msg_ptr = (u8_t*)p->payload; plen += p->len; 80305ac: 8947 ldrh r7, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80305ae: 6845 ldr r5, [r0, #4] plen += p->len; 80305b0: 19e4 adds r4, r4, r7 80305b2: b2a4 uxth r4, r4 80305b4: e000 b.n 80305b8 } else { /* next octet in same pbuf */ msg_ptr++; 80305b6: 3501 adds r5, #1 } } oid_ptr++; oid->len++; 80305b8: 781f ldrb r7, [r3, #0] 80305ba: 3701 adds r7, #1 80305bc: 701f strb r7, [r3, #0] 80305be: 3604 adds r6, #4 { /* next octet in same pbuf */ msg_ptr++; } } while ((len > 0) && (oid->len < LWIP_SNMP_OBJ_ID_LEN)) 80305c0: 2a00 cmp r2, #0 80305c2: d083 beq.n 80304cc 80305c4: 781f ldrb r7, [r3, #0] 80305c6: 2f1f cmp r7, #31 80305c8: d9bc bls.n 8030544 80305ca: e7b2 b.n 8030532 /* len > 0, oid->len == LWIP_SNMP_OBJ_ID_LEN or malformed encoding */ return ERR_ARG; } } p = p->next; 80305cc: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 80305ce: 4626 mov r6, r4 u16_t plen, base; u8_t *msg_ptr; s32_t *oid_ptr; plen = 0; while (p != NULL) 80305d0: 2800 cmp r0, #0 80305d2: f47f af6f bne.w 80304b4 80305d6: e7ac b.n 8030532 80305d8: b240 sxtb r0, r0 80305da: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} { /* next octet in same pbuf */ msg_ptr++; } } if (!(*msg_ptr & 0x80) && (len > 0)) 80305de: 2a00 cmp r2, #0 80305e0: d1d3 bne.n 803058a 80305e2: e7e9 b.n 80305b8 080305e4 : * @param raw return raw bytes * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_raw(struct pbuf *p, u16_t ofs, u16_t len, u16_t raw_len, u8_t *raw) { 80305e4: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; if (len > 0) 80305e6: 2a00 cmp r2, #0 80305e8: d12d bne.n 8030646 80305ea: e027 b.n 803063c { plen = 0; while (p != NULL) { base = plen; plen += p->len; 80305ec: 8944 ldrh r4, [r0, #10] 80305ee: 1934 adds r4, r6, r4 80305f0: b2a4 uxth r4, r4 if (ofs < plen) 80305f2: 42a1 cmp r1, r4 80305f4: d224 bcs.n 8030640 { msg_ptr = (u8_t*)p->payload; 80305f6: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; 80305f8: 1b8d subs r5, r1, r6 if (raw_len >= len) 80305fa: 4293 cmp r3, r2 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 80305fc: 443d add r5, r7 if (raw_len >= len) 80305fe: d305 bcc.n 803060c 8030600: 9b05 ldr r3, [sp, #20] * @param raw_len length of the raw return value * @param raw return raw bytes * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_raw(struct pbuf *p, u16_t ofs, u16_t len, u16_t raw_len, u8_t *raw) 8030602: b29e uxth r6, r3 8030604: 18b2 adds r2, r6, r2 8030606: b292 uxth r2, r2 8030608: 1b89 subs r1, r1, r6 803060a: e011 b.n 8030630 return ERR_OK; } else { /* raw_len < len, not enough dst space */ return ERR_ARG; 803060c: 20f2 movs r0, #242 ; 0xf2 803060e: e01e b.n 803064e { while (len > 1) { /* copy len - 1 octets */ len--; *raw = *msg_ptr; 8030610: 782e ldrb r6, [r5, #0] 8030612: f803 6b01 strb.w r6, [r3], #1 * @param raw_len length of the raw return value * @param raw return raw bytes * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) decode */ err_t snmp_asn1_dec_raw(struct pbuf *p, u16_t ofs, u16_t len, u16_t raw_len, u8_t *raw) 8030616: 18ce adds r6, r1, r3 /* copy len - 1 octets */ len--; *raw = *msg_ptr; raw++; ofs += 1; if (ofs >= plen) 8030618: b2b6 uxth r6, r6 803061a: 42a6 cmp r6, r4 803061c: d307 bcc.n 803062e { /* next octet in next pbuf */ p = p->next; 803061e: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030620: 2800 cmp r0, #0 8030622: d0f3 beq.n 803060c msg_ptr = (u8_t*)p->payload; plen += p->len; 8030624: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030626: 6845 ldr r5, [r0, #4] plen += p->len; 8030628: 19a4 adds r4, r4, r6 803062a: b2a4 uxth r4, r4 803062c: e000 b.n 8030630 } else { /* next octet in same pbuf */ msg_ptr++; 803062e: 3501 adds r5, #1 { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; if (raw_len >= len) { while (len > 1) 8030630: 1ad7 subs r7, r2, r3 8030632: b2bf uxth r7, r7 8030634: 2f01 cmp r7, #1 8030636: d8eb bhi.n 8030610 /* next octet in same pbuf */ msg_ptr++; } } /* copy last octet */ *raw = *msg_ptr; 8030638: 782a ldrb r2, [r5, #0] 803063a: 701a strb r2, [r3, #0] return ERR_OK; 803063c: 2000 movs r0, #0 803063e: e006 b.n 803064e { /* raw_len < len, not enough dst space */ return ERR_ARG; } } p = p->next; 8030640: 6800 ldr r0, [r0, #0] { plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030642: 4626 mov r6, r4 8030644: e000 b.n 8030648 snmp_asn1_dec_raw(struct pbuf *p, u16_t ofs, u16_t len, u16_t raw_len, u8_t *raw) { u16_t plen, base; u8_t *msg_ptr; if (len > 0) 8030646: 2600 movs r6, #0 { plen = 0; while (p != NULL) 8030648: 2800 cmp r0, #0 803064a: d1cf bne.n 80305ec 803064c: e7de b.n 803060c else { /* len == 0, empty string */ return ERR_OK; } } 803064e: b240 sxtb r0, r0 8030650: bdf0 pop {r4, r5, r6, r7, pc} 08030652 : * @param octets_needed points to the return value */ void snmp_asn1_enc_length_cnt(u16_t length, u8_t *octets_needed) { if (length < 0x80U) 8030652: 287f cmp r0, #127 ; 0x7f 8030654: d801 bhi.n 803065a { *octets_needed = 1; 8030656: 2301 movs r3, #1 8030658: e004 b.n 8030664 } else if (length < 0x100U) 803065a: 28ff cmp r0, #255 ; 0xff 803065c: d801 bhi.n 8030662 { *octets_needed = 2; 803065e: 2302 movs r3, #2 8030660: e000 b.n 8030664 } else { *octets_needed = 3; 8030662: 2303 movs r3, #3 8030664: 700b strb r3, [r1, #0] 8030666: 4770 bx lr 08030668 : * of 0xFFFFFFFF is preceded with 0x00 and the length is 5 octets!! */ void snmp_asn1_enc_u32t_cnt(u32_t value, u16_t *octets_needed) { if (value < 0x80UL) 8030668: 287f cmp r0, #127 ; 0x7f 803066a: d801 bhi.n 8030670 { *octets_needed = 1; 803066c: 2301 movs r3, #1 803066e: e00e b.n 803068e } else if (value < 0x8000UL) 8030670: f5b0 4f00 cmp.w r0, #32768 ; 0x8000 8030674: d201 bcs.n 803067a { *octets_needed = 2; 8030676: 2302 movs r3, #2 8030678: e009 b.n 803068e } else if (value < 0x800000UL) 803067a: f5b0 0f00 cmp.w r0, #8388608 ; 0x800000 803067e: d201 bcs.n 8030684 { *octets_needed = 3; 8030680: 2303 movs r3, #3 8030682: e004 b.n 803068e } else if (value < 0x80000000UL) 8030684: 2800 cmp r0, #0 8030686: db01 blt.n 803068c { *octets_needed = 4; 8030688: 2304 movs r3, #4 803068a: e000 b.n 803068e } else { *octets_needed = 5; 803068c: 2305 movs r3, #5 803068e: 800b strh r3, [r1, #0] 8030690: 4770 bx lr 08030692 : void snmp_asn1_enc_s32t_cnt(s32_t value, u16_t *octets_needed) { if (value < 0) { value = ~value; 8030692: 43c3 mvns r3, r0 8030694: 4283 cmp r3, r0 8030696: bfa8 it ge 8030698: 4618 movge r0, r3 } if (value < 0x80L) 803069a: 287f cmp r0, #127 ; 0x7f 803069c: dc01 bgt.n 80306a2 { *octets_needed = 1; 803069e: 2301 movs r3, #1 80306a0: e00a b.n 80306b8 } else if (value < 0x8000L) 80306a2: f5b0 4f00 cmp.w r0, #32768 ; 0x8000 80306a6: da01 bge.n 80306ac { *octets_needed = 2; 80306a8: 2302 movs r3, #2 80306aa: e005 b.n 80306b8 } else if (value < 0x800000L) 80306ac: f5b0 0f00 cmp.w r0, #8388608 ; 0x800000 80306b0: da01 bge.n 80306b6 { *octets_needed = 3; 80306b2: 2303 movs r3, #3 80306b4: e000 b.n 80306b8 } else { *octets_needed = 4; 80306b6: 2304 movs r3, #4 80306b8: 800b strh r3, [r1, #0] 80306ba: 4770 bx lr 080306bc : { s32_t sub_id; u8_t cnt; cnt = 0; if (ident_len > 1) 80306bc: 2801 cmp r0, #1 * @param ident points to object identifier array * @param octets_needed points to the return value */ void snmp_asn1_enc_oid_cnt(u8_t ident_len, s32_t *ident, u16_t *octets_needed) { 80306be: b510 push {r4, lr} s32_t sub_id; u8_t cnt; cnt = 0; if (ident_len > 1) 80306c0: d904 bls.n 80306cc { /* compressed prefix in one octet */ cnt++; ident_len -= 2; 80306c2: 3802 subs r0, #2 80306c4: b2c0 uxtb r0, r0 ident += 2; 80306c6: 3108 adds r1, #8 cnt = 0; if (ident_len > 1) { /* compressed prefix in one octet */ cnt++; 80306c8: 2301 movs r3, #1 80306ca: e000 b.n 80306ce snmp_asn1_enc_oid_cnt(u8_t ident_len, s32_t *ident, u16_t *octets_needed) { s32_t sub_id; u8_t cnt; cnt = 0; 80306cc: 2300 movs r3, #0 * @param ident_len object identifier array length * @param ident points to object identifier array * @param octets_needed points to the return value */ void snmp_asn1_enc_oid_cnt(u8_t ident_len, s32_t *ident, u16_t *octets_needed) 80306ce: 3904 subs r1, #4 80306d0: e008 b.n 80306e4 ident_len -= 2; ident += 2; } while(ident_len > 0) { ident_len--; 80306d2: 3801 subs r0, #1 sub_id = *ident; 80306d4: f851 4f04 ldr.w r4, [r1, #4]! ident_len -= 2; ident += 2; } while(ident_len > 0) { ident_len--; 80306d8: b2c0 uxtb r0, r0 sub_id >>= 7; cnt++; while(sub_id > 0) { sub_id >>= 7; 80306da: 11e4 asrs r4, r4, #7 cnt++; 80306dc: 3301 adds r3, #1 ident_len--; sub_id = *ident; sub_id >>= 7; cnt++; while(sub_id > 0) 80306de: 2c00 cmp r4, #0 { sub_id >>= 7; cnt++; 80306e0: b2db uxtb r3, r3 ident_len--; sub_id = *ident; sub_id >>= 7; cnt++; while(sub_id > 0) 80306e2: dcfa bgt.n 80306da /* compressed prefix in one octet */ cnt++; ident_len -= 2; ident += 2; } while(ident_len > 0) 80306e4: 2800 cmp r0, #0 80306e6: d1f4 bne.n 80306d2 sub_id >>= 7; cnt++; } ident++; } *octets_needed = cnt; 80306e8: 8013 strh r3, [r2, #0] 80306ea: bd10 pop {r4, pc} 080306ec : * @param type input ASN1 type * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_type(struct pbuf *p, u16_t ofs, u8_t type) { 80306ec: b510 push {r4, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 80306ee: 2300 movs r3, #0 while (p != NULL) 80306f0: e00b b.n 803070a { base = plen; plen += p->len; 80306f2: 8944 ldrh r4, [r0, #10] 80306f4: 191c adds r4, r3, r4 80306f6: b2a4 uxth r4, r4 if (ofs < plen) 80306f8: 42a1 cmp r1, r4 80306fa: d204 bcs.n 8030706 { msg_ptr = (u8_t*)p->payload; 80306fc: 6840 ldr r0, [r0, #4] msg_ptr += ofs - base; 80306fe: 1acb subs r3, r1, r3 *msg_ptr = type; 8030700: 54c2 strb r2, [r0, r3] return ERR_OK; 8030702: 2000 movs r0, #0 8030704: e004 b.n 8030710 } p = p->next; 8030706: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030708: 4623 mov r3, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 803070a: 2800 cmp r0, #0 803070c: d1f1 bne.n 80306f2 return ERR_OK; } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; 803070e: 20f2 movs r0, #242 ; 0xf2 } 8030710: b240 sxtb r0, r0 8030712: bd10 pop {r4, pc} 08030714 : * @param length is the host order length to be encoded * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_length(struct pbuf *p, u16_t ofs, u16_t length) { 8030714: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030716: 2400 movs r4, #0 while (p != NULL) 8030718: e03f b.n 803079a { base = plen; plen += p->len; 803071a: 8943 ldrh r3, [r0, #10] 803071c: 18e3 adds r3, r4, r3 803071e: b29b uxth r3, r3 if (ofs < plen) 8030720: 4299 cmp r1, r3 8030722: d238 bcs.n 8030796 { msg_ptr = (u8_t*)p->payload; 8030724: 6845 ldr r5, [r0, #4] msg_ptr += ofs - base; 8030726: 1b0c subs r4, r1, r4 if (length < 0x80) 8030728: 2a7f cmp r2, #127 ; 0x7f base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 803072a: eb05 0604 add.w r6, r5, r4 if (length < 0x80) 803072e: d801 bhi.n 8030734 { *msg_ptr = (u8_t)length; 8030730: 552a strb r2, [r5, r4] 8030732: e02e b.n 8030792 return ERR_OK; } else if (length < 0x100) 8030734: 2aff cmp r2, #255 ; 0xff 8030736: f101 0701 add.w r7, r1, #1 803073a: d80d bhi.n 8030758 { *msg_ptr = 0x81; ofs += 1; if (ofs >= plen) 803073c: b2bf uxth r7, r7 *msg_ptr = (u8_t)length; return ERR_OK; } else if (length < 0x100) { *msg_ptr = 0x81; 803073e: 2181 movs r1, #129 ; 0x81 ofs += 1; if (ofs >= plen) 8030740: 429f cmp r7, r3 *msg_ptr = (u8_t)length; return ERR_OK; } else if (length < 0x100) { *msg_ptr = 0x81; 8030742: 5529 strb r1, [r5, r4] ofs += 1; if (ofs >= plen) 8030744: d305 bcc.n 8030752 { /* next octet in next pbuf */ p = p->next; 8030746: 6803 ldr r3, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030748: b90b cbnz r3, 803074e 803074a: 20f2 movs r0, #242 ; 0xf2 803074c: e028 b.n 80307a0 msg_ptr = (u8_t*)p->payload; 803074e: 685e ldr r6, [r3, #4] 8030750: e000 b.n 8030754 } else { /* next octet in same pbuf */ msg_ptr++; 8030752: 3601 adds r6, #1 } *msg_ptr = (u8_t)length; 8030754: 7032 strb r2, [r6, #0] 8030756: e01c b.n 8030792 i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 8030758: b2bf uxth r7, r7 else { u8_t i; /* length >= 0x100 && length <= 0xFFFF */ *msg_ptr = 0x82; 803075a: f04f 0c82 mov.w ip, #130 ; 0x82 i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 803075e: 429f cmp r7, r3 else { u8_t i; /* length >= 0x100 && length <= 0xFFFF */ *msg_ptr = 0x82; 8030760: f805 c004 strb.w ip, [r5, r4] i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 8030764: d201 bcs.n 803076a plen += p->len; } else { /* next octet in same pbuf */ msg_ptr++; 8030766: 1c74 adds r4, r6, #1 8030768: e006 b.n 8030778 i--; ofs += 1; if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; 803076a: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 803076c: 2800 cmp r0, #0 803076e: d0ec beq.n 803074a msg_ptr = (u8_t*)p->payload; plen += p->len; 8030770: 8945 ldrh r5, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030772: 6844 ldr r4, [r0, #4] plen += p->len; 8030774: 195b adds r3, r3, r5 8030776: b29b uxth r3, r3 *msg_ptr = 0x82; i = 2; while (i > 0) { i--; ofs += 1; 8030778: 3102 adds r1, #2 if (ofs >= plen) 803077a: b289 uxth r1, r1 *msg_ptr = (u8_t)length; } else { /* most significant length octet */ *msg_ptr = (u8_t)(length >> 8); 803077c: 0a15 lsrs r5, r2, #8 i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 803077e: 4299 cmp r1, r3 *msg_ptr = (u8_t)length; } else { /* most significant length octet */ *msg_ptr = (u8_t)(length >> 8); 8030780: 7025 strb r5, [r4, #0] i = 2; while (i > 0) { i--; ofs += 1; if (ofs >= plen) 8030782: d201 bcs.n 8030788 plen += p->len; } else { /* next octet in same pbuf */ msg_ptr++; 8030784: 3401 adds r4, #1 8030786: e003 b.n 8030790 i--; ofs += 1; if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; 8030788: 6803 ldr r3, [r0, #0] if (p == NULL) { return ERR_ARG; } 803078a: 2b00 cmp r3, #0 803078c: d0dd beq.n 803074a msg_ptr = (u8_t*)p->payload; 803078e: 685c ldr r4, [r3, #4] msg_ptr++; } if (i == 0) { /* least significant length octet */ *msg_ptr = (u8_t)length; 8030790: 7022 strb r2, [r4, #0] { /* most significant length octet */ *msg_ptr = (u8_t)(length >> 8); } } return ERR_OK; 8030792: 2000 movs r0, #0 8030794: e004 b.n 80307a0 } } p = p->next; 8030796: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030798: 461c mov r4, r3 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 803079a: 2800 cmp r0, #0 803079c: d1bd bne.n 803071a 803079e: e7d4 b.n 803074a } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 80307a0: b240 sxtb r0, r0 80307a2: bdf0 pop {r4, r5, r6, r7, pc} 080307a4 : * * @see snmp_asn1_enc_u32t_cnt() */ err_t snmp_asn1_enc_u32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, u32_t value) { 80307a4: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 80307a6: 2500 movs r5, #0 while (p != NULL) 80307a8: e037 b.n 803081a { base = plen; plen += p->len; 80307aa: 8944 ldrh r4, [r0, #10] 80307ac: 192c adds r4, r5, r4 80307ae: b2a4 uxth r4, r4 if (ofs < plen) 80307b0: 42a1 cmp r1, r4 80307b2: d230 bcs.n 8030816 { msg_ptr = (u8_t*)p->payload; 80307b4: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; 80307b6: 1b4e subs r6, r1, r5 if (octets_needed == 5) 80307b8: 2a05 cmp r2, #5 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 80307ba: eb07 0506 add.w r5, r7, r6 if (octets_needed == 5) 80307be: d110 bne.n 80307e2 { /* not enough bits in 'value' add leading 0x00 */ octets_needed--; *msg_ptr = 0x00; ofs += 1; 80307c0: 3101 adds r1, #1 80307c2: b289 uxth r1, r1 if (octets_needed == 5) { /* not enough bits in 'value' add leading 0x00 */ octets_needed--; *msg_ptr = 0x00; 80307c4: 2200 movs r2, #0 ofs += 1; if (ofs >= plen) 80307c6: 42a1 cmp r1, r4 if (octets_needed == 5) { /* not enough bits in 'value' add leading 0x00 */ octets_needed--; *msg_ptr = 0x00; 80307c8: 55ba strb r2, [r7, r6] ofs += 1; if (ofs >= plen) 80307ca: d308 bcc.n 80307de { /* next octet in next pbuf */ p = p->next; 80307cc: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 80307ce: b908 cbnz r0, 80307d4 80307d0: 20f2 movs r0, #242 ; 0xf2 80307d2: e025 b.n 8030820 msg_ptr = (u8_t*)p->payload; plen += p->len; 80307d4: 8942 ldrh r2, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80307d6: 6845 ldr r5, [r0, #4] plen += p->len; 80307d8: 18a4 adds r4, r4, r2 80307da: b2a4 uxth r4, r4 80307dc: e000 b.n 80307e0 } else { /* next octet in same pbuf */ msg_ptr++; 80307de: 3501 adds r5, #1 msg_ptr += ofs - base; if (octets_needed == 5) { /* not enough bits in 'value' add leading 0x00 */ octets_needed--; 80307e0: 2204 movs r2, #4 * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode * * @see snmp_asn1_enc_u32t_cnt() */ err_t snmp_asn1_enc_u32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, u32_t value) 80307e2: 1851 adds r1, r2, r1 80307e4: e012 b.n 803080c msg_ptr++; } } while (octets_needed > 1) { octets_needed--; 80307e6: 3a01 subs r2, #1 80307e8: b292 uxth r2, r2 *msg_ptr = (u8_t)(value >> (octets_needed << 3)); 80307ea: 00d6 lsls r6, r2, #3 80307ec: fa23 f606 lsr.w r6, r3, r6 80307f0: 702e strb r6, [r5, #0] * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode * * @see snmp_asn1_enc_u32t_cnt() */ err_t snmp_asn1_enc_u32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, u32_t value) 80307f2: 1a8e subs r6, r1, r2 while (octets_needed > 1) { octets_needed--; *msg_ptr = (u8_t)(value >> (octets_needed << 3)); ofs += 1; if (ofs >= plen) 80307f4: b2b6 uxth r6, r6 80307f6: 42a6 cmp r6, r4 80307f8: d307 bcc.n 803080a { /* next octet in next pbuf */ p = p->next; 80307fa: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 80307fc: 2800 cmp r0, #0 80307fe: d0e7 beq.n 80307d0 msg_ptr = (u8_t*)p->payload; plen += p->len; 8030800: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030802: 6845 ldr r5, [r0, #4] plen += p->len; 8030804: 19a4 adds r4, r4, r6 8030806: b2a4 uxth r4, r4 8030808: e000 b.n 803080c } else { /* next octet in same pbuf */ msg_ptr++; 803080a: 3501 adds r5, #1 { /* next octet in same pbuf */ msg_ptr++; } } while (octets_needed > 1) 803080c: 2a01 cmp r2, #1 803080e: d8ea bhi.n 80307e6 /* next octet in same pbuf */ msg_ptr++; } } /* (only) one least significant octet */ *msg_ptr = (u8_t)value; 8030810: 702b strb r3, [r5, #0] return ERR_OK; 8030812: 2000 movs r0, #0 8030814: e004 b.n 8030820 } p = p->next; 8030816: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030818: 4625 mov r5, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 803081a: 2800 cmp r0, #0 803081c: d1c5 bne.n 80307aa 803081e: e7d7 b.n 80307d0 } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 8030820: b240 sxtb r0, r0 8030822: bdf0 pop {r4, r5, r6, r7, pc} 08030824 : * * @see snmp_asn1_enc_s32t_cnt() */ err_t snmp_asn1_enc_s32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, s32_t value) { 8030824: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030826: 2600 movs r6, #0 while (p != NULL) 8030828: e024 b.n 8030874 { base = plen; plen += p->len; 803082a: 8944 ldrh r4, [r0, #10] 803082c: 1934 adds r4, r6, r4 803082e: b2a4 uxth r4, r4 if (ofs < plen) 8030830: 42a1 cmp r1, r4 8030832: d21d bcs.n 8030870 { msg_ptr = (u8_t*)p->payload; 8030834: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; 8030836: 1b8d subs r5, r1, r6 8030838: 197d adds r5, r7, r5 * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode * * @see snmp_asn1_enc_s32t_cnt() */ err_t snmp_asn1_enc_s32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, s32_t value) 803083a: 1851 adds r1, r2, r1 if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; while (octets_needed > 1) 803083c: e013 b.n 8030866 { octets_needed--; 803083e: 3a01 subs r2, #1 8030840: b292 uxth r2, r2 *msg_ptr = (u8_t)(value >> (octets_needed << 3)); 8030842: 00d6 lsls r6, r2, #3 8030844: fa43 f606 asr.w r6, r3, r6 8030848: 702e strb r6, [r5, #0] * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode * * @see snmp_asn1_enc_s32t_cnt() */ err_t snmp_asn1_enc_s32t(struct pbuf *p, u16_t ofs, u16_t octets_needed, s32_t value) 803084a: 1a8e subs r6, r1, r2 while (octets_needed > 1) { octets_needed--; *msg_ptr = (u8_t)(value >> (octets_needed << 3)); ofs += 1; if (ofs >= plen) 803084c: b2b6 uxth r6, r6 803084e: 42a6 cmp r6, r4 8030850: d308 bcc.n 8030864 { /* next octet in next pbuf */ p = p->next; 8030852: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030854: b908 cbnz r0, 803085a 8030856: 20f2 movs r0, #242 ; 0xf2 8030858: e00f b.n 803087a msg_ptr = (u8_t*)p->payload; plen += p->len; 803085a: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 803085c: 6845 ldr r5, [r0, #4] plen += p->len; 803085e: 19a4 adds r4, r4, r6 8030860: b2a4 uxth r4, r4 8030862: e000 b.n 8030866 } else { /* next octet in same pbuf */ msg_ptr++; 8030864: 3501 adds r5, #1 if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; while (octets_needed > 1) 8030866: 2a01 cmp r2, #1 8030868: d8e9 bhi.n 803083e /* next octet in same pbuf */ msg_ptr++; } } /* (only) one least significant octet */ *msg_ptr = (u8_t)value; 803086a: 702b strb r3, [r5, #0] return ERR_OK; 803086c: 2000 movs r0, #0 803086e: e004 b.n 803087a } p = p->next; 8030870: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030872: 4626 mov r6, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 8030874: 2800 cmp r0, #0 8030876: d1d8 bne.n 803082a 8030878: e7ed b.n 8030856 } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 803087a: b240 sxtb r0, r0 803087c: bdf0 pop {r4, r5, r6, r7, pc} 0803087e : * @param ident points to object identifier array * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_oid(struct pbuf *p, u16_t ofs, u8_t ident_len, s32_t *ident) { 803087e: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030882: 2500 movs r5, #0 while (p != NULL) 8030884: e068 b.n 8030958 { base = plen; plen += p->len; 8030886: 8944 ldrh r4, [r0, #10] 8030888: 192c adds r4, r5, r4 803088a: b2a4 uxth r4, r4 if (ofs < plen) 803088c: 42a1 cmp r1, r4 803088e: d261 bcs.n 8030954 { msg_ptr = (u8_t*)p->payload; 8030890: 6846 ldr r6, [r0, #4] msg_ptr += ofs - base; 8030892: 1b4d subs r5, r1, r5 if (ident_len > 1) 8030894: 2a01 cmp r2, #1 base = plen; plen += p->len; if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; 8030896: eb06 0805 add.w r8, r6, r5 if (ident_len > 1) 803089a: d801 bhi.n 80308a0 } else { /* @bug: allow empty varbinds for symmetry (we must decode them for getnext), allow partial compression?? */ /* ident_len <= 1, at least we need zeroDotZero (0.0) (ident_len == 2) */ return ERR_ARG; 803089c: 20f2 movs r0, #242 ; 0xf2 803089e: e05e b.n 803095e msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; if (ident_len > 1) { if ((ident[0] == 1) && (ident[1] == 3)) 80308a0: f8d3 c000 ldr.w ip, [r3] 80308a4: f1bc 0f01 cmp.w ip, #1 80308a8: d105 bne.n 80308b6 80308aa: 685f ldr r7, [r3, #4] 80308ac: 2f03 cmp r7, #3 80308ae: d102 bne.n 80308b6 { /* compressed (most common) prefix .iso.org */ *msg_ptr = 0x2b; 80308b0: 272b movs r7, #43 ; 0x2b 80308b2: 5577 strb r7, [r6, r5] 80308b4: e006 b.n 80308c4 } else { /* calculate prefix */ *msg_ptr = (u8_t)((ident[0] * 40) + ident[1]); 80308b6: 685f ldr r7, [r3, #4] 80308b8: f04f 0928 mov.w r9, #40 ; 0x28 80308bc: fb09 7c0c mla ip, r9, ip, r7 80308c0: f806 c005 strb.w ip, [r6, r5] } ofs += 1; 80308c4: 3101 adds r1, #1 80308c6: b289 uxth r1, r1 if (ofs >= plen) 80308c8: 42a1 cmp r1, r4 80308ca: d307 bcc.n 80308dc { /* next octet in next pbuf */ p = p->next; 80308cc: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 80308ce: 2800 cmp r0, #0 80308d0: d0e4 beq.n 803089c msg_ptr = (u8_t*)p->payload; plen += p->len; 80308d2: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 80308d4: 6845 ldr r5, [r0, #4] plen += p->len; 80308d6: 19a4 adds r4, r4, r6 80308d8: b2a4 uxth r4, r4 80308da: e001 b.n 80308e0 } else { /* next octet in same pbuf */ msg_ptr++; 80308dc: f108 0501 add.w r5, r8, #1 } ident_len -= 2; 80308e0: 3a02 subs r2, #2 80308e2: b2d2 uxtb r2, r2 * @param ident_len object identifier array length * @param ident points to object identifier array * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_oid(struct pbuf *p, u16_t ofs, u8_t ident_len, s32_t *ident) 80308e4: 3304 adds r3, #4 { /* @bug: allow empty varbinds for symmetry (we must decode them for getnext), allow partial compression?? */ /* ident_len <= 1, at least we need zeroDotZero (0.0) (ident_len == 2) */ return ERR_ARG; } while (ident_len > 0) 80308e6: e031 b.n 803094c { s32_t sub_id; u8_t shift, tail; ident_len--; 80308e8: 3a01 subs r2, #1 sub_id = *ident; 80308ea: f853 cf04 ldr.w ip, [r3, #4]! while (ident_len > 0) { s32_t sub_id; u8_t shift, tail; ident_len--; 80308ee: b2d2 uxtb r2, r2 sub_id = *ident; 80308f0: 261c movs r6, #28 tail = 0; 80308f2: 2700 movs r7, #0 shift = 28; while(shift > 0) { u8_t code; code = (u8_t)(sub_id >> shift); 80308f4: fa4c f806 asr.w r8, ip, r6 if ((code != 0) || (tail != 0)) 80308f8: f018 0fff tst.w r8, #255 ; 0xff 80308fc: d100 bne.n 8030900 80308fe: b18f cbz r7, 8030924 { tail = 1; *msg_ptr = code | 0x80; ofs += 1; 8030900: 3101 adds r1, #1 8030902: b289 uxth r1, r1 code = (u8_t)(sub_id >> shift); if ((code != 0) || (tail != 0)) { tail = 1; *msg_ptr = code | 0x80; 8030904: f048 0880 orr.w r8, r8, #128 ; 0x80 ofs += 1; if (ofs >= plen) 8030908: 42a1 cmp r1, r4 code = (u8_t)(sub_id >> shift); if ((code != 0) || (tail != 0)) { tail = 1; *msg_ptr = code | 0x80; 803090a: f885 8000 strb.w r8, [r5] ofs += 1; if (ofs >= plen) 803090e: d307 bcc.n 8030920 { /* next octet in next pbuf */ p = p->next; 8030910: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030912: 2800 cmp r0, #0 8030914: d0c2 beq.n 803089c msg_ptr = (u8_t*)p->payload; plen += p->len; 8030916: 8947 ldrh r7, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030918: 6845 ldr r5, [r0, #4] plen += p->len; 803091a: 19e4 adds r4, r4, r7 803091c: b2a4 uxth r4, r4 803091e: e000 b.n 8030922 } else { /* next octet in same pbuf */ msg_ptr++; 8030920: 3501 adds r5, #1 u8_t code; code = (u8_t)(sub_id >> shift); if ((code != 0) || (tail != 0)) { tail = 1; 8030922: 2701 movs r7, #1 ident_len--; sub_id = *ident; tail = 0; shift = 28; while(shift > 0) 8030924: 3e07 subs r6, #7 8030926: d1e5 bne.n 80308f4 msg_ptr++; } } shift -= 7; } *msg_ptr = (u8_t)sub_id & 0x7F; 8030928: f00c 0c7f and.w ip, ip, #127 ; 0x7f 803092c: f885 c000 strb.w ip, [r5] if (ident_len > 0) 8030930: b172 cbz r2, 8030950 { ofs += 1; 8030932: 3101 adds r1, #1 8030934: b289 uxth r1, r1 if (ofs >= plen) 8030936: 42a1 cmp r1, r4 8030938: d307 bcc.n 803094a { /* next octet in next pbuf */ p = p->next; 803093a: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 803093c: 2800 cmp r0, #0 803093e: d0ad beq.n 803089c msg_ptr = (u8_t*)p->payload; plen += p->len; 8030940: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 8030942: 6845 ldr r5, [r0, #4] plen += p->len; 8030944: 19a4 adds r4, r4, r6 8030946: b2a4 uxth r4, r4 8030948: e000 b.n 803094c } else { /* next octet in same pbuf */ msg_ptr++; 803094a: 3501 adds r5, #1 { /* @bug: allow empty varbinds for symmetry (we must decode them for getnext), allow partial compression?? */ /* ident_len <= 1, at least we need zeroDotZero (0.0) (ident_len == 2) */ return ERR_ARG; } while (ident_len > 0) 803094c: 2a00 cmp r2, #0 803094e: d1cb bne.n 80308e8 } } /* proceed to next sub-identifier */ ident++; } return ERR_OK; 8030950: 2000 movs r0, #0 8030952: e004 b.n 803095e } p = p->next; 8030954: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 8030956: 4625 mov r5, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 8030958: 2800 cmp r0, #0 803095a: d194 bne.n 8030886 803095c: e79e b.n 803089c } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 803095e: b240 sxtb r0, r0 8030960: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 08030964 : * @param raw points raw data * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_raw(struct pbuf *p, u16_t ofs, u16_t raw_len, u8_t *raw) { 8030964: b5f0 push {r4, r5, r6, r7, lr} u16_t plen, base; u8_t *msg_ptr; plen = 0; 8030966: 2600 movs r6, #0 while (p != NULL) 8030968: e025 b.n 80309b6 { base = plen; plen += p->len; 803096a: 8944 ldrh r4, [r0, #10] 803096c: 1934 adds r4, r6, r4 803096e: b2a4 uxth r4, r4 if (ofs < plen) 8030970: 42a1 cmp r1, r4 8030972: d21e bcs.n 80309b2 { msg_ptr = (u8_t*)p->payload; 8030974: 6847 ldr r7, [r0, #4] msg_ptr += ofs - base; 8030976: 1b8d subs r5, r1, r6 8030978: 197d adds r5, r7, r5 * @param raw_len raw data length * @param raw points raw data * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_raw(struct pbuf *p, u16_t ofs, u16_t raw_len, u8_t *raw) 803097a: 1851 adds r1, r2, r1 if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; while (raw_len > 1) 803097c: e012 b.n 80309a4 { /* copy raw_len - 1 octets */ raw_len--; 803097e: 3a01 subs r2, #1 *msg_ptr = *raw; 8030980: f813 6b01 ldrb.w r6, [r3], #1 msg_ptr += ofs - base; while (raw_len > 1) { /* copy raw_len - 1 octets */ raw_len--; 8030984: b292 uxth r2, r2 *msg_ptr = *raw; 8030986: 702e strb r6, [r5, #0] * @param raw_len raw data length * @param raw points raw data * @return ERR_OK if successfull, ERR_ARG if we can't (or won't) encode */ err_t snmp_asn1_enc_raw(struct pbuf *p, u16_t ofs, u16_t raw_len, u8_t *raw) 8030988: 1a8e subs r6, r1, r2 /* copy raw_len - 1 octets */ raw_len--; *msg_ptr = *raw; raw++; ofs += 1; if (ofs >= plen) 803098a: b2b6 uxth r6, r6 803098c: 42a6 cmp r6, r4 803098e: d308 bcc.n 80309a2 { /* next octet in next pbuf */ p = p->next; 8030990: 6800 ldr r0, [r0, #0] if (p == NULL) { return ERR_ARG; } 8030992: b908 cbnz r0, 8030998 8030994: 20f2 movs r0, #242 ; 0xf2 8030996: e012 b.n 80309be msg_ptr = (u8_t*)p->payload; plen += p->len; 8030998: 8946 ldrh r6, [r0, #10] if (ofs >= plen) { /* next octet in next pbuf */ p = p->next; if (p == NULL) { return ERR_ARG; } msg_ptr = (u8_t*)p->payload; 803099a: 6845 ldr r5, [r0, #4] plen += p->len; 803099c: 19a4 adds r4, r4, r6 803099e: b2a4 uxth r4, r4 80309a0: e000 b.n 80309a4 } else { /* next octet in same pbuf */ msg_ptr++; 80309a2: 3501 adds r5, #1 if (ofs < plen) { msg_ptr = (u8_t*)p->payload; msg_ptr += ofs - base; while (raw_len > 1) 80309a4: 2a01 cmp r2, #1 80309a6: d8ea bhi.n 803097e { /* next octet in same pbuf */ msg_ptr++; } } if (raw_len > 0) 80309a8: b142 cbz r2, 80309bc { /* copy last or single octet */ *msg_ptr = *raw; 80309aa: 781b ldrb r3, [r3, #0] } return ERR_OK; 80309ac: 2000 movs r0, #0 } } if (raw_len > 0) { /* copy last or single octet */ *msg_ptr = *raw; 80309ae: 702b strb r3, [r5, #0] 80309b0: e005 b.n 80309be } return ERR_OK; } p = p->next; 80309b2: 6800 ldr r0, [r0, #0] plen = 0; while (p != NULL) { base = plen; plen += p->len; 80309b4: 4626 mov r6, r4 { u16_t plen, base; u8_t *msg_ptr; plen = 0; while (p != NULL) 80309b6: 2800 cmp r0, #0 80309b8: d1d7 bne.n 803096a 80309ba: e7eb b.n 8030994 if (raw_len > 0) { /* copy last or single octet */ *msg_ptr = *raw; } return ERR_OK; 80309bc: 4610 mov r0, r2 } p = p->next; } /* p == NULL, ofs >= plen */ return ERR_ARG; } 80309be: b240 sxtb r0, r0 80309c0: bdf0 pop {r4, r5, r6, r7, pc} 080309c2 : void noleafs_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { LWIP_UNUSED_ARG(ident_len); LWIP_UNUSED_ARG(ident); od->instance = MIB_OBJECT_NONE; 80309c2: 2300 movs r3, #0 80309c4: 7013 strb r3, [r2, #0] 80309c6: 4770 bx lr 080309c8 : } void noleafs_get_value(struct obj_def *od, u16_t len, void *value) { 80309c8: 4770 bx lr 080309ca : LWIP_UNUSED_ARG(od); LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value); /* can't set */ return 0; } 80309ca: 2000 movs r0, #0 80309cc: 4770 bx lr 080309ce : void noleafs_set_value(struct obj_def *od, u16_t len, void *value) { 80309ce: 4770 bx lr 080309d0 : u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 80309d0: 2801 cmp r0, #1 80309d2: d145 bne.n 8030a60 { od->id_inst_len = ident_len; 80309d4: 2002 movs r0, #2 { u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 80309d6: 1f0b subs r3, r1, #4 if (ident_len == 2) { od->id_inst_len = ident_len; 80309d8: 7190 strb r0, [r2, #6] od->id_inst_ptr = ident; 80309da: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; LWIP_DEBUGF(SNMP_MIB_DEBUG,("get_object_def system.%"U16_F".0\n",(u16_t)id)); switch (id) 80309dc: f811 3c04 ldrb.w r3, [r1, #-4] 80309e0: 3b01 subs r3, #1 80309e2: 2b06 cmp r3, #6 80309e4: d83c bhi.n 8030a60 80309e6: e8df f003 tbb [pc, r3] 80309ea: 0b04 .short 0x0b04 80309ec: 2a221a14 .word 0x2a221a14 80309f0: 34 .byte 0x34 80309f1: 00 .byte 0x00 { case 1: /* sysDescr */ od->instance = MIB_OBJECT_SCALAR; 80309f2: 2301 movs r3, #1 80309f4: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 80309f6: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 80309f8: 2304 movs r3, #4 80309fa: 7093 strb r3, [r2, #2] od->v_len = *sysdescr_len_ptr; 80309fc: 4b1a ldr r3, [pc, #104] ; (8030a68 ) 80309fe: e025 b.n 8030a4c break; case 2: /* sysObjectID */ od->instance = MIB_OBJECT_SCALAR; 8030a00: 2301 movs r3, #1 8030a02: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030a04: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID); 8030a06: 2306 movs r3, #6 8030a08: 7093 strb r3, [r2, #2] od->v_len = sysobjid.len * sizeof(s32_t); 8030a0a: 4b18 ldr r3, [pc, #96] ; (8030a6c ) 8030a0c: 781b ldrb r3, [r3, #0] 8030a0e: 009b lsls r3, r3, #2 8030a10: e024 b.n 8030a5c break; case 3: /* sysUpTime */ od->instance = MIB_OBJECT_SCALAR; 8030a12: 2301 movs r3, #1 8030a14: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030a16: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS); 8030a18: 2343 movs r3, #67 ; 0x43 8030a1a: 7093 strb r3, [r2, #2] 8030a1c: e01d b.n 8030a5a od->v_len = sizeof(u32_t); break; case 4: /* sysContact */ od->instance = MIB_OBJECT_SCALAR; 8030a1e: 2301 movs r3, #1 8030a20: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 8030a22: 2303 movs r3, #3 8030a24: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030a26: 2304 movs r3, #4 8030a28: 7093 strb r3, [r2, #2] od->v_len = *syscontact_len_ptr; 8030a2a: 4b11 ldr r3, [pc, #68] ; (8030a70 ) 8030a2c: e00e b.n 8030a4c break; case 5: /* sysName */ od->instance = MIB_OBJECT_SCALAR; 8030a2e: 2301 movs r3, #1 8030a30: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 8030a32: 2303 movs r3, #3 8030a34: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030a36: 2304 movs r3, #4 8030a38: 7093 strb r3, [r2, #2] od->v_len = *sysname_len_ptr; 8030a3a: 4b0e ldr r3, [pc, #56] ; (8030a74 ) 8030a3c: e006 b.n 8030a4c break; case 6: /* sysLocation */ od->instance = MIB_OBJECT_SCALAR; 8030a3e: 2301 movs r3, #1 8030a40: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 8030a42: 2303 movs r3, #3 8030a44: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030a46: 2304 movs r3, #4 8030a48: 7093 strb r3, [r2, #2] od->v_len = *syslocation_len_ptr; 8030a4a: 4b0b ldr r3, [pc, #44] ; (8030a78 ) 8030a4c: 681b ldr r3, [r3, #0] 8030a4e: 781b ldrb r3, [r3, #0] 8030a50: e004 b.n 8030a5c break; case 7: /* sysServices */ od->instance = MIB_OBJECT_SCALAR; 8030a52: 2301 movs r3, #1 8030a54: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030a56: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8030a58: 7090 strb r0, [r2, #2] od->v_len = sizeof(s32_t); 8030a5a: 2304 movs r3, #4 8030a5c: 8093 strh r3, [r2, #4] break; 8030a5e: 4770 bx lr }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("system_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030a60: 2300 movs r3, #0 8030a62: 7013 strb r3, [r2, #0] 8030a64: 4770 bx lr 8030a66: bf00 nop 8030a68: 2000180c .word 0x2000180c 8030a6c: 200016bc .word 0x200016bc 8030a70: 20001668 .word 0x20001668 8030a74: 20001664 .word 0x20001664 8030a78: 20001850 .word 0x20001850 08030a7c : interfaces_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8030a7c: 2801 cmp r0, #1 8030a7e: d109 bne.n 8030a94 { od->id_inst_len = ident_len; 8030a80: 2302 movs r3, #2 8030a82: 7193 strb r3, [r2, #6] static void interfaces_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8030a84: 3904 subs r1, #4 od->id_inst_len = ident_len; od->id_inst_ptr = ident; od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8030a86: 7093 strb r3, [r2, #2] od->v_len = sizeof(s32_t); 8030a88: 2304 movs r3, #4 ident_len += 1; ident -= 1; if (ident_len == 2) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8030a8a: 6091 str r1, [r2, #8] od->instance = MIB_OBJECT_SCALAR; 8030a8c: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030a8e: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); 8030a90: 8093 strh r3, [r2, #4] 8030a92: 4770 bx lr } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("interfaces_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030a94: 2300 movs r3, #0 8030a96: 7013 strb r3, [r2, #0] 8030a98: 4770 bx lr 8030a9a: 0000 movs r0, r0 08030a9c : */ static void interfaces_get_value(struct obj_def *od, u16_t len, void *value) { LWIP_UNUSED_ARG(len); if (od->id_inst_ptr[0] == 1) 8030a9c: 6883 ldr r3, [r0, #8] 8030a9e: 681b ldr r3, [r3, #0] 8030aa0: 2b01 cmp r3, #1 8030aa2: d102 bne.n 8030aaa { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = iflist_root.count; 8030aa4: 4b01 ldr r3, [pc, #4] ; (8030aac ) 8030aa6: 8b9b ldrh r3, [r3, #28] 8030aa8: 6013 str r3, [r2, #0] 8030aaa: 4770 bx lr 8030aac: 2000169c .word 0x2000169c 08030ab0 : { u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030ab0: 6883 ldr r3, [r0, #8] switch (id) 8030ab2: 781b ldrb r3, [r3, #0] 8030ab4: 3b01 subs r3, #1 8030ab6: 2b16 cmp r3, #22 8030ab8: d836 bhi.n 8030b28 8030aba: e8df f003 tbb [pc, r3] 8030abe: 0e0c .short 0x0e0c 8030ac0: 16141210 .word 0x16141210 8030ac4: 1e1c1a18 .word 0x1e1c1a18 8030ac8: 26242220 .word 0x26242220 8030acc: 2e2c2a28 .word 0x2e2c2a28 8030ad0: 35353530 .word 0x35353530 8030ad4: 32 .byte 0x32 8030ad5: 00 .byte 0x00 #if IP_FORWARD /* forwarding */ *sint_ptr = 1; #else /* not-forwarding */ *sint_ptr = 2; 8030ad6: 2302 movs r3, #2 8030ad8: e025 b.n 8030b26 } break; case 2: /* ipDefaultTTL */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = IP_DEFAULT_TTL; 8030ada: 23ff movs r3, #255 ; 0xff 8030adc: e023 b.n 8030b26 } break; case 3: /* ipInReceives */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipinreceives; 8030ade: 4b13 ldr r3, [pc, #76] ; (8030b2c ) 8030ae0: e020 b.n 8030b24 } break; case 4: /* ipInHdrErrors */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipinhdrerrors; 8030ae2: 4b13 ldr r3, [pc, #76] ; (8030b30 ) 8030ae4: e01e b.n 8030b24 } break; case 5: /* ipInAddrErrors */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipinaddrerrors; 8030ae6: 4b13 ldr r3, [pc, #76] ; (8030b34 ) 8030ae8: e01c b.n 8030b24 } break; case 6: /* ipForwDatagrams */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipforwdatagrams; 8030aea: 4b13 ldr r3, [pc, #76] ; (8030b38 ) 8030aec: e01a b.n 8030b24 } break; case 7: /* ipInUnknownProtos */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipinunknownprotos; 8030aee: 4b13 ldr r3, [pc, #76] ; (8030b3c ) 8030af0: e018 b.n 8030b24 } break; case 8: /* ipInDiscards */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipindiscards; 8030af2: 4b13 ldr r3, [pc, #76] ; (8030b40 ) 8030af4: e016 b.n 8030b24 } break; case 9: /* ipInDelivers */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipindelivers; 8030af6: 4b13 ldr r3, [pc, #76] ; (8030b44 ) 8030af8: e014 b.n 8030b24 } break; case 10: /* ipOutRequests */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipoutrequests; 8030afa: 4b13 ldr r3, [pc, #76] ; (8030b48 ) 8030afc: e012 b.n 8030b24 } break; case 11: /* ipOutDiscards */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipoutdiscards; 8030afe: 4b13 ldr r3, [pc, #76] ; (8030b4c ) 8030b00: e010 b.n 8030b24 } break; case 12: /* ipOutNoRoutes */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipoutnoroutes; 8030b02: 4b13 ldr r3, [pc, #76] ; (8030b50 ) 8030b04: e00e b.n 8030b24 { s32_t *sint_ptr = (s32_t*)value; #if IP_REASSEMBLY *sint_ptr = IP_REASS_MAXAGE; #else *sint_ptr = 0; 8030b06: 2300 movs r3, #0 8030b08: e00d b.n 8030b26 } break; case 14: /* ipReasmReqds */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipreasmreqds; 8030b0a: 4b12 ldr r3, [pc, #72] ; (8030b54 ) 8030b0c: e00a b.n 8030b24 } break; case 15: /* ipReasmOKs */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipreasmoks; 8030b0e: 4b12 ldr r3, [pc, #72] ; (8030b58 ) 8030b10: e008 b.n 8030b24 } break; case 16: /* ipReasmFails */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipreasmfails; 8030b12: 4b12 ldr r3, [pc, #72] ; (8030b5c ) 8030b14: e006 b.n 8030b24 } break; case 17: /* ipFragOKs */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipfragoks; 8030b16: 4b12 ldr r3, [pc, #72] ; (8030b60 ) 8030b18: e004 b.n 8030b24 } break; case 18: /* ipFragFails */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipfragfails; 8030b1a: 4b12 ldr r3, [pc, #72] ; (8030b64 ) 8030b1c: e002 b.n 8030b24 } break; case 19: /* ipFragCreates */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = ipfragcreates; 8030b1e: 4b12 ldr r3, [pc, #72] ; (8030b68 ) 8030b20: e000 b.n 8030b24 break; case 23: /* ipRoutingDiscards */ /** @todo can lwIP discard routes at all?? hardwire this to 0?? */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = iproutingdiscards; 8030b22: 4b12 ldr r3, [pc, #72] ; (8030b6c ) 8030b24: 681b ldr r3, [r3, #0] 8030b26: 6013 str r3, [r2, #0] 8030b28: 4770 bx lr 8030b2a: bf00 nop 8030b2c: 2000e1e4 .word 0x2000e1e4 8030b30: 2000e16c .word 0x2000e16c 8030b34: 2000e150 .word 0x2000e150 8030b38: 2000e26c .word 0x2000e26c 8030b3c: 2000e1ac .word 0x2000e1ac 8030b40: 2000e238 .word 0x2000e238 8030b44: 2000e270 .word 0x2000e270 8030b48: 2000e258 .word 0x2000e258 8030b4c: 2000e1fc .word 0x2000e1fc 8030b50: 2000e27c .word 0x2000e27c 8030b54: 2000e1cc .word 0x2000e1cc 8030b58: 2000e178 .word 0x2000e178 8030b5c: 2000e22c .word 0x2000e22c 8030b60: 2000e13c .word 0x2000e13c 8030b64: 2000e1a8 .word 0x2000e1a8 8030b68: 2000e248 .word 0x2000e248 8030b6c: 2000e234 .word 0x2000e234 08030b70 : s32_t *sint_ptr = (s32_t*)value; LWIP_UNUSED_ARG(len); set_ok = 0; LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030b70: 6883 ldr r3, [r0, #8] switch (id) 8030b72: 781b ldrb r3, [r3, #0] 8030b74: 2b01 cmp r3, #1 8030b76: d002 beq.n 8030b7e 8030b78: 2b02 cmp r3, #2 8030b7a: d109 bne.n 8030b90 8030b7c: e002 b.n 8030b84 #if IP_FORWARD /* forwarding */ if (*sint_ptr == 1) #else /* not-forwarding */ if (*sint_ptr == 2) 8030b7e: 6810 ldr r0, [r2, #0] { u8_t id, set_ok; s32_t *sint_ptr = (s32_t*)value; LWIP_UNUSED_ARG(len); set_ok = 0; 8030b80: 2802 cmp r0, #2 8030b82: e001 b.n 8030b88 { set_ok = 1; } break; case 2: /* ipDefaultTTL */ if (*sint_ptr == IP_DEFAULT_TTL) 8030b84: 6810 ldr r0, [r2, #0] { u8_t id, set_ok; s32_t *sint_ptr = (s32_t*)value; LWIP_UNUSED_ARG(len); set_ok = 0; 8030b86: 28ff cmp r0, #255 ; 0xff 8030b88: bf14 ite ne 8030b8a: 2000 movne r0, #0 8030b8c: 2001 moveq r0, #1 8030b8e: 4770 bx lr 8030b90: 2000 movs r0, #0 set_ok = 1; } break; }; return set_ok; } 8030b92: 4770 bx lr 08030b94 : /* return to object name, adding index depth (4) */ ident_len += 4; ident -= 4; if (ident_len == 5) 8030b94: 2801 cmp r0, #1 8030b96: d12c bne.n 8030bf2 { od->id_inst_len = ident_len; 8030b98: 2305 movs r3, #5 8030b9a: 7193 strb r3, [r2, #6] { u8_t id; /* return to object name, adding index depth (4) */ ident_len += 4; ident -= 4; 8030b9c: f1a1 0310 sub.w r3, r1, #16 if (ident_len == 5) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8030ba0: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 8030ba2: f811 3c10 ldrb.w r3, [r1, #-16] 8030ba6: 3b01 subs r3, #1 8030ba8: 2b0c cmp r3, #12 8030baa: d822 bhi.n 8030bf2 8030bac: e8df f003 tbb [pc, r3] 8030bb0: 0d0d0d07 .word 0x0d0d0d07 8030bb4: 0d070d0d .word 0x0d070d0d 8030bb8: 0d070d11 .word 0x0d070d11 8030bbc: 18 .byte 0x18 8030bbd: 00 .byte 0x00 { case 1: /* ipRouteDest */ case 7: /* ipRouteNextHop */ case 11: /* ipRouteMask */ od->instance = MIB_OBJECT_TAB; 8030bbe: 2302 movs r3, #2 8030bc0: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 8030bc2: 2303 movs r3, #3 8030bc4: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR); 8030bc6: 2340 movs r3, #64 ; 0x40 8030bc8: e007 b.n 8030bda case 5: /* ipRouteMetric3 */ case 6: /* ipRouteMetric4 */ case 8: /* ipRouteType */ case 10: /* ipRouteAge */ case 12: /* ipRouteMetric5 */ od->instance = MIB_OBJECT_TAB; 8030bca: 2302 movs r3, #2 8030bcc: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 8030bce: 2103 movs r1, #3 8030bd0: e002 b.n 8030bd8 od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 9: /* ipRouteProto */ od->instance = MIB_OBJECT_TAB; 8030bd2: 2302 movs r3, #2 8030bd4: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030bd6: 2101 movs r1, #1 8030bd8: 7051 strb r1, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8030bda: 7093 strb r3, [r2, #2] od->v_len = sizeof(s32_t); 8030bdc: 2304 movs r3, #4 8030bde: e006 b.n 8030bee break; case 13: /* ipRouteInfo */ /** @note returning zeroDotZero (0.0) no routing protocol specific MIB */ od->instance = MIB_OBJECT_TAB; 8030be0: 2302 movs r3, #2 8030be2: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030be4: 2301 movs r3, #1 8030be6: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID); 8030be8: 2306 movs r3, #6 8030bea: 7093 strb r3, [r2, #2] od->v_len = iprouteinfo.len * sizeof(s32_t); 8030bec: 2308 movs r3, #8 8030bee: 8093 strh r3, [r2, #4] break; 8030bf0: 4770 bx lr } } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ip_rteentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030bf2: 2300 movs r3, #0 8030bf4: 7013 strb r3, [r2, #0] 8030bf6: 4770 bx lr 08030bf8 : icmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if ((ident_len == 2) && 8030bf8: 2801 cmp r0, #1 8030bfa: d110 bne.n 8030c1e (ident[0] > 0) && (ident[0] < 27)) 8030bfc: f851 3c04 ldr.w r3, [r1, #-4] icmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if ((ident_len == 2) && 8030c00: 2b00 cmp r3, #0 8030c02: dd0c ble.n 8030c1e (ident[0] > 0) && (ident[0] < 27)) 8030c04: 2b1a cmp r3, #26 8030c06: dc0a bgt.n 8030c1e { od->id_inst_len = ident_len; 8030c08: 2302 movs r3, #2 8030c0a: 7193 strb r3, [r2, #6] od->id_inst_ptr = ident; od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8030c0c: 2341 movs r3, #65 ; 0x41 static void icmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8030c0e: 3904 subs r1, #4 od->id_inst_len = ident_len; od->id_inst_ptr = ident; od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8030c10: 7093 strb r3, [r2, #2] od->v_len = sizeof(u32_t); 8030c12: 2304 movs r3, #4 ident -= 1; if ((ident_len == 2) && (ident[0] > 0) && (ident[0] < 27)) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8030c14: 6091 str r1, [r2, #8] od->instance = MIB_OBJECT_SCALAR; 8030c16: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030c18: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); od->v_len = sizeof(u32_t); 8030c1a: 8093 strh r3, [r2, #4] 8030c1c: 4770 bx lr } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("icmp_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030c1e: 2300 movs r3, #0 8030c20: 7013 strb r3, [r2, #0] 8030c22: 4770 bx lr 08030c24 : u32_t *uint_ptr = (u32_t*)value; u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030c24: 6883 ldr r3, [r0, #8] switch (id) 8030c26: 781b ldrb r3, [r3, #0] 8030c28: 3b01 subs r3, #1 8030c2a: 2b19 cmp r3, #25 8030c2c: d843 bhi.n 8030cb6 8030c2e: e8df f003 tbb [pc, r3] 8030c32: 0f0d .short 0x0f0d 8030c34: 17151311 .word 0x17151311 8030c38: 1f1d1b19 .word 0x1f1d1b19 8030c3c: 27252321 .word 0x27252321 8030c40: 2f2d2b29 .word 0x2f2d2b29 8030c44: 37353331 .word 0x37353331 8030c48: 3f3d3b39 .word 0x3f3d3b39 { case 1: /* icmpInMsgs */ *uint_ptr = icmpinmsgs; 8030c4c: 4b1a ldr r3, [pc, #104] ; (8030cb8 ) 8030c4e: e030 b.n 8030cb2 break; case 2: /* icmpInErrors */ *uint_ptr = icmpinerrors; 8030c50: 4b1a ldr r3, [pc, #104] ; (8030cbc ) 8030c52: e02e b.n 8030cb2 break; case 3: /* icmpInDestUnreachs */ *uint_ptr = icmpindestunreachs; 8030c54: 4b1a ldr r3, [pc, #104] ; (8030cc0 ) 8030c56: e02c b.n 8030cb2 break; case 4: /* icmpInTimeExcds */ *uint_ptr = icmpintimeexcds; 8030c58: 4b1a ldr r3, [pc, #104] ; (8030cc4 ) 8030c5a: e02a b.n 8030cb2 break; case 5: /* icmpInParmProbs */ *uint_ptr = icmpinparmprobs; 8030c5c: 4b1a ldr r3, [pc, #104] ; (8030cc8 ) 8030c5e: e028 b.n 8030cb2 break; case 6: /* icmpInSrcQuenchs */ *uint_ptr = icmpinsrcquenchs; 8030c60: 4b1a ldr r3, [pc, #104] ; (8030ccc ) 8030c62: e026 b.n 8030cb2 break; case 7: /* icmpInRedirects */ *uint_ptr = icmpinredirects; 8030c64: 4b1a ldr r3, [pc, #104] ; (8030cd0 ) 8030c66: e024 b.n 8030cb2 break; case 8: /* icmpInEchos */ *uint_ptr = icmpinechos; 8030c68: 4b1a ldr r3, [pc, #104] ; (8030cd4 ) 8030c6a: e022 b.n 8030cb2 break; case 9: /* icmpInEchoReps */ *uint_ptr = icmpinechoreps; 8030c6c: 4b1a ldr r3, [pc, #104] ; (8030cd8 ) 8030c6e: e020 b.n 8030cb2 break; case 10: /* icmpInTimestamps */ *uint_ptr = icmpintimestamps; 8030c70: 4b1a ldr r3, [pc, #104] ; (8030cdc ) 8030c72: e01e b.n 8030cb2 break; case 11: /* icmpInTimestampReps */ *uint_ptr = icmpintimestampreps; 8030c74: 4b1a ldr r3, [pc, #104] ; (8030ce0 ) 8030c76: e01c b.n 8030cb2 break; case 12: /* icmpInAddrMasks */ *uint_ptr = icmpinaddrmasks; 8030c78: 4b1a ldr r3, [pc, #104] ; (8030ce4 ) 8030c7a: e01a b.n 8030cb2 break; case 13: /* icmpInAddrMaskReps */ *uint_ptr = icmpinaddrmaskreps; 8030c7c: 4b1a ldr r3, [pc, #104] ; (8030ce8 ) 8030c7e: e018 b.n 8030cb2 break; case 14: /* icmpOutMsgs */ *uint_ptr = icmpoutmsgs; 8030c80: 4b1a ldr r3, [pc, #104] ; (8030cec ) 8030c82: e016 b.n 8030cb2 break; case 15: /* icmpOutErrors */ *uint_ptr = icmpouterrors; 8030c84: 4b1a ldr r3, [pc, #104] ; (8030cf0 ) 8030c86: e014 b.n 8030cb2 break; case 16: /* icmpOutDestUnreachs */ *uint_ptr = icmpoutdestunreachs; 8030c88: 4b1a ldr r3, [pc, #104] ; (8030cf4 ) 8030c8a: e012 b.n 8030cb2 break; case 17: /* icmpOutTimeExcds */ *uint_ptr = icmpouttimeexcds; 8030c8c: 4b1a ldr r3, [pc, #104] ; (8030cf8 ) 8030c8e: e010 b.n 8030cb2 break; case 18: /* icmpOutParmProbs */ *uint_ptr = icmpoutparmprobs; 8030c90: 4b1a ldr r3, [pc, #104] ; (8030cfc ) 8030c92: e00e b.n 8030cb2 break; case 19: /* icmpOutSrcQuenchs */ *uint_ptr = icmpoutsrcquenchs; 8030c94: 4b1a ldr r3, [pc, #104] ; (8030d00 ) 8030c96: e00c b.n 8030cb2 break; case 20: /* icmpOutRedirects */ *uint_ptr = icmpoutredirects; 8030c98: 4b1a ldr r3, [pc, #104] ; (8030d04 ) 8030c9a: e00a b.n 8030cb2 break; case 21: /* icmpOutEchos */ *uint_ptr = icmpoutechos; 8030c9c: 4b1a ldr r3, [pc, #104] ; (8030d08 ) 8030c9e: e008 b.n 8030cb2 break; case 22: /* icmpOutEchoReps */ *uint_ptr = icmpoutechoreps; 8030ca0: 4b1a ldr r3, [pc, #104] ; (8030d0c ) 8030ca2: e006 b.n 8030cb2 break; case 23: /* icmpOutTimestamps */ *uint_ptr = icmpouttimestamps; 8030ca4: 4b1a ldr r3, [pc, #104] ; (8030d10 ) 8030ca6: e004 b.n 8030cb2 break; case 24: /* icmpOutTimestampReps */ *uint_ptr = icmpouttimestampreps; 8030ca8: 4b1a ldr r3, [pc, #104] ; (8030d14 ) 8030caa: e002 b.n 8030cb2 break; case 25: /* icmpOutAddrMasks */ *uint_ptr = icmpoutaddrmasks; 8030cac: 4b1a ldr r3, [pc, #104] ; (8030d18 ) 8030cae: e000 b.n 8030cb2 break; case 26: /* icmpOutAddrMaskReps */ *uint_ptr = icmpoutaddrmaskreps; 8030cb0: 4b1a ldr r3, [pc, #104] ; (8030d1c ) 8030cb2: 681b ldr r3, [r3, #0] 8030cb4: 6013 str r3, [r2, #0] 8030cb6: 4770 bx lr 8030cb8: 2000e174 .word 0x2000e174 8030cbc: 2000e170 .word 0x2000e170 8030cc0: 2000e14c .word 0x2000e14c 8030cc4: 2000e230 .word 0x2000e230 8030cc8: 2000e264 .word 0x2000e264 8030ccc: 2000e15c .word 0x2000e15c 8030cd0: 2000e188 .word 0x2000e188 8030cd4: 2000e228 .word 0x2000e228 8030cd8: 2000e1a0 .word 0x2000e1a0 8030cdc: 2000e190 .word 0x2000e190 8030ce0: 2000e1d0 .word 0x2000e1d0 8030ce4: 2000e268 .word 0x2000e268 8030ce8: 2000e204 .word 0x2000e204 8030cec: 2000e1f4 .word 0x2000e1f4 8030cf0: 2000e278 .word 0x2000e278 8030cf4: 2000e20c .word 0x2000e20c 8030cf8: 2000e1c0 .word 0x2000e1c0 8030cfc: 2000e184 .word 0x2000e184 8030d00: 2000e1d8 .word 0x2000e1d8 8030d04: 2000e194 .word 0x2000e194 8030d08: 2000e274 .word 0x2000e274 8030d0c: 2000e214 .word 0x2000e214 8030d10: 2000e1e0 .word 0x2000e1e0 8030d14: 2000e1c4 .word 0x2000e1c4 8030d18: 2000e18c .word 0x2000e18c 8030d1c: 2000e1ec .word 0x2000e1ec 08030d20 : s32_t *sint_ptr = (s32_t*)value; u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030d20: 6883 ldr r3, [r0, #8] switch (id) 8030d22: 781b ldrb r3, [r3, #0] 8030d24: 3b01 subs r3, #1 8030d26: 2b0e cmp r3, #14 8030d28: d836 bhi.n 8030d98 8030d2a: e8df f003 tbb [pc, r3] 8030d2e: 0a08 .short 0x0a08 8030d30: 1412100d .word 0x1412100d 8030d34: 2a1a1816 .word 0x2a1a1816 8030d38: 30352e2c .word 0x30352e2c 8030d3c: 32 .byte 0x32 8030d3d: 00 .byte 0x00 { case 1: /* tcpRtoAlgorithm, vanj(4) */ *sint_ptr = 4; 8030d3e: 2304 movs r3, #4 8030d40: e029 b.n 8030d96 break; case 2: /* tcpRtoMin */ /* @todo not the actual value, a guess, needs to be calculated */ *sint_ptr = 1000; 8030d42: f44f 737a mov.w r3, #1000 ; 0x3e8 8030d46: e026 b.n 8030d96 break; case 3: /* tcpRtoMax */ /* @todo not the actual value, a guess, needs to be calculated */ *sint_ptr = 60000; 8030d48: f64e 2360 movw r3, #60000 ; 0xea60 8030d4c: e023 b.n 8030d96 break; case 4: /* tcpMaxConn */ *sint_ptr = MEMP_NUM_TCP_PCB; 8030d4e: 230c movs r3, #12 8030d50: e021 b.n 8030d96 break; case 5: /* tcpActiveOpens */ *uint_ptr = tcpactiveopens; 8030d52: 4b12 ldr r3, [pc, #72] ; (8030d9c ) 8030d54: e01e b.n 8030d94 break; case 6: /* tcpPassiveOpens */ *uint_ptr = tcppassiveopens; 8030d56: 4b12 ldr r3, [pc, #72] ; (8030da0 ) 8030d58: e01c b.n 8030d94 break; case 7: /* tcpAttemptFails */ *uint_ptr = tcpattemptfails; 8030d5a: 4b12 ldr r3, [pc, #72] ; (8030da4 ) 8030d5c: e01a b.n 8030d94 break; case 8: /* tcpEstabResets */ *uint_ptr = tcpestabresets; 8030d5e: 4b12 ldr r3, [pc, #72] ; (8030da8 ) 8030d60: e018 b.n 8030d94 break; case 9: /* tcpCurrEstab */ { u16_t tcpcurrestab = 0; struct tcp_pcb *pcb = tcp_active_pcbs; 8030d62: 4b12 ldr r3, [pc, #72] ; (8030dac ) case 8: /* tcpEstabResets */ *uint_ptr = tcpestabresets; break; case 9: /* tcpCurrEstab */ { u16_t tcpcurrestab = 0; 8030d64: 2100 movs r1, #0 struct tcp_pcb *pcb = tcp_active_pcbs; 8030d66: 681b ldr r3, [r3, #0] while (pcb != NULL) 8030d68: e007 b.n 8030d7a { if ((pcb->state == ESTABLISHED) || 8030d6a: 7e18 ldrb r0, [r3, #24] 8030d6c: 2804 cmp r0, #4 8030d6e: d001 beq.n 8030d74 8030d70: 2807 cmp r0, #7 8030d72: d101 bne.n 8030d78 (pcb->state == CLOSE_WAIT)) { tcpcurrestab++; 8030d74: 3101 adds r1, #1 8030d76: b289 uxth r1, r1 } pcb = pcb->next; 8030d78: 68db ldr r3, [r3, #12] break; case 9: /* tcpCurrEstab */ { u16_t tcpcurrestab = 0; struct tcp_pcb *pcb = tcp_active_pcbs; while (pcb != NULL) 8030d7a: 2b00 cmp r3, #0 8030d7c: d1f5 bne.n 8030d6a { tcpcurrestab++; } pcb = pcb->next; } *uint_ptr = tcpcurrestab; 8030d7e: 6011 str r1, [r2, #0] } break; 8030d80: 4770 bx lr case 10: /* tcpInSegs */ *uint_ptr = tcpinsegs; 8030d82: 4b0b ldr r3, [pc, #44] ; (8030db0 ) 8030d84: e006 b.n 8030d94 break; case 11: /* tcpOutSegs */ *uint_ptr = tcpoutsegs; 8030d86: 4b0b ldr r3, [pc, #44] ; (8030db4 ) 8030d88: e004 b.n 8030d94 break; case 12: /* tcpRetransSegs */ *uint_ptr = tcpretranssegs; 8030d8a: 4b0b ldr r3, [pc, #44] ; (8030db8 ) 8030d8c: e002 b.n 8030d94 break; case 14: /* tcpInErrs */ *uint_ptr = tcpinerrs; 8030d8e: 4b0b ldr r3, [pc, #44] ; (8030dbc ) 8030d90: e000 b.n 8030d94 break; case 15: /* tcpOutRsts */ *uint_ptr = tcpoutrsts; 8030d92: 4b0b ldr r3, [pc, #44] ; (8030dc0 ) 8030d94: 681b ldr r3, [r3, #0] 8030d96: 6013 str r3, [r2, #0] 8030d98: 4770 bx lr 8030d9a: bf00 nop 8030d9c: 2000e168 .word 0x2000e168 8030da0: 2000e19c .word 0x2000e19c 8030da4: 2000e1e8 .word 0x2000e1e8 8030da8: 2000e17c .word 0x2000e17c 8030dac: 20010fdc .word 0x20010fdc 8030db0: 2000e1f8 .word 0x2000e1f8 8030db4: 2000e244 .word 0x2000e244 8030db8: 2000e218 .word 0x2000e218 8030dbc: 2000e1a4 .word 0x2000e1a4 8030dc0: 2000e208 .word 0x2000e208 08030dc4 : udp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if ((ident_len == 2) && 8030dc4: 2801 cmp r0, #1 8030dc6: d110 bne.n 8030dea (ident[0] > 0) && (ident[0] < 6)) 8030dc8: f851 3c04 ldr.w r3, [r1, #-4] udp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if ((ident_len == 2) && 8030dcc: 2b00 cmp r3, #0 8030dce: dd0c ble.n 8030dea (ident[0] > 0) && (ident[0] < 6)) 8030dd0: 2b05 cmp r3, #5 8030dd2: dc0a bgt.n 8030dea { od->id_inst_len = ident_len; 8030dd4: 2302 movs r3, #2 8030dd6: 7193 strb r3, [r2, #6] od->id_inst_ptr = ident; od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8030dd8: 2341 movs r3, #65 ; 0x41 static void udp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8030dda: 3904 subs r1, #4 od->id_inst_len = ident_len; od->id_inst_ptr = ident; od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8030ddc: 7093 strb r3, [r2, #2] od->v_len = sizeof(u32_t); 8030dde: 2304 movs r3, #4 ident -= 1; if ((ident_len == 2) && (ident[0] > 0) && (ident[0] < 6)) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8030de0: 6091 str r1, [r2, #8] od->instance = MIB_OBJECT_SCALAR; 8030de2: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8030de4: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); od->v_len = sizeof(u32_t); 8030de6: 8093 strh r3, [r2, #4] 8030de8: 4770 bx lr } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("udp_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030dea: 2300 movs r3, #0 8030dec: 7013 strb r3, [r2, #0] 8030dee: 4770 bx lr 08030df0 : u32_t *uint_ptr = (u32_t*)value; u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030df0: 6883 ldr r3, [r0, #8] switch (id) 8030df2: 781b ldrb r3, [r3, #0] 8030df4: 3b01 subs r3, #1 8030df6: 2b03 cmp r3, #3 8030df8: d80c bhi.n 8030e14 8030dfa: e8df f003 tbb [pc, r3] 8030dfe: 0402 .short 0x0402 8030e00: 0806 .short 0x0806 { case 1: /* udpInDatagrams */ *uint_ptr = udpindatagrams; 8030e02: 4b05 ldr r3, [pc, #20] ; (8030e18 ) 8030e04: e004 b.n 8030e10 break; case 2: /* udpNoPorts */ *uint_ptr = udpnoports; 8030e06: 4b05 ldr r3, [pc, #20] ; (8030e1c ) 8030e08: e002 b.n 8030e10 break; case 3: /* udpInErrors */ *uint_ptr = udpinerrors; 8030e0a: 4b05 ldr r3, [pc, #20] ; (8030e20 ) 8030e0c: e000 b.n 8030e10 break; case 4: /* udpOutDatagrams */ *uint_ptr = udpoutdatagrams; 8030e0e: 4b05 ldr r3, [pc, #20] ; (8030e24 ) 8030e10: 681b ldr r3, [r3, #0] 8030e12: 6013 str r3, [r2, #0] 8030e14: 4770 bx lr 8030e16: bf00 nop 8030e18: 2000e224 .word 0x2000e224 8030e1c: 2000e1dc .word 0x2000e1dc 8030e20: 2000e24c .word 0x2000e24c 8030e24: 2000e1d4 .word 0x2000e1d4 08030e28 : u32_t *uint_ptr = (u32_t*)value; u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030e28: 6883 ldr r3, [r0, #8] switch (id) 8030e2a: 781b ldrb r3, [r3, #0] 8030e2c: 3b01 subs r3, #1 8030e2e: 2b1d cmp r3, #29 8030e30: d84b bhi.n 8030eca 8030e32: e8df f003 tbb [pc, r3] 8030e36: 110f .short 0x110f 8030e38: 19171513 .word 0x19171513 8030e3c: 1f1d1b4a .word 0x1f1d1b4a 8030e40: 27252321 .word 0x27252321 8030e44: 2f2d2b29 .word 0x2f2d2b29 8030e48: 37353331 .word 0x37353331 8030e4c: 3d3b394a .word 0x3d3b394a 8030e50: 4643413f .word 0x4643413f { case 1: /* snmpInPkts */ *uint_ptr = snmpinpkts; 8030e54: 4b1d ldr r3, [pc, #116] ; (8030ecc ) 8030e56: e032 b.n 8030ebe break; case 2: /* snmpOutPkts */ *uint_ptr = snmpoutpkts; 8030e58: 4b1d ldr r3, [pc, #116] ; (8030ed0 ) 8030e5a: e030 b.n 8030ebe break; case 3: /* snmpInBadVersions */ *uint_ptr = snmpinbadversions; 8030e5c: 4b1d ldr r3, [pc, #116] ; (8030ed4 ) 8030e5e: e02e b.n 8030ebe break; case 4: /* snmpInBadCommunityNames */ *uint_ptr = snmpinbadcommunitynames; 8030e60: 4b1d ldr r3, [pc, #116] ; (8030ed8 ) 8030e62: e02c b.n 8030ebe break; case 5: /* snmpInBadCommunityUses */ *uint_ptr = snmpinbadcommunityuses; 8030e64: 4b1d ldr r3, [pc, #116] ; (8030edc ) 8030e66: e02a b.n 8030ebe break; case 6: /* snmpInASNParseErrs */ *uint_ptr = snmpinasnparseerrs; 8030e68: 4b1d ldr r3, [pc, #116] ; (8030ee0 ) 8030e6a: e028 b.n 8030ebe break; case 8: /* snmpInTooBigs */ *uint_ptr = snmpintoobigs; 8030e6c: 4b1d ldr r3, [pc, #116] ; (8030ee4 ) 8030e6e: e026 b.n 8030ebe break; case 9: /* snmpInNoSuchNames */ *uint_ptr = snmpinnosuchnames; 8030e70: 4b1d ldr r3, [pc, #116] ; (8030ee8 ) 8030e72: e024 b.n 8030ebe break; case 10: /* snmpInBadValues */ *uint_ptr = snmpinbadvalues; 8030e74: 4b1d ldr r3, [pc, #116] ; (8030eec ) 8030e76: e022 b.n 8030ebe break; case 11: /* snmpInReadOnlys */ *uint_ptr = snmpinreadonlys; 8030e78: 4b1d ldr r3, [pc, #116] ; (8030ef0 ) 8030e7a: e020 b.n 8030ebe break; case 12: /* snmpInGenErrs */ *uint_ptr = snmpingenerrs; 8030e7c: 4b1d ldr r3, [pc, #116] ; (8030ef4 ) 8030e7e: e01e b.n 8030ebe break; case 13: /* snmpInTotalReqVars */ *uint_ptr = snmpintotalreqvars; 8030e80: 4b1d ldr r3, [pc, #116] ; (8030ef8 ) 8030e82: e01c b.n 8030ebe break; case 14: /* snmpInTotalSetVars */ *uint_ptr = snmpintotalsetvars; 8030e84: 4b1d ldr r3, [pc, #116] ; (8030efc ) 8030e86: e01a b.n 8030ebe break; case 15: /* snmpInGetRequests */ *uint_ptr = snmpingetrequests; 8030e88: 4b1d ldr r3, [pc, #116] ; (8030f00 ) 8030e8a: e018 b.n 8030ebe break; case 16: /* snmpInGetNexts */ *uint_ptr = snmpingetnexts; 8030e8c: 4b1d ldr r3, [pc, #116] ; (8030f04 ) 8030e8e: e016 b.n 8030ebe break; case 17: /* snmpInSetRequests */ *uint_ptr = snmpinsetrequests; 8030e90: 4b1d ldr r3, [pc, #116] ; (8030f08 ) 8030e92: e014 b.n 8030ebe break; case 18: /* snmpInGetResponses */ *uint_ptr = snmpingetresponses; 8030e94: 4b1d ldr r3, [pc, #116] ; (8030f0c ) 8030e96: e012 b.n 8030ebe break; case 19: /* snmpInTraps */ *uint_ptr = snmpintraps; 8030e98: 4b1d ldr r3, [pc, #116] ; (8030f10 ) 8030e9a: e010 b.n 8030ebe break; case 20: /* snmpOutTooBigs */ *uint_ptr = snmpouttoobigs; 8030e9c: 4b1d ldr r3, [pc, #116] ; (8030f14 ) 8030e9e: e00e b.n 8030ebe break; case 21: /* snmpOutNoSuchNames */ *uint_ptr = snmpoutnosuchnames; 8030ea0: 4b1d ldr r3, [pc, #116] ; (8030f18 ) 8030ea2: e00c b.n 8030ebe break; case 22: /* snmpOutBadValues */ *uint_ptr = snmpoutbadvalues; 8030ea4: 4b1d ldr r3, [pc, #116] ; (8030f1c ) 8030ea6: e00a b.n 8030ebe break; case 24: /* snmpOutGenErrs */ *uint_ptr = snmpoutgenerrs; 8030ea8: 4b1d ldr r3, [pc, #116] ; (8030f20 ) 8030eaa: e008 b.n 8030ebe break; case 25: /* snmpOutGetRequests */ *uint_ptr = snmpoutgetrequests; 8030eac: 4b1d ldr r3, [pc, #116] ; (8030f24 ) 8030eae: e006 b.n 8030ebe break; case 26: /* snmpOutGetNexts */ *uint_ptr = snmpoutgetnexts; 8030eb0: 4b1d ldr r3, [pc, #116] ; (8030f28 ) 8030eb2: e004 b.n 8030ebe break; case 27: /* snmpOutSetRequests */ *uint_ptr = snmpoutsetrequests; 8030eb4: 4b1d ldr r3, [pc, #116] ; (8030f2c ) 8030eb6: e002 b.n 8030ebe break; case 28: /* snmpOutGetResponses */ *uint_ptr = snmpoutgetresponses; 8030eb8: 4b1d ldr r3, [pc, #116] ; (8030f30 ) 8030eba: e000 b.n 8030ebe break; case 29: /* snmpOutTraps */ *uint_ptr = snmpouttraps; 8030ebc: 4b1d ldr r3, [pc, #116] ; (8030f34 ) 8030ebe: 681b ldr r3, [r3, #0] 8030ec0: e002 b.n 8030ec8 break; case 30: /* snmpEnableAuthenTraps */ *uint_ptr = *snmpenableauthentraps_ptr; 8030ec2: 4b1d ldr r3, [pc, #116] ; (8030f38 ) 8030ec4: 681b ldr r3, [r3, #0] 8030ec6: 781b ldrb r3, [r3, #0] 8030ec8: 6013 str r3, [r2, #0] 8030eca: 4770 bx lr 8030ecc: 2000e180 .word 0x2000e180 8030ed0: 2000e250 .word 0x2000e250 8030ed4: 2000e23c .word 0x2000e23c 8030ed8: 2000e154 .word 0x2000e154 8030edc: 2000e158 .word 0x2000e158 8030ee0: 2000e240 .word 0x2000e240 8030ee4: 2000e200 .word 0x2000e200 8030ee8: 2000e280 .word 0x2000e280 8030eec: 2000e21c .word 0x2000e21c 8030ef0: 2000e1f0 .word 0x2000e1f0 8030ef4: 2000e1c8 .word 0x2000e1c8 8030ef8: 2000e220 .word 0x2000e220 8030efc: 2000e160 .word 0x2000e160 8030f00: 2000e1b4 .word 0x2000e1b4 8030f04: 2000e138 .word 0x2000e138 8030f08: 2000e25c .word 0x2000e25c 8030f0c: 2000e1b0 .word 0x2000e1b0 8030f10: 2000e148 .word 0x2000e148 8030f14: 2000e198 .word 0x2000e198 8030f18: 2000e164 .word 0x2000e164 8030f1c: 2000e144 .word 0x2000e144 8030f20: 2000e284 .word 0x2000e284 8030f24: 2000e1bc .word 0x2000e1bc 8030f28: 2000e254 .word 0x2000e254 8030f2c: 2000e260 .word 0x2000e260 8030f30: 2000e140 .word 0x2000e140 8030f34: 2000e1b8 .word 0x2000e1b8 8030f38: 20001768 .word 0x20001768 08030f3c : { u8_t id; LWIP_UNUSED_ARG(len); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8030f3c: 6883 ldr r3, [r0, #8] if (id == 30) 8030f3e: 781b ldrb r3, [r3, #0] 8030f40: 2b1e cmp r3, #30 8030f42: d103 bne.n 8030f4c { /* snmpEnableAuthenTraps */ /* @todo @fixme: which kind of pointer is 'value'? s32_t or u8_t??? */ u8_t *ptr = (u8_t*)value; *snmpenableauthentraps_ptr = *ptr; 8030f44: 4b02 ldr r3, [pc, #8] ; (8030f50 ) 8030f46: 7812 ldrb r2, [r2, #0] 8030f48: 681b ldr r3, [r3, #0] 8030f4a: 701a strb r2, [r3, #0] 8030f4c: 4770 bx lr 8030f4e: bf00 nop 8030f50: 20001768 .word 0x20001768 08030f54 : u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8030f54: 2801 cmp r0, #1 * @param ident points to objectname.index * @param od points to object definition. */ static void ifentry_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { 8030f56: b513 push {r0, r1, r4, lr} 8030f58: 4614 mov r4, r2 u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8030f5a: d149 bne.n 8030ff0 { od->id_inst_len = ident_len; 8030f5c: 2302 movs r3, #2 8030f5e: 7193 strb r3, [r2, #6] { u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8030f60: 1f0a subs r2, r1, #4 if (ident_len == 2) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8030f62: 60a2 str r2, [r4, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; LWIP_DEBUGF(SNMP_MIB_DEBUG,("get_object_def ifentry.%"U16_F"\n",(u16_t)id)); switch (id) 8030f64: f811 2c04 ldrb.w r2, [r1, #-4] 8030f68: 3a01 subs r2, #1 8030f6a: 2a15 cmp r2, #21 8030f6c: d840 bhi.n 8030ff0 8030f6e: e8df f002 tbb [pc, r2] 8030f72: 0e0b .short 0x0e0b 8030f74: 19140b0b .word 0x19140b0b 8030f78: 302b0b27 .word 0x302b0b27 8030f7c: 30303030 .word 0x30303030 8030f80: 30303030 .word 0x30303030 8030f84: 37143030 .word 0x37143030 { case 1: /* ifIndex */ case 3: /* ifType */ case 4: /* ifMtu */ case 8: /* ifOperStatus */ od->instance = MIB_OBJECT_TAB; 8030f88: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030f8a: 2201 movs r2, #1 8030f8c: e01a b.n 8030fc4 od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 2: /* ifDescr */ od->instance = MIB_OBJECT_TAB; od->access = MIB_OBJECT_READ_ONLY; 8030f8e: 2201 movs r2, #1 8030f90: 7062 strb r2, [r4, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030f92: 2204 movs r2, #4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 2: /* ifDescr */ od->instance = MIB_OBJECT_TAB; 8030f94: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030f96: 70a2 strb r2, [r4, #2] 8030f98: e028 b.n 8030fec /** @todo this should be some sort of sizeof(struct netif.name) */ od->v_len = 2; break; case 5: /* ifSpeed */ case 21: /* ifOutQLen */ od->instance = MIB_OBJECT_TAB; 8030f9a: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030f9c: 2301 movs r3, #1 8030f9e: 7063 strb r3, [r4, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_GAUGE); 8030fa0: 2342 movs r3, #66 ; 0x42 8030fa2: e01a b.n 8030fda break; case 6: /* ifPhysAddress */ { struct netif *netif; snmp_ifindextonetif(ident[1], &netif); 8030fa4: 6808 ldr r0, [r1, #0] 8030fa6: a901 add r1, sp, #4 8030fa8: f001 f800 bl 8031fac od->instance = MIB_OBJECT_TAB; 8030fac: 2302 movs r3, #2 8030fae: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030fb0: 2301 movs r3, #1 8030fb2: 7063 strb r3, [r4, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 8030fb4: 2304 movs r3, #4 8030fb6: 70a3 strb r3, [r4, #2] od->v_len = netif->hwaddr_len; 8030fb8: 9b01 ldr r3, [sp, #4] 8030fba: f893 3026 ldrb.w r3, [r3, #38] ; 0x26 8030fbe: e015 b.n 8030fec } break; case 7: /* ifAdminStatus */ od->instance = MIB_OBJECT_TAB; 8030fc0: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_WRITE; 8030fc2: 2203 movs r2, #3 8030fc4: 7062 strb r2, [r4, #1] 8030fc6: e008 b.n 8030fda od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 9: /* ifLastChange */ od->instance = MIB_OBJECT_TAB; 8030fc8: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030fca: 2301 movs r3, #1 8030fcc: 7063 strb r3, [r4, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS); 8030fce: 2343 movs r3, #67 ; 0x43 8030fd0: e003 b.n 8030fda case 16: /* ifOutOctets */ case 17: /* ifOutUcastPkts */ case 18: /* ifOutNUcastPkts */ case 19: /* ifOutDiscarts */ case 20: /* ifOutErrors */ od->instance = MIB_OBJECT_TAB; 8030fd2: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030fd4: 2301 movs r3, #1 8030fd6: 7063 strb r3, [r4, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8030fd8: 2341 movs r3, #65 ; 0x41 8030fda: 70a3 strb r3, [r4, #2] od->v_len = sizeof(u32_t); 8030fdc: 2304 movs r3, #4 8030fde: e005 b.n 8030fec break; case 22: /* ifSpecific */ /** @note returning zeroDotZero (0.0) no media specific MIB support */ od->instance = MIB_OBJECT_TAB; 8030fe0: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8030fe2: 2301 movs r3, #1 8030fe4: 7063 strb r3, [r4, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID); 8030fe6: 2306 movs r3, #6 8030fe8: 70a3 strb r3, [r4, #2] od->v_len = ifspecific.len * sizeof(s32_t); 8030fea: 2308 movs r3, #8 8030fec: 80a3 strh r3, [r4, #4] break; 8030fee: e001 b.n 8030ff4 }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ifentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8030ff0: 2300 movs r3, #0 8030ff2: 7023 strb r3, [r4, #0] } } 8030ff4: bd1c pop {r2, r3, r4, pc} 8030ff6: 0000 movs r0, r0 08030ff8 : } } static void udpentry_get_value(struct obj_def *od, u16_t len, void *value) { 8030ff8: b537 push {r0, r1, r2, r4, r5, lr} 8030ffa: 4604 mov r4, r0 struct udp_pcb *pcb; ip_addr_t ip; u16_t port; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); 8030ffc: 6880 ldr r0, [r0, #8] 8030ffe: a901 add r1, sp, #4 8031000: 3004 adds r0, #4 } } static void udpentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031002: 4615 mov r5, r2 struct udp_pcb *pcb; ip_addr_t ip; u16_t port; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); 8031004: f000 fff0 bl 8031fe8 LWIP_ASSERT("invalid port", (od->id_inst_ptr[5] >= 0) && (od->id_inst_ptr[5] <= 0xffff)); port = (u16_t)od->id_inst_ptr[5]; 8031008: 68a1 ldr r1, [r4, #8] pcb = udp_pcbs; 803100a: 4b0c ldr r3, [pc, #48] ; (803103c ) u16_t port; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); LWIP_ASSERT("invalid port", (od->id_inst_ptr[5] >= 0) && (od->id_inst_ptr[5] <= 0xffff)); port = (u16_t)od->id_inst_ptr[5]; 803100c: 8a8a ldrh r2, [r1, #20] pcb = udp_pcbs; 803100e: 681b ldr r3, [r3, #0] while ((pcb != NULL) && !(ip_addr_cmp(&pcb->local_ip, &ip) && 8031010: 9801 ldr r0, [sp, #4] snmp_oidtoip(&od->id_inst_ptr[1], &ip); LWIP_ASSERT("invalid port", (od->id_inst_ptr[5] >= 0) && (od->id_inst_ptr[5] <= 0xffff)); port = (u16_t)od->id_inst_ptr[5]; pcb = udp_pcbs; while ((pcb != NULL) && 8031012: e000 b.n 8031016 !(ip_addr_cmp(&pcb->local_ip, &ip) && (pcb->local_port == port))) { pcb = pcb->next; 8031014: 68db ldr r3, [r3, #12] snmp_oidtoip(&od->id_inst_ptr[1], &ip); LWIP_ASSERT("invalid port", (od->id_inst_ptr[5] >= 0) && (od->id_inst_ptr[5] <= 0xffff)); port = (u16_t)od->id_inst_ptr[5]; pcb = udp_pcbs; while ((pcb != NULL) && 8031016: b17b cbz r3, 8031038 8031018: 681c ldr r4, [r3, #0] 803101a: 4284 cmp r4, r0 803101c: d1fa bne.n 8031014 !(ip_addr_cmp(&pcb->local_ip, &ip) && (pcb->local_port == port))) 803101e: 8a5c ldrh r4, [r3, #18] LWIP_ASSERT("invalid port", (od->id_inst_ptr[5] >= 0) && (od->id_inst_ptr[5] <= 0xffff)); port = (u16_t)od->id_inst_ptr[5]; pcb = udp_pcbs; while ((pcb != NULL) && !(ip_addr_cmp(&pcb->local_ip, &ip) && 8031020: 4294 cmp r4, r2 8031022: d1f7 bne.n 8031014 8031024: e003 b.n 803102e switch (id) { case 1: /* udpLocalAddress */ { ip_addr_t *dst = (ip_addr_t*)value; *dst = pcb->local_ip; 8031026: 6028 str r0, [r5, #0] } break; 8031028: e006 b.n 8031038 case 2: /* udpLocalPort */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = pcb->local_port; 803102a: 602a str r2, [r5, #0] } break; 803102c: e004 b.n 8031038 if (pcb != NULL) { LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; switch (id) 803102e: 780b ldrb r3, [r1, #0] 8031030: 2b01 cmp r3, #1 8031032: d0f8 beq.n 8031026 8031034: 2b02 cmp r3, #2 8031036: d0f8 beq.n 803102a *sint_ptr = pcb->local_port; } break; } } } 8031038: bd3e pop {r1, r2, r3, r4, r5, pc} 803103a: bf00 nop 803103c: 20010ff8 .word 0x20010ff8 08031040 : } } static void ip_addrentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031040: b573 push {r0, r1, r4, r5, r6, lr} 8031042: 4606 mov r6, r0 u16_t ifidx; ip_addr_t ip; struct netif *netif = netif_list; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); 8031044: 6880 ldr r0, [r0, #8] ip_addrentry_get_value(struct obj_def *od, u16_t len, void *value) { u8_t id; u16_t ifidx; ip_addr_t ip; struct netif *netif = netif_list; 8031046: 4b18 ldr r3, [pc, #96] ; (80310a8 ) LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); 8031048: a901 add r1, sp, #4 803104a: 3004 adds r0, #4 ip_addrentry_get_value(struct obj_def *od, u16_t len, void *value) { u8_t id; u16_t ifidx; ip_addr_t ip; struct netif *netif = netif_list; 803104c: 681c ldr r4, [r3, #0] } } static void ip_addrentry_get_value(struct obj_def *od, u16_t len, void *value) { 803104e: 4615 mov r5, r2 u16_t ifidx; ip_addr_t ip; struct netif *netif = netif_list; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); 8031050: f000 ffca bl 8031fe8 ifidx = 0; while ((netif != NULL) && !ip_addr_cmp(&ip, &netif->ip_addr)) 8031054: 9901 ldr r1, [sp, #4] ip_addr_t ip; struct netif *netif = netif_list; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); ifidx = 0; 8031056: 2300 movs r3, #0 while ((netif != NULL) && !ip_addr_cmp(&ip, &netif->ip_addr)) 8031058: e002 b.n 8031060 { netif = netif->next; ifidx++; 803105a: 3301 adds r3, #1 LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); ifidx = 0; while ((netif != NULL) && !ip_addr_cmp(&ip, &netif->ip_addr)) { netif = netif->next; 803105c: 6824 ldr r4, [r4, #0] ifidx++; 803105e: b29b uxth r3, r3 struct netif *netif = netif_list; LWIP_UNUSED_ARG(len); snmp_oidtoip(&od->id_inst_ptr[1], &ip); ifidx = 0; while ((netif != NULL) && !ip_addr_cmp(&ip, &netif->ip_addr)) 8031060: b304 cbz r4, 80310a4 8031062: 6862 ldr r2, [r4, #4] 8031064: 4291 cmp r1, r2 8031066: d1f8 bne.n 803105a 8031068: e00a b.n 8031080 switch (id) { case 1: /* ipAdEntAddr */ { ip_addr_t *dst = (ip_addr_t*)value; *dst = netif->ip_addr; 803106a: 6863 ldr r3, [r4, #4] 803106c: e006 b.n 803107c } break; case 2: /* ipAdEntIfIndex */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = ifidx + 1; 803106e: 3301 adds r3, #1 8031070: e004 b.n 803107c } break; case 3: /* ipAdEntNetMask */ { ip_addr_t *dst = (ip_addr_t*)value; *dst = netif->netmask; 8031072: 68a3 ldr r3, [r4, #8] 8031074: e002 b.n 803107c { s32_t *sint_ptr = (s32_t*)value; /* lwIP oddity, there's no broadcast address in the netif we can rely on */ *sint_ptr = IPADDR_BROADCAST & 1; 8031076: 2301 movs r3, #1 8031078: e000 b.n 803107c *sint_ptr = (IP_HLEN + ((IP_REASS_MAX_PBUFS/2) * (PBUF_POOL_BUFSIZE - PBUF_LINK_HLEN - IP_HLEN))); #else /** @todo returning MTU would be a bad thing and returning a wild guess like '576' isn't good either */ *sint_ptr = 0; 803107a: 2300 movs r3, #0 803107c: 602b str r3, [r5, #0] #endif } break; 803107e: e011 b.n 80310a4 } if (netif != NULL) { LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031080: 68b2 ldr r2, [r6, #8] switch (id) 8031082: 7812 ldrb r2, [r2, #0] 8031084: 3a01 subs r2, #1 8031086: 2a04 cmp r2, #4 8031088: d80c bhi.n 80310a4 803108a: a101 add r1, pc, #4 ; (adr r1, 8031090 ) 803108c: f851 f022 ldr.w pc, [r1, r2, lsl #2] 8031090: 0803106b .word 0x0803106b 8031094: 0803106f .word 0x0803106f 8031098: 08031073 .word 0x08031073 803109c: 08031077 .word 0x08031077 80310a0: 0803107b .word 0x0803107b #endif } break; } } } 80310a4: bd7c pop {r2, r3, r4, r5, r6, pc} 80310a6: bf00 nop 80310a8: 20010fd0 .word 0x20010fd0 080310ac : } } static void ip_ntomentry_get_value(struct obj_def *od, u16_t len, void *value) { 80310ac: b530 push {r4, r5, lr} struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 80310ae: 6883 ldr r3, [r0, #8] } } static void ip_ntomentry_get_value(struct obj_def *od, u16_t len, void *value) { 80310b0: b085 sub sp, #20 80310b2: 4605 mov r5, r0 struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 80310b4: a903 add r1, sp, #12 80310b6: 6858 ldr r0, [r3, #4] } } static void ip_ntomentry_get_value(struct obj_def *od, u16_t len, void *value) { 80310b8: 4614 mov r4, r2 struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 80310ba: f000 ff77 bl 8031fac snmp_oidtoip(&od->id_inst_ptr[2], &ip); 80310be: 68a8 ldr r0, [r5, #8] 80310c0: a902 add r1, sp, #8 80310c2: 3008 adds r0, #8 80310c4: f000 ff90 bl 8031fe8 #if LWIP_ARP /** @todo implement a netif_find_addr */ if (etharp_find_addr(netif, &ip, ðaddr_ret, &ipaddr_ret) > -1) 80310c8: 9803 ldr r0, [sp, #12] 80310ca: a902 add r1, sp, #8 80310cc: 466a mov r2, sp 80310ce: ab01 add r3, sp, #4 80310d0: f002 ffca bl 8034068 80310d4: 2800 cmp r0, #0 80310d6: db15 blt.n 8031104 { LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 80310d8: 68ab ldr r3, [r5, #8] switch (id) 80310da: 781a ldrb r2, [r3, #0] 80310dc: 3a01 subs r2, #1 80310de: 2a03 cmp r2, #3 80310e0: d810 bhi.n 8031104 80310e2: e8df f002 tbb [pc, r2] 80310e6: 0402 .short 0x0402 80310e8: 0d0a .short 0x0d0a { case 1: /* ipNetToMediaIfIndex */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = od->id_inst_ptr[1]; 80310ea: 685b ldr r3, [r3, #4] 80310ec: e009 b.n 8031102 break; case 2: /* ipNetToMediaPhysAddress */ { struct eth_addr *dst = (struct eth_addr*)value; *dst = *ethaddr_ret; 80310ee: 9b00 ldr r3, [sp, #0] 80310f0: 681a ldr r2, [r3, #0] 80310f2: 6022 str r2, [r4, #0] 80310f4: 889b ldrh r3, [r3, #4] 80310f6: 80a3 strh r3, [r4, #4] } break; 80310f8: e004 b.n 8031104 case 3: /* ipNetToMediaNetAddress */ { ip_addr_t *dst = (ip_addr_t*)value; *dst = *ipaddr_ret; 80310fa: 9b01 ldr r3, [sp, #4] 80310fc: 681b ldr r3, [r3, #0] 80310fe: e000 b.n 8031102 break; case 4: /* ipNetToMediaType */ { s32_t *sint_ptr = (s32_t*)value; /* dynamic (?) */ *sint_ptr = 3; 8031100: 2303 movs r3, #3 8031102: 6023 str r3, [r4, #0] } break; } } #endif /* LWIP_ARP */ } 8031104: b005 add sp, #20 8031106: bd30 pop {r4, r5, pc} 08031108 : } } static void atentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031108: b530 push {r4, r5, lr} struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 803110a: 6883 ldr r3, [r0, #8] } } static void atentry_get_value(struct obj_def *od, u16_t len, void *value) { 803110c: b085 sub sp, #20 803110e: 4605 mov r5, r0 struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 8031110: a903 add r1, sp, #12 8031112: 6858 ldr r0, [r3, #4] } } static void atentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031114: 4614 mov r4, r2 struct netif *netif; LWIP_UNUSED_ARG(len); LWIP_UNUSED_ARG(value);/* if !LWIP_ARP */ snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 8031116: f000 ff49 bl 8031fac snmp_oidtoip(&od->id_inst_ptr[2], &ip); 803111a: 68a8 ldr r0, [r5, #8] 803111c: a902 add r1, sp, #8 803111e: 3008 adds r0, #8 8031120: f000 ff62 bl 8031fe8 #if LWIP_ARP /** @todo implement a netif_find_addr */ if (etharp_find_addr(netif, &ip, ðaddr_ret, &ipaddr_ret) > -1) 8031124: 9803 ldr r0, [sp, #12] 8031126: a902 add r1, sp, #8 8031128: 466a mov r2, sp 803112a: ab01 add r3, sp, #4 803112c: f002 ff9c bl 8034068 8031130: 2800 cmp r0, #0 8031132: db12 blt.n 803115a { LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031134: 68aa ldr r2, [r5, #8] switch (id) 8031136: 7813 ldrb r3, [r2, #0] 8031138: 2b02 cmp r3, #2 803113a: d005 beq.n 8031148 803113c: 2b03 cmp r3, #3 803113e: d009 beq.n 8031154 8031140: 2b01 cmp r3, #1 8031142: d10a bne.n 803115a { case 1: /* atIfIndex */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = od->id_inst_ptr[1]; 8031144: 6853 ldr r3, [r2, #4] 8031146: e007 b.n 8031158 break; case 2: /* atPhysAddress */ { struct eth_addr *dst = (struct eth_addr*)value; *dst = *ethaddr_ret; 8031148: 9b00 ldr r3, [sp, #0] 803114a: 681a ldr r2, [r3, #0] 803114c: 6022 str r2, [r4, #0] 803114e: 889b ldrh r3, [r3, #4] 8031150: 80a3 strh r3, [r4, #4] } break; 8031152: e002 b.n 803115a case 3: /* atNetAddress */ { ip_addr_t *dst = (ip_addr_t*)value; *dst = *ipaddr_ret; 8031154: 9b01 ldr r3, [sp, #4] 8031156: 681b ldr r3, [r3, #0] 8031158: 6023 str r3, [r4, #0] } break; } } #endif /* LWIP_ARP */ } 803115a: b005 add sp, #20 803115c: bd30 pop {r4, r5, pc} 803115e: 0000 movs r0, r0 08031160 : u8_t id, set_ok; LWIP_UNUSED_ARG(value); set_ok = 0; LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031160: 6883 ldr r3, [r0, #8] switch (id) 8031162: 781b ldrb r3, [r3, #0] 8031164: 2b05 cmp r3, #5 8031166: d007 beq.n 8031178 8031168: 2b06 cmp r3, #6 803116a: d00f beq.n 803118c 803116c: 2b04 cmp r3, #4 803116e: d111 bne.n 8031194 { case 4: /* sysContact */ if ((syscontact_ptr != syscontact_default) && 8031170: 4b09 ldr r3, [pc, #36] ; (8031198 ) 8031172: 681a ldr r2, [r3, #0] 8031174: 4b09 ldr r3, [pc, #36] ; (803119c ) 8031176: e002 b.n 803117e { set_ok = 1; } break; case 5: /* sysName */ if ((sysname_ptr != sysname_default) && 8031178: 4b09 ldr r3, [pc, #36] ; (80311a0 ) 803117a: 681a ldr r2, [r3, #0] 803117c: 4b09 ldr r3, [pc, #36] ; (80311a4 ) 803117e: 429a cmp r2, r3 8031180: d008 beq.n 8031194 system_set_test(struct obj_def *od, u16_t len, void *value) { u8_t id, set_ok; LWIP_UNUSED_ARG(value); set_ok = 0; 8031182: 29ff cmp r1, #255 ; 0xff 8031184: bf8c ite hi 8031186: 2000 movhi r0, #0 8031188: 2001 movls r0, #1 803118a: 4770 bx lr { set_ok = 1; } break; case 6: /* sysLocation */ if ((syslocation_ptr != syslocation_default) && 803118c: 4b06 ldr r3, [pc, #24] ; (80311a8 ) 803118e: 681a ldr r2, [r3, #0] 8031190: 4b06 ldr r3, [pc, #24] ; (80311ac ) 8031192: e7f4 b.n 803117e system_set_test(struct obj_def *od, u16_t len, void *value) { u8_t id, set_ok; LWIP_UNUSED_ARG(value); set_ok = 0; 8031194: 2000 movs r0, #0 set_ok = 1; } break; }; return set_ok; } 8031196: 4770 bx lr 8031198: 200017e4 .word 0x200017e4 803119c: 08040288 .word 0x08040288 80311a0: 20001770 .word 0x20001770 80311a4: 0803ffa0 .word 0x0803ffa0 80311a8: 200018fc .word 0x200018fc 80311ac: 0803ffd0 .word 0x0803ffd0 080311b0 : { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; if (ident_len == 6) 80311b0: 2801 cmp r0, #1 80311b2: d120 bne.n 80311f6 { od->id_inst_len = ident_len; 80311b4: 2006 movs r0, #6 static void atentry_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; 80311b6: f1a1 0314 sub.w r3, r1, #20 if (ident_len == 6) { od->id_inst_len = ident_len; 80311ba: 7190 strb r0, [r2, #6] od->id_inst_ptr = ident; 80311bc: 6093 str r3, [r2, #8] switch (ident[0]) 80311be: f851 3c14 ldr.w r3, [r1, #-20] 80311c2: 2b02 cmp r3, #2 80311c4: d008 beq.n 80311d8 80311c6: 2b03 cmp r3, #3 80311c8: d00d beq.n 80311e6 80311ca: 2b01 cmp r3, #1 80311cc: d113 bne.n 80311f6 { case 1: /* atIfIndex */ od->instance = MIB_OBJECT_TAB; 80311ce: 2302 movs r3, #2 od->access = MIB_OBJECT_READ_WRITE; 80311d0: 2103 movs r1, #3 od->id_inst_ptr = ident; switch (ident[0]) { case 1: /* atIfIndex */ od->instance = MIB_OBJECT_TAB; 80311d2: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80311d4: 7051 strb r1, [r2, #1] 80311d6: e00a b.n 80311ee od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 2: /* atPhysAddress */ od->instance = MIB_OBJECT_TAB; 80311d8: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80311da: 2303 movs r3, #3 80311dc: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 80311de: 2304 movs r3, #4 80311e0: 7093 strb r3, [r2, #2] od->v_len = 6; /** @todo try to use netif::hwaddr_len */ 80311e2: 8090 strh r0, [r2, #4] break; 80311e4: 4770 bx lr case 3: /* atNetAddress */ od->instance = MIB_OBJECT_TAB; 80311e6: 2102 movs r1, #2 od->access = MIB_OBJECT_READ_WRITE; 80311e8: 7053 strb r3, [r2, #1] od->access = MIB_OBJECT_READ_WRITE; od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); od->v_len = 6; /** @todo try to use netif::hwaddr_len */ break; case 3: /* atNetAddress */ od->instance = MIB_OBJECT_TAB; 80311ea: 7011 strb r1, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR); 80311ec: 2340 movs r3, #64 ; 0x40 80311ee: 7093 strb r3, [r2, #2] od->v_len = 4; 80311f0: 2304 movs r3, #4 80311f2: 8093 strh r3, [r2, #4] break; 80311f4: 4770 bx lr } } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("atentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 80311f6: 2300 movs r3, #0 80311f8: 7013 strb r3, [r2, #0] 80311fa: 4770 bx lr 080311fc : u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 80311fc: 2801 cmp r0, #1 #endif /* LWIP_ARP */ } static void ip_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { 80311fe: b510 push {r4, lr} u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8031200: d121 bne.n 8031246 { od->id_inst_len = ident_len; 8031202: 2402 movs r4, #2 { u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8031204: 1f0b subs r3, r1, #4 if (ident_len == 2) { od->id_inst_len = ident_len; 8031206: 7194 strb r4, [r2, #6] od->id_inst_ptr = ident; 8031208: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; LWIP_DEBUGF(SNMP_MIB_DEBUG,("get_object_def ip.%"U16_F".0\n",(u16_t)id)); switch (id) 803120a: f811 3c04 ldrb.w r3, [r1, #-4] 803120e: 2b17 cmp r3, #23 8031210: d819 bhi.n 8031246 8031212: 490e ldr r1, [pc, #56] ; (803124c ) 8031214: 4099 lsls r1, r3 8031216: d40b bmi.n 8031230 8031218: f44f 2180 mov.w r1, #262144 ; 0x40000 803121c: 4099 lsls r1, r3 803121e: d40c bmi.n 803123a 8031220: f04f 41c0 mov.w r1, #1610612736 ; 0x60000000 8031224: 4099 lsls r1, r3 8031226: d50e bpl.n 8031246 { case 1: /* ipForwarding */ case 2: /* ipDefaultTTL */ od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_WRITE; 8031228: 2303 movs r3, #3 LWIP_DEBUGF(SNMP_MIB_DEBUG,("get_object_def ip.%"U16_F".0\n",(u16_t)id)); switch (id) { case 1: /* ipForwarding */ case 2: /* ipDefaultTTL */ od->instance = MIB_OBJECT_SCALAR; 803122a: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 803122c: 7053 strb r3, [r2, #1] 803122e: e006 b.n 803123e case 18: /* ipFragFails */ case 19: /* ipFragCreates */ case 23: /* ipRoutingDiscards */ od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8031230: 2341 movs r3, #65 ; 0x41 case 16: /* ipReasmFails */ case 17: /* ipFragOKs */ case 18: /* ipFragFails */ case 19: /* ipFragCreates */ case 23: /* ipRoutingDiscards */ od->instance = MIB_OBJECT_SCALAR; 8031232: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8031234: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8031236: 7093 strb r3, [r2, #2] 8031238: e002 b.n 8031240 od->v_len = sizeof(u32_t); break; case 13: /* ipReasmTimeout */ od->instance = MIB_OBJECT_SCALAR; 803123a: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 803123c: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 803123e: 7094 strb r4, [r2, #2] od->v_len = sizeof(s32_t); 8031240: 2304 movs r3, #4 8031242: 8093 strh r3, [r2, #4] break; 8031244: bd10 pop {r4, pc} }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ip_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8031246: 2300 movs r3, #0 8031248: 7013 strb r3, [r2, #0] 803124a: bd10 pop {r4, pc} 803124c: 1ffbf100 .word 0x1ffbf100 08031250 : { /* return to object name, adding index depth (4) */ ident_len += 4; ident -= 4; if (ident_len == 5) 8031250: 2801 cmp r0, #1 8031252: d11c bne.n 803128e { u8_t id; od->id_inst_len = ident_len; 8031254: 2305 movs r3, #5 8031256: 7193 strb r3, [r2, #6] static void ip_addrentry_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (4) */ ident_len += 4; ident -= 4; 8031258: f1a1 0310 sub.w r3, r1, #16 if (ident_len == 5) { u8_t id; od->id_inst_len = ident_len; od->id_inst_ptr = ident; 803125c: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 803125e: f811 3c10 ldrb.w r3, [r1, #-16] 8031262: 2b05 cmp r3, #5 8031264: d813 bhi.n 803128e 8031266: f04f 5130 mov.w r1, #738197504 ; 0x2c000000 803126a: 4099 lsls r1, r3 803126c: d408 bmi.n 8031280 803126e: f04f 41a0 mov.w r1, #1342177280 ; 0x50000000 8031272: 4099 lsls r1, r3 8031274: d50b bpl.n 803128e { case 1: /* ipAdEntAddr */ case 3: /* ipAdEntNetMask */ od->instance = MIB_OBJECT_TAB; 8031276: 2302 movs r3, #2 8031278: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 803127a: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR); 803127c: 2340 movs r3, #64 ; 0x40 803127e: e002 b.n 8031286 od->v_len = 4; break; case 2: /* ipAdEntIfIndex */ case 4: /* ipAdEntBcastAddr */ case 5: /* ipAdEntReasmMaxSize */ od->instance = MIB_OBJECT_TAB; 8031280: 2302 movs r3, #2 8031282: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8031284: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8031286: 7093 strb r3, [r2, #2] od->v_len = sizeof(s32_t); 8031288: 2304 movs r3, #4 803128a: 8093 strh r3, [r2, #4] break; 803128c: 4770 bx lr } } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ip_addrentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 803128e: 2300 movs r3, #0 8031290: 7013 strb r3, [r2, #0] 8031292: 4770 bx lr 08031294 : { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; if (ident_len == 6) 8031294: 2801 cmp r0, #1 8031296: d123 bne.n 80312e0 { u8_t id; od->id_inst_len = ident_len; 8031298: 2306 movs r3, #6 803129a: 7193 strb r3, [r2, #6] static void ip_ntomentry_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; 803129c: f1a1 0314 sub.w r3, r1, #20 if (ident_len == 6) { u8_t id; od->id_inst_len = ident_len; od->id_inst_ptr = ident; 80312a0: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 80312a2: f811 3c14 ldrb.w r3, [r1, #-20] 80312a6: 3b01 subs r3, #1 80312a8: 2b03 cmp r3, #3 80312aa: d819 bhi.n 80312e0 80312ac: e8df f003 tbb [pc, r3] 80312b0: 020f0702 .word 0x020f0702 { case 1: /* ipNetToMediaIfIndex */ case 4: /* ipNetToMediaType */ od->instance = MIB_OBJECT_TAB; 80312b4: 2302 movs r3, #2 od->access = MIB_OBJECT_READ_WRITE; 80312b6: 2103 movs r1, #3 id = (u8_t)ident[0]; switch (id) { case 1: /* ipNetToMediaIfIndex */ case 4: /* ipNetToMediaType */ od->instance = MIB_OBJECT_TAB; 80312b8: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80312ba: 7051 strb r1, [r2, #1] 80312bc: e00c b.n 80312d8 od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); od->v_len = sizeof(s32_t); break; case 2: /* ipNetToMediaPhysAddress */ od->instance = MIB_OBJECT_TAB; 80312be: 2302 movs r3, #2 80312c0: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80312c2: 2303 movs r3, #3 80312c4: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR); 80312c6: 2304 movs r3, #4 80312c8: 7093 strb r3, [r2, #2] od->v_len = 6; /** @todo try to use netif::hwaddr_len */ 80312ca: 2306 movs r3, #6 80312cc: e006 b.n 80312dc break; case 3: /* ipNetToMediaNetAddress */ od->instance = MIB_OBJECT_TAB; 80312ce: 2302 movs r3, #2 80312d0: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80312d2: 2303 movs r3, #3 80312d4: 7053 strb r3, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR); 80312d6: 2340 movs r3, #64 ; 0x40 80312d8: 7093 strb r3, [r2, #2] od->v_len = 4; 80312da: 2304 movs r3, #4 80312dc: 8093 strh r3, [r2, #4] break; 80312de: 4770 bx lr } } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ip_ntomentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 80312e0: 2300 movs r3, #0 80312e2: 7013 strb r3, [r2, #0] 80312e4: 4770 bx lr 80312e6: 0000 movs r0, r0 080312e8 : u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 80312e8: 2801 cmp r0, #1 #if LWIP_TCP /** @todo tcp grp */ static void tcp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { 80312ea: b510 push {r4, lr} u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 80312ec: d121 bne.n 8031332 { od->id_inst_len = ident_len; 80312ee: 2402 movs r4, #2 { u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 80312f0: 1f0b subs r3, r1, #4 if (ident_len == 2) { od->id_inst_len = ident_len; 80312f2: 7194 strb r4, [r2, #6] od->id_inst_ptr = ident; 80312f4: 6093 str r3, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; LWIP_DEBUGF(SNMP_MIB_DEBUG,("get_object_def tcp.%"U16_F".0\n",(u16_t)id)); switch (id) 80312f6: f811 3c04 ldrb.w r3, [r1, #-4] 80312fa: 2b0f cmp r3, #15 80312fc: d819 bhi.n 8031332 80312fe: 490e ldr r1, [pc, #56] ; (8031338 ) 8031300: 4099 lsls r1, r3 8031302: d40b bmi.n 803131c 8031304: f44f 0180 mov.w r1, #4194304 ; 0x400000 8031308: 4099 lsls r1, r3 803130a: d40b bmi.n 8031324 803130c: f04f 41f0 mov.w r1, #2013265920 ; 0x78000000 8031310: 4099 lsls r1, r3 8031312: d50e bpl.n 8031332 { case 1: /* tcpRtoAlgorithm */ case 2: /* tcpRtoMin */ case 3: /* tcpRtoMax */ case 4: /* tcpMaxConn */ od->instance = MIB_OBJECT_SCALAR; 8031314: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8031316: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8031318: 7094 strb r4, [r2, #2] 803131a: e007 b.n 803132c case 10: /* tcpInSegs */ case 11: /* tcpOutSegs */ case 12: /* tcpRetransSegs */ case 14: /* tcpInErrs */ case 15: /* tcpOutRsts */ od->instance = MIB_OBJECT_SCALAR; 803131c: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 803131e: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 8031320: 2341 movs r3, #65 ; 0x41 8031322: e002 b.n 803132a od->v_len = sizeof(u32_t); break; case 9: /* tcpCurrEstab */ od->instance = MIB_OBJECT_TAB; 8031324: 7014 strb r4, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8031326: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_GAUGE); 8031328: 2342 movs r3, #66 ; 0x42 803132a: 7093 strb r3, [r2, #2] od->v_len = sizeof(u32_t); 803132c: 2304 movs r3, #4 803132e: 8093 strh r3, [r2, #4] break; 8031330: bd10 pop {r4, pc} }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("tcp_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8031332: 2300 movs r3, #0 8031334: 7013 strb r3, [r2, #0] 8031336: bd10 pop {r4, pc} 8031338: 07bb0000 .word 0x07bb0000 0803133c : { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; if (ident_len == 6) 803133c: 2801 cmp r0, #1 803133e: d116 bne.n 803136e { od->id_inst_len = ident_len; 8031340: 2306 movs r3, #6 8031342: 7193 strb r3, [r2, #6] static void udpentry_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (5) */ ident_len += 5; ident -= 5; 8031344: f1a1 0314 sub.w r3, r1, #20 if (ident_len == 6) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8031348: 6093 str r3, [r2, #8] switch (ident[0]) 803134a: f851 3c14 ldr.w r3, [r1, #-20] 803134e: 2b01 cmp r3, #1 8031350: d002 beq.n 8031358 8031352: 2b02 cmp r3, #2 8031354: d10b bne.n 803136e 8031356: e004 b.n 8031362 { case 1: /* udpLocalAddress */ od->instance = MIB_OBJECT_TAB; 8031358: 2102 movs r1, #2 od->access = MIB_OBJECT_READ_ONLY; 803135a: 7053 strb r3, [r2, #1] od->id_inst_ptr = ident; switch (ident[0]) { case 1: /* udpLocalAddress */ od->instance = MIB_OBJECT_TAB; 803135c: 7011 strb r1, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR); 803135e: 2340 movs r3, #64 ; 0x40 8031360: e001 b.n 8031366 od->v_len = 4; break; case 2: /* udpLocalPort */ od->instance = MIB_OBJECT_TAB; 8031362: 7013 strb r3, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 8031364: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 8031366: 7093 strb r3, [r2, #2] od->v_len = sizeof(s32_t); 8031368: 2304 movs r3, #4 803136a: 8093 strh r3, [r2, #4] break; 803136c: 4770 bx lr } } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("udpentry_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 803136e: 2300 movs r3, #0 8031370: 7013 strb r3, [r2, #0] 8031372: 4770 bx lr 08031374 : snmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8031374: 2801 cmp r0, #1 } } static void snmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { 8031376: b510 push {r4, lr} /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8031378: d119 bne.n 80313ae { u8_t id; od->id_inst_len = ident_len; 803137a: 2302 movs r3, #2 803137c: 7193 strb r3, [r2, #6] static void snmp_get_object_def(u8_t ident_len, s32_t *ident, struct obj_def *od) { /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 803137e: 1f0c subs r4, r1, #4 od->id_inst_len = ident_len; od->id_inst_ptr = ident; LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 8031380: f811 1c04 ldrb.w r1, [r1, #-4] if (ident_len == 2) { u8_t id; od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8031384: 6094 str r4, [r2, #8] LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 8031386: 291e cmp r1, #30 8031388: d811 bhi.n 80313ae 803138a: 4c0a ldr r4, [pc, #40] ; (80313b4 ) 803138c: 408c lsls r4, r1 803138e: d403 bmi.n 8031398 8031390: fa13 f101 lsls.w r1, r3, r1 8031394: d404 bmi.n 80313a0 8031396: e00a b.n 80313ae case 25: /* snmpOutGetRequests */ case 26: /* snmpOutGetNexts */ case 27: /* snmpOutSetRequests */ case 28: /* snmpOutGetResponses */ case 29: /* snmpOutTraps */ od->instance = MIB_OBJECT_SCALAR; 8031398: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_ONLY; 803139a: 7050 strb r0, [r2, #1] od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); 803139c: 2341 movs r3, #65 ; 0x41 803139e: e002 b.n 80313a6 od->v_len = sizeof(u32_t); break; case 30: /* snmpEnableAuthenTraps */ od->instance = MIB_OBJECT_SCALAR; od->access = MIB_OBJECT_READ_WRITE; 80313a0: 2103 movs r1, #3 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER); od->v_len = sizeof(u32_t); break; case 30: /* snmpEnableAuthenTraps */ od->instance = MIB_OBJECT_SCALAR; 80313a2: 7010 strb r0, [r2, #0] od->access = MIB_OBJECT_READ_WRITE; 80313a4: 7051 strb r1, [r2, #1] od->asn_type = (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG); 80313a6: 7093 strb r3, [r2, #2] od->v_len = sizeof(s32_t); 80313a8: 2304 movs r3, #4 80313aa: 8093 strh r3, [r2, #4] break; 80313ac: bd10 pop {r4, pc} }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("snmp_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 80313ae: 2300 movs r3, #0 80313b0: 7013 strb r3, [r2, #0] 80313b2: bd10 pop {r4, pc} 80313b4: 7efffefc .word 0x7efffefc 080313b8 : u8_t id, set_ok; LWIP_UNUSED_ARG(len); set_ok = 0; LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 80313b8: 6883 ldr r3, [r0, #8] if (id == 30) 80313ba: 781b ldrb r3, [r3, #0] 80313bc: 2b1e cmp r3, #30 80313be: d10f bne.n 80313e0 { /* snmpEnableAuthenTraps */ s32_t *sint_ptr = (s32_t*)value; if (snmpenableauthentraps_ptr != &snmpenableauthentraps_default) 80313c0: 4b08 ldr r3, [pc, #32] ; (80313e4 ) 80313c2: 6810 ldr r0, [r2, #0] 80313c4: 6819 ldr r1, [r3, #0] 80313c6: 4b08 ldr r3, [pc, #32] ; (80313e8 ) 80313c8: 4299 cmp r1, r3 80313ca: d005 beq.n 80313d8 { /* we should have writable non-volatile mem here */ if ((*sint_ptr == 1) || (*sint_ptr == 2)) 80313cc: 3801 subs r0, #1 snmp_set_test(struct obj_def *od, u16_t len, void *value) { u8_t id, set_ok; LWIP_UNUSED_ARG(len); set_ok = 0; 80313ce: 2801 cmp r0, #1 80313d0: bf8c ite hi 80313d2: 2000 movhi r0, #0 80313d4: 2001 movls r0, #1 80313d6: 4770 bx lr 80313d8: 1e83 subs r3, r0, #2 80313da: 4258 negs r0, r3 80313dc: 4158 adcs r0, r3 80313de: 4770 bx lr 80313e0: 2000 movs r0, #0 set_ok = 1; } } } return set_ok; } 80313e2: 4770 bx lr 80313e4: 20001768 .word 0x20001768 80313e8: 08040084 .word 0x08040084 080313ec : * @param dst points to destination * @param src points to source * @param n number of octets to copy. */ void ocstrncpy(u8_t *dst, u8_t *src, u16_t n) { 80313ec: b510 push {r4, lr} u16_t i = n; while (i > 0) { 80313ee: 2300 movs r3, #0 80313f0: e002 b.n 80313f8 i--; *dst++ = *src++; 80313f2: 5ccc ldrb r4, [r1, r3] 80313f4: 54c4 strb r4, [r0, r3] 80313f6: 3301 adds r3, #1 * @param n number of octets to copy. */ void ocstrncpy(u8_t *dst, u8_t *src, u16_t n) { u16_t i = n; while (i > 0) { 80313f8: b29c uxth r4, r3 80313fa: 42a2 cmp r2, r4 80313fc: d1f9 bne.n 80313f2 i--; *dst++ = *src++; } } 80313fe: bd10 pop {r4, pc} 08031400 : { u8_t id; LWIP_ASSERT("invalid len", len <= 0xff); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031400: 6883 ldr r3, [r0, #8] switch (id) 8031402: 781b ldrb r3, [r3, #0] 8031404: 2b05 cmp r3, #5 return set_ok; } static void system_set_value(struct obj_def *od, u16_t len, void *value) { 8031406: b510 push {r4, lr} 8031408: 460c mov r4, r1 803140a: 4611 mov r1, r2 u8_t id; LWIP_ASSERT("invalid len", len <= 0xff); LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; switch (id) 803140c: d00a beq.n 8031424 803140e: 2b06 cmp r3, #6 8031410: d00f beq.n 8031432 8031412: 2b04 cmp r3, #4 8031414: d115 bne.n 8031442 { case 4: /* sysContact */ ocstrncpy(syscontact_ptr, (u8_t*)value, len); 8031416: 4b0b ldr r3, [pc, #44] ; (8031444 ) 8031418: 4622 mov r2, r4 803141a: 6818 ldr r0, [r3, #0] 803141c: f7ff ffe6 bl 80313ec *syscontact_len_ptr = (u8_t)len; 8031420: 4b09 ldr r3, [pc, #36] ; (8031448 ) 8031422: e00c b.n 803143e break; case 5: /* sysName */ ocstrncpy(sysname_ptr, (u8_t*)value, len); 8031424: 4b09 ldr r3, [pc, #36] ; (803144c ) 8031426: 4622 mov r2, r4 8031428: 6818 ldr r0, [r3, #0] 803142a: f7ff ffdf bl 80313ec *sysname_len_ptr = (u8_t)len; 803142e: 4b08 ldr r3, [pc, #32] ; (8031450 ) 8031430: e005 b.n 803143e break; case 6: /* sysLocation */ ocstrncpy(syslocation_ptr, (u8_t*)value, len); 8031432: 4b08 ldr r3, [pc, #32] ; (8031454 ) 8031434: 4622 mov r2, r4 8031436: 6818 ldr r0, [r3, #0] 8031438: f7ff ffd8 bl 80313ec *syslocation_len_ptr = (u8_t)len; 803143c: 4b06 ldr r3, [pc, #24] ; (8031458 ) 803143e: 681b ldr r3, [r3, #0] 8031440: 701c strb r4, [r3, #0] 8031442: bd10 pop {r4, pc} 8031444: 200017e4 .word 0x200017e4 8031448: 20001668 .word 0x20001668 803144c: 20001770 .word 0x20001770 8031450: 20001664 .word 0x20001664 8031454: 200018fc .word 0x200018fc 8031458: 20001850 .word 0x20001850 0803145c : * * @param dst points to destination * @param src points to source * @param n number of sub identifiers to copy. */ void objectidncpy(s32_t *dst, s32_t *src, u8_t n) 803145c: 3904 subs r1, #4 { u8_t i = n; while(i > 0) { 803145e: e005 b.n 803146c i--; *dst++ = *src++; 8031460: f851 3f04 ldr.w r3, [r1, #4]! */ void objectidncpy(s32_t *dst, s32_t *src, u8_t n) { u8_t i = n; while(i > 0) { i--; 8031464: 3a01 subs r2, #1 *dst++ = *src++; 8031466: f840 3b04 str.w r3, [r0], #4 */ void objectidncpy(s32_t *dst, s32_t *src, u8_t n) { u8_t i = n; while(i > 0) { i--; 803146a: b2d2 uxtb r2, r2 * @param n number of sub identifiers to copy. */ void objectidncpy(s32_t *dst, s32_t *src, u8_t n) { u8_t i = n; while(i > 0) { 803146c: 2a00 cmp r2, #0 803146e: d1f7 bne.n 8031460 i--; *dst++ = *src++; } } 8031470: 4770 bx lr 8031472: 0000 movs r0, r0 08031474 : * @param len return value space (in bytes) * @param value points to (varbind) space to copy value into. */ static void ifentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031474: b573 push {r0, r1, r4, r5, r6, lr} struct netif *netif; u8_t id; snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 8031476: 6883 ldr r3, [r0, #8] * @param len return value space (in bytes) * @param value points to (varbind) space to copy value into. */ static void ifentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031478: 4606 mov r6, r0 803147a: 460d mov r5, r1 struct netif *netif; u8_t id; snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 803147c: 6858 ldr r0, [r3, #4] 803147e: a901 add r1, sp, #4 * @param len return value space (in bytes) * @param value points to (varbind) space to copy value into. */ static void ifentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031480: 4614 mov r4, r2 struct netif *netif; u8_t id; snmp_ifindextonetif(od->id_inst_ptr[1], &netif); 8031482: f000 fd93 bl 8031fac LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031486: 68b3 ldr r3, [r6, #8] switch (id) 8031488: 781a ldrb r2, [r3, #0] 803148a: 3a01 subs r2, #1 803148c: 2a15 cmp r2, #21 803148e: d85c bhi.n 803154a 8031490: e8df f002 tbb [pc, r2] 8031494: 15110d0b .word 0x15110d0b 8031498: 2e221b18 .word 0x2e221b18 803149c: 403d3a37 .word 0x403d3a37 80314a0: 46525243 .word 0x46525243 80314a4: 524f4c49 .word 0x524f4c49 80314a8: 5552 .short 0x5552 { case 1: /* ifIndex */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = od->id_inst_ptr[1]; 80314aa: 685b ldr r3, [r3, #4] 80314ac: e045 b.n 803153a } break; case 2: /* ifDescr */ ocstrncpy((u8_t*)value, (u8_t*)netif->name, len); 80314ae: 9901 ldr r1, [sp, #4] 80314b0: 4620 mov r0, r4 80314b2: 312e adds r1, #46 ; 0x2e 80314b4: e00c b.n 80314d0 break; case 3: /* ifType */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = netif->link_type; 80314b6: 9b01 ldr r3, [sp, #4] 80314b8: f893 3031 ldrb.w r3, [r3, #49] ; 0x31 80314bc: e03d b.n 803153a } break; case 4: /* ifMtu */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = netif->mtu; 80314be: 9b01 ldr r3, [sp, #4] 80314c0: 8c9b ldrh r3, [r3, #36] ; 0x24 80314c2: e03a b.n 803153a } break; case 5: /* ifSpeed */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->link_speed; 80314c4: 9b01 ldr r3, [sp, #4] 80314c6: 6b5b ldr r3, [r3, #52] ; 0x34 80314c8: e037 b.n 803153a } break; case 6: /* ifPhysAddress */ ocstrncpy((u8_t*)value, netif->hwaddr, len); 80314ca: 9901 ldr r1, [sp, #4] 80314cc: 4620 mov r0, r4 80314ce: 3127 adds r1, #39 ; 0x27 80314d0: 462a mov r2, r5 80314d2: f7ff ff8b bl 80313ec break; 80314d6: e038 b.n 803154a case 7: /* ifAdminStatus */ { s32_t *sint_ptr = (s32_t*)value; if (netif_is_up(netif)) 80314d8: 9b01 ldr r3, [sp, #4] 80314da: f893 302d ldrb.w r3, [r3, #45] ; 0x2d 80314de: 07d9 lsls r1, r3, #31 80314e0: d50d bpl.n 80314fe { if (netif_is_link_up(netif)) 80314e2: f003 0310 and.w r3, r3, #16 80314e6: b2db uxtb r3, r3 80314e8: b103 cbz r3, 80314ec 80314ea: e006 b.n 80314fa { *sint_ptr = 1; /* up */ } else { *sint_ptr = 7; /* lowerLayerDown */ 80314ec: 2307 movs r3, #7 80314ee: e024 b.n 803153a } break; case 8: /* ifOperStatus */ { s32_t *sint_ptr = (s32_t*)value; if (netif_is_up(netif)) 80314f0: 9b01 ldr r3, [sp, #4] 80314f2: f893 302d ldrb.w r3, [r3, #45] ; 0x2d 80314f6: 07da lsls r2, r3, #31 80314f8: d501 bpl.n 80314fe { *sint_ptr = 1; 80314fa: 2301 movs r3, #1 80314fc: e01d b.n 803153a } else { *sint_ptr = 2; 80314fe: 2302 movs r3, #2 8031500: e01b b.n 803153a } break; case 9: /* ifLastChange */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ts; 8031502: 9b01 ldr r3, [sp, #4] 8031504: 6b9b ldr r3, [r3, #56] ; 0x38 8031506: e018 b.n 803153a } break; case 10: /* ifInOctets */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifinoctets; 8031508: 9b01 ldr r3, [sp, #4] 803150a: 6bdb ldr r3, [r3, #60] ; 0x3c 803150c: e015 b.n 803153a } break; case 11: /* ifInUcastPkts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifinucastpkts; 803150e: 9b01 ldr r3, [sp, #4] 8031510: 6c1b ldr r3, [r3, #64] ; 0x40 8031512: e012 b.n 803153a } break; case 12: /* ifInNUcastPkts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifinnucastpkts; 8031514: 9b01 ldr r3, [sp, #4] 8031516: 6c5b ldr r3, [r3, #68] ; 0x44 8031518: e00f b.n 803153a } break; case 13: /* ifInDiscarts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifindiscards; 803151a: 9b01 ldr r3, [sp, #4] 803151c: 6c9b ldr r3, [r3, #72] ; 0x48 803151e: e00c b.n 803153a } break; case 16: /* ifOutOctets */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifoutoctets; 8031520: 9b01 ldr r3, [sp, #4] 8031522: 6cdb ldr r3, [r3, #76] ; 0x4c 8031524: e009 b.n 803153a } break; case 17: /* ifOutUcastPkts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifoutucastpkts; 8031526: 9b01 ldr r3, [sp, #4] 8031528: 6d1b ldr r3, [r3, #80] ; 0x50 803152a: e006 b.n 803153a } break; case 18: /* ifOutNUcastPkts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifoutnucastpkts; 803152c: 9b01 ldr r3, [sp, #4] 803152e: 6d5b ldr r3, [r3, #84] ; 0x54 8031530: e003 b.n 803153a } break; case 19: /* ifOutDiscarts */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = netif->ifoutdiscards; 8031532: 9b01 ldr r3, [sp, #4] 8031534: 6d9b ldr r3, [r3, #88] ; 0x58 8031536: e000 b.n 803153a break; case 21: /* ifOutQLen */ /** @todo figure out if this must be 0 (no queue) or 1? */ { u32_t *uint_ptr = (u32_t*)value; *uint_ptr = 0; 8031538: 2300 movs r3, #0 803153a: 6023 str r3, [r4, #0] } break; 803153c: e005 b.n 803154a case 22: /* ifSpecific */ objectidncpy((s32_t*)value, (s32_t*)ifspecific.id, (u8_t)(len / sizeof(s32_t))); 803153e: 4620 mov r0, r4 8031540: 4902 ldr r1, [pc, #8] ; (803154c ) 8031542: f3c5 0287 ubfx r2, r5, #2, #8 8031546: f7ff ff89 bl 803145c break; }; } 803154a: bd7c pop {r2, r3, r4, r5, r6, pc} 803154c: 0804010c .word 0x0804010c 08031550 : } } static void ip_rteentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031550: b5f7 push {r0, r1, r2, r4, r5, r6, r7, lr} struct netif *netif; ip_addr_t dest; s32_t *ident; u8_t id; ident = od->id_inst_ptr; 8031552: 6885 ldr r5, [r0, #8] } } static void ip_rteentry_get_value(struct obj_def *od, u16_t len, void *value) { 8031554: 460f mov r7, r1 ip_addr_t dest; s32_t *ident; u8_t id; ident = od->id_inst_ptr; snmp_oidtoip(&ident[1], &dest); 8031556: 1d28 adds r0, r5, #4 8031558: a901 add r1, sp, #4 } } static void ip_rteentry_get_value(struct obj_def *od, u16_t len, void *value) { 803155a: 4614 mov r4, r2 ip_addr_t dest; s32_t *ident; u8_t id; ident = od->id_inst_ptr; snmp_oidtoip(&ident[1], &dest); 803155c: f000 fd44 bl 8031fe8 if (ip_addr_isany(&dest)) 8031560: 9b01 ldr r3, [sp, #4] 8031562: b91b cbnz r3, 803156c { /* ip_route() uses default netif for default route */ netif = netif_default; 8031564: 4a23 ldr r2, [pc, #140] ; (80315f4 ) 8031566: 6810 ldr r0, [r2, #0] !ip_addr_netcmp(&dest, &(netif->ip_addr), &(netif->netmask)) ) { netif = netif->next; } } if (netif != NULL) 8031568: b960 cbnz r0, 8031584 803156a: e041 b.n 80315f0 netif = netif_default; } else { /* not using ip_route(), need exact match! */ netif = netif_list; 803156c: 4a22 ldr r2, [pc, #136] ; (80315f8 ) 803156e: 6810 ldr r0, [r2, #0] while ((netif != NULL) && 8031570: e000 b.n 8031574 !ip_addr_netcmp(&dest, &(netif->ip_addr), &(netif->netmask)) ) { netif = netif->next; 8031572: 6800 ldr r0, [r0, #0] } else { /* not using ip_route(), need exact match! */ netif = netif_list; while ((netif != NULL) && 8031574: 2800 cmp r0, #0 8031576: d03b beq.n 80315f0 !ip_addr_netcmp(&dest, &(netif->ip_addr), &(netif->netmask)) ) 8031578: 6846 ldr r6, [r0, #4] 803157a: ea83 0206 eor.w r2, r3, r6 803157e: 6886 ldr r6, [r0, #8] } else { /* not using ip_route(), need exact match! */ netif = netif_list; while ((netif != NULL) && 8031580: 4232 tst r2, r6 8031582: d1f6 bne.n 8031572 } if (netif != NULL) { LWIP_ASSERT("invalid id", (ident[0] >= 0) && (ident[0] <= 0xff)); id = (u8_t)ident[0]; switch (id) 8031584: 782d ldrb r5, [r5, #0] 8031586: 3d01 subs r5, #1 8031588: 2d0c cmp r5, #12 803158a: d831 bhi.n 80315f0 803158c: e8df f005 tbb [pc, r5] 8031590: 14110d07 .word 0x14110d07 8031594: 1c171414 .word 0x1c171414 8031598: 14252321 .word 0x14252321 803159c: 2a .byte 0x2a 803159d: 00 .byte 0x00 { case 1: /* ipRouteDest */ { ip_addr_t *dst = (ip_addr_t*)value; if (ip_addr_isany(&dest)) 803159e: b903 cbnz r3, 80315a2 80315a0: e01e b.n 80315e0 ip_addr_set_zero(dst); } else { /* netifs have netaddress dest */ ip_addr_get_network(dst, &netif->ip_addr, &netif->netmask); 80315a2: 6882 ldr r2, [r0, #8] 80315a4: 6843 ldr r3, [r0, #4] 80315a6: 4013 ands r3, r2 80315a8: e01a b.n 80315e0 break; case 2: /* ipRouteIfIndex */ { s32_t *sint_ptr = (s32_t*)value; snmp_netiftoifindex(netif, sint_ptr); 80315aa: 4621 mov r1, r4 80315ac: f000 fd0c bl 8031fc8 } break; 80315b0: e01e b.n 80315f0 case 3: /* ipRouteMetric1 */ { s32_t *sint_ptr = (s32_t*)value; if (ip_addr_isany(&dest)) 80315b2: b983 cbnz r3, 80315d6 { /* default rte has metric 1 */ *sint_ptr = 1; 80315b4: 2301 movs r3, #1 80315b6: e013 b.n 80315e0 case 6: /* ipRouteMetric4 */ case 12: /* ipRouteMetric5 */ { s32_t *sint_ptr = (s32_t*)value; /* not used */ *sint_ptr = -1; 80315b8: f04f 33ff mov.w r3, #4294967295 80315bc: e010 b.n 80315e0 break; case 7: /* ipRouteNextHop */ { ip_addr_t *dst = (ip_addr_t*)value; if (ip_addr_isany(&dest)) 80315be: b90b cbnz r3, 80315c4 { /* default rte: gateway */ *dst = netif->gw; 80315c0: 68c3 ldr r3, [r0, #12] 80315c2: e00d b.n 80315e0 } else { /* other rtes: netif ip_addr */ *dst = netif->ip_addr; 80315c4: 6843 ldr r3, [r0, #4] 80315c6: e00b b.n 80315e0 break; case 8: /* ipRouteType */ { s32_t *sint_ptr = (s32_t*)value; if (ip_addr_isany(&dest)) 80315c8: b90b cbnz r3, 80315ce { /* default rte is indirect */ *sint_ptr = 4; 80315ca: 2304 movs r3, #4 80315cc: e008 b.n 80315e0 } else { /* other rtes are direct */ *sint_ptr = 3; 80315ce: 2303 movs r3, #3 80315d0: e006 b.n 80315e0 break; case 9: /* ipRouteProto */ { s32_t *sint_ptr = (s32_t*)value; /* locally defined routes */ *sint_ptr = 2; 80315d2: 2302 movs r3, #2 80315d4: e004 b.n 80315e0 case 10: /* ipRouteAge */ { s32_t *sint_ptr = (s32_t*)value; /** @todo (sysuptime - timestamp last change) / 100 @see snmp_insert_iprteidx_tree() */ *sint_ptr = 0; 80315d6: 2300 movs r3, #0 80315d8: e002 b.n 80315e0 break; case 11: /* ipRouteMask */ { ip_addr_t *dst = (ip_addr_t*)value; if (ip_addr_isany(&dest)) 80315da: b903 cbnz r3, 80315de 80315dc: e000 b.n 80315e0 ip_addr_set_zero(dst); } else { /* other rtes use netmask */ *dst = netif->netmask; 80315de: 6883 ldr r3, [r0, #8] 80315e0: 6023 str r3, [r4, #0] 80315e2: e005 b.n 80315f0 } } break; case 13: /* ipRouteInfo */ objectidncpy((s32_t*)value, (s32_t*)iprouteinfo.id, (u8_t)(len / sizeof(s32_t))); 80315e4: 4620 mov r0, r4 80315e6: 4905 ldr r1, [pc, #20] ; (80315fc ) 80315e8: f3c7 0287 ubfx r2, r7, #2, #8 80315ec: f7ff ff36 bl 803145c break; } } } 80315f0: bdfe pop {r1, r2, r3, r4, r5, r6, r7, pc} 80315f2: bf00 nop 80315f4: 20010fd4 .word 0x20010fd4 80315f8: 20010fd0 .word 0x20010fd0 80315fc: 0803ff20 .word 0x0803ff20 08031600 : * @param str if non-NULL then copy str pointer * @param len points to string length, excluding zero terminator */ void snmp_set_sysdesr(u8_t *str, u8_t *len) { if (str != NULL) 8031600: b118 cbz r0, 803160a { sysdescr_ptr = str; 8031602: 4b02 ldr r3, [pc, #8] ; (803160c ) 8031604: 6018 str r0, [r3, #0] sysdescr_len_ptr = len; 8031606: 4b02 ldr r3, [pc, #8] ; (8031610 ) 8031608: 6019 str r1, [r3, #0] 803160a: 4770 bx lr 803160c: 20001790 .word 0x20001790 8031610: 2000180c .word 0x2000180c 08031614 : { sysuptime+=value; } void snmp_get_sysuptime(u32_t *value) { 8031614: b510 push {r4, lr} 8031616: 4604 mov r4, r0 SNMP_GET_SYSUPTIME(sysuptime); 8031618: f003 f975 bl 8034906 803161c: 230a movs r3, #10 803161e: 4a03 ldr r2, [pc, #12] ; (803162c ) 8031620: fbb0 f0f3 udiv r0, r0, r3 8031624: 6010 str r0, [r2, #0] *value = sysuptime; 8031626: 6020 str r0, [r4, #0] 8031628: bd10 pop {r4, pc} 803162a: bf00 nop 803162c: 2000e210 .word 0x2000e210 08031630 : * @param len return value space (in bytes) * @param value points to (varbind) space to copy value into. */ static void system_get_value(struct obj_def *od, u16_t len, void *value) { 8031630: 4613 mov r3, r2 u8_t id; LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; 8031632: 6882 ldr r2, [r0, #8] switch (id) 8031634: 7812 ldrb r2, [r2, #0] 8031636: 3a01 subs r2, #1 * @param len return value space (in bytes) * @param value points to (varbind) space to copy value into. */ static void system_get_value(struct obj_def *od, u16_t len, void *value) { 8031638: b510 push {r4, lr} 803163a: 460c mov r4, r1 u8_t id; LWIP_ASSERT("invalid id", (od->id_inst_ptr[0] >= 0) && (od->id_inst_ptr[0] <= 0xff)); id = (u8_t)od->id_inst_ptr[0]; switch (id) 803163c: 2a06 cmp r2, #6 803163e: d825 bhi.n 803168c 8031640: e8df f002 tbb [pc, r2] 8031644: 140f0704 .word 0x140f0704 8031648: 1a17 .short 0x1a17 803164a: 22 .byte 0x22 803164b: 00 .byte 0x00 { case 1: /* sysDescr */ ocstrncpy((u8_t*)value, sysdescr_ptr, len); 803164c: 4618 mov r0, r3 803164e: 4b10 ldr r3, [pc, #64] ; (8031690 ) 8031650: e014 b.n 803167c break; case 2: /* sysObjectID */ objectidncpy((s32_t*)value, (s32_t*)sysobjid.id, (u8_t)(len / sizeof(s32_t))); 8031652: 4910 ldr r1, [pc, #64] ; (8031694 ) 8031654: 4618 mov r0, r3 8031656: f3c4 0287 ubfx r2, r4, #2, #8 s32_t *sint_ptr = (s32_t*)value; *sint_ptr = sysservices; } break; }; } 803165a: e8bd 4010 ldmia.w sp!, {r4, lr} { case 1: /* sysDescr */ ocstrncpy((u8_t*)value, sysdescr_ptr, len); break; case 2: /* sysObjectID */ objectidncpy((s32_t*)value, (s32_t*)sysobjid.id, (u8_t)(len / sizeof(s32_t))); 803165e: f7ff befd b.w 803145c break; case 3: /* sysUpTime */ { snmp_get_sysuptime((u32_t*)value); 8031662: 4618 mov r0, r3 s32_t *sint_ptr = (s32_t*)value; *sint_ptr = sysservices; } break; }; } 8031664: e8bd 4010 ldmia.w sp!, {r4, lr} case 2: /* sysObjectID */ objectidncpy((s32_t*)value, (s32_t*)sysobjid.id, (u8_t)(len / sizeof(s32_t))); break; case 3: /* sysUpTime */ { snmp_get_sysuptime((u32_t*)value); 8031668: f7ff bfd4 b.w 8031614 } break; case 4: /* sysContact */ ocstrncpy((u8_t*)value, syscontact_ptr, len); 803166c: 4618 mov r0, r3 803166e: 4b0a ldr r3, [pc, #40] ; (8031698 ) 8031670: e004 b.n 803167c break; case 5: /* sysName */ ocstrncpy((u8_t*)value, sysname_ptr, len); 8031672: 4618 mov r0, r3 8031674: 4b09 ldr r3, [pc, #36] ; (803169c ) 8031676: e001 b.n 803167c break; case 6: /* sysLocation */ ocstrncpy((u8_t*)value, syslocation_ptr, len); 8031678: 4618 mov r0, r3 803167a: 4b09 ldr r3, [pc, #36] ; (80316a0 ) 803167c: 6819 ldr r1, [r3, #0] 803167e: 4622 mov r2, r4 s32_t *sint_ptr = (s32_t*)value; *sint_ptr = sysservices; } break; }; } 8031680: e8bd 4010 ldmia.w sp!, {r4, lr} break; case 5: /* sysName */ ocstrncpy((u8_t*)value, sysname_ptr, len); break; case 6: /* sysLocation */ ocstrncpy((u8_t*)value, syslocation_ptr, len); 8031684: f7ff beb2 b.w 80313ec break; case 7: /* sysServices */ { s32_t *sint_ptr = (s32_t*)value; *sint_ptr = sysservices; 8031688: 2248 movs r2, #72 ; 0x48 803168a: 601a str r2, [r3, #0] 803168c: bd10 pop {r4, pc} 803168e: bf00 nop 8031690: 20001790 .word 0x20001790 8031694: 200016c0 .word 0x200016c0 8031698: 200017e4 .word 0x200017e4 803169c: 20001770 .word 0x20001770 80316a0: 200018fc .word 0x200018fc 080316a4 : * @param ocstr if non-NULL then copy str pointer * @param ocstrlen points to string length, excluding zero terminator */ void snmp_set_syscontact(u8_t *ocstr, u8_t *ocstrlen) { if (ocstr != NULL) 80316a4: b118 cbz r0, 80316ae { syscontact_ptr = ocstr; 80316a6: 4b02 ldr r3, [pc, #8] ; (80316b0 ) 80316a8: 6018 str r0, [r3, #0] syscontact_len_ptr = ocstrlen; 80316aa: 4b02 ldr r3, [pc, #8] ; (80316b4 ) 80316ac: 6019 str r1, [r3, #0] 80316ae: 4770 bx lr 80316b0: 200017e4 .word 0x200017e4 80316b4: 20001668 .word 0x20001668 080316b8 : * @param ocstr if non-NULL then copy str pointer * @param ocstrlen points to string length, excluding zero terminator */ void snmp_set_syslocation(u8_t *ocstr, u8_t *ocstrlen) { if (ocstr != NULL) 80316b8: b118 cbz r0, 80316c2 { syslocation_ptr = ocstr; 80316ba: 4b02 ldr r3, [pc, #8] ; (80316c4 ) 80316bc: 6018 str r0, [r3, #0] syslocation_len_ptr = ocstrlen; 80316be: 4b02 ldr r3, [pc, #8] ; (80316c8 ) 80316c0: 6019 str r1, [r3, #0] 80316c2: 4770 bx lr 80316c4: 200018fc .word 0x200018fc 80316c8: 20001850 .word 0x20001850 080316cc : { (ni->ifoutdiscards)++; } void snmp_inc_iflist(void) { 80316cc: b507 push {r0, r1, r2, lr} struct mib_list_node *if_node = NULL; snmp_mib_node_insert(&iflist_root, iflist_root.count + 1, &if_node); 80316ce: 4806 ldr r0, [pc, #24] ; (80316e8 ) (ni->ifoutdiscards)++; } void snmp_inc_iflist(void) { struct mib_list_node *if_node = NULL; 80316d0: aa02 add r2, sp, #8 snmp_mib_node_insert(&iflist_root, iflist_root.count + 1, &if_node); 80316d2: 8b81 ldrh r1, [r0, #28] (ni->ifoutdiscards)++; } void snmp_inc_iflist(void) { struct mib_list_node *if_node = NULL; 80316d4: 2300 movs r3, #0 80316d6: f842 3d04 str.w r3, [r2, #-4]! snmp_mib_node_insert(&iflist_root, iflist_root.count + 1, &if_node); 80316da: 3101 adds r1, #1 80316dc: f000 fccc bl 8032078 /* enable getnext traversal on filled table */ iftable.maxlength = 1; 80316e0: 4b02 ldr r3, [pc, #8] ; (80316ec ) 80316e2: 2201 movs r2, #1 80316e4: 825a strh r2, [r3, #18] } 80316e6: bd0e pop {r1, r2, r3, pc} 80316e8: 2000169c .word 0x2000169c 80316ec: 20001814 .word 0x20001814 080316f0 : /** * Inserts ARP table indexes (.xIfIndex.xNetAddress) * into arp table index trees (both atTable and ipNetToMediaTable). */ void snmp_insert_arpidx_tree(struct netif *ni, ip_addr_t *ip) { 80316f0: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 80316f4: b086 sub sp, #24 80316f6: 460c mov r4, r1 struct mib_list_node *at_node; s32_t arpidx[5]; u8_t level, tree; LWIP_ASSERT("ni != NULL", ni != NULL); snmp_netiftoifindex(ni, &arpidx[0]); 80316f8: a901 add r1, sp, #4 80316fa: f000 fc65 bl 8031fc8 snmp_iptooid(ip, &arpidx[1]); 80316fe: 4620 mov r0, r4 8031700: a902 add r1, sp, #8 8031702: f000 fc7e bl 8032002 for (tree = 0; tree < 2; tree++) { if (tree == 0) { at_rn = &arptree_root; 8031706: f8df 80a0 ldr.w r8, [pc, #160] ; 80317a8 LWIP_ASSERT("ni != NULL", ni != NULL); snmp_netiftoifindex(ni, &arpidx[0]); snmp_iptooid(ip, &arpidx[1]); for (tree = 0; tree < 2; tree++) 803170a: 2500 movs r5, #0 { if (tree == 0) { at_rn = &arptree_root; 803170c: 4c1f ldr r4, [pc, #124] ; (803178c ) else { at_rn->get_object_def = ip_ntomentry_get_object_def; at_rn->get_value = ip_ntomentry_get_value; } at_rn->set_test = noleafs_set_test; 803170e: f8df 909c ldr.w r9, [pc, #156] ; 80317ac at_rn->set_value = noleafs_set_value; 8031712: f8df a09c ldr.w sl, [pc, #156] ; 80317b0 for (tree = 0; tree < 2; tree++) { if (tree == 0) { at_rn = &arptree_root; 8031716: 2d00 cmp r5, #0 8031718: bf18 it ne 803171a: 4644 movne r4, r8 } else { at_rn = &ipntomtree_root; 803171c: 2600 movs r6, #0 } for (level = 0; level < 5; level++) { at_node = NULL; 803171e: 2300 movs r3, #0 8031720: 9300 str r3, [sp, #0] snmp_mib_node_insert(at_rn, arpidx[level], &at_node); 8031722: ab01 add r3, sp, #4 8031724: 4620 mov r0, r4 8031726: f853 1026 ldr.w r1, [r3, r6, lsl #2] 803172a: aa00 add r2, sp, #0 803172c: b2f7 uxtb r7, r6 803172e: f000 fca3 bl 8032078 if ((level != 4) && (at_node != NULL)) 8031732: 2f04 cmp r7, #4 8031734: d01d beq.n 8031772 8031736: 9b00 ldr r3, [sp, #0] 8031738: b1db cbz r3, 8031772 { if (at_node->nptr == NULL) 803173a: 68dc ldr r4, [r3, #12] 803173c: b9cc cbnz r4, 8031772 { at_rn = snmp_mib_lrn_alloc(); 803173e: f000 fc79 bl 8032034 at_node->nptr = (struct mib_node*)at_rn; 8031742: 9b00 ldr r3, [sp, #0] snmp_mib_node_insert(at_rn, arpidx[level], &at_node); if ((level != 4) && (at_node != NULL)) { if (at_node->nptr == NULL) { at_rn = snmp_mib_lrn_alloc(); 8031744: 4604 mov r4, r0 at_node->nptr = (struct mib_node*)at_rn; 8031746: 60d8 str r0, [r3, #12] if (at_rn != NULL) 8031748: b920 cbnz r0, 8031754 LWIP_ASSERT("ni != NULL", ni != NULL); snmp_netiftoifindex(ni, &arpidx[0]); snmp_iptooid(ip, &arpidx[1]); for (tree = 0; tree < 2; tree++) 803174a: 3501 adds r5, #1 803174c: b2ed uxtb r5, r5 803174e: 2d02 cmp r5, #2 8031750: d1dc bne.n 803170c 8031752: e012 b.n 803177a { at_rn = snmp_mib_lrn_alloc(); at_node->nptr = (struct mib_node*)at_rn; if (at_rn != NULL) { if (level == 3) 8031754: 2f03 cmp r7, #3 8031756: d10c bne.n 8031772 { if (tree == 0) 8031758: b91d cbnz r5, 8031762 { at_rn->get_object_def = atentry_get_object_def; 803175a: 4b0d ldr r3, [pc, #52] ; (8031790 ) 803175c: 6003 str r3, [r0, #0] at_rn->get_value = atentry_get_value; 803175e: 4b0d ldr r3, [pc, #52] ; (8031794 ) 8031760: e002 b.n 8031768 } else { at_rn->get_object_def = ip_ntomentry_get_object_def; 8031762: 4b0d ldr r3, [pc, #52] ; (8031798 ) 8031764: 6003 str r3, [r0, #0] at_rn->get_value = ip_ntomentry_get_value; 8031766: 4b0d ldr r3, [pc, #52] ; (803179c ) 8031768: 6063 str r3, [r4, #4] } at_rn->set_test = noleafs_set_test; 803176a: f8c4 9008 str.w r9, [r4, #8] at_rn->set_value = noleafs_set_value; 803176e: f8c4 a00c str.w sl, [r4, #12] 8031772: 3601 adds r6, #1 } else { at_rn = &ipntomtree_root; } for (level = 0; level < 5; level++) 8031774: 2e05 cmp r6, #5 8031776: d1d2 bne.n 803171e 8031778: e7e7 b.n 803174a } } } } /* enable getnext traversal on filled tables */ at.maxlength = 1; 803177a: 4a09 ldr r2, [pc, #36] ; (80317a0 ) 803177c: 2301 movs r3, #1 803177e: 8253 strh r3, [r2, #18] ipntomtable.maxlength = 1; 8031780: 4a08 ldr r2, [pc, #32] ; (80317a4 ) 8031782: 8253 strh r3, [r2, #18] } 8031784: b006 add sp, #24 8031786: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 803178a: bf00 nop 803178c: 200017e8 .word 0x200017e8 8031790: 080311b1 .word 0x080311b1 8031794: 08031109 .word 0x08031109 8031798: 08031295 .word 0x08031295 803179c: 080310ad .word 0x080310ad 80317a0: 2000160c .word 0x2000160c 80317a4: 200015f0 .word 0x200015f0 80317a8: 200018d8 .word 0x200018d8 80317ac: 080309cb .word 0x080309cb 80317b0: 080309cf .word 0x080309cf 080317b4 : /** * Removes ARP table indexes (.xIfIndex.xNetAddress) * from arp table index trees. */ void snmp_delete_arpidx_tree(struct netif *ni, ip_addr_t *ip) { 80317b4: b5f0 push {r4, r5, r6, r7, lr} 80317b6: b091 sub sp, #68 ; 0x44 80317b8: 460c mov r4, r1 struct mib_list_rootnode *at_rn, *next, *del_rn[5]; struct mib_list_node *at_n, *del_n[5]; s32_t arpidx[5]; u8_t fc, tree, level, del_cnt; snmp_netiftoifindex(ni, &arpidx[0]); 80317ba: a90b add r1, sp, #44 ; 0x2c 80317bc: f000 fc04 bl 8031fc8 snmp_iptooid(ip, &arpidx[1]); 80317c0: 4620 mov r0, r4 80317c2: a90c add r1, sp, #48 ; 0x30 80317c4: f000 fc1d bl 8032002 for (tree = 0; tree < 2; tree++) 80317c8: 2700 movs r7, #0 { /* mark nodes for deletion */ if (tree == 0) { at_rn = &arptree_root; 80317ca: 4b26 ldr r3, [pc, #152] ; (8031864 ) 80317cc: 4d26 ldr r5, [pc, #152] ; (8031868 ) } else { at_rn = &ipntomtree_root; 80317ce: 2600 movs r6, #0 for (tree = 0; tree < 2; tree++) { /* mark nodes for deletion */ if (tree == 0) { at_rn = &arptree_root; 80317d0: 2f00 cmp r7, #0 80317d2: bf08 it eq 80317d4: 461d moveq r5, r3 } else { at_rn = &ipntomtree_root; 80317d6: 4634 mov r4, r6 } level = 0; del_cnt = 0; while ((level < 5) && (at_rn != NULL)) { fc = snmp_mib_node_find(at_rn, arpidx[level], &at_n); 80317d8: ab0b add r3, sp, #44 ; 0x2c 80317da: 4628 mov r0, r5 80317dc: 58f1 ldr r1, [r6, r3] 80317de: aa00 add r2, sp, #0 80317e0: f000 fc85 bl 80320ee 80317e4: b2c0 uxtb r0, r0 if (fc == 0) 80317e6: b198 cbz r0, 8031810 { /* arpidx[level] does not exist */ del_cnt = 0; at_rn = NULL; } else if (fc == 1) 80317e8: 2801 cmp r0, #1 80317ea: d10b bne.n 8031804 { del_rn[del_cnt] = at_rn; 80317ec: ab10 add r3, sp, #64 ; 0x40 80317ee: eb03 0284 add.w r2, r3, r4, lsl #2 del_n[del_cnt] = at_n; 80317f2: 9b00 ldr r3, [sp, #0] del_cnt = 0; at_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = at_rn; 80317f4: f842 5c3c str.w r5, [r2, #-60] del_n[del_cnt] = at_n; del_cnt++; 80317f8: 3401 adds r4, #1 at_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = at_rn; del_n[del_cnt] = at_n; 80317fa: f842 3c28 str.w r3, [r2, #-40] del_cnt++; 80317fe: b2e4 uxtb r4, r4 at_rn = (struct mib_list_rootnode*)(at_n->nptr); 8031800: 68dd ldr r5, [r3, #12] 8031802: e007 b.n 8031814 } else if (fc == 2) 8031804: 2802 cmp r0, #2 8031806: d105 bne.n 8031814 { /* reset delete (2 or more childs) */ del_cnt = 0; at_rn = (struct mib_list_rootnode*)(at_n->nptr); 8031808: 9b00 ldr r3, [sp, #0] at_rn = (struct mib_list_rootnode*)(at_n->nptr); } else if (fc == 2) { /* reset delete (2 or more childs) */ del_cnt = 0; 803180a: 2400 movs r4, #0 at_rn = (struct mib_list_rootnode*)(at_n->nptr); 803180c: 68dd ldr r5, [r3, #12] 803180e: e001 b.n 8031814 { fc = snmp_mib_node_find(at_rn, arpidx[level], &at_n); if (fc == 0) { /* arpidx[level] does not exist */ del_cnt = 0; 8031810: 4604 mov r4, r0 at_rn = NULL; 8031812: 4605 mov r5, r0 8031814: 3604 adds r6, #4 { at_rn = &ipntomtree_root; } level = 0; del_cnt = 0; while ((level < 5) && (at_rn != NULL)) 8031816: 2e14 cmp r6, #20 8031818: d011 beq.n 803183e 803181a: 2d00 cmp r5, #0 803181c: d1dc bne.n 80317d8 803181e: e00e b.n 803183e level++; } /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; 8031820: 3c01 subs r4, #1 8031822: b2e4 uxtb r4, r4 at_rn = del_rn[del_cnt]; 8031824: aa10 add r2, sp, #64 ; 0x40 8031826: eb02 0384 add.w r3, r2, r4, lsl #2 at_n = del_n[del_cnt]; 803182a: f853 1c28 ldr.w r1, [r3, #-40] /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; at_rn = del_rn[del_cnt]; 803182e: f853 0c3c ldr.w r0, [r3, #-60] at_n = del_n[del_cnt]; 8031832: 9100 str r1, [sp, #0] next = snmp_mib_node_delete(at_rn, at_n); 8031834: f000 fc75 bl 8032122 if (next != NULL) 8031838: b108 cbz r0, 803183e { LWIP_ASSERT("next_count == 0",next->count == 0); snmp_mib_lrn_free(next); 803183a: f000 fc19 bl 8032070 at_rn = (struct mib_list_rootnode*)(at_n->nptr); } level++; } /* delete marked index nodes */ while (del_cnt > 0) 803183e: 2c00 cmp r4, #0 8031840: d1ee bne.n 8031820 u8_t fc, tree, level, del_cnt; snmp_netiftoifindex(ni, &arpidx[0]); snmp_iptooid(ip, &arpidx[1]); for (tree = 0; tree < 2; tree++) 8031842: 3701 adds r7, #1 8031844: b2ff uxtb r7, r7 8031846: 2f02 cmp r7, #2 8031848: d1bf bne.n 80317ca snmp_mib_lrn_free(next); } } } /* disable getnext traversal on empty tables */ if(arptree_root.count == 0) at.maxlength = 0; 803184a: 4b06 ldr r3, [pc, #24] ; (8031864 ) 803184c: 8b9b ldrh r3, [r3, #28] 803184e: b90b cbnz r3, 8031854 8031850: 4b06 ldr r3, [pc, #24] ; (803186c ) 8031852: 825c strh r4, [r3, #18] if(ipntomtree_root.count == 0) ipntomtable.maxlength = 0; 8031854: 4b04 ldr r3, [pc, #16] ; (8031868 ) 8031856: 8b9b ldrh r3, [r3, #28] 8031858: b90b cbnz r3, 803185e 803185a: 4a05 ldr r2, [pc, #20] ; (8031870 ) 803185c: 8253 strh r3, [r2, #18] } 803185e: b011 add sp, #68 ; 0x44 8031860: bdf0 pop {r4, r5, r6, r7, pc} 8031862: bf00 nop 8031864: 200017e8 .word 0x200017e8 8031868: 200018d8 .word 0x200018d8 803186c: 2000160c .word 0x2000160c 8031870: 200015f0 .word 0x200015f0 08031874 : void snmp_inc_ipinreceives(void) { ipinreceives++; 8031874: 4b02 ldr r3, [pc, #8] ; (8031880 ) 8031876: 681a ldr r2, [r3, #0] 8031878: 3201 adds r2, #1 803187a: 601a str r2, [r3, #0] 803187c: 4770 bx lr 803187e: bf00 nop 8031880: 2000e1e4 .word 0x2000e1e4 08031884 : } void snmp_inc_ipinhdrerrors(void) { ipinhdrerrors++; 8031884: 4b02 ldr r3, [pc, #8] ; (8031890 ) 8031886: 681a ldr r2, [r3, #0] 8031888: 3201 adds r2, #1 803188a: 601a str r2, [r3, #0] 803188c: 4770 bx lr 803188e: bf00 nop 8031890: 2000e16c .word 0x2000e16c 08031894 : } void snmp_inc_ipinaddrerrors(void) { ipinaddrerrors++; 8031894: 4b02 ldr r3, [pc, #8] ; (80318a0 ) 8031896: 681a ldr r2, [r3, #0] 8031898: 3201 adds r2, #1 803189a: 601a str r2, [r3, #0] 803189c: 4770 bx lr 803189e: bf00 nop 80318a0: 2000e150 .word 0x2000e150 080318a4 : ipforwdatagrams++; } void snmp_inc_ipinunknownprotos(void) { ipinunknownprotos++; 80318a4: 4b02 ldr r3, [pc, #8] ; (80318b0 ) 80318a6: 681a ldr r2, [r3, #0] 80318a8: 3201 adds r2, #1 80318aa: 601a str r2, [r3, #0] 80318ac: 4770 bx lr 80318ae: bf00 nop 80318b0: 2000e1ac .word 0x2000e1ac 080318b4 : } void snmp_inc_ipindiscards(void) { ipindiscards++; 80318b4: 4b02 ldr r3, [pc, #8] ; (80318c0 ) 80318b6: 681a ldr r2, [r3, #0] 80318b8: 3201 adds r2, #1 80318ba: 601a str r2, [r3, #0] 80318bc: 4770 bx lr 80318be: bf00 nop 80318c0: 2000e238 .word 0x2000e238 080318c4 : } void snmp_inc_ipindelivers(void) { ipindelivers++; 80318c4: 4b02 ldr r3, [pc, #8] ; (80318d0 ) 80318c6: 681a ldr r2, [r3, #0] 80318c8: 3201 adds r2, #1 80318ca: 601a str r2, [r3, #0] 80318cc: 4770 bx lr 80318ce: bf00 nop 80318d0: 2000e270 .word 0x2000e270 080318d4 : } void snmp_inc_ipoutrequests(void) { ipoutrequests++; 80318d4: 4b02 ldr r3, [pc, #8] ; (80318e0 ) 80318d6: 681a ldr r2, [r3, #0] 80318d8: 3201 adds r2, #1 80318da: 601a str r2, [r3, #0] 80318dc: 4770 bx lr 80318de: bf00 nop 80318e0: 2000e258 .word 0x2000e258 080318e4 : } void snmp_inc_ipoutdiscards(void) { ipoutdiscards++; 80318e4: 4b02 ldr r3, [pc, #8] ; (80318f0 ) 80318e6: 681a ldr r2, [r3, #0] 80318e8: 3201 adds r2, #1 80318ea: 601a str r2, [r3, #0] 80318ec: 4770 bx lr 80318ee: bf00 nop 80318f0: 2000e1fc .word 0x2000e1fc 080318f4 : } void snmp_inc_ipoutnoroutes(void) { ipoutnoroutes++; 80318f4: 4b02 ldr r3, [pc, #8] ; (8031900 ) 80318f6: 681a ldr r2, [r3, #0] 80318f8: 3201 adds r2, #1 80318fa: 601a str r2, [r3, #0] 80318fc: 4770 bx lr 80318fe: bf00 nop 8031900: 2000e27c .word 0x2000e27c 08031904 : /** * Inserts ipAddrTable indexes (.ipAdEntAddr) * into index tree. */ void snmp_insert_ipaddridx_tree(struct netif *ni) { 8031904: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8031908: b086 sub sp, #24 struct mib_list_node *ipa_node; s32_t ipaddridx[4]; u8_t level; LWIP_ASSERT("ni != NULL", ni != NULL); snmp_iptooid(&ni->ip_addr, &ipaddridx[0]); 803190a: 3004 adds r0, #4 803190c: a902 add r1, sp, #8 803190e: f000 fb78 bl 8032002 level = 0; ipa_rn = &ipaddrtree_root; 8031912: 4c17 ldr r4, [pc, #92] ; (8031970 ) ipa_node->nptr = (struct mib_node*)ipa_rn; if (ipa_rn != NULL) { if (level == 2) { ipa_rn->get_object_def = ip_addrentry_get_object_def; 8031914: 4f17 ldr r7, [pc, #92] ; (8031974 ) ipa_rn->get_value = ip_addrentry_get_value; 8031916: f8df 806c ldr.w r8, [pc, #108] ; 8031984 struct mib_list_node *ipa_node; s32_t ipaddridx[4]; u8_t level; LWIP_ASSERT("ni != NULL", ni != NULL); snmp_iptooid(&ni->ip_addr, &ipaddridx[0]); 803191a: 2500 movs r5, #0 level = 0; ipa_rn = &ipaddrtree_root; while (level < 4) { ipa_node = NULL; 803191c: 2300 movs r3, #0 803191e: 9301 str r3, [sp, #4] snmp_mib_node_insert(ipa_rn, ipaddridx[level], &ipa_node); 8031920: ab02 add r3, sp, #8 8031922: 4620 mov r0, r4 8031924: f853 1025 ldr.w r1, [r3, r5, lsl #2] 8031928: aa01 add r2, sp, #4 803192a: b2ee uxtb r6, r5 803192c: f000 fba4 bl 8032078 if ((level != 3) && (ipa_node != NULL)) 8031930: 2e03 cmp r6, #3 8031932: d015 beq.n 8031960 8031934: 9b01 ldr r3, [sp, #4] 8031936: b19b cbz r3, 8031960 { if (ipa_node->nptr == NULL) 8031938: 68dc ldr r4, [r3, #12] 803193a: b98c cbnz r4, 8031960 { ipa_rn = snmp_mib_lrn_alloc(); 803193c: f000 fb7a bl 8032034 ipa_node->nptr = (struct mib_node*)ipa_rn; 8031940: 9b01 ldr r3, [sp, #4] snmp_mib_node_insert(ipa_rn, ipaddridx[level], &ipa_node); if ((level != 3) && (ipa_node != NULL)) { if (ipa_node->nptr == NULL) { ipa_rn = snmp_mib_lrn_alloc(); 8031942: 4604 mov r4, r0 ipa_node->nptr = (struct mib_node*)ipa_rn; 8031944: 60d8 str r0, [r3, #12] if (ipa_rn != NULL) 8031946: b918 cbnz r0, 8031950 } } level++; } /* enable getnext traversal on filled table */ ipaddrtable.maxlength = 1; 8031948: 4b0b ldr r3, [pc, #44] ; (8031978 ) 803194a: 2201 movs r2, #1 803194c: 825a strh r2, [r3, #18] 803194e: e00b b.n 8031968 { ipa_rn = snmp_mib_lrn_alloc(); ipa_node->nptr = (struct mib_node*)ipa_rn; if (ipa_rn != NULL) { if (level == 2) 8031950: 2e02 cmp r6, #2 8031952: d105 bne.n 8031960 { ipa_rn->get_object_def = ip_addrentry_get_object_def; ipa_rn->get_value = ip_addrentry_get_value; ipa_rn->set_test = noleafs_set_test; 8031954: 4b09 ldr r3, [pc, #36] ; (803197c ) if (ipa_rn != NULL) { if (level == 2) { ipa_rn->get_object_def = ip_addrentry_get_object_def; ipa_rn->get_value = ip_addrentry_get_value; 8031956: e880 0180 stmia.w r0, {r7, r8} ipa_rn->set_test = noleafs_set_test; 803195a: 6083 str r3, [r0, #8] ipa_rn->set_value = noleafs_set_value; 803195c: 4b08 ldr r3, [pc, #32] ; (8031980 ) 803195e: 60c3 str r3, [r0, #12] 8031960: 3501 adds r5, #1 LWIP_ASSERT("ni != NULL", ni != NULL); snmp_iptooid(&ni->ip_addr, &ipaddridx[0]); level = 0; ipa_rn = &ipaddrtree_root; while (level < 4) 8031962: 2d04 cmp r5, #4 8031964: d1da bne.n 803191c 8031966: e7ef b.n 8031948 } level++; } /* enable getnext traversal on filled table */ ipaddrtable.maxlength = 1; } 8031968: b006 add sp, #24 803196a: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 803196e: bf00 nop 8031970: 20001744 .word 0x20001744 8031974: 08031251 .word 0x08031251 8031978: 200017c8 .word 0x200017c8 803197c: 080309cb .word 0x080309cb 8031980: 080309cf .word 0x080309cf 8031984: 08031041 .word 0x08031041 08031988 : /** * Removes ipAddrTable indexes (.ipAdEntAddr) * from index tree. */ void snmp_delete_ipaddridx_tree(struct netif *ni) { 8031988: b570 push {r4, r5, r6, lr} 803198a: b08e sub sp, #56 ; 0x38 struct mib_list_node *ipa_n, *del_n[4]; s32_t ipaddridx[4]; u8_t fc, level, del_cnt; LWIP_ASSERT("ni != NULL", ni != NULL); snmp_iptooid(&ni->ip_addr, &ipaddridx[0]); 803198c: 3004 adds r0, #4 803198e: a90a add r1, sp, #40 ; 0x28 8031990: f000 fb37 bl 8032002 8031994: 2600 movs r6, #0 /* mark nodes for deletion */ level = 0; del_cnt = 0; ipa_rn = &ipaddrtree_root; 8031996: 4d1f ldr r5, [pc, #124] ; (8031a14 ) LWIP_ASSERT("ni != NULL", ni != NULL); snmp_iptooid(&ni->ip_addr, &ipaddridx[0]); /* mark nodes for deletion */ level = 0; del_cnt = 0; 8031998: 4634 mov r4, r6 ipa_rn = &ipaddrtree_root; while ((level < 4) && (ipa_rn != NULL)) { fc = snmp_mib_node_find(ipa_rn, ipaddridx[level], &ipa_n); 803199a: ab0a add r3, sp, #40 ; 0x28 803199c: 4628 mov r0, r5 803199e: 58f1 ldr r1, [r6, r3] 80319a0: aa01 add r2, sp, #4 80319a2: f000 fba4 bl 80320ee 80319a6: b2c0 uxtb r0, r0 if (fc == 0) 80319a8: b198 cbz r0, 80319d2 { /* ipaddridx[level] does not exist */ del_cnt = 0; ipa_rn = NULL; } else if (fc == 1) 80319aa: 2801 cmp r0, #1 80319ac: d10b bne.n 80319c6 { del_rn[del_cnt] = ipa_rn; 80319ae: ab0e add r3, sp, #56 ; 0x38 80319b0: eb03 0284 add.w r2, r3, r4, lsl #2 del_n[del_cnt] = ipa_n; 80319b4: 9b01 ldr r3, [sp, #4] del_cnt = 0; ipa_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = ipa_rn; 80319b6: f842 5c30 str.w r5, [r2, #-48] del_n[del_cnt] = ipa_n; del_cnt++; 80319ba: 3401 adds r4, #1 ipa_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = ipa_rn; del_n[del_cnt] = ipa_n; 80319bc: f842 3c20 str.w r3, [r2, #-32] del_cnt++; 80319c0: b2e4 uxtb r4, r4 ipa_rn = (struct mib_list_rootnode*)(ipa_n->nptr); 80319c2: 68dd ldr r5, [r3, #12] 80319c4: e007 b.n 80319d6 } else if (fc == 2) 80319c6: 2802 cmp r0, #2 80319c8: d105 bne.n 80319d6 { /* reset delete (2 or more childs) */ del_cnt = 0; ipa_rn = (struct mib_list_rootnode*)(ipa_n->nptr); 80319ca: 9b01 ldr r3, [sp, #4] ipa_rn = (struct mib_list_rootnode*)(ipa_n->nptr); } else if (fc == 2) { /* reset delete (2 or more childs) */ del_cnt = 0; 80319cc: 2400 movs r4, #0 ipa_rn = (struct mib_list_rootnode*)(ipa_n->nptr); 80319ce: 68dd ldr r5, [r3, #12] 80319d0: e001 b.n 80319d6 { fc = snmp_mib_node_find(ipa_rn, ipaddridx[level], &ipa_n); if (fc == 0) { /* ipaddridx[level] does not exist */ del_cnt = 0; 80319d2: 4604 mov r4, r0 ipa_rn = NULL; 80319d4: 4605 mov r5, r0 /* mark nodes for deletion */ level = 0; del_cnt = 0; ipa_rn = &ipaddrtree_root; while ((level < 4) && (ipa_rn != NULL)) 80319d6: 2e0c cmp r6, #12 80319d8: d012 beq.n 8031a00 80319da: 3604 adds r6, #4 80319dc: 2d00 cmp r5, #0 80319de: d1dc bne.n 803199a 80319e0: e00e b.n 8031a00 level++; } /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; 80319e2: 3c01 subs r4, #1 80319e4: b2e4 uxtb r4, r4 ipa_rn = del_rn[del_cnt]; 80319e6: aa0e add r2, sp, #56 ; 0x38 80319e8: eb02 0384 add.w r3, r2, r4, lsl #2 ipa_n = del_n[del_cnt]; 80319ec: f853 1c20 ldr.w r1, [r3, #-32] /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; ipa_rn = del_rn[del_cnt]; 80319f0: f853 0c30 ldr.w r0, [r3, #-48] ipa_n = del_n[del_cnt]; 80319f4: 9101 str r1, [sp, #4] next = snmp_mib_node_delete(ipa_rn, ipa_n); 80319f6: f000 fb94 bl 8032122 if (next != NULL) 80319fa: b108 cbz r0, 8031a00 { LWIP_ASSERT("next_count == 0",next->count == 0); snmp_mib_lrn_free(next); 80319fc: f000 fb38 bl 8032070 ipa_rn = (struct mib_list_rootnode*)(ipa_n->nptr); } level++; } /* delete marked index nodes */ while (del_cnt > 0) 8031a00: 2c00 cmp r4, #0 8031a02: d1ee bne.n 80319e2 LWIP_ASSERT("next_count == 0",next->count == 0); snmp_mib_lrn_free(next); } } /* disable getnext traversal on empty table */ if (ipaddrtree_root.count == 0) ipaddrtable.maxlength = 0; 8031a04: 4b03 ldr r3, [pc, #12] ; (8031a14 ) 8031a06: 8b9b ldrh r3, [r3, #28] 8031a08: b90b cbnz r3, 8031a0e 8031a0a: 4b03 ldr r3, [pc, #12] ; (8031a18 ) 8031a0c: 825c strh r4, [r3, #18] } 8031a0e: b00e add sp, #56 ; 0x38 8031a10: bd70 pop {r4, r5, r6, pc} 8031a12: bf00 nop 8031a14: 20001744 .word 0x20001744 8031a18: 200017c8 .word 0x200017c8 08031a1c : * * @todo record sysuptime for _this_ route when it is installed * (needed for ipRouteAge) in the netif. */ void snmp_insert_iprteidx_tree(u8_t dflt, struct netif *ni) { 8031a1c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8031a20: b086 sub sp, #24 u8_t insert = 0; ip_addr_t dst; if (dflt != 0) 8031a22: b110 cbz r0, 8031a2a { /* the default route 0.0.0.0 */ ip_addr_set_any(&dst); 8031a24: 2300 movs r3, #0 8031a26: 9300 str r3, [sp, #0] 8031a28: e02b b.n 8031a82 insert = 1; } else { /* route to the network address */ ip_addr_get_network(&dst, &ni->ip_addr, &ni->netmask); 8031a2a: 688a ldr r2, [r1, #8] 8031a2c: 684b ldr r3, [r1, #4] 8031a2e: 4013 ands r3, r2 8031a30: 9300 str r3, [sp, #0] /* exclude 0.0.0.0 network (reserved for default rte) */ if (!ip_addr_isany(&dst)) { 8031a32: bb33 cbnz r3, 8031a82 8031a34: e021 b.n 8031a7a snmp_iptooid(&dst, &iprteidx[0]); level = 0; iprte_rn = &iprtetree_root; while (level < 4) { iprte_node = NULL; 8031a36: 2300 movs r3, #0 8031a38: 9301 str r3, [sp, #4] snmp_mib_node_insert(iprte_rn, iprteidx[level], &iprte_node); 8031a3a: ab02 add r3, sp, #8 8031a3c: 4620 mov r0, r4 8031a3e: f853 1025 ldr.w r1, [r3, r5, lsl #2] 8031a42: aa01 add r2, sp, #4 8031a44: b2ee uxtb r6, r5 8031a46: f000 fb17 bl 8032078 if ((level != 3) && (iprte_node != NULL)) 8031a4a: 2e03 cmp r6, #3 8031a4c: d012 beq.n 8031a74 8031a4e: 9b01 ldr r3, [sp, #4] 8031a50: b183 cbz r3, 8031a74 { if (iprte_node->nptr == NULL) 8031a52: 68dc ldr r4, [r3, #12] 8031a54: b974 cbnz r4, 8031a74 { iprte_rn = snmp_mib_lrn_alloc(); 8031a56: f000 faed bl 8032034 iprte_node->nptr = (struct mib_node*)iprte_rn; 8031a5a: 9b01 ldr r3, [sp, #4] snmp_mib_node_insert(iprte_rn, iprteidx[level], &iprte_node); if ((level != 3) && (iprte_node != NULL)) { if (iprte_node->nptr == NULL) { iprte_rn = snmp_mib_lrn_alloc(); 8031a5c: 4604 mov r4, r0 iprte_node->nptr = (struct mib_node*)iprte_rn; 8031a5e: 60d8 str r0, [r3, #12] if (iprte_rn != NULL) 8031a60: b158 cbz r0, 8031a7a { if (level == 2) 8031a62: 2e02 cmp r6, #2 8031a64: d106 bne.n 8031a74 { iprte_rn->get_object_def = ip_rteentry_get_object_def; iprte_rn->get_value = ip_rteentry_get_value; iprte_rn->set_test = noleafs_set_test; 8031a66: 4b0d ldr r3, [pc, #52] ; (8031a9c ) iprte_node->nptr = (struct mib_node*)iprte_rn; if (iprte_rn != NULL) { if (level == 2) { iprte_rn->get_object_def = ip_rteentry_get_object_def; 8031a68: f8c0 8000 str.w r8, [r0] iprte_rn->get_value = ip_rteentry_get_value; iprte_rn->set_test = noleafs_set_test; 8031a6c: 6083 str r3, [r0, #8] iprte_rn->set_value = noleafs_set_value; 8031a6e: 4b0c ldr r3, [pc, #48] ; (8031aa0 ) if (iprte_rn != NULL) { if (level == 2) { iprte_rn->get_object_def = ip_rteentry_get_object_def; iprte_rn->get_value = ip_rteentry_get_value; 8031a70: 6047 str r7, [r0, #4] iprte_rn->set_test = noleafs_set_test; iprte_rn->set_value = noleafs_set_value; 8031a72: 60c3 str r3, [r0, #12] 8031a74: 3501 adds r5, #1 u8_t level; snmp_iptooid(&dst, &iprteidx[0]); level = 0; iprte_rn = &iprtetree_root; while (level < 4) 8031a76: 2d04 cmp r5, #4 8031a78: d1dd bne.n 8031a36 } level++; } } /* enable getnext traversal on filled table */ iprtetable.maxlength = 1; 8031a7a: 4b0a ldr r3, [pc, #40] ; (8031aa4 ) 8031a7c: 2201 movs r2, #1 8031a7e: 825a strh r2, [r3, #18] 8031a80: e009 b.n 8031a96 struct mib_list_rootnode *iprte_rn; struct mib_list_node *iprte_node; s32_t iprteidx[4]; u8_t level; snmp_iptooid(&dst, &iprteidx[0]); 8031a82: 4668 mov r0, sp 8031a84: a902 add r1, sp, #8 8031a86: f000 fabc bl 8032002 8031a8a: 2500 movs r5, #0 level = 0; iprte_rn = &iprtetree_root; 8031a8c: 4c06 ldr r4, [pc, #24] ; (8031aa8 ) iprte_node->nptr = (struct mib_node*)iprte_rn; if (iprte_rn != NULL) { if (level == 2) { iprte_rn->get_object_def = ip_rteentry_get_object_def; 8031a8e: f8df 8020 ldr.w r8, [pc, #32] ; 8031ab0 iprte_rn->get_value = ip_rteentry_get_value; 8031a92: 4f06 ldr r7, [pc, #24] ; (8031aac ) 8031a94: e7cf b.n 8031a36 level++; } } /* enable getnext traversal on filled table */ iprtetable.maxlength = 1; } 8031a96: b006 add sp, #24 8031a98: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8031a9c: 080309cb .word 0x080309cb 8031aa0: 080309cf .word 0x080309cf 8031aa4: 20001830 .word 0x20001830 8031aa8: 20001674 .word 0x20001674 8031aac: 08031551 .word 0x08031551 8031ab0: 08030b95 .word 0x08030b95 08031ab4 : * @param dflt non-zero for the default rte, zero for network rte * @param ni points to network interface for this rte or NULL * for default route to be removed. */ void snmp_delete_iprteidx_tree(u8_t dflt, struct netif *ni) { 8031ab4: b570 push {r4, r5, r6, lr} 8031ab6: b08e sub sp, #56 ; 0x38 u8_t del = 0; ip_addr_t dst; if (dflt != 0) 8031ab8: b110 cbz r0, 8031ac0 { /* the default route 0.0.0.0 */ ip_addr_set_any(&dst); 8031aba: 2300 movs r3, #0 8031abc: 9300 str r3, [sp, #0] 8031abe: e041 b.n 8031b44 del = 1; } else { /* route to the network address */ ip_addr_get_network(&dst, &ni->ip_addr, &ni->netmask); 8031ac0: 688a ldr r2, [r1, #8] 8031ac2: 684b ldr r3, [r1, #4] 8031ac4: 4013 ands r3, r2 8031ac6: 9300 str r3, [sp, #0] /* exclude 0.0.0.0 network (reserved for default rte) */ if (!ip_addr_isany(&dst)) { 8031ac8: 2b00 cmp r3, #0 8031aca: d13b bne.n 8031b44 8031acc: e034 b.n 8031b38 level = 0; del_cnt = 0; iprte_rn = &iprtetree_root; while ((level < 4) && (iprte_rn != NULL)) { fc = snmp_mib_node_find(iprte_rn, iprteidx[level], &iprte_n); 8031ace: ab0a add r3, sp, #40 ; 0x28 8031ad0: 4628 mov r0, r5 8031ad2: 58f1 ldr r1, [r6, r3] 8031ad4: aa01 add r2, sp, #4 8031ad6: f000 fb0a bl 80320ee 8031ada: b2c0 uxtb r0, r0 if (fc == 0) 8031adc: b198 cbz r0, 8031b06 { /* iprteidx[level] does not exist */ del_cnt = 0; iprte_rn = NULL; } else if (fc == 1) 8031ade: 2801 cmp r0, #1 8031ae0: d10b bne.n 8031afa { del_rn[del_cnt] = iprte_rn; 8031ae2: ab0e add r3, sp, #56 ; 0x38 8031ae4: eb03 0284 add.w r2, r3, r4, lsl #2 del_n[del_cnt] = iprte_n; 8031ae8: 9b01 ldr r3, [sp, #4] del_cnt = 0; iprte_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = iprte_rn; 8031aea: f842 5c30 str.w r5, [r2, #-48] del_n[del_cnt] = iprte_n; del_cnt++; 8031aee: 3401 adds r4, #1 iprte_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = iprte_rn; del_n[del_cnt] = iprte_n; 8031af0: f842 3c20 str.w r3, [r2, #-32] del_cnt++; 8031af4: b2e4 uxtb r4, r4 iprte_rn = (struct mib_list_rootnode*)(iprte_n->nptr); 8031af6: 68dd ldr r5, [r3, #12] 8031af8: e007 b.n 8031b0a } else if (fc == 2) 8031afa: 2802 cmp r0, #2 8031afc: d105 bne.n 8031b0a { /* reset delete (2 or more childs) */ del_cnt = 0; iprte_rn = (struct mib_list_rootnode*)(iprte_n->nptr); 8031afe: 9b01 ldr r3, [sp, #4] iprte_rn = (struct mib_list_rootnode*)(iprte_n->nptr); } else if (fc == 2) { /* reset delete (2 or more childs) */ del_cnt = 0; 8031b00: 2400 movs r4, #0 iprte_rn = (struct mib_list_rootnode*)(iprte_n->nptr); 8031b02: 68dd ldr r5, [r3, #12] 8031b04: e001 b.n 8031b0a { fc = snmp_mib_node_find(iprte_rn, iprteidx[level], &iprte_n); if (fc == 0) { /* iprteidx[level] does not exist */ del_cnt = 0; 8031b06: 4604 mov r4, r0 iprte_rn = NULL; 8031b08: 4605 mov r5, r0 snmp_iptooid(&dst, &iprteidx[0]); /* mark nodes for deletion */ level = 0; del_cnt = 0; iprte_rn = &iprtetree_root; while ((level < 4) && (iprte_rn != NULL)) 8031b0a: 2e0c cmp r6, #12 8031b0c: d012 beq.n 8031b34 8031b0e: 3604 adds r6, #4 8031b10: 2d00 cmp r5, #0 8031b12: d1dc bne.n 8031ace 8031b14: e00e b.n 8031b34 level++; } /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; 8031b16: 3c01 subs r4, #1 8031b18: b2e4 uxtb r4, r4 iprte_rn = del_rn[del_cnt]; 8031b1a: aa0e add r2, sp, #56 ; 0x38 8031b1c: eb02 0384 add.w r3, r2, r4, lsl #2 iprte_n = del_n[del_cnt]; 8031b20: f853 1c20 ldr.w r1, [r3, #-32] /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; iprte_rn = del_rn[del_cnt]; 8031b24: f853 0c30 ldr.w r0, [r3, #-48] iprte_n = del_n[del_cnt]; 8031b28: 9101 str r1, [sp, #4] next = snmp_mib_node_delete(iprte_rn, iprte_n); 8031b2a: f000 fafa bl 8032122 if (next != NULL) 8031b2e: b108 cbz r0, 8031b34 { LWIP_ASSERT("next_count == 0",next->count == 0); snmp_mib_lrn_free(next); 8031b30: f000 fa9e bl 8032070 iprte_rn = (struct mib_list_rootnode*)(iprte_n->nptr); } level++; } /* delete marked index nodes */ while (del_cnt > 0) 8031b34: 2c00 cmp r4, #0 8031b36: d1ee bne.n 8031b16 snmp_mib_lrn_free(next); } } } /* disable getnext traversal on empty table */ if (iprtetree_root.count == 0) iprtetable.maxlength = 0; 8031b38: 4b07 ldr r3, [pc, #28] ; (8031b58 ) 8031b3a: 8b9b ldrh r3, [r3, #28] 8031b3c: b953 cbnz r3, 8031b54 8031b3e: 4a07 ldr r2, [pc, #28] ; (8031b5c ) 8031b40: 8253 strh r3, [r2, #18] 8031b42: e007 b.n 8031b54 struct mib_list_rootnode *iprte_rn, *next, *del_rn[4]; struct mib_list_node *iprte_n, *del_n[4]; s32_t iprteidx[4]; u8_t fc, level, del_cnt; snmp_iptooid(&dst, &iprteidx[0]); 8031b44: 4668 mov r0, sp 8031b46: a90a add r1, sp, #40 ; 0x28 8031b48: 2600 movs r6, #0 8031b4a: f000 fa5a bl 8032002 /* mark nodes for deletion */ level = 0; del_cnt = 0; 8031b4e: 4634 mov r4, r6 iprte_rn = &iprtetree_root; 8031b50: 4d01 ldr r5, [pc, #4] ; (8031b58 ) 8031b52: e7bc b.n 8031ace } } } /* disable getnext traversal on empty table */ if (iprtetree_root.count == 0) iprtetable.maxlength = 0; } 8031b54: b00e add sp, #56 ; 0x38 8031b56: bd70 pop {r4, r5, r6, pc} 8031b58: 20001674 .word 0x20001674 8031b5c: 20001830 .word 0x20001830 08031b60 : void snmp_inc_icmpinmsgs(void) { icmpinmsgs++; 8031b60: 4b02 ldr r3, [pc, #8] ; (8031b6c ) 8031b62: 681a ldr r2, [r3, #0] 8031b64: 3201 adds r2, #1 8031b66: 601a str r2, [r3, #0] 8031b68: 4770 bx lr 8031b6a: bf00 nop 8031b6c: 2000e174 .word 0x2000e174 08031b70 : } void snmp_inc_icmpinerrors(void) { icmpinerrors++; 8031b70: 4b02 ldr r3, [pc, #8] ; (8031b7c ) 8031b72: 681a ldr r2, [r3, #0] 8031b74: 3201 adds r2, #1 8031b76: 601a str r2, [r3, #0] 8031b78: 4770 bx lr 8031b7a: bf00 nop 8031b7c: 2000e170 .word 0x2000e170 08031b80 : icmpinaddrmaskreps++; } void snmp_inc_icmpoutmsgs(void) { icmpoutmsgs++; 8031b80: 4b02 ldr r3, [pc, #8] ; (8031b8c ) 8031b82: 681a ldr r2, [r3, #0] 8031b84: 3201 adds r2, #1 8031b86: 601a str r2, [r3, #0] 8031b88: 4770 bx lr 8031b8a: bf00 nop 8031b8c: 2000e1f4 .word 0x2000e1f4 08031b90 : icmpoutdestunreachs++; } void snmp_inc_icmpouttimeexcds(void) { icmpouttimeexcds++; 8031b90: 4b02 ldr r3, [pc, #8] ; (8031b9c ) 8031b92: 681a ldr r2, [r3, #0] 8031b94: 3201 adds r2, #1 8031b96: 601a str r2, [r3, #0] 8031b98: 4770 bx lr 8031b9a: bf00 nop 8031b9c: 2000e1c0 .word 0x2000e1c0 08031ba0 : icmpoutechos++; } void snmp_inc_icmpoutechoreps(void) { icmpoutechoreps++; 8031ba0: 4b02 ldr r3, [pc, #8] ; (8031bac ) 8031ba2: 681a ldr r2, [r3, #0] 8031ba4: 3201 adds r2, #1 8031ba6: 601a str r2, [r3, #0] 8031ba8: 4770 bx lr 8031baa: bf00 nop 8031bac: 2000e214 .word 0x2000e214 08031bb0 : tcpactiveopens++; } void snmp_inc_tcppassiveopens(void) { tcppassiveopens++; 8031bb0: 4b02 ldr r3, [pc, #8] ; (8031bbc ) 8031bb2: 681a ldr r2, [r3, #0] 8031bb4: 3201 adds r2, #1 8031bb6: 601a str r2, [r3, #0] 8031bb8: 4770 bx lr 8031bba: bf00 nop 8031bbc: 2000e19c .word 0x2000e19c 08031bc0 : } void snmp_inc_tcpattemptfails(void) { tcpattemptfails++; 8031bc0: 4b02 ldr r3, [pc, #8] ; (8031bcc ) 8031bc2: 681a ldr r2, [r3, #0] 8031bc4: 3201 adds r2, #1 8031bc6: 601a str r2, [r3, #0] 8031bc8: 4770 bx lr 8031bca: bf00 nop 8031bcc: 2000e1e8 .word 0x2000e1e8 08031bd0 : } void snmp_inc_tcpestabresets(void) { tcpestabresets++; 8031bd0: 4b02 ldr r3, [pc, #8] ; (8031bdc ) 8031bd2: 681a ldr r2, [r3, #0] 8031bd4: 3201 adds r2, #1 8031bd6: 601a str r2, [r3, #0] 8031bd8: 4770 bx lr 8031bda: bf00 nop 8031bdc: 2000e17c .word 0x2000e17c 08031be0 : } void snmp_inc_tcpinsegs(void) { tcpinsegs++; 8031be0: 4b02 ldr r3, [pc, #8] ; (8031bec ) 8031be2: 681a ldr r2, [r3, #0] 8031be4: 3201 adds r2, #1 8031be6: 601a str r2, [r3, #0] 8031be8: 4770 bx lr 8031bea: bf00 nop 8031bec: 2000e1f8 .word 0x2000e1f8 08031bf0 : } void snmp_inc_tcpoutsegs(void) { tcpoutsegs++; 8031bf0: 4b02 ldr r3, [pc, #8] ; (8031bfc ) 8031bf2: 681a ldr r2, [r3, #0] 8031bf4: 3201 adds r2, #1 8031bf6: 601a str r2, [r3, #0] 8031bf8: 4770 bx lr 8031bfa: bf00 nop 8031bfc: 2000e244 .word 0x2000e244 08031c00 : } void snmp_inc_tcpretranssegs(void) { tcpretranssegs++; 8031c00: 4b02 ldr r3, [pc, #8] ; (8031c0c ) 8031c02: 681a ldr r2, [r3, #0] 8031c04: 3201 adds r2, #1 8031c06: 601a str r2, [r3, #0] 8031c08: 4770 bx lr 8031c0a: bf00 nop 8031c0c: 2000e218 .word 0x2000e218 08031c10 : } void snmp_inc_tcpinerrs(void) { tcpinerrs++; 8031c10: 4b02 ldr r3, [pc, #8] ; (8031c1c ) 8031c12: 681a ldr r2, [r3, #0] 8031c14: 3201 adds r2, #1 8031c16: 601a str r2, [r3, #0] 8031c18: 4770 bx lr 8031c1a: bf00 nop 8031c1c: 2000e1a4 .word 0x2000e1a4 08031c20 : } void snmp_inc_tcpoutrsts(void) { tcpoutrsts++; 8031c20: 4b02 ldr r3, [pc, #8] ; (8031c2c ) 8031c22: 681a ldr r2, [r3, #0] 8031c24: 3201 adds r2, #1 8031c26: 601a str r2, [r3, #0] 8031c28: 4770 bx lr 8031c2a: bf00 nop 8031c2c: 2000e208 .word 0x2000e208 08031c30 : } void snmp_inc_udpindatagrams(void) { udpindatagrams++; 8031c30: 4b02 ldr r3, [pc, #8] ; (8031c3c ) 8031c32: 681a ldr r2, [r3, #0] 8031c34: 3201 adds r2, #1 8031c36: 601a str r2, [r3, #0] 8031c38: 4770 bx lr 8031c3a: bf00 nop 8031c3c: 2000e224 .word 0x2000e224 08031c40 : } void snmp_inc_udpnoports(void) { udpnoports++; 8031c40: 4b02 ldr r3, [pc, #8] ; (8031c4c ) 8031c42: 681a ldr r2, [r3, #0] 8031c44: 3201 adds r2, #1 8031c46: 601a str r2, [r3, #0] 8031c48: 4770 bx lr 8031c4a: bf00 nop 8031c4c: 2000e1dc .word 0x2000e1dc 08031c50 : } void snmp_inc_udpinerrors(void) { udpinerrors++; 8031c50: 4b02 ldr r3, [pc, #8] ; (8031c5c ) 8031c52: 681a ldr r2, [r3, #0] 8031c54: 3201 adds r2, #1 8031c56: 601a str r2, [r3, #0] 8031c58: 4770 bx lr 8031c5a: bf00 nop 8031c5c: 2000e24c .word 0x2000e24c 08031c60 : } void snmp_inc_udpoutdatagrams(void) { udpoutdatagrams++; 8031c60: 4b02 ldr r3, [pc, #8] ; (8031c6c ) 8031c62: 681a ldr r2, [r3, #0] 8031c64: 3201 adds r2, #1 8031c66: 601a str r2, [r3, #0] 8031c68: 4770 bx lr 8031c6a: bf00 nop 8031c6c: 2000e1d4 .word 0x2000e1d4 08031c70 : /** * Inserts udpTable indexes (.udpLocalAddress.udpLocalPort) * into index tree. */ void snmp_insert_udpidx_tree(struct udp_pcb *pcb) { 8031c70: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8031c74: 4604 mov r4, r0 8031c76: b086 sub sp, #24 struct mib_list_node *udp_node; s32_t udpidx[5]; u8_t level; LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); 8031c78: a901 add r1, sp, #4 8031c7a: f000 f9c2 bl 8032002 udpidx[4] = pcb->local_port; 8031c7e: 8a63 ldrh r3, [r4, #18] udp_node->nptr = (struct mib_node*)udp_rn; if (udp_rn != NULL) { if (level == 3) { udp_rn->get_object_def = udpentry_get_object_def; 8031c80: 4f17 ldr r7, [pc, #92] ; (8031ce0 ) LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); udpidx[4] = pcb->local_port; udp_rn = &udp_root; 8031c82: 4c18 ldr r4, [pc, #96] ; (8031ce4 ) if (udp_rn != NULL) { if (level == 3) { udp_rn->get_object_def = udpentry_get_object_def; udp_rn->get_value = udpentry_get_value; 8031c84: f8df 806c ldr.w r8, [pc, #108] ; 8031cf4 s32_t udpidx[5]; u8_t level; LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); udpidx[4] = pcb->local_port; 8031c88: 9305 str r3, [sp, #20] 8031c8a: 2500 movs r5, #0 udp_rn = &udp_root; for (level = 0; level < 5; level++) { udp_node = NULL; 8031c8c: 2300 movs r3, #0 8031c8e: 9300 str r3, [sp, #0] snmp_mib_node_insert(udp_rn, udpidx[level], &udp_node); 8031c90: ab01 add r3, sp, #4 8031c92: 4620 mov r0, r4 8031c94: f853 1025 ldr.w r1, [r3, r5, lsl #2] 8031c98: 466a mov r2, sp 8031c9a: b2ee uxtb r6, r5 8031c9c: f000 f9ec bl 8032078 if ((level != 4) && (udp_node != NULL)) 8031ca0: 2e04 cmp r6, #4 8031ca2: d015 beq.n 8031cd0 8031ca4: 9b00 ldr r3, [sp, #0] 8031ca6: b19b cbz r3, 8031cd0 { if (udp_node->nptr == NULL) 8031ca8: 68dc ldr r4, [r3, #12] 8031caa: b98c cbnz r4, 8031cd0 { udp_rn = snmp_mib_lrn_alloc(); 8031cac: f000 f9c2 bl 8032034 udp_node->nptr = (struct mib_node*)udp_rn; 8031cb0: 9b00 ldr r3, [sp, #0] snmp_mib_node_insert(udp_rn, udpidx[level], &udp_node); if ((level != 4) && (udp_node != NULL)) { if (udp_node->nptr == NULL) { udp_rn = snmp_mib_lrn_alloc(); 8031cb2: 4604 mov r4, r0 udp_node->nptr = (struct mib_node*)udp_rn; 8031cb4: 60d8 str r0, [r3, #12] if (udp_rn != NULL) 8031cb6: b918 cbnz r0, 8031cc0 { udp_rn = (struct mib_list_rootnode*)udp_node->nptr; } } } udptable.maxlength = 1; 8031cb8: 4b0b ldr r3, [pc, #44] ; (8031ce8 ) 8031cba: 2201 movs r2, #1 8031cbc: 825a strh r2, [r3, #18] 8031cbe: e00b b.n 8031cd8 { udp_rn = snmp_mib_lrn_alloc(); udp_node->nptr = (struct mib_node*)udp_rn; if (udp_rn != NULL) { if (level == 3) 8031cc0: 2e03 cmp r6, #3 8031cc2: d105 bne.n 8031cd0 { udp_rn->get_object_def = udpentry_get_object_def; udp_rn->get_value = udpentry_get_value; udp_rn->set_test = noleafs_set_test; 8031cc4: 4b09 ldr r3, [pc, #36] ; (8031cec ) if (udp_rn != NULL) { if (level == 3) { udp_rn->get_object_def = udpentry_get_object_def; udp_rn->get_value = udpentry_get_value; 8031cc6: e880 0180 stmia.w r0, {r7, r8} udp_rn->set_test = noleafs_set_test; 8031cca: 6083 str r3, [r0, #8] udp_rn->set_value = noleafs_set_value; 8031ccc: 4b08 ldr r3, [pc, #32] ; (8031cf0 ) 8031cce: 60c3 str r3, [r0, #12] 8031cd0: 3501 adds r5, #1 LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); udpidx[4] = pcb->local_port; udp_rn = &udp_root; for (level = 0; level < 5; level++) 8031cd2: 2d05 cmp r5, #5 8031cd4: d1da bne.n 8031c8c 8031cd6: e7ef b.n 8031cb8 udp_rn = (struct mib_list_rootnode*)udp_node->nptr; } } } udptable.maxlength = 1; } 8031cd8: b006 add sp, #24 8031cda: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8031cde: bf00 nop 8031ce0: 0803133d .word 0x0803133d 8031ce4: 20001644 .word 0x20001644 8031ce8: 20001628 .word 0x20001628 8031cec: 080309cb .word 0x080309cb 8031cf0: 080309cf .word 0x080309cf 8031cf4: 08030ff9 .word 0x08030ff9 08031cf8 : /** * Removes udpTable indexes (.udpLocalAddress.udpLocalPort) * from index tree. */ void snmp_delete_udpidx_tree(struct udp_pcb *pcb) { 8031cf8: b570 push {r4, r5, r6, lr} 8031cfa: 4604 mov r4, r0 8031cfc: b090 sub sp, #64 ; 0x40 struct mib_list_node *udp_n, *del_n[5]; s32_t udpidx[5]; u8_t bindings, fc, level, del_cnt; LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); 8031cfe: a90b add r1, sp, #44 ; 0x2c 8031d00: f000 f97f bl 8032002 udpidx[4] = pcb->local_port; 8031d04: 8a61 ldrh r1, [r4, #18] /* count PCBs for a given binding (e.g. when reusing ports or for temp output PCBs) */ bindings = 0; npcb = udp_pcbs; 8031d06: 4b2a ldr r3, [pc, #168] ; (8031db0 ) s32_t udpidx[5]; u8_t bindings, fc, level, del_cnt; LWIP_ASSERT("pcb != NULL", pcb != NULL); snmp_iptooid(&pcb->local_ip, &udpidx[0]); udpidx[4] = pcb->local_port; 8031d08: 910f str r1, [sp, #60] ; 0x3c /* count PCBs for a given binding (e.g. when reusing ports or for temp output PCBs) */ bindings = 0; npcb = udp_pcbs; 8031d0a: 681b ldr r3, [r3, #0] snmp_iptooid(&pcb->local_ip, &udpidx[0]); udpidx[4] = pcb->local_port; /* count PCBs for a given binding (e.g. when reusing ports or for temp output PCBs) */ bindings = 0; 8031d0c: 2200 movs r2, #0 npcb = udp_pcbs; while ((npcb != NULL)) 8031d0e: e009 b.n 8031d24 { if (ip_addr_cmp(&npcb->local_ip, &pcb->local_ip) && 8031d10: 681d ldr r5, [r3, #0] 8031d12: 6820 ldr r0, [r4, #0] 8031d14: 4285 cmp r5, r0 8031d16: d104 bne.n 8031d22 (npcb->local_port == udpidx[4])) 8031d18: 8a58 ldrh r0, [r3, #18] (e.g. when reusing ports or for temp output PCBs) */ bindings = 0; npcb = udp_pcbs; while ((npcb != NULL)) { if (ip_addr_cmp(&npcb->local_ip, &pcb->local_ip) && 8031d1a: 4288 cmp r0, r1 8031d1c: d101 bne.n 8031d22 (npcb->local_port == udpidx[4])) { bindings++; 8031d1e: 3201 adds r2, #1 8031d20: b2d2 uxtb r2, r2 } npcb = npcb->next; 8031d22: 68db ldr r3, [r3, #12] /* count PCBs for a given binding (e.g. when reusing ports or for temp output PCBs) */ bindings = 0; npcb = udp_pcbs; while ((npcb != NULL)) 8031d24: 2b00 cmp r3, #0 8031d26: d1f3 bne.n 8031d10 { bindings++; } npcb = npcb->next; } if (bindings == 1) 8031d28: 2a01 cmp r2, #1 8031d2a: d004 beq.n 8031d36 snmp_mib_lrn_free(next); } } } /* disable getnext traversal on empty table */ if (udp_root.count == 0) udptable.maxlength = 0; 8031d2c: 4b21 ldr r3, [pc, #132] ; (8031db4 ) 8031d2e: 8b9b ldrh r3, [r3, #28] 8031d30: 2b00 cmp r3, #0 8031d32: d039 beq.n 8031da8 8031d34: e03a b.n 8031dac { /* selectively remove */ /* mark nodes for deletion */ level = 0; del_cnt = 0; udp_rn = &udp_root; 8031d36: 4d1f ldr r5, [pc, #124] ; (8031db4 ) { bindings++; } npcb = npcb->next; } if (bindings == 1) 8031d38: 461e mov r6, r3 8031d3a: 461c mov r4, r3 level = 0; del_cnt = 0; udp_rn = &udp_root; while ((level < 5) && (udp_rn != NULL)) { fc = snmp_mib_node_find(udp_rn, udpidx[level], &udp_n); 8031d3c: ab0b add r3, sp, #44 ; 0x2c 8031d3e: 4628 mov r0, r5 8031d40: 58f1 ldr r1, [r6, r3] 8031d42: 466a mov r2, sp 8031d44: f000 f9d3 bl 80320ee 8031d48: b2c0 uxtb r0, r0 if (fc == 0) 8031d4a: b198 cbz r0, 8031d74 { /* udpidx[level] does not exist */ del_cnt = 0; udp_rn = NULL; } else if (fc == 1) 8031d4c: 2801 cmp r0, #1 8031d4e: d10b bne.n 8031d68 { del_rn[del_cnt] = udp_rn; 8031d50: ab10 add r3, sp, #64 ; 0x40 8031d52: eb03 0284 add.w r2, r3, r4, lsl #2 del_n[del_cnt] = udp_n; 8031d56: 9b00 ldr r3, [sp, #0] del_cnt = 0; udp_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = udp_rn; 8031d58: f842 5c3c str.w r5, [r2, #-60] del_n[del_cnt] = udp_n; del_cnt++; 8031d5c: 3401 adds r4, #1 udp_rn = NULL; } else if (fc == 1) { del_rn[del_cnt] = udp_rn; del_n[del_cnt] = udp_n; 8031d5e: f842 3c28 str.w r3, [r2, #-40] del_cnt++; 8031d62: b2e4 uxtb r4, r4 udp_rn = (struct mib_list_rootnode*)(udp_n->nptr); 8031d64: 68dd ldr r5, [r3, #12] 8031d66: e007 b.n 8031d78 } else if (fc == 2) 8031d68: 2802 cmp r0, #2 8031d6a: d105 bne.n 8031d78 { /* reset delete (2 or more childs) */ del_cnt = 0; udp_rn = (struct mib_list_rootnode*)(udp_n->nptr); 8031d6c: 9b00 ldr r3, [sp, #0] udp_rn = (struct mib_list_rootnode*)(udp_n->nptr); } else if (fc == 2) { /* reset delete (2 or more childs) */ del_cnt = 0; 8031d6e: 2400 movs r4, #0 udp_rn = (struct mib_list_rootnode*)(udp_n->nptr); 8031d70: 68dd ldr r5, [r3, #12] 8031d72: e001 b.n 8031d78 { fc = snmp_mib_node_find(udp_rn, udpidx[level], &udp_n); if (fc == 0) { /* udpidx[level] does not exist */ del_cnt = 0; 8031d74: 4604 mov r4, r0 udp_rn = NULL; 8031d76: 4605 mov r5, r0 /* selectively remove */ /* mark nodes for deletion */ level = 0; del_cnt = 0; udp_rn = &udp_root; while ((level < 5) && (udp_rn != NULL)) 8031d78: 2e10 cmp r6, #16 8031d7a: d012 beq.n 8031da2 8031d7c: 3604 adds r6, #4 8031d7e: 2d00 cmp r5, #0 8031d80: d1dc bne.n 8031d3c 8031d82: e00e b.n 8031da2 level++; } /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; 8031d84: 3c01 subs r4, #1 8031d86: b2e4 uxtb r4, r4 udp_rn = del_rn[del_cnt]; 8031d88: aa10 add r2, sp, #64 ; 0x40 8031d8a: eb02 0384 add.w r3, r2, r4, lsl #2 udp_n = del_n[del_cnt]; 8031d8e: f853 1c28 ldr.w r1, [r3, #-40] /* delete marked index nodes */ while (del_cnt > 0) { del_cnt--; udp_rn = del_rn[del_cnt]; 8031d92: f853 0c3c ldr.w r0, [r3, #-60] udp_n = del_n[del_cnt]; 8031d96: 9100 str r1, [sp, #0] next = snmp_mib_node_delete(udp_rn, udp_n); 8031d98: f000 f9c3 bl 8032122 if (next != NULL) 8031d9c: b108 cbz r0, 8031da2 { LWIP_ASSERT("next_count == 0",next->count == 0); snmp_mib_lrn_free(next); 8031d9e: f000 f967 bl 8032070 udp_rn = (struct mib_list_rootnode*)(udp_n->nptr); } level++; } /* delete marked index nodes */ while (del_cnt > 0) 8031da2: 2c00 cmp r4, #0 8031da4: d1ee bne.n 8031d84 8031da6: e7c1 b.n 8031d2c snmp_mib_lrn_free(next); } } } /* disable getnext traversal on empty table */ if (udp_root.count == 0) udptable.maxlength = 0; 8031da8: 4a03 ldr r2, [pc, #12] ; (8031db8 ) 8031daa: 8253 strh r3, [r2, #18] } 8031dac: b010 add sp, #64 ; 0x40 8031dae: bd70 pop {r4, r5, r6, pc} 8031db0: 20010ff8 .word 0x20010ff8 8031db4: 20001644 .word 0x20001644 8031db8: 20001628 .word 0x20001628 08031dbc : void snmp_inc_snmpinpkts(void) { snmpinpkts++; 8031dbc: 4b02 ldr r3, [pc, #8] ; (8031dc8 ) 8031dbe: 681a ldr r2, [r3, #0] 8031dc0: 3201 adds r2, #1 8031dc2: 601a str r2, [r3, #0] 8031dc4: 4770 bx lr 8031dc6: bf00 nop 8031dc8: 2000e180 .word 0x2000e180 08031dcc : } void snmp_inc_snmpoutpkts(void) { snmpoutpkts++; 8031dcc: 4b02 ldr r3, [pc, #8] ; (8031dd8 ) 8031dce: 681a ldr r2, [r3, #0] 8031dd0: 3201 adds r2, #1 8031dd2: 601a str r2, [r3, #0] 8031dd4: 4770 bx lr 8031dd6: bf00 nop 8031dd8: 2000e250 .word 0x2000e250 08031ddc : } void snmp_inc_snmpinbadversions(void) { snmpinbadversions++; 8031ddc: 4b02 ldr r3, [pc, #8] ; (8031de8 ) 8031dde: 681a ldr r2, [r3, #0] 8031de0: 3201 adds r2, #1 8031de2: 601a str r2, [r3, #0] 8031de4: 4770 bx lr 8031de6: bf00 nop 8031de8: 2000e23c .word 0x2000e23c 08031dec : } void snmp_inc_snmpinbadcommunitynames(void) { snmpinbadcommunitynames++; 8031dec: 4b02 ldr r3, [pc, #8] ; (8031df8 ) 8031dee: 681a ldr r2, [r3, #0] 8031df0: 3201 adds r2, #1 8031df2: 601a str r2, [r3, #0] 8031df4: 4770 bx lr 8031df6: bf00 nop 8031df8: 2000e154 .word 0x2000e154 08031dfc : snmpinbadcommunityuses++; } void snmp_inc_snmpinasnparseerrs(void) { snmpinasnparseerrs++; 8031dfc: 4b02 ldr r3, [pc, #8] ; (8031e08 ) 8031dfe: 681a ldr r2, [r3, #0] 8031e00: 3201 adds r2, #1 8031e02: 601a str r2, [r3, #0] 8031e04: 4770 bx lr 8031e06: bf00 nop 8031e08: 2000e240 .word 0x2000e240 08031e0c : } void snmp_inc_snmpintoobigs(void) { snmpintoobigs++; 8031e0c: 4b02 ldr r3, [pc, #8] ; (8031e18 ) 8031e0e: 681a ldr r2, [r3, #0] 8031e10: 3201 adds r2, #1 8031e12: 601a str r2, [r3, #0] 8031e14: 4770 bx lr 8031e16: bf00 nop 8031e18: 2000e200 .word 0x2000e200 08031e1c : } void snmp_inc_snmpinnosuchnames(void) { snmpinnosuchnames++; 8031e1c: 4b02 ldr r3, [pc, #8] ; (8031e28 ) 8031e1e: 681a ldr r2, [r3, #0] 8031e20: 3201 adds r2, #1 8031e22: 601a str r2, [r3, #0] 8031e24: 4770 bx lr 8031e26: bf00 nop 8031e28: 2000e280 .word 0x2000e280 08031e2c : } void snmp_inc_snmpinbadvalues(void) { snmpinbadvalues++; 8031e2c: 4b02 ldr r3, [pc, #8] ; (8031e38 ) 8031e2e: 681a ldr r2, [r3, #0] 8031e30: 3201 adds r2, #1 8031e32: 601a str r2, [r3, #0] 8031e34: 4770 bx lr 8031e36: bf00 nop 8031e38: 2000e21c .word 0x2000e21c 08031e3c : } void snmp_inc_snmpinreadonlys(void) { snmpinreadonlys++; 8031e3c: 4b02 ldr r3, [pc, #8] ; (8031e48 ) 8031e3e: 681a ldr r2, [r3, #0] 8031e40: 3201 adds r2, #1 8031e42: 601a str r2, [r3, #0] 8031e44: 4770 bx lr 8031e46: bf00 nop 8031e48: 2000e1f0 .word 0x2000e1f0 08031e4c : } void snmp_inc_snmpingenerrs(void) { snmpingenerrs++; 8031e4c: 4b02 ldr r3, [pc, #8] ; (8031e58 ) 8031e4e: 681a ldr r2, [r3, #0] 8031e50: 3201 adds r2, #1 8031e52: 601a str r2, [r3, #0] 8031e54: 4770 bx lr 8031e56: bf00 nop 8031e58: 2000e1c8 .word 0x2000e1c8 08031e5c : } void snmp_add_snmpintotalreqvars(u8_t value) { snmpintotalreqvars += value; 8031e5c: 4b02 ldr r3, [pc, #8] ; (8031e68 ) 8031e5e: 681a ldr r2, [r3, #0] 8031e60: 1880 adds r0, r0, r2 8031e62: 6018 str r0, [r3, #0] 8031e64: 4770 bx lr 8031e66: bf00 nop 8031e68: 2000e220 .word 0x2000e220 08031e6c : } void snmp_add_snmpintotalsetvars(u8_t value) { snmpintotalsetvars += value; 8031e6c: 4b02 ldr r3, [pc, #8] ; (8031e78 ) 8031e6e: 681a ldr r2, [r3, #0] 8031e70: 1880 adds r0, r0, r2 8031e72: 6018 str r0, [r3, #0] 8031e74: 4770 bx lr 8031e76: bf00 nop 8031e78: 2000e160 .word 0x2000e160 08031e7c : } void snmp_inc_snmpingetrequests(void) { snmpingetrequests++; 8031e7c: 4b02 ldr r3, [pc, #8] ; (8031e88 ) 8031e7e: 681a ldr r2, [r3, #0] 8031e80: 3201 adds r2, #1 8031e82: 601a str r2, [r3, #0] 8031e84: 4770 bx lr 8031e86: bf00 nop 8031e88: 2000e1b4 .word 0x2000e1b4 08031e8c : } void snmp_inc_snmpingetnexts(void) { snmpingetnexts++; 8031e8c: 4b02 ldr r3, [pc, #8] ; (8031e98 ) 8031e8e: 681a ldr r2, [r3, #0] 8031e90: 3201 adds r2, #1 8031e92: 601a str r2, [r3, #0] 8031e94: 4770 bx lr 8031e96: bf00 nop 8031e98: 2000e138 .word 0x2000e138 08031e9c : } void snmp_inc_snmpinsetrequests(void) { snmpinsetrequests++; 8031e9c: 4b02 ldr r3, [pc, #8] ; (8031ea8 ) 8031e9e: 681a ldr r2, [r3, #0] 8031ea0: 3201 adds r2, #1 8031ea2: 601a str r2, [r3, #0] 8031ea4: 4770 bx lr 8031ea6: bf00 nop 8031ea8: 2000e25c .word 0x2000e25c 08031eac : } void snmp_inc_snmpingetresponses(void) { snmpingetresponses++; 8031eac: 4b02 ldr r3, [pc, #8] ; (8031eb8 ) 8031eae: 681a ldr r2, [r3, #0] 8031eb0: 3201 adds r2, #1 8031eb2: 601a str r2, [r3, #0] 8031eb4: 4770 bx lr 8031eb6: bf00 nop 8031eb8: 2000e1b0 .word 0x2000e1b0 08031ebc : } void snmp_inc_snmpintraps(void) { snmpintraps++; 8031ebc: 4b02 ldr r3, [pc, #8] ; (8031ec8 ) 8031ebe: 681a ldr r2, [r3, #0] 8031ec0: 3201 adds r2, #1 8031ec2: 601a str r2, [r3, #0] 8031ec4: 4770 bx lr 8031ec6: bf00 nop 8031ec8: 2000e148 .word 0x2000e148 08031ecc : } void snmp_inc_snmpouttoobigs(void) { snmpouttoobigs++; 8031ecc: 4b02 ldr r3, [pc, #8] ; (8031ed8 ) 8031ece: 681a ldr r2, [r3, #0] 8031ed0: 3201 adds r2, #1 8031ed2: 601a str r2, [r3, #0] 8031ed4: 4770 bx lr 8031ed6: bf00 nop 8031ed8: 2000e198 .word 0x2000e198 08031edc : } void snmp_inc_snmpoutnosuchnames(void) { snmpoutnosuchnames++; 8031edc: 4b02 ldr r3, [pc, #8] ; (8031ee8 ) 8031ede: 681a ldr r2, [r3, #0] 8031ee0: 3201 adds r2, #1 8031ee2: 601a str r2, [r3, #0] 8031ee4: 4770 bx lr 8031ee6: bf00 nop 8031ee8: 2000e164 .word 0x2000e164 08031eec : } void snmp_inc_snmpoutbadvalues(void) { snmpoutbadvalues++; 8031eec: 4b02 ldr r3, [pc, #8] ; (8031ef8 ) 8031eee: 681a ldr r2, [r3, #0] 8031ef0: 3201 adds r2, #1 8031ef2: 601a str r2, [r3, #0] 8031ef4: 4770 bx lr 8031ef6: bf00 nop 8031ef8: 2000e144 .word 0x2000e144 08031efc : } void snmp_inc_snmpoutgenerrs(void) { snmpoutgenerrs++; 8031efc: 4b02 ldr r3, [pc, #8] ; (8031f08 ) 8031efe: 681a ldr r2, [r3, #0] 8031f00: 3201 adds r2, #1 8031f02: 601a str r2, [r3, #0] 8031f04: 4770 bx lr 8031f06: bf00 nop 8031f08: 2000e284 .word 0x2000e284 08031f0c : snmpoutsetrequests++; } void snmp_inc_snmpoutgetresponses(void) { snmpoutgetresponses++; 8031f0c: 4b02 ldr r3, [pc, #8] ; (8031f18 ) 8031f0e: 681a ldr r2, [r3, #0] 8031f10: 3201 adds r2, #1 8031f12: 601a str r2, [r3, #0] 8031f14: 4770 bx lr 8031f16: bf00 nop 8031f18: 2000e140 .word 0x2000e140 08031f1c : } void snmp_inc_snmpouttraps(void) { snmpouttraps++; 8031f1c: 4b02 ldr r3, [pc, #8] ; (8031f28 ) 8031f1e: 681a ldr r2, [r3, #0] 8031f20: 3201 adds r2, #1 8031f22: 601a str r2, [r3, #0] 8031f24: 4770 bx lr 8031f26: bf00 nop 8031f28: 2000e1b8 .word 0x2000e1b8 08031f2c : } void snmp_get_snmpgrpid_ptr(struct snmp_obj_id **oid) { *oid = &snmpgrp_id; 8031f2c: 4b01 ldr r3, [pc, #4] ; (8031f34 ) 8031f2e: 6003 str r3, [r0, #0] 8031f30: 4770 bx lr 8031f32: bf00 nop 8031f34: 20001854 .word 0x20001854 08031f38 : } } void snmp_get_snmpenableauthentraps(u8_t *value) { *value = *snmpenableauthentraps_ptr; 8031f38: 4b02 ldr r3, [pc, #8] ; (8031f44 ) 8031f3a: 681b ldr r3, [r3, #0] 8031f3c: 781b ldrb r3, [r3, #0] 8031f3e: 7003 strb r3, [r0, #0] 8031f40: 4770 bx lr 8031f42: bf00 nop 8031f44: 20001768 .word 0x20001768 08031f48 : /** * Pushes nse struct onto stack. */ static void push_node(struct nse* node) { 8031f48: b530 push {r4, r5, lr} LWIP_ASSERT("node_stack_cnt < NODE_STACK_SIZE",node_stack_cnt < NODE_STACK_SIZE); LWIP_DEBUGF(SNMP_MIB_DEBUG,("push_node() node=%p id=%"S32_F"\n",(void*)(node->r_ptr),node->r_id)); if (node_stack_cnt < NODE_STACK_SIZE) 8031f4a: 4d07 ldr r5, [pc, #28] ; (8031f68 ) 8031f4c: 782b ldrb r3, [r5, #0] 8031f4e: 2b1f cmp r3, #31 8031f50: d808 bhi.n 8031f64 { node_stack[node_stack_cnt] = *node; 8031f52: 4a06 ldr r2, [pc, #24] ; (8031f6c ) 8031f54: 240c movs r4, #12 8031f56: fb04 2403 mla r4, r4, r3, r2 8031f5a: c807 ldmia r0, {r0, r1, r2} 8031f5c: e884 0007 stmia.w r4, {r0, r1, r2} node_stack_cnt++; 8031f60: 3301 adds r3, #1 8031f62: 702b strb r3, [r5, #0] 8031f64: bd30 pop {r4, r5, pc} 8031f66: bf00 nop 8031f68: 2000e288 .word 0x2000e288 8031f6c: 2000e28c .word 0x2000e28c 08031f70 : empty_table(struct mib_node *node) { u8_t node_type; u8_t empty = 0; if (node != NULL) 8031f70: b1d0 cbz r0, 8031fa8 { node_type = node->node_type; 8031f72: 7c03 ldrb r3, [r0, #16] if (node_type == MIB_NODE_LR) 8031f74: 2b04 cmp r3, #4 8031f76: d105 bne.n 8031f84 { struct mib_list_rootnode *lrn; lrn = (struct mib_list_rootnode *)node; if ((lrn->count == 0) || (lrn->head == NULL)) 8031f78: 8b83 ldrh r3, [r0, #28] 8031f7a: b903 cbnz r3, 8031f7e 8031f7c: e009 b.n 8031f92 8031f7e: 6943 ldr r3, [r0, #20] 8031f80: b13b cbz r3, 8031f92 8031f82: e010 b.n 8031fa6 { empty = 1; } } else if ((node_type == MIB_NODE_AR) || (node_type == MIB_NODE_RA)) 8031f84: 1e9a subs r2, r3, #2 8031f86: 2a01 cmp r2, #1 8031f88: d805 bhi.n 8031f96 { struct mib_array_node *an; an = (struct mib_array_node *)node; if ((an->maxlength == 0) || (an->nptr == NULL)) 8031f8a: 8a43 ldrh r3, [r0, #18] 8031f8c: b10b cbz r3, 8031f92 8031f8e: 6980 ldr r0, [r0, #24] 8031f90: e004 b.n 8031f9c { empty = 1; 8031f92: 2001 movs r0, #1 8031f94: 4770 bx lr } } else if (node_type == MIB_NODE_EX) 8031f96: 2b05 cmp r3, #5 8031f98: d105 bne.n 8031fa6 { struct mib_external_node *en; en = (struct mib_external_node *)node; if (en->tree_levels == 0) 8031f9a: 7e00 ldrb r0, [r0, #24] */ static u8_t empty_table(struct mib_node *node) { u8_t node_type; u8_t empty = 0; 8031f9c: f1d0 0001 rsbs r0, r0, #1 8031fa0: bf38 it cc 8031fa2: 2000 movcc r0, #0 8031fa4: 4770 bx lr 8031fa6: 2000 movs r0, #0 empty = 1; } } } return empty; } 8031fa8: 4770 bx lr 8031faa: 0000 movs r0, r0 08031fac : * @param netif points to returned netif struct pointer */ void snmp_ifindextonetif(s32_t ifindex, struct netif **netif) { struct netif *nif = netif_list; 8031fac: 4b05 ldr r3, [pc, #20] ; (8031fc4 ) s32_t i, ifidx; ifidx = ifindex - 1; 8031fae: 3801 subs r0, #1 * @param netif points to returned netif struct pointer */ void snmp_ifindextonetif(s32_t ifindex, struct netif **netif) { struct netif *nif = netif_list; 8031fb0: 681b ldr r3, [r3, #0] s32_t i, ifidx; ifidx = ifindex - 1; i = 0; 8031fb2: 2200 movs r2, #0 while ((nif != NULL) && (i < ifidx)) 8031fb4: e001 b.n 8031fba { nif = nif->next; 8031fb6: 681b ldr r3, [r3, #0] i++; 8031fb8: 3201 adds r2, #1 struct netif *nif = netif_list; s32_t i, ifidx; ifidx = ifindex - 1; i = 0; while ((nif != NULL) && (i < ifidx)) 8031fba: b10b cbz r3, 8031fc0 8031fbc: 4282 cmp r2, r0 8031fbe: dbfa blt.n 8031fb6 { nif = nif->next; i++; } *netif = nif; 8031fc0: 600b str r3, [r1, #0] 8031fc2: 4770 bx lr 8031fc4: 20010fd0 .word 0x20010fd0 08031fc8 : * @param ifidx points to s32_t object sub-identifier */ void snmp_netiftoifindex(struct netif *netif, s32_t *ifidx) { struct netif *nif = netif_list; 8031fc8: 4b06 ldr r3, [pc, #24] ; (8031fe4 ) u16_t i; i = 0; 8031fca: 2200 movs r2, #0 * @param ifidx points to s32_t object sub-identifier */ void snmp_netiftoifindex(struct netif *netif, s32_t *ifidx) { struct netif *nif = netif_list; 8031fcc: 681b ldr r3, [r3, #0] u16_t i; i = 0; while ((nif != NULL) && (nif != netif)) 8031fce: e001 b.n 8031fd4 { nif = nif->next; 8031fd0: 681b ldr r3, [r3, #0] i++; 8031fd2: b292 uxth r2, r2 8031fd4: 3201 adds r2, #1 { struct netif *nif = netif_list; u16_t i; i = 0; while ((nif != NULL) && (nif != netif)) 8031fd6: b90b cbnz r3, 8031fdc { nif = nif->next; i++; } *ifidx = i+1; 8031fd8: 600a str r2, [r1, #0] 8031fda: 4770 bx lr { struct netif *nif = netif_list; u16_t i; i = 0; while ((nif != NULL) && (nif != netif)) 8031fdc: 4283 cmp r3, r0 8031fde: d1f7 bne.n 8031fd0 8031fe0: e7fa b.n 8031fd8 8031fe2: bf00 nop 8031fe4: 20010fd0 .word 0x20010fd0 08031fe8 : * @param ip points to output struct */ void snmp_oidtoip(s32_t *ident, ip_addr_t *ip) { IP4_ADDR(ip, ident[0], ident[1], ident[2], ident[3]); 8031fe8: 7802 ldrb r2, [r0, #0] 8031fea: 68c3 ldr r3, [r0, #12] 8031fec: ea42 6303 orr.w r3, r2, r3, lsl #24 8031ff0: 7a02 ldrb r2, [r0, #8] 8031ff2: ea43 4302 orr.w r3, r3, r2, lsl #16 8031ff6: 6842 ldr r2, [r0, #4] 8031ff8: 0612 lsls r2, r2, #24 8031ffa: ea43 4312 orr.w r3, r3, r2, lsr #16 8031ffe: 600b str r3, [r1, #0] 8032000: 4770 bx lr 08032002 : * @param ident points to s32_t ident[4] output */ void snmp_iptooid(ip_addr_t *ip, s32_t *ident) { ident[0] = ip4_addr1(ip); 8032002: 7803 ldrb r3, [r0, #0] 8032004: 600b str r3, [r1, #0] ident[1] = ip4_addr2(ip); 8032006: 7843 ldrb r3, [r0, #1] 8032008: 604b str r3, [r1, #4] ident[2] = ip4_addr3(ip); 803200a: 7883 ldrb r3, [r0, #2] 803200c: 608b str r3, [r1, #8] ident[3] = ip4_addr4(ip); 803200e: 78c3 ldrb r3, [r0, #3] 8032010: 60cb str r3, [r1, #12] 8032012: 4770 bx lr 08032014 : } struct mib_list_node * snmp_mib_ln_alloc(s32_t id) { 8032014: b510 push {r4, lr} 8032016: 4604 mov r4, r0 struct mib_list_node *ln; ln = (struct mib_list_node *)memp_malloc(MEMP_SNMP_NODE); 8032018: 200b movs r0, #11 803201a: f7fa fee9 bl 802cdf0 if (ln != NULL) 803201e: b120 cbz r0, 803202a { ln->prev = NULL; 8032020: 2300 movs r3, #0 8032022: 6003 str r3, [r0, #0] ln->next = NULL; 8032024: 6043 str r3, [r0, #4] ln->objid = id; 8032026: 6084 str r4, [r0, #8] ln->nptr = NULL; 8032028: 60c3 str r3, [r0, #12] } return ln; } 803202a: bd10 pop {r4, pc} 0803202c : void snmp_mib_ln_free(struct mib_list_node *ln) { 803202c: 4601 mov r1, r0 memp_free(MEMP_SNMP_NODE, ln); 803202e: 200b movs r0, #11 8032030: f7fa bef4 b.w 802ce1c 08032034 : } struct mib_list_rootnode * snmp_mib_lrn_alloc(void) { 8032034: b508 push {r3, lr} struct mib_list_rootnode *lrn; lrn = (struct mib_list_rootnode*)memp_malloc(MEMP_SNMP_ROOTNODE); 8032036: 200a movs r0, #10 8032038: f7fa feda bl 802cdf0 if (lrn != NULL) 803203c: b170 cbz r0, 803205c { lrn->get_object_def = noleafs_get_object_def; 803203e: 4b08 ldr r3, [pc, #32] ; (8032060 ) 8032040: 6003 str r3, [r0, #0] lrn->get_value = noleafs_get_value; 8032042: 4b08 ldr r3, [pc, #32] ; (8032064 ) 8032044: 6043 str r3, [r0, #4] lrn->set_test = noleafs_set_test; 8032046: 4b08 ldr r3, [pc, #32] ; (8032068 ) 8032048: 6083 str r3, [r0, #8] lrn->set_value = noleafs_set_value; 803204a: 4b08 ldr r3, [pc, #32] ; (803206c ) 803204c: 60c3 str r3, [r0, #12] lrn->node_type = MIB_NODE_LR; 803204e: 2304 movs r3, #4 8032050: 7403 strb r3, [r0, #16] lrn->maxlength = 0; 8032052: 2300 movs r3, #0 8032054: 8243 strh r3, [r0, #18] lrn->head = NULL; 8032056: 6143 str r3, [r0, #20] lrn->tail = NULL; 8032058: 6183 str r3, [r0, #24] lrn->count = 0; 803205a: 8383 strh r3, [r0, #28] } return lrn; } 803205c: bd08 pop {r3, pc} 803205e: bf00 nop 8032060: 080309c3 .word 0x080309c3 8032064: 080309c9 .word 0x080309c9 8032068: 080309cb .word 0x080309cb 803206c: 080309cf .word 0x080309cf 08032070 : void snmp_mib_lrn_free(struct mib_list_rootnode *lrn) { 8032070: 4601 mov r1, r0 memp_free(MEMP_SNMP_ROOTNODE, lrn); 8032072: 200a movs r0, #10 8032074: f7fa bed2 b.w 802ce1c 08032078 : * used for constructing the tree. * @return -1 if failed, 1 if inserted, 2 if present. */ s8_t snmp_mib_node_insert(struct mib_list_rootnode *rn, s32_t objid, struct mib_list_node **insn) { 8032078: b5f8 push {r3, r4, r5, r6, r7, lr} 803207a: 4605 mov r5, r0 803207c: 4616 mov r6, r2 LWIP_ASSERT("rn != NULL",rn != NULL); /* -1 = malloc failure, 0 = not inserted, 1 = inserted, 2 = was present */ insert = 0; if (rn->head == NULL) 803207e: 696c ldr r4, [r5, #20] * used for constructing the tree. * @return -1 if failed, 1 if inserted, 2 if present. */ s8_t snmp_mib_node_insert(struct mib_list_rootnode *rn, s32_t objid, struct mib_list_node **insn) { 8032080: 4608 mov r0, r1 LWIP_ASSERT("rn != NULL",rn != NULL); /* -1 = malloc failure, 0 = not inserted, 1 = inserted, 2 = was present */ insert = 0; if (rn->head == NULL) 8032082: b93c cbnz r4, 8032094 { /* empty list, add first node */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("alloc empty list objid==%"S32_F"\n",objid)); nn = snmp_mib_ln_alloc(objid); 8032084: f7ff ffc6 bl 8032014 if (nn != NULL) 8032088: b350 cbz r0, 80320e0 { rn->head = nn; 803208a: 6168 str r0, [r5, #20] rn->tail = nn; 803208c: 61a8 str r0, [r5, #24] *insn = nn; 803208e: 6030 str r0, [r6, #0] 8032090: e021 b.n 80320d6 *insn = n; insert = 2; } else if (n->objid < objid) { if (n->next == NULL) 8032092: 463c mov r4, r7 struct mib_list_node *n; /* at least one node is present */ n = rn->head; while ((n != NULL) && (insert == 0)) { if (n->objid == objid) 8032094: 68a3 ldr r3, [r4, #8] 8032096: 4283 cmp r3, r0 8032098: d102 bne.n 80320a0 { /* node is already there */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("node already there objid==%"S32_F"\n",objid)); *insn = n; 803209a: 6034 str r4, [r6, #0] insert = 2; 803209c: 2302 movs r3, #2 803209e: e023 b.n 80320e8 } else if (n->objid < objid) 80320a0: da0a bge.n 80320b8 { if (n->next == NULL) 80320a2: 6867 ldr r7, [r4, #4] 80320a4: 2f00 cmp r7, #0 80320a6: d1f4 bne.n 8032092 { /* alloc and insert at the tail */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("alloc ins tail objid==%"S32_F"\n",objid)); nn = snmp_mib_ln_alloc(objid); 80320a8: f7ff ffb4 bl 8032014 if (nn != NULL) 80320ac: b1d8 cbz r0, 80320e6 { nn->next = NULL; nn->prev = n; 80320ae: e880 0090 stmia.w r0, {r4, r7} n->next = nn; 80320b2: 6060 str r0, [r4, #4] rn->tail = nn; 80320b4: 61a8 str r0, [r5, #24] 80320b6: e00b b.n 80320d0 else { /* n->objid > objid */ /* alloc and insert between n->prev and n */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("alloc ins n->prev, objid==%"S32_F", n\n",objid)); nn = snmp_mib_ln_alloc(objid); 80320b8: f7ff ffac bl 8032014 if (nn != NULL) 80320bc: b198 cbz r0, 80320e6 { if (n->prev == NULL) 80320be: 6822 ldr r2, [r4, #0] { /* insert at the head */ nn->next = n; nn->prev = NULL; 80320c0: e880 0014 stmia.w r0, {r2, r4} /* alloc and insert between n->prev and n */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("alloc ins n->prev, objid==%"S32_F", n\n",objid)); nn = snmp_mib_ln_alloc(objid); if (nn != NULL) { if (n->prev == NULL) 80320c4: b90a cbnz r2, 80320ca { /* insert at the head */ nn->next = n; nn->prev = NULL; rn->head = nn; 80320c6: 6168 str r0, [r5, #20] 80320c8: e001 b.n 80320ce else { /* insert in the middle */ nn->next = n; nn->prev = n->prev; n->prev->next = nn; 80320ca: 6822 ldr r2, [r4, #0] 80320cc: 6050 str r0, [r2, #4] n->prev = nn; 80320ce: 6020 str r0, [r4, #0] } *insn = nn; 80320d0: 6030 str r0, [r6, #0] insert = 1; 80320d2: 2301 movs r3, #1 80320d4: e008 b.n 80320e8 } } } if (insert == 1) { rn->count += 1; 80320d6: 8bab ldrh r3, [r5, #28] 80320d8: 3301 adds r3, #1 80320da: 83ab strh r3, [r5, #28] 80320dc: 2301 movs r3, #1 80320de: e000 b.n 80320e2 *insn = nn; insert = 1; } else { insert = -1; 80320e0: 23ff movs r3, #255 ; 0xff if (insert == 1) { rn->count += 1; } LWIP_ASSERT("insert != 0",insert != 0); return insert; 80320e2: b258 sxtb r0, r3 80320e4: bdf8 pop {r3, r4, r5, r6, r7, pc} insert = 1; } else { /* insertion failure */ insert = -1; 80320e6: 23ff movs r3, #255 ; 0xff } } } } if (insert == 1) 80320e8: 2b01 cmp r3, #1 80320ea: d1fa bne.n 80320e2 80320ec: e7f3 b.n 80320d6 080320ee : { s8_t fc; struct mib_list_node *n; LWIP_ASSERT("rn != NULL",rn != NULL); n = rn->head; 80320ee: 6943 ldr r3, [r0, #20] while ((n != NULL) && (n->objid != objid)) 80320f0: e000 b.n 80320f4 { n = n->next; 80320f2: 685b ldr r3, [r3, #4] s8_t fc; struct mib_list_node *n; LWIP_ASSERT("rn != NULL",rn != NULL); n = rn->head; while ((n != NULL) && (n->objid != objid)) 80320f4: b16b cbz r3, 8032112 80320f6: 6898 ldr r0, [r3, #8] 80320f8: 4288 cmp r0, r1 80320fa: d1fa bne.n 80320f2 } if (n == NULL) { fc = 0; } else if (n->nptr == NULL) 80320fc: 68d9 ldr r1, [r3, #12] 80320fe: b161 cbz r1, 803211a } else { struct mib_list_rootnode *r; if (n->nptr->node_type == MIB_NODE_LR) 8032100: 7c08 ldrb r0, [r1, #16] 8032102: 2804 cmp r0, #4 8032104: d107 bne.n 8032116 { r = (struct mib_list_rootnode *)n->nptr; if (r->count > 1) 8032106: 8b88 ldrh r0, [r1, #28] { /* can't delete node */ fc = 2; 8032108: 2801 cmp r0, #1 803210a: bf94 ite ls 803210c: 2001 movls r0, #1 803210e: 2002 movhi r0, #2 8032110: e004 b.n 803211c { n = n->next; } if (n == NULL) { fc = 0; 8032112: 4618 mov r0, r3 8032114: e002 b.n 803211c } } else { /* other node type */ fc = 3; 8032116: 2003 movs r0, #3 8032118: e000 b.n 803211c fc = 0; } else if (n->nptr == NULL) { /* leaf, can delete node */ fc = 1; 803211a: 2001 movs r0, #1 { /* other node type */ fc = 3; } } *fn = n; 803211c: 6013 str r3, [r2, #0] return fc; } 803211e: b240 sxtb r0, r0 8032120: 4770 bx lr 08032122 : * @param n points to the node to delete * @return the nptr to be freed by caller */ struct mib_list_rootnode * snmp_mib_node_delete(struct mib_list_rootnode *rn, struct mib_list_node *n) { 8032122: b538 push {r3, r4, r5, lr} LWIP_ASSERT("rn != NULL",rn != NULL); LWIP_ASSERT("n != NULL",n != NULL); /* caller must remove this sub-tree */ next = (struct mib_list_rootnode*)(n->nptr); rn->count -= 1; 8032124: 8b83 ldrh r3, [r0, #28] LWIP_ASSERT("rn != NULL",rn != NULL); LWIP_ASSERT("n != NULL",n != NULL); /* caller must remove this sub-tree */ next = (struct mib_list_rootnode*)(n->nptr); 8032126: 68cd ldr r5, [r1, #12] rn->count -= 1; 8032128: 3b01 subs r3, #1 803212a: 8383 strh r3, [r0, #28] if (n == rn->head) 803212c: 6943 ldr r3, [r0, #20] 803212e: 4299 cmp r1, r3 * @param n points to the node to delete * @return the nptr to be freed by caller */ struct mib_list_rootnode * snmp_mib_node_delete(struct mib_list_rootnode *rn, struct mib_list_node *n) { 8032130: 4604 mov r4, r0 /* caller must remove this sub-tree */ next = (struct mib_list_rootnode*)(n->nptr); rn->count -= 1; if (n == rn->head) 8032132: d105 bne.n 8032140 { rn->head = n->next; 8032134: 684b ldr r3, [r1, #4] 8032136: 6143 str r3, [r0, #20] if (n->next != NULL) 8032138: b17b cbz r3, 803215a { /* not last node, new list begin */ n->next->prev = NULL; 803213a: 2200 movs r2, #0 803213c: 601a str r2, [r3, #0] 803213e: e00c b.n 803215a } } else if (n == rn->tail) 8032140: 6983 ldr r3, [r0, #24] 8032142: 4299 cmp r1, r3 8032144: 680b ldr r3, [r1, #0] 8032146: d104 bne.n 8032152 { rn->tail = n->prev; 8032148: 6183 str r3, [r0, #24] if (n->prev != NULL) 803214a: b133 cbz r3, 803215a { /* not last node, new list end */ n->prev->next = NULL; 803214c: 2200 movs r2, #0 803214e: 605a str r2, [r3, #4] 8032150: e003 b.n 803215a } } else { /* node must be in the middle */ n->prev->next = n->next; 8032152: 684a ldr r2, [r1, #4] 8032154: 605a str r2, [r3, #4] n->next->prev = n->prev; 8032156: 684a ldr r2, [r1, #4] 8032158: 6013 str r3, [r2, #0] } LWIP_DEBUGF(SNMP_MIB_DEBUG,("free list objid==%"S32_F"\n",n->objid)); snmp_mib_ln_free(n); 803215a: 4608 mov r0, r1 803215c: f7ff ff66 bl 803202c if (rn->count == 0) 8032160: 8ba3 ldrh r3, [r4, #28] 8032162: b90b cbnz r3, 8032168 { rn->head = NULL; 8032164: 6163 str r3, [r4, #20] rn->tail = NULL; 8032166: 61a3 str r3, [r4, #24] } return next; } 8032168: 4628 mov r0, r5 803216a: bd38 pop {r3, r4, r5, pc} 0803216c : * @param np points to the found object instance (return) * @return pointer to the requested parent (!) node if success, NULL otherwise */ struct mib_node * snmp_search_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_name_ptr *np) { 803216c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8032170: 4604 mov r4, r0 8032172: b085 sub sp, #20 8032174: 460d mov r5, r1 8032176: 461e mov r6, r3 * @param ident points to the array of sub identifiers * @param np points to the found object instance (return) * @return pointer to the requested parent (!) node if success, NULL otherwise */ struct mib_node * snmp_search_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_name_ptr *np) 8032178: f102 0804 add.w r8, r2, #4 { u8_t node_type, ext_level; ext_level = 0; 803217c: f04f 0b00 mov.w fp, #0 LWIP_DEBUGF(SNMP_MIB_DEBUG,("node==%p *ident==%"S32_F"\n",(void*)node,*ident)); while (node != NULL) 8032180: e068 b.n 8032254 { node_type = node->node_type; 8032182: 7c23 ldrb r3, [r4, #16] if ((node_type == MIB_NODE_AR) || (node_type == MIB_NODE_RA)) 8032184: 1e9a subs r2, r3, #2 8032186: 2a01 cmp r2, #1 8032188: d812 bhi.n 80321b0 { struct mib_array_node *an; u16_t i; if (ident_len > 0) 803218a: b90d cbnz r5, 8032190 } else { /* search failed, short object identifier (nosuchname) */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("an search failed, short object identifier\n")); return NULL; 803218c: 2000 movs r0, #0 803218e: e06a b.n 8032266 if (ident_len > 0) { /* array node (internal ROM or RAM, fixed length) */ an = (struct mib_array_node *)node; i = 0; while ((i < an->maxlength) && (an->objid[i] != *ident)) 8032190: 8a67 ldrh r7, [r4, #18] 8032192: 2300 movs r3, #0 8032194: b29a uxth r2, r3 8032196: 42ba cmp r2, r7 8032198: d2f8 bcs.n 803218c 803219a: 009a lsls r2, r3, #2 803219c: 6961 ldr r1, [r4, #20] 803219e: 5888 ldr r0, [r1, r2] 80321a0: f858 1c04 ldr.w r1, [r8, #-4] 80321a4: 3301 adds r3, #1 80321a6: 4288 cmp r0, r1 80321a8: d1f4 bne.n 8032194 } if (i < an->maxlength) { /* found it, if available proceed to child, otherwise inspect leaf */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("an->objid[%"U16_F"]==%"S32_F" *ident==%"S32_F"\n",i,an->objid[i],*ident)); if (an->nptr[i] == NULL) 80321aa: 69a3 ldr r3, [r4, #24] 80321ac: 589b ldr r3, [r3, r2] 80321ae: e057 b.n 8032260 /* search failed, short object identifier (nosuchname) */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("an search failed, short object identifier\n")); return NULL; } } else if(node_type == MIB_NODE_LR) 80321b0: 2b04 cmp r3, #4 80321b2: d10c bne.n 80321ce { struct mib_list_rootnode *lrn; struct mib_list_node *ln; if (ident_len > 0) 80321b4: 2d00 cmp r5, #0 80321b6: d0e9 beq.n 803218c { /* list root node (internal 'RAM', variable length) */ lrn = (struct mib_list_rootnode *)node; ln = lrn->head; 80321b8: 6963 ldr r3, [r4, #20] /* iterate over list, head to tail */ while ((ln != NULL) && (ln->objid != *ident)) 80321ba: e000 b.n 80321be { ln = ln->next; 80321bc: 685b ldr r3, [r3, #4] { /* list root node (internal 'RAM', variable length) */ lrn = (struct mib_list_rootnode *)node; ln = lrn->head; /* iterate over list, head to tail */ while ((ln != NULL) && (ln->objid != *ident)) 80321be: 2b00 cmp r3, #0 80321c0: d0e4 beq.n 803218c 80321c2: 6899 ldr r1, [r3, #8] 80321c4: f858 2c04 ldr.w r2, [r8, #-4] 80321c8: 4291 cmp r1, r2 80321ca: d1f7 bne.n 80321bc 80321cc: e047 b.n 803225e /* search failed, short object identifier (nosuchname) */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("ln search failed, short object identifier\n")); return NULL; } } else if(node_type == MIB_NODE_EX) 80321ce: 2b05 cmp r3, #5 80321d0: d12e bne.n 8032230 { struct mib_external_node *en; u16_t i, len; if (ident_len > 0) 80321d2: 2d00 cmp r5, #0 80321d4: d0da beq.n 803218c { /* external node (addressing and access via functions) */ en = (struct mib_external_node *)node; i = 0; len = en->level_length(en->addr_inf,ext_level); 80321d6: 69e3 ldr r3, [r4, #28] 80321d8: 6960 ldr r0, [r4, #20] 80321da: 4659 mov r1, fp 80321dc: 4798 blx r3 if (ident_len > 0) { /* external node (addressing and access via functions) */ en = (struct mib_external_node *)node; i = 0; 80321de: f04f 0900 mov.w r9, #0 len = en->level_length(en->addr_inf,ext_level); 80321e2: 4684 mov ip, r0 while ((i < len) && (en->ident_cmp(en->addr_inf,ext_level,i,*ident) != 0)) 80321e4: e003 b.n 80321ee { i++; 80321e6: f109 0901 add.w r9, r9, #1 80321ea: fa1f f989 uxth.w r9, r9 /* external node (addressing and access via functions) */ en = (struct mib_external_node *)node; i = 0; len = en->level_length(en->addr_inf,ext_level); while ((i < len) && (en->ident_cmp(en->addr_inf,ext_level,i,*ident) != 0)) 80321ee: 45e1 cmp r9, ip 80321f0: d0cc beq.n 803218c 80321f2: 6960 ldr r0, [r4, #20] 80321f4: f858 3c04 ldr.w r3, [r8, #-4] 80321f8: 6a27 ldr r7, [r4, #32] 80321fa: f8cd c004 str.w ip, [sp, #4] 80321fe: 4659 mov r1, fp 8032200: 464a mov r2, r9 8032202: 47b8 blx r7 8032204: f8dd c004 ldr.w ip, [sp, #4] 8032208: 2800 cmp r0, #0 803220a: d1ec bne.n 80321e6 { i++; } if (i < len) 803220c: 45e1 cmp r9, ip 803220e: d2bd bcs.n 803218c { s32_t debug_id; en->get_objid(en->addr_inf,ext_level,i,&debug_id); 8032210: 4659 mov r1, fp 8032212: ab03 add r3, sp, #12 8032214: 6a67 ldr r7, [r4, #36] ; 0x24 8032216: 6960 ldr r0, [r4, #20] 8032218: 464a mov r2, r9 803221a: 47b8 blx r7 LWIP_DEBUGF(SNMP_MIB_DEBUG,("en->objid==%"S32_F" *ident==%"S32_F"\n",debug_id,*ident)); if ((ext_level + 1) == en->tree_levels) 803221c: 7e23 ldrb r3, [r4, #24] 803221e: f10b 0b01 add.w fp, fp, #1 8032222: 459b cmp fp, r3 8032224: d100 bne.n 8032228 8032226: e00b b.n 8032240 else { /* found it, proceed to child */ ident_len--; ident++; ext_level++; 8032228: fa5f fb8b uxtb.w fp, fp 803222c: 4623 mov r3, r4 803222e: e00c b.n 803224a /* search failed, short object identifier (nosuchname) */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("en search failed, short object identifier\n")); return NULL; } } else if (node_type == MIB_NODE_SC) 8032230: 2b01 cmp r3, #1 8032232: d1ab bne.n 803218c { mib_scalar_node *sn; sn = (mib_scalar_node *)node; if ((ident_len == 1) && (*ident == 0)) 8032234: 2d01 cmp r5, #1 8032236: d1a9 bne.n 803218c 8032238: f8da 3000 ldr.w r3, [sl] 803223c: 2b00 cmp r3, #0 803223e: d1a5 bne.n 803218c { np->ident_len = ident_len; 8032240: 7035 strb r5, [r6, #0] np->ident = ident; 8032242: f8c6 a004 str.w sl, [r6, #4] return (struct mib_node*)sn; 8032246: 4620 mov r0, r4 8032248: e00d b.n 8032266 803224a: 3d01 subs r5, #1 803224c: b2ed uxtb r5, r5 803224e: f108 0804 add.w r8, r8, #4 8032252: 461c mov r4, r3 * @param ident points to the array of sub identifiers * @param np points to the found object instance (return) * @return pointer to the requested parent (!) node if success, NULL otherwise */ struct mib_node * snmp_search_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_name_ptr *np) 8032254: f1a8 0a04 sub.w sl, r8, #4 { u8_t node_type, ext_level; ext_level = 0; LWIP_DEBUGF(SNMP_MIB_DEBUG,("node==%p *ident==%"S32_F"\n",(void*)node,*ident)); while (node != NULL) 8032258: 2c00 cmp r4, #0 803225a: d192 bne.n 8032182 803225c: e796 b.n 803218c } if (ln != NULL) { /* found it, proceed to child */; LWIP_DEBUGF(SNMP_MIB_DEBUG,("ln->objid==%"S32_F" *ident==%"S32_F"\n",ln->objid,*ident)); if (ln->nptr == NULL) 803225e: 68db ldr r3, [r3, #12] 8032260: 2b00 cmp r3, #0 8032262: d1f2 bne.n 803224a 8032264: e7ec b.n 8032240 } } /* done, found nothing */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("search failed node==%p\n",(void*)node)); return NULL; } 8032266: b005 add sp, #20 8032268: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 0803226c : /** * Tree expansion. */ struct mib_node * snmp_expand_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) { 803226c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8032270: 461d mov r5, r3 8032272: b08b sub sp, #44 ; 0x2c u8_t node_type, ext_level, climb_tree; ext_level = 0; /* reset node stack */ node_stack_cnt = 0; 8032274: 4ba4 ldr r3, [pc, #656] ; (8032508 ) 8032276: f04f 0a00 mov.w sl, #0 j = (u8_t)i + 1; if (j < len) { /* right node is the current external node */ cur_node.r_ptr = node; en->get_objid(en->addr_inf,ext_level,j,&cur_node.r_id); 803227a: af08 add r7, sp, #32 /** * Tree expansion. */ struct mib_node * snmp_expand_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) { 803227c: 4604 mov r4, r0 803227e: 460e mov r6, r1 8032280: 4690 mov r8, r2 u8_t node_type, ext_level, climb_tree; ext_level = 0; /* reset node stack */ node_stack_cnt = 0; 8032282: f883 a000 strb.w sl, [r3] j = (u8_t)i + 1; if (j < len) { /* right node is the current external node */ cur_node.r_ptr = node; en->get_objid(en->addr_inf,ext_level,j,&cur_node.r_id); 8032286: 9705 str r7, [sp, #20] u8_t node_type, ext_level, climb_tree; ext_level = 0; /* reset node stack */ node_stack_cnt = 0; while (node != NULL) 8032288: e19c b.n 80325c4 { climb_tree = 0; node_type = node->node_type; 803228a: 7c23 ldrb r3, [r4, #16] if ((node_type == MIB_NODE_AR) || (node_type == MIB_NODE_RA)) 803228c: 1e9a subs r2, r3, #2 803228e: 2a01 cmp r2, #1 8032290: f200 808f bhi.w 80323b2 8032294: 8a67 ldrh r7, [r4, #18] struct mib_array_node *an; u16_t i; /* array node (internal ROM or RAM, fixed length) */ an = (struct mib_array_node *)node; if (ident_len > 0) 8032296: b90e cbnz r6, 803229c else { u8_t j; /* ident_len == 0, complete with leftmost '.thing' */ j = 0; while ((j < an->maxlength) && empty_table(an->nptr[j])) 8032298: 46b1 mov r9, r6 803229a: e06f b.n 803237c /* array node (internal ROM or RAM, fixed length) */ an = (struct mib_array_node *)node; if (ident_len > 0) { i = 0; while ((i < an->maxlength) && (an->objid[i] < *ident)) 803229c: f04f 0c00 mov.w ip, #0 80322a0: fa1f f28c uxth.w r2, ip 80322a4: 42ba cmp r2, r7 80322a6: f080 8168 bcs.w 803257a 80322aa: 6963 ldr r3, [r4, #20] 80322ac: f853 102c ldr.w r1, [r3, ip, lsl #2] 80322b0: f8d8 3000 ldr.w r3, [r8] 80322b4: 4299 cmp r1, r3 80322b6: ea4f 098c mov.w r9, ip, lsl #2 80322ba: f10c 0c01 add.w ip, ip, #1 80322be: dbef blt.n 80322a0 } if (i < an->maxlength) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("an->objid[%"U16_F"]==%"S32_F" *ident==%"S32_F"\n",i,an->objid[i],*ident)); /* add identifier to oidret */ oidret->id[oidret->len] = an->objid[i]; 80322c0: 782b ldrb r3, [r5, #0] 80322c2: eb05 0783 add.w r7, r5, r3, lsl #2 80322c6: 6079 str r1, [r7, #4] (oidret->len)++; 80322c8: 1c59 adds r1, r3, #1 80322ca: 7029 strb r1, [r5, #0] if (an->nptr[i] == NULL) 80322cc: f8d4 b018 ldr.w fp, [r4, #24] 80322d0: f85b 0009 ldr.w r0, [fp, r9] 80322d4: b998 cbnz r0, 80322fe { LWIP_DEBUGF(SNMP_MIB_DEBUG,("leaf node\n")); /* leaf node (e.g. in a fixed size table) */ if (an->objid[i] > *ident) 80322d6: 6960 ldr r0, [r4, #20] 80322d8: f850 6009 ldr.w r6, [r0, r9] 80322dc: f8d8 0000 ldr.w r0, [r8] 80322e0: 4286 cmp r6, r0 80322e2: f300 8173 bgt.w 80325cc { return (struct mib_node*)an; } else if ((i + 1) < an->maxlength) 80322e6: 8a60 ldrh r0, [r4, #18] { /* an->objid[i] == *ident */ (oidret->len)--; 80322e8: 702b strb r3, [r5, #0] /* leaf node (e.g. in a fixed size table) */ if (an->objid[i] > *ident) { return (struct mib_node*)an; } else if ((i + 1) < an->maxlength) 80322ea: 3201 adds r2, #1 80322ec: 4282 cmp r2, r0 80322ee: f280 8144 bge.w 803257a { /* an->objid[i] == *ident */ (oidret->len)--; oidret->id[oidret->len] = an->objid[i + 1]; 80322f2: 6963 ldr r3, [r4, #20] 80322f4: f853 302c ldr.w r3, [r3, ip, lsl #2] (oidret->len)++; 80322f8: 7029 strb r1, [r5, #0] } else if ((i + 1) < an->maxlength) { /* an->objid[i] == *ident */ (oidret->len)--; oidret->id[oidret->len] = an->objid[i + 1]; 80322fa: 607b str r3, [r7, #4] 80322fc: e166 b.n 80325cc struct nse cur_node; LWIP_DEBUGF(SNMP_MIB_DEBUG,("non-leaf node\n")); /* non-leaf, store right child ptr and id */ LWIP_ASSERT("i < 0xff", i < 0xff); j = (u8_t)i + 1; 80322fe: 3201 adds r2, #1 while ((j < an->maxlength) && (empty_table(an->nptr[j]))) 8032300: 8a61 ldrh r1, [r4, #18] struct nse cur_node; LWIP_DEBUGF(SNMP_MIB_DEBUG,("non-leaf node\n")); /* non-leaf, store right child ptr and id */ LWIP_ASSERT("i < 0xff", i < 0xff); j = (u8_t)i + 1; 8032302: fa5f fc82 uxtb.w ip, r2 while ((j < an->maxlength) && (empty_table(an->nptr[j]))) 8032306: 2700 movs r7, #0 /** * Tree expansion. */ struct mib_node * snmp_expand_tree(struct mib_node *node, u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) 8032308: eb0c 0307 add.w r3, ip, r7 803230c: b2db uxtb r3, r3 LWIP_DEBUGF(SNMP_MIB_DEBUG,("non-leaf node\n")); /* non-leaf, store right child ptr and id */ LWIP_ASSERT("i < 0xff", i < 0xff); j = (u8_t)i + 1; while ((j < an->maxlength) && (empty_table(an->nptr[j]))) 803230e: 428b cmp r3, r1 8032310: d21a bcs.n 8032348 8032312: b21b sxth r3, r3 8032314: 009a lsls r2, r3, #2 8032316: f85b 3023 ldr.w r3, [fp, r3, lsl #2] 803231a: 9104 str r1, [sp, #16] 803231c: 4618 mov r0, r3 803231e: 9203 str r2, [sp, #12] 8032320: 9302 str r3, [sp, #8] 8032322: f8cd c004 str.w ip, [sp, #4] 8032326: f7ff fe23 bl 8031f70 803232a: 3701 adds r7, #1 803232c: 9904 ldr r1, [sp, #16] 803232e: 9a03 ldr r2, [sp, #12] 8032330: 9b02 ldr r3, [sp, #8] 8032332: f8dd c004 ldr.w ip, [sp, #4] 8032336: 2800 cmp r0, #0 8032338: d1e6 bne.n 8032308 { j++; } if (j < an->maxlength) { cur_node.r_ptr = an->nptr[j]; 803233a: 9307 str r3, [sp, #28] cur_node.r_id = an->objid[j]; 803233c: 6963 ldr r3, [r4, #20] 803233e: 589b ldr r3, [r3, r2] cur_node.r_nl = 0; 8032340: f88d 0024 strb.w r0, [sp, #36] ; 0x24 j++; } if (j < an->maxlength) { cur_node.r_ptr = an->nptr[j]; cur_node.r_id = an->objid[j]; 8032344: 9308 str r3, [sp, #32] 8032346: e001 b.n 803234c cur_node.r_nl = 0; } else { cur_node.r_ptr = NULL; 8032348: 2300 movs r3, #0 803234a: 9307 str r3, [sp, #28] } push_node(&cur_node); 803234c: a807 add r0, sp, #28 803234e: f7ff fdfb bl 8031f48 if (an->objid[i] == *ident) 8032352: 6963 ldr r3, [r4, #20] 8032354: f853 2009 ldr.w r2, [r3, r9] 8032358: f8d8 3000 ldr.w r3, [r8] 803235c: 429a cmp r2, r3 803235e: d104 bne.n 803236a { ident_len--; 8032360: 3e01 subs r6, #1 8032362: b2f6 uxtb r6, r6 ident++; 8032364: f108 0804 add.w r8, r8, #4 8032368: e000 b.n 803236c } else { /* an->objid[i] < *ident */ ident_len = 0; 803236a: 2600 movs r6, #0 } /* follow next child pointer */ node = an->nptr[i]; 803236c: 69a3 ldr r3, [r4, #24] 803236e: f853 3009 ldr.w r3, [r3, r9] 8032372: e140 b.n 80325f6 u8_t j; /* ident_len == 0, complete with leftmost '.thing' */ j = 0; while ((j < an->maxlength) && empty_table(an->nptr[j])) { j++; 8032374: f109 0901 add.w r9, r9, #1 8032378: fa5f f989 uxtb.w r9, r9 else { u8_t j; /* ident_len == 0, complete with leftmost '.thing' */ j = 0; while ((j < an->maxlength) && empty_table(an->nptr[j])) 803237c: 45b9 cmp r9, r7 803237e: f080 80fc bcs.w 803257a 8032382: fa0f f289 sxth.w r2, r9 8032386: 69a3 ldr r3, [r4, #24] 8032388: f853 0022 ldr.w r0, [r3, r2, lsl #2] 803238c: ea4f 0b82 mov.w fp, r2, lsl #2 8032390: f7ff fdee bl 8031f70 8032394: 2800 cmp r0, #0 8032396: d1ed bne.n 8032374 j++; } if (j < an->maxlength) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("left an->objid[j]==%"S32_F"\n",an->objid[j])); oidret->id[oidret->len] = an->objid[j]; 8032398: 6962 ldr r2, [r4, #20] 803239a: 782b ldrb r3, [r5, #0] 803239c: f852 100b ldr.w r1, [r2, fp] 80323a0: eb05 0283 add.w r2, r5, r3, lsl #2 (oidret->len)++; 80323a4: 3301 adds r3, #1 80323a6: 702b strb r3, [r5, #0] if (an->nptr[j] == NULL) 80323a8: 69a3 ldr r3, [r4, #24] j++; } if (j < an->maxlength) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("left an->objid[j]==%"S32_F"\n",an->objid[j])); oidret->id[oidret->len] = an->objid[j]; 80323aa: 6051 str r1, [r2, #4] (oidret->len)++; if (an->nptr[j] == NULL) 80323ac: f853 300b ldr.w r3, [r3, fp] 80323b0: e11f b.n 80325f2 /* j == an->maxlength */ climb_tree = 1; } } } else if(node_type == MIB_NODE_LR) 80323b2: 2b04 cmp r3, #4 80323b4: d14c bne.n 8032450 80323b6: 6967 ldr r7, [r4, #20] struct mib_list_rootnode *lrn; struct mib_list_node *ln; /* list root node (internal 'RAM', variable length) */ lrn = (struct mib_list_rootnode *)node; if (ident_len > 0) 80323b8: 2e00 cmp r6, #0 80323ba: d040 beq.n 803243e { ln = lrn->head; /* iterate over list, head to tail */ while ((ln != NULL) && (ln->objid < *ident)) 80323bc: e000 b.n 80323c0 { ln = ln->next; 80323be: 687f ldr r7, [r7, #4] lrn = (struct mib_list_rootnode *)node; if (ident_len > 0) { ln = lrn->head; /* iterate over list, head to tail */ while ((ln != NULL) && (ln->objid < *ident)) 80323c0: 2f00 cmp r7, #0 80323c2: f000 80da beq.w 803257a 80323c6: 68ba ldr r2, [r7, #8] 80323c8: f8d8 3000 ldr.w r3, [r8] 80323cc: 429a cmp r2, r3 80323ce: dbf6 blt.n 80323be ln = ln->next; } if (ln != NULL) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("ln->objid==%"S32_F" *ident==%"S32_F"\n",ln->objid,*ident)); oidret->id[oidret->len] = ln->objid; 80323d0: 782b ldrb r3, [r5, #0] 80323d2: eb05 0183 add.w r1, r5, r3, lsl #2 80323d6: 604a str r2, [r1, #4] (oidret->len)++; 80323d8: 1c5a adds r2, r3, #1 80323da: 702a strb r2, [r5, #0] if (ln->nptr == NULL) 80323dc: 68f8 ldr r0, [r7, #12] 80323de: b978 cbnz r0, 8032400 { /* leaf node */ if (ln->objid > *ident) 80323e0: 68b8 ldr r0, [r7, #8] 80323e2: f8d8 6000 ldr.w r6, [r8] 80323e6: 42b0 cmp r0, r6 80323e8: f300 80f0 bgt.w 80325cc { return (struct mib_node*)lrn; } else if (ln->next != NULL) 80323ec: 6878 ldr r0, [r7, #4] { /* ln->objid == *ident */ (oidret->len)--; 80323ee: 702b strb r3, [r5, #0] /* leaf node */ if (ln->objid > *ident) { return (struct mib_node*)lrn; } else if (ln->next != NULL) 80323f0: 2800 cmp r0, #0 80323f2: f000 80c2 beq.w 803257a { /* ln->objid == *ident */ (oidret->len)--; oidret->id[oidret->len] = ln->next->objid; 80323f6: 687b ldr r3, [r7, #4] 80323f8: 689b ldr r3, [r3, #8] (oidret->len)++; 80323fa: 702a strb r2, [r5, #0] } else if (ln->next != NULL) { /* ln->objid == *ident */ (oidret->len)--; oidret->id[oidret->len] = ln->next->objid; 80323fc: 604b str r3, [r1, #4] 80323fe: e0e5 b.n 80325cc { struct mib_list_node *jn; struct nse cur_node; /* non-leaf, store right child ptr and id */ jn = ln->next; 8032400: 687c ldr r4, [r7, #4] while ((jn != NULL) && empty_table(jn->nptr)) 8032402: e000 b.n 8032406 { jn = jn->next; 8032404: 6864 ldr r4, [r4, #4] struct mib_list_node *jn; struct nse cur_node; /* non-leaf, store right child ptr and id */ jn = ln->next; while ((jn != NULL) && empty_table(jn->nptr)) 8032406: 2c00 cmp r4, #0 8032408: f000 80e9 beq.w 80325de 803240c: f8d4 900c ldr.w r9, [r4, #12] 8032410: 4648 mov r0, r9 8032412: f7ff fdad bl 8031f70 8032416: 2800 cmp r0, #0 8032418: d1f4 bne.n 8032404 803241a: e0d9 b.n 80325d0 } else { cur_node.r_ptr = NULL; } push_node(&cur_node); 803241c: a807 add r0, sp, #28 803241e: f7ff fd93 bl 8031f48 if (ln->objid == *ident) 8032422: 68ba ldr r2, [r7, #8] 8032424: f8d8 3000 ldr.w r3, [r8] 8032428: 429a cmp r2, r3 803242a: d104 bne.n 8032436 { ident_len--; 803242c: 3e01 subs r6, #1 803242e: b2f6 uxtb r6, r6 ident++; 8032430: f108 0804 add.w r8, r8, #4 8032434: e000 b.n 8032438 } else { /* ln->objid < *ident */ ident_len = 0; 8032436: 2600 movs r6, #0 } /* follow next child pointer */ node = ln->nptr; 8032438: 68fb ldr r3, [r7, #12] 803243a: e0dc b.n 80325f6 struct mib_list_node *jn; /* ident_len == 0, complete with leftmost '.thing' */ jn = lrn->head; while ((jn != NULL) && empty_table(jn->nptr)) { jn = jn->next; 803243c: 687f ldr r7, [r7, #4] else { struct mib_list_node *jn; /* ident_len == 0, complete with leftmost '.thing' */ jn = lrn->head; while ((jn != NULL) && empty_table(jn->nptr)) 803243e: 2f00 cmp r7, #0 8032440: f000 809b beq.w 803257a 8032444: 68f8 ldr r0, [r7, #12] 8032446: f7ff fd93 bl 8031f70 803244a: 2800 cmp r0, #0 803244c: d1f6 bne.n 803243c 803244e: e0c8 b.n 80325e2 /* jn == NULL */ climb_tree = 1; } } } else if(node_type == MIB_NODE_EX) 8032450: 2b05 cmp r3, #5 8032452: f040 8086 bne.w 8032562 struct mib_external_node *en; s32_t ex_id; /* external node (addressing and access via functions) */ en = (struct mib_external_node *)node; if (ident_len > 0) 8032456: 2e00 cmp r6, #0 8032458: d06e beq.n 8032538 { u16_t i, len; i = 0; len = en->level_length(en->addr_inf,ext_level); 803245a: 69e3 ldr r3, [r4, #28] 803245c: 6960 ldr r0, [r4, #20] 803245e: 4651 mov r1, sl 8032460: 4798 blx r3 en = (struct mib_external_node *)node; if (ident_len > 0) { u16_t i, len; i = 0; 8032462: f04f 0900 mov.w r9, #0 len = en->level_length(en->addr_inf,ext_level); 8032466: 4683 mov fp, r0 while ((i < len) && (en->ident_cmp(en->addr_inf,ext_level,i,*ident) < 0)) 8032468: e003 b.n 8032472 { i++; 803246a: f109 0901 add.w r9, r9, #1 803246e: fa1f f989 uxth.w r9, r9 { u16_t i, len; i = 0; len = en->level_length(en->addr_inf,ext_level); while ((i < len) && (en->ident_cmp(en->addr_inf,ext_level,i,*ident) < 0)) 8032472: 45d9 cmp r9, fp 8032474: f000 8081 beq.w 803257a 8032478: 6a27 ldr r7, [r4, #32] 803247a: 6960 ldr r0, [r4, #20] 803247c: f8d8 3000 ldr.w r3, [r8] 8032480: 4651 mov r1, sl 8032482: 464a mov r2, r9 8032484: 47b8 blx r7 8032486: 2800 cmp r0, #0 8032488: dbef blt.n 803246a { i++; } if (i < len) 803248a: 45d9 cmp r9, fp 803248c: d275 bcs.n 803257a { /* add identifier to oidret */ en->get_objid(en->addr_inf,ext_level,i,&ex_id); 803248e: 4651 mov r1, sl 8032490: 464a mov r2, r9 8032492: ab06 add r3, sp, #24 8032494: 6a67 ldr r7, [r4, #36] ; 0x24 8032496: 6960 ldr r0, [r4, #20] 8032498: 47b8 blx r7 LWIP_DEBUGF(SNMP_MIB_DEBUG,("en->objid[%"U16_F"]==%"S32_F" *ident==%"S32_F"\n",i,ex_id,*ident)); oidret->id[oidret->len] = ex_id; 803249a: 782b ldrb r3, [r5, #0] 803249c: 9a06 ldr r2, [sp, #24] 803249e: eb05 0183 add.w r1, r5, r3, lsl #2 (oidret->len)++; if ((ext_level + 1) == en->tree_levels) 80324a2: f10a 0c01 add.w ip, sl, #1 if (i < len) { /* add identifier to oidret */ en->get_objid(en->addr_inf,ext_level,i,&ex_id); LWIP_DEBUGF(SNMP_MIB_DEBUG,("en->objid[%"U16_F"]==%"S32_F" *ident==%"S32_F"\n",i,ex_id,*ident)); oidret->id[oidret->len] = ex_id; 80324a6: 604a str r2, [r1, #4] (oidret->len)++; 80324a8: 1c59 adds r1, r3, #1 80324aa: 7029 strb r1, [r5, #0] if ((ext_level + 1) == en->tree_levels) 80324ac: 7e21 ldrb r1, [r4, #24] 80324ae: 458c cmp ip, r1 80324b0: d118 bne.n 80324e4 { LWIP_DEBUGF(SNMP_MIB_DEBUG,("leaf node\n")); /* leaf node */ if (ex_id > *ident) 80324b2: f8d8 1000 ldr.w r1, [r8] 80324b6: 428a cmp r2, r1 80324b8: f300 8088 bgt.w 80325cc { return (struct mib_node*)en; } else if ((i + 1) < len) 80324bc: f109 0201 add.w r2, r9, #1 80324c0: 455a cmp r2, fp 80324c2: da0d bge.n 80324e0 { /* ex_id == *ident */ en->get_objid(en->addr_inf,ext_level,i + 1,&ex_id); 80324c4: ab06 add r3, sp, #24 80324c6: 6a66 ldr r6, [r4, #36] ; 0x24 80324c8: 6960 ldr r0, [r4, #20] 80324ca: 4651 mov r1, sl 80324cc: b292 uxth r2, r2 80324ce: 47b0 blx r6 (oidret->len)--; 80324d0: 782b ldrb r3, [r5, #0] 80324d2: 3b01 subs r3, #1 oidret->id[oidret->len] = ex_id; 80324d4: b2db uxtb r3, r3 80324d6: eb05 0583 add.w r5, r5, r3, lsl #2 80324da: 9b06 ldr r3, [sp, #24] 80324dc: 606b str r3, [r5, #4] 80324de: e075 b.n 80325cc return (struct mib_node*)en; } else { /* (i + 1) == len */ (oidret->len)--; 80324e0: 702b strb r3, [r5, #0] 80324e2: e04a b.n 803257a struct nse cur_node; LWIP_DEBUGF(SNMP_MIB_DEBUG,("non-leaf node\n")); /* non-leaf, store right child ptr and id */ LWIP_ASSERT("i < 0xff", i < 0xff); j = (u8_t)i + 1; 80324e4: f109 0201 add.w r2, r9, #1 if (j < len) 80324e8: b2d2 uxtb r2, r2 80324ea: 455a cmp r2, fp 80324ec: d20e bcs.n 803250c { /* right node is the current external node */ cur_node.r_ptr = node; 80324ee: 9407 str r4, [sp, #28] en->get_objid(en->addr_inf,ext_level,j,&cur_node.r_id); 80324f0: 6960 ldr r0, [r4, #20] 80324f2: 9b05 ldr r3, [sp, #20] 80324f4: f8cd c004 str.w ip, [sp, #4] 80324f8: 4651 mov r1, sl 80324fa: 6a67 ldr r7, [r4, #36] ; 0x24 80324fc: 47b8 blx r7 cur_node.r_nl = ext_level + 1; 80324fe: f8dd c004 ldr.w ip, [sp, #4] 8032502: f88d c024 strb.w ip, [sp, #36] ; 0x24 8032506: e003 b.n 8032510 8032508: 2000e288 .word 0x2000e288 } else { cur_node.r_ptr = NULL; 803250c: 2300 movs r3, #0 803250e: 9307 str r3, [sp, #28] } push_node(&cur_node); 8032510: a807 add r0, sp, #28 8032512: f7ff fd19 bl 8031f48 if (en->ident_cmp(en->addr_inf,ext_level,i,*ident) == 0) 8032516: 6a27 ldr r7, [r4, #32] 8032518: 6960 ldr r0, [r4, #20] 803251a: f8d8 3000 ldr.w r3, [r8] 803251e: 4651 mov r1, sl 8032520: 464a mov r2, r9 8032522: 47b8 blx r7 8032524: b920 cbnz r0, 8032530 { ident_len--; 8032526: 3e01 subs r6, #1 8032528: b2f6 uxtb r6, r6 ident++; 803252a: f108 0804 add.w r8, r8, #4 803252e: e000 b.n 8032532 } else { /* external id < *ident */ ident_len = 0; 8032530: 2600 movs r6, #0 } /* proceed to child */ ext_level++; 8032532: f10a 0a01 add.w sl, sl, #1 8032536: e011 b.n 803255c } } else { /* ident_len == 0, complete with leftmost '.thing' */ en->get_objid(en->addr_inf,ext_level,0,&ex_id); 8032538: 4651 mov r1, sl 803253a: 4632 mov r2, r6 803253c: ab06 add r3, sp, #24 803253e: 6a67 ldr r7, [r4, #36] ; 0x24 8032540: 6960 ldr r0, [r4, #20] 8032542: 47b8 blx r7 LWIP_DEBUGF(SNMP_MIB_DEBUG,("left en->objid==%"S32_F"\n",ex_id)); oidret->id[oidret->len] = ex_id; 8032544: 782b ldrb r3, [r5, #0] 8032546: 9a06 ldr r2, [sp, #24] 8032548: eb05 0183 add.w r1, r5, r3, lsl #2 (oidret->len)++; 803254c: 3301 adds r3, #1 else { /* ident_len == 0, complete with leftmost '.thing' */ en->get_objid(en->addr_inf,ext_level,0,&ex_id); LWIP_DEBUGF(SNMP_MIB_DEBUG,("left en->objid==%"S32_F"\n",ex_id)); oidret->id[oidret->len] = ex_id; 803254e: 604a str r2, [r1, #4] (oidret->len)++; 8032550: 702b strb r3, [r5, #0] if ((ext_level + 1) == en->tree_levels) 8032552: 7e23 ldrb r3, [r4, #24] 8032554: f10a 0a01 add.w sl, sl, #1 8032558: 459a cmp sl, r3 803255a: d037 beq.n 80325cc return (struct mib_node*)en; } else { /* no leaf, proceed to child */ ext_level++; 803255c: fa5f fa8a uxtb.w sl, sl 8032560: e030 b.n 80325c4 } } } else if(node_type == MIB_NODE_SC) 8032562: 2b01 cmp r3, #1 8032564: d001 beq.n 803256a } else { /* unknown/unhandled node_type */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("expand failed node_type %"U16_F" unkown\n",(u16_t)node_type)); return NULL; 8032566: 2000 movs r0, #0 8032568: e047 b.n 80325fa { mib_scalar_node *sn; /* scalar node */ sn = (mib_scalar_node *)node; if (ident_len > 0) 803256a: b936 cbnz r6, 803257a climb_tree = 1; } else { /* ident_len == 0, complete object identifier */ oidret->id[oidret->len] = 0; 803256c: 782b ldrb r3, [r5, #0] 803256e: eb05 0283 add.w r2, r5, r3, lsl #2 (oidret->len)++; 8032572: 3301 adds r3, #1 climb_tree = 1; } else { /* ident_len == 0, complete object identifier */ oidret->id[oidret->len] = 0; 8032574: 6056 str r6, [r2, #4] (oidret->len)++; 8032576: 702b strb r3, [r5, #0] 8032578: e028 b.n 80325cc 803257a: 4921 ldr r1, [pc, #132] ; (8032600 ) struct nse child; /* find right child ptr */ child.r_ptr = NULL; child.r_id = 0; child.r_nl = 0; 803257c: f04f 0a00 mov.w sl, #0 8032580: 780b ldrb r3, [r1, #0] pop_node(struct nse* node) { if (node_stack_cnt > 0) { node_stack_cnt--; *node = node_stack[node_stack_cnt]; 8032582: 4920 ldr r1, [pc, #128] ; (8032604 ) { struct nse child; /* find right child ptr */ child.r_ptr = NULL; child.r_id = 0; 8032584: 4652 mov r2, sl if (climb_tree) { struct nse child; /* find right child ptr */ child.r_ptr = NULL; 8032586: 4654 mov r4, sl pop_node(struct nse* node) { if (node_stack_cnt > 0) { node_stack_cnt--; *node = node_stack[node_stack_cnt]; 8032588: 260c movs r6, #12 /* find right child ptr */ child.r_ptr = NULL; child.r_id = 0; child.r_nl = 0; while ((node_stack_cnt > 0) && (child.r_ptr == NULL)) 803258a: e00b b.n 80325a4 static void pop_node(struct nse* node) { if (node_stack_cnt > 0) { node_stack_cnt--; 803258c: 3b01 subs r3, #1 803258e: b2db uxtb r3, r3 *node = node_stack[node_stack_cnt]; 8032590: fb06 f203 mul.w r2, r6, r3 8032594: 1888 adds r0, r1, r2 8032596: 588c ldr r4, [r1, r2] 8032598: f890 a008 ldrb.w sl, [r0, #8] 803259c: 6842 ldr r2, [r0, #4] child.r_nl = 0; while ((node_stack_cnt > 0) && (child.r_ptr == NULL)) { pop_node(&child); /* trim returned oid */ (oidret->len)--; 803259e: 7828 ldrb r0, [r5, #0] 80325a0: 3801 subs r0, #1 80325a2: 7028 strb r0, [r5, #0] /* find right child ptr */ child.r_ptr = NULL; child.r_id = 0; child.r_nl = 0; while ((node_stack_cnt > 0) && (child.r_ptr == NULL)) 80325a4: b91b cbnz r3, 80325ae 80325a6: 4f16 ldr r7, [pc, #88] ; (8032600 ) 80325a8: 703b strb r3, [r7, #0] { pop_node(&child); /* trim returned oid */ (oidret->len)--; } if (child.r_ptr != NULL) 80325aa: b924 cbnz r4, 80325b6 80325ac: e7db b.n 8032566 /* find right child ptr */ child.r_ptr = NULL; child.r_id = 0; child.r_nl = 0; while ((node_stack_cnt > 0) && (child.r_ptr == NULL)) 80325ae: 2c00 cmp r4, #0 80325b0: d0ec beq.n 803258c 80325b2: 4913 ldr r1, [pc, #76] ; (8032600 ) 80325b4: 700b strb r3, [r1, #0] } if (child.r_ptr != NULL) { /* incoming ident is useless beyond this point */ ident_len = 0; oidret->id[oidret->len] = child.r_id; 80325b6: 782b ldrb r3, [r5, #0] 80325b8: eb05 0183 add.w r1, r5, r3, lsl #2 oidret->len++; 80325bc: 3301 adds r3, #1 } if (child.r_ptr != NULL) { /* incoming ident is useless beyond this point */ ident_len = 0; oidret->id[oidret->len] = child.r_id; 80325be: 604a str r2, [r1, #4] oidret->len++; 80325c0: 702b strb r3, [r5, #0] (oidret->len)--; } if (child.r_ptr != NULL) { /* incoming ident is useless beyond this point */ ident_len = 0; 80325c2: 2600 movs r6, #0 u8_t node_type, ext_level, climb_tree; ext_level = 0; /* reset node stack */ node_stack_cnt = 0; while (node != NULL) 80325c4: 2c00 cmp r4, #0 80325c6: f47f ae60 bne.w 803228a 80325ca: e7cc b.n 8032566 if (jn != NULL) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("left jn->objid==%"S32_F"\n",jn->objid)); oidret->id[oidret->len] = jn->objid; (oidret->len)++; if (jn->nptr == NULL) 80325cc: 4620 mov r0, r4 80325ce: e014 b.n 80325fa jn = jn->next; } if (jn != NULL) { cur_node.r_ptr = jn->nptr; cur_node.r_id = jn->objid; 80325d0: 68a3 ldr r3, [r4, #8] { jn = jn->next; } if (jn != NULL) { cur_node.r_ptr = jn->nptr; 80325d2: f8cd 901c str.w r9, [sp, #28] cur_node.r_id = jn->objid; 80325d6: 9308 str r3, [sp, #32] cur_node.r_nl = 0; 80325d8: f88d 0024 strb.w r0, [sp, #36] ; 0x24 80325dc: e71e b.n 803241c } else { cur_node.r_ptr = NULL; 80325de: 9407 str r4, [sp, #28] 80325e0: e71c b.n 803241c jn = jn->next; } if (jn != NULL) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("left jn->objid==%"S32_F"\n",jn->objid)); oidret->id[oidret->len] = jn->objid; 80325e2: 782b ldrb r3, [r5, #0] 80325e4: 68ba ldr r2, [r7, #8] 80325e6: eb05 0183 add.w r1, r5, r3, lsl #2 (oidret->len)++; 80325ea: 3301 adds r3, #1 80325ec: 702b strb r3, [r5, #0] if (jn->nptr == NULL) 80325ee: 68fb ldr r3, [r7, #12] jn = jn->next; } if (jn != NULL) { LWIP_DEBUGF(SNMP_MIB_DEBUG,("left jn->objid==%"S32_F"\n",jn->objid)); oidret->id[oidret->len] = jn->objid; 80325f0: 604a str r2, [r1, #4] (oidret->len)++; if (jn->nptr == NULL) 80325f2: 2b00 cmp r3, #0 80325f4: d0ea beq.n 80325cc (oidret->len)--; } if (child.r_ptr != NULL) { /* incoming ident is useless beyond this point */ ident_len = 0; 80325f6: 461c mov r4, r3 80325f8: e7e4 b.n 80325c4 } } /* done, found nothing */ LWIP_DEBUGF(SNMP_MIB_DEBUG,("expand failed node==%p\n",(void*)node)); return NULL; } 80325fa: b00b add sp, #44 ; 0x2c 80325fc: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 8032600: 2000e288 .word 0x2000e288 8032604: 2000e28c .word 0x2000e28c 08032608 : * @return 1 if it matches, 0 otherwise */ u8_t snmp_iso_prefix_tst(u8_t ident_len, s32_t *ident) { if ((ident_len > 3) && 8032608: 2803 cmp r0, #3 803260a: d90d bls.n 8032628 803260c: 680b ldr r3, [r1, #0] 803260e: 2b01 cmp r3, #1 8032610: d10a bne.n 8032628 (ident[0] == 1) && (ident[1] == 3) && 8032612: 684b ldr r3, [r1, #4] 8032614: 2b03 cmp r3, #3 8032616: d107 bne.n 8032628 8032618: 688b ldr r3, [r1, #8] 803261a: 2b06 cmp r3, #6 803261c: d104 bne.n 8032628 (ident[2] == 6) && (ident[3] == 1)) 803261e: 68c8 ldr r0, [r1, #12] { return 1; 8032620: 1e43 subs r3, r0, #1 8032622: 4258 negs r0, r3 8032624: 4158 adcs r0, r3 8032626: 4770 bx lr } else { return 0; 8032628: 2000 movs r0, #0 } } 803262a: 4770 bx lr 0803262c : i = 0; prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; ident_len = ((ident_len < 4)?ident_len:4); while ((i < ident_len) && ((*ident) <= (*prefix_ptr))) 803262c: 2300 movs r3, #0 * * @note ident_len 0 is allowed, expanding to the first known object id!! */ u8_t snmp_iso_prefix_expand(u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) { 803262e: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} s32_t *ret_ptr; u8_t i; i = 0; prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; 8032632: 1d15 adds r5, r2, #4 ident_len = ((ident_len < 4)?ident_len:4); 8032634: 2804 cmp r0, #4 8032636: bf34 ite cc 8032638: 4680 movcc r8, r0 803263a: f04f 0804 movcs.w r8, #4 { const s32_t *prefix_ptr; s32_t *ret_ptr; u8_t i; i = 0; 803263e: 461c mov r4, r3 * @return 1 if it matches, 0 otherwise * * @note ident_len 0 is allowed, expanding to the first known object id!! */ u8_t snmp_iso_prefix_expand(u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) 8032640: 4f10 ldr r7, [pc, #64] ; (8032684 ) i = 0; prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; ident_len = ((ident_len < 4)?ident_len:4); while ((i < ident_len) && ((*ident) <= (*prefix_ptr))) 8032642: e003 b.n 803264c { *ret_ptr++ = *prefix_ptr++; ident++; i++; 8032644: 3401 adds r4, #1 prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; ident_len = ((ident_len < 4)?ident_len:4); while ((i < ident_len) && ((*ident) <= (*prefix_ptr))) { *ret_ptr++ = *prefix_ptr++; 8032646: 50ee str r6, [r5, r3] ident++; i++; 8032648: b2e4 uxtb r4, r4 803264a: 3304 adds r3, #4 i = 0; prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; ident_len = ((ident_len < 4)?ident_len:4); while ((i < ident_len) && ((*ident) <= (*prefix_ptr))) 803264c: 4544 cmp r4, r8 * @return 1 if it matches, 0 otherwise * * @note ident_len 0 is allowed, expanding to the first known object id!! */ u8_t snmp_iso_prefix_expand(u8_t ident_len, s32_t *ident, struct snmp_obj_id *oidret) 803264e: eb05 0c03 add.w ip, r5, r3 8032652: eb07 0603 add.w r6, r7, r3 i = 0; prefix_ptr = &prefix[0]; ret_ptr = &oidret->id[0]; ident_len = ((ident_len < 4)?ident_len:4); while ((i < ident_len) && ((*ident) <= (*prefix_ptr))) 8032656: d101 bne.n 803265c 8032658: 2300 movs r3, #0 803265a: e00c b.n 8032676 803265c: 59de ldr r6, [r3, r7] 803265e: 58c8 ldr r0, [r1, r3] 8032660: 42b0 cmp r0, r6 8032662: ddef ble.n 8032644 return 1; } else { /* i != ident_len */ return 0; 8032664: 2000 movs r0, #0 8032666: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} if (i == ident_len) { /* match, complete missing bits */ while (i < 4) { *ret_ptr++ = *prefix_ptr++; 803266a: 58f1 ldr r1, [r6, r3] i++; 803266c: 3401 adds r4, #1 if (i == ident_len) { /* match, complete missing bits */ while (i < 4) { *ret_ptr++ = *prefix_ptr++; 803266e: f84c 1003 str.w r1, [ip, r3] i++; 8032672: b2e4 uxtb r4, r4 8032674: 3304 adds r3, #4 i++; } if (i == ident_len) { /* match, complete missing bits */ while (i < 4) 8032676: 2c03 cmp r4, #3 8032678: d9f7 bls.n 803266a { *ret_ptr++ = *prefix_ptr++; i++; } oidret->len = i; 803267a: 7014 strb r4, [r2, #0] return 1; 803267c: 2001 movs r0, #1 else { /* i != ident_len */ return 0; } } 803267e: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} 8032682: bf00 nop 8032684: 0804079c .word 0x0804079c 08032688 : * Starts SNMP Agent. * Allocates UDP pcb and binds it to IP_ADDR_ANY port 161. */ void snmp_init(void) { 8032688: b510 push {r4, lr} struct snmp_msg_pstat *msg_ps; u8_t i; snmp1_pcb = udp_new(); 803268a: f7fd fa39 bl 802fb00 803268e: 4c0b ldr r4, [pc, #44] ; (80326bc ) 8032690: 6020 str r0, [r4, #0] if (snmp1_pcb != NULL) 8032692: b140 cbz r0, 80326a6 { udp_recv(snmp1_pcb, snmp_recv, (void *)SNMP_IN_PORT); 8032694: 490a ldr r1, [pc, #40] ; (80326c0 ) 8032696: 22a1 movs r2, #161 ; 0xa1 8032698: f7fd fa12 bl 802fac0 udp_bind(snmp1_pcb, IP_ADDR_ANY, SNMP_IN_PORT); 803269c: 6820 ldr r0, [r4, #0] 803269e: 4909 ldr r1, [pc, #36] ; (80326c4 ) 80326a0: 22a1 movs r2, #161 ; 0xa1 80326a2: f7fd f915 bl 802f8d0 } msg_ps = &msg_input_list[0]; for (i=0; istate = SNMP_MSG_EMPTY; 80326a6: 4b08 ldr r3, [pc, #32] ; (80326c8 ) 80326a8: 2200 movs r2, #0 80326aa: f883 205a strb.w r2, [r3, #90] ; 0x5a msg_ps->error_index = 0; 80326ae: 615a str r2, [r3, #20] msg_ps->error_status = SNMP_ES_NOERROR; 80326b0: 611a str r2, [r3, #16] msg_ps++; } trap_msg.pcb = snmp1_pcb; 80326b2: 4b02 ldr r3, [pc, #8] ; (80326bc ) 80326b4: 681a ldr r2, [r3, #0] 80326b6: 4b05 ldr r3, [pc, #20] ; (80326cc ) 80326b8: 601a str r2, [r3, #0] 80326ba: bd10 pop {r4, pc} 80326bc: 2001100c .word 0x2001100c 80326c0: 08033235 .word 0x08033235 80326c4: 0803fe88 .word 0x0803fe88 80326c8: 20011010 .word 0x20011010 80326cc: 20011148 .word 0x20011148 080326d0 : return ERR_OK; } struct snmp_varbind* snmp_varbind_alloc(struct snmp_obj_id *oid, u8_t type, u8_t len) { 80326d0: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} 80326d4: 4680 mov r8, r0 struct snmp_varbind *vb; vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 80326d6: 200c movs r0, #12 return ERR_OK; } struct snmp_varbind* snmp_varbind_alloc(struct snmp_obj_id *oid, u8_t type, u8_t len) { 80326d8: 4689 mov r9, r1 80326da: 4617 mov r7, r2 struct snmp_varbind *vb; vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 80326dc: f7fa fb88 bl 802cdf0 if (vb != NULL) 80326e0: 4604 mov r4, r0 80326e2: 2800 cmp r0, #0 80326e4: d032 beq.n 803274c { u8_t i; vb->next = NULL; 80326e6: 2300 movs r3, #0 80326e8: 6003 str r3, [r0, #0] vb->prev = NULL; 80326ea: 6043 str r3, [r0, #4] i = oid->len; 80326ec: f898 5000 ldrb.w r5, [r8] vb->ident_len = i; 80326f0: 7205 strb r5, [r0, #8] if (i > 0) 80326f2: b1ad cbz r5, 8032720 { LWIP_ASSERT("SNMP_MAX_TREE_DEPTH is configured too low", i <= SNMP_MAX_TREE_DEPTH); /* allocate array of s32_t for our object identifier */ vb->ident = (s32_t*)memp_malloc(MEMP_SNMP_VALUE); 80326f4: 200d movs r0, #13 80326f6: f7fa fb7b bl 802cdf0 80326fa: 4606 mov r6, r0 80326fc: 60e0 str r0, [r4, #12] if (vb->ident == NULL) 80326fe: b928 cbnz r0, 803270c { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_varbind_alloc: couldn't allocate ident value space\n")); memp_free(MEMP_SNMP_VARBIND, vb); 8032700: 4621 mov r1, r4 8032702: 200c movs r0, #12 8032704: f7fa fb8a bl 802ce1c return NULL; 8032708: 4634 mov r4, r6 803270a: e01f b.n 803274c } while(i > 0) { i--; 803270c: 3d01 subs r5, #1 803270e: b2ed uxtb r5, r5 vb->ident[i] = oid->id[i]; 8032710: eb08 0385 add.w r3, r8, r5, lsl #2 8032714: 685b ldr r3, [r3, #4] 8032716: f846 3025 str.w r3, [r6, r5, lsl #2] { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_varbind_alloc: couldn't allocate ident value space\n")); memp_free(MEMP_SNMP_VARBIND, vb); return NULL; } while(i > 0) 803271a: 2d00 cmp r5, #0 803271c: d1f6 bne.n 803270c 803271e: e000 b.n 8032722 } } else { /* i == 0, pass zero length object identifier */ vb->ident = NULL; 8032720: 60c5 str r5, [r0, #12] } vb->value_type = type; 8032722: f884 9010 strb.w r9, [r4, #16] vb->value_len = len; 8032726: 7467 strb r7, [r4, #17] if (len > 0) 8032728: b17f cbz r7, 803274a { LWIP_ASSERT("SNMP_MAX_OCTET_STRING_LEN is configured too low", vb->value_len <= SNMP_MAX_VALUE_SIZE); /* allocate raw bytes for our object value */ vb->value = memp_malloc(MEMP_SNMP_VALUE); 803272a: 200d movs r0, #13 803272c: f7fa fb60 bl 802cdf0 8032730: 6160 str r0, [r4, #20] if (vb->value == NULL) 8032732: b958 cbnz r0, 803274c { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_varbind_alloc: couldn't allocate value space\n")); if (vb->ident != NULL) 8032734: 68e1 ldr r1, [r4, #12] 8032736: b111 cbz r1, 803273e { memp_free(MEMP_SNMP_VALUE, vb->ident); 8032738: 200d movs r0, #13 803273a: f7fa fb6f bl 802ce1c } memp_free(MEMP_SNMP_VARBIND, vb); 803273e: 4621 mov r1, r4 8032740: 200c movs r0, #12 8032742: f7fa fb6b bl 802ce1c return NULL; 8032746: 2400 movs r4, #0 8032748: e000 b.n 803274c } } else { /* ASN1_NUL type, or zero length ASN1_OC_STR */ vb->value = NULL; 803274a: 6167 str r7, [r4, #20] else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_varbind_alloc: couldn't allocate varbind space\n")); } return vb; } 803274c: 4620 mov r0, r4 803274e: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 08032752 : void snmp_varbind_free(struct snmp_varbind *vb) { if (vb->value != NULL ) 8032752: 6941 ldr r1, [r0, #20] return vb; } void snmp_varbind_free(struct snmp_varbind *vb) { 8032754: b510 push {r4, lr} 8032756: 4604 mov r4, r0 if (vb->value != NULL ) 8032758: b111 cbz r1, 8032760 { memp_free(MEMP_SNMP_VALUE, vb->value); 803275a: 200d movs r0, #13 803275c: f7fa fb5e bl 802ce1c } if (vb->ident != NULL ) 8032760: 68e1 ldr r1, [r4, #12] 8032762: b111 cbz r1, 803276a { memp_free(MEMP_SNMP_VALUE, vb->ident); 8032764: 200d movs r0, #13 8032766: f7fa fb59 bl 802ce1c } memp_free(MEMP_SNMP_VARBIND, vb); 803276a: 200c movs r0, #12 803276c: 4621 mov r1, r4 } 803276e: e8bd 4010 ldmia.w sp!, {r4, lr} } if (vb->ident != NULL ) { memp_free(MEMP_SNMP_VALUE, vb->ident); } memp_free(MEMP_SNMP_VARBIND, vb); 8032772: f7fa bb53 b.w 802ce1c 08032776 : } void snmp_varbind_list_free(struct snmp_varbind_root *root) { 8032776: b538 push {r3, r4, r5, lr} 8032778: 4604 mov r4, r0 struct snmp_varbind *vb, *prev; vb = root->tail; 803277a: 6840 ldr r0, [r0, #4] while ( vb != NULL ) 803277c: e003 b.n 8032786 { prev = vb->prev; 803277e: 6845 ldr r5, [r0, #4] snmp_varbind_free(vb); 8032780: f7ff ffe7 bl 8032752 vb = prev; 8032784: 4628 mov r0, r5 snmp_varbind_list_free(struct snmp_varbind_root *root) { struct snmp_varbind *vb, *prev; vb = root->tail; while ( vb != NULL ) 8032786: 2800 cmp r0, #0 8032788: d1f9 bne.n 803277e { prev = vb->prev; snmp_varbind_free(vb); vb = prev; } root->count = 0; 803278a: 7220 strb r0, [r4, #8] root->head = NULL; 803278c: 6020 str r0, [r4, #0] root->tail = NULL; 803278e: 6060 str r0, [r4, #4] 8032790: bd38 pop {r3, r4, r5, pc} 08032792 : //snmp_coldstart_trap(); } static void snmp_error_response(struct snmp_msg_pstat *msg_ps, u8_t error) { 8032792: b570 push {r4, r5, r6, lr} 8032794: 4604 mov r4, r0 /* move names back from outvb to invb */ int v; struct snmp_varbind *vbi = msg_ps->invb.head; struct snmp_varbind *vbo = msg_ps->outvb.head; for (v=0; vvb_idx; v++) { 8032796: 2200 movs r2, #0 //snmp_coldstart_trap(); } static void snmp_error_response(struct snmp_msg_pstat *msg_ps, u8_t error) { 8032798: 460e mov r6, r1 /* move names back from outvb to invb */ int v; struct snmp_varbind *vbi = msg_ps->invb.head; 803279a: f8d0 0100 ldr.w r0, [r0, #256] ; 0x100 struct snmp_varbind *vbo = msg_ps->outvb.head; 803279e: f8d4 310c ldr.w r3, [r4, #268] ; 0x10c for (v=0; vvb_idx; v++) { vbi->ident_len = vbo->ident_len; vbo->ident_len = 0; 80327a2: 4611 mov r1, r2 { /* move names back from outvb to invb */ int v; struct snmp_varbind *vbi = msg_ps->invb.head; struct snmp_varbind *vbo = msg_ps->outvb.head; for (v=0; vvb_idx; v++) { 80327a4: e008 b.n 80327b8 vbi->ident_len = vbo->ident_len; 80327a6: 7a1d ldrb r5, [r3, #8] 80327a8: 7205 strb r5, [r0, #8] vbo->ident_len = 0; vbi->ident = vbo->ident; 80327aa: 68dd ldr r5, [r3, #12] int v; struct snmp_varbind *vbi = msg_ps->invb.head; struct snmp_varbind *vbo = msg_ps->outvb.head; for (v=0; vvb_idx; v++) { vbi->ident_len = vbo->ident_len; vbo->ident_len = 0; 80327ac: 7219 strb r1, [r3, #8] vbi->ident = vbo->ident; 80327ae: 60c5 str r5, [r0, #12] vbo->ident = NULL; 80327b0: 60d9 str r1, [r3, #12] vbi = vbi->next; 80327b2: 6800 ldr r0, [r0, #0] vbo = vbo->next; 80327b4: 681b ldr r3, [r3, #0] { /* move names back from outvb to invb */ int v; struct snmp_varbind *vbi = msg_ps->invb.head; struct snmp_varbind *vbo = msg_ps->outvb.head; for (v=0; vvb_idx; v++) { 80327b6: 3201 adds r2, #1 80327b8: f894 50f8 ldrb.w r5, [r4, #248] ; 0xf8 80327bc: 42aa cmp r2, r5 80327be: dbf2 blt.n 80327a6 vbo->ident = NULL; vbi = vbi->next; vbo = vbo->next; } /* free outvb */ snmp_varbind_list_free(&msg_ps->outvb); 80327c0: f504 7586 add.w r5, r4, #268 ; 0x10c 80327c4: 4628 mov r0, r5 80327c6: f7ff ffd6 bl 8032776 /* we send invb back */ msg_ps->outvb = msg_ps->invb; 80327ca: f504 7380 add.w r3, r4, #256 ; 0x100 80327ce: e893 0007 ldmia.w r3, {r0, r1, r2} msg_ps->invb.head = NULL; 80327d2: 2300 movs r3, #0 msg_ps->invb.tail = NULL; msg_ps->invb.count = 0; msg_ps->error_status = error; /* error index must be 0 for error too big */ msg_ps->error_index = (error != SNMP_ES_TOOBIG) ? (1 + msg_ps->vb_idx) : 0; 80327d4: 2e01 cmp r6, #1 } /* free outvb */ snmp_varbind_list_free(&msg_ps->outvb); /* we send invb back */ msg_ps->outvb = msg_ps->invb; msg_ps->invb.head = NULL; 80327d6: f8c4 3100 str.w r3, [r4, #256] ; 0x100 msg_ps->invb.tail = NULL; 80327da: f8c4 3104 str.w r3, [r4, #260] ; 0x104 msg_ps->invb.count = 0; 80327de: f884 3108 strb.w r3, [r4, #264] ; 0x108 msg_ps->error_status = error; /* error index must be 0 for error too big */ msg_ps->error_index = (error != SNMP_ES_TOOBIG) ? (1 + msg_ps->vb_idx) : 0; 80327e2: bf18 it ne 80327e4: f894 30f8 ldrbne.w r3, [r4, #248] ; 0xf8 /* we send invb back */ msg_ps->outvb = msg_ps->invb; msg_ps->invb.head = NULL; msg_ps->invb.tail = NULL; msg_ps->invb.count = 0; msg_ps->error_status = error; 80327e8: 6126 str r6, [r4, #16] /* error index must be 0 for error too big */ msg_ps->error_index = (error != SNMP_ES_TOOBIG) ? (1 + msg_ps->vb_idx) : 0; 80327ea: bf18 it ne 80327ec: 3301 addne r3, #1 vbo = vbo->next; } /* free outvb */ snmp_varbind_list_free(&msg_ps->outvb); /* we send invb back */ msg_ps->outvb = msg_ps->invb; 80327ee: e885 0007 stmia.w r5, {r0, r1, r2} msg_ps->invb.head = NULL; msg_ps->invb.tail = NULL; msg_ps->invb.count = 0; msg_ps->error_status = error; /* error index must be 0 for error too big */ msg_ps->error_index = (error != SNMP_ES_TOOBIG) ? (1 + msg_ps->vb_idx) : 0; 80327f2: 6163 str r3, [r4, #20] snmp_send_response(msg_ps); 80327f4: 4620 mov r0, r4 80327f6: f001 f873 bl 80338e0 snmp_varbind_list_free(&msg_ps->outvb); 80327fa: 4628 mov r0, r5 80327fc: f7ff ffbb bl 8032776 msg_ps->state = SNMP_MSG_EMPTY; 8032800: 2300 movs r3, #0 8032802: f884 305a strb.w r3, [r4, #90] ; 0x5a 8032806: bd70 pop {r4, r5, r6, pc} 08032808 : } static void snmp_ok_response(struct snmp_msg_pstat *msg_ps) { 8032808: b510 push {r4, lr} 803280a: 4604 mov r4, r0 err_t err_ret; err_ret = snmp_send_response(msg_ps); 803280c: f001 f868 bl 80338e0 else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event = %"S32_F"\n",msg_ps->error_status)); } /* free varbinds (if available) */ snmp_varbind_list_free(&msg_ps->invb); 8032810: f504 7080 add.w r0, r4, #256 ; 0x100 8032814: f7ff ffaf bl 8032776 snmp_varbind_list_free(&msg_ps->outvb); 8032818: f504 7086 add.w r0, r4, #268 ; 0x10c 803281c: f7ff ffab bl 8032776 msg_ps->state = SNMP_MSG_EMPTY; 8032820: 2300 movs r3, #0 8032822: f884 305a strb.w r3, [r4, #90] ; 0x5a 8032826: bd10 pop {r4, pc} 08032828 : } void snmp_varbind_tail_add(struct snmp_varbind_root *root, struct snmp_varbind *vb) { if (root->count == 0) 8032828: 7a03 ldrb r3, [r0, #8] 803282a: b90b cbnz r3, 8032830 { /* add first varbind to list */ root->head = vb; 803282c: 6001 str r1, [r0, #0] 803282e: e002 b.n 8032836 root->tail = vb; } else { /* add nth varbind to list tail */ root->tail->next = vb; 8032830: 6843 ldr r3, [r0, #4] 8032832: 6019 str r1, [r3, #0] vb->prev = root->tail; 8032834: 604b str r3, [r1, #4] root->tail = vb; } root->count += 1; 8032836: 7a03 ldrb r3, [r0, #8] else { /* add nth varbind to list tail */ root->tail->next = vb; vb->prev = root->tail; root->tail = vb; 8032838: 6041 str r1, [r0, #4] } root->count += 1; 803283a: 3301 adds r3, #1 803283c: 7203 strb r3, [r0, #8] 803283e: 4770 bx lr 08032840 : * * @param request_id identifies requests from 0 to (SNMP_CONCURRENT_REQUESTS-1) */ void snmp_msg_event(u8_t request_id) { 8032840: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} struct snmp_msg_pstat *msg_ps; if (request_id < SNMP_CONCURRENT_REQUESTS) 8032844: 4605 mov r5, r0 * * @param request_id identifies requests from 0 to (SNMP_CONCURRENT_REQUESTS-1) */ void snmp_msg_event(u8_t request_id) { 8032846: b0a7 sub sp, #156 ; 0x9c struct snmp_msg_pstat *msg_ps; if (request_id < SNMP_CONCURRENT_REQUESTS) 8032848: 2800 cmp r0, #0 803284a: f040 8390 bne.w 8032f6e { msg_ps = &msg_input_list[request_id]; if (msg_ps->rt == SNMP_ASN1_PDU_GET_NEXT_REQ) 803284e: 4cb2 ldr r4, [pc, #712] ; (8032b18 ) 8032850: 7aa6 ldrb r6, [r4, #10] 8032852: 2e01 cmp r6, #1 8032854: f040 80d4 bne.w 8032a00 static void snmp_msg_getnext_event(u8_t request_id, struct snmp_msg_pstat *msg_ps) { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_getnext_event: msg_ps->state==%"U16_F"\n",(u16_t)msg_ps->state)); if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_OBJDEF) 8032858: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 803285c: 2b07 cmp r3, #7 803285e: d125 bne.n 80328ac /* get_object_def() answer*/ en = msg_ps->ext_mib_node; /* translate answer into a known lifeform */ en->get_object_def_a(request_id, 1, &msg_ps->ext_oid.id[msg_ps->ext_oid.len - 1], &msg_ps->ext_object_def); 8032860: f894 2074 ldrb.w r2, [r4, #116] ; 0x74 if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_OBJDEF) { struct mib_external_node *en; /* get_object_def() answer*/ en = msg_ps->ext_mib_node; 8032864: f8d4 805c ldr.w r8, [r4, #92] ; 0x5c /* translate answer into a known lifeform */ en->get_object_def_a(request_id, 1, &msg_ps->ext_oid.id[msg_ps->ext_oid.len - 1], &msg_ps->ext_object_def); 8032868: eb04 0282 add.w r2, r4, r2, lsl #2 803286c: 4631 mov r1, r6 803286e: 3274 adds r2, #116 ; 0x74 8032870: f104 0368 add.w r3, r4, #104 ; 0x68 8032874: f8d8 7038 ldr.w r7, [r8, #56] ; 0x38 8032878: 47b8 blx r7 if (msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) 803287a: f894 0068 ldrb.w r0, [r4, #104] ; 0x68 803287e: b148 cbz r0, 8032894 { msg_ps->state = SNMP_MSG_EXTERNAL_GET_VALUE; 8032880: 2308 movs r3, #8 8032882: f884 305a strb.w r3, [r4, #90] ; 0x5a en->get_value_q(request_id, &msg_ps->ext_object_def); 8032886: f8d8 302c ldr.w r3, [r8, #44] ; 0x2c 803288a: 4628 mov r0, r5 803288c: f104 0168 add.w r1, r4, #104 ; 0x68 8032890: 4798 blx r3 8032892: e0a6 b.n 80329e2 } else { en->get_object_def_pc(request_id, 1, &msg_ps->ext_oid.id[msg_ps->ext_oid.len - 1]); 8032894: f894 2074 ldrb.w r2, [r4, #116] ; 0x74 8032898: f8d8 3048 ldr.w r3, [r8, #72] ; 0x48 803289c: eb04 0282 add.w r2, r4, r2, lsl #2 80328a0: 4631 mov r1, r6 80328a2: 3274 adds r2, #116 ; 0x74 80328a4: 4798 blx r3 /* search failed, object id points to unknown object (nosuchname) */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 80328a6: 4620 mov r0, r4 80328a8: 2102 movs r1, #2 80328aa: e02a b.n 8032902 } } else if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_VALUE) 80328ac: 2b08 cmp r3, #8 80328ae: f040 8098 bne.w 80329e2 /* get_value() answer */ en = msg_ps->ext_mib_node; LWIP_ASSERT("invalid length", msg_ps->ext_object_def.v_len <= 0xff); vb = snmp_varbind_alloc(&msg_ps->ext_oid, 80328b2: f104 0074 add.w r0, r4, #116 ; 0x74 80328b6: f894 106a ldrb.w r1, [r4, #106] ; 0x6a 80328ba: f894 206c ldrb.w r2, [r4, #108] ; 0x6c { struct mib_external_node *en; struct snmp_varbind *vb; /* get_value() answer */ en = msg_ps->ext_mib_node; 80328be: f8d4 805c ldr.w r8, [r4, #92] ; 0x5c LWIP_ASSERT("invalid length", msg_ps->ext_object_def.v_len <= 0xff); vb = snmp_varbind_alloc(&msg_ps->ext_oid, 80328c2: f7ff ff05 bl 80326d0 msg_ps->ext_object_def.asn_type, (u8_t)msg_ps->ext_object_def.v_len); if (vb != NULL) 80328c6: 4607 mov r7, r0 80328c8: b1a0 cbz r0, 80328f4 { en->get_value_a(request_id, &msg_ps->ext_object_def, vb->value_len, vb->value); 80328ca: 697b ldr r3, [r7, #20] 80328cc: f8d8 c03c ldr.w ip, [r8, #60] ; 0x3c 80328d0: 7c7a ldrb r2, [r7, #17] 80328d2: 4628 mov r0, r5 80328d4: f104 0168 add.w r1, r4, #104 ; 0x68 80328d8: 47e0 blx ip snmp_varbind_tail_add(&msg_ps->outvb, vb); 80328da: f504 7086 add.w r0, r4, #268 ; 0x10c 80328de: 4639 mov r1, r7 80328e0: f7ff ffa2 bl 8032828 msg_ps->state = SNMP_MSG_SEARCH_OBJ; msg_ps->vb_idx += 1; 80328e4: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 (u8_t)msg_ps->ext_object_def.v_len); if (vb != NULL) { en->get_value_a(request_id, &msg_ps->ext_object_def, vb->value_len, vb->value); snmp_varbind_tail_add(&msg_ps->outvb, vb); msg_ps->state = SNMP_MSG_SEARCH_OBJ; 80328e8: f884 605a strb.w r6, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 80328ec: 3301 adds r3, #1 80328ee: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 80328f2: e076 b.n 80329e2 } else { en->get_value_pc(request_id, &msg_ps->ext_object_def); 80328f4: f104 0168 add.w r1, r4, #104 ; 0x68 80328f8: f8d8 304c ldr.w r3, [r8, #76] ; 0x4c 80328fc: 4798 blx r3 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_getnext_event: couldn't allocate outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); 80328fe: 4620 mov r0, r4 8032900: 4631 mov r1, r6 8032902: f7ff ff46 bl 8032792 8032906: e06c b.n 80329e2 (msg_ps->vb_idx < msg_ps->invb.count)) { struct mib_node *mn; struct snmp_obj_id oid; if (msg_ps->vb_idx == 0) 8032908: b913 cbnz r3, 8032910 { msg_ps->vb_ptr = msg_ps->invb.head; 803290a: f8d4 3100 ldr.w r3, [r4, #256] ; 0x100 803290e: e002 b.n 8032916 } else { msg_ps->vb_ptr = msg_ps->vb_ptr->next; 8032910: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032914: 681b ldr r3, [r3, #0] 8032916: f8c4 30fc str.w r3, [r4, #252] ; 0xfc } if (snmp_iso_prefix_expand(msg_ps->vb_ptr->ident_len, msg_ps->vb_ptr->ident, &oid)) 803291a: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 803291e: aa05 add r2, sp, #20 8032920: 7a18 ldrb r0, [r3, #8] 8032922: 68d9 ldr r1, [r3, #12] 8032924: f7ff fe82 bl 803262c 8032928: 2800 cmp r0, #0 803292a: f000 82ff beq.w 8032f2c { if (msg_ps->vb_ptr->ident_len > 3) 803292e: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032932: 7a19 ldrb r1, [r3, #8] 8032934: 2903 cmp r1, #3 8032936: d905 bls.n 8032944 { /* can offset ident_len and ident */ mn = snmp_expand_tree((struct mib_node*)&internet, 8032938: 68da ldr r2, [r3, #12] 803293a: 4878 ldr r0, [pc, #480] ; (8032b1c ) 803293c: 3904 subs r1, #4 803293e: b2c9 uxtb r1, r1 8032940: 3210 adds r2, #16 8032942: e002 b.n 803294a msg_ps->vb_ptr->ident + 4, &oid); } else { /* can't offset ident_len -4, ident + 4 */ mn = snmp_expand_tree((struct mib_node*)&internet, 0, NULL, &oid); 8032944: 2100 movs r1, #0 8032946: 4875 ldr r0, [pc, #468] ; (8032b1c ) 8032948: 460a mov r2, r1 803294a: ab05 add r3, sp, #20 803294c: f7ff fc8e bl 803226c 8032950: 4605 mov r5, r0 } else { mn = NULL; } if (mn != NULL) 8032952: 2800 cmp r0, #0 8032954: f000 82ea beq.w 8032f2c { if (mn->node_type == MIB_NODE_EX) 8032958: 7c03 ldrb r3, [r0, #16] 803295a: 2b05 cmp r3, #5 803295c: d113 bne.n 8032986 { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 803295e: 2307 movs r3, #7 /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; 8032960: 65e0 str r0, [r4, #92] ; 0x5c msg_ps->ext_oid = oid; 8032962: a905 add r1, sp, #20 8032964: 2284 movs r2, #132 ; 0x84 8032966: 486e ldr r0, [pc, #440] ; (8032b20 ) if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 8032968: f884 305a strb.w r3, [r4, #90] ; 0x5a /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_oid = oid; 803296c: f7ee ffee bl 802194c en->get_object_def_q(en->addr_inf, request_id, 1, &oid.id[oid.len - 1]); 8032970: f89d 3014 ldrb.w r3, [sp, #20] 8032974: 6aae ldr r6, [r5, #40] ; 0x28 8032976: 6968 ldr r0, [r5, #20] 8032978: ad05 add r5, sp, #20 803297a: 2100 movs r1, #0 803297c: 2201 movs r2, #1 803297e: eb05 0383 add.w r3, r5, r3, lsl #2 8032982: 47b0 blx r6 8032984: e02e b.n 80329e4 { /* internal object */ struct obj_def object_def; struct snmp_varbind *vb; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF; 8032986: 2302 movs r3, #2 mn->get_object_def(1, &oid.id[oid.len - 1], &object_def); 8032988: f89d 1014 ldrb.w r1, [sp, #20] { /* internal object */ struct obj_def object_def; struct snmp_varbind *vb; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF; 803298c: f884 305a strb.w r3, [r4, #90] ; 0x5a mn->get_object_def(1, &oid.id[oid.len - 1], &object_def); 8032990: af05 add r7, sp, #20 8032992: 6803 ldr r3, [r0, #0] 8032994: eb07 0181 add.w r1, r7, r1, lsl #2 8032998: 2001 movs r0, #1 803299a: aa02 add r2, sp, #8 803299c: 4798 blx r3 LWIP_ASSERT("invalid length", object_def.v_len <= 0xff); vb = snmp_varbind_alloc(&oid, object_def.asn_type, (u8_t)object_def.v_len); 803299e: a805 add r0, sp, #20 80329a0: f89d 100a ldrb.w r1, [sp, #10] 80329a4: f89d 200c ldrb.w r2, [sp, #12] 80329a8: f7ff fe92 bl 80326d0 if (vb != NULL) 80329ac: 4606 mov r6, r0 80329ae: b1a8 cbz r0, 80329dc { msg_ps->state = SNMP_MSG_INTERNAL_GET_VALUE; 80329b0: 2303 movs r3, #3 80329b2: f884 305a strb.w r3, [r4, #90] ; 0x5a mn->get_value(&object_def, object_def.v_len, vb->value); 80329b6: 686b ldr r3, [r5, #4] 80329b8: f8bd 100c ldrh.w r1, [sp, #12] 80329bc: 6972 ldr r2, [r6, #20] 80329be: a802 add r0, sp, #8 80329c0: 4798 blx r3 snmp_varbind_tail_add(&msg_ps->outvb, vb); 80329c2: 4858 ldr r0, [pc, #352] ; (8032b24 ) 80329c4: 4631 mov r1, r6 80329c6: f7ff ff2f bl 8032828 msg_ps->state = SNMP_MSG_SEARCH_OBJ; 80329ca: 2301 movs r3, #1 80329cc: f884 305a strb.w r3, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 80329d0: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 80329d4: 3301 adds r3, #1 80329d6: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 80329da: e003 b.n 80329e4 } else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_recv couldn't allocate outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); 80329dc: 484e ldr r0, [pc, #312] ; (8032b18 ) 80329de: 2101 movs r1, #1 80329e0: e2a6 b.n 8032f30 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_getnext_event: couldn't allocate outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); } } while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 80329e2: 4c4d ldr r4, [pc, #308] ; (8032b18 ) 80329e4: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 80329e8: 2b01 cmp r3, #1 80329ea: f040 82c0 bne.w 8032f6e (msg_ps->vb_idx < msg_ps->invb.count)) 80329ee: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 80329f2: f894 2108 ldrb.w r2, [r4, #264] ; 0x108 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_getnext_event: couldn't allocate outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); } } while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 80329f6: 4293 cmp r3, r2 80329f8: d386 bcc.n 8032908 80329fa: e2a7 b.n 8032f4c } } if ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && (msg_ps->vb_idx == msg_ps->invb.count)) { snmp_ok_response(msg_ps); 80329fc: 4846 ldr r0, [pc, #280] ; (8032b18 ) 80329fe: e292 b.n 8032f26 msg_ps = &msg_input_list[request_id]; if (msg_ps->rt == SNMP_ASN1_PDU_GET_NEXT_REQ) { snmp_msg_getnext_event(request_id, msg_ps); } else if (msg_ps->rt == SNMP_ASN1_PDU_GET_REQ) 8032a00: 2e00 cmp r6, #0 8032a02: f040 8126 bne.w 8032c52 static void snmp_msg_get_event(u8_t request_id, struct snmp_msg_pstat *msg_ps) { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_get_event: msg_ps->state==%"U16_F"\n",(u16_t)msg_ps->state)); if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_OBJDEF) 8032a06: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 8032a0a: 2b07 cmp r3, #7 8032a0c: d122 bne.n 8032a54 { struct mib_external_node *en; struct snmp_name_ptr np; /* get_object_def() answer*/ en = msg_ps->ext_mib_node; 8032a0e: 6de5 ldr r5, [r4, #92] ; 0x5c np = msg_ps->ext_name_ptr; 8032a10: f894 9060 ldrb.w r9, [r4, #96] ; 0x60 8032a14: f8d4 8064 ldr.w r8, [r4, #100] ; 0x64 /* translate answer into a known lifeform */ en->get_object_def_a(request_id, np.ident_len, np.ident, &msg_ps->ext_object_def); 8032a18: 6baf ldr r7, [r5, #56] ; 0x38 8032a1a: f104 0368 add.w r3, r4, #104 ; 0x68 8032a1e: 4649 mov r1, r9 8032a20: 4642 mov r2, r8 8032a22: 47b8 blx r7 if ((msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) && 8032a24: f894 3068 ldrb.w r3, [r4, #104] ; 0x68 8032a28: b163 cbz r3, 8032a44 (msg_ps->ext_object_def.access & MIB_ACCESS_READ)) 8032a2a: f894 3069 ldrb.w r3, [r4, #105] ; 0x69 en = msg_ps->ext_mib_node; np = msg_ps->ext_name_ptr; /* translate answer into a known lifeform */ en->get_object_def_a(request_id, np.ident_len, np.ident, &msg_ps->ext_object_def); if ((msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) && 8032a2e: 07da lsls r2, r3, #31 8032a30: d508 bpl.n 8032a44 (msg_ps->ext_object_def.access & MIB_ACCESS_READ)) { msg_ps->state = SNMP_MSG_EXTERNAL_GET_VALUE; 8032a32: 2308 movs r3, #8 8032a34: f884 305a strb.w r3, [r4, #90] ; 0x5a en->get_value_q(request_id, &msg_ps->ext_object_def); 8032a38: 6aeb ldr r3, [r5, #44] ; 0x2c 8032a3a: 4630 mov r0, r6 8032a3c: f104 0168 add.w r1, r4, #104 ; 0x68 8032a40: 4798 blx r3 8032a42: e0f7 b.n 8032c34 } else { en->get_object_def_pc(request_id, np.ident_len, np.ident); 8032a44: 2000 movs r0, #0 8032a46: 4649 mov r1, r9 8032a48: 6cab ldr r3, [r5, #72] ; 0x48 8032a4a: 4642 mov r2, r8 8032a4c: 4798 blx r3 /* search failed, object id points to unknown object (nosuchname) */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032a4e: 4832 ldr r0, [pc, #200] ; (8032b18 ) 8032a50: 2102 movs r1, #2 8032a52: e059 b.n 8032b08 } } else if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_VALUE) 8032a54: 2b08 cmp r3, #8 8032a56: f040 80ed bne.w 8032c34 /* get_value() answer */ en = msg_ps->ext_mib_node; /* allocate output varbind */ vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 8032a5a: 200c movs r0, #12 { struct mib_external_node *en; struct snmp_varbind *vb; /* get_value() answer */ en = msg_ps->ext_mib_node; 8032a5c: f8d4 805c ldr.w r8, [r4, #92] ; 0x5c /* allocate output varbind */ vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 8032a60: f7fa f9c6 bl 802cdf0 if (vb != NULL) 8032a64: 4605 mov r5, r0 8032a66: 2800 cmp r0, #0 8032a68: d047 beq.n 8032afa { vb->next = NULL; 8032a6a: 6006 str r6, [r0, #0] vb->prev = NULL; 8032a6c: 6046 str r6, [r0, #4] /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; 8032a6e: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032a72: 68da ldr r2, [r3, #12] vb->ident_len = msg_ps->vb_ptr->ident_len; 8032a74: 7a1b ldrb r3, [r3, #8] { vb->next = NULL; vb->prev = NULL; /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; 8032a76: 60c2 str r2, [r0, #12] vb->ident_len = msg_ps->vb_ptr->ident_len; 8032a78: 7203 strb r3, [r0, #8] /* ensure this memory is refereced once only */ msg_ps->vb_ptr->ident = NULL; 8032a7a: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc msg_ps->vb_ptr->ident_len = 0; 8032a7e: 721e strb r6, [r3, #8] /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; vb->ident_len = msg_ps->vb_ptr->ident_len; /* ensure this memory is refereced once only */ msg_ps->vb_ptr->ident = NULL; 8032a80: 60de str r6, [r3, #12] msg_ps->vb_ptr->ident_len = 0; vb->value_type = msg_ps->ext_object_def.asn_type; 8032a82: f894 306a ldrb.w r3, [r4, #106] ; 0x6a 8032a86: 7403 strb r3, [r0, #16] LWIP_ASSERT("invalid length", msg_ps->ext_object_def.v_len <= 0xff); vb->value_len = (u8_t)msg_ps->ext_object_def.v_len; 8032a88: f894 706c ldrb.w r7, [r4, #108] ; 0x6c 8032a8c: 7447 strb r7, [r0, #17] if (vb->value_len > 0) 8032a8e: b1ef cbz r7, 8032acc { LWIP_ASSERT("SNMP_MAX_OCTET_STRING_LEN is configured too low", vb->value_len <= SNMP_MAX_VALUE_SIZE); vb->value = memp_malloc(MEMP_SNMP_VALUE); 8032a90: 200d movs r0, #13 8032a92: f7fa f9ad bl 802cdf0 8032a96: 4603 mov r3, r0 8032a98: 6168 str r0, [r5, #20] if (vb->value != NULL) 8032a9a: b138 cbz r0, 8032aac { en->get_value_a(request_id, &msg_ps->ext_object_def, vb->value_len, vb->value); 8032a9c: f8d8 703c ldr.w r7, [r8, #60] ; 0x3c 8032aa0: 7c6a ldrb r2, [r5, #17] 8032aa2: 4630 mov r0, r6 8032aa4: f104 0168 add.w r1, r4, #104 ; 0x68 8032aa8: 47b8 blx r7 8032aaa: e018 b.n 8032ade msg_ps->state = SNMP_MSG_SEARCH_OBJ; msg_ps->vb_idx += 1; } else { en->get_value_pc(request_id, &msg_ps->ext_object_def); 8032aac: f8d8 304c ldr.w r3, [r8, #76] ; 0x4c 8032ab0: f104 0168 add.w r1, r4, #104 ; 0x68 8032ab4: 4798 blx r3 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no variable space\n")); msg_ps->vb_ptr->ident = vb->ident; 8032ab6: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032aba: 68ea ldr r2, [r5, #12] 8032abc: 60da str r2, [r3, #12] msg_ps->vb_ptr->ident_len = vb->ident_len; 8032abe: 7a2a ldrb r2, [r5, #8] memp_free(MEMP_SNMP_VARBIND, vb); 8032ac0: 200c movs r0, #12 else { en->get_value_pc(request_id, &msg_ps->ext_object_def); LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no variable space\n")); msg_ps->vb_ptr->ident = vb->ident; msg_ps->vb_ptr->ident_len = vb->ident_len; 8032ac2: 721a strb r2, [r3, #8] memp_free(MEMP_SNMP_VARBIND, vb); 8032ac4: 4629 mov r1, r5 8032ac6: f7fa f9a9 bl 802ce1c 8032aca: e01b b.n 8032b04 } } else { /* vb->value_len == 0, empty value (e.g. empty string) */ en->get_value_a(request_id, &msg_ps->ext_object_def, 0, NULL); 8032acc: f8d8 603c ldr.w r6, [r8, #60] ; 0x3c 8032ad0: 4638 mov r0, r7 8032ad2: f104 0168 add.w r1, r4, #104 ; 0x68 8032ad6: 463a mov r2, r7 8032ad8: 463b mov r3, r7 8032ada: 47b0 blx r6 vb->value = NULL; 8032adc: 616f str r7, [r5, #20] snmp_varbind_tail_add(&msg_ps->outvb, vb); 8032ade: f504 7086 add.w r0, r4, #268 ; 0x10c 8032ae2: 4629 mov r1, r5 8032ae4: f7ff fea0 bl 8032828 /* search again (if vb_idx < msg_ps->invb.count) */ msg_ps->state = SNMP_MSG_SEARCH_OBJ; 8032ae8: 2301 movs r3, #1 8032aea: f884 305a strb.w r3, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 8032aee: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032af2: 3301 adds r3, #1 8032af4: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 8032af8: e09c b.n 8032c34 } } else { en->get_value_pc(request_id, &msg_ps->ext_object_def); 8032afa: f8d8 304c ldr.w r3, [r8, #76] ; 0x4c 8032afe: f104 0168 add.w r1, r4, #104 ; 0x68 8032b02: 4798 blx r3 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); 8032b04: 4620 mov r0, r4 8032b06: 2101 movs r1, #1 8032b08: f7ff fe43 bl 8032792 8032b0c: e092 b.n 8032c34 (msg_ps->vb_idx < msg_ps->invb.count)) { struct mib_node *mn; struct snmp_name_ptr np; if (msg_ps->vb_idx == 0) 8032b0e: b95b cbnz r3, 8032b28 { msg_ps->vb_ptr = msg_ps->invb.head; 8032b10: f8d4 3100 ldr.w r3, [r4, #256] ; 0x100 8032b14: e00b b.n 8032b2e 8032b16: bf00 nop 8032b18: 20011010 .word 0x20011010 8032b1c: 080406b4 .word 0x080406b4 8032b20: 20011084 .word 0x20011084 8032b24: 2001111c .word 0x2001111c } else { msg_ps->vb_ptr = msg_ps->vb_ptr->next; 8032b28: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032b2c: 681b ldr r3, [r3, #0] 8032b2e: f8c4 30fc str.w r3, [r4, #252] ; 0xfc } /** test object identifier for .iso.org.dod.internet prefix */ if (snmp_iso_prefix_tst(msg_ps->vb_ptr->ident_len, msg_ps->vb_ptr->ident)) 8032b32: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032b36: 7a18 ldrb r0, [r3, #8] 8032b38: 68d9 ldr r1, [r3, #12] 8032b3a: f7ff fd65 bl 8032608 8032b3e: 2800 cmp r0, #0 8032b40: d073 beq.n 8032c2a { mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032b42: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032b46: 48a6 ldr r0, [pc, #664] ; (8032de0 ) 8032b48: 7a19 ldrb r1, [r3, #8] 8032b4a: 68da ldr r2, [r3, #12] 8032b4c: 3904 subs r1, #4 8032b4e: b2c9 uxtb r1, r1 8032b50: 3210 adds r2, #16 8032b52: 466b mov r3, sp 8032b54: f7ff fb0a bl 803216c msg_ps->vb_ptr->ident + 4, &np); if (mn != NULL) 8032b58: 4606 mov r6, r0 8032b5a: 2800 cmp r0, #0 8032b5c: d065 beq.n 8032c2a { if (mn->node_type == MIB_NODE_EX) 8032b5e: 7c03 ldrb r3, [r0, #16] 8032b60: 2b05 cmp r3, #5 8032b62: d110 bne.n 8032b86 /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; 8032b64: 65e0 str r0, [r4, #92] ; 0x5c if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 8032b66: 2307 movs r3, #7 /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032b68: e898 0003 ldmia.w r8, {r0, r1} if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 8032b6c: f884 305a strb.w r3, [r4, #90] ; 0x5a /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032b70: 4b9c ldr r3, [pc, #624] ; (8032de4 ) en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032b72: f89d 2000 ldrb.w r2, [sp] struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032b76: e883 0003 stmia.w r3, {r0, r1} en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032b7a: 2100 movs r1, #0 8032b7c: 6ab5 ldr r5, [r6, #40] ; 0x28 8032b7e: 6970 ldr r0, [r6, #20] 8032b80: 9b01 ldr r3, [sp, #4] 8032b82: 47a8 blx r5 8032b84: e058 b.n 8032c38 else { /* internal object */ struct obj_def object_def; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF; 8032b86: 2302 movs r3, #2 8032b88: f884 305a strb.w r3, [r4, #90] ; 0x5a mn->get_object_def(np.ident_len, np.ident, &object_def); 8032b8c: 6803 ldr r3, [r0, #0] 8032b8e: 9901 ldr r1, [sp, #4] 8032b90: f89d 0000 ldrb.w r0, [sp] 8032b94: aa02 add r2, sp, #8 8032b96: 4798 blx r3 if ((object_def.instance != MIB_OBJECT_NONE) && 8032b98: f89d 3008 ldrb.w r3, [sp, #8] 8032b9c: 2b00 cmp r3, #0 8032b9e: d044 beq.n 8032c2a (object_def.access & MIB_ACCESS_READ)) 8032ba0: f89d 3009 ldrb.w r3, [sp, #9] /* internal object */ struct obj_def object_def; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF; mn->get_object_def(np.ident_len, np.ident, &object_def); if ((object_def.instance != MIB_OBJECT_NONE) && 8032ba4: 07db lsls r3, r3, #31 8032ba6: f100 81c6 bmi.w 8032f36 8032baa: e03e b.n 8032c2a msg_ps->state = SNMP_MSG_INTERNAL_GET_VALUE; /* allocate output varbind */ vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); if (vb != NULL) { vb->next = NULL; 8032bac: 2200 movs r2, #0 8032bae: 602a str r2, [r5, #0] vb->prev = NULL; 8032bb0: 606a str r2, [r5, #4] /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; 8032bb2: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032bb6: 68d9 ldr r1, [r3, #12] vb->ident_len = msg_ps->vb_ptr->ident_len; 8032bb8: 7a1b ldrb r3, [r3, #8] { vb->next = NULL; vb->prev = NULL; /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; 8032bba: 60e9 str r1, [r5, #12] vb->ident_len = msg_ps->vb_ptr->ident_len; 8032bbc: 722b strb r3, [r5, #8] /* ensure this memory is refereced once only */ msg_ps->vb_ptr->ident = NULL; 8032bbe: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc msg_ps->vb_ptr->ident_len = 0; 8032bc2: 721a strb r2, [r3, #8] /* move name from invb to outvb */ vb->ident = msg_ps->vb_ptr->ident; vb->ident_len = msg_ps->vb_ptr->ident_len; /* ensure this memory is refereced once only */ msg_ps->vb_ptr->ident = NULL; 8032bc4: 60da str r2, [r3, #12] msg_ps->vb_ptr->ident_len = 0; vb->value_type = object_def.asn_type; 8032bc6: f89d 300a ldrb.w r3, [sp, #10] 8032bca: 742b strb r3, [r5, #16] LWIP_ASSERT("invalid length", object_def.v_len <= 0xff); vb->value_len = (u8_t)object_def.v_len; 8032bcc: f89d 300c ldrb.w r3, [sp, #12] 8032bd0: 746b strb r3, [r5, #17] if (vb->value_len > 0) 8032bd2: b1bb cbz r3, 8032c04 { LWIP_ASSERT("SNMP_MAX_OCTET_STRING_LEN is configured too low", vb->value_len <= SNMP_MAX_VALUE_SIZE); vb->value = memp_malloc(MEMP_SNMP_VALUE); 8032bd4: 200d movs r0, #13 8032bd6: f7fa f90b bl 802cdf0 8032bda: 4602 mov r2, r0 8032bdc: 6168 str r0, [r5, #20] if (vb->value != NULL) 8032bde: b120 cbz r0, 8032bea { mn->get_value(&object_def, vb->value_len, vb->value); 8032be0: 6877 ldr r7, [r6, #4] 8032be2: 7c69 ldrb r1, [r5, #17] 8032be4: a802 add r0, sp, #8 8032be6: 47b8 blx r7 8032be8: e00d b.n 8032c06 msg_ps->vb_idx += 1; } else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: couldn't allocate variable space\n")); msg_ps->vb_ptr->ident = vb->ident; 8032bea: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032bee: 68e9 ldr r1, [r5, #12] 8032bf0: 60d9 str r1, [r3, #12] msg_ps->vb_ptr->ident_len = vb->ident_len; 8032bf2: 7a29 ldrb r1, [r5, #8] vb->ident = NULL; 8032bf4: 60e8 str r0, [r5, #12] } else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: couldn't allocate variable space\n")); msg_ps->vb_ptr->ident = vb->ident; msg_ps->vb_ptr->ident_len = vb->ident_len; 8032bf6: 7219 strb r1, [r3, #8] vb->ident = NULL; vb->ident_len = 0; 8032bf8: 7228 strb r0, [r5, #8] memp_free(MEMP_SNMP_VARBIND, vb); 8032bfa: 4629 mov r1, r5 8032bfc: 200c movs r0, #12 8032bfe: f7fa f90d bl 802ce1c 8032c02: e00d b.n 8032c20 } } else { /* vb->value_len == 0, empty value (e.g. empty string) */ vb->value = NULL; 8032c04: 616b str r3, [r5, #20] snmp_varbind_tail_add(&msg_ps->outvb, vb); 8032c06: 4878 ldr r0, [pc, #480] ; (8032de8 ) 8032c08: 4629 mov r1, r5 8032c0a: f7ff fe0d bl 8032828 msg_ps->state = SNMP_MSG_SEARCH_OBJ; 8032c0e: 2301 movs r3, #1 8032c10: f884 305a strb.w r3, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 8032c14: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032c18: 3301 adds r3, #1 8032c1a: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 8032c1e: e003 b.n 8032c28 } } else { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: couldn't allocate outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); 8032c20: 4872 ldr r0, [pc, #456] ; (8032dec ) 8032c22: 2101 movs r1, #1 8032c24: f7ff fdb5 bl 8032792 } else { mn = NULL; } if (mn == NULL) 8032c28: b936 cbnz r6, 8032c38 { /* mn == NULL, noSuchName */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032c2a: 4870 ldr r0, [pc, #448] ; (8032dec ) 8032c2c: 2102 movs r1, #2 8032c2e: f7ff fdb0 bl 8032792 8032c32: e001 b.n 8032c38 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); } } while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032c34: 4c6d ldr r4, [pc, #436] ; (8032dec ) msg_ps->vb_ptr = msg_ps->vb_ptr->next; } /** test object identifier for .iso.org.dod.internet prefix */ if (snmp_iso_prefix_tst(msg_ps->vb_ptr->ident_len, msg_ps->vb_ptr->ident)) { mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032c36: 46e8 mov r8, sp LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); } } while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032c38: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 8032c3c: 2b01 cmp r3, #1 8032c3e: f040 8196 bne.w 8032f6e (msg_ps->vb_idx < msg_ps->invb.count)) 8032c42: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032c46: f894 2108 ldrb.w r2, [r4, #264] ; 0x108 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_event: no outvb space\n")); snmp_error_response(msg_ps,SNMP_ES_TOOBIG); } } while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032c4a: 4293 cmp r3, r2 8032c4c: f4ff af5f bcc.w 8032b0e 8032c50: e17c b.n 8032f4c } else if (msg_ps->rt == SNMP_ASN1_PDU_GET_REQ) { snmp_msg_get_event(request_id, msg_ps); } else if(msg_ps->rt == SNMP_ASN1_PDU_SET_REQ) 8032c52: 2e03 cmp r6, #3 8032c54: f040 818b bne.w 8032f6e static void snmp_msg_set_event(u8_t request_id, struct snmp_msg_pstat *msg_ps) { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_msg_set_event: msg_ps->state==%"U16_F"\n",(u16_t)msg_ps->state)); if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_OBJDEF) 8032c58: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 8032c5c: 2b07 cmp r3, #7 8032c5e: d11b bne.n 8032c98 { struct mib_external_node *en; struct snmp_name_ptr np; /* get_object_def() answer*/ en = msg_ps->ext_mib_node; 8032c60: 6de6 ldr r6, [r4, #92] ; 0x5c np = msg_ps->ext_name_ptr; 8032c62: f894 9060 ldrb.w r9, [r4, #96] ; 0x60 8032c66: f8d4 8064 ldr.w r8, [r4, #100] ; 0x64 /* translate answer into a known lifeform */ en->get_object_def_a(request_id, np.ident_len, np.ident, &msg_ps->ext_object_def); 8032c6a: 6bb7 ldr r7, [r6, #56] ; 0x38 8032c6c: 4649 mov r1, r9 8032c6e: 4642 mov r2, r8 8032c70: f104 0368 add.w r3, r4, #104 ; 0x68 8032c74: 47b8 blx r7 if (msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) 8032c76: f894 0068 ldrb.w r0, [r4, #104] ; 0x68 8032c7a: b140 cbz r0, 8032c8e { msg_ps->state = SNMP_MSG_EXTERNAL_SET_TEST; 8032c7c: 2309 movs r3, #9 8032c7e: f884 305a strb.w r3, [r4, #90] ; 0x5a en->set_test_q(request_id, &msg_ps->ext_object_def); 8032c82: 6b33 ldr r3, [r6, #48] ; 0x30 8032c84: 4628 mov r0, r5 8032c86: f104 0168 add.w r1, r4, #104 ; 0x68 8032c8a: 4798 blx r3 8032c8c: e0d5 b.n 8032e3a } else { en->get_object_def_pc(request_id, np.ident_len, np.ident); 8032c8e: 6cb3 ldr r3, [r6, #72] ; 0x48 8032c90: 4649 mov r1, r9 8032c92: 4642 mov r2, r8 8032c94: 4798 blx r3 8032c96: e023 b.n 8032ce0 /* search failed, object id points to unknown object (nosuchname) */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); } } else if (msg_ps->state == SNMP_MSG_EXTERNAL_SET_TEST) 8032c98: 2b09 cmp r3, #9 8032c9a: d124 bne.n 8032ce6 struct mib_external_node *en; /* set_test() answer*/ en = msg_ps->ext_mib_node; if (msg_ps->ext_object_def.access & MIB_ACCESS_WRITE) 8032c9c: f894 3069 ldrb.w r3, [r4, #105] ; 0x69 else if (msg_ps->state == SNMP_MSG_EXTERNAL_SET_TEST) { struct mib_external_node *en; /* set_test() answer*/ en = msg_ps->ext_mib_node; 8032ca0: 6de5 ldr r5, [r4, #92] ; 0x5c if (msg_ps->ext_object_def.access & MIB_ACCESS_WRITE) 8032ca2: f003 0302 and.w r3, r3, #2 8032ca6: b2db uxtb r3, r3 8032ca8: b1b3 cbz r3, 8032cd8 { if ((msg_ps->ext_object_def.asn_type == msg_ps->vb_ptr->value_type) && 8032caa: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032cae: f894 106a ldrb.w r1, [r4, #106] ; 0x6a 8032cb2: 7c1a ldrb r2, [r3, #16] 8032cb4: 4291 cmp r1, r2 8032cb6: d108 bne.n 8032cca (en->set_test_a(request_id,&msg_ps->ext_object_def, 8032cb8: 7c5a ldrb r2, [r3, #17] 8032cba: 6c2e ldr r6, [r5, #64] ; 0x40 8032cbc: 695b ldr r3, [r3, #20] 8032cbe: f104 0168 add.w r1, r4, #104 ; 0x68 8032cc2: 47b0 blx r6 /* set_test() answer*/ en = msg_ps->ext_mib_node; if (msg_ps->ext_object_def.access & MIB_ACCESS_WRITE) { if ((msg_ps->ext_object_def.asn_type == msg_ps->vb_ptr->value_type) && 8032cc4: b108 cbz r0, 8032cca (en->set_test_a(request_id,&msg_ps->ext_object_def, msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value) != 0)) { msg_ps->state = SNMP_MSG_SEARCH_OBJ; 8032cc6: 2301 movs r3, #1 8032cc8: e040 b.n 8032d4c msg_ps->vb_idx += 1; } else { en->set_test_pc(request_id,&msg_ps->ext_object_def); 8032cca: 2000 movs r0, #0 8032ccc: 4948 ldr r1, [pc, #288] ; (8032df0 ) 8032cce: 6d2b ldr r3, [r5, #80] ; 0x50 8032cd0: 4798 blx r3 /* bad value */ snmp_error_response(msg_ps,SNMP_ES_BADVALUE); 8032cd2: 4846 ldr r0, [pc, #280] ; (8032dec ) 8032cd4: 2103 movs r1, #3 8032cd6: e029 b.n 8032d2c } } else { en->set_test_pc(request_id,&msg_ps->ext_object_def); 8032cd8: 6d2b ldr r3, [r5, #80] ; 0x50 8032cda: f104 0168 add.w r1, r4, #104 ; 0x68 8032cde: 4798 blx r3 /* object not available for set */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032ce0: 4620 mov r0, r4 8032ce2: 2102 movs r1, #2 8032ce4: e022 b.n 8032d2c } } else if (msg_ps->state == SNMP_MSG_EXTERNAL_GET_OBJDEF_S) 8032ce6: 2b0a cmp r3, #10 8032ce8: d123 bne.n 8032d32 { struct mib_external_node *en; struct snmp_name_ptr np; /* get_object_def() answer*/ en = msg_ps->ext_mib_node; 8032cea: 6de6 ldr r6, [r4, #92] ; 0x5c np = msg_ps->ext_name_ptr; 8032cec: f894 9060 ldrb.w r9, [r4, #96] ; 0x60 8032cf0: f8d4 8064 ldr.w r8, [r4, #100] ; 0x64 /* translate answer into a known lifeform */ en->get_object_def_a(request_id, np.ident_len, np.ident, &msg_ps->ext_object_def); 8032cf4: 6bb7 ldr r7, [r6, #56] ; 0x38 8032cf6: 4649 mov r1, r9 8032cf8: 4642 mov r2, r8 8032cfa: f104 0368 add.w r3, r4, #104 ; 0x68 8032cfe: 47b8 blx r7 if (msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) 8032d00: f894 0068 ldrb.w r0, [r4, #104] ; 0x68 8032d04: b160 cbz r0, 8032d20 { msg_ps->state = SNMP_MSG_EXTERNAL_SET_VALUE; 8032d06: 230b movs r3, #11 8032d08: f884 305a strb.w r3, [r4, #90] ; 0x5a en->set_value_q(request_id, &msg_ps->ext_object_def, msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value); 8032d0c: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc /* translate answer into a known lifeform */ en->get_object_def_a(request_id, np.ident_len, np.ident, &msg_ps->ext_object_def); if (msg_ps->ext_object_def.instance != MIB_OBJECT_NONE) { msg_ps->state = SNMP_MSG_EXTERNAL_SET_VALUE; en->set_value_q(request_id, &msg_ps->ext_object_def, 8032d10: 6b76 ldr r6, [r6, #52] ; 0x34 8032d12: 7c5a ldrb r2, [r3, #17] 8032d14: 695b ldr r3, [r3, #20] 8032d16: 4628 mov r0, r5 8032d18: f104 0168 add.w r1, r4, #104 ; 0x68 8032d1c: 47b0 blx r6 8032d1e: e08c b.n 8032e3a msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value); } else { en->get_object_def_pc(request_id, np.ident_len, np.ident); 8032d20: 4649 mov r1, r9 8032d22: 6cb3 ldr r3, [r6, #72] ; 0x48 8032d24: 4642 mov r2, r8 8032d26: 4798 blx r3 /* set_value failed, object has disappeared for some odd reason?? */ snmp_error_response(msg_ps,SNMP_ES_GENERROR); 8032d28: 4620 mov r0, r4 8032d2a: 2105 movs r1, #5 8032d2c: f7ff fd31 bl 8032792 8032d30: e083 b.n 8032e3a } } else if (msg_ps->state == SNMP_MSG_EXTERNAL_SET_VALUE) 8032d32: 2b0b cmp r3, #11 8032d34: f040 8081 bne.w 8032e3a struct mib_external_node *en; /** set_value_a() */ en = msg_ps->ext_mib_node; en->set_value_a(request_id, &msg_ps->ext_object_def, msg_ps->vb_ptr->value_len, msg_ps->vb_ptr->value); 8032d38: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc { struct mib_external_node *en; /** set_value_a() */ en = msg_ps->ext_mib_node; en->set_value_a(request_id, &msg_ps->ext_object_def, 8032d3c: 6de2 ldr r2, [r4, #92] ; 0x5c 8032d3e: f104 0168 add.w r1, r4, #104 ; 0x68 8032d42: 6c55 ldr r5, [r2, #68] ; 0x44 8032d44: 7c5a ldrb r2, [r3, #17] 8032d46: 695b ldr r3, [r3, #20] 8032d48: 47a8 blx r5 msg_ps->vb_ptr->value_len, msg_ps->vb_ptr->value); /** @todo use set_value_pc() if toobig */ msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; 8032d4a: 2306 movs r3, #6 8032d4c: f884 305a strb.w r3, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 8032d50: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032d54: 3301 adds r3, #1 8032d56: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 8032d5a: e06e b.n 8032e3a (msg_ps->vb_idx < msg_ps->invb.count)) { struct mib_node *mn; struct snmp_name_ptr np; if (msg_ps->vb_idx == 0) 8032d5c: b912 cbnz r2, 8032d64 { msg_ps->vb_ptr = msg_ps->invb.head; 8032d5e: f8d4 3100 ldr.w r3, [r4, #256] ; 0x100 8032d62: e002 b.n 8032d6a } else { msg_ps->vb_ptr = msg_ps->vb_ptr->next; 8032d64: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032d68: 681b ldr r3, [r3, #0] 8032d6a: f8c4 30fc str.w r3, [r4, #252] ; 0xfc } /** test object identifier for .iso.org.dod.internet prefix */ if (snmp_iso_prefix_tst(msg_ps->vb_ptr->ident_len, msg_ps->vb_ptr->ident)) 8032d6e: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032d72: 7a18 ldrb r0, [r3, #8] 8032d74: 68d9 ldr r1, [r3, #12] 8032d76: f7ff fc47 bl 8032608 8032d7a: 2800 cmp r0, #0 8032d7c: d058 beq.n 8032e30 { mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032d7e: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032d82: 4817 ldr r0, [pc, #92] ; (8032de0 ) 8032d84: 7a19 ldrb r1, [r3, #8] 8032d86: 68da ldr r2, [r3, #12] 8032d88: 3904 subs r1, #4 8032d8a: b2c9 uxtb r1, r1 8032d8c: 3210 adds r2, #16 8032d8e: 466b mov r3, sp 8032d90: f7ff f9ec bl 803216c msg_ps->vb_ptr->ident + 4, &np); if (mn != NULL) 8032d94: 4605 mov r5, r0 8032d96: 2800 cmp r0, #0 8032d98: d04a beq.n 8032e30 { if (mn->node_type == MIB_NODE_EX) 8032d9a: 7c03 ldrb r3, [r0, #16] 8032d9c: 2b05 cmp r3, #5 8032d9e: d110 bne.n 8032dc2 /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; 8032da0: 65e0 str r0, [r4, #92] ; 0x5c if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 8032da2: 2307 movs r3, #7 /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032da4: e896 0003 ldmia.w r6, {r0, r1} if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; 8032da8: f884 305a strb.w r3, [r4, #90] ; 0x5a /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032dac: 4b0d ldr r3, [pc, #52] ; (8032de4 ) en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032dae: f89d 2000 ldrb.w r2, [sp] struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032db2: e883 0003 stmia.w r3, {r0, r1} en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032db6: 2100 movs r1, #0 8032db8: 6aaf ldr r7, [r5, #40] ; 0x28 8032dba: 6968 ldr r0, [r5, #20] 8032dbc: 9b01 ldr r3, [sp, #4] 8032dbe: 47b8 blx r7 8032dc0: e03d b.n 8032e3e else { /* internal object */ struct obj_def object_def; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF; 8032dc2: 2702 movs r7, #2 8032dc4: f884 705a strb.w r7, [r4, #90] ; 0x5a mn->get_object_def(np.ident_len, np.ident, &object_def); 8032dc8: 6803 ldr r3, [r0, #0] 8032dca: 9901 ldr r1, [sp, #4] 8032dcc: f89d 0000 ldrb.w r0, [sp] 8032dd0: aa02 add r2, sp, #8 8032dd2: 4798 blx r3 if (object_def.instance != MIB_OBJECT_NONE) 8032dd4: f89d 3008 ldrb.w r3, [sp, #8] 8032dd8: 2b00 cmp r3, #0 8032dda: f040 80b9 bne.w 8032f50 8032dde: e027 b.n 8032e30 8032de0: 080406b4 .word 0x080406b4 8032de4: 20011070 .word 0x20011070 8032de8: 2001111c .word 0x2001111c 8032dec: 20011010 .word 0x20011010 8032df0: 20011078 .word 0x20011078 { msg_ps->state = SNMP_MSG_INTERNAL_SET_TEST; if (object_def.access & MIB_ACCESS_WRITE) { if ((object_def.asn_type == msg_ps->vb_ptr->value_type) && 8032df4: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032df8: f89d 100a ldrb.w r1, [sp, #10] 8032dfc: 7c1a ldrb r2, [r3, #16] 8032dfe: 4291 cmp r1, r2 8032e00: d10e bne.n 8032e20 (mn->set_test(&object_def,msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value) != 0)) 8032e02: 68af ldr r7, [r5, #8] 8032e04: 7c59 ldrb r1, [r3, #17] 8032e06: 695a ldr r2, [r3, #20] 8032e08: a802 add r0, sp, #8 8032e0a: 47b8 blx r7 { msg_ps->state = SNMP_MSG_INTERNAL_SET_TEST; if (object_def.access & MIB_ACCESS_WRITE) { if ((object_def.asn_type == msg_ps->vb_ptr->value_type) && 8032e0c: b140 cbz r0, 8032e20 (mn->set_test(&object_def,msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value) != 0)) { msg_ps->state = SNMP_MSG_SEARCH_OBJ; 8032e0e: 2301 movs r3, #1 8032e10: f884 305a strb.w r3, [r4, #90] ; 0x5a msg_ps->vb_idx += 1; 8032e14: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032e18: 3301 adds r3, #1 8032e1a: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 8032e1e: e006 b.n 8032e2e } else { /* bad value */ snmp_error_response(msg_ps,SNMP_ES_BADVALUE); 8032e20: 4854 ldr r0, [pc, #336] ; (8032f74 ) 8032e22: 2103 movs r1, #3 8032e24: e001 b.n 8032e2a } } else { /* object not available for set */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032e26: 4853 ldr r0, [pc, #332] ; (8032f74 ) 8032e28: 4639 mov r1, r7 8032e2a: f7ff fcb2 bl 8032792 } else { mn = NULL; } if (mn == NULL) 8032e2e: b935 cbnz r5, 8032e3e { /* mn == NULL, noSuchName */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032e30: 4850 ldr r0, [pc, #320] ; (8032f74 ) 8032e32: 2102 movs r1, #2 8032e34: f7ff fcad bl 8032792 8032e38: e001 b.n 8032e3e msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; msg_ps->vb_idx += 1; } /* test all values before setting */ while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032e3a: 4c4e ldr r4, [pc, #312] ; (8032f74 ) msg_ps->vb_ptr = msg_ps->vb_ptr->next; } /** test object identifier for .iso.org.dod.internet prefix */ if (snmp_iso_prefix_tst(msg_ps->vb_ptr->ident_len, msg_ps->vb_ptr->ident)) { mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032e3c: 466e mov r6, sp msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; msg_ps->vb_idx += 1; } /* test all values before setting */ while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032e3e: f894 205a ldrb.w r2, [r4, #90] ; 0x5a 8032e42: 4b4c ldr r3, [pc, #304] ; (8032f74 ) 8032e44: 2a01 cmp r2, #1 8032e46: d151 bne.n 8032eec (msg_ps->vb_idx < msg_ps->invb.count)) 8032e48: f894 20f8 ldrb.w r2, [r4, #248] ; 0xf8 8032e4c: f894 1108 ldrb.w r1, [r4, #264] ; 0x108 msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; msg_ps->vb_idx += 1; } /* test all values before setting */ while ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032e50: 428a cmp r2, r1 8032e52: d383 bcc.n 8032d5c 8032e54: e088 b.n 8032f68 } if ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && (msg_ps->vb_idx == msg_ps->invb.count)) { msg_ps->vb_idx = 0; 8032e56: 2200 movs r2, #0 8032e58: f883 20f8 strb.w r2, [r3, #248] ; 0xf8 msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; 8032e5c: 2206 movs r2, #6 8032e5e: f883 205a strb.w r2, [r3, #90] ; 0x5a 8032e62: e043 b.n 8032eec (msg_ps->vb_idx < msg_ps->invb.count)) { struct mib_node *mn; struct snmp_name_ptr np; if (msg_ps->vb_idx == 0) 8032e64: b913 cbnz r3, 8032e6c { msg_ps->vb_ptr = msg_ps->invb.head; 8032e66: f8d4 3100 ldr.w r3, [r4, #256] ; 0x100 8032e6a: e002 b.n 8032e72 } else { msg_ps->vb_ptr = msg_ps->vb_ptr->next; 8032e6c: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032e70: 681b ldr r3, [r3, #0] 8032e72: f8c4 30fc str.w r3, [r4, #252] ; 0xfc } /* skip iso prefix test, was done previously while settesting() */ mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032e76: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032e7a: 483f ldr r0, [pc, #252] ; (8032f78 ) 8032e7c: 7a19 ldrb r1, [r3, #8] 8032e7e: 68da ldr r2, [r3, #12] 8032e80: 3904 subs r1, #4 8032e82: b2c9 uxtb r1, r1 8032e84: 3210 adds r2, #16 8032e86: 466b mov r3, sp 8032e88: f7ff f970 bl 803216c msg_ps->vb_ptr->ident + 4, &np); /* check if object is still available (e.g. external hot-plug thingy present?) */ if (mn != NULL) 8032e8c: 4605 mov r5, r0 8032e8e: 2800 cmp r0, #0 8032e90: d02e beq.n 8032ef0 { if (mn->node_type == MIB_NODE_EX) 8032e92: 7c03 ldrb r3, [r0, #16] 8032e94: 2b05 cmp r3, #5 8032e96: d110 bne.n 8032eba /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF_S; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; 8032e98: 65e0 str r0, [r4, #92] ; 0x5c if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF_S; 8032e9a: 230a movs r3, #10 /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032e9c: e896 0003 ldmia.w r6, {r0, r1} if (mn->node_type == MIB_NODE_EX) { /* external object */ struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF_S; 8032ea0: f884 305a strb.w r3, [r4, #90] ; 0x5a /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032ea4: 4b35 ldr r3, [pc, #212] ; (8032f7c ) en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032ea6: f89d 2000 ldrb.w r2, [sp] struct mib_external_node *en = (struct mib_external_node*)mn; msg_ps->state = SNMP_MSG_EXTERNAL_GET_OBJDEF_S; /* save en && args in msg_ps!! */ msg_ps->ext_mib_node = en; msg_ps->ext_name_ptr = np; 8032eaa: e883 0003 stmia.w r3, {r0, r1} en->get_object_def_q(en->addr_inf, request_id, np.ident_len, np.ident); 8032eae: 2100 movs r1, #0 8032eb0: 6aaf ldr r7, [r5, #40] ; 0x28 8032eb2: 6968 ldr r0, [r5, #20] 8032eb4: 9b01 ldr r3, [sp, #4] 8032eb6: 47b8 blx r7 8032eb8: e01a b.n 8032ef0 else { /* internal object */ struct obj_def object_def; msg_ps->state = SNMP_MSG_INTERNAL_GET_OBJDEF_S; 8032eba: 2305 movs r3, #5 8032ebc: f884 305a strb.w r3, [r4, #90] ; 0x5a mn->get_object_def(np.ident_len, np.ident, &object_def); 8032ec0: 6803 ldr r3, [r0, #0] 8032ec2: 9901 ldr r1, [sp, #4] 8032ec4: f89d 0000 ldrb.w r0, [sp] 8032ec8: aa02 add r2, sp, #8 8032eca: 4798 blx r3 msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; 8032ecc: 2306 movs r3, #6 8032ece: f884 305a strb.w r3, [r4, #90] ; 0x5a mn->set_value(&object_def,msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value); 8032ed2: f8d4 30fc ldr.w r3, [r4, #252] ; 0xfc 8032ed6: 68ed ldr r5, [r5, #12] 8032ed8: 7c59 ldrb r1, [r3, #17] 8032eda: 695a ldr r2, [r3, #20] 8032edc: a802 add r0, sp, #8 8032ede: 47a8 blx r5 msg_ps->vb_idx += 1; 8032ee0: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032ee4: 3301 adds r3, #1 8032ee6: f884 30f8 strb.w r3, [r4, #248] ; 0xf8 8032eea: e001 b.n 8032ef0 msg_ps->vb_idx = 0; msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; } /* set all values "atomically" (be as "atomic" as possible) */ while ((msg_ps->state == SNMP_MSG_INTERNAL_SET_VALUE) && 8032eec: 4c21 ldr r4, [pc, #132] ; (8032f74 ) else { msg_ps->vb_ptr = msg_ps->vb_ptr->next; } /* skip iso prefix test, was done previously while settesting() */ mn = snmp_search_tree((struct mib_node*)&internet, msg_ps->vb_ptr->ident_len - 4, 8032eee: 466e mov r6, sp msg_ps->vb_idx = 0; msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; } /* set all values "atomically" (be as "atomic" as possible) */ while ((msg_ps->state == SNMP_MSG_INTERNAL_SET_VALUE) && 8032ef0: f894 305a ldrb.w r3, [r4, #90] ; 0x5a 8032ef4: 4d1f ldr r5, [pc, #124] ; (8032f74 ) 8032ef6: 2b06 cmp r3, #6 8032ef8: d139 bne.n 8032f6e (msg_ps->vb_idx < msg_ps->invb.count)) 8032efa: f894 30f8 ldrb.w r3, [r4, #248] ; 0xf8 8032efe: f894 2108 ldrb.w r2, [r4, #264] ; 0x108 msg_ps->vb_idx = 0; msg_ps->state = SNMP_MSG_INTERNAL_SET_VALUE; } /* set all values "atomically" (be as "atomic" as possible) */ while ((msg_ps->state == SNMP_MSG_INTERNAL_SET_VALUE) && 8032f02: 4293 cmp r3, r2 8032f04: d3ae bcc.n 8032e64 8032f06: e031 b.n 8032f6c (msg_ps->vb_idx == msg_ps->invb.count)) { /* simply echo the input if we can set it @todo do we need to return the actual value? e.g. if value is silently modified or behaves sticky? */ msg_ps->outvb = msg_ps->invb; 8032f08: f505 7280 add.w r2, r5, #256 ; 0x100 8032f0c: ca07 ldmia r2, {r0, r1, r2} 8032f0e: f505 7386 add.w r3, r5, #268 ; 0x10c 8032f12: e883 0007 stmia.w r3, {r0, r1, r2} msg_ps->invb.head = NULL; 8032f16: 2300 movs r3, #0 8032f18: f8c5 3100 str.w r3, [r5, #256] ; 0x100 msg_ps->invb.tail = NULL; 8032f1c: f8c5 3104 str.w r3, [r5, #260] ; 0x104 msg_ps->invb.count = 0; 8032f20: f885 3108 strb.w r3, [r5, #264] ; 0x108 snmp_ok_response(msg_ps); 8032f24: 4628 mov r0, r5 8032f26: f7ff fc6f bl 8032808 8032f2a: e020 b.n 8032f6e } } if (mn == NULL) { /* mn == NULL, noSuchName */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); 8032f2c: 4811 ldr r0, [pc, #68] ; (8032f74 ) 8032f2e: 2102 movs r1, #2 8032f30: f7ff fc2f bl 8032792 8032f34: e556 b.n 80329e4 } if (mn != NULL) { struct snmp_varbind *vb; msg_ps->state = SNMP_MSG_INTERNAL_GET_VALUE; 8032f36: 2303 movs r3, #3 /* allocate output varbind */ vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 8032f38: 200c movs r0, #12 } if (mn != NULL) { struct snmp_varbind *vb; msg_ps->state = SNMP_MSG_INTERNAL_GET_VALUE; 8032f3a: f884 305a strb.w r3, [r4, #90] ; 0x5a /* allocate output varbind */ vb = (struct snmp_varbind *)memp_malloc(MEMP_SNMP_VARBIND); 8032f3e: f7f9 ff57 bl 802cdf0 if (vb != NULL) 8032f42: 4605 mov r5, r0 8032f44: 2800 cmp r0, #0 8032f46: f47f ae31 bne.w 8032bac 8032f4a: e669 b.n 8032c20 { /* mn == NULL, noSuchName */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); } } if ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032f4c: d10f bne.n 8032f6e 8032f4e: e555 b.n 80329fc /* search failed, object id points to unknown object (nosuchname) */ mn = NULL; } if (mn != NULL) { msg_ps->state = SNMP_MSG_INTERNAL_SET_TEST; 8032f50: 2304 movs r3, #4 8032f52: f884 305a strb.w r3, [r4, #90] ; 0x5a if (object_def.access & MIB_ACCESS_WRITE) 8032f56: f89d 3009 ldrb.w r3, [sp, #9] 8032f5a: f003 0302 and.w r3, r3, #2 8032f5e: b2db uxtb r3, r3 8032f60: 2b00 cmp r3, #0 8032f62: f47f af47 bne.w 8032df4 8032f66: e75e b.n 8032e26 /* mn == NULL, noSuchName */ snmp_error_response(msg_ps,SNMP_ES_NOSUCHNAME); } } if ((msg_ps->state == SNMP_MSG_SEARCH_OBJ) && 8032f68: d1c0 bne.n 8032eec 8032f6a: e774 b.n 8032e56 mn->set_value(&object_def,msg_ps->vb_ptr->value_len,msg_ps->vb_ptr->value); msg_ps->vb_idx += 1; } } } if ((msg_ps->state == SNMP_MSG_INTERNAL_SET_VALUE) && 8032f6c: d0cc beq.n 8032f08 else if(msg_ps->rt == SNMP_ASN1_PDU_SET_REQ) { snmp_msg_set_event(request_id, msg_ps); } } } 8032f6e: b027 add sp, #156 ; 0x9c 8032f70: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 8032f74: 20011010 .word 0x20011010 8032f78: 080406b4 .word 0x080406b4 8032f7c: 20011070 .word 0x20011070 08032f80 : return ERR_OK; } static err_t snmp_pdu_dec_varbindlist(struct pbuf *p, u16_t ofs, u16_t *ofs_ret, struct snmp_msg_pstat *m_stat) { 8032f80: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} 8032f84: b0c7 sub sp, #284 ; 0x11c u16_t len, vb_len; u8_t len_octets; u8_t type; /* variable binding list */ snmp_asn1_dec_type(p, ofs, &type); 8032f86: f10d 070b add.w r7, sp, #11 return ERR_OK; } static err_t snmp_pdu_dec_varbindlist(struct pbuf *p, u16_t ofs, u16_t *ofs_ret, struct snmp_msg_pstat *m_stat) { 8032f8a: 468a mov sl, r1 8032f8c: 4691 mov r9, r2 u16_t len, vb_len; u8_t len_octets; u8_t type; /* variable binding list */ snmp_asn1_dec_type(p, ofs, &type); 8032f8e: 463a mov r2, r7 return ERR_OK; } static err_t snmp_pdu_dec_varbindlist(struct pbuf *p, u16_t ofs, u16_t *ofs_ret, struct snmp_msg_pstat *m_stat) { 8032f90: 4604 mov r4, r0 8032f92: 461d mov r5, r3 u8_t len_octets; u8_t type; /* variable binding list */ snmp_asn1_dec_type(p, ofs, &type); derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &vb_len); 8032f94: f10d 060e add.w r6, sp, #14 u16_t len, vb_len; u8_t len_octets; u8_t type; /* variable binding list */ snmp_asn1_dec_type(p, ofs, &type); 8032f98: f7fd f944 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &vb_len); 8032f9c: f10a 0101 add.w r1, sl, #1 8032fa0: 4620 mov r0, r4 8032fa2: b289 uxth r1, r1 8032fa4: f10d 020a add.w r2, sp, #10 8032fa8: 4633 mov r3, r6 8032faa: f7fd f950 bl 803024e if ((derr != ERR_OK) || 8032fae: b910 cbnz r0, 8032fb6 8032fb0: 783b ldrb r3, [r7, #0] 8032fb2: 2b30 cmp r3, #48 ; 0x30 8032fb4: d002 beq.n 8032fbc (type != (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ))) { snmp_inc_snmpinasnparseerrs(); 8032fb6: f7fe ff21 bl 8031dfc 8032fba: e02b b.n 8033014 return ERR_ARG; } ofs += (1 + len_octets); 8032fbc: f89d 800a ldrb.w r8, [sp, #10] /* start with empty list */ m_stat->invb.count = 0; 8032fc0: f885 0108 strb.w r0, [r5, #264] ; 0x108 (type != (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ))) { snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } ofs += (1 + len_octets); 8032fc4: f108 0801 add.w r8, r8, #1 8032fc8: 44d0 add r8, sl 8032fca: fa1f f888 uxth.w r8, r8 /* start with empty list */ m_stat->invb.count = 0; m_stat->invb.head = NULL; 8032fce: f8c5 0100 str.w r0, [r5, #256] ; 0x100 m_stat->invb.tail = NULL; 8032fd2: f8c5 0104 str.w r0, [r5, #260] ; 0x104 while (vb_len > 0) 8032fd6: e118 b.n 803320a { struct snmp_obj_id oid, oid_value; struct snmp_varbind *vb; snmp_asn1_dec_type(p, ofs, &type); 8032fd8: 4641 mov r1, r8 8032fda: 463a mov r2, r7 8032fdc: 4620 mov r0, r4 8032fde: f7fd f921 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 8032fe2: f108 0101 add.w r1, r8, #1 8032fe6: 4620 mov r0, r4 8032fe8: b289 uxth r1, r1 8032fea: f10d 020a add.w r2, sp, #10 8032fee: ab03 add r3, sp, #12 8032ff0: f7fd f92d bl 803024e if ((derr != ERR_OK) || 8032ff4: b940 cbnz r0, 8033008 8032ff6: 783b ldrb r3, [r7, #0] 8032ff8: 2b30 cmp r3, #48 ; 0x30 8032ffa: d105 bne.n 8033008 (type != (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)) || (len == 0) || (len > vb_len)) 8032ffc: f8bd 200c ldrh.w r2, [sp, #12] struct snmp_varbind *vb; snmp_asn1_dec_type(p, ofs, &type); derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)) || 8033000: b112 cbz r2, 8033008 (len == 0) || (len > vb_len)) 8033002: 8833 ldrh r3, [r6, #0] 8033004: 429a cmp r2, r3 8033006: d907 bls.n 8033018 { snmp_inc_snmpinasnparseerrs(); 8033008: f7fe fef8 bl 8031dfc /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); 803300c: f505 7080 add.w r0, r5, #256 ; 0x100 8033010: f7ff fbb1 bl 8032776 8033014: 20f2 movs r0, #242 ; 0xf2 8033016: e109 b.n 803322c return ERR_ARG; } ofs += (1 + len_octets); 8033018: f89d 200a ldrb.w r2, [sp, #10] 803301c: 4490 add r8, r2 803301e: fa1f f888 uxth.w r8, r8 8033022: f108 0a01 add.w sl, r8, #1 vb_len -= (1 + len_octets); 8033026: 43d2 mvns r2, r2 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets); 8033028: fa1f fa8a uxth.w sl, sl vb_len -= (1 + len_octets); 803302c: 189b adds r3, r3, r2 snmp_asn1_dec_type(p, ofs, &type); 803302e: 4651 mov r1, sl 8033030: 463a mov r2, r7 8033032: 4620 mov r0, r4 /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets); vb_len -= (1 + len_octets); 8033034: 8033 strh r3, [r6, #0] snmp_asn1_dec_type(p, ofs, &type); 8033036: f7fd f8f5 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 803303a: f108 0102 add.w r1, r8, #2 803303e: 4620 mov r0, r4 8033040: b289 uxth r1, r1 8033042: f10d 020a add.w r2, sp, #10 8033046: ab03 add r3, sp, #12 8033048: f7fd f901 bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID))) 803304c: 2800 cmp r0, #0 803304e: d1db bne.n 8033008 8033050: 783b ldrb r3, [r7, #0] 8033052: 2b06 cmp r3, #6 8033054: d1d8 bne.n 8033008 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } derr = snmp_asn1_dec_oid(p, ofs + 1 + len_octets, len, &oid); 8033056: f89d 100a ldrb.w r1, [sp, #10] 803305a: f8bd 200c ldrh.w r2, [sp, #12] 803305e: 3101 adds r1, #1 8033060: 4451 add r1, sl 8033062: 4620 mov r0, r4 8033064: b289 uxth r1, r1 8033066: ab04 add r3, sp, #16 8033068: f7fd fa20 bl 80304ac if (derr != ERR_OK) 803306c: 2800 cmp r0, #0 803306e: d1cb bne.n 8033008 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); 8033070: f89d 300a ldrb.w r3, [sp, #10] 8033074: f8bd 200c ldrh.w r2, [sp, #12] 8033078: 1899 adds r1, r3, r2 803307a: 448a add sl, r1 803307c: fa1f fa8a uxth.w sl, sl vb_len -= (1 + len_octets + len); 8033080: 8831 ldrh r1, [r6, #0] snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); 8033082: f10a 0801 add.w r8, sl, #1 vb_len -= (1 + len_octets + len); 8033086: 1a8a subs r2, r1, r2 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); 8033088: fa1f f888 uxth.w r8, r8 vb_len -= (1 + len_octets + len); 803308c: 43db mvns r3, r3 803308e: 18d3 adds r3, r2, r3 snmp_asn1_dec_type(p, ofs, &type); 8033090: 4641 mov r1, r8 8033092: 463a mov r2, r7 8033094: 4620 mov r0, r4 /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); vb_len -= (1 + len_octets + len); 8033096: 8033 strh r3, [r6, #0] snmp_asn1_dec_type(p, ofs, &type); 8033098: f7fd f8c4 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 803309c: f10a 0102 add.w r1, sl, #2 80330a0: 4620 mov r0, r4 80330a2: b289 uxth r1, r1 80330a4: f10d 020a add.w r2, sp, #10 80330a8: ab03 add r3, sp, #12 80330aa: f7fd f8d0 bl 803024e if (derr != ERR_OK) 80330ae: 2800 cmp r0, #0 80330b0: d1aa bne.n 8033008 /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } switch (type) 80330b2: 7839 ldrb r1, [r7, #0] 80330b4: 2906 cmp r1, #6 80330b6: d047 beq.n 8033148 80330b8: d805 bhi.n 80330c6 80330ba: 2904 cmp r1, #4 80330bc: d036 beq.n 803312c 80330be: d839 bhi.n 8033134 80330c0: 2902 cmp r1, #2 80330c2: d1a1 bne.n 8033008 80330c4: e009 b.n 80330da 80330c6: 2943 cmp r1, #67 ; 0x43 80330c8: d804 bhi.n 80330d4 80330ca: 2941 cmp r1, #65 ; 0x41 80330cc: d219 bcs.n 8033102 80330ce: 2940 cmp r1, #64 ; 0x40 80330d0: d19a bne.n 8033008 80330d2: e069 b.n 80331a8 80330d4: 2944 cmp r1, #68 ; 0x44 80330d6: d197 bne.n 8033008 80330d8: e028 b.n 803312c { case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG): vb = snmp_varbind_alloc(&oid, type, sizeof(s32_t)); 80330da: a804 add r0, sp, #16 80330dc: 2204 movs r2, #4 80330de: f7ff faf7 bl 80326d0 if (vb != NULL) 80330e2: 4683 mov fp, r0 80330e4: 2800 cmp r0, #0 80330e6: d08f beq.n 8033008 { s32_t *vptr = (s32_t*)vb->value; derr = snmp_asn1_dec_s32t(p, ofs + 1 + len_octets, len, vptr); 80330e8: f89d 100a ldrb.w r1, [sp, #10] 80330ec: f8bd 200c ldrh.w r2, [sp, #12] 80330f0: f8db 3014 ldr.w r3, [fp, #20] 80330f4: 3101 adds r1, #1 80330f6: 4441 add r1, r8 80330f8: 4620 mov r0, r4 80330fa: b289 uxth r1, r1 80330fc: f7fd f97d bl 80303fa 8033100: e06b b.n 80331da } break; case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_GAUGE): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS): vb = snmp_varbind_alloc(&oid, type, sizeof(u32_t)); 8033102: a804 add r0, sp, #16 8033104: 2204 movs r2, #4 8033106: f7ff fae3 bl 80326d0 if (vb != NULL) 803310a: 4683 mov fp, r0 803310c: 2800 cmp r0, #0 803310e: f43f af7b beq.w 8033008 { u32_t *vptr = (u32_t*)vb->value; derr = snmp_asn1_dec_u32t(p, ofs + 1 + len_octets, len, vptr); 8033112: f89d 100a ldrb.w r1, [sp, #10] 8033116: f8bd 200c ldrh.w r2, [sp, #12] 803311a: f8db 3014 ldr.w r3, [fp, #20] 803311e: 3101 adds r1, #1 8033120: 4441 add r1, r8 8033122: 4620 mov r0, r4 8033124: b289 uxth r1, r1 8033126: f7fd f914 bl 8030352 803312a: e056 b.n 80331da } break; case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_OPAQUE): LWIP_ASSERT("invalid length", len <= 0xff); vb = snmp_varbind_alloc(&oid, type, (u8_t)len); 803312c: a804 add r0, sp, #16 803312e: f89d 200c ldrb.w r2, [sp, #12] 8033132: e03f b.n 80331b4 { derr = ERR_ARG; } break; case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_NUL): vb = snmp_varbind_alloc(&oid, type, 0); 8033134: 2105 movs r1, #5 8033136: a804 add r0, sp, #16 8033138: 2200 movs r2, #0 803313a: f7ff fac9 bl 80326d0 if (vb != NULL) 803313e: 4601 mov r1, r0 8033140: 2800 cmp r0, #0 8033142: f43f af61 beq.w 8033008 8033146: e02a b.n 803319e { derr = ERR_ARG; } break; case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID): derr = snmp_asn1_dec_oid(p, ofs + 1 + len_octets, len, &oid_value); 8033148: f89d 100a ldrb.w r1, [sp, #10] 803314c: f8bd 200c ldrh.w r2, [sp, #12] 8033150: 3101 adds r1, #1 8033152: 4441 add r1, r8 8033154: 4620 mov r0, r4 8033156: b289 uxth r1, r1 8033158: ab25 add r3, sp, #148 ; 0x94 803315a: f7fd f9a7 bl 80304ac if (derr == ERR_OK) 803315e: 2800 cmp r0, #0 8033160: f47f af52 bne.w 8033008 { vb = snmp_varbind_alloc(&oid, type, oid_value.len * sizeof(s32_t)); 8033164: f89d 2094 ldrb.w r2, [sp, #148] ; 0x94 8033168: 7839 ldrb r1, [r7, #0] 803316a: 0092 lsls r2, r2, #2 803316c: a804 add r0, sp, #16 803316e: f002 02fc and.w r2, r2, #252 ; 0xfc 8033172: f7ff faad bl 80326d0 if (vb != NULL) 8033176: 4601 mov r1, r0 8033178: 2800 cmp r0, #0 803317a: f43f af45 beq.w 8033008 { u8_t i = oid_value.len; 803317e: f89d 3094 ldrb.w r3, [sp, #148] ; 0x94 s32_t *vptr = (s32_t*)vb->value; 8033182: 6940 ldr r0, [r0, #20] while(i > 0) 8033184: e009 b.n 803319a { i--; 8033186: 3b01 subs r3, #1 8033188: b2db uxtb r3, r3 vptr[i] = oid_value.id[i]; 803318a: f50d 7e8c add.w lr, sp, #280 ; 0x118 803318e: eb0e 0283 add.w r2, lr, r3, lsl #2 8033192: f852 2c80 ldr.w r2, [r2, #-128] 8033196: f840 2023 str.w r2, [r0, r3, lsl #2] if (vb != NULL) { u8_t i = oid_value.len; s32_t *vptr = (s32_t*)vb->value; while(i > 0) 803319a: 2b00 cmp r3, #0 803319c: d1f3 bne.n 8033186 { i--; vptr[i] = oid_value.id[i]; } snmp_varbind_tail_add(&m_stat->invb, vb); 803319e: f505 7080 add.w r0, r5, #256 ; 0x100 80331a2: f7ff fb41 bl 8032828 80331a6: e022 b.n 80331ee derr = ERR_ARG; } } break; case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR): if (len == 4) 80331a8: f8bd 200c ldrh.w r2, [sp, #12] 80331ac: 2a04 cmp r2, #4 80331ae: f47f af2b bne.w 8033008 { /* must be exactly 4 octets! */ vb = snmp_varbind_alloc(&oid, type, 4); 80331b2: a804 add r0, sp, #16 80331b4: f7ff fa8c bl 80326d0 if (vb != NULL) 80331b8: 4683 mov fp, r0 80331ba: 2800 cmp r0, #0 80331bc: f43f af24 beq.w 8033008 { derr = snmp_asn1_dec_raw(p, ofs + 1 + len_octets, len, vb->value_len, (u8_t*)vb->value); 80331c0: f89d 100a ldrb.w r1, [sp, #10] 80331c4: 7c43 ldrb r3, [r0, #17] 80331c6: 6940 ldr r0, [r0, #20] 80331c8: f8bd 200c ldrh.w r2, [sp, #12] 80331cc: 9000 str r0, [sp, #0] 80331ce: 3101 adds r1, #1 80331d0: 4441 add r1, r8 80331d2: 4620 mov r0, r4 80331d4: b289 uxth r1, r1 80331d6: f7fd fa05 bl 80305e4 80331da: 4682 mov sl, r0 snmp_varbind_tail_add(&m_stat->invb, vb); 80331dc: 4659 mov r1, fp 80331de: f505 7080 add.w r0, r5, #256 ; 0x100 80331e2: f7ff fb21 bl 8032828 break; default: derr = ERR_ARG; break; } if (derr != ERR_OK) 80331e6: f1ba 0f00 cmp.w sl, #0 80331ea: f47f af0d bne.w 8033008 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); 80331ee: f8bd 200c ldrh.w r2, [sp, #12] 80331f2: f89d 300a ldrb.w r3, [sp, #10] 80331f6: 1c51 adds r1, r2, #1 80331f8: 1859 adds r1, r3, r1 80331fa: 4488 add r8, r1 vb_len -= (1 + len_octets + len); 80331fc: 8831 ldrh r1, [r6, #0] 80331fe: 43db mvns r3, r3 8033200: 1a8a subs r2, r1, r2 8033202: 18d3 adds r3, r2, r3 snmp_inc_snmpinasnparseerrs(); /* free varbinds (if available) */ snmp_varbind_list_free(&m_stat->invb); return ERR_ARG; } ofs += (1 + len_octets + len); 8033204: fa1f f888 uxth.w r8, r8 vb_len -= (1 + len_octets + len); 8033208: 8033 strh r3, [r6, #0] /* start with empty list */ m_stat->invb.count = 0; m_stat->invb.head = NULL; m_stat->invb.tail = NULL; while (vb_len > 0) 803320a: 8833 ldrh r3, [r6, #0] 803320c: 2b00 cmp r3, #0 803320e: f47f aee3 bne.w 8032fd8 } ofs += (1 + len_octets + len); vb_len -= (1 + len_octets + len); } if (m_stat->rt == SNMP_ASN1_PDU_SET_REQ) 8033212: 7aab ldrb r3, [r5, #10] 8033214: f895 0108 ldrb.w r0, [r5, #264] ; 0x108 8033218: 2b03 cmp r3, #3 803321a: d102 bne.n 8033222 { snmp_add_snmpintotalsetvars(m_stat->invb.count); 803321c: f7fe fe26 bl 8031e6c 8033220: e001 b.n 8033226 } else { snmp_add_snmpintotalreqvars(m_stat->invb.count); 8033222: f7fe fe1b bl 8031e5c } *ofs_ret = ofs; 8033226: f8a9 8000 strh.w r8, [r9] return ERR_OK; 803322a: 2000 movs r0, #0 } 803322c: b240 sxtb r0, r0 803322e: b047 add sp, #284 ; 0x11c 8033230: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 08033234 : /* lwIP UDP receive callback function */ static void snmp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { 8033234: e92d 43f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, lr} LWIP_UNUSED_ARG(arg); /* traverse input message process list, look for SNMP_MSG_EMPTY */ msg_ps = &msg_input_list[0]; req_idx = 0; while ((req_idx < SNMP_CONCURRENT_REQUESTS) && (msg_ps->state != SNMP_MSG_EMPTY)) 8033238: 4da3 ldr r5, [pc, #652] ; (80334c8 ) snmp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { volatile struct snmp_msg_pstat *msg_ps; u8_t req_idx; err_t err_ret; u16_t payload_len = p->tot_len; 803323a: 8917 ldrh r7, [r2, #8] LWIP_UNUSED_ARG(arg); /* traverse input message process list, look for SNMP_MSG_EMPTY */ msg_ps = &msg_input_list[0]; req_idx = 0; while ((req_idx < SNMP_CONCURRENT_REQUESTS) && (msg_ps->state != SNMP_MSG_EMPTY)) 803323c: f895 605a ldrb.w r6, [r5, #90] ; 0x5a /* lwIP UDP receive callback function */ static void snmp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { 8033240: b087 sub sp, #28 8033242: 4699 mov r9, r3 volatile struct snmp_msg_pstat *msg_ps; u8_t req_idx; err_t err_ret; u16_t payload_len = p->tot_len; u16_t payload_ofs = 0; u16_t varbind_ofs = 0; 8033244: 2300 movs r3, #0 /* lwIP UDP receive callback function */ static void snmp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { 8033246: 4688 mov r8, r1 8033248: 4614 mov r4, r2 volatile struct snmp_msg_pstat *msg_ps; u8_t req_idx; err_t err_ret; u16_t payload_len = p->tot_len; u16_t payload_ofs = 0; u16_t varbind_ofs = 0; 803324a: f8ad 3010 strh.w r3, [sp, #16] LWIP_UNUSED_ARG(arg); /* traverse input message process list, look for SNMP_MSG_EMPTY */ msg_ps = &msg_input_list[0]; req_idx = 0; while ((req_idx < SNMP_CONCURRENT_REQUESTS) && (msg_ps->state != SNMP_MSG_EMPTY)) 803324e: 2e00 cmp r6, #0 8033250: f000 81aa beq.w 80335a8 msg_ps++; } if (req_idx == SNMP_CONCURRENT_REQUESTS) { /* exceeding number of concurrent requests */ pbuf_free(p); 8033254: 4620 mov r0, r4 8033256: f7f9 feeb bl 802d030 803325a: e1d6 b.n 803360a ofs_base = ofs; snmp_asn1_dec_type(p, ofs, &type); derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); if ((derr != ERR_OK) || (pdu_len != (1 + len_octets + len)) || 803325c: f89d 600e ldrb.w r6, [sp, #14] 8033260: f8bd 3012 ldrh.w r3, [sp, #18] 8033264: 1c75 adds r5, r6, #1 8033266: 18eb adds r3, r5, r3 s32_t version; ofs_base = ofs; snmp_asn1_dec_type(p, ofs, &type); derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); if ((derr != ERR_OK) || 8033268: 429f cmp r7, r3 803326a: f040 80c4 bne.w 80333f6 (pdu_len != (1 + len_octets + len)) || 803326e: f89d 300f ldrb.w r3, [sp, #15] 8033272: 2b30 cmp r3, #48 ; 0x30 8033274: d000 beq.n 8033278 8033276: e0be b.n 80333f6 (type != (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ))) { snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } ofs += (1 + len_octets); 8033278: b2ad uxth r5, r5 snmp_asn1_dec_type(p, ofs, &type); 803327a: 4629 mov r1, r5 803327c: f10d 020f add.w r2, sp, #15 8033280: 4620 mov r0, r4 8033282: f7fc ffcf bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 8033286: 4620 mov r0, r4 8033288: 1cb1 adds r1, r6, #2 803328a: f10d 020e add.w r2, sp, #14 803328e: f10d 0312 add.w r3, sp, #18 8033292: f7fc ffdc bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG))) 8033296: 2800 cmp r0, #0 8033298: f040 80ad bne.w 80333f6 803329c: f89d 300f ldrb.w r3, [sp, #15] 80332a0: 2b02 cmp r3, #2 80332a2: f040 80a8 bne.w 80333f6 { /* can't decode or no integer (version) */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } derr = snmp_asn1_dec_s32t(p, ofs + 1 + len_octets, len, &version); 80332a6: f89d 100e ldrb.w r1, [sp, #14] 80332aa: f8bd 2012 ldrh.w r2, [sp, #18] 80332ae: 3101 adds r1, #1 80332b0: 4620 mov r0, r4 80332b2: 1869 adds r1, r5, r1 80332b4: ab05 add r3, sp, #20 80332b6: f7fd f8a0 bl 80303fa if (derr != ERR_OK) 80332ba: 2800 cmp r0, #0 80332bc: f040 809b bne.w 80333f6 { /* can't decode */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } if (version != 0) 80332c0: 9b05 ldr r3, [sp, #20] 80332c2: b113 cbz r3, 80332ca { /* not version 1 */ snmp_inc_snmpinbadversions(); 80332c4: f7fe fd8a bl 8031ddc 80332c8: e7c4 b.n 8033254 return ERR_ARG; } ofs += (1 + len_octets + len); 80332ca: f89d 200e ldrb.w r2, [sp, #14] 80332ce: f8bd 3012 ldrh.w r3, [sp, #18] 80332d2: 18d3 adds r3, r2, r3 80332d4: 18ed adds r5, r5, r3 80332d6: b2ad uxth r5, r5 80332d8: 1c6e adds r6, r5, #1 80332da: b2b6 uxth r6, r6 snmp_asn1_dec_type(p, ofs, &type); 80332dc: 4631 mov r1, r6 80332de: f10d 020f add.w r2, sp, #15 80332e2: 4620 mov r0, r4 80332e4: f7fc ff9e bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 80332e8: 1ca9 adds r1, r5, #2 80332ea: 4620 mov r0, r4 80332ec: b289 uxth r1, r1 80332ee: f10d 020e add.w r2, sp, #14 80332f2: f10d 0312 add.w r3, sp, #18 80332f6: f7fc ffaa bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR))) 80332fa: 2800 cmp r0, #0 80332fc: d17b bne.n 80333f6 80332fe: f89d 300f ldrb.w r3, [sp, #15] 8033302: 2b04 cmp r3, #4 8033304: d177 bne.n 80333f6 { /* can't decode or no octet string (community) */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } derr = snmp_asn1_dec_raw(p, ofs + 1 + len_octets, len, SNMP_COMMUNITY_STR_LEN, m_stat->community); 8033306: f89d 100e ldrb.w r1, [sp, #14] 803330a: 4d70 ldr r5, [pc, #448] ; (80334cc ) 803330c: f8bd 2012 ldrh.w r2, [sp, #18] 8033310: 9500 str r5, [sp, #0] 8033312: 3101 adds r1, #1 8033314: 1871 adds r1, r6, r1 8033316: 4620 mov r0, r4 8033318: b289 uxth r1, r1 803331a: 2340 movs r3, #64 ; 0x40 803331c: f7fd f962 bl 80305e4 if (derr != ERR_OK) 8033320: 2800 cmp r0, #0 8033322: d168 bne.n 80333f6 { snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* add zero terminator */ len = ((len < (SNMP_COMMUNITY_STR_LEN))?(len):(SNMP_COMMUNITY_STR_LEN)); 8033324: f8bd 3012 ldrh.w r3, [sp, #18] m_stat->community[len] = 0; 8033328: f1a5 0218 sub.w r2, r5, #24 { snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* add zero terminator */ len = ((len < (SNMP_COMMUNITY_STR_LEN))?(len):(SNMP_COMMUNITY_STR_LEN)); 803332c: 2b40 cmp r3, #64 ; 0x40 803332e: bf28 it cs 8033330: 2340 movcs r3, #64 ; 0x40 m_stat->community[len] = 0; 8033332: 18d1 adds r1, r2, r3 snmp_inc_snmpinbadcommunitynames(); snmp_authfail_trap(); return ERR_ARG; }*/ ofs += (1 + len_octets + len); 8033334: f89d 200e ldrb.w r2, [sp, #14] { snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* add zero terminator */ len = ((len < (SNMP_COMMUNITY_STR_LEN))?(len):(SNMP_COMMUNITY_STR_LEN)); 8033338: f8ad 3012 strh.w r3, [sp, #18] m_stat->community[len] = 0; m_stat->com_strlen = (u8_t)len; 803333c: f885 3041 strb.w r3, [r5, #65] ; 0x41 snmp_inc_snmpinbadcommunitynames(); snmp_authfail_trap(); return ERR_ARG; }*/ ofs += (1 + len_octets + len); 8033340: 189b adds r3, r3, r2 8033342: 18f6 adds r6, r6, r3 8033344: b2b6 uxth r6, r6 8033346: f106 0801 add.w r8, r6, #1 803334a: fa1f f888 uxth.w r8, r8 snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* add zero terminator */ len = ((len < (SNMP_COMMUNITY_STR_LEN))?(len):(SNMP_COMMUNITY_STR_LEN)); m_stat->community[len] = 0; 803334e: 7608 strb r0, [r1, #24] snmp_authfail_trap(); return ERR_ARG; }*/ ofs += (1 + len_octets + len); snmp_asn1_dec_type(p, ofs, &type); 8033350: f10d 020f add.w r2, sp, #15 8033354: 4641 mov r1, r8 8033356: 4620 mov r0, r4 8033358: f7fc ff64 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 803335c: 1cb1 adds r1, r6, #2 803335e: 4620 mov r0, r4 8033360: b289 uxth r1, r1 8033362: f10d 020e add.w r2, sp, #14 8033366: f10d 0312 add.w r3, sp, #18 803336a: f7fc ff70 bl 803024e if (derr != ERR_OK) 803336e: 2800 cmp r0, #0 8033370: d141 bne.n 80333f6 return ERR_ARG; } /* FIX for write/read communuty */ /* GetRequest PDU */ if (type == (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_REQ)) 8033372: f89d 300f ldrb.w r3, [sp, #15] 8033376: 2ba0 cmp r3, #160 ; 0xa0 8033378: d10f bne.n 803339a { if (strncmp(sSettings.sSnmp.readCommunity, (const char*)m_stat->community, strlen(sSettings.sSnmp.readCommunity)) != 0 803337a: 4855 ldr r0, [pc, #340] ; (80334d0 ) 803337c: f7ee fd78 bl 8021e70 8033380: 4629 mov r1, r5 8033382: 4602 mov r2, r0 8033384: 4852 ldr r0, [pc, #328] ; (80334d0 ) 8033386: f7ee fdd5 bl 8021f34 803338a: b120 cbz r0, 8033396 || (strlen(sSettings.sSnmp.readCommunity) != strlen((const char*)m_stat->community)) ) { snmp_inc_snmpinbadcommunitynames(); 803338c: f7fe fd2e bl 8031dec snmp_authfail_trap(); 8033390: f000 fd7e bl 8033e90 8033394: e75e b.n 8033254 /* FIX for write/read communuty */ /* GetRequest PDU */ if (type == (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_REQ)) { if (strncmp(sSettings.sSnmp.readCommunity, (const char*)m_stat->community, strlen(sSettings.sSnmp.readCommunity)) != 0 || (strlen(sSettings.sSnmp.readCommunity) != strlen((const char*)m_stat->community)) ) 8033396: 484e ldr r0, [pc, #312] ; (80334d0 ) 8033398: e00c b.n 80333b4 snmp_authfail_trap(); return ERR_ARG; } } /* SetRequest PDU */ else if (type == (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_SET_REQ)) 803339a: 2ba3 cmp r3, #163 ; 0xa3 803339c: d112 bne.n 80333c4 { if (strncmp(sSettings.sSnmp.writeCommunity, (const char*)m_stat->community, strlen(sSettings.sSnmp.writeCommunity)) != 0 803339e: 484d ldr r0, [pc, #308] ; (80334d4 ) 80333a0: f7ee fd66 bl 8021e70 80333a4: 4629 mov r1, r5 80333a6: 4602 mov r2, r0 80333a8: 484a ldr r0, [pc, #296] ; (80334d4 ) 80333aa: f7ee fdc3 bl 8021f34 80333ae: 2800 cmp r0, #0 80333b0: d1ec bne.n 803338c || (strlen(sSettings.sSnmp.writeCommunity) != strlen((const char*)m_stat->community)) ) 80333b2: 4848 ldr r0, [pc, #288] ; (80334d4 ) 80333b4: f7ee fd5c bl 8021e70 80333b8: 4606 mov r6, r0 80333ba: 4628 mov r0, r5 80333bc: f7ee fd58 bl 8021e70 80333c0: 4286 cmp r6, r0 80333c2: d1e3 bne.n 803338c snmp_authfail_trap(); return ERR_ARG; } } switch(type) 80333c4: f89d 300f ldrb.w r3, [sp, #15] 80333c8: 3ba0 subs r3, #160 ; 0xa0 80333ca: 2b04 cmp r3, #4 80333cc: d813 bhi.n 80333f6 80333ce: e8df f003 tbb [pc, r3] 80333d2: 0603 .short 0x0603 80333d4: 0c09 .short 0x0c09 80333d6: 0f .byte 0x0f 80333d7: 00 .byte 0x00 { case (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_REQ): // GetRequest PDU snmp_inc_snmpingetrequests(); 80333d8: f7fe fd50 bl 8031e7c 80333dc: e100 b.n 80335e0 derr = ERR_OK; break; case (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_NEXT_REQ): // GetNextRequest PDU snmp_inc_snmpingetnexts(); 80333de: f7fe fd55 bl 8031e8c 80333e2: e0fd b.n 80335e0 derr = ERR_OK; break; case (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP): // GetResponse PDU snmp_inc_snmpingetresponses(); 80333e4: f7fe fd62 bl 8031eac 80333e8: e734 b.n 8033254 derr = ERR_ARG; break; case (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_SET_REQ): // SetRequest PDU snmp_inc_snmpinsetrequests(); 80333ea: f7fe fd57 bl 8031e9c 80333ee: e0f7 b.n 80335e0 derr = ERR_OK; break; case (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP): // Trap PDU snmp_inc_snmpintraps(); 80333f0: f7fe fd64 bl 8031ebc 80333f4: e72e b.n 8033254 derr = ERR_ARG; break; default: snmp_inc_snmpinasnparseerrs(); 80333f6: f7fe fd01 bl 8031dfc 80333fa: e72b b.n 8033254 { /* decoded PDU length does not equal actual payload length */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } snmp_asn1_dec_type(p, ofs, &type); 80333fc: 4631 mov r1, r6 80333fe: f10d 020f add.w r2, sp, #15 8033402: 4620 mov r0, r4 8033404: f7fc ff0e bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 8033408: f108 0102 add.w r1, r8, #2 803340c: 4620 mov r0, r4 803340e: b289 uxth r1, r1 8033410: f10d 020e add.w r2, sp, #14 8033414: f10d 0312 add.w r3, sp, #18 8033418: f7fc ff19 bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG))) 803341c: 2800 cmp r0, #0 803341e: d1ea bne.n 80333f6 8033420: f89d 300f ldrb.w r3, [sp, #15] 8033424: 2b02 cmp r3, #2 8033426: d1e6 bne.n 80333f6 { /* can't decode or no integer (request ID) */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } derr = snmp_asn1_dec_s32t(p, ofs + 1 + len_octets, len, &m_stat->rid); 8033428: f89d 100e ldrb.w r1, [sp, #14] 803342c: f8bd 2012 ldrh.w r2, [sp, #18] 8033430: 3101 adds r1, #1 8033432: 1871 adds r1, r6, r1 8033434: 4620 mov r0, r4 8033436: b289 uxth r1, r1 8033438: f105 030c add.w r3, r5, #12 803343c: f7fc ffdd bl 80303fa if (derr != ERR_OK) 8033440: 2800 cmp r0, #0 8033442: d1d8 bne.n 80333f6 { /* can't decode */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } ofs += (1 + len_octets + len); 8033444: f89d 200e ldrb.w r2, [sp, #14] 8033448: f8bd 3012 ldrh.w r3, [sp, #18] 803344c: 18d3 adds r3, r2, r3 803344e: 18f6 adds r6, r6, r3 8033450: b2b6 uxth r6, r6 8033452: 1c77 adds r7, r6, #1 8033454: b2bf uxth r7, r7 snmp_asn1_dec_type(p, ofs, &type); 8033456: 4639 mov r1, r7 8033458: f10d 020f add.w r2, sp, #15 803345c: 4620 mov r0, r4 803345e: f7fc fee1 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 8033462: 1cb1 adds r1, r6, #2 8033464: 4620 mov r0, r4 8033466: b289 uxth r1, r1 8033468: f10d 020e add.w r2, sp, #14 803346c: f10d 0312 add.w r3, sp, #18 8033470: f7fc feed bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG))) 8033474: 2800 cmp r0, #0 8033476: d1be bne.n 80333f6 8033478: f89d 300f ldrb.w r3, [sp, #15] 803347c: 2b02 cmp r3, #2 803347e: d1ba bne.n 80333f6 snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* must be noError (0) for incoming requests. log errors for mib-2 completeness and for debug purposes */ derr = snmp_asn1_dec_s32t(p, ofs + 1 + len_octets, len, &m_stat->error_status); 8033480: f89d 100e ldrb.w r1, [sp, #14] 8033484: f8bd 2012 ldrh.w r2, [sp, #18] 8033488: 3101 adds r1, #1 803348a: 1879 adds r1, r7, r1 803348c: 4620 mov r0, r4 803348e: b289 uxth r1, r1 8033490: f105 0310 add.w r3, r5, #16 8033494: f7fc ffb1 bl 80303fa if (derr != ERR_OK) 8033498: 2800 cmp r0, #0 803349a: d1ac bne.n 80333f6 { /* can't decode */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } switch (m_stat->error_status) 803349c: 692b ldr r3, [r5, #16] 803349e: 3b01 subs r3, #1 80334a0: 2b04 cmp r3, #4 80334a2: d81b bhi.n 80334dc 80334a4: e8df f003 tbb [pc, r3] 80334a8: 0c090603 .word 0x0c090603 80334ac: 18 .byte 0x18 80334ad: 00 .byte 0x00 { case SNMP_ES_TOOBIG: snmp_inc_snmpintoobigs(); 80334ae: f7fe fcad bl 8031e0c 80334b2: e013 b.n 80334dc break; case SNMP_ES_NOSUCHNAME: snmp_inc_snmpinnosuchnames(); 80334b4: f7fe fcb2 bl 8031e1c 80334b8: e010 b.n 80334dc break; case SNMP_ES_BADVALUE: snmp_inc_snmpinbadvalues(); 80334ba: f7fe fcb7 bl 8031e2c 80334be: e00d b.n 80334dc break; case SNMP_ES_READONLY: snmp_inc_snmpinreadonlys(); 80334c0: f7fe fcbc bl 8031e3c 80334c4: e00a b.n 80334dc 80334c6: bf00 nop 80334c8: 20011010 .word 0x20011010 80334cc: 20011028 .word 0x20011028 80334d0: 2000e9e8 .word 0x2000e9e8 80334d4: 2000e9fc .word 0x2000e9fc break; case SNMP_ES_GENERROR: snmp_inc_snmpingenerrs(); 80334d8: f7fe fcb8 bl 8031e4c break; } ofs += (1 + len_octets + len); 80334dc: f89d 200e ldrb.w r2, [sp, #14] 80334e0: f8bd 3012 ldrh.w r3, [sp, #18] 80334e4: 18d3 adds r3, r2, r3 80334e6: 18ff adds r7, r7, r3 80334e8: b2bf uxth r7, r7 80334ea: 1c7d adds r5, r7, #1 80334ec: b2ad uxth r5, r5 snmp_asn1_dec_type(p, ofs, &type); 80334ee: 4629 mov r1, r5 80334f0: f10d 020f add.w r2, sp, #15 80334f4: 4620 mov r0, r4 80334f6: f7fc fe95 bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 80334fa: 1cb9 adds r1, r7, #2 80334fc: 4620 mov r0, r4 80334fe: b289 uxth r1, r1 8033500: f10d 020e add.w r2, sp, #14 8033504: f10d 0312 add.w r3, sp, #18 8033508: f7fc fea1 bl 803024e if ((derr != ERR_OK) || (type != (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG))) 803350c: 2800 cmp r0, #0 803350e: f47f af72 bne.w 80333f6 8033512: f89d 300f ldrb.w r3, [sp, #15] 8033516: 2b02 cmp r3, #2 8033518: f47f af6d bne.w 80333f6 snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } /* must be 0 for incoming requests. decode anyway to catch bad integers (and dirty tricks) */ derr = snmp_asn1_dec_s32t(p, ofs + 1 + len_octets, len, &m_stat->error_index); 803351c: f89d 100e ldrb.w r1, [sp, #14] 8033520: f8bd 2012 ldrh.w r2, [sp, #18] 8033524: 4b3a ldr r3, [pc, #232] ; (8033610 ) 8033526: 3101 adds r1, #1 8033528: 1869 adds r1, r5, r1 803352a: 4620 mov r0, r4 803352c: b289 uxth r1, r1 803352e: f7fc ff64 bl 80303fa if (derr != ERR_OK) 8033532: 2800 cmp r0, #0 8033534: f47f af5f bne.w 80333f6 { /* can't decode */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } ofs += (1 + len_octets + len); 8033538: f8bd 3012 ldrh.w r3, [sp, #18] 803353c: f89d 200e ldrb.w r2, [sp, #14] 8033540: 3301 adds r3, #1 8033542: 189b adds r3, r3, r2 8033544: 18ed adds r5, r5, r3 /* check total length, version, community, pdu type */ err_ret = snmp_pdu_header_check(p, payload_ofs, payload_len, &varbind_ofs, msg_ps); /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && 8033546: 4b33 ldr r3, [pc, #204] ; (8033614 ) /* can't decode */ snmp_inc_snmpinasnparseerrs(); return ERR_ARG; } ofs += (1 + len_octets + len); *ofs_ret = ofs; 8033548: f8ad 5010 strh.w r5, [sp, #16] /* check total length, version, community, pdu type */ err_ret = snmp_pdu_header_check(p, payload_ofs, payload_len, &varbind_ofs, msg_ps); /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && 803354c: 7a9a ldrb r2, [r3, #10] /* check total length, version, community, pdu type */ err_ret = snmp_pdu_header_check(p, payload_ofs, payload_len, &varbind_ofs, msg_ps); /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || 803354e: b132 cbz r2, 803355e ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_GET_NEXT_REQ) && 8033550: 7a9a ldrb r2, [r3, #10] /* check total length, version, community, pdu type */ err_ret = snmp_pdu_header_check(p, payload_ofs, payload_len, &varbind_ofs, msg_ps); /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && 8033552: 2a01 cmp r2, #1 8033554: d003 beq.n 803355e (msg_ps->rt != SNMP_ASN1_PDU_GET_NEXT_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_SET_REQ)) || 8033556: 7a9a ldrb r2, [r3, #10] err_ret = snmp_pdu_header_check(p, payload_ofs, payload_len, &varbind_ofs, msg_ps); /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_GET_NEXT_REQ) && 8033558: 2a03 cmp r2, #3 803355a: f47f ae7b bne.w 8033254 (msg_ps->rt != SNMP_ASN1_PDU_SET_REQ)) || ((msg_ps->error_status != SNMP_ES_NOERROR) || 803355e: 691b ldr r3, [r3, #16] 8033560: 4d2c ldr r5, [pc, #176] ; (8033614 ) /* Only accept requests and requests without error (be robust) */ /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_GET_NEXT_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_SET_REQ)) || 8033562: 2b00 cmp r3, #0 8033564: f47f ae76 bne.w 8033254 ((msg_ps->error_status != SNMP_ES_NOERROR) || (msg_ps->error_index != 0)) ) 8033568: 696b ldr r3, [r5, #20] /* Reject response and trap headers or error requests as input! */ if ((err_ret != ERR_OK) || ((msg_ps->rt != SNMP_ASN1_PDU_GET_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_GET_NEXT_REQ) && (msg_ps->rt != SNMP_ASN1_PDU_SET_REQ)) || ((msg_ps->error_status != SNMP_ES_NOERROR) || 803356a: 2b00 cmp r3, #0 803356c: f47f ae72 bne.w 8033254 } LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_recv ok, community %s\n", msg_ps->community)); /* Builds a list of variable bindings. Copy the varbinds from the pbuf chain to glue them when these are divided over two or more pbuf's. */ err_ret = snmp_pdu_dec_varbindlist(p, varbind_ofs, &varbind_ofs, msg_ps); 8033570: aa06 add r2, sp, #24 8033572: 4620 mov r0, r4 8033574: f832 1d08 ldrh.w r1, [r2, #-8]! 8033578: 462b mov r3, r5 803357a: f7ff fd01 bl 8032f80 803357e: 4606 mov r6, r0 /* we've decoded the incoming message, release input msg now */ pbuf_free(p); 8033580: 4620 mov r0, r4 8033582: f7f9 fd55 bl 802d030 if ((err_ret != ERR_OK) || (msg_ps->invb.count == 0)) 8033586: 2e00 cmp r6, #0 8033588: d13f bne.n 803360a 803358a: f895 3108 ldrb.w r3, [r5, #264] ; 0x108 803358e: 2b00 cmp r3, #0 8033590: d03b beq.n 803360a } msg_ps->error_status = SNMP_ES_NOERROR; msg_ps->error_index = 0; /* find object for each variable binding */ msg_ps->state = SNMP_MSG_SEARCH_OBJ; 8033592: 2301 movs r3, #1 (errors are only returned for a specific varbind failure) */ LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_pdu_dec_varbindlist() failed\n")); return; } msg_ps->error_status = SNMP_ES_NOERROR; 8033594: 612e str r6, [r5, #16] msg_ps->vb_idx = 0; LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_recv varbind cnt=%"U16_F"\n",(u16_t)msg_ps->invb.count)); /* handle input event and as much objects as possible in one go */ snmp_msg_event(req_idx); 8033596: 4630 mov r0, r6 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_pdu_dec_varbindlist() failed\n")); return; } msg_ps->error_status = SNMP_ES_NOERROR; msg_ps->error_index = 0; 8033598: 616e str r6, [r5, #20] /* find object for each variable binding */ msg_ps->state = SNMP_MSG_SEARCH_OBJ; 803359a: f885 305a strb.w r3, [r5, #90] ; 0x5a /* first variable binding from list to inspect */ msg_ps->vb_idx = 0; 803359e: f885 60f8 strb.w r6, [r5, #248] ; 0xf8 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_recv varbind cnt=%"U16_F"\n",(u16_t)msg_ps->invb.count)); /* handle input event and as much objects as possible in one go */ snmp_msg_event(req_idx); 80335a2: f7ff f94d bl 8032840 80335a6: e030 b.n 803360a pbuf_free(p); return; } /* accepting request */ snmp_inc_snmpinpkts(); 80335a8: f7fe fc08 bl 8031dbc /* record used 'protocol control block' */ msg_ps->pcb = pcb; /* source address (network order) */ msg_ps->sip = *addr; 80335ac: f8d9 3000 ldr.w r3, [r9] } /* accepting request */ snmp_inc_snmpinpkts(); /* record used 'protocol control block' */ msg_ps->pcb = pcb; 80335b0: f8c5 8000 str.w r8, [r5] /* source address (network order) */ msg_ps->sip = *addr; 80335b4: 606b str r3, [r5, #4] /* source port (host order (lwIP oddity)) */ msg_ps->sp = port; 80335b6: f8bd 3038 ldrh.w r3, [sp, #56] ; 0x38 u8_t len_octets; u8_t type; s32_t version; ofs_base = ofs; snmp_asn1_dec_type(p, ofs, &type); 80335ba: 4631 mov r1, r6 /* record used 'protocol control block' */ msg_ps->pcb = pcb; /* source address (network order) */ msg_ps->sip = *addr; /* source port (host order (lwIP oddity)) */ msg_ps->sp = port; 80335bc: 812b strh r3, [r5, #8] u8_t len_octets; u8_t type; s32_t version; ofs_base = ofs; snmp_asn1_dec_type(p, ofs, &type); 80335be: f10d 020f add.w r2, sp, #15 80335c2: 4620 mov r0, r4 80335c4: f7fc fe2e bl 8030224 derr = snmp_asn1_dec_length(p, ofs+1, &len_octets, &len); 80335c8: 4620 mov r0, r4 80335ca: 2101 movs r1, #1 80335cc: f10d 020e add.w r2, sp, #14 80335d0: f10d 0312 add.w r3, sp, #18 80335d4: f7fc fe3b bl 803024e if ((derr != ERR_OK) || 80335d8: 2800 cmp r0, #0 80335da: f43f ae3f beq.w 803325c 80335de: e70a b.n 80333f6 if (derr != ERR_OK) { /* unsupported input PDU for this agent (no parse error) */ return ERR_ARG; } m_stat->rt = type & 0x1F; 80335e0: f89d 300f ldrb.w r3, [sp, #15] 80335e4: 4d0b ldr r5, [pc, #44] ; (8033614 ) 80335e6: f003 031f and.w r3, r3, #31 80335ea: 72ab strb r3, [r5, #10] ofs += (1 + len_octets); 80335ec: f89d 300e ldrb.w r3, [sp, #14] 80335f0: 4498 add r8, r3 80335f2: fa1f f888 uxth.w r8, r8 80335f6: f108 0601 add.w r6, r8, #1 80335fa: b2b6 uxth r6, r6 if (len != (pdu_len - (ofs - ofs_base))) 80335fc: f8bd 3012 ldrh.w r3, [sp, #18] 8033600: 1bbf subs r7, r7, r6 8033602: 42bb cmp r3, r7 8033604: f43f aefa beq.w 80333fc 8033608: e6f5 b.n 80333f6 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_recv varbind cnt=%"U16_F"\n",(u16_t)msg_ps->invb.count)); /* handle input event and as much objects as possible in one go */ snmp_msg_event(req_idx); } 803360a: b007 add sp, #28 803360c: e8bd 83f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, pc} 8033610: 20011024 .word 0x20011024 8033614: 20011010 .word 0x20011010 08033618 : * @param root points to the root of the variable binding list * @return the required lenght for encoding the variable bindings */ static u16_t snmp_varbind_list_sum(struct snmp_varbind_root *root) { 8033618: b5f8 push {r3, r4, r5, r6, r7, lr} struct snmp_varbind *vb; u32_t *uint_ptr; s32_t *sint_ptr; u16_t tot_len; tot_len = 0; 803361a: 2500 movs r5, #0 * @param root points to the root of the variable binding list * @return the required lenght for encoding the variable bindings */ static u16_t snmp_varbind_list_sum(struct snmp_varbind_root *root) { 803361c: 4606 mov r6, r0 u32_t *uint_ptr; s32_t *sint_ptr; u16_t tot_len; tot_len = 0; vb = root->tail; 803361e: 6844 ldr r4, [r0, #4] sint_ptr = (s32_t*)vb->value; snmp_asn1_enc_oid_cnt(vb->value_len / sizeof(s32_t), sint_ptr, &vb->vlen); break; default: /* unsupported type */ vb->vlen = 0; 8033620: 462f mov r7, r5 s32_t *sint_ptr; u16_t tot_len; tot_len = 0; vb = root->tail; while ( vb != NULL ) 8033622: e051 b.n 80336c8 { /* encoded value lenght depends on type */ switch (vb->value_type) 8033624: 7c23 ldrb r3, [r4, #16] 8033626: 2b06 cmp r3, #6 8033628: d020 beq.n 803366c 803362a: d805 bhi.n 8033638 803362c: 2b02 cmp r3, #2 803362e: d00c beq.n 803364a 8033630: d324 bcc.n 803367c 8033632: 2b04 cmp r3, #4 8033634: d322 bcc.n 803367c 8033636: e016 b.n 8033666 8033638: 2b43 cmp r3, #67 ; 0x43 803363a: d803 bhi.n 8033644 803363c: 2b41 cmp r3, #65 ; 0x41 803363e: d20b bcs.n 8033658 8033640: 2b40 cmp r3, #64 ; 0x40 8033642: e000 b.n 8033646 8033644: 2b44 cmp r3, #68 ; 0x44 8033646: d119 bne.n 803367c 8033648: e00d b.n 8033666 { case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG): sint_ptr = (s32_t*)vb->value; snmp_asn1_enc_s32t_cnt(*sint_ptr, &vb->vlen); 803364a: 6963 ldr r3, [r4, #20] 803364c: f104 0120 add.w r1, r4, #32 8033650: 6818 ldr r0, [r3, #0] 8033652: f7fd f81e bl 8030692 break; 8033656: e012 b.n 803367e case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_GAUGE): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS): uint_ptr = (u32_t*)vb->value; snmp_asn1_enc_u32t_cnt(*uint_ptr, &vb->vlen); 8033658: 6963 ldr r3, [r4, #20] 803365a: f104 0120 add.w r1, r4, #32 803365e: 6818 ldr r0, [r3, #0] 8033660: f7fd f802 bl 8030668 break; 8033664: e00b b.n 803367e case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR): case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_NUL): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_OPAQUE): vb->vlen = vb->value_len; 8033666: 7c63 ldrb r3, [r4, #17] 8033668: 8423 strh r3, [r4, #32] break; 803366a: e008 b.n 803367e case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID): sint_ptr = (s32_t*)vb->value; snmp_asn1_enc_oid_cnt(vb->value_len / sizeof(s32_t), sint_ptr, &vb->vlen); 803366c: 7c60 ldrb r0, [r4, #17] 803366e: 6961 ldr r1, [r4, #20] 8033670: 0880 lsrs r0, r0, #2 8033672: f104 0220 add.w r2, r4, #32 8033676: f7fd f821 bl 80306bc break; 803367a: e000 b.n 803367e default: /* unsupported type */ vb->vlen = 0; 803367c: 8427 strh r7, [r4, #32] break; }; /* encoding length of value length field */ snmp_asn1_enc_length_cnt(vb->vlen, &vb->vlenlen); 803367e: 8c20 ldrh r0, [r4, #32] 8033680: f104 011a add.w r1, r4, #26 8033684: f7fc ffe5 bl 8030652 snmp_asn1_enc_oid_cnt(vb->ident_len, vb->ident, &vb->olen); 8033688: f104 021e add.w r2, r4, #30 803368c: 7a20 ldrb r0, [r4, #8] 803368e: 68e1 ldr r1, [r4, #12] 8033690: f7fd f814 bl 80306bc snmp_asn1_enc_length_cnt(vb->olen, &vb->olenlen); 8033694: 8be0 ldrh r0, [r4, #30] 8033696: f104 0119 add.w r1, r4, #25 803369a: f7fc ffda bl 8030652 vb->seqlen = 1 + vb->vlenlen + vb->vlen; 803369e: 8be3 ldrh r3, [r4, #30] 80336a0: 8c20 ldrh r0, [r4, #32] 80336a2: 18c0 adds r0, r0, r3 80336a4: 7ea3 ldrb r3, [r4, #26] vb->seqlen += 1 + vb->olenlen + vb->olen; 80336a6: 3002 adds r0, #2 80336a8: 18c0 adds r0, r0, r3 80336aa: 7e63 ldrb r3, [r4, #25] 80336ac: 18c0 adds r0, r0, r3 80336ae: b280 uxth r0, r0 80336b0: 83a0 strh r0, [r4, #28] snmp_asn1_enc_length_cnt(vb->seqlen, &vb->seqlenlen); 80336b2: f104 0118 add.w r1, r4, #24 80336b6: f7fc ffcc bl 8030652 /* varbind seq */ tot_len += 1 + vb->seqlenlen + vb->seqlen; 80336ba: 8ba3 ldrh r3, [r4, #28] 80336bc: 7e22 ldrb r2, [r4, #24] vb = vb->prev; 80336be: 6864 ldr r4, [r4, #4] vb->seqlen = 1 + vb->vlenlen + vb->vlen; vb->seqlen += 1 + vb->olenlen + vb->olen; snmp_asn1_enc_length_cnt(vb->seqlen, &vb->seqlenlen); /* varbind seq */ tot_len += 1 + vb->seqlenlen + vb->seqlen; 80336c0: 3301 adds r3, #1 80336c2: 189b adds r3, r3, r2 80336c4: 18ed adds r5, r5, r3 80336c6: b2ad uxth r5, r5 s32_t *sint_ptr; u16_t tot_len; tot_len = 0; vb = root->tail; while ( vb != NULL ) 80336c8: 2c00 cmp r4, #0 80336ca: d1ab bne.n 8033624 vb = vb->prev; } /* varbind-list seq */ root->seqlen = tot_len; snmp_asn1_enc_length_cnt(root->seqlen, &root->seqlenlen); 80336cc: 4628 mov r0, r5 vb = vb->prev; } /* varbind-list seq */ root->seqlen = tot_len; 80336ce: 8175 strh r5, [r6, #10] snmp_asn1_enc_length_cnt(root->seqlen, &root->seqlenlen); 80336d0: f106 0109 add.w r1, r6, #9 80336d4: f7fc ffbd bl 8030652 tot_len += 1 + root->seqlenlen; 80336d8: 7a73 ldrb r3, [r6, #9] 80336da: 3301 adds r3, #1 80336dc: 18e8 adds r0, r5, r3 return tot_len; } 80336de: b280 uxth r0, r0 80336e0: bdf8 pop {r3, r4, r5, r6, r7, pc} 80336e2: 0000 movs r0, r0 080336e4 : * @param rhl points to returned header lengths * @return the required lenght for encoding the response header */ static u16_t snmp_resp_header_sum(struct snmp_msg_pstat *m_stat, u16_t vb_len) { 80336e4: e92d 47f0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, lr} 80336e8: 4604 mov r4, r0 u16_t tot_len; struct snmp_resp_header_lengths *rhl; rhl = &m_stat->rhl; tot_len = vb_len; snmp_asn1_enc_s32t_cnt(m_stat->error_index, &rhl->erridxlen); 80336ea: f500 758c add.w r5, r0, #280 ; 0x118 * @param rhl points to returned header lengths * @return the required lenght for encoding the response header */ static u16_t snmp_resp_header_sum(struct snmp_msg_pstat *m_stat, u16_t vb_len) { 80336ee: 460f mov r7, r1 u16_t tot_len; struct snmp_resp_header_lengths *rhl; rhl = &m_stat->rhl; tot_len = vb_len; snmp_asn1_enc_s32t_cnt(m_stat->error_index, &rhl->erridxlen); 80336f0: 6940 ldr r0, [r0, #20] 80336f2: f504 7190 add.w r1, r4, #288 ; 0x120 80336f6: f7fc ffcc bl 8030692 snmp_asn1_enc_length_cnt(rhl->erridxlen, &rhl->erridxlenlen); 80336fa: f8b4 0120 ldrh.w r0, [r4, #288] ; 0x120 80336fe: 4629 mov r1, r5 8033700: f7fc ffa7 bl 8030652 tot_len += 1 + rhl->erridxlenlen + rhl->erridxlen; snmp_asn1_enc_s32t_cnt(m_stat->error_status, &rhl->errstatlen); 8033704: 6920 ldr r0, [r4, #16] rhl = &m_stat->rhl; tot_len = vb_len; snmp_asn1_enc_s32t_cnt(m_stat->error_index, &rhl->erridxlen); snmp_asn1_enc_length_cnt(rhl->erridxlen, &rhl->erridxlenlen); tot_len += 1 + rhl->erridxlenlen + rhl->erridxlen; 8033706: f894 8118 ldrb.w r8, [r4, #280] ; 0x118 803370a: f8b4 a120 ldrh.w sl, [r4, #288] ; 0x120 snmp_asn1_enc_s32t_cnt(m_stat->error_status, &rhl->errstatlen); 803370e: f504 7191 add.w r1, r4, #290 ; 0x122 8033712: f7fc ffbe bl 8030692 snmp_asn1_enc_length_cnt(rhl->errstatlen, &rhl->errstatlenlen); 8033716: 1c69 adds r1, r5, #1 8033718: f8b4 0122 ldrh.w r0, [r4, #290] ; 0x122 803371c: f7fc ff99 bl 8030652 tot_len += 1 + rhl->errstatlenlen + rhl->errstatlen; 8033720: f8b4 9122 ldrh.w r9, [r4, #290] ; 0x122 snmp_asn1_enc_s32t_cnt(m_stat->rid, &rhl->ridlen); 8033724: 68e0 ldr r0, [r4, #12] snmp_asn1_enc_length_cnt(rhl->erridxlen, &rhl->erridxlenlen); tot_len += 1 + rhl->erridxlenlen + rhl->erridxlen; snmp_asn1_enc_s32t_cnt(m_stat->error_status, &rhl->errstatlen); snmp_asn1_enc_length_cnt(rhl->errstatlen, &rhl->errstatlenlen); tot_len += 1 + rhl->errstatlenlen + rhl->errstatlen; 8033726: f894 6119 ldrb.w r6, [r4, #281] ; 0x119 snmp_asn1_enc_s32t_cnt(m_stat->rid, &rhl->ridlen); 803372a: f504 7192 add.w r1, r4, #292 ; 0x124 803372e: f7fc ffb0 bl 8030692 snmp_asn1_enc_length_cnt(rhl->ridlen, &rhl->ridlenlen); 8033732: f8b4 0124 ldrh.w r0, [r4, #292] ; 0x124 8033736: f504 718d add.w r1, r4, #282 ; 0x11a 803373a: f7fc ff8a bl 8030652 rhl = &m_stat->rhl; tot_len = vb_len; snmp_asn1_enc_s32t_cnt(m_stat->error_index, &rhl->erridxlen); snmp_asn1_enc_length_cnt(rhl->erridxlen, &rhl->erridxlenlen); tot_len += 1 + rhl->erridxlenlen + rhl->erridxlen; 803373e: 44d1 add r9, sl snmp_asn1_enc_s32t_cnt(m_stat->error_status, &rhl->errstatlen); snmp_asn1_enc_length_cnt(rhl->errstatlen, &rhl->errstatlenlen); tot_len += 1 + rhl->errstatlenlen + rhl->errstatlen; 8033740: f8b4 3124 ldrh.w r3, [r4, #292] ; 0x124 8033744: f109 0903 add.w r9, r9, #3 8033748: 4499 add r9, r3 803374a: fa18 f889 uxtah r8, r8, r9 snmp_asn1_enc_s32t_cnt(m_stat->rid, &rhl->ridlen); snmp_asn1_enc_length_cnt(rhl->ridlen, &rhl->ridlenlen); tot_len += 1 + rhl->ridlenlen + rhl->ridlen; 803374e: f894 311a ldrb.w r3, [r4, #282] ; 0x11a 8033752: 4446 add r6, r8 8033754: 18f6 adds r6, r6, r3 8033756: fa17 f686 uxtah r6, r7, r6 803375a: b2b6 uxth r6, r6 rhl->pdulen = tot_len; snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); 803375c: 1ce9 adds r1, r5, #3 803375e: 4630 mov r0, r6 snmp_asn1_enc_s32t_cnt(m_stat->rid, &rhl->ridlen); snmp_asn1_enc_length_cnt(rhl->ridlen, &rhl->ridlenlen); tot_len += 1 + rhl->ridlenlen + rhl->ridlen; rhl->pdulen = tot_len; 8033760: f8a4 6126 strh.w r6, [r4, #294] ; 0x126 snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); 8033764: f7fc ff75 bl 8030652 tot_len += 1 + rhl->pdulenlen; rhl->comlen = m_stat->com_strlen; 8033768: f894 0059 ldrb.w r0, [r4, #89] ; 0x59 snmp_asn1_enc_length_cnt(rhl->ridlen, &rhl->ridlenlen); tot_len += 1 + rhl->ridlenlen + rhl->ridlen; rhl->pdulen = tot_len; snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); tot_len += 1 + rhl->pdulenlen; 803376c: f894 811b ldrb.w r8, [r4, #283] ; 0x11b rhl->comlen = m_stat->com_strlen; 8033770: f8a4 0128 strh.w r0, [r4, #296] ; 0x128 snmp_asn1_enc_length_cnt(rhl->comlen, &rhl->comlenlen); 8033774: f504 718e add.w r1, r4, #284 ; 0x11c 8033778: f7fc ff6b bl 8030652 tot_len += 1 + rhl->comlenlen + rhl->comlen; snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); 803377c: 4b14 ldr r3, [pc, #80] ; (80337d0 ) snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); tot_len += 1 + rhl->pdulenlen; rhl->comlen = m_stat->com_strlen; snmp_asn1_enc_length_cnt(rhl->comlen, &rhl->comlenlen); tot_len += 1 + rhl->comlenlen + rhl->comlen; 803377e: f894 711c ldrb.w r7, [r4, #284] ; 0x11c snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); 8033782: 6818 ldr r0, [r3, #0] snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); tot_len += 1 + rhl->pdulenlen; rhl->comlen = m_stat->com_strlen; snmp_asn1_enc_length_cnt(rhl->comlen, &rhl->comlenlen); tot_len += 1 + rhl->comlenlen + rhl->comlen; 8033784: f8b4 9128 ldrh.w r9, [r4, #296] ; 0x128 snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); 8033788: f504 7195 add.w r1, r4, #298 ; 0x12a 803378c: f7fc ff81 bl 8030692 snmp_asn1_enc_length_cnt(rhl->verlen, &rhl->verlenlen); 8033790: 1d69 adds r1, r5, #5 8033792: f8b4 012a ldrh.w r0, [r4, #298] ; 0x12a 8033796: f7fc ff5c bl 8030652 snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); tot_len += 1 + rhl->pdulenlen; rhl->comlen = m_stat->com_strlen; snmp_asn1_enc_length_cnt(rhl->comlen, &rhl->comlenlen); tot_len += 1 + rhl->comlenlen + rhl->comlen; 803379a: f8b4 512a ldrh.w r5, [r4, #298] ; 0x12a snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); snmp_asn1_enc_length_cnt(rhl->verlen, &rhl->verlenlen); tot_len += 1 + rhl->verlen + rhl->verlenlen; 803379e: f894 311d ldrb.w r3, [r4, #285] ; 0x11d snmp_asn1_enc_length_cnt(rhl->pdulen, &rhl->pdulenlen); tot_len += 1 + rhl->pdulenlen; rhl->comlen = m_stat->com_strlen; snmp_asn1_enc_length_cnt(rhl->comlen, &rhl->comlenlen); tot_len += 1 + rhl->comlenlen + rhl->comlen; 80337a2: 444d add r5, r9 80337a4: 3503 adds r5, #3 80337a6: 4445 add r5, r8 snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); snmp_asn1_enc_length_cnt(rhl->verlen, &rhl->verlenlen); tot_len += 1 + rhl->verlen + rhl->verlenlen; 80337a8: 197d adds r5, r7, r5 80337aa: 18ed adds r5, r5, r3 80337ac: fa16 f585 uxtah r5, r6, r5 80337b0: b2ad uxth r5, r5 rhl->seqlen = tot_len; snmp_asn1_enc_length_cnt(rhl->seqlen, &rhl->seqlenlen); 80337b2: 4628 mov r0, r5 snmp_asn1_enc_s32t_cnt(snmp_version, &rhl->verlen); snmp_asn1_enc_length_cnt(rhl->verlen, &rhl->verlenlen); tot_len += 1 + rhl->verlen + rhl->verlenlen; rhl->seqlen = tot_len; 80337b4: f8a4 512c strh.w r5, [r4, #300] ; 0x12c snmp_asn1_enc_length_cnt(rhl->seqlen, &rhl->seqlenlen); 80337b8: f504 718f add.w r1, r4, #286 ; 0x11e 80337bc: f7fc ff49 bl 8030652 tot_len += 1 + rhl->seqlenlen; 80337c0: f894 311e ldrb.w r3, [r4, #286] ; 0x11e 80337c4: 3301 adds r3, #1 80337c6: 18e8 adds r0, r5, r3 return tot_len; } 80337c8: b280 uxth r0, r0 80337ca: e8bd 87f0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, pc} 80337ce: bf00 nop 80337d0: 080407ac .word 0x080407ac 080337d4 : /** * Encodes varbind list from head to tail. */ static u16_t snmp_varbind_list_enc(struct snmp_varbind_root *root, struct pbuf *p, u16_t ofs) { 80337d4: b570 push {r4, r5, r6, lr} 80337d6: 4616 mov r6, r2 80337d8: 4604 mov r4, r0 s32_t *sint_ptr; u32_t *uint_ptr; u8_t *raw_ptr; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); ofs += 1; 80337da: 3601 adds r6, #1 /** * Encodes varbind list from head to tail. */ static u16_t snmp_varbind_list_enc(struct snmp_varbind_root *root, struct pbuf *p, u16_t ofs) { 80337dc: 460d mov r5, r1 struct snmp_varbind *vb; s32_t *sint_ptr; u32_t *uint_ptr; u8_t *raw_ptr; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 80337de: 4608 mov r0, r1 ofs += 1; 80337e0: b2b6 uxth r6, r6 struct snmp_varbind *vb; s32_t *sint_ptr; u32_t *uint_ptr; u8_t *raw_ptr; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 80337e2: 4611 mov r1, r2 80337e4: 2230 movs r2, #48 ; 0x30 80337e6: f7fc ff81 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, root->seqlen); 80337ea: 4628 mov r0, r5 80337ec: 4631 mov r1, r6 80337ee: 8962 ldrh r2, [r4, #10] 80337f0: f7fc ff90 bl 8030714 ofs += root->seqlenlen; 80337f4: 7a63 ldrb r3, [r4, #9] 80337f6: e064 b.n 80338c2 vb = root->head; while ( vb != NULL ) { snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 80337f8: 4631 mov r1, r6 ofs += 1; 80337fa: 3601 adds r6, #1 ofs += root->seqlenlen; vb = root->head; while ( vb != NULL ) { snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 80337fc: 2230 movs r2, #48 ; 0x30 ofs += 1; 80337fe: b2b6 uxth r6, r6 ofs += root->seqlenlen; vb = root->head; while ( vb != NULL ) { snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 8033800: 4628 mov r0, r5 8033802: f7fc ff73 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, vb->seqlen); 8033806: 4631 mov r1, r6 8033808: 8ba2 ldrh r2, [r4, #28] 803380a: 4628 mov r0, r5 803380c: f7fc ff82 bl 8030714 ofs += vb->seqlenlen; 8033810: 7e23 ldrb r3, [r4, #24] 8033812: 18f6 adds r6, r6, r3 8033814: b2b6 uxth r6, r6 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 8033816: 4631 mov r1, r6 ofs += 1; 8033818: 3601 adds r6, #1 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); ofs += 1; snmp_asn1_enc_length(p, ofs, vb->seqlen); ofs += vb->seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 803381a: 2206 movs r2, #6 ofs += 1; 803381c: b2b6 uxth r6, r6 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); ofs += 1; snmp_asn1_enc_length(p, ofs, vb->seqlen); ofs += vb->seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 803381e: 4628 mov r0, r5 8033820: f7fc ff64 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, vb->olen); 8033824: 4631 mov r1, r6 8033826: 8be2 ldrh r2, [r4, #30] 8033828: 4628 mov r0, r5 803382a: f7fc ff73 bl 8030714 ofs += vb->olenlen; 803382e: 7e63 ldrb r3, [r4, #25] snmp_asn1_enc_oid(p, ofs, vb->ident_len, &vb->ident[0]); 8033830: 7a22 ldrb r2, [r4, #8] ofs += vb->seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); ofs += 1; snmp_asn1_enc_length(p, ofs, vb->olen); ofs += vb->olenlen; 8033832: 18f6 adds r6, r6, r3 8033834: b2b6 uxth r6, r6 snmp_asn1_enc_oid(p, ofs, vb->ident_len, &vb->ident[0]); 8033836: 4631 mov r1, r6 8033838: 68e3 ldr r3, [r4, #12] 803383a: 4628 mov r0, r5 803383c: f7fd f81f bl 803087e ofs += vb->olen; 8033840: 8be3 ldrh r3, [r4, #30] snmp_asn1_enc_type(p, ofs, vb->value_type); 8033842: 7c22 ldrb r2, [r4, #16] snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); ofs += 1; snmp_asn1_enc_length(p, ofs, vb->olen); ofs += vb->olenlen; snmp_asn1_enc_oid(p, ofs, vb->ident_len, &vb->ident[0]); ofs += vb->olen; 8033844: 18f6 adds r6, r6, r3 8033846: b2b6 uxth r6, r6 snmp_asn1_enc_type(p, ofs, vb->value_type); 8033848: 4631 mov r1, r6 ofs += 1; 803384a: 3601 adds r6, #1 803384c: b2b6 uxth r6, r6 snmp_asn1_enc_length(p, ofs, vb->olen); ofs += vb->olenlen; snmp_asn1_enc_oid(p, ofs, vb->ident_len, &vb->ident[0]); ofs += vb->olen; snmp_asn1_enc_type(p, ofs, vb->value_type); 803384e: 4628 mov r0, r5 8033850: f7fc ff4c bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, vb->vlen); 8033854: 4631 mov r1, r6 8033856: 4628 mov r0, r5 8033858: 8c22 ldrh r2, [r4, #32] 803385a: f7fc ff5b bl 8030714 ofs += vb->vlenlen; 803385e: 7ea3 ldrb r3, [r4, #26] 8033860: 18f6 adds r6, r6, r3 switch (vb->value_type) 8033862: 7c23 ldrb r3, [r4, #16] 8033864: 2b40 cmp r3, #64 ; 0x40 ofs += vb->olen; snmp_asn1_enc_type(p, ofs, vb->value_type); ofs += 1; snmp_asn1_enc_length(p, ofs, vb->vlen); ofs += vb->vlenlen; 8033866: b2b6 uxth r6, r6 switch (vb->value_type) 8033868: d01c beq.n 80338a4 803386a: d806 bhi.n 803387a 803386c: 2b04 cmp r3, #4 803386e: d019 beq.n 80338a4 8033870: 2b06 cmp r3, #6 8033872: d01e beq.n 80338b2 8033874: 2b02 cmp r3, #2 8033876: d123 bne.n 80338c0 8033878: e004 b.n 8033884 803387a: 2b43 cmp r3, #67 ; 0x43 803387c: d90a bls.n 8033894 803387e: 2b44 cmp r3, #68 ; 0x44 8033880: d11e bne.n 80338c0 8033882: e00f b.n 80338a4 { case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG): sint_ptr = (s32_t*)vb->value; snmp_asn1_enc_s32t(p, ofs, vb->vlen, *sint_ptr); 8033884: 6963 ldr r3, [r4, #20] 8033886: 8c22 ldrh r2, [r4, #32] 8033888: 681b ldr r3, [r3, #0] 803388a: 4628 mov r0, r5 803388c: 4631 mov r1, r6 803388e: f7fc ffc9 bl 8030824 break; 8033892: e015 b.n 80338c0 case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_COUNTER): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_GAUGE): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS): uint_ptr = (u32_t*)vb->value; snmp_asn1_enc_u32t(p, ofs, vb->vlen, *uint_ptr); 8033894: 6963 ldr r3, [r4, #20] 8033896: 8c22 ldrh r2, [r4, #32] 8033898: 681b ldr r3, [r3, #0] 803389a: 4628 mov r0, r5 803389c: 4631 mov r1, r6 803389e: f7fc ff81 bl 80307a4 break; 80338a2: e00d b.n 80338c0 case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR): case (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_OPAQUE): raw_ptr = (u8_t*)vb->value; snmp_asn1_enc_raw(p, ofs, vb->vlen, raw_ptr); 80338a4: 4628 mov r0, r5 80338a6: 4631 mov r1, r6 80338a8: 8c22 ldrh r2, [r4, #32] 80338aa: 6963 ldr r3, [r4, #20] 80338ac: f7fd f85a bl 8030964 break; 80338b0: e006 b.n 80338c0 case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_NUL): break; case (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID): sint_ptr = (s32_t*)vb->value; snmp_asn1_enc_oid(p, ofs, vb->value_len / sizeof(s32_t), sint_ptr); 80338b2: 7c62 ldrb r2, [r4, #17] 80338b4: 6963 ldr r3, [r4, #20] 80338b6: 4628 mov r0, r5 80338b8: 4631 mov r1, r6 80338ba: 0892 lsrs r2, r2, #2 80338bc: f7fc ffdf bl 803087e break; default: /* unsupported type */ break; }; ofs += vb->vlen; 80338c0: 8c23 ldrh r3, [r4, #32] vb = vb->next; 80338c2: 6824 ldr r4, [r4, #0] break; default: /* unsupported type */ break; }; ofs += vb->vlen; 80338c4: 18f6 adds r6, r6, r3 80338c6: b2b6 uxth r6, r6 ofs += 1; snmp_asn1_enc_length(p, ofs, root->seqlen); ofs += root->seqlenlen; vb = root->head; while ( vb != NULL ) 80338c8: 2c00 cmp r4, #0 80338ca: d195 bne.n 80337f8 }; ofs += vb->vlen; vb = vb->next; } return ofs; } 80338cc: 4630 mov r0, r6 80338ce: bd70 pop {r4, r5, r6, pc} 080338d0 : * @param dst IPv4 address in host order. */ void snmp_trap_dst_ip_set(u8_t dst_idx, ip_addr_t *dst) { if (dst_idx < SNMP_TRAP_DESTINATIONS) 80338d0: b918 cbnz r0, 80338da { ip_addr_set(&trap_dst[dst_idx].dip, dst); 80338d2: b101 cbz r1, 80338d6 80338d4: 6809 ldr r1, [r1, #0] 80338d6: 4b01 ldr r3, [pc, #4] ; (80338dc ) 80338d8: 6019 str r1, [r3, #0] 80338da: 4770 bx lr 80338dc: 20011140 .word 0x20011140 080338e0 : * @note the caller is responsible for filling in outvb in the m_stat * and provide error-status and index (except for tooBig errors) ... */ err_t snmp_send_response(struct snmp_msg_pstat *m_stat) { 80338e0: b5f0 push {r4, r5, r6, r7, lr} 80338e2: 4604 mov r4, r0 80338e4: b085 sub sp, #20 struct snmp_varbind_root emptyvb = {NULL, NULL, 0, 0, 0}; 80338e6: 220c movs r2, #12 80338e8: 2100 movs r1, #0 80338ea: a801 add r0, sp, #4 struct pbuf *p; u16_t tot_len; err_t err; /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&m_stat->outvb); 80338ec: f504 7686 add.w r6, r4, #268 ; 0x10c * and provide error-status and index (except for tooBig errors) ... */ err_t snmp_send_response(struct snmp_msg_pstat *m_stat) { struct snmp_varbind_root emptyvb = {NULL, NULL, 0, 0, 0}; 80338f0: f7ee f8e6 bl 8021ac0 struct pbuf *p; u16_t tot_len; err_t err; /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&m_stat->outvb); 80338f4: 4630 mov r0, r6 80338f6: f7ff fe8f bl 8033618 80338fa: 4601 mov r1, r0 tot_len = snmp_resp_header_sum(m_stat, tot_len); 80338fc: 4620 mov r0, r4 80338fe: f7ff fef1 bl 80336e4 /* try allocating pbuf(s) for complete response */ p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_POOL); 8033902: 2203 movs r2, #3 u16_t tot_len; err_t err; /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&m_stat->outvb); tot_len = snmp_resp_header_sum(m_stat, tot_len); 8033904: 4601 mov r1, r0 /* try allocating pbuf(s) for complete response */ p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_POOL); 8033906: 2000 movs r0, #0 8033908: f7f9 fbdf bl 802d0ca if (p == NULL) 803390c: 4605 mov r5, r0 803390e: b990 cbnz r0, 8033936 { LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_snd_response() tooBig\n")); /* can't construct reply, return error-status tooBig */ m_stat->error_status = SNMP_ES_TOOBIG; 8033910: 2301 movs r3, #1 8033912: 6123 str r3, [r4, #16] m_stat->error_index = 0; 8033914: 6160 str r0, [r4, #20] /* pass 0, recalculate lengths, for empty varbind-list */ tot_len = snmp_varbind_list_sum(&emptyvb); 8033916: a801 add r0, sp, #4 8033918: f7ff fe7e bl 8033618 803391c: 4601 mov r1, r0 tot_len = snmp_resp_header_sum(m_stat, tot_len); 803391e: 4620 mov r0, r4 8033920: f7ff fee0 bl 80336e4 /* retry allocation once for header and empty varbind-list */ p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_POOL); 8033924: 2203 movs r2, #3 /* can't construct reply, return error-status tooBig */ m_stat->error_status = SNMP_ES_TOOBIG; m_stat->error_index = 0; /* pass 0, recalculate lengths, for empty varbind-list */ tot_len = snmp_varbind_list_sum(&emptyvb); tot_len = snmp_resp_header_sum(m_stat, tot_len); 8033926: 4601 mov r1, r0 /* retry allocation once for header and empty varbind-list */ p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_POOL); 8033928: 4628 mov r0, r5 803392a: f7f9 fbce bl 802d0ca } if (p != NULL) 803392e: 4605 mov r5, r0 8033930: 2800 cmp r0, #0 8033932: f000 80dc beq.w 8033aee snmp_resp_header_enc(struct snmp_msg_pstat *m_stat, struct pbuf *p) { u16_t ofs; ofs = 0; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 8033936: 2100 movs r1, #0 8033938: 2230 movs r2, #48 ; 0x30 803393a: 4628 mov r0, r5 803393c: f7fc fed6 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.seqlen); 8033940: 2101 movs r1, #1 8033942: f8b4 212c ldrh.w r2, [r4, #300] ; 0x12c 8033946: 4628 mov r0, r5 8033948: f7fc fee4 bl 8030714 ofs += m_stat->rhl.seqlenlen; 803394c: f894 711e ldrb.w r7, [r4, #286] ; 0x11e snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033950: 2202 movs r2, #2 8033952: 1c79 adds r1, r7, #1 8033954: 4628 mov r0, r5 ofs += 1; 8033956: 3702 adds r7, #2 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.seqlen); ofs += m_stat->rhl.seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033958: f7fc fec8 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.verlen); 803395c: 4639 mov r1, r7 803395e: f8b4 212a ldrh.w r2, [r4, #298] ; 0x12a 8033962: 4628 mov r0, r5 8033964: f7fc fed6 bl 8030714 ofs += m_stat->rhl.verlenlen; 8033968: f894 311d ldrb.w r3, [r4, #285] ; 0x11d snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.verlen, snmp_version); 803396c: f8b4 212a ldrh.w r2, [r4, #298] ; 0x12a ofs += m_stat->rhl.seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.verlen); ofs += m_stat->rhl.verlenlen; 8033970: 18ff adds r7, r7, r3 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.verlen, snmp_version); 8033972: 4b61 ldr r3, [pc, #388] ; (8033af8 ) 8033974: 4639 mov r1, r7 8033976: 681b ldr r3, [r3, #0] 8033978: 4628 mov r0, r5 803397a: f7fc ff53 bl 8030824 ofs += m_stat->rhl.verlen; 803397e: f8b4 312a ldrh.w r3, [r4, #298] ; 0x12a 8033982: 18ff adds r7, r7, r3 8033984: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 8033986: 4639 mov r1, r7 ofs += 1; 8033988: 3701 adds r7, #1 snmp_asn1_enc_length(p, ofs, m_stat->rhl.verlen); ofs += m_stat->rhl.verlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.verlen, snmp_version); ofs += m_stat->rhl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 803398a: 2204 movs r2, #4 ofs += 1; 803398c: b2bf uxth r7, r7 snmp_asn1_enc_length(p, ofs, m_stat->rhl.verlen); ofs += m_stat->rhl.verlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.verlen, snmp_version); ofs += m_stat->rhl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 803398e: 4628 mov r0, r5 8033990: f7fc feac bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.comlen); 8033994: 4639 mov r1, r7 8033996: f8b4 2128 ldrh.w r2, [r4, #296] ; 0x128 803399a: 4628 mov r0, r5 803399c: f7fc feba bl 8030714 ofs += m_stat->rhl.comlenlen; 80339a0: f894 311c ldrb.w r3, [r4, #284] ; 0x11c snmp_asn1_enc_raw(p, ofs, m_stat->rhl.comlen, m_stat->community); 80339a4: f8b4 2128 ldrh.w r2, [r4, #296] ; 0x128 ofs += m_stat->rhl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.comlen); ofs += m_stat->rhl.comlenlen; 80339a8: 18ff adds r7, r7, r3 80339aa: b2bf uxth r7, r7 snmp_asn1_enc_raw(p, ofs, m_stat->rhl.comlen, m_stat->community); 80339ac: 4639 mov r1, r7 80339ae: f104 0318 add.w r3, r4, #24 80339b2: 4628 mov r0, r5 80339b4: f7fc ffd6 bl 8030964 ofs += m_stat->rhl.comlen; 80339b8: f8b4 3128 ldrh.w r3, [r4, #296] ; 0x128 80339bc: 18ff adds r7, r7, r3 80339be: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP)); 80339c0: 4639 mov r1, r7 ofs += 1; 80339c2: 3701 adds r7, #1 snmp_asn1_enc_length(p, ofs, m_stat->rhl.comlen); ofs += m_stat->rhl.comlenlen; snmp_asn1_enc_raw(p, ofs, m_stat->rhl.comlen, m_stat->community); ofs += m_stat->rhl.comlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP)); 80339c4: 22a2 movs r2, #162 ; 0xa2 ofs += 1; 80339c6: b2bf uxth r7, r7 snmp_asn1_enc_length(p, ofs, m_stat->rhl.comlen); ofs += m_stat->rhl.comlenlen; snmp_asn1_enc_raw(p, ofs, m_stat->rhl.comlen, m_stat->community); ofs += m_stat->rhl.comlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP)); 80339c8: 4628 mov r0, r5 80339ca: f7fc fe8f bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.pdulen); 80339ce: 4639 mov r1, r7 80339d0: f8b4 2126 ldrh.w r2, [r4, #294] ; 0x126 80339d4: 4628 mov r0, r5 80339d6: f7fc fe9d bl 8030714 ofs += m_stat->rhl.pdulenlen; 80339da: f894 311b ldrb.w r3, [r4, #283] ; 0x11b 80339de: 18ff adds r7, r7, r3 80339e0: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 80339e2: 4639 mov r1, r7 ofs += 1; 80339e4: 3701 adds r7, #1 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.pdulen); ofs += m_stat->rhl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 80339e6: 2202 movs r2, #2 ofs += 1; 80339e8: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_GET_RESP)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.pdulen); ofs += m_stat->rhl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 80339ea: 4628 mov r0, r5 80339ec: f7fc fe7e bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.ridlen); 80339f0: 4639 mov r1, r7 80339f2: f8b4 2124 ldrh.w r2, [r4, #292] ; 0x124 80339f6: 4628 mov r0, r5 80339f8: f7fc fe8c bl 8030714 ofs += m_stat->rhl.ridlenlen; 80339fc: f894 311a ldrb.w r3, [r4, #282] ; 0x11a snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.ridlen, m_stat->rid); 8033a00: f8b4 2124 ldrh.w r2, [r4, #292] ; 0x124 ofs += m_stat->rhl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.ridlen); ofs += m_stat->rhl.ridlenlen; 8033a04: 18ff adds r7, r7, r3 8033a06: b2bf uxth r7, r7 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.ridlen, m_stat->rid); 8033a08: 4639 mov r1, r7 8033a0a: 68e3 ldr r3, [r4, #12] 8033a0c: 4628 mov r0, r5 8033a0e: f7fc ff09 bl 8030824 ofs += m_stat->rhl.ridlen; 8033a12: f8b4 3124 ldrh.w r3, [r4, #292] ; 0x124 8033a16: 18ff adds r7, r7, r3 8033a18: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a1a: 4639 mov r1, r7 ofs += 1; 8033a1c: 3701 adds r7, #1 snmp_asn1_enc_length(p, ofs, m_stat->rhl.ridlen); ofs += m_stat->rhl.ridlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.ridlen, m_stat->rid); ofs += m_stat->rhl.ridlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a1e: 2202 movs r2, #2 ofs += 1; 8033a20: b2bf uxth r7, r7 snmp_asn1_enc_length(p, ofs, m_stat->rhl.ridlen); ofs += m_stat->rhl.ridlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.ridlen, m_stat->rid); ofs += m_stat->rhl.ridlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a22: 4628 mov r0, r5 8033a24: f7fc fe62 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.errstatlen); 8033a28: 4639 mov r1, r7 8033a2a: f8b4 2122 ldrh.w r2, [r4, #290] ; 0x122 8033a2e: 4628 mov r0, r5 8033a30: f7fc fe70 bl 8030714 ofs += m_stat->rhl.errstatlenlen; 8033a34: f894 3119 ldrb.w r3, [r4, #281] ; 0x119 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.errstatlen, m_stat->error_status); 8033a38: f8b4 2122 ldrh.w r2, [r4, #290] ; 0x122 ofs += m_stat->rhl.ridlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.errstatlen); ofs += m_stat->rhl.errstatlenlen; 8033a3c: 18ff adds r7, r7, r3 8033a3e: b2bf uxth r7, r7 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.errstatlen, m_stat->error_status); 8033a40: 4639 mov r1, r7 8033a42: 6923 ldr r3, [r4, #16] 8033a44: 4628 mov r0, r5 8033a46: f7fc feed bl 8030824 ofs += m_stat->rhl.errstatlen; 8033a4a: f8b4 3122 ldrh.w r3, [r4, #290] ; 0x122 8033a4e: 18ff adds r7, r7, r3 8033a50: b2bf uxth r7, r7 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a52: 4639 mov r1, r7 ofs += 1; 8033a54: 3701 adds r7, #1 snmp_asn1_enc_length(p, ofs, m_stat->rhl.errstatlen); ofs += m_stat->rhl.errstatlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.errstatlen, m_stat->error_status); ofs += m_stat->rhl.errstatlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a56: 2202 movs r2, #2 ofs += 1; 8033a58: b2bf uxth r7, r7 snmp_asn1_enc_length(p, ofs, m_stat->rhl.errstatlen); ofs += m_stat->rhl.errstatlenlen; snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.errstatlen, m_stat->error_status); ofs += m_stat->rhl.errstatlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033a5a: 4628 mov r0, r5 8033a5c: f7fc fe46 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.erridxlen); 8033a60: 4639 mov r1, r7 8033a62: f8b4 2120 ldrh.w r2, [r4, #288] ; 0x120 8033a66: 4628 mov r0, r5 8033a68: f7fc fe54 bl 8030714 ofs += m_stat->rhl.erridxlenlen; 8033a6c: f894 3118 ldrb.w r3, [r4, #280] ; 0x118 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.erridxlen, m_stat->error_index); 8033a70: f8b4 2120 ldrh.w r2, [r4, #288] ; 0x120 ofs += m_stat->rhl.errstatlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_stat->rhl.erridxlen); ofs += m_stat->rhl.erridxlenlen; 8033a74: 18ff adds r7, r7, r3 8033a76: b2bf uxth r7, r7 snmp_asn1_enc_s32t(p, ofs, m_stat->rhl.erridxlen, m_stat->error_index); 8033a78: 4639 mov r1, r7 8033a7a: 6963 ldr r3, [r4, #20] 8033a7c: 4628 mov r0, r5 8033a7e: f7fc fed1 bl 8030824 ofs += m_stat->rhl.erridxlen; 8033a82: f8b4 3120 ldrh.w r3, [r4, #288] ; 0x120 8033a86: 18fa adds r2, r7, r3 LWIP_DEBUGF(SNMP_MSG_DEBUG, ("snmp_snd_response() p != NULL\n")); /* pass 1, size error, encode packet ino the pbuf(s) */ ofs = snmp_resp_header_enc(m_stat, p); snmp_varbind_list_enc(&m_stat->outvb, p, ofs); 8033a88: 4630 mov r0, r6 8033a8a: 4629 mov r1, r5 8033a8c: b292 uxth r2, r2 8033a8e: f7ff fea1 bl 80337d4 switch (m_stat->error_status) 8033a92: 6923 ldr r3, [r4, #16] 8033a94: 3b01 subs r3, #1 8033a96: 2b04 cmp r3, #4 8033a98: d80f bhi.n 8033aba 8033a9a: e8df f003 tbb [pc, r3] 8033a9e: 0603 .short 0x0603 8033aa0: 0e09 .short 0x0e09 8033aa2: 0c .byte 0x0c 8033aa3: 00 .byte 0x00 { case SNMP_ES_TOOBIG: snmp_inc_snmpouttoobigs(); 8033aa4: f7fe fa12 bl 8031ecc break; 8033aa8: e007 b.n 8033aba case SNMP_ES_NOSUCHNAME: snmp_inc_snmpoutnosuchnames(); 8033aaa: f7fe fa17 bl 8031edc break; 8033aae: e004 b.n 8033aba case SNMP_ES_BADVALUE: snmp_inc_snmpoutbadvalues(); 8033ab0: f7fe fa1c bl 8031eec break; 8033ab4: e001 b.n 8033aba case SNMP_ES_GENERROR: snmp_inc_snmpoutgenerrs(); 8033ab6: f7fe fa21 bl 8031efc break; } snmp_inc_snmpoutgetresponses(); 8033aba: f7fe fa27 bl 8031f0c snmp_inc_snmpoutpkts(); 8033abe: f7fe f985 bl 8031dcc /** @todo do we need separate rx and tx pcbs for threaded case? */ /** connect to the originating source */ udp_connect(m_stat->pcb, &m_stat->sip, m_stat->sp); 8033ac2: 8922 ldrh r2, [r4, #8] 8033ac4: 6820 ldr r0, [r4, #0] 8033ac6: 1d21 adds r1, r4, #4 8033ac8: f7fb ffcc bl 802fa64 err = udp_send(m_stat->pcb, p); 8033acc: 4629 mov r1, r5 8033ace: 6820 ldr r0, [r4, #0] 8033ad0: f7fb ffc3 bl 802fa5a /** @todo release some memory, retry and return tooBig? tooMuchHassle? */ err = ERR_MEM; } else { err = ERR_OK; 8033ad4: f1b0 3fff cmp.w r0, #4294967295 8033ad8: bf0c ite eq 8033ada: f04f 36ff moveq.w r6, #4294967295 8033ade: 2600 movne r6, #0 } /** disassociate remote address and port with this pcb */ udp_disconnect(m_stat->pcb); 8033ae0: 6820 ldr r0, [r4, #0] 8033ae2: f7fb ffe5 bl 802fab0 pbuf_free(p); 8033ae6: 4628 mov r0, r5 8033ae8: f7f9 faa2 bl 802d030 8033aec: e000 b.n 8033af0 } else { /* first pbuf alloc try or retry alloc failed very low on memory, couldn't return tooBig */ return ERR_MEM; 8033aee: 26ff movs r6, #255 ; 0xff } } 8033af0: b270 sxtb r0, r6 8033af2: b005 add sp, #20 8033af4: bdf0 pop {r4, r5, r6, r7, pc} 8033af6: bf00 nop 8033af8: 080407ac .word 0x080407ac 08033afc : * and .iso.org.dod.internet.private.enterprises.yourenterprise * (sysObjectID) for specific traps. */ err_t snmp_send_trap(s8_t generic_trap, struct snmp_obj_id *eoid, s32_t specific_trap) { 8033afc: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} struct pbuf *p; u16_t i,tot_len; for (i=0, td = &trap_dst[0]; ienable != 0) && !ip_addr_isany(&td->dip)) 8033b00: 4b11 ldr r3, [pc, #68] ; (8033b48 ) * and .iso.org.dod.internet.private.enterprises.yourenterprise * (sysObjectID) for specific traps. */ err_t snmp_send_trap(s8_t generic_trap, struct snmp_obj_id *eoid, s32_t specific_trap) { 8033b02: 4617 mov r7, r2 struct pbuf *p; u16_t i,tot_len; for (i=0, td = &trap_dst[0]; ienable != 0) && !ip_addr_isany(&td->dip)) 8033b04: 791a ldrb r2, [r3, #4] * and .iso.org.dod.internet.private.enterprises.yourenterprise * (sysObjectID) for specific traps. */ err_t snmp_send_trap(s8_t generic_trap, struct snmp_obj_id *eoid, s32_t specific_trap) { 8033b06: b085 sub sp, #20 8033b08: 4605 mov r5, r0 8033b0a: 460e mov r6, r1 struct pbuf *p; u16_t i,tot_len; for (i=0, td = &trap_dst[0]; ienable != 0) && !ip_addr_isany(&td->dip)) 8033b0c: 2a00 cmp r2, #0 8033b0e: f000 81b8 beq.w 8033e82 8033b12: 6818 ldr r0, [r3, #0] 8033b14: 2800 cmp r0, #0 8033b16: f000 81b4 beq.w 8033e82 { /* network order trap destination */ ip_addr_copy(trap_msg.dip, td->dip); 8033b1a: 4c0c ldr r4, [pc, #48] ; (8033b4c ) 8033b1c: 6060 str r0, [r4, #4] /* lookup current source address for this dst */ dst_if = ip_route(&td->dip); 8033b1e: 4618 mov r0, r3 8033b20: f7fc fa10 bl 802ff44 ip_addr_copy(dst_ip, dst_if->ip_addr); 8033b24: 6843 ldr r3, [r0, #4] /* @todo: what about IPv6? */ trap_msg.sip_raw[0] = ip4_addr1(&dst_ip); trap_msg.sip_raw[1] = ip4_addr2(&dst_ip); trap_msg.sip_raw[2] = ip4_addr3(&dst_ip); trap_msg.sip_raw[3] = ip4_addr4(&dst_ip); trap_msg.gen_trap = generic_trap; 8033b26: 6125 str r5, [r4, #16] /* lookup current source address for this dst */ dst_if = ip_route(&td->dip); ip_addr_copy(dst_ip, dst_if->ip_addr); /* @todo: what about IPv6? */ trap_msg.sip_raw[0] = ip4_addr1(&dst_ip); trap_msg.sip_raw[1] = ip4_addr2(&dst_ip); 8033b28: f3c3 2207 ubfx r2, r3, #8, #8 ip_addr_copy(trap_msg.dip, td->dip); /* lookup current source address for this dst */ dst_if = ip_route(&td->dip); ip_addr_copy(dst_ip, dst_if->ip_addr); /* @todo: what about IPv6? */ trap_msg.sip_raw[0] = ip4_addr1(&dst_ip); 8033b2c: 7323 strb r3, [r4, #12] trap_msg.sip_raw[1] = ip4_addr2(&dst_ip); 8033b2e: 7362 strb r2, [r4, #13] trap_msg.sip_raw[2] = ip4_addr3(&dst_ip); trap_msg.sip_raw[3] = ip4_addr4(&dst_ip); trap_msg.gen_trap = generic_trap; trap_msg.spc_trap = specific_trap; if (generic_trap == SNMP_GENTRAP_ENTERPRISESPC) 8033b30: 2d06 cmp r5, #6 dst_if = ip_route(&td->dip); ip_addr_copy(dst_ip, dst_if->ip_addr); /* @todo: what about IPv6? */ trap_msg.sip_raw[0] = ip4_addr1(&dst_ip); trap_msg.sip_raw[1] = ip4_addr2(&dst_ip); trap_msg.sip_raw[2] = ip4_addr3(&dst_ip); 8033b32: f3c3 4207 ubfx r2, r3, #16, #8 trap_msg.sip_raw[3] = ip4_addr4(&dst_ip); 8033b36: f3c3 6307 ubfx r3, r3, #24, #8 dst_if = ip_route(&td->dip); ip_addr_copy(dst_ip, dst_if->ip_addr); /* @todo: what about IPv6? */ trap_msg.sip_raw[0] = ip4_addr1(&dst_ip); trap_msg.sip_raw[1] = ip4_addr2(&dst_ip); trap_msg.sip_raw[2] = ip4_addr3(&dst_ip); 8033b3a: 73a2 strb r2, [r4, #14] trap_msg.sip_raw[3] = ip4_addr4(&dst_ip); 8033b3c: 73e3 strb r3, [r4, #15] trap_msg.gen_trap = generic_trap; trap_msg.spc_trap = specific_trap; 8033b3e: 6167 str r7, [r4, #20] if (generic_trap == SNMP_GENTRAP_ENTERPRISESPC) 8033b40: d106 bne.n 8033b50 { /* enterprise-Specific trap */ trap_msg.enterprise = eoid; 8033b42: 60a6 str r6, [r4, #8] 8033b44: e008 b.n 8033b58 8033b46: bf00 nop 8033b48: 20011140 .word 0x20011140 8033b4c: 20011148 .word 0x20011148 } else { /* generic (MIB-II) trap */ snmp_get_snmpgrpid_ptr(&trap_msg.enterprise); 8033b50: f104 0008 add.w r0, r4, #8 8033b54: f7fe f9ea bl 8031f2c } snmp_get_sysuptime(&trap_msg.ts); 8033b58: 48bb ldr r0, [pc, #748] ; (8033e48 ) struct snmp_trap_header_lengths *thl; thl = &m_trap->thl; tot_len = vb_len; snmp_asn1_enc_u32t_cnt(m_trap->ts, &thl->tslen); 8033b5a: 4cbc ldr r4, [pc, #752] ; (8033e4c ) else { /* generic (MIB-II) trap */ snmp_get_snmpgrpid_ptr(&trap_msg.enterprise); } snmp_get_sysuptime(&trap_msg.ts); 8033b5c: f7fd fd5a bl 8031614 /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&trap_msg.outvb); 8033b60: 48bb ldr r0, [pc, #748] ; (8033e50 ) 8033b62: f7ff fd59 bl 8033618 struct snmp_trap_header_lengths *thl; thl = &m_trap->thl; tot_len = vb_len; snmp_asn1_enc_u32t_cnt(m_trap->ts, &thl->tslen); 8033b66: f104 0132 add.w r1, r4, #50 ; 0x32 snmp_get_snmpgrpid_ptr(&trap_msg.enterprise); } snmp_get_sysuptime(&trap_msg.ts); /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&trap_msg.outvb); 8033b6a: 4606 mov r6, r0 struct snmp_trap_header_lengths *thl; thl = &m_trap->thl; tot_len = vb_len; snmp_asn1_enc_u32t_cnt(m_trap->ts, &thl->tslen); 8033b6c: 69a0 ldr r0, [r4, #24] 8033b6e: f7fc fd7b bl 8030668 snmp_asn1_enc_length_cnt(thl->tslen, &thl->tslenlen); 8033b72: 8e60 ldrh r0, [r4, #50] ; 0x32 8033b74: f104 0128 add.w r1, r4, #40 ; 0x28 8033b78: f7fc fd6b bl 8030652 tot_len += 1 + thl->tslen + thl->tslenlen; 8033b7c: f8b4 c032 ldrh.w ip, [r4, #50] ; 0x32 snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); 8033b80: 6960 ldr r0, [r4, #20] 8033b82: f8cd c004 str.w ip, [sp, #4] 8033b86: f104 0134 add.w r1, r4, #52 ; 0x34 thl = &m_trap->thl; tot_len = vb_len; snmp_asn1_enc_u32t_cnt(m_trap->ts, &thl->tslen); snmp_asn1_enc_length_cnt(thl->tslen, &thl->tslenlen); tot_len += 1 + thl->tslen + thl->tslenlen; 8033b8a: f894 9028 ldrb.w r9, [r4, #40] ; 0x28 snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); 8033b8e: f7fc fd80 bl 8030692 snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); 8033b92: 8ea0 ldrh r0, [r4, #52] ; 0x34 8033b94: f104 0129 add.w r1, r4, #41 ; 0x29 8033b98: f7fc fd5b bl 8030652 tot_len += 1 + thl->strplen + thl->strplenlen; 8033b9c: 8ea3 ldrh r3, [r4, #52] ; 0x34 snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); 8033b9e: 6920 ldr r0, [r4, #16] 8033ba0: 9302 str r3, [sp, #8] 8033ba2: f104 0136 add.w r1, r4, #54 ; 0x36 snmp_asn1_enc_length_cnt(thl->tslen, &thl->tslenlen); tot_len += 1 + thl->tslen + thl->tslenlen; snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); tot_len += 1 + thl->strplen + thl->strplenlen; 8033ba6: f894 8029 ldrb.w r8, [r4, #41] ; 0x29 snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; thl->aaddrlen = 4; 8033baa: 2504 movs r5, #4 snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); tot_len += 1 + thl->strplen + thl->strplenlen; snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); 8033bac: f7fc fd71 bl 8030692 snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); 8033bb0: 8ee0 ldrh r0, [r4, #54] ; 0x36 8033bb2: f104 012a add.w r1, r4, #42 ; 0x2a 8033bb6: f7fc fd4c bl 8030652 tot_len += 1 + thl->gtrplen + thl->gtrplenlen; thl->aaddrlen = 4; snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); 8033bba: 4628 mov r0, r5 8033bbc: f104 012b add.w r1, r4, #43 ; 0x2b snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); tot_len += 1 + thl->strplen + thl->strplenlen; snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; 8033bc0: f8b4 b036 ldrh.w fp, [r4, #54] ; 0x36 8033bc4: f894 702a ldrb.w r7, [r4, #42] ; 0x2a thl->aaddrlen = 4; 8033bc8: 8725 strh r5, [r4, #56] ; 0x38 snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); 8033bca: f7fc fd42 bl 8030652 tot_len += 1 + thl->aaddrlen + thl->aaddrlenlen; 8033bce: f894 202b ldrb.w r2, [r4, #43] ; 0x2b snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); 8033bd2: 68a1 ldr r1, [r4, #8] snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; thl->aaddrlen = 4; snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); tot_len += 1 + thl->aaddrlen + thl->aaddrlenlen; 8033bd4: 9203 str r2, [sp, #12] snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); 8033bd6: f811 0b04 ldrb.w r0, [r1], #4 snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; thl->aaddrlen = 4; snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); tot_len += 1 + thl->aaddrlen + thl->aaddrlenlen; 8033bda: f8b4 a038 ldrh.w sl, [r4, #56] ; 0x38 snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); 8033bde: f104 023a add.w r2, r4, #58 ; 0x3a 8033be2: f7fc fd6b bl 80306bc snmp_asn1_enc_length_cnt(thl->eidlen, &thl->eidlenlen); 8033be6: 8f60 ldrh r0, [r4, #58] ; 0x3a 8033be8: f104 012c add.w r1, r4, #44 ; 0x2c 8033bec: f7fc fd31 bl 8030652 snmp_asn1_enc_length_cnt(thl->tslen, &thl->tslenlen); tot_len += 1 + thl->tslen + thl->tslenlen; snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); tot_len += 1 + thl->strplen + thl->strplenlen; 8033bf0: f8dd c004 ldr.w ip, [sp, #4] 8033bf4: 9b02 ldr r3, [sp, #8] snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; 8033bf6: 8f62 ldrh r2, [r4, #58] ; 0x3a snmp_asn1_enc_length_cnt(thl->tslen, &thl->tslenlen); tot_len += 1 + thl->tslen + thl->tslenlen; snmp_asn1_enc_s32t_cnt(m_trap->spc_trap, &thl->strplen); snmp_asn1_enc_length_cnt(thl->strplen, &thl->strplenlen); tot_len += 1 + thl->strplen + thl->strplenlen; 8033bf8: 4463 add r3, ip 8033bfa: 3305 adds r3, #5 snmp_asn1_enc_s32t_cnt(m_trap->gen_trap, &thl->gtrplen); snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; 8033bfc: 449b add fp, r3 8033bfe: 44da add sl, fp 8033c00: fa12 fa8a uxtah sl, r2, sl thl->aaddrlen = 4; snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); tot_len += 1 + thl->aaddrlen + thl->aaddrlenlen; 8033c04: 44d1 add r9, sl 8033c06: 44c8 add r8, r9 snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); snmp_asn1_enc_length_cnt(thl->eidlen, &thl->eidlenlen); tot_len += 1 + thl->eidlen + thl->eidlenlen; 8033c08: 9b03 ldr r3, [sp, #12] snmp_asn1_enc_length_cnt(thl->gtrplen, &thl->gtrplenlen); tot_len += 1 + thl->gtrplen + thl->gtrplenlen; thl->aaddrlen = 4; snmp_asn1_enc_length_cnt(thl->aaddrlen, &thl->aaddrlenlen); tot_len += 1 + thl->aaddrlen + thl->aaddrlenlen; 8033c0a: fa17 f788 uxtah r7, r7, r8 snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); snmp_asn1_enc_length_cnt(thl->eidlen, &thl->eidlenlen); tot_len += 1 + thl->eidlen + thl->eidlenlen; 8033c0e: 19df adds r7, r3, r7 8033c10: f894 302c ldrb.w r3, [r4, #44] ; 0x2c 8033c14: 18ff adds r7, r7, r3 8033c16: fa16 f687 uxtah r6, r6, r7 8033c1a: b2b6 uxth r6, r6 thl->pdulen = tot_len; snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); 8033c1c: 4630 mov r0, r6 8033c1e: f104 012d add.w r1, r4, #45 ; 0x2d tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; 8033c22: 2706 movs r7, #6 snmp_asn1_enc_oid_cnt(m_trap->enterprise->len, &m_trap->enterprise->id[0], &thl->eidlen); snmp_asn1_enc_length_cnt(thl->eidlen, &thl->eidlenlen); tot_len += 1 + thl->eidlen + thl->eidlenlen; thl->pdulen = tot_len; 8033c24: 87a6 strh r6, [r4, #60] ; 0x3c snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); 8033c26: f7fc fd14 bl 8030652 tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); 8033c2a: 4638 mov r0, r7 8033c2c: f104 012e add.w r1, r4, #46 ; 0x2e snmp_asn1_enc_length_cnt(thl->eidlen, &thl->eidlenlen); tot_len += 1 + thl->eidlen + thl->eidlenlen; thl->pdulen = tot_len; snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); tot_len += 1 + thl->pdulenlen; 8033c30: f894 a02d ldrb.w sl, [r4, #45] ; 0x2d thl->comlen = sizeof(snmp_publiccommunity) - 1; 8033c34: 87e7 strh r7, [r4, #62] ; 0x3e snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); 8033c36: f7fc fd0c bl 8030652 tot_len += 1 + thl->comlenlen + thl->comlen; snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); 8033c3a: 4b86 ldr r3, [pc, #536] ; (8033e54 ) snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); tot_len += 1 + thl->comlenlen + thl->comlen; 8033c3c: f894 902e ldrb.w r9, [r4, #46] ; 0x2e snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); 8033c40: f8d3 8000 ldr.w r8, [r3] snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); tot_len += 1 + thl->comlenlen + thl->comlen; 8033c44: f8b4 b03e ldrh.w fp, [r4, #62] ; 0x3e snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); 8033c48: 4640 mov r0, r8 8033c4a: f104 0140 add.w r1, r4, #64 ; 0x40 8033c4e: f7fc fd20 bl 8030692 snmp_asn1_enc_length_cnt(thl->verlen, &thl->verlenlen); 8033c52: f8b4 0040 ldrh.w r0, [r4, #64] ; 0x40 8033c56: f104 012f add.w r1, r4, #47 ; 0x2f 8033c5a: f7fc fcfa bl 8030652 snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); tot_len += 1 + thl->comlenlen + thl->comlen; 8033c5e: f8b4 3040 ldrh.w r3, [r4, #64] ; 0x40 8033c62: 449b add fp, r3 8033c64: f10b 0b03 add.w fp, fp, #3 snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); snmp_asn1_enc_length_cnt(thl->verlen, &thl->verlenlen); tot_len += 1 + thl->verlen + thl->verlenlen; 8033c68: f894 302f ldrb.w r3, [r4, #47] ; 0x2f snmp_asn1_enc_length_cnt(thl->pdulen, &thl->pdulenlen); tot_len += 1 + thl->pdulenlen; thl->comlen = sizeof(snmp_publiccommunity) - 1; snmp_asn1_enc_length_cnt(thl->comlen, &thl->comlenlen); tot_len += 1 + thl->comlenlen + thl->comlen; 8033c6c: 44da add sl, fp snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); snmp_asn1_enc_length_cnt(thl->verlen, &thl->verlenlen); tot_len += 1 + thl->verlen + thl->verlenlen; 8033c6e: 44d1 add r9, sl 8033c70: 4499 add r9, r3 8033c72: fa16 f689 uxtah r6, r6, r9 8033c76: b2b6 uxth r6, r6 thl->seqlen = tot_len; snmp_asn1_enc_length_cnt(thl->seqlen, &thl->seqlenlen); 8033c78: 4630 mov r0, r6 8033c7a: f104 0130 add.w r1, r4, #48 ; 0x30 snmp_asn1_enc_s32t_cnt(snmp_version, &thl->verlen); snmp_asn1_enc_length_cnt(thl->verlen, &thl->verlenlen); tot_len += 1 + thl->verlen + thl->verlenlen; thl->seqlen = tot_len; 8033c7e: f8a4 6042 strh.w r6, [r4, #66] ; 0x42 snmp_asn1_enc_length_cnt(thl->seqlen, &thl->seqlenlen); 8033c82: f7fc fce6 bl 8030652 tot_len += 1 + thl->seqlenlen; 8033c86: f894 3030 ldrb.w r3, [r4, #48] ; 0x30 8033c8a: 3301 adds r3, #1 8033c8c: 18f1 adds r1, r6, r3 /* pass 0, calculate length fields */ tot_len = snmp_varbind_list_sum(&trap_msg.outvb); tot_len = snmp_trap_header_sum(&trap_msg, tot_len); /* allocate pbuf(s) */ p = pbuf_alloc(PBUF_TRANSPORT, tot_len, PBUF_POOL); 8033c8e: 2000 movs r0, #0 8033c90: b289 uxth r1, r1 8033c92: 2203 movs r2, #3 8033c94: f7f9 fa19 bl 802d0ca if (p != NULL) 8033c98: 4606 mov r6, r0 8033c9a: 2800 cmp r0, #0 8033c9c: f000 80f3 beq.w 8033e86 snmp_trap_header_enc(struct snmp_msg_trap *m_trap, struct pbuf *p) { u16_t ofs; ofs = 0; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); 8033ca0: 2100 movs r1, #0 8033ca2: 2230 movs r2, #48 ; 0x30 8033ca4: f7fc fd22 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.seqlen); 8033ca8: 2101 movs r1, #1 8033caa: f8b4 2042 ldrh.w r2, [r4, #66] ; 0x42 8033cae: 4630 mov r0, r6 8033cb0: f7fc fd30 bl 8030714 ofs += m_trap->thl.seqlenlen; 8033cb4: f894 9030 ldrb.w r9, [r4, #48] ; 0x30 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033cb8: 2202 movs r2, #2 8033cba: f109 0101 add.w r1, r9, #1 8033cbe: 4630 mov r0, r6 ofs += 1; 8033cc0: f109 0902 add.w r9, r9, #2 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_CONSTR | SNMP_ASN1_SEQ)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.seqlen); ofs += m_trap->thl.seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033cc4: f7fc fd12 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.verlen); 8033cc8: 4649 mov r1, r9 8033cca: f8b4 2040 ldrh.w r2, [r4, #64] ; 0x40 8033cce: 4630 mov r0, r6 8033cd0: f7fc fd20 bl 8030714 ofs += m_trap->thl.verlenlen; 8033cd4: f894 302f ldrb.w r3, [r4, #47] ; 0x2f snmp_asn1_enc_s32t(p, ofs, m_trap->thl.verlen, snmp_version); 8033cd8: f8b4 2040 ldrh.w r2, [r4, #64] ; 0x40 ofs += m_trap->thl.seqlenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.verlen); ofs += m_trap->thl.verlenlen; 8033cdc: 4499 add r9, r3 snmp_asn1_enc_s32t(p, ofs, m_trap->thl.verlen, snmp_version); 8033cde: 4649 mov r1, r9 8033ce0: 4643 mov r3, r8 8033ce2: 4630 mov r0, r6 8033ce4: f7fc fd9e bl 8030824 ofs += m_trap->thl.verlen; 8033ce8: f8b4 3040 ldrh.w r3, [r4, #64] ; 0x40 8033cec: 4499 add r9, r3 8033cee: fa1f f989 uxth.w r9, r9 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 8033cf2: 462a mov r2, r5 ofs += 1; 8033cf4: f109 0501 add.w r5, r9, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.verlen); ofs += m_trap->thl.verlenlen; snmp_asn1_enc_s32t(p, ofs, m_trap->thl.verlen, snmp_version); ofs += m_trap->thl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 8033cf8: 4649 mov r1, r9 ofs += 1; 8033cfa: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.verlen); ofs += m_trap->thl.verlenlen; snmp_asn1_enc_s32t(p, ofs, m_trap->thl.verlen, snmp_version); ofs += m_trap->thl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); 8033cfc: 4630 mov r0, r6 8033cfe: f7fc fcf5 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.comlen); 8033d02: 4629 mov r1, r5 8033d04: 8fe2 ldrh r2, [r4, #62] ; 0x3e 8033d06: 4630 mov r0, r6 8033d08: f7fc fd04 bl 8030714 ofs += m_trap->thl.comlenlen; 8033d0c: f894 302e ldrb.w r3, [r4, #46] ; 0x2e snmp_asn1_enc_raw(p, ofs, m_trap->thl.comlen, (u8_t *)&snmp_publiccommunity[0]); 8033d10: 8fe2 ldrh r2, [r4, #62] ; 0x3e ofs += m_trap->thl.verlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OC_STR)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.comlen); ofs += m_trap->thl.comlenlen; 8033d12: 18ed adds r5, r5, r3 8033d14: b2ad uxth r5, r5 snmp_asn1_enc_raw(p, ofs, m_trap->thl.comlen, (u8_t *)&snmp_publiccommunity[0]); 8033d16: 4629 mov r1, r5 8033d18: 4b4f ldr r3, [pc, #316] ; (8033e58 ) 8033d1a: 4630 mov r0, r6 8033d1c: f7fc fe22 bl 8030964 ofs += m_trap->thl.comlen; 8033d20: 8fe3 ldrh r3, [r4, #62] ; 0x3e 8033d22: 18ed adds r5, r5, r3 8033d24: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP)); 8033d26: 4629 mov r1, r5 ofs += 1; 8033d28: 3501 adds r5, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.comlen); ofs += m_trap->thl.comlenlen; snmp_asn1_enc_raw(p, ofs, m_trap->thl.comlen, (u8_t *)&snmp_publiccommunity[0]); ofs += m_trap->thl.comlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP)); 8033d2a: 22a4 movs r2, #164 ; 0xa4 ofs += 1; 8033d2c: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.comlen); ofs += m_trap->thl.comlenlen; snmp_asn1_enc_raw(p, ofs, m_trap->thl.comlen, (u8_t *)&snmp_publiccommunity[0]); ofs += m_trap->thl.comlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP)); 8033d2e: 4630 mov r0, r6 8033d30: f7fc fcdc bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.pdulen); 8033d34: 4629 mov r1, r5 8033d36: 8fa2 ldrh r2, [r4, #60] ; 0x3c 8033d38: 4630 mov r0, r6 8033d3a: f7fc fceb bl 8030714 ofs += m_trap->thl.pdulenlen; 8033d3e: f894 302d ldrb.w r3, [r4, #45] ; 0x2d 8033d42: 18ed adds r5, r5, r3 8033d44: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 8033d46: 4629 mov r1, r5 ofs += 1; 8033d48: 3501 adds r5, #1 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.pdulen); ofs += m_trap->thl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 8033d4a: 463a mov r2, r7 ofs += 1; 8033d4c: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_CONTXT | SNMP_ASN1_CONSTR | SNMP_ASN1_PDU_TRAP)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.pdulen); ofs += m_trap->thl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); 8033d4e: 4630 mov r0, r6 8033d50: f7fc fccc bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.eidlen); 8033d54: 4629 mov r1, r5 8033d56: 8f62 ldrh r2, [r4, #58] ; 0x3a 8033d58: 4630 mov r0, r6 8033d5a: f7fc fcdb bl 8030714 ofs += m_trap->thl.eidlenlen; 8033d5e: f894 302c ldrb.w r3, [r4, #44] ; 0x2c 8033d62: 18ed adds r5, r5, r3 snmp_asn1_enc_oid(p, ofs, m_trap->enterprise->len, &m_trap->enterprise->id[0]); 8033d64: 68a3 ldr r3, [r4, #8] ofs += m_trap->thl.pdulenlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_OBJ_ID)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.eidlen); ofs += m_trap->thl.eidlenlen; 8033d66: b2ad uxth r5, r5 snmp_asn1_enc_oid(p, ofs, m_trap->enterprise->len, &m_trap->enterprise->id[0]); 8033d68: 4629 mov r1, r5 8033d6a: f813 2b04 ldrb.w r2, [r3], #4 8033d6e: 4630 mov r0, r6 8033d70: f7fc fd85 bl 803087e ofs += m_trap->thl.eidlen; 8033d74: 8f63 ldrh r3, [r4, #58] ; 0x3a 8033d76: 18ed adds r5, r5, r3 8033d78: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR)); 8033d7a: 4629 mov r1, r5 ofs += 1; 8033d7c: 3501 adds r5, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.eidlen); ofs += m_trap->thl.eidlenlen; snmp_asn1_enc_oid(p, ofs, m_trap->enterprise->len, &m_trap->enterprise->id[0]); ofs += m_trap->thl.eidlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR)); 8033d7e: 2240 movs r2, #64 ; 0x40 ofs += 1; 8033d80: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.eidlen); ofs += m_trap->thl.eidlenlen; snmp_asn1_enc_oid(p, ofs, m_trap->enterprise->len, &m_trap->enterprise->id[0]); ofs += m_trap->thl.eidlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR)); 8033d82: 4630 mov r0, r6 8033d84: f7fc fcb2 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.aaddrlen); 8033d88: 4629 mov r1, r5 8033d8a: 8f22 ldrh r2, [r4, #56] ; 0x38 8033d8c: 4630 mov r0, r6 8033d8e: f7fc fcc1 bl 8030714 ofs += m_trap->thl.aaddrlenlen; 8033d92: f894 302b ldrb.w r3, [r4, #43] ; 0x2b snmp_asn1_enc_raw(p, ofs, m_trap->thl.aaddrlen, &m_trap->sip_raw[0]); 8033d96: 8f22 ldrh r2, [r4, #56] ; 0x38 ofs += m_trap->thl.eidlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_IPADDR)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.aaddrlen); ofs += m_trap->thl.aaddrlenlen; 8033d98: 18ed adds r5, r5, r3 8033d9a: b2ad uxth r5, r5 snmp_asn1_enc_raw(p, ofs, m_trap->thl.aaddrlen, &m_trap->sip_raw[0]); 8033d9c: 4629 mov r1, r5 8033d9e: f104 030c add.w r3, r4, #12 8033da2: 4630 mov r0, r6 8033da4: f7fc fdde bl 8030964 ofs += m_trap->thl.aaddrlen; 8033da8: 8f23 ldrh r3, [r4, #56] ; 0x38 8033daa: 18ed adds r5, r5, r3 8033dac: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033dae: 4629 mov r1, r5 ofs += 1; 8033db0: 3501 adds r5, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.aaddrlen); ofs += m_trap->thl.aaddrlenlen; snmp_asn1_enc_raw(p, ofs, m_trap->thl.aaddrlen, &m_trap->sip_raw[0]); ofs += m_trap->thl.aaddrlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033db2: 2202 movs r2, #2 ofs += 1; 8033db4: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.aaddrlen); ofs += m_trap->thl.aaddrlenlen; snmp_asn1_enc_raw(p, ofs, m_trap->thl.aaddrlen, &m_trap->sip_raw[0]); ofs += m_trap->thl.aaddrlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033db6: 4630 mov r0, r6 8033db8: f7fc fc98 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.gtrplen); 8033dbc: 4629 mov r1, r5 8033dbe: 8ee2 ldrh r2, [r4, #54] ; 0x36 8033dc0: 4630 mov r0, r6 8033dc2: f7fc fca7 bl 8030714 ofs += m_trap->thl.gtrplenlen; 8033dc6: f894 302a ldrb.w r3, [r4, #42] ; 0x2a snmp_asn1_enc_u32t(p, ofs, m_trap->thl.gtrplen, m_trap->gen_trap); 8033dca: 8ee2 ldrh r2, [r4, #54] ; 0x36 ofs += m_trap->thl.aaddrlen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.gtrplen); ofs += m_trap->thl.gtrplenlen; 8033dcc: 18ed adds r5, r5, r3 8033dce: b2ad uxth r5, r5 snmp_asn1_enc_u32t(p, ofs, m_trap->thl.gtrplen, m_trap->gen_trap); 8033dd0: 4629 mov r1, r5 8033dd2: 6923 ldr r3, [r4, #16] 8033dd4: 4630 mov r0, r6 8033dd6: f7fc fce5 bl 80307a4 ofs += m_trap->thl.gtrplen; 8033dda: 8ee3 ldrh r3, [r4, #54] ; 0x36 8033ddc: 18ed adds r5, r5, r3 8033dde: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033de0: 4629 mov r1, r5 ofs += 1; 8033de2: 3501 adds r5, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.gtrplen); ofs += m_trap->thl.gtrplenlen; snmp_asn1_enc_u32t(p, ofs, m_trap->thl.gtrplen, m_trap->gen_trap); ofs += m_trap->thl.gtrplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033de4: 2202 movs r2, #2 ofs += 1; 8033de6: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.gtrplen); ofs += m_trap->thl.gtrplenlen; snmp_asn1_enc_u32t(p, ofs, m_trap->thl.gtrplen, m_trap->gen_trap); ofs += m_trap->thl.gtrplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); 8033de8: 4630 mov r0, r6 8033dea: f7fc fc7f bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.strplen); 8033dee: 4629 mov r1, r5 8033df0: 8ea2 ldrh r2, [r4, #52] ; 0x34 8033df2: 4630 mov r0, r6 8033df4: f7fc fc8e bl 8030714 ofs += m_trap->thl.strplenlen; 8033df8: f894 3029 ldrb.w r3, [r4, #41] ; 0x29 snmp_asn1_enc_u32t(p, ofs, m_trap->thl.strplen, m_trap->spc_trap); 8033dfc: 8ea2 ldrh r2, [r4, #52] ; 0x34 ofs += m_trap->thl.gtrplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_UNIV | SNMP_ASN1_PRIMIT | SNMP_ASN1_INTEG)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.strplen); ofs += m_trap->thl.strplenlen; 8033dfe: 18ed adds r5, r5, r3 8033e00: b2ad uxth r5, r5 snmp_asn1_enc_u32t(p, ofs, m_trap->thl.strplen, m_trap->spc_trap); 8033e02: 4629 mov r1, r5 8033e04: 6963 ldr r3, [r4, #20] 8033e06: 4630 mov r0, r6 8033e08: f7fc fccc bl 80307a4 ofs += m_trap->thl.strplen; 8033e0c: 8ea3 ldrh r3, [r4, #52] ; 0x34 8033e0e: 18ed adds r5, r5, r3 8033e10: b2ad uxth r5, r5 snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS)); 8033e12: 4629 mov r1, r5 ofs += 1; 8033e14: 3501 adds r5, #1 snmp_asn1_enc_length(p, ofs, m_trap->thl.strplen); ofs += m_trap->thl.strplenlen; snmp_asn1_enc_u32t(p, ofs, m_trap->thl.strplen, m_trap->spc_trap); ofs += m_trap->thl.strplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS)); 8033e16: 2243 movs r2, #67 ; 0x43 ofs += 1; 8033e18: b2ad uxth r5, r5 snmp_asn1_enc_length(p, ofs, m_trap->thl.strplen); ofs += m_trap->thl.strplenlen; snmp_asn1_enc_u32t(p, ofs, m_trap->thl.strplen, m_trap->spc_trap); ofs += m_trap->thl.strplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS)); 8033e1a: 4630 mov r0, r6 8033e1c: f7fc fc66 bl 80306ec ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.tslen); 8033e20: 4629 mov r1, r5 8033e22: 8e62 ldrh r2, [r4, #50] ; 0x32 8033e24: 4630 mov r0, r6 8033e26: f7fc fc75 bl 8030714 ofs += m_trap->thl.tslenlen; 8033e2a: f894 3028 ldrb.w r3, [r4, #40] ; 0x28 snmp_asn1_enc_u32t(p, ofs, m_trap->thl.tslen, m_trap->ts); 8033e2e: 8e62 ldrh r2, [r4, #50] ; 0x32 ofs += m_trap->thl.strplen; snmp_asn1_enc_type(p, ofs, (SNMP_ASN1_APPLIC | SNMP_ASN1_PRIMIT | SNMP_ASN1_TIMETICKS)); ofs += 1; snmp_asn1_enc_length(p, ofs, m_trap->thl.tslen); ofs += m_trap->thl.tslenlen; 8033e30: 18ed adds r5, r5, r3 8033e32: b2ad uxth r5, r5 snmp_asn1_enc_u32t(p, ofs, m_trap->thl.tslen, m_trap->ts); 8033e34: 4629 mov r1, r5 8033e36: 69a3 ldr r3, [r4, #24] 8033e38: 4630 mov r0, r6 8033e3a: f7fc fcb3 bl 80307a4 ofs += m_trap->thl.tslen; 8033e3e: 8e63 ldrh r3, [r4, #50] ; 0x32 8033e40: 18ea adds r2, r5, r3 { u16_t ofs; /* pass 1, encode packet ino the pbuf(s) */ ofs = snmp_trap_header_enc(&trap_msg, p); snmp_varbind_list_enc(&trap_msg.outvb, p, ofs); 8033e42: 4631 mov r1, r6 8033e44: e00a b.n 8033e5c 8033e46: bf00 nop 8033e48: 20011160 .word 0x20011160 8033e4c: 20011148 .word 0x20011148 8033e50: 20011164 .word 0x20011164 8033e54: 080407ac .word 0x080407ac 8033e58: 080407b0 .word 0x080407b0 8033e5c: b292 uxth r2, r2 8033e5e: f104 001c add.w r0, r4, #28 8033e62: f7ff fcb7 bl 80337d4 snmp_inc_snmpouttraps(); 8033e66: f7fe f859 bl 8031f1c snmp_inc_snmpoutpkts(); 8033e6a: f7fd ffaf bl 8031dcc /** send to the TRAP destination */ udp_sendto(trap_msg.pcb, p, &trap_msg.dip, SNMP_TRAP_PORT); 8033e6e: 4622 mov r2, r4 8033e70: 4631 mov r1, r6 8033e72: f852 0b04 ldr.w r0, [r2], #4 8033e76: 23a2 movs r3, #162 ; 0xa2 8033e78: f7fb fddb bl 802fa32 pbuf_free(p); 8033e7c: 4630 mov r0, r6 8033e7e: f7f9 f8d7 bl 802d030 { return ERR_MEM; } } } return ERR_OK; 8033e82: 2000 movs r0, #0 8033e84: e000 b.n 8033e88 pbuf_free(p); } else { return ERR_MEM; 8033e86: 20ff movs r0, #255 ; 0xff } } } return ERR_OK; } 8033e88: b240 sxtb r0, r0 8033e8a: b005 add sp, #20 8033e8c: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 08033e90 : snmp_send_trap(SNMP_GENTRAP_COLDSTART, NULL, 0); } void snmp_authfail_trap(void) { 8033e90: b507 push {r0, r1, r2, lr} u8_t enable; snmp_get_snmpenableauthentraps(&enable); 8033e92: f10d 0007 add.w r0, sp, #7 8033e96: f7fe f84f bl 8031f38 if (enable == 1) 8033e9a: f89d 3007 ldrb.w r3, [sp, #7] 8033e9e: 2b01 cmp r3, #1 8033ea0: d109 bne.n 8033eb6 { trap_msg.outvb.head = NULL; 8033ea2: 2100 movs r1, #0 8033ea4: 4b04 ldr r3, [pc, #16] ; (8033eb8 ) trap_msg.outvb.tail = NULL; trap_msg.outvb.count = 0; snmp_send_trap(SNMP_GENTRAP_AUTHFAIL, NULL, 0); 8033ea6: 2004 movs r0, #4 8033ea8: 460a mov r2, r1 { u8_t enable; snmp_get_snmpenableauthentraps(&enable); if (enable == 1) { trap_msg.outvb.head = NULL; 8033eaa: 61d9 str r1, [r3, #28] trap_msg.outvb.tail = NULL; 8033eac: 6219 str r1, [r3, #32] trap_msg.outvb.count = 0; 8033eae: f883 1024 strb.w r1, [r3, #36] ; 0x24 snmp_send_trap(SNMP_GENTRAP_AUTHFAIL, NULL, 0); 8033eb2: f7ff fe23 bl 8033afc } } 8033eb6: bd0e pop {r1, r2, r3, pc} 8033eb8: 20011148 .word 0x20011148 08033ebc : * @params dst the destination MAC address to be copied into the ethernet header * @return ERR_OK if the packet was sent, any other err_t on failure */ static err_t etharp_send_ip(struct netif *netif, struct pbuf *p, struct eth_addr *src, struct eth_addr *dst) { 8033ebc: b5f8 push {r3, r4, r5, r6, r7, lr} struct eth_hdr *ethhdr = (struct eth_hdr *)p->payload; 8033ebe: 684c ldr r4, [r1, #4] * @params dst the destination MAC address to be copied into the ethernet header * @return ERR_OK if the packet was sent, any other err_t on failure */ static err_t etharp_send_ip(struct netif *netif, struct pbuf *p, struct eth_addr *src, struct eth_addr *dst) { 8033ec0: 4606 mov r6, r0 8033ec2: 460d mov r5, r1 8033ec4: 4617 mov r7, r2 struct eth_hdr *ethhdr = (struct eth_hdr *)p->payload; LWIP_ASSERT("netif->hwaddr_len must be the same as ETHARP_HWADDR_LEN for etharp!", (netif->hwaddr_len == ETHARP_HWADDR_LEN)); ETHADDR32_COPY(ðhdr->dest, dst); 8033ec6: 4619 mov r1, r3 8033ec8: 2206 movs r2, #6 8033eca: 4620 mov r0, r4 8033ecc: f7ed fd3e bl 802194c ETHADDR16_COPY(ðhdr->src, src); 8033ed0: 4639 mov r1, r7 8033ed2: 1da0 adds r0, r4, #6 8033ed4: 2206 movs r2, #6 8033ed6: f7ed fd39 bl 802194c ethhdr->type = PP_HTONS(ETHTYPE_IP); 8033eda: 2308 movs r3, #8 8033edc: 7323 strb r3, [r4, #12] 8033ede: 2300 movs r3, #0 8033ee0: 7363 strb r3, [r4, #13] LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_send_ip: sending packet %p\n", (void *)p)); /* send the packet */ return netif->linkoutput(netif, p); 8033ee2: 69b3 ldr r3, [r6, #24] 8033ee4: 4630 mov r0, r6 8033ee6: 4629 mov r1, r5 8033ee8: 4798 blx r3 } 8033eea: bdf8 pop {r3, r4, r5, r6, r7, pc} 08033eec : #endif /* ARP_QUEUEING */ /** Clean up ARP table entries */ static void etharp_free_entry(int i) { 8033eec: b570 push {r4, r5, r6, lr} /* remove from SNMP ARP index tree */ snmp_delete_arpidx_tree(arp_table[i].netif, &arp_table[i].ipaddr); 8033eee: 4d0b ldr r5, [pc, #44] ; (8033f1c ) 8033ef0: 2414 movs r4, #20 8033ef2: 4344 muls r4, r0 8033ef4: 1929 adds r1, r5, r4 #endif /* ARP_QUEUEING */ /** Clean up ARP table entries */ static void etharp_free_entry(int i) { 8033ef6: 4606 mov r6, r0 /* remove from SNMP ARP index tree */ snmp_delete_arpidx_tree(arp_table[i].netif, &arp_table[i].ipaddr); 8033ef8: 3104 adds r1, #4 8033efa: 6848 ldr r0, [r1, #4] 8033efc: f7fd fc5a bl 80317b4 /* and empty packet queue */ if (arp_table[i].q != NULL) { 8033f00: 5928 ldr r0, [r5, r4] 8033f02: b118 cbz r0, 8033f0c /* remove all queued packets */ LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_free_entry: freeing entry %"U16_F", packet queue %p.\n", (u16_t)i, (void *)(arp_table[i].q))); free_etharp_q(arp_table[i].q); 8033f04: f7f9 f894 bl 802d030 arp_table[i].q = NULL; 8033f08: 2300 movs r3, #0 8033f0a: 512b str r3, [r5, r4] } /* recycle entry for re-use */ arp_table[i].state = ETHARP_STATE_EMPTY; 8033f0c: 2314 movs r3, #20 8033f0e: fb03 5506 mla r5, r3, r6, r5 8033f12: 2300 movs r3, #0 8033f14: 74ab strb r3, [r5, #18] 8033f16: 3510 adds r5, #16 8033f18: bd70 pop {r4, r5, r6, pc} 8033f1a: bf00 nop 8033f1c: 2000e410 .word 0x2000e410 08033f20 : * @return The ARP entry index that matched or is created, ERR_MEM if no * entry is found or could be recycled. */ static s8_t etharp_find_entry(ip_addr_t *ipaddr, u8_t flags) { 8033f20: e92d 4ff7 stmdb sp!, {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} s8_t empty = ARP_TABLE_SIZE; u8_t i = 0, age_pending = 0, age_stable = 0; /* oldest entry with packets on queue */ s8_t old_queue = ARP_TABLE_SIZE; /* its age */ u8_t age_queue = 0; 8033f24: 2500 movs r5, #0 { s8_t old_pending = ARP_TABLE_SIZE, old_stable = ARP_TABLE_SIZE; s8_t empty = ARP_TABLE_SIZE; u8_t i = 0, age_pending = 0, age_stable = 0; /* oldest entry with packets on queue */ s8_t old_queue = ARP_TABLE_SIZE; 8033f26: 240a movs r4, #10 8033f28: 4a35 ldr r2, [pc, #212] ; (8034000 ) * @return The ARP entry index that matched or is created, ERR_MEM if no * entry is found or could be recycled. */ static s8_t etharp_find_entry(ip_addr_t *ipaddr, u8_t flags) { 8033f2a: 9101 str r1, [sp, #4] 8033f2c: 4606 mov r6, r0 s8_t old_pending = ARP_TABLE_SIZE, old_stable = ARP_TABLE_SIZE; s8_t empty = ARP_TABLE_SIZE; u8_t i = 0, age_pending = 0, age_stable = 0; 8033f2e: 46a8 mov r8, r5 8033f30: 46aa mov sl, r5 * 4) remember the oldest pending entry with queued packets (if any) * 5) search for a matching IP entry, either pending or stable * until 5 matches, or all entries are searched for. */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { 8033f32: 462b mov r3, r5 */ static s8_t etharp_find_entry(ip_addr_t *ipaddr, u8_t flags) { s8_t old_pending = ARP_TABLE_SIZE, old_stable = ARP_TABLE_SIZE; s8_t empty = ARP_TABLE_SIZE; 8033f34: 4627 mov r7, r4 * entry is found or could be recycled. */ static s8_t etharp_find_entry(ip_addr_t *ipaddr, u8_t flags) { s8_t old_pending = ARP_TABLE_SIZE, old_stable = ARP_TABLE_SIZE; 8033f36: 46a4 mov ip, r4 8033f38: 46a3 mov fp, r4 */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { u8_t state = arp_table[i].state; /* no empty entry found yet and now we do find one? */ if ((empty == ARP_TABLE_SIZE) && (state == ETHARP_STATE_EMPTY)) { 8033f3a: 2f0a cmp r7, #10 * 5) search for a matching IP entry, either pending or stable * until 5 matches, or all entries are searched for. */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { u8_t state = arp_table[i].state; 8033f3c: f892 9012 ldrb.w r9, [r2, #18] /* no empty entry found yet and now we do find one? */ if ((empty == ARP_TABLE_SIZE) && (state == ETHARP_STATE_EMPTY)) { 8033f40: d104 bne.n 8033f4c 8033f42: f1b9 0f00 cmp.w r9, #0 8033f46: d104 bne.n 8033f52 LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_find_entry: found empty entry %"U16_F"\n", (u16_t)i)); /* remember first empty entry */ empty = i; 8033f48: b2df uxtb r7, r3 8033f4a: e023 b.n 8033f94 } else if (state != ETHARP_STATE_EMPTY) { 8033f4c: f1b9 0f00 cmp.w r9, #0 8033f50: d020 beq.n 8033f94 LWIP_ASSERT("state == ETHARP_STATE_PENDING || state >= ETHARP_STATE_STABLE", state == ETHARP_STATE_PENDING || state >= ETHARP_STATE_STABLE); /* if given, does IP address match IP address in ARP entry? */ if (ipaddr && ip_addr_cmp(ipaddr, &arp_table[i].ipaddr)) { 8033f52: b12e cbz r6, 8033f60 8033f54: 6830 ldr r0, [r6, #0] 8033f56: 6851 ldr r1, [r2, #4] 8033f58: 4288 cmp r0, r1 8033f5a: d101 bne.n 8033f60 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_find_entry: found matching entry %"U16_F"\n", (u16_t)i)); /* found exact IP address match, simply bail out */ return i; 8033f5c: 4618 mov r0, r3 8033f5e: e04b b.n 8033ff8 } /* pending entry? */ if (state == ETHARP_STATE_PENDING) { 8033f60: f1b9 0f01 cmp.w r9, #1 8033f64: d10e bne.n 8033f84 /* pending with queued packets? */ if (arp_table[i].q != NULL) { 8033f66: 6810 ldr r0, [r2, #0] if (arp_table[i].ctime >= age_queue) { 8033f68: f892 9013 ldrb.w r9, [r2, #19] return i; } /* pending entry? */ if (state == ETHARP_STATE_PENDING) { /* pending with queued packets? */ if (arp_table[i].q != NULL) { 8033f6c: b120 cbz r0, 8033f78 if (arp_table[i].ctime >= age_queue) { 8033f6e: 45a9 cmp r9, r5 8033f70: d310 bcc.n 8033f94 old_queue = i; 8033f72: b2dc uxtb r4, r3 8033f74: 464d mov r5, r9 8033f76: e00d b.n 8033f94 age_queue = arp_table[i].ctime; } } else /* pending without queued packets? */ { if (arp_table[i].ctime >= age_pending) { 8033f78: 45d1 cmp r9, sl 8033f7a: d30b bcc.n 8033f94 old_pending = i; 8033f7c: fa5f fb83 uxtb.w fp, r3 8033f80: 46ca mov sl, r9 8033f82: e007 b.n 8033f94 age_pending = arp_table[i].ctime; } } /* stable entry? */ } else if (state >= ETHARP_STATE_STABLE) { 8033f84: d906 bls.n 8033f94 /* don't record old_stable for static entries since they never expire */ if (state < ETHARP_STATE_STATIC) #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ { /* remember entry with oldest stable entry in oldest, its age in maxtime */ if (arp_table[i].ctime >= age_stable) { 8033f86: f892 9013 ldrb.w r9, [r2, #19] 8033f8a: 45c1 cmp r9, r8 old_stable = i; 8033f8c: bf24 itt cs 8033f8e: fa5f fc83 uxtbcs.w ip, r3 8033f92: 46c8 movcs r8, r9 * 4) remember the oldest pending entry with queued packets (if any) * 5) search for a matching IP entry, either pending or stable * until 5 matches, or all entries are searched for. */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { 8033f94: 3301 adds r3, #1 8033f96: b2db uxtb r3, r3 8033f98: 3214 adds r2, #20 8033f9a: 2b0a cmp r3, #10 8033f9c: d1cd bne.n 8033f3a } } /* { we have no match } => try to create a new entry */ /* don't create new entry, only search? */ if (((flags & ETHARP_FLAG_FIND_ONLY) != 0) || 8033f9e: 9a01 ldr r2, [sp, #4] 8033fa0: f002 0302 and.w r3, r2, #2 8033fa4: b2db uxtb r3, r3 8033fa6: bb33 cbnz r3, 8033ff6 8033fa8: 2f0a cmp r7, #10 8033faa: d102 bne.n 8033fb2 /* or no empty entry found and not allowed to recycle? */ ((empty == ARP_TABLE_SIZE) && ((flags & ETHARP_FLAG_TRY_HARD) == 0))) { 8033fac: 07d3 lsls r3, r2, #31 8033fae: d402 bmi.n 8033fb6 8033fb0: e021 b.n 8033ff6 * { ETHARP_FLAG_TRY_HARD is set at this point } */ /* 1) empty entry available? */ if (empty < ARP_TABLE_SIZE) { i = empty; 8033fb2: b2fc uxtb r4, r7 8033fb4: e011 b.n 8033fda LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_find_entry: selecting empty entry %"U16_F"\n", (u16_t)i)); } else { /* 2) found recyclable stable entry? */ if (old_stable < ARP_TABLE_SIZE) { 8033fb6: f1bc 0f0a cmp.w ip, #10 8033fba: d002 beq.n 8033fc2 /* recycle oldest stable*/ i = old_stable; 8033fbc: fa5f f48c uxtb.w r4, ip 8033fc0: e008 b.n 8033fd4 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_find_entry: selecting oldest stable entry %"U16_F"\n", (u16_t)i)); /* no queued packets should exist on stable entries */ LWIP_ASSERT("arp_table[i].q == NULL", arp_table[i].q == NULL); /* 3) found recyclable pending entry without queued packets? */ } else if (old_pending < ARP_TABLE_SIZE) { 8033fc2: f1bb 0f0a cmp.w fp, #10 8033fc6: d002 beq.n 8033fce /* recycle oldest pending */ i = old_pending; 8033fc8: fa5f f48b uxtb.w r4, fp 8033fcc: e002 b.n 8033fd4 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_find_entry: selecting oldest pending entry %"U16_F" (without queue)\n", (u16_t)i)); /* 4) found recyclable pending entry with queued packets? */ } else if (old_queue < ARP_TABLE_SIZE) { 8033fce: 2c0a cmp r4, #10 8033fd0: d011 beq.n 8033ff6 /* recycle oldest pending (queued packets are free in etharp_free_entry) */ i = old_queue; 8033fd2: b2e4 uxtb r4, r4 return (s8_t)ERR_MEM; } /* { empty or recyclable entry found } */ LWIP_ASSERT("i < ARP_TABLE_SIZE", i < ARP_TABLE_SIZE); etharp_free_entry(i); 8033fd4: 4620 mov r0, r4 8033fd6: f7ff ff89 bl 8033eec 8033fda: 4b09 ldr r3, [pc, #36] ; (8034000 ) LWIP_ASSERT("i < ARP_TABLE_SIZE", i < ARP_TABLE_SIZE); LWIP_ASSERT("arp_table[i].state == ETHARP_STATE_EMPTY", arp_table[i].state == ETHARP_STATE_EMPTY); /* IP address given? */ if (ipaddr != NULL) { 8033fdc: b126 cbz r6, 8033fe8 /* set IP address */ ip_addr_copy(arp_table[i].ipaddr, *ipaddr); 8033fde: 2214 movs r2, #20 8033fe0: 6831 ldr r1, [r6, #0] 8033fe2: fb02 3204 mla r2, r2, r4, r3 8033fe6: 6051 str r1, [r2, #4] } arp_table[i].ctime = 0; 8033fe8: 2214 movs r2, #20 8033fea: fb02 3304 mla r3, r2, r4, r3 8033fee: 2200 movs r2, #0 8033ff0: 74da strb r2, [r3, #19] return (err_t)i; 8033ff2: 4620 mov r0, r4 8033ff4: e000 b.n 8033ff8 /* don't create new entry, only search? */ if (((flags & ETHARP_FLAG_FIND_ONLY) != 0) || /* or no empty entry found and not allowed to recycle? */ ((empty == ARP_TABLE_SIZE) && ((flags & ETHARP_FLAG_TRY_HARD) == 0))) { LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_find_entry: no empty entry found and not allowed to recycle\n")); return (s8_t)ERR_MEM; 8033ff6: 20ff movs r0, #255 ; 0xff /* set IP address */ ip_addr_copy(arp_table[i].ipaddr, *ipaddr); } arp_table[i].ctime = 0; return (err_t)i; } 8033ff8: b240 sxtb r0, r0 8033ffa: e8bd 8ffe ldmia.w sp!, {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 8033ffe: bf00 nop 8034000: 2000e410 .word 0x2000e410 08034004 : * This function should be called every ETHARP_TMR_INTERVAL milliseconds (5 seconds), * in order to expire entries in the ARP table. */ void etharp_tmr(void) { 8034004: b570 push {r4, r5, r6, lr} 8034006: 4c0d ldr r4, [pc, #52] ; (803403c ) 8034008: 2500 movs r5, #0 etharp_free_entry(i); } else if (arp_table[i].state == ETHARP_STATE_STABLE_REREQUESTING) { /* Reset state to stable, so that the next transmitted packet will re-send an ARP request. */ arp_table[i].state = ETHARP_STATE_STABLE; 803400a: 2602 movs r6, #2 LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_timer\n")); /* remove expired entries from the ARP table */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { u8_t state = arp_table[i].state; if (state != ETHARP_STATE_EMPTY 803400c: 7ca3 ldrb r3, [r4, #18] 803400e: b183 cbz r3, 8034032 #if ETHARP_SUPPORT_STATIC_ENTRIES && (state != ETHARP_STATE_STATIC) #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ ) { arp_table[i].ctime++; 8034010: 7ce2 ldrb r2, [r4, #19] 8034012: 3201 adds r2, #1 8034014: b2d2 uxtb r2, r2 if ((arp_table[i].ctime >= ARP_MAXAGE) || 8034016: 2aef cmp r2, #239 ; 0xef if (state != ETHARP_STATE_EMPTY #if ETHARP_SUPPORT_STATIC_ENTRIES && (state != ETHARP_STATE_STATIC) #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ ) { arp_table[i].ctime++; 8034018: 74e2 strb r2, [r4, #19] if ((arp_table[i].ctime >= ARP_MAXAGE) || 803401a: d803 bhi.n 8034024 803401c: 2b01 cmp r3, #1 803401e: d105 bne.n 803402c ((arp_table[i].state == ETHARP_STATE_PENDING) && 8034020: 2a01 cmp r2, #1 8034022: d906 bls.n 8034032 (arp_table[i].ctime >= ARP_MAXPENDING))) { /* pending or stable entry has become old! */ LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_timer: expired %s entry %"U16_F".\n", arp_table[i].state >= ETHARP_STATE_STABLE ? "stable" : "pending", (u16_t)i)); /* clean up entries that have just been expired */ etharp_free_entry(i); 8034024: 4628 mov r0, r5 8034026: f7ff ff61 bl 8033eec 803402a: e002 b.n 8034032 } else if (arp_table[i].state == ETHARP_STATE_STABLE_REREQUESTING) { 803402c: 2b03 cmp r3, #3 /* Reset state to stable, so that the next transmitted packet will re-send an ARP request. */ arp_table[i].state = ETHARP_STATE_STABLE; 803402e: bf08 it eq 8034030: 74a6 strbeq r6, [r4, #18] 8034032: 3501 adds r5, #1 8034034: 3414 adds r4, #20 { u8_t i; LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_timer\n")); /* remove expired entries from the ARP table */ for (i = 0; i < ARP_TABLE_SIZE; ++i) { 8034036: 2d0a cmp r5, #10 8034038: d1e8 bne.n 803400c /* resend an ARP query here? */ } #endif /* ARP_QUEUEING */ } } } 803403a: bd70 pop {r4, r5, r6, pc} 803403c: 2000e410 .word 0x2000e410 08034040 : * Remove all ARP table entries of the specified netif. * * @param netif points to a network interface */ void etharp_cleanup_netif(struct netif *netif) { 8034040: b570 push {r4, r5, r6, lr} 8034042: 4d08 ldr r5, [pc, #32] ; (8034064 ) 8034044: 4606 mov r6, r0 8034046: 2400 movs r4, #0 u8_t i; for (i = 0; i < ARP_TABLE_SIZE; ++i) { u8_t state = arp_table[i].state; if ((state != ETHARP_STATE_EMPTY) && (arp_table[i].netif == netif)) { 8034048: 7cab ldrb r3, [r5, #18] 803404a: b12b cbz r3, 8034058 803404c: 68ab ldr r3, [r5, #8] 803404e: 42b3 cmp r3, r6 8034050: d102 bne.n 8034058 etharp_free_entry(i); 8034052: 4620 mov r0, r4 8034054: f7ff ff4a bl 8033eec 8034058: 3401 adds r4, #1 803405a: 3514 adds r5, #20 */ void etharp_cleanup_netif(struct netif *netif) { u8_t i; for (i = 0; i < ARP_TABLE_SIZE; ++i) { 803405c: 2c0a cmp r4, #10 803405e: d1f3 bne.n 8034048 u8_t state = arp_table[i].state; if ((state != ETHARP_STATE_EMPTY) && (arp_table[i].netif == netif)) { etharp_free_entry(i); } } } 8034060: bd70 pop {r4, r5, r6, pc} 8034062: bf00 nop 8034064: 2000e410 .word 0x2000e410 08034068 : * @return table index if found, -1 otherwise */ s8_t etharp_find_addr(struct netif *netif, ip_addr_t *ipaddr, struct eth_addr **eth_ret, ip_addr_t **ip_ret) { 8034068: b5f8 push {r3, r4, r5, r6, r7, lr} LWIP_ASSERT("eth_ret != NULL && ip_ret != NULL", eth_ret != NULL && ip_ret != NULL); LWIP_UNUSED_ARG(netif); i = etharp_find_entry(ipaddr, ETHARP_FLAG_FIND_ONLY); 803406a: 4608 mov r0, r1 803406c: 2102 movs r1, #2 * @return table index if found, -1 otherwise */ s8_t etharp_find_addr(struct netif *netif, ip_addr_t *ipaddr, struct eth_addr **eth_ret, ip_addr_t **ip_ret) { 803406e: 4616 mov r6, r2 8034070: 461f mov r7, r3 LWIP_ASSERT("eth_ret != NULL && ip_ret != NULL", eth_ret != NULL && ip_ret != NULL); LWIP_UNUSED_ARG(netif); i = etharp_find_entry(ipaddr, ETHARP_FLAG_FIND_ONLY); 8034072: f7ff ff55 bl 8033f20 if((i >= 0) && (arp_table[i].state >= ETHARP_STATE_STABLE)) { 8034076: 2800 cmp r0, #0 8034078: db0c blt.n 8034094 803407a: 2414 movs r4, #20 803407c: 4d07 ldr r5, [pc, #28] ; (803409c ) 803407e: 4344 muls r4, r0 8034080: 1929 adds r1, r5, r4 8034082: 7c8b ldrb r3, [r1, #18] 8034084: 2b01 cmp r3, #1 8034086: d905 bls.n 8034094 *eth_ret = &arp_table[i].ethaddr; 8034088: 460c mov r4, r1 803408a: 340c adds r4, #12 *ip_ret = &arp_table[i].ipaddr; 803408c: 3104 adds r1, #4 LWIP_UNUSED_ARG(netif); i = etharp_find_entry(ipaddr, ETHARP_FLAG_FIND_ONLY); if((i >= 0) && (arp_table[i].state >= ETHARP_STATE_STABLE)) { *eth_ret = &arp_table[i].ethaddr; 803408e: 6034 str r4, [r6, #0] *ip_ret = &arp_table[i].ipaddr; 8034090: 6039 str r1, [r7, #0] return i; 8034092: e000 b.n 8034096 } return -1; 8034094: 20ff movs r0, #255 ; 0xff } 8034096: b240 sxtb r0, r0 8034098: bdf8 pop {r3, r4, r5, r6, r7, pc} 803409a: bf00 nop 803409c: 2000e410 .word 0x2000e410 080340a0 : * ERR_MEM if the ARP packet couldn't be allocated * any other err_t on failure */ err_t etharp_request(struct netif *netif, ip_addr_t *ipaddr) { 80340a0: e92d 43f8 stmdb sp!, {r3, r4, r5, r6, r7, r8, r9, lr} #endif /* LWIP_AUTOIP */ LWIP_ASSERT("netif != NULL", netif != NULL); /* allocate a pbuf for the outgoing ARP request packet */ p = pbuf_alloc(PBUF_RAW, SIZEOF_ETHARP_PACKET, PBUF_RAM); 80340a4: 2200 movs r2, #0 * ERR_MEM if the ARP packet couldn't be allocated * any other err_t on failure */ err_t etharp_request(struct netif *netif, ip_addr_t *ipaddr) { 80340a6: 4606 mov r6, r0 80340a8: 4688 mov r8, r1 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_request: sending ARP request.\n")); return etharp_raw(netif, (struct eth_addr *)netif->hwaddr, ðbroadcast, (struct eth_addr *)netif->hwaddr, &netif->ip_addr, ðzero, 80340aa: f100 0727 add.w r7, r0, #39 ; 0x27 80340ae: f100 0904 add.w r9, r0, #4 #endif /* LWIP_AUTOIP */ LWIP_ASSERT("netif != NULL", netif != NULL); /* allocate a pbuf for the outgoing ARP request packet */ p = pbuf_alloc(PBUF_RAW, SIZEOF_ETHARP_PACKET, PBUF_RAM); 80340b2: 212a movs r1, #42 ; 0x2a 80340b4: 2003 movs r0, #3 80340b6: f7f9 f808 bl 802d0ca /* could allocate a pbuf for an ARP request? */ if (p == NULL) { 80340ba: 4605 mov r5, r0 80340bc: 2800 cmp r0, #0 80340be: d03c beq.n 803413a return ERR_MEM; } LWIP_ASSERT("check that first pbuf can hold struct etharp_hdr", (p->len >= SIZEOF_ETHARP_PACKET)); ethhdr = (struct eth_hdr *)p->payload; 80340c0: 6844 ldr r4, [r0, #4] hdr = (struct etharp_hdr *)((u8_t*)ethhdr + SIZEOF_ETH_HDR); LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_raw: sending raw ARP packet.\n")); hdr->opcode = htons(opcode); 80340c2: 2001 movs r0, #1 80340c4: f7f7 fe76 bl 802bdb4 * 'sender IP address' MUST be sent using link-layer broadcast instead of * link-layer unicast. (See RFC3927 Section 2.5, last paragraph) */ ethdst_hwaddr = ip_addr_islinklocal(ipsrc_addr) ? (u8_t*)(ethbroadcast.addr) : ethdst_addr->addr; #endif /* LWIP_AUTOIP */ /* Write the ARP MAC-Addresses */ ETHADDR16_COPY(&hdr->shwaddr, hwsrc_addr); 80340c8: 4639 mov r1, r7 (p->len >= SIZEOF_ETHARP_PACKET)); ethhdr = (struct eth_hdr *)p->payload; hdr = (struct etharp_hdr *)((u8_t*)ethhdr + SIZEOF_ETH_HDR); LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_raw: sending raw ARP packet.\n")); hdr->opcode = htons(opcode); 80340ca: 82a0 strh r0, [r4, #20] * 'sender IP address' MUST be sent using link-layer broadcast instead of * link-layer unicast. (See RFC3927 Section 2.5, last paragraph) */ ethdst_hwaddr = ip_addr_islinklocal(ipsrc_addr) ? (u8_t*)(ethbroadcast.addr) : ethdst_addr->addr; #endif /* LWIP_AUTOIP */ /* Write the ARP MAC-Addresses */ ETHADDR16_COPY(&hdr->shwaddr, hwsrc_addr); 80340cc: 2206 movs r2, #6 80340ce: f104 0016 add.w r0, r4, #22 80340d2: f7ed fc3b bl 802194c ETHADDR16_COPY(&hdr->dhwaddr, hwdst_addr); 80340d6: 2206 movs r2, #6 80340d8: f104 0020 add.w r0, r4, #32 80340dc: 4919 ldr r1, [pc, #100] ; (8034144 ) 80340de: f7ed fc35 bl 802194c /* Write the Ethernet MAC-Addresses */ #if LWIP_AUTOIP ETHADDR16_COPY(ðhdr->dest, ethdst_hwaddr); #else /* LWIP_AUTOIP */ ETHADDR16_COPY(ðhdr->dest, ethdst_addr); 80340e2: 2206 movs r2, #6 80340e4: 4620 mov r0, r4 80340e6: 4918 ldr r1, [pc, #96] ; (8034148 ) 80340e8: f7ed fc30 bl 802194c #endif /* LWIP_AUTOIP */ ETHADDR16_COPY(ðhdr->src, ethsrc_addr); 80340ec: 1da0 adds r0, r4, #6 80340ee: 4639 mov r1, r7 80340f0: 2206 movs r2, #6 80340f2: f7ed fc2b bl 802194c /* Copy struct ip_addr2 to aligned ip_addr, to support compilers without * structure packing. */ IPADDR2_COPY(&hdr->sipaddr, ipsrc_addr); 80340f6: 4649 mov r1, r9 80340f8: 2204 movs r2, #4 80340fa: f104 001c add.w r0, r4, #28 80340fe: f7ed fc25 bl 802194c IPADDR2_COPY(&hdr->dipaddr, ipdst_addr); 8034102: 4641 mov r1, r8 8034104: 2204 movs r2, #4 8034106: f104 0026 add.w r0, r4, #38 ; 0x26 803410a: f7ed fc1f bl 802194c hdr->hwtype = PP_HTONS(HWTYPE_ETHERNET); 803410e: 2300 movs r3, #0 8034110: 2201 movs r2, #1 8034112: 73a3 strb r3, [r4, #14] 8034114: 73e2 strb r2, [r4, #15] hdr->proto = PP_HTONS(ETHTYPE_IP); 8034116: 7463 strb r3, [r4, #17] 8034118: 2208 movs r2, #8 /* set hwlen and protolen */ hdr->hwlen = ETHARP_HWADDR_LEN; 803411a: 2306 movs r3, #6 hdr->protolen = sizeof(ip_addr_t); 803411c: 2104 movs r1, #4 * structure packing. */ IPADDR2_COPY(&hdr->sipaddr, ipsrc_addr); IPADDR2_COPY(&hdr->dipaddr, ipdst_addr); hdr->hwtype = PP_HTONS(HWTYPE_ETHERNET); hdr->proto = PP_HTONS(ETHTYPE_IP); 803411e: 7422 strb r2, [r4, #16] /* set hwlen and protolen */ hdr->hwlen = ETHARP_HWADDR_LEN; hdr->protolen = sizeof(ip_addr_t); 8034120: 74e1 strb r1, [r4, #19] ethhdr->type = PP_HTONS(ETHTYPE_ARP); 8034122: 7322 strb r2, [r4, #12] IPADDR2_COPY(&hdr->dipaddr, ipdst_addr); hdr->hwtype = PP_HTONS(HWTYPE_ETHERNET); hdr->proto = PP_HTONS(ETHTYPE_IP); /* set hwlen and protolen */ hdr->hwlen = ETHARP_HWADDR_LEN; 8034124: 74a3 strb r3, [r4, #18] hdr->protolen = sizeof(ip_addr_t); ethhdr->type = PP_HTONS(ETHTYPE_ARP); 8034126: 7363 strb r3, [r4, #13] /* send ARP query */ result = netif->linkoutput(netif, p); 8034128: 69b3 ldr r3, [r6, #24] 803412a: 4630 mov r0, r6 803412c: 4629 mov r1, r5 803412e: 4798 blx r3 8034130: 4604 mov r4, r0 ETHARP_STATS_INC(etharp.xmit); /* free ARP query packet */ pbuf_free(p); 8034132: 4628 mov r0, r5 8034134: f7f8 ff7c bl 802d030 8034138: e000 b.n 803413c /* could allocate a pbuf for an ARP request? */ if (p == NULL) { LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("etharp_raw: could not allocate pbuf for ARP request.\n")); ETHARP_STATS_INC(etharp.memerr); return ERR_MEM; 803413a: 24ff movs r4, #255 ; 0xff { LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_request: sending ARP request.\n")); return etharp_raw(netif, (struct eth_addr *)netif->hwaddr, ðbroadcast, (struct eth_addr *)netif->hwaddr, &netif->ip_addr, ðzero, ipaddr, ARP_REQUEST); } 803413c: b260 sxtb r0, r4 803413e: e8bd 83f8 ldmia.w sp!, {r3, r4, r5, r6, r7, r8, r9, pc} 8034142: bf00 nop 8034144: 080407bd .word 0x080407bd 8034148: 080407b7 .word 0x080407b7 0803414c : * - ERR_ARG Non-unicast address given, those will not appear in ARP cache. * */ err_t etharp_query(struct netif *netif, ip_addr_t *ipaddr, struct pbuf *q) { 803414c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} 8034150: 4607 mov r7, r0 8034152: 460e mov r6, r1 struct eth_addr * srcaddr = (struct eth_addr *)netif->hwaddr; err_t result = ERR_MEM; s8_t i; /* ARP entry index */ /* non-unicast address? */ if (ip_addr_isbroadcast(ipaddr, netif) || 8034154: 6808 ldr r0, [r1, #0] 8034156: 4639 mov r1, r7 * - ERR_ARG Non-unicast address given, those will not appear in ARP cache. * */ err_t etharp_query(struct netif *netif, ip_addr_t *ipaddr, struct pbuf *q) { 8034158: 4615 mov r5, r2 struct eth_addr * srcaddr = (struct eth_addr *)netif->hwaddr; err_t result = ERR_MEM; s8_t i; /* ARP entry index */ /* non-unicast address? */ if (ip_addr_isbroadcast(ipaddr, netif) || 803415a: f7fb fe03 bl 802fd64 803415e: 2800 cmp r0, #0 8034160: d157 bne.n 8034212 ip_addr_ismulticast(ipaddr) || 8034162: 6833 ldr r3, [r6, #0] 8034164: f003 02f0 and.w r2, r3, #240 ; 0xf0 struct eth_addr * srcaddr = (struct eth_addr *)netif->hwaddr; err_t result = ERR_MEM; s8_t i; /* ARP entry index */ /* non-unicast address? */ if (ip_addr_isbroadcast(ipaddr, netif) || 8034168: 2ae0 cmp r2, #224 ; 0xe0 803416a: d052 beq.n 8034212 ip_addr_ismulticast(ipaddr) || ip_addr_isany(ipaddr)) { 803416c: 2b00 cmp r3, #0 803416e: d050 beq.n 8034212 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: will not add non-unicast IP address to ARP cache\n")); return ERR_ARG; } /* find entry in ARP cache, ask to create entry if queueing packet */ i = etharp_find_entry(ipaddr, ETHARP_FLAG_TRY_HARD); 8034170: 2101 movs r1, #1 8034172: 4630 mov r0, r6 8034174: f7ff fed4 bl 8033f20 /* could not find or create entry? */ if (i < 0) { 8034178: 1e04 subs r4, r0, #0 803417a: db4f blt.n 803421c } return (err_t)i; } /* mark a fresh entry as pending (we just sent a request) */ if (arp_table[i].state == ETHARP_STATE_EMPTY) { 803417c: 4931 ldr r1, [pc, #196] ; (8034244 ) 803417e: 2214 movs r2, #20 8034180: fb02 1304 mla r3, r2, r4, r1 8034184: 3310 adds r3, #16 8034186: 7898 ldrb r0, [r3, #2] 8034188: b908 cbnz r0, 803418e arp_table[i].state = ETHARP_STATE_PENDING; 803418a: 2001 movs r0, #1 803418c: 7098 strb r0, [r3, #2] LWIP_ASSERT("arp_table[i].state == PENDING or STABLE", ((arp_table[i].state == ETHARP_STATE_PENDING) || (arp_table[i].state >= ETHARP_STATE_STABLE))); /* do we have a pending entry? or an implicit query request? */ if ((arp_table[i].state == ETHARP_STATE_PENDING) || (q == NULL)) { 803418e: fb02 1204 mla r2, r2, r4, r1 8034192: 7c93 ldrb r3, [r2, #18] 8034194: 2b01 cmp r3, #1 8034196: d000 beq.n 803419a 8034198: b935 cbnz r5, 80341a8 /* try to resolve it; send out ARP request */ result = etharp_request(netif, ipaddr); 803419a: 4638 mov r0, r7 803419c: 4631 mov r1, r6 803419e: f7ff ff7f bl 80340a0 80341a2: 4602 mov r2, r0 /* ARP request couldn't be sent */ /* We don't re-send arp request in etharp_tmr, but we still queue packets, since this failure could be temporary, and the next packet calling etharp_query again could lead to sending the queued packets. */ } if (q == NULL) { 80341a4: b90d cbnz r5, 80341aa 80341a6: e036 b.n 8034216 */ err_t etharp_query(struct netif *netif, ip_addr_t *ipaddr, struct pbuf *q) { struct eth_addr * srcaddr = (struct eth_addr *)netif->hwaddr; err_t result = ERR_MEM; 80341a8: 22ff movs r2, #255 ; 0xff } /* packet given? */ LWIP_ASSERT("q != NULL", q != NULL); /* stable entry? */ if (arp_table[i].state >= ETHARP_STATE_STABLE) { 80341aa: 2314 movs r3, #20 80341ac: 4925 ldr r1, [pc, #148] ; (8034244 ) 80341ae: 4363 muls r3, r4 80341b0: 18c8 adds r0, r1, r3 80341b2: 7c80 ldrb r0, [r0, #18] 80341b4: 2801 cmp r0, #1 80341b6: d90b bls.n 80341d0 /* we have a valid IP->Ethernet address mapping */ ETHARP_SET_HINT(netif, i); 80341b8: 4a23 ldr r2, [pc, #140] ; (8034248 ) /* send the packet */ result = etharp_send_ip(netif, q, srcaddr, &(arp_table[i].ethaddr)); 80341ba: 18cb adds r3, r1, r3 /* packet given? */ LWIP_ASSERT("q != NULL", q != NULL); /* stable entry? */ if (arp_table[i].state >= ETHARP_STATE_STABLE) { /* we have a valid IP->Ethernet address mapping */ ETHARP_SET_HINT(netif, i); 80341bc: 7014 strb r4, [r2, #0] /* send the packet */ result = etharp_send_ip(netif, q, srcaddr, &(arp_table[i].ethaddr)); 80341be: 4638 mov r0, r7 80341c0: 4629 mov r1, r5 80341c2: f107 0227 add.w r2, r7, #39 ; 0x27 80341c6: 330c adds r3, #12 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: could not queue a copy of PBUF_REF packet %p (out of memory)\n", (void *)q)); result = ERR_MEM; } } return result; } 80341c8: e8bd 41f0 ldmia.w sp!, {r4, r5, r6, r7, r8, lr} /* stable entry? */ if (arp_table[i].state >= ETHARP_STATE_STABLE) { /* we have a valid IP->Ethernet address mapping */ ETHARP_SET_HINT(netif, i); /* send the packet */ result = etharp_send_ip(netif, q, srcaddr, &(arp_table[i].ethaddr)); 80341cc: f7ff be76 b.w 8033ebc /* pending entry? (either just created or already pending */ } else if (arp_table[i].state == ETHARP_STATE_PENDING) { 80341d0: d123 bne.n 803421a 80341d2: 462b mov r3, r5 80341d4: e003 b.n 80341de * to copy the whole queue into a new PBUF_RAM (see bug #11400) * PBUF_ROMs can be left as they are, since ROM must not get changed. */ p = q; while (p) { LWIP_ASSERT("no packet queues allowed!", (p->len != p->tot_len) || (p->next == 0)); if(p->type != PBUF_ROM) { 80341d6: 7b1a ldrb r2, [r3, #12] 80341d8: 2a01 cmp r2, #1 80341da: d128 bne.n 803422e copy_needed = 1; break; } p = p->next; 80341dc: 681b ldr r3, [r3, #0] int copy_needed = 0; /* IF q includes a PBUF_REF, PBUF_POOL or PBUF_RAM, we have no choice but * to copy the whole queue into a new PBUF_RAM (see bug #11400) * PBUF_ROMs can be left as they are, since ROM must not get changed. */ p = q; while (p) { 80341de: 2b00 cmp r3, #0 80341e0: d1f9 bne.n 80341d6 80341e2: e01e b.n 8034222 } if(copy_needed) { /* copy the whole packet into new pbufs */ p = pbuf_alloc(PBUF_RAW, p->tot_len, PBUF_RAM); if(p != NULL) { if (pbuf_copy(p, q) != ERR_OK) { 80341e4: 4629 mov r1, r5 80341e6: f7f9 f827 bl 802d238 80341ea: b120 cbz r0, 80341f6 pbuf_free(p); 80341ec: 4630 mov r0, r6 80341ee: f7f8 ff1f bl 802d030 80341f2: e024 b.n 803423e /* referencing the old pbuf is enough */ p = q; pbuf_ref(p); } /* packet could be taken over? */ if (p != NULL) { 80341f4: 462e mov r6, r5 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: could not queue a copy of PBUF_REF packet %p (out of memory)\n", (void *)q)); result = ERR_MEM; } #else /* ARP_QUEUEING */ /* always queue one packet per ARP request only, freeing a previously queued packet */ if (arp_table[i].q != NULL) { 80341f6: 2314 movs r3, #20 80341f8: 4a12 ldr r2, [pc, #72] ; (8034244 ) 80341fa: fb03 f104 mul.w r1, r3, r4 80341fe: 4615 mov r5, r2 8034200: 5850 ldr r0, [r2, r1] 8034202: 461f mov r7, r3 8034204: b108 cbz r0, 803420a LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: dropped previously queued packet %p for ARP entry %"S16_F"\n", (void *)q, (s16_t)i)); pbuf_free(arp_table[i].q); 8034206: f7f8 ff13 bl 802d030 } arp_table[i].q = p; 803420a: 437c muls r4, r7 803420c: 512e str r6, [r5, r4] result = ERR_OK; 803420e: 2400 movs r4, #0 8034210: e004 b.n 803421c /* non-unicast address? */ if (ip_addr_isbroadcast(ipaddr, netif) || ip_addr_ismulticast(ipaddr) || ip_addr_isany(ipaddr)) { LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: will not add non-unicast IP address to ARP cache\n")); return ERR_ARG; 8034212: 24f2 movs r4, #242 ; 0xf2 8034214: e002 b.n 803421c /* We don't re-send arp request in etharp_tmr, but we still queue packets, since this failure could be temporary, and the next packet calling etharp_query again could lead to sending the queued packets. */ } if (q == NULL) { return result; 8034216: 4604 mov r4, r0 8034218: e000 b.n 803421c /* we have a valid IP->Ethernet address mapping */ ETHARP_SET_HINT(netif, i); /* send the packet */ result = etharp_send_ip(netif, q, srcaddr, &(arp_table[i].ethaddr)); /* pending entry? (either just created or already pending */ } else if (arp_table[i].state == ETHARP_STATE_PENDING) { 803421a: 4614 mov r4, r2 803421c: b260 sxtb r0, r4 803421e: e8bd 81f0 ldmia.w sp!, {r4, r5, r6, r7, r8, pc} } } } else { /* referencing the old pbuf is enough */ p = q; pbuf_ref(p); 8034222: 4628 mov r0, r5 8034224: f7f8 ffe1 bl 802d1ea } /* packet could be taken over? */ if (p != NULL) { 8034228: 2d00 cmp r5, #0 803422a: d1e3 bne.n 80341f4 803422c: e007 b.n 803423e } p = p->next; } if(copy_needed) { /* copy the whole packet into new pbufs */ p = pbuf_alloc(PBUF_RAW, p->tot_len, PBUF_RAM); 803422e: 2003 movs r0, #3 8034230: 8919 ldrh r1, [r3, #8] 8034232: 2200 movs r2, #0 8034234: f7f8 ff49 bl 802d0ca if(p != NULL) { 8034238: 4606 mov r6, r0 803423a: 2800 cmp r0, #0 803423c: d1d2 bne.n 80341e4 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: queued packet %p on ARP entry %"S16_F"\n", (void *)q, (s16_t)i)); #endif /* ARP_QUEUEING */ } else { ETHARP_STATS_INC(etharp.memerr); LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_query: could not queue a copy of PBUF_REF packet %p (out of memory)\n", (void *)q)); result = ERR_MEM; 803423e: 24ff movs r4, #255 ; 0xff 8034240: e7ec b.n 803421c 8034242: bf00 nop 8034244: 2000e410 .word 0x2000e410 8034248: 2000e40c .word 0x2000e40c 0803424c : /** Just a small helper function that sends a pbuf to an ethernet address * in the arp_table specified by the index 'arp_idx'. */ static err_t etharp_output_to_arp_index(struct netif *netif, struct pbuf *q, u8_t arp_idx) { 803424c: e92d 41f0 stmdb sp!, {r4, r5, r6, r7, r8, lr} LWIP_ASSERT("arp_table[arp_idx].state >= ETHARP_STATE_STABLE", arp_table[arp_idx].state >= ETHARP_STATE_STABLE); /* if arp table entry is about to expire: re-request it, but only if its state is ETHARP_STATE_STABLE to prevent flooding the network with ARP requests if this address is used frequently. */ if ((arp_table[arp_idx].state == ETHARP_STATE_STABLE) && 8034250: 4b10 ldr r3, [pc, #64] ; (8034294 ) /** Just a small helper function that sends a pbuf to an ethernet address * in the arp_table specified by the index 'arp_idx'. */ static err_t etharp_output_to_arp_index(struct netif *netif, struct pbuf *q, u8_t arp_idx) { 8034252: 4615 mov r5, r2 LWIP_ASSERT("arp_table[arp_idx].state >= ETHARP_STATE_STABLE", arp_table[arp_idx].state >= ETHARP_STATE_STABLE); /* if arp table entry is about to expire: re-request it, but only if its state is ETHARP_STATE_STABLE to prevent flooding the network with ARP requests if this address is used frequently. */ if ((arp_table[arp_idx].state == ETHARP_STATE_STABLE) && 8034254: 2214 movs r2, #20 /** Just a small helper function that sends a pbuf to an ethernet address * in the arp_table specified by the index 'arp_idx'. */ static err_t etharp_output_to_arp_index(struct netif *netif, struct pbuf *q, u8_t arp_idx) { 8034256: 460e mov r6, r1 LWIP_ASSERT("arp_table[arp_idx].state >= ETHARP_STATE_STABLE", arp_table[arp_idx].state >= ETHARP_STATE_STABLE); /* if arp table entry is about to expire: re-request it, but only if its state is ETHARP_STATE_STABLE to prevent flooding the network with ARP requests if this address is used frequently. */ if ((arp_table[arp_idx].state == ETHARP_STATE_STABLE) && 8034258: fb02 3105 mla r1, r2, r5, r3 /** Just a small helper function that sends a pbuf to an ethernet address * in the arp_table specified by the index 'arp_idx'. */ static err_t etharp_output_to_arp_index(struct netif *netif, struct pbuf *q, u8_t arp_idx) { 803425c: 4607 mov r7, r0 LWIP_ASSERT("arp_table[arp_idx].state >= ETHARP_STATE_STABLE", arp_table[arp_idx].state >= ETHARP_STATE_STABLE); /* if arp table entry is about to expire: re-request it, but only if its state is ETHARP_STATE_STABLE to prevent flooding the network with ARP requests if this address is used frequently. */ if ((arp_table[arp_idx].state == ETHARP_STATE_STABLE) && 803425e: 7c8a ldrb r2, [r1, #18] 8034260: 2a02 cmp r2, #2 8034262: f101 0410 add.w r4, r1, #16 8034266: d108 bne.n 803427a 8034268: 7cca ldrb r2, [r1, #19] 803426a: 2ae3 cmp r2, #227 ; 0xe3 803426c: d905 bls.n 803427a (arp_table[arp_idx].ctime >= ARP_AGE_REREQUEST_USED)) { if (etharp_request(netif, &arp_table[arp_idx].ipaddr) == ERR_OK) { 803426e: 3104 adds r1, #4 8034270: f7ff ff16 bl 80340a0 8034274: b908 cbnz r0, 803427a arp_table[arp_idx].state = ETHARP_STATE_STABLE_REREQUESTING; 8034276: 2303 movs r3, #3 8034278: 70a3 strb r3, [r4, #2] } } return etharp_send_ip(netif, q, (struct eth_addr*)(netif->hwaddr), 803427a: 4b06 ldr r3, [pc, #24] ; (8034294 ) 803427c: 2214 movs r2, #20 803427e: fb02 3305 mla r3, r2, r5, r3 8034282: 4638 mov r0, r7 8034284: 4631 mov r1, r6 8034286: f107 0227 add.w r2, r7, #39 ; 0x27 803428a: 330c adds r3, #12 &arp_table[arp_idx].ethaddr); } 803428c: e8bd 41f0 ldmia.w sp!, {r4, r5, r6, r7, r8, lr} if (etharp_request(netif, &arp_table[arp_idx].ipaddr) == ERR_OK) { arp_table[arp_idx].state = ETHARP_STATE_STABLE_REREQUESTING; } } return etharp_send_ip(netif, q, (struct eth_addr*)(netif->hwaddr), 8034290: f7ff be14 b.w 8033ebc 8034294: 2000e410 .word 0x2000e410 08034298 : * - ERR_RTE No route to destination (no gateway to external networks), * or the return type of either etharp_query() or etharp_send_ip(). */ err_t etharp_output(struct netif *netif, struct pbuf *q, ip_addr_t *ipaddr) { 8034298: b5f7 push {r0, r1, r2, r4, r5, r6, r7, lr} 803429a: 4604 mov r4, r0 803429c: 460e mov r6, r1 LWIP_ASSERT("netif != NULL", netif != NULL); LWIP_ASSERT("q != NULL", q != NULL); LWIP_ASSERT("ipaddr != NULL", ipaddr != NULL); /* make room for Ethernet header - should not fail */ if (pbuf_header(q, sizeof(struct eth_hdr)) != 0) { 803429e: 4608 mov r0, r1 80342a0: 210e movs r1, #14 * - ERR_RTE No route to destination (no gateway to external networks), * or the return type of either etharp_query() or etharp_send_ip(). */ err_t etharp_output(struct netif *netif, struct pbuf *q, ip_addr_t *ipaddr) { 80342a2: 4615 mov r5, r2 LWIP_ASSERT("netif != NULL", netif != NULL); LWIP_ASSERT("q != NULL", q != NULL); LWIP_ASSERT("ipaddr != NULL", ipaddr != NULL); /* make room for Ethernet header - should not fail */ if (pbuf_header(q, sizeof(struct eth_hdr)) != 0) { 80342a4: f7f8 fe99 bl 802cfda 80342a8: 2800 cmp r0, #0 80342aa: d163 bne.n 8034374 /* Determine on destination hardware address. Broadcasts and multicasts * are special, other IP addresses are looked up in the ARP table. */ /* broadcast destination IP address? */ if (ip_addr_isbroadcast(ipaddr, netif)) { 80342ac: 6828 ldr r0, [r5, #0] 80342ae: 4621 mov r1, r4 80342b0: f7fb fd58 bl 802fd64 80342b4: 2800 cmp r0, #0 80342b6: d155 bne.n 8034364 /* broadcast on Ethernet also */ dest = (struct eth_addr *)ðbroadcast; /* multicast destination IP address? */ } else if (ip_addr_ismulticast(ipaddr)) { 80342b8: 682b ldr r3, [r5, #0] 80342ba: f003 02f0 and.w r2, r3, #240 ; 0xf0 80342be: 2ae0 cmp r2, #224 ; 0xe0 80342c0: d114 bne.n 80342ec /* Hash IP multicast address to MAC address.*/ mcastaddr.addr[0] = LL_MULTICAST_ADDR_0; 80342c2: 2301 movs r3, #1 80342c4: f88d 3000 strb.w r3, [sp] mcastaddr.addr[1] = LL_MULTICAST_ADDR_1; mcastaddr.addr[2] = LL_MULTICAST_ADDR_2; 80342c8: 235e movs r3, #94 ; 0x5e 80342ca: f88d 3002 strb.w r3, [sp, #2] mcastaddr.addr[3] = ip4_addr2(ipaddr) & 0x7f; 80342ce: 786b ldrb r3, [r5, #1] dest = (struct eth_addr *)ðbroadcast; /* multicast destination IP address? */ } else if (ip_addr_ismulticast(ipaddr)) { /* Hash IP multicast address to MAC address.*/ mcastaddr.addr[0] = LL_MULTICAST_ADDR_0; mcastaddr.addr[1] = LL_MULTICAST_ADDR_1; 80342d0: f88d 0001 strb.w r0, [sp, #1] mcastaddr.addr[2] = LL_MULTICAST_ADDR_2; mcastaddr.addr[3] = ip4_addr2(ipaddr) & 0x7f; 80342d4: f003 037f and.w r3, r3, #127 ; 0x7f 80342d8: f88d 3003 strb.w r3, [sp, #3] mcastaddr.addr[4] = ip4_addr3(ipaddr); 80342dc: 78ab ldrb r3, [r5, #2] 80342de: f88d 3004 strb.w r3, [sp, #4] mcastaddr.addr[5] = ip4_addr4(ipaddr); 80342e2: 78eb ldrb r3, [r5, #3] 80342e4: f88d 3005 strb.w r3, [sp, #5] /* destination Ethernet address is multicast */ dest = &mcastaddr; 80342e8: 466b mov r3, sp 80342ea: e03c b.n 8034366 /* unicast destination IP address? */ } else { s8_t i; /* outside local network? if so, this can neither be a global broadcast nor a subnet broadcast. */ if (!ip_addr_netcmp(ipaddr, &(netif->ip_addr), &(netif->netmask)) && 80342ec: 6862 ldr r2, [r4, #4] 80342ee: ea83 0102 eor.w r1, r3, r2 80342f2: 68a2 ldr r2, [r4, #8] 80342f4: 4211 tst r1, r2 80342f6: d009 beq.n 803430c !ip_addr_islinklocal(ipaddr)) { 80342f8: b29b uxth r3, r3 /* unicast destination IP address? */ } else { s8_t i; /* outside local network? if so, this can neither be a global broadcast nor a subnet broadcast. */ if (!ip_addr_netcmp(ipaddr, &(netif->ip_addr), &(netif->netmask)) && 80342fa: f64f 62a9 movw r2, #65193 ; 0xfea9 80342fe: 4293 cmp r3, r2 8034300: d004 beq.n 803430c router for forwarding". */ if (!ip_addr_islinklocal(&iphdr->src)) #endif /* LWIP_AUTOIP */ { /* interface has default gateway? */ if (!ip_addr_isany(&netif->gw)) { 8034302: 68e3 ldr r3, [r4, #12] 8034304: f104 010c add.w r1, r4, #12 8034308: b90b cbnz r3, 803430e 803430a: e035 b.n 8034378 /* unicast destination IP address? */ } else { s8_t i; /* outside local network? if so, this can neither be a global broadcast nor a subnet broadcast. */ if (!ip_addr_netcmp(ipaddr, &(netif->ip_addr), &(netif->netmask)) && 803430c: 4629 mov r1, r5 if (netif->addr_hint != NULL) { /* per-pcb cached entry was given */ u8_t etharp_cached_entry = *(netif->addr_hint); if (etharp_cached_entry < ARP_TABLE_SIZE) { #endif /* LWIP_NETIF_HWADDRHINT */ if ((arp_table[etharp_cached_entry].state >= ETHARP_STATE_STABLE) && 803430e: 4b1c ldr r3, [pc, #112] ; (8034380 ) 8034310: 781a ldrb r2, [r3, #0] 8034312: 4b1c ldr r3, [pc, #112] ; (8034384 ) 8034314: 2014 movs r0, #20 8034316: fb00 3302 mla r3, r0, r2, r3 803431a: 7c98 ldrb r0, [r3, #18] 803431c: 2801 cmp r0, #1 803431e: d904 bls.n 803432a 8034320: 6808 ldr r0, [r1, #0] 8034322: 685b ldr r3, [r3, #4] 8034324: 4298 cmp r0, r3 8034326: d100 bne.n 803432a 8034328: e00d b.n 8034346 803432a: 2300 movs r3, #0 * @return * - ERR_RTE No route to destination (no gateway to external networks), * or the return type of either etharp_query() or etharp_send_ip(). */ err_t etharp_output(struct netif *netif, struct pbuf *q, ip_addr_t *ipaddr) 803432c: 4f15 ldr r7, [pc, #84] ; (8034384 ) if (netif->addr_hint != NULL) { /* per-pcb cached entry was given */ u8_t etharp_cached_entry = *(netif->addr_hint); if (etharp_cached_entry < ARP_TABLE_SIZE) { #endif /* LWIP_NETIF_HWADDRHINT */ if ((arp_table[etharp_cached_entry].state >= ETHARP_STATE_STABLE) && 803432e: 461a mov r2, r3 * @return * - ERR_RTE No route to destination (no gateway to external networks), * or the return type of either etharp_query() or etharp_send_ip(). */ err_t etharp_output(struct netif *netif, struct pbuf *q, ip_addr_t *ipaddr) 8034330: 18f8 adds r0, r7, r3 #endif /* LWIP_NETIF_HWADDRHINT */ /* find stable entry: do this here since this is a critical path for throughput and etharp_find_entry() is kind of slow */ for (i = 0; i < ARP_TABLE_SIZE; i++) { if ((arp_table[i].state >= ETHARP_STATE_STABLE) && 8034332: 7c85 ldrb r5, [r0, #18] 8034334: 2d01 cmp r5, #1 8034336: d90b bls.n 8034350 8034338: 680d ldr r5, [r1, #0] 803433a: 6840 ldr r0, [r0, #4] 803433c: 4285 cmp r5, r0 803433e: d107 bne.n 8034350 (ip_addr_cmp(dst_addr, &arp_table[i].ipaddr))) { /* found an existing, stable entry */ ETHARP_SET_HINT(netif, i); 8034340: 4b0f ldr r3, [pc, #60] ; (8034380 ) 8034342: b2d2 uxtb r2, r2 8034344: 701a strb r2, [r3, #0] return etharp_output_to_arp_index(netif, q, i); 8034346: 4620 mov r0, r4 8034348: 4631 mov r1, r6 803434a: f7ff ff7f bl 803424c 803434e: e014 b.n 803437a 8034350: 3314 adds r3, #20 } #endif /* LWIP_NETIF_HWADDRHINT */ /* find stable entry: do this here since this is a critical path for throughput and etharp_find_entry() is kind of slow */ for (i = 0; i < ARP_TABLE_SIZE; i++) { 8034352: 3201 adds r2, #1 8034354: 2bc8 cmp r3, #200 ; 0xc8 8034356: b2d2 uxtb r2, r2 8034358: d1ea bne.n 8034330 return etharp_output_to_arp_index(netif, q, i); } } /* no stable entry found, use the (slower) query function: queue on destination Ethernet address belonging to ipaddr */ return etharp_query(netif, dst_addr, q); 803435a: 4620 mov r0, r4 803435c: 4632 mov r2, r6 803435e: f7ff fef5 bl 803414c 8034362: e00a b.n 803437a * are special, other IP addresses are looked up in the ARP table. */ /* broadcast destination IP address? */ if (ip_addr_isbroadcast(ipaddr, netif)) { /* broadcast on Ethernet also */ dest = (struct eth_addr *)ðbroadcast; 8034364: 4b08 ldr r3, [pc, #32] ; (8034388 ) } /* continuation for multicast/broadcast destinations */ /* obtain source Ethernet address of the given interface */ /* send packet directly on the link */ return etharp_send_ip(netif, q, (struct eth_addr*)(netif->hwaddr), dest); 8034366: 4620 mov r0, r4 8034368: 4631 mov r1, r6 803436a: f104 0227 add.w r2, r4, #39 ; 0x27 803436e: f7ff fda5 bl 8033ebc 8034372: e002 b.n 803437a if (pbuf_header(q, sizeof(struct eth_hdr)) != 0) { /* bail out */ LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_LEVEL_SERIOUS, ("etharp_output: could not allocate room for header.\n")); LINK_STATS_INC(link.lenerr); return ERR_BUF; 8034374: 20fe movs r0, #254 ; 0xfe 8034376: e000 b.n 803437a /* send to hardware address of default gateway IP address */ dst_addr = &(netif->gw); /* no default gateway available */ } else { /* no route to destination error (default gateway missing) */ return ERR_RTE; 8034378: 20fc movs r0, #252 ; 0xfc /* continuation for multicast/broadcast destinations */ /* obtain source Ethernet address of the given interface */ /* send packet directly on the link */ return etharp_send_ip(netif, q, (struct eth_addr*)(netif->hwaddr), dest); } 803437a: b240 sxtb r0, r0 803437c: bdfe pop {r1, r2, r3, r4, r5, r6, r7, pc} 803437e: bf00 nop 8034380: 2000e40c .word 0x2000e40c 8034384: 2000e410 .word 0x2000e410 8034388: 080407b7 .word 0x080407b7 0803438c : * @param p the recevied packet, p->payload pointing to the ethernet header * @param netif the network interface on which the packet was received */ err_t ethernet_input(struct pbuf *p, struct netif *netif) { 803438c: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} u16_t type; #if LWIP_ARP || ETHARP_SUPPORT_VLAN s16_t ip_hdr_offset = SIZEOF_ETH_HDR; #endif /* LWIP_ARP || ETHARP_SUPPORT_VLAN */ if (p->len <= SIZEOF_ETH_HDR) { 8034390: 8943 ldrh r3, [r0, #10] 8034392: 2b0e cmp r3, #14 * @param p the recevied packet, p->payload pointing to the ethernet header * @param netif the network interface on which the packet was received */ err_t ethernet_input(struct pbuf *p, struct netif *netif) { 8034394: b087 sub sp, #28 8034396: 4604 mov r4, r0 8034398: 460d mov r5, r1 u16_t type; #if LWIP_ARP || ETHARP_SUPPORT_VLAN s16_t ip_hdr_offset = SIZEOF_ETH_HDR; #endif /* LWIP_ARP || ETHARP_SUPPORT_VLAN */ if (p->len <= SIZEOF_ETH_HDR) { 803439a: f240 80ed bls.w 8034578 ETHARP_STATS_INC(etharp.drop); goto free_and_return; } /* points to packet payload, which starts with an Ethernet header */ ethhdr = (struct eth_hdr *)p->payload; 803439e: 6840 ldr r0, [r0, #4] #if LWIP_ARP_FILTER_NETIF netif = LWIP_ARP_FILTER_NETIF_FN(p, netif, htons(type)); #endif /* LWIP_ARP_FILTER_NETIF*/ if (ethhdr->dest.addr[0] & 1) { 80343a0: 7803 ldrb r3, [r0, #0] (unsigned)ethhdr->dest.addr[3], (unsigned)ethhdr->dest.addr[4], (unsigned)ethhdr->dest.addr[5], (unsigned)ethhdr->src.addr[0], (unsigned)ethhdr->src.addr[1], (unsigned)ethhdr->src.addr[2], (unsigned)ethhdr->src.addr[3], (unsigned)ethhdr->src.addr[4], (unsigned)ethhdr->src.addr[5], (unsigned)htons(ethhdr->type))); type = ethhdr->type; 80343a2: 8986 ldrh r6, [r0, #12] #if LWIP_ARP_FILTER_NETIF netif = LWIP_ARP_FILTER_NETIF_FN(p, netif, htons(type)); #endif /* LWIP_ARP_FILTER_NETIF*/ if (ethhdr->dest.addr[0] & 1) { 80343a4: 07da lsls r2, r3, #31 80343a6: d513 bpl.n 80343d0 /* this might be a multicast or broadcast packet */ if (ethhdr->dest.addr[0] == LL_MULTICAST_ADDR_0) { 80343a8: 2b01 cmp r3, #1 80343aa: d108 bne.n 80343be if ((ethhdr->dest.addr[1] == LL_MULTICAST_ADDR_1) && 80343ac: 7843 ldrb r3, [r0, #1] 80343ae: b97b cbnz r3, 80343d0 80343b0: 7883 ldrb r3, [r0, #2] 80343b2: 2b5e cmp r3, #94 ; 0x5e 80343b4: d10c bne.n 80343d0 (ethhdr->dest.addr[2] == LL_MULTICAST_ADDR_2)) { /* mark the pbuf as link-layer multicast */ p->flags |= PBUF_FLAG_LLMCAST; 80343b6: 7b63 ldrb r3, [r4, #13] 80343b8: f043 0310 orr.w r3, r3, #16 80343bc: e007 b.n 80343ce } } else if (eth_addr_cmp(ðhdr->dest, ðbroadcast)) { 80343be: 4972 ldr r1, [pc, #456] ; (8034588 ) 80343c0: 2206 movs r2, #6 80343c2: f7ed fa91 bl 80218e8 80343c6: b918 cbnz r0, 80343d0 /* mark the pbuf as link-layer broadcast */ p->flags |= PBUF_FLAG_LLBCAST; 80343c8: 7b63 ldrb r3, [r4, #13] 80343ca: f043 0308 orr.w r3, r3, #8 80343ce: 7363 strb r3, [r4, #13] } } switch (type) { 80343d0: 2e08 cmp r6, #8 80343d2: d004 beq.n 80343de 80343d4: f5b6 6fc1 cmp.w r6, #1544 ; 0x608 80343d8: f040 80ce bne.w 8034578 80343dc: e014 b.n 8034408 #if LWIP_ARP /* IP packet? */ case PP_HTONS(ETHTYPE_IP): if (!(netif->flags & NETIF_FLAG_ETHARP)) { 80343de: f895 302d ldrb.w r3, [r5, #45] ; 0x2d 80343e2: f003 0320 and.w r3, r3, #32 80343e6: b2db uxtb r3, r3 80343e8: 2b00 cmp r3, #0 80343ea: f000 80c5 beq.w 8034578 #if ETHARP_TRUST_IP_MAC /* update ARP table */ etharp_ip_input(netif, p); #endif /* ETHARP_TRUST_IP_MAC */ /* skip Ethernet header */ if(pbuf_header(p, -ip_hdr_offset)) { 80343ee: 4620 mov r0, r4 80343f0: f06f 010d mvn.w r1, #13 80343f4: f7f8 fdf1 bl 802cfda 80343f8: 2800 cmp r0, #0 80343fa: f040 80bd bne.w 8034578 LWIP_ASSERT("Can't move over header in packet", 0); goto free_and_return; } else { /* pass to IP layer */ ip_input(p, netif); 80343fe: 4620 mov r0, r4 8034400: 4629 mov r1, r5 8034402: f7fb fdc3 bl 802ff8c } break; 8034406: e0ba b.n 803457e case PP_HTONS(ETHTYPE_ARP): if (!(netif->flags & NETIF_FLAG_ETHARP)) { 8034408: f895 302d ldrb.w r3, [r5, #45] ; 0x2d 803440c: f003 0320 and.w r3, r3, #32 8034410: b2db uxtb r3, r3 8034412: 2b00 cmp r3, #0 8034414: f000 80b0 beq.w 8034578 LWIP_ERROR("netif != NULL", (netif != NULL), return;); /* drop short ARP packets: we have to check for p->len instead of p->tot_len here since a struct etharp_hdr is pointed to p->payload, so it musn't be chained! */ if (p->len < SIZEOF_ETHARP_PACKET) { 8034418: 8963 ldrh r3, [r4, #10] 803441a: 2b29 cmp r3, #41 ; 0x29 803441c: d800 bhi.n 8034420 803441e: e0ab b.n 8034578 ETHARP_STATS_INC(etharp.drop); pbuf_free(p); return; } ethhdr = (struct eth_hdr *)p->payload; 8034420: 6866 ldr r6, [r4, #4] hdr = (struct etharp_hdr *)(((u8_t*)ethhdr) + SIZEOF_ETH_HDR + SIZEOF_VLAN_HDR); } #endif /* ETHARP_SUPPORT_VLAN */ /* RFC 826 "Packet Reception": */ if ((hdr->hwtype != PP_HTONS(HWTYPE_ETHERNET)) || 8034422: 89f3 ldrh r3, [r6, #14] 8034424: f5b3 7f80 cmp.w r3, #256 ; 0x100 8034428: f040 80a6 bne.w 8034578 803442c: 7cb3 ldrb r3, [r6, #18] 803442e: 2b06 cmp r3, #6 8034430: f040 80a2 bne.w 8034578 (hdr->hwlen != ETHARP_HWADDR_LEN) || 8034434: 7cf7 ldrb r7, [r6, #19] 8034436: 2f04 cmp r7, #4 8034438: f040 809e bne.w 8034578 (hdr->protolen != sizeof(ip_addr_t)) || 803443c: 8a33 ldrh r3, [r6, #16] 803443e: 2b08 cmp r3, #8 8034440: f040 809a bne.w 8034578 autoip_arp_reply(netif, hdr); #endif /* LWIP_AUTOIP */ /* Copy struct ip_addr2 to aligned ip_addr, to support compilers without * structure packing (not using structure copy which breaks strict-aliasing rules). */ IPADDR2_COPY(&sipaddr, &hdr->sipaddr); 8034444: f106 0a1c add.w sl, r6, #28 8034448: 4651 mov r1, sl 803444a: 463a mov r2, r7 803444c: a804 add r0, sp, #16 803444e: f7ed fa7d bl 802194c IPADDR2_COPY(&dipaddr, &hdr->dipaddr); 8034452: f106 0226 add.w r2, r6, #38 ; 0x26 8034456: 9203 str r2, [sp, #12] 8034458: 4611 mov r1, r2 803445a: a805 add r0, sp, #20 803445c: 463a mov r2, r7 803445e: f7ed fa75 bl 802194c /* this interface is not configured? */ if (ip_addr_isany(&netif->ip_addr)) { 8034462: 686b ldr r3, [r5, #4] 8034464: b12b cbz r3, 8034472 for_us = 0; } else { /* ARP packet directed to us? */ for_us = (u8_t)ip_addr_cmp(&dipaddr, &(netif->ip_addr)); 8034466: 9a05 ldr r2, [sp, #20] 8034468: 1ad1 subs r1, r2, r3 803446a: 424a negs r2, r1 803446c: 414a adcs r2, r1 803446e: 9201 str r2, [sp, #4] 8034470: e000 b.n 8034474 IPADDR2_COPY(&sipaddr, &hdr->sipaddr); IPADDR2_COPY(&dipaddr, &hdr->dipaddr); /* this interface is not configured? */ if (ip_addr_isany(&netif->ip_addr)) { for_us = 0; 8034472: 9301 str r3, [sp, #4] /* ARP message directed to us? -> add IP address in ARP cache; assume requester wants to talk to us, can result in directly sending the queued packets for this host. ARP message not directed to us? -> update the source IP address in the cache, if present */ etharp_update_arp_entry(netif, &sipaddr, &(hdr->shwaddr), 8034474: 9b01 ldr r3, [sp, #4] LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_update_arp_entry: %"U16_F".%"U16_F".%"U16_F".%"U16_F" - %02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F"\n", ip4_addr1_16(ipaddr), ip4_addr2_16(ipaddr), ip4_addr3_16(ipaddr), ip4_addr4_16(ipaddr), ethaddr->addr[0], ethaddr->addr[1], ethaddr->addr[2], ethaddr->addr[3], ethaddr->addr[4], ethaddr->addr[5])); /* non-unicast address? */ if (ip_addr_isany(ipaddr) || 8034476: 9804 ldr r0, [sp, #16] /* ARP message directed to us? -> add IP address in ARP cache; assume requester wants to talk to us, can result in directly sending the queued packets for this host. ARP message not directed to us? -> update the source IP address in the cache, if present */ etharp_update_arp_entry(netif, &sipaddr, &(hdr->shwaddr), 8034478: f106 0716 add.w r7, r6, #22 803447c: 2b00 cmp r3, #0 803447e: bf0c ite eq 8034480: f04f 0802 moveq.w r8, #2 8034484: f04f 0801 movne.w r8, #1 case PP_HTONS(ETHTYPE_ARP): if (!(netif->flags & NETIF_FLAG_ETHARP)) { goto free_and_return; } /* pass p to ARP module */ etharp_arp_input(netif, (struct eth_addr*)(netif->hwaddr), p); 8034488: f105 0927 add.w r9, r5, #39 ; 0x27 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_update_arp_entry: %"U16_F".%"U16_F".%"U16_F".%"U16_F" - %02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F"\n", ip4_addr1_16(ipaddr), ip4_addr2_16(ipaddr), ip4_addr3_16(ipaddr), ip4_addr4_16(ipaddr), ethaddr->addr[0], ethaddr->addr[1], ethaddr->addr[2], ethaddr->addr[3], ethaddr->addr[4], ethaddr->addr[5])); /* non-unicast address? */ if (ip_addr_isany(ipaddr) || 803448c: 2800 cmp r0, #0 803448e: d03d beq.n 803450c ip_addr_isbroadcast(ipaddr, netif) || 8034490: 4629 mov r1, r5 8034492: f7fb fc67 bl 802fd64 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_update_arp_entry: %"U16_F".%"U16_F".%"U16_F".%"U16_F" - %02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F":%02"X16_F"\n", ip4_addr1_16(ipaddr), ip4_addr2_16(ipaddr), ip4_addr3_16(ipaddr), ip4_addr4_16(ipaddr), ethaddr->addr[0], ethaddr->addr[1], ethaddr->addr[2], ethaddr->addr[3], ethaddr->addr[4], ethaddr->addr[5])); /* non-unicast address? */ if (ip_addr_isany(ipaddr) || 8034496: 9002 str r0, [sp, #8] 8034498: 2800 cmp r0, #0 803449a: d137 bne.n 803450c ip_addr_isbroadcast(ipaddr, netif) || ip_addr_ismulticast(ipaddr)) { 803449c: 9a04 ldr r2, [sp, #16] 803449e: f002 02f0 and.w r2, r2, #240 ; 0xf0 ip4_addr1_16(ipaddr), ip4_addr2_16(ipaddr), ip4_addr3_16(ipaddr), ip4_addr4_16(ipaddr), ethaddr->addr[0], ethaddr->addr[1], ethaddr->addr[2], ethaddr->addr[3], ethaddr->addr[4], ethaddr->addr[5])); /* non-unicast address? */ if (ip_addr_isany(ipaddr) || ip_addr_isbroadcast(ipaddr, netif) || 80344a2: 2ae0 cmp r2, #224 ; 0xe0 80344a4: d032 beq.n 803450c ip_addr_ismulticast(ipaddr)) { LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_update_arp_entry: will not add non-unicast IP address to ARP cache\n")); return ERR_ARG; } /* find or create ARP entry */ i = etharp_find_entry(ipaddr, flags); 80344a6: a804 add r0, sp, #16 80344a8: 4641 mov r1, r8 80344aa: f7ff fd39 bl 8033f20 /* bail out if no entry could be found */ if (i < 0) { 80344ae: 2800 cmp r0, #0 80344b0: db2c blt.n 803450c arp_table[i].state = ETHARP_STATE_STATIC; } else #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ { /* mark it stable */ arp_table[i].state = ETHARP_STATE_STABLE; 80344b2: 4b36 ldr r3, [pc, #216] ; (803458c ) 80344b4: f04f 0814 mov.w r8, #20 80344b8: fb08 f800 mul.w r8, r8, r0 80344bc: eb03 0108 add.w r1, r3, r8 80344c0: 2202 movs r2, #2 80344c2: 748a strb r2, [r1, #18] } /* record network interface */ arp_table[i].netif = netif; 80344c4: 608d str r5, [r1, #8] arp_table[i].state = ETHARP_STATE_STATIC; } else #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ { /* mark it stable */ arp_table[i].state = ETHARP_STATE_STABLE; 80344c6: f101 0b10 add.w fp, r1, #16 } /* record network interface */ arp_table[i].netif = netif; /* insert in SNMP ARP index tree */ snmp_insert_arpidx_tree(netif, &arp_table[i].ipaddr); 80344ca: 4628 mov r0, r5 80344cc: 3104 adds r1, #4 80344ce: 9300 str r3, [sp, #0] 80344d0: f7fd f90e bl 80316f0 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_update_arp_entry: updating stable entry %"S16_F"\n", (s16_t)i)); /* update address */ ETHADDR32_COPY(&arp_table[i].ethaddr, ethaddr); 80344d4: 9b00 ldr r3, [sp, #0] 80344d6: eb03 0008 add.w r0, r3, r8 80344da: 2206 movs r2, #6 80344dc: 300c adds r0, #12 80344de: 4639 mov r1, r7 80344e0: f7ed fa34 bl 802194c /* reset time stamp */ arp_table[i].ctime = 0; 80344e4: 9a02 ldr r2, [sp, #8] 80344e6: f88b 2003 strb.w r2, [fp, #3] /* get the packet pointer */ p = q->p; /* now queue entry can be freed */ memp_free(MEMP_ARP_QUEUE, q); #else /* ARP_QUEUEING */ if (arp_table[i].q != NULL) { 80344ea: 9b00 ldr r3, [sp, #0] 80344ec: f853 b008 ldr.w fp, [r3, r8] 80344f0: f1bb 0f00 cmp.w fp, #0 80344f4: d00a beq.n 803450c struct pbuf *p = arp_table[i].q; arp_table[i].q = NULL; 80344f6: f843 2008 str.w r2, [r3, r8] #endif /* ARP_QUEUEING */ /* send the queued IP packet */ etharp_send_ip(netif, p, (struct eth_addr*)(netif->hwaddr), ethaddr); 80344fa: 4628 mov r0, r5 80344fc: 4659 mov r1, fp 80344fe: 464a mov r2, r9 8034500: 463b mov r3, r7 8034502: f7ff fcdb bl 8033ebc /* free the queued IP packet */ pbuf_free(p); 8034506: 4658 mov r0, fp 8034508: f7f8 fd92 bl 802d030 -> update the source IP address in the cache, if present */ etharp_update_arp_entry(netif, &sipaddr, &(hdr->shwaddr), for_us ? ETHARP_FLAG_TRY_HARD : ETHARP_FLAG_FIND_ONLY); /* now act on the message itself */ switch (hdr->opcode) { 803450c: 8ab3 ldrh r3, [r6, #20] 803450e: f5b3 7f80 cmp.w r3, #256 ; 0x100 8034512: d003 beq.n 803451c 8034514: f5b3 7f00 cmp.w r3, #512 ; 0x200 8034518: d12e bne.n 8034578 803451a: e029 b.n 8034570 * reply. In any case, we time-stamp any existing ARP entry, * and possiby send out an IP packet that was queued on it. */ LWIP_DEBUGF (ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_arp_input: incoming ARP request\n")); /* ARP request for our address? */ if (for_us) { 803451c: 9b01 ldr r3, [sp, #4] 803451e: b35b cbz r3, 8034578 LWIP_DEBUGF(ETHARP_DEBUG | LWIP_DBG_TRACE, ("etharp_arp_input: replying to ARP request for our IP address\n")); /* Re-use pbuf to send ARP reply. Since we are re-using an existing pbuf, we can't call etharp_raw since that would allocate a new pbuf. */ hdr->opcode = htons(ARP_REPLY); 8034520: 2002 movs r0, #2 8034522: f7f7 fc47 bl 802bdb4 8034526: 82b0 strh r0, [r6, #20] IPADDR2_COPY(&hdr->dipaddr, &hdr->sipaddr); 8034528: 4651 mov r1, sl 803452a: 2204 movs r2, #4 803452c: 9803 ldr r0, [sp, #12] 803452e: f7ed fa0d bl 802194c IPADDR2_COPY(&hdr->sipaddr, &netif->ip_addr); 8034532: 1d29 adds r1, r5, #4 8034534: 2204 movs r2, #4 8034536: 4650 mov r0, sl 8034538: f7ed fa08 bl 802194c * 'sender IP address' MUST be sent using link-layer broadcast instead of * link-layer unicast. (See RFC3927 Section 2.5, last paragraph) */ ethdst_hwaddr = ip_addr_islinklocal(&netif->ip_addr) ? (u8_t*)(ethbroadcast.addr) : hdr->shwaddr.addr; #endif /* LWIP_AUTOIP */ ETHADDR16_COPY(&hdr->dhwaddr, &hdr->shwaddr); 803453c: 4639 mov r1, r7 803453e: 2206 movs r2, #6 8034540: f106 0020 add.w r0, r6, #32 8034544: f7ed fa02 bl 802194c #if LWIP_AUTOIP ETHADDR16_COPY(ðhdr->dest, ethdst_hwaddr); #else /* LWIP_AUTOIP */ ETHADDR16_COPY(ðhdr->dest, &hdr->shwaddr); 8034548: 4639 mov r1, r7 803454a: 2206 movs r2, #6 803454c: 4630 mov r0, r6 803454e: f7ed f9fd bl 802194c #endif /* LWIP_AUTOIP */ ETHADDR16_COPY(&hdr->shwaddr, ethaddr); 8034552: 4649 mov r1, r9 8034554: 2206 movs r2, #6 8034556: 4638 mov r0, r7 8034558: f7ed f9f8 bl 802194c ETHADDR16_COPY(ðhdr->src, ethaddr); 803455c: 4649 mov r1, r9 803455e: 1db0 adds r0, r6, #6 8034560: 2206 movs r2, #6 8034562: f7ed f9f3 bl 802194c /* hwtype, hwaddr_len, proto, protolen and the type in the ethernet header are already correct, we tested that before */ /* return ARP reply */ netif->linkoutput(netif, p); 8034566: 69ab ldr r3, [r5, #24] 8034568: 4628 mov r0, r5 803456a: 4621 mov r1, r4 803456c: 4798 blx r3 803456e: e003 b.n 8034578 #if (LWIP_DHCP && DHCP_DOES_ARP_CHECK) /* DHCP wants to know about ARP replies from any host with an * IP address also offered to us by the DHCP server. We do not * want to take a duplicate IP address on a single network. * @todo How should we handle redundant (fail-over) interfaces? */ dhcp_arp_reply(netif, &sipaddr); 8034570: 4628 mov r0, r5 8034572: a904 add r1, sp, #16 8034574: f7f8 f8f4 bl 802c760 /* This means the pbuf is freed or consumed, so the caller doesn't have to free it again */ return ERR_OK; free_and_return: pbuf_free(p); 8034578: 4620 mov r0, r4 803457a: f7f8 fd59 bl 802d030 return ERR_OK; } 803457e: 2000 movs r0, #0 8034580: b007 add sp, #28 8034582: e8bd 8ff0 ldmia.w sp!, {r4, r5, r6, r7, r8, r9, sl, fp, pc} 8034586: bf00 nop 8034588: 080407b7 .word 0x080407b7 803458c: 2000e410 .word 0x2000e410 08034590 : return ERR_OK; } static void arp_timer(void *arg) { 8034590: b508 push {r3, lr} etharp_tmr(); 8034592: f7ff fd37 bl 8034004 sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 8034596: 4904 ldr r1, [pc, #16] ; (80345a8 ) 8034598: f241 3088 movw r0, #5000 ; 0x1388 803459c: 2200 movs r2, #0 } 803459e: e8bd 4008 ldmia.w sp!, {r3, lr} static void arp_timer(void *arg) { etharp_tmr(); sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 80345a2: f7fa bfcb b.w 802f53c 80345a6: bf00 nop 80345a8: 08034591 .word 0x08034591 080345ac : } } */ void ethernetif_input(void * pvParameters) { 80345ac: e92d 4ff0 stmdb sp!, {r4, r5, r6, r7, r8, r9, sl, fp, lr} struct pbuf *p; for( ;; ) { if(xSemaphoreTake(s_xSemaphore, emacBLOCK_TIME_WAITING_FOR_INPUT)==pdTRUE) 80345b0: f8df 80c4 ldr.w r8, [pc, #196] ; 8034678 } } */ void ethernetif_input(void * pvParameters) { 80345b4: b085 sub sp, #20 struct pbuf *p; for( ;; ) { if(xSemaphoreTake(s_xSemaphore, emacBLOCK_TIME_WAITING_FOR_INPUT)==pdTRUE) 80345b6: 2100 movs r1, #0 80345b8: 2264 movs r2, #100 ; 0x64 80345ba: f8d8 0000 ldr.w r0, [r8] 80345be: 460b mov r3, r1 80345c0: f7f4 fdd4 bl 802916c 80345c4: 2801 cmp r0, #1 80345c6: d1f6 bne.n 80345b6 } } /* Release descriptors to DMA */ /* Check if received frame with multiple DMA buffer segments */ if (DMA_RX_FRAME_infos->Seg_Count > 1) 80345c8: f8df a0b0 ldr.w sl, [pc, #176] ; 803467c /* Clear Segment_Count */ DMA_RX_FRAME_infos->Seg_Count =0; /* When Rx Buffer unavailable flag is set: clear it and resume reception */ if ((ETH->DMASR & ETH_DMASR_RBUS) != (u32)RESET) 80345cc: f8df 90b0 ldr.w r9, [pc, #176] ; 8034680 __IO ETH_DMADESCTypeDef *DMARxNextDesc; p = NULL; /* Get received frame */ frame = ETH_Get_Received_Frame_interrupt(); 80345d0: a801 add r0, sp, #4 80345d2: f000 ff45 bl 8035460 80345d6: 9e03 ldr r6, [sp, #12] /* check that frame has no error */ if ((frame.descriptor->Status & ETH_DMARxDesc_ES) == (uint32_t)RESET) 80345d8: 6837 ldr r7, [r6, #0] 80345da: f417 4700 ands.w r7, r7, #32768 ; 0x8000 80345de: d001 beq.n 80345e4 uint32_t l=0,i =0; FrameTypeDef frame; u8 *buffer; __IO ETH_DMADESCTypeDef *DMARxNextDesc; p = NULL; 80345e0: 2400 movs r4, #0 80345e2: e016 b.n 8034612 /* Obtain the size of the packet and put it into the "len" variable. */ len = frame.length; buffer = (u8 *)frame.buffer; /* We allocate a pbuf chain of pbufs from the pool. */ p = pbuf_alloc(PBUF_RAW, len, PBUF_POOL); 80345e4: 2003 movs r0, #3 80345e6: f8bd 1004 ldrh.w r1, [sp, #4] if ((frame.descriptor->Status & ETH_DMARxDesc_ES) == (uint32_t)RESET) { /* Obtain the size of the packet and put it into the "len" variable. */ len = frame.length; buffer = (u8 *)frame.buffer; 80345ea: f8dd b008 ldr.w fp, [sp, #8] /* We allocate a pbuf chain of pbufs from the pool. */ p = pbuf_alloc(PBUF_RAW, len, PBUF_POOL); 80345ee: 4602 mov r2, r0 80345f0: f7f8 fd6b bl 802d0ca /* Copy received frame from ethernet driver buffer to stack buffer */ if (p != NULL) 80345f4: 4604 mov r4, r0 80345f6: 2800 cmp r0, #0 80345f8: d0f2 beq.n 80345e0 80345fa: 4605 mov r5, r0 { for (q = p; q != NULL; q = q->next) { memcpy((u8_t*)q->payload, (u8_t*)&buffer[l], q->len); 80345fc: 6868 ldr r0, [r5, #4] 80345fe: 896a ldrh r2, [r5, #10] 8034600: eb0b 0107 add.w r1, fp, r7 8034604: f7ed f9a2 bl 802194c l = l + q->len; 8034608: 896b ldrh r3, [r5, #10] p = pbuf_alloc(PBUF_RAW, len, PBUF_POOL); /* Copy received frame from ethernet driver buffer to stack buffer */ if (p != NULL) { for (q = p; q != NULL; q = q->next) 803460a: 682d ldr r5, [r5, #0] { memcpy((u8_t*)q->payload, (u8_t*)&buffer[l], q->len); l = l + q->len; 803460c: 18ff adds r7, r7, r3 p = pbuf_alloc(PBUF_RAW, len, PBUF_POOL); /* Copy received frame from ethernet driver buffer to stack buffer */ if (p != NULL) { for (q = p; q != NULL; q = q->next) 803460e: 2d00 cmp r5, #0 8034610: d1f4 bne.n 80345fc } } /* Release descriptors to DMA */ /* Check if received frame with multiple DMA buffer segments */ if (DMA_RX_FRAME_infos->Seg_Count > 1) 8034612: f8da 3000 ldr.w r3, [sl] 8034616: 689a ldr r2, [r3, #8] 8034618: 2a01 cmp r2, #1 { DMARxNextDesc = DMA_RX_FRAME_infos->FS_Rx_Desc; 803461a: bf88 it hi 803461c: 681e ldrhi r6, [r3, #0] } /* Set Own bit in Rx descriptors: gives the buffers back to DMA */ for (i=0; iSeg_Count; i++) { DMARxNextDesc->Status = ETH_DMARxDesc_OWN; 803461e: f04f 4000 mov.w r0, #2147483648 ; 0x80000000 uint32_t l=0,i =0; FrameTypeDef frame; u8 *buffer; __IO ETH_DMADESCTypeDef *DMARxNextDesc; p = NULL; 8034622: 2200 movs r2, #0 8034624: e002 b.n 803462c } /* Set Own bit in Rx descriptors: gives the buffers back to DMA */ for (i=0; iSeg_Count; i++) { DMARxNextDesc->Status = ETH_DMARxDesc_OWN; 8034626: 6030 str r0, [r6, #0] DMARxNextDesc = (ETH_DMADESCTypeDef *)(DMARxNextDesc->Buffer2NextDescAddr); 8034628: 68f6 ldr r6, [r6, #12] { DMARxNextDesc = frame.descriptor; } /* Set Own bit in Rx descriptors: gives the buffers back to DMA */ for (i=0; iSeg_Count; i++) 803462a: 3201 adds r2, #1 803462c: 6899 ldr r1, [r3, #8] 803462e: 428a cmp r2, r1 8034630: d3f9 bcc.n 8034626 DMARxNextDesc->Status = ETH_DMARxDesc_OWN; DMARxNextDesc = (ETH_DMADESCTypeDef *)(DMARxNextDesc->Buffer2NextDescAddr); } /* Clear Segment_Count */ DMA_RX_FRAME_infos->Seg_Count =0; 8034632: 2200 movs r2, #0 8034634: 609a str r2, [r3, #8] /* When Rx Buffer unavailable flag is set: clear it and resume reception */ if ((ETH->DMASR & ETH_DMASR_RBUS) != (u32)RESET) 8034636: f8d9 3000 ldr.w r3, [r9] 803463a: 061b lsls r3, r3, #24 803463c: d504 bpl.n 8034648 { /* Clear RBUS ETHERNET DMA flag */ ETH->DMASR = ETH_DMASR_RBUS; 803463e: 2380 movs r3, #128 ; 0x80 8034640: f8c9 3000 str.w r3, [r9] /* Resume DMA reception */ ETH->DMARPDR = 0; 8034644: 4b0a ldr r3, [pc, #40] ; (8034670 ) 8034646: 601a str r2, [r3, #0] { if(xSemaphoreTake(s_xSemaphore, emacBLOCK_TIME_WAITING_FOR_INPUT)==pdTRUE) { GET_NEXT_FRAGMENT: p = low_level_input( s_pxNetIf ); if (p != NULL) 8034648: 2c00 cmp r4, #0 803464a: d0b4 beq.n 80345b6 { if (ERR_OK != s_pxNetIf->input( p, s_pxNetIf)) 803464c: 4b09 ldr r3, [pc, #36] ; (8034674 ) 803464e: 6819 ldr r1, [r3, #0] 8034650: 4620 mov r0, r4 8034652: 690b ldr r3, [r1, #16] 8034654: 4798 blx r3 8034656: 4601 mov r1, r0 8034658: b118 cbz r0, 8034662 { pbuf_free(p); 803465a: 4620 mov r0, r4 803465c: f7f8 fce8 bl 802d030 8034660: e7a9 b.n 80345b6 p=NULL; } else { xSemaphoreTake(s_xSemaphore, 0); 8034662: f8d8 0000 ldr.w r0, [r8] 8034666: 460a mov r2, r1 8034668: 460b mov r3, r1 803466a: f7f4 fd7f bl 802916c goto GET_NEXT_FRAGMENT; 803466e: e7af b.n 80345d0 8034670: 40029008 .word 0x40029008 8034674: 2000e4d8 .word 0x2000e4d8 8034678: 2000e4dc .word 0x2000e4dc 803467c: 200132d0 .word 0x200132d0 8034680: 40029014 .word 0x40029014 08034684 : * to become availale since the stack doesn't retry to send a packet * dropped because of memory failure (except for the TCP timers). */ static err_t low_level_output(struct netif *netif, struct pbuf *p) { 8034684: b570 push {r4, r5, r6, lr} static SemaphoreHandle_t xTxSemaphore = NULL; struct pbuf *q; uint32_t l = 0; u8 *buffer ; if (xTxSemaphore == NULL) 8034686: 4e19 ldr r6, [pc, #100] ; (80346ec ) 8034688: 6835 ldr r5, [r6, #0] * to become availale since the stack doesn't retry to send a packet * dropped because of memory failure (except for the TCP timers). */ static err_t low_level_output(struct netif *netif, struct pbuf *p) { 803468a: 460c mov r4, r1 static SemaphoreHandle_t xTxSemaphore = NULL; struct pbuf *q; uint32_t l = 0; u8 *buffer ; if (xTxSemaphore == NULL) 803468c: b95d cbnz r5, 80346a6 { vSemaphoreCreateBinary (xTxSemaphore); 803468e: 2001 movs r0, #1 8034690: 4629 mov r1, r5 8034692: 2203 movs r2, #3 8034694: f7f4 fbed bl 8028e72 8034698: 6030 str r0, [r6, #0] 803469a: b120 cbz r0, 80346a6 803469c: 4629 mov r1, r5 803469e: 462a mov r2, r5 80346a0: 462b mov r3, r5 80346a2: f7f4 fc23 bl 8028eec } if (xSemaphoreTake(xTxSemaphore, netifGUARD_BLOCK_TIME)) 80346a6: 4b11 ldr r3, [pc, #68] ; (80346ec ) 80346a8: 2100 movs r1, #0 80346aa: 6818 ldr r0, [r3, #0] 80346ac: 22fa movs r2, #250 ; 0xfa 80346ae: 460b mov r3, r1 80346b0: f7f4 fd5c bl 802916c 80346b4: b1c0 cbz r0, 80346e8 { buffer = (u8 *)(DMATxDescToSet->Buffer1Addr); 80346b6: 4b0e ldr r3, [pc, #56] ; (80346f0 ) 80346b8: 681b ldr r3, [r3, #0] static err_t low_level_output(struct netif *netif, struct pbuf *p) { static SemaphoreHandle_t xTxSemaphore = NULL; struct pbuf *q; uint32_t l = 0; 80346ba: 2500 movs r5, #0 vSemaphoreCreateBinary (xTxSemaphore); } if (xSemaphoreTake(xTxSemaphore, netifGUARD_BLOCK_TIME)) { buffer = (u8 *)(DMATxDescToSet->Buffer1Addr); 80346bc: 689e ldr r6, [r3, #8] 80346be: e007 b.n 80346d0 for(q = p; q != NULL; q = q->next) { memcpy((u8_t*)&buffer[l], q->payload, q->len); 80346c0: 1970 adds r0, r6, r5 80346c2: 6861 ldr r1, [r4, #4] 80346c4: 8962 ldrh r2, [r4, #10] 80346c6: f7ed f941 bl 802194c l = l + q->len; 80346ca: 8963 ldrh r3, [r4, #10] } if (xSemaphoreTake(xTxSemaphore, netifGUARD_BLOCK_TIME)) { buffer = (u8 *)(DMATxDescToSet->Buffer1Addr); for(q = p; q != NULL; q = q->next) 80346cc: 6824 ldr r4, [r4, #0] { memcpy((u8_t*)&buffer[l], q->payload, q->len); l = l + q->len; 80346ce: 18ed adds r5, r5, r3 } if (xSemaphoreTake(xTxSemaphore, netifGUARD_BLOCK_TIME)) { buffer = (u8 *)(DMATxDescToSet->Buffer1Addr); for(q = p; q != NULL; q = q->next) 80346d0: 2c00 cmp r4, #0 80346d2: d1f5 bne.n 80346c0 { memcpy((u8_t*)&buffer[l], q->payload, q->len); l = l + q->len; } ETH_Prepare_Transmit_Descriptors(l); 80346d4: b2a8 uxth r0, r5 80346d6: f000 ff13 bl 8035500 xSemaphoreGive(xTxSemaphore); 80346da: 4b04 ldr r3, [pc, #16] ; (80346ec ) 80346dc: 4621 mov r1, r4 80346de: 6818 ldr r0, [r3, #0] 80346e0: 4622 mov r2, r4 80346e2: 4623 mov r3, r4 80346e4: f7f4 fc02 bl 8028eec } return ERR_OK; } 80346e8: 2000 movs r0, #0 80346ea: bd70 pop {r4, r5, r6, pc} 80346ec: 2000e4e0 .word 0x2000e4e0 80346f0: 20011464 .word 0x20011464 080346f4 : #if LWIP_NETIF_HOSTNAME /* Initialize interface hostname */ netif->hostname = "lwip"; #endif /* LWIP_NETIF_HOSTNAME */ netif->name[0] = IFNAME0; 80346f4: 2373 movs r3, #115 ; 0x73 * @return ERR_OK if the loopif is initialized * ERR_MEM if private data couldn't be allocated * any other err_t on error */ err_t ethernetif_init(struct netif *netif) { 80346f6: b530 push {r4, r5, lr} #if LWIP_NETIF_HOSTNAME /* Initialize interface hostname */ netif->hostname = "lwip"; #endif /* LWIP_NETIF_HOSTNAME */ netif->name[0] = IFNAME0; 80346f8: f880 302e strb.w r3, [r0, #46] ; 0x2e netif->name[1] = IFNAME1; 80346fc: 2374 movs r3, #116 ; 0x74 80346fe: f880 302f strb.w r3, [r0, #47] ; 0x2f netif->output = etharp_output; 8034702: 4b37 ldr r3, [pc, #220] ; (80347e0 ) netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP; s_pxNetIf =netif; /* create binary semaphore used for informing ethernetif of frame reception */ if (s_xSemaphore == NULL) 8034704: 4d37 ldr r5, [pc, #220] ; (80347e4 ) #endif /* LWIP_NETIF_HOSTNAME */ netif->name[0] = IFNAME0; netif->name[1] = IFNAME1; netif->output = etharp_output; 8034706: 6143 str r3, [r0, #20] netif->linkoutput = low_level_output; 8034708: 4b37 ldr r3, [pc, #220] ; (80347e8 ) * @return ERR_OK if the loopif is initialized * ERR_MEM if private data couldn't be allocated * any other err_t on error */ err_t ethernetif_init(struct netif *netif) { 803470a: b087 sub sp, #28 netif->name[0] = IFNAME0; netif->name[1] = IFNAME1; netif->output = etharp_output; netif->linkoutput = low_level_output; 803470c: 6183 str r3, [r0, #24] { uint8_t mac[6]; uint32_t i; /* set netif MAC hardware address length */ netif->hwaddr_len = ETHARP_HWADDR_LEN; 803470e: 2306 movs r3, #6 * @return ERR_OK if the loopif is initialized * ERR_MEM if private data couldn't be allocated * any other err_t on error */ err_t ethernetif_init(struct netif *netif) { 8034710: 4604 mov r4, r0 { uint8_t mac[6]; uint32_t i; /* set netif MAC hardware address length */ netif->hwaddr_len = ETHARP_HWADDR_LEN; 8034712: f880 3026 strb.w r3, [r0, #38] ; 0x26 /* set netif MAC hardware address */ SETTINGS_GetMac(mac); 8034716: a804 add r0, sp, #16 8034718: f7f3 fff6 bl 8028708 netif->hwaddr[0] = mac[0]; 803471c: f89d 3010 ldrb.w r3, [sp, #16] netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP; s_pxNetIf =netif; /* create binary semaphore used for informing ethernetif of frame reception */ if (s_xSemaphore == NULL) 8034720: 6829 ldr r1, [r5, #0] /* set netif MAC hardware address */ SETTINGS_GetMac(mac); netif->hwaddr[0] = mac[0]; 8034722: f884 3027 strb.w r3, [r4, #39] ; 0x27 netif->hwaddr[1] = mac[1]; 8034726: f89d 3011 ldrb.w r3, [sp, #17] 803472a: f884 3028 strb.w r3, [r4, #40] ; 0x28 netif->hwaddr[2] = mac[2]; 803472e: f89d 3012 ldrb.w r3, [sp, #18] 8034732: f884 3029 strb.w r3, [r4, #41] ; 0x29 netif->hwaddr[3] = mac[3]; 8034736: f89d 3013 ldrb.w r3, [sp, #19] 803473a: f884 302a strb.w r3, [r4, #42] ; 0x2a netif->hwaddr[4] = mac[4]; 803473e: f89d 3014 ldrb.w r3, [sp, #20] 8034742: f884 302b strb.w r3, [r4, #43] ; 0x2b netif->hwaddr[5] = mac[5]; 8034746: f89d 3015 ldrb.w r3, [sp, #21] 803474a: f884 302c strb.w r3, [r4, #44] ; 0x2c /* set netif maximum transfer unit */ netif->mtu = 1500; 803474e: f240 53dc movw r3, #1500 ; 0x5dc 8034752: 84a3 strh r3, [r4, #36] ; 0x24 /* Accept broadcast address and ARP traffic */ netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP; 8034754: 2322 movs r3, #34 ; 0x22 8034756: f884 302d strb.w r3, [r4, #45] ; 0x2d s_pxNetIf =netif; 803475a: 4b24 ldr r3, [pc, #144] ; (80347ec ) 803475c: 601c str r4, [r3, #0] /* create binary semaphore used for informing ethernetif of frame reception */ if (s_xSemaphore == NULL) 803475e: b919 cbnz r1, 8034768 { s_xSemaphore= xSemaphoreCreateCounting(20,0); 8034760: 2014 movs r0, #20 8034762: f7f4 fbad bl 8028ec0 8034766: 6028 str r0, [r5, #0] } /* initialize MAC address in ethernet MAC */ ETH_MACAddressConfig(ETH_MAC_Address0, netif->hwaddr); 8034768: f104 0127 add.w r1, r4, #39 ; 0x27 803476c: 2000 movs r0, #0 803476e: f000 fe5f bl 8035430 /* Initialize Tx Descriptors list: Chain Mode */ ETH_DMATxDescChainInit(DMATxDscrTab, &Tx_Buff[0][0], ETH_TXBUFNB); 8034772: 481f ldr r0, [pc, #124] ; (80347f0 ) 8034774: 491f ldr r1, [pc, #124] ; (80347f4 ) /* Enable Ethernet Rx interrrupt */ { for(i=0; i) /* initialize MAC address in ethernet MAC */ ETH_MACAddressConfig(ETH_MAC_Address0, netif->hwaddr); /* Initialize Tx Descriptors list: Chain Mode */ ETH_DMATxDescChainInit(DMATxDscrTab, &Tx_Buff[0][0], ETH_TXBUFNB); 8034778: 2205 movs r2, #5 803477a: f000 ff47 bl 803560c /* Initialize Rx Descriptors list: Chain Mode */ ETH_DMARxDescChainInit(DMARxDscrTab, &Rx_Buff[0][0], ETH_RXBUFNB); 803477e: 481e ldr r0, [pc, #120] ; (80347f8 ) 8034780: 491e ldr r1, [pc, #120] ; (80347fc ) 8034782: 2205 movs r2, #5 8034784: f000 ff16 bl 80355b4 /* Enable Ethernet Rx interrrupt */ { for(i=0; i /* Initialize Rx Descriptors list: Chain Mode */ ETH_DMARxDescChainInit(DMARxDscrTab, &Rx_Buff[0][0], ETH_RXBUFNB); /* Enable Ethernet Rx interrrupt */ { for(i=0; i #ifdef CHECKSUM_BY_HARDWARE /* Enable the checksum insertion for the Tx frames */ { for(i=0; i) /* Initialize Rx Descriptors list: Chain Mode */ ETH_DMARxDescChainInit(DMARxDscrTab, &Rx_Buff[0][0], ETH_RXBUFNB); /* Enable Ethernet Rx interrrupt */ { for(i=0; i } #ifdef CHECKSUM_BY_HARDWARE /* Enable the checksum insertion for the Tx frames */ { for(i=0; i } } #endif /* create the task that handles the ETH_MAC */ xTaskCreate(ethernetif_input, "Eth_if", netifINTERFACE_TASK_STACK_SIZE, NULL, 80347b0: 2400 movs r4, #0 80347b2: 2304 movs r3, #4 80347b4: 2296 movs r2, #150 ; 0x96 80347b6: e88d 0018 stmia.w sp, {r3, r4} 80347ba: 4911 ldr r1, [pc, #68] ; (8034800 ) 80347bc: 9402 str r4, [sp, #8] 80347be: 4623 mov r3, r4 80347c0: 9403 str r4, [sp, #12] 80347c2: 4810 ldr r0, [pc, #64] ; (8034804 ) 80347c4: f7f4 fddc bl 8029380 netifINTERFACE_TASK_PRIORITY,NULL); /* Enable MAC and DMA transmission and reception */ ETH_Start(); 80347c8: f000 ff9c bl 8035704 /* initialize the hardware */ low_level_init(netif); etharp_init(); sys_timeout(ARP_TMR_INTERVAL, arp_timer, NULL); 80347cc: f241 3088 movw r0, #5000 ; 0x1388 80347d0: 490d ldr r1, [pc, #52] ; (8034808 ) 80347d2: 4622 mov r2, r4 80347d4: f7fa feb2 bl 802f53c return ERR_OK; } 80347d8: 4620 mov r0, r4 80347da: b007 add sp, #28 80347dc: bd30 pop {r4, r5, pc} 80347de: bf00 nop 80347e0: 08034299 .word 0x08034299 80347e4: 2000e4dc .word 0x2000e4dc 80347e8: 08034685 .word 0x08034685 80347ec: 2000e4d8 .word 0x2000e4d8 80347f0: 20011468 .word 0x20011468 80347f4: 20013374 .word 0x20013374 80347f8: 200132d4 .word 0x200132d4 80347fc: 20011508 .word 0x20011508 8034800: 080407c3 .word 0x080407c3 8034804: 080345ad .word 0x080345ad 8034808: 08034591 .word 0x08034591 0803480c : * int size -- Size of elements in the mailbox * Outputs: * sys_mbox_t -- Handle to new mailbox *---------------------------------------------------------------------------*/ err_t sys_mbox_new( sys_mbox_t *pxMailBox, int iSize ) { 803480c: b510 push {r4, lr} err_t xReturn = ERR_MEM; *pxMailBox = xQueueCreate( iSize, sizeof( void * ) ); 803480e: 2200 movs r2, #0 * int size -- Size of elements in the mailbox * Outputs: * sys_mbox_t -- Handle to new mailbox *---------------------------------------------------------------------------*/ err_t sys_mbox_new( sys_mbox_t *pxMailBox, int iSize ) { 8034810: 4604 mov r4, r0 err_t xReturn = ERR_MEM; *pxMailBox = xQueueCreate( iSize, sizeof( void * ) ); 8034812: 4608 mov r0, r1 8034814: 2104 movs r1, #4 8034816: f7f4 fb2c bl 8028e72 803481a: 6020 str r0, [r4, #0] xReturn = ERR_OK; SYS_STATS_INC_USED( mbox ); } return xReturn; } 803481c: 2800 cmp r0, #0 803481e: bf14 ite ne 8034820: 2000 movne r0, #0 8034822: f06f 0000 mvneq.w r0, #0 8034826: bd10 pop {r4, pc} 08034828 : * Outputs: * err_t -- ERR_OK if message posted, else ERR_MEM * if not. *---------------------------------------------------------------------------*/ err_t sys_mbox_trypost( sys_mbox_t *pxMailBox, void *pxMessageToPost ) { 8034828: b51f push {r0, r1, r2, r3, r4, lr} err_t xReturn; portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; if( xInsideISR != pdFALSE ) 803482a: 4a0b ldr r2, [pc, #44] ; (8034858 ) * Outputs: * err_t -- ERR_OK if message posted, else ERR_MEM * if not. *---------------------------------------------------------------------------*/ err_t sys_mbox_trypost( sys_mbox_t *pxMailBox, void *pxMessageToPost ) { 803482c: 9101 str r1, [sp, #4] err_t xReturn; portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; if( xInsideISR != pdFALSE ) 803482e: 6812 ldr r2, [r2, #0] { xReturn = xQueueSendFromISR( *pxMailBox, &pxMessageToPost, &xHigherPriorityTaskWoken ); 8034830: 6800 ldr r0, [r0, #0] * if not. *---------------------------------------------------------------------------*/ err_t sys_mbox_trypost( sys_mbox_t *pxMailBox, void *pxMessageToPost ) { err_t xReturn; portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; 8034832: 2300 movs r3, #0 8034834: 9303 str r3, [sp, #12] if( xInsideISR != pdFALSE ) { xReturn = xQueueSendFromISR( *pxMailBox, &pxMessageToPost, &xHigherPriorityTaskWoken ); 8034836: a901 add r1, sp, #4 err_t sys_mbox_trypost( sys_mbox_t *pxMailBox, void *pxMessageToPost ) { err_t xReturn; portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE; if( xInsideISR != pdFALSE ) 8034838: b11a cbz r2, 8034842 { xReturn = xQueueSendFromISR( *pxMailBox, &pxMessageToPost, &xHigherPriorityTaskWoken ); 803483a: aa03 add r2, sp, #12 803483c: f7f4 fc1a bl 8029074 8034840: e002 b.n 8034848 } else { xReturn = xQueueSend( *pxMailBox, &pxMessageToPost, ( TickType_t ) 0 ); 8034842: 4613 mov r3, r2 8034844: f7f4 fb52 bl 8028eec 8034848: b2c0 uxtb r0, r0 xReturn = ERR_MEM; SYS_STATS_INC( mbox.err ); } return xReturn; } 803484a: 3801 subs r0, #1 803484c: bf18 it ne 803484e: f06f 0000 mvnne.w r0, #0 8034852: b005 add sp, #20 8034854: bd00 pop {pc} 8034856: bf00 nop 8034858: 2000e4e4 .word 0x2000e4e4 0803485c : * Outputs: * u32_t -- SYS_ARCH_TIMEOUT if timeout, else number * of milliseconds until received. *---------------------------------------------------------------------------*/ u32_t sys_arch_mbox_fetch( sys_mbox_t *pxMailBox, void **ppvBuffer, u32_t ulTimeOut ) { 803485c: e92d 41f3 stmdb sp!, {r0, r1, r4, r5, r6, r7, r8, lr} 8034860: 4607 mov r7, r0 8034862: 460c mov r4, r1 8034864: 4690 mov r8, r2 void *pvDummy; TickType_t xStartTime, xEndTime, xElapsed; unsigned long ulReturn; xStartTime = xTaskGetTickCount(); 8034866: f7f4 fef3 bl 8029650 803486a: 4605 mov r5, r0 if( NULL == ppvBuffer ) 803486c: b904 cbnz r4, 8034870 { ppvBuffer = &pvDummy; 803486e: ac01 add r4, sp, #4 } if( ulTimeOut != 0UL ) 8034870: f1b8 0f00 cmp.w r8, #0 8034874: d015 beq.n 80348a2 { configASSERT( xInsideISR == ( portBASE_TYPE ) 0 ); 8034876: 4b13 ldr r3, [pc, #76] ; (80348c4 ) 8034878: 681e ldr r6, [r3, #0] 803487a: b116 cbz r6, 8034882 803487c: f7f5 fbdc bl 802a038 8034880: e7fe b.n 8034880 if( pdTRUE == xQueueReceive( *pxMailBox, &( *ppvBuffer ), ulTimeOut/ portTICK_PERIOD_MS ) ) 8034882: 6838 ldr r0, [r7, #0] 8034884: 4621 mov r1, r4 8034886: 4642 mov r2, r8 8034888: 4633 mov r3, r6 803488a: f7f4 fc6f bl 802916c 803488e: 2801 cmp r0, #1 8034890: d103 bne.n 803489a { xEndTime = xTaskGetTickCount(); 8034892: f7f4 fedd bl 8029650 xElapsed = ( xEndTime - xStartTime ) * portTICK_PERIOD_MS; 8034896: 1b40 subs r0, r0, r5 8034898: e011 b.n 80348be ulReturn = xElapsed; } else { /* Timed out. */ *ppvBuffer = NULL; 803489a: 6026 str r6, [r4, #0] ulReturn = SYS_ARCH_TIMEOUT; 803489c: f04f 30ff mov.w r0, #4294967295 80348a0: e00d b.n 80348be } } else { while( pdTRUE != xQueueReceive( *pxMailBox, &( *ppvBuffer ), portMAX_DELAY ) ); 80348a2: 2300 movs r3, #0 80348a4: 6838 ldr r0, [r7, #0] 80348a6: 4621 mov r1, r4 80348a8: f04f 32ff mov.w r2, #4294967295 80348ac: f7f4 fc5e bl 802916c 80348b0: 2801 cmp r0, #1 80348b2: d1f6 bne.n 80348a2 xEndTime = xTaskGetTickCount(); 80348b4: f7f4 fecc bl 8029650 xElapsed = ( xEndTime - xStartTime ) * portTICK_PERIOD_MS; if( xElapsed == 0UL ) 80348b8: 1b40 subs r0, r0, r5 80348ba: bf08 it eq 80348bc: 2001 moveq r0, #1 ulReturn = xElapsed; } return ulReturn; } 80348be: e8bd 81fc ldmia.w sp!, {r2, r3, r4, r5, r6, r7, r8, pc} 80348c2: bf00 nop 80348c4: 2000e4e4 .word 0x2000e4e4 080348c8 : /** Create a new mutex * @param mutex pointer to the mutex to create * @return a new mutex */ err_t sys_mutex_new( sys_mutex_t *pxMutex ) { 80348c8: b510 push {r4, lr} 80348ca: 4604 mov r4, r0 err_t xReturn = ERR_MEM; *pxMutex = xSemaphoreCreateMutex(); 80348cc: 2001 movs r0, #1 80348ce: f7f4 fba7 bl 8029020 80348d2: 6020 str r0, [r4, #0] { SYS_STATS_INC( mutex.err ); } return xReturn; } 80348d4: 2800 cmp r0, #0 80348d6: bf14 ite ne 80348d8: 2000 movne r0, #0 80348da: f06f 0000 mvneq.w r0, #0 80348de: bd10 pop {r4, pc} 080348e0 : /** Lock a mutex * @param mutex the mutex to lock */ void sys_mutex_lock( sys_mutex_t *pxMutex ) { 80348e0: b510 push {r4, lr} 80348e2: 4604 mov r4, r0 while( xSemaphoreTake( *pxMutex, portMAX_DELAY ) != pdPASS ); 80348e4: 2100 movs r1, #0 80348e6: 6820 ldr r0, [r4, #0] 80348e8: f04f 32ff mov.w r2, #4294967295 80348ec: 460b mov r3, r1 80348ee: f7f4 fc3d bl 802916c 80348f2: 2801 cmp r0, #1 80348f4: d1f6 bne.n 80348e4 } 80348f6: bd10 pop {r4, pc} 080348f8 : /** Unlock a mutex * @param mutex the mutex to unlock */ void sys_mutex_unlock(sys_mutex_t *pxMutex ) { xSemaphoreGive( *pxMutex ); 80348f8: 2100 movs r1, #0 80348fa: 6800 ldr r0, [r0, #0] 80348fc: 460a mov r2, r1 80348fe: 460b mov r3, r1 8034900: f7f4 baf4 b.w 8028eec 08034904 : *---------------------------------------------------------------------------* * Description: * Initialize sys arch *---------------------------------------------------------------------------*/ void sys_init(void) { 8034904: 4770 bx lr 08034906 : } u32_t sys_now(void) { return xTaskGetTickCount(); 8034906: f7f4 bea3 b.w 8029650 0803490a : * int prio -- Thread priority * Outputs: * sys_thread_t -- Pointer to per-thread timeouts. *---------------------------------------------------------------------------*/ sys_thread_t sys_thread_new( const char *pcName, void( *pxThread )( void *pvParameters ), void *pvArg, int iStackSize, int iPriority ) { 803490a: b570 push {r4, r5, r6, lr} 803490c: b086 sub sp, #24 803490e: 4606 mov r6, r0 TaskHandle_t xCreatedTask; portBASE_TYPE xResult; sys_thread_t xReturn; xResult = xTaskCreate( pxThread, pcName, iStackSize, pvArg, iPriority, &xCreatedTask ); 8034910: 9c0a ldr r4, [sp, #40] ; 0x28 * int prio -- Thread priority * Outputs: * sys_thread_t -- Pointer to per-thread timeouts. *---------------------------------------------------------------------------*/ sys_thread_t sys_thread_new( const char *pcName, void( *pxThread )( void *pvParameters ), void *pvArg, int iStackSize, int iPriority ) { 8034912: 4615 mov r5, r2 TaskHandle_t xCreatedTask; portBASE_TYPE xResult; sys_thread_t xReturn; xResult = xTaskCreate( pxThread, pcName, iStackSize, pvArg, iPriority, &xCreatedTask ); 8034914: 9400 str r4, [sp, #0] 8034916: aa05 add r2, sp, #20 8034918: 2400 movs r4, #0 803491a: 9201 str r2, [sp, #4] 803491c: 9402 str r4, [sp, #8] 803491e: b29a uxth r2, r3 8034920: 9403 str r4, [sp, #12] 8034922: 4608 mov r0, r1 8034924: 462b mov r3, r5 8034926: 4631 mov r1, r6 8034928: f7f4 fd2a bl 8029380 if( xResult == pdPASS ) 803492c: 2801 cmp r0, #1 { xReturn = xCreatedTask; 803492e: bf0c ite eq 8034930: 9805 ldreq r0, [sp, #20] } else { xReturn = NULL; 8034932: 4620 movne r0, r4 } return xReturn; } 8034934: b006 add sp, #24 8034936: bd70 pop {r4, r5, r6, pc} 08034938 : * operating system. * Outputs: * sys_prot_t -- Previous protection level (not used here) *---------------------------------------------------------------------------*/ sys_prot_t sys_arch_protect( void ) { 8034938: b508 push {r3, lr} if( xInsideISR == pdFALSE ) 803493a: 4b03 ldr r3, [pc, #12] ; (8034948 ) 803493c: 681b ldr r3, [r3, #0] 803493e: b90b cbnz r3, 8034944 { taskENTER_CRITICAL(); 8034940: f7f5 fb82 bl 802a048 } return ( sys_prot_t ) 1; } 8034944: 2001 movs r0, #1 8034946: bd08 pop {r3, pc} 8034948: 2000e4e4 .word 0x2000e4e4 0803494c : * sys_prot_t -- Previous protection level (not used here) *---------------------------------------------------------------------------*/ void sys_arch_unprotect( sys_prot_t xValue ) { (void) xValue; if( xInsideISR == pdFALSE ) 803494c: 4b02 ldr r3, [pc, #8] ; (8034958 ) 803494e: 681b ldr r3, [r3, #0] 8034950: b90b cbnz r3, 8034956 { taskEXIT_CRITICAL(); 8034952: f7f5 bba5 b.w 802a0a0 8034956: 4770 bx lr 8034958: 2000e4e4 .word 0x2000e4e4 0803495c : * Если флаг не устанавливается в положенное время, то сбрасывается * флаг sSettings.sFlags.netsettingsChanged, сохраняется вся структура * настроек в памяти и контроллер перезагружается. */ void vTaskWebReinit(void * pvParameters) { 803495c: b538 push {r3, r4, r5, lr} static uint16_t timeCounter = 0; for (;;) { /* Контроль времени работы задачи */ if (timeCounter++ > TIME_COUNTER_10_MIN) 803495e: 4c20 ldr r4, [pc, #128] ; (80349e0 ) if (fConfirmWebParams) { fConfirmWebParams = false; /* Сохраняем временные сетевые настройки в постоянные */ sSettings.sWebParams.dhcpEnable = sSettings.sWebTempParams.dhcpEnable; 8034960: 4d20 ldr r5, [pc, #128] ; (80349e4 ) static uint16_t timeCounter = 0; for (;;) { /* Контроль времени работы задачи */ if (timeCounter++ > TIME_COUNTER_10_MIN) 8034962: 8823 ldrh r3, [r4, #0] 8034964: 1c5a adds r2, r3, #1 8034966: f5b3 7f16 cmp.w r3, #600 ; 0x258 803496a: 8022 strh r2, [r4, #0] 803496c: d914 bls.n 8034998 { SetWebReinitFlag(false); 803496e: 2000 movs r0, #0 8034970: f7f3 faee bl 8027f50 HTTP_SaveSettings(); 8034974: f7f7 f979 bl 802bc6a vTaskDelay(1010); 8034978: f240 30f2 movw r0, #1010 ; 0x3f2 803497c: f7f4 ff9a bl 80298b4 8034980: f3bf 8f4f dsb sy (SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) | 8034984: 4a18 ldr r2, [pc, #96] ; (80349e8 ) 8034986: 4b19 ldr r3, [pc, #100] ; (80349ec ) 8034988: 68d1 ldr r1, [r2, #12] 803498a: f401 61e0 and.w r1, r1, #1792 ; 0x700 803498e: 430b orrs r3, r1 __STATIC_INLINE void NVIC_SystemReset(void) //static inline void NVIC_SystemReset(void) { __DSB(); /* Ensure all outstanding memory accesses included buffered write are completed before reset */ SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | 8034990: 60d3 str r3, [r2, #12] 8034992: f3bf 8f4f dsb sy 8034996: e7fe b.n 8034996 NVIC_SystemReset(); } if (fConfirmWebParams) 8034998: 4b15 ldr r3, [pc, #84] ; (80349f0 ) 803499a: 781a ldrb r2, [r3, #0] 803499c: b1d2 cbz r2, 80349d4 { fConfirmWebParams = false; 803499e: 2200 movs r2, #0 /* Сохраняем временные сетевые настройки в постоянные */ sSettings.sWebParams.dhcpEnable = sSettings.sWebTempParams.dhcpEnable; strcpy(sSettings.sWebParams.ip, sSettings.sWebTempParams.ip); 80349a0: 4814 ldr r0, [pc, #80] ; (80349f4 ) NVIC_SystemReset(); } if (fConfirmWebParams) { fConfirmWebParams = false; 80349a2: 701a strb r2, [r3, #0] /* Сохраняем временные сетевые настройки в постоянные */ sSettings.sWebParams.dhcpEnable = sSettings.sWebTempParams.dhcpEnable; 80349a4: f895 3063 ldrb.w r3, [r5, #99] ; 0x63 strcpy(sSettings.sWebParams.ip, sSettings.sWebTempParams.ip); 80349a8: f100 0131 add.w r1, r0, #49 ; 0x31 if (fConfirmWebParams) { fConfirmWebParams = false; /* Сохраняем временные сетевые настройки в постоянные */ sSettings.sWebParams.dhcpEnable = sSettings.sWebTempParams.dhcpEnable; 80349ac: f885 3032 strb.w r3, [r5, #50] ; 0x32 strcpy(sSettings.sWebParams.ip, sSettings.sWebTempParams.ip); 80349b0: f7ed fa00 bl 8021db4 strcpy(sSettings.sWebParams.gate, sSettings.sWebTempParams.gate); 80349b4: 4810 ldr r0, [pc, #64] ; (80349f8 ) 80349b6: f100 0131 add.w r1, r0, #49 ; 0x31 80349ba: f7ed f9fb bl 8021db4 strcpy(sSettings.sWebParams.mask, sSettings.sWebTempParams.mask); 80349be: 480f ldr r0, [pc, #60] ; (80349fc ) 80349c0: f100 0131 add.w r1, r0, #49 ; 0x31 80349c4: f7ed f9f6 bl 8021db4 HTTP_SaveSettings(); 80349c8: f7f7 f94f bl 802bc6a vTaskDelete(xHandleWebReinit); 80349cc: 4b0c ldr r3, [pc, #48] ; (8034a00 ) 80349ce: 6818 ldr r0, [r3, #0] 80349d0: f7f4 fdae bl 8029530 } vTaskDelay(1000); 80349d4: f44f 707a mov.w r0, #1000 ; 0x3e8 80349d8: f7f4 ff6c bl 80298b4 } 80349dc: e7c1 b.n 8034962 80349de: bf00 nop 80349e0: 2000e4f4 .word 0x2000e4f4 80349e4: 2000e8e4 .word 0x2000e8e4 80349e8: e000ed00 .word 0xe000ed00 80349ec: 05fa0004 .word 0x05fa0004 80349f0: 200028ac .word 0x200028ac 80349f4: 2000e8e6 .word 0x2000e8e6 80349f8: 2000e8f6 .word 0x2000e8f6 80349fc: 2000e906 .word 0x2000e906 8034a00: 2000e4ec .word 0x2000e4ec 08034a04 : * @brief LwIP_DHCP_Process_Handle * @param None * @retval None */ void LwIP_DHCP_task(void * pvParameters) { 8034a04: b530 push {r4, r5, lr} DHCP_state = DHCP_TIMEOUT; /* Stop DHCP */ dhcp_stop(&xnetif); if (sSettings.sFlags.netsettingsChanged == true) 8034a06: 4d48 ldr r5, [pc, #288] ; (8034b28 ) * @brief LwIP_DHCP_Process_Handle * @param None * @retval None */ void LwIP_DHCP_task(void * pvParameters) { 8034a08: b085 sub sp, #20 struct ip_addr ipaddr; struct ip_addr netmask; struct ip_addr gw; uint8_t DHCP_state; DHCP_state = DHCP_START; 8034a0a: 2400 movs r4, #0 for (;;) { switch (DHCP_state) 8034a0c: b11c cbz r4, 8034a16 8034a0e: 2c01 cmp r4, #1 8034a10: f040 8085 bne.w 8034b1e 8034a14: e004 b.n 8034a20 { case DHCP_START: { dhcp_start(&xnetif); 8034a16: 4845 ldr r0, [pc, #276] ; (8034b2c ) 8034a18: f7f8 f80e bl 802ca38 DHCP_state = DHCP_WAIT_ADDRESS; 8034a1c: 2401 movs r4, #1 //PRINT_USART("\n\rLooking for DHCP server please wait...\n\r"); } break; 8034a1e: e07e b.n 8034b1e case DHCP_WAIT_ADDRESS: { /* Read the new IP address */ ipaddr = xnetif.ip_addr; 8034a20: 4842 ldr r0, [pc, #264] ; (8034b2c ) netmask = xnetif.netmask; 8034a22: 6882 ldr r2, [r0, #8] break; case DHCP_WAIT_ADDRESS: { /* Read the new IP address */ ipaddr = xnetif.ip_addr; 8034a24: 6843 ldr r3, [r0, #4] netmask = xnetif.netmask; 8034a26: 9202 str r2, [sp, #8] gw = xnetif.gw; 8034a28: 68c2 ldr r2, [r0, #12] break; case DHCP_WAIT_ADDRESS: { /* Read the new IP address */ ipaddr = xnetif.ip_addr; 8034a2a: 9301 str r3, [sp, #4] netmask = xnetif.netmask; gw = xnetif.gw; 8034a2c: 9203 str r2, [sp, #12] if (ipaddr.addr != 0) 8034a2e: 2b00 cmp r3, #0 8034a30: d045 beq.n 8034abe { DHCP_state = DHCP_ADDRESS_ASSIGNED; dhcp_stop(&xnetif); 8034a32: f7f7 ffe9 bl 802ca08 /* Сохранение полученных сетевый параметров */ /* Если настройки изменили, то сохраняем во временные настройки */ if (sSettings.sFlags.netsettingsChanged == true) 8034a36: f895 32fc ldrb.w r3, [r5, #764] ; 0x2fc { sprintf(sSettings.sWebTempParams.ip, "%s", ipaddr_ntoa(&ipaddr)); 8034a3a: a801 add r0, sp, #4 DHCP_state = DHCP_ADDRESS_ASSIGNED; dhcp_stop(&xnetif); /* Сохранение полученных сетевый параметров */ /* Если настройки изменили, то сохраняем во временные настройки */ if (sSettings.sFlags.netsettingsChanged == true) 8034a3c: b103 cbz r3, 8034a40 8034a3e: e01b b.n 8034a78 sprintf(sSettings.sWebTempParams.mask, "%s", ipaddr_ntoa(&netmask)); sprintf(sSettings.sWebTempParams.gate, "%s", ipaddr_ntoa(&gw)); } else { sprintf(sSettings.sWebParams.ip, "%s", ipaddr_ntoa(&ipaddr)); 8034a40: f7fb fa7a bl 802ff38 8034a44: 493a ldr r1, [pc, #232] ; (8034b30 ) 8034a46: 4602 mov r2, r0 8034a48: 483a ldr r0, [pc, #232] ; (8034b34 ) 8034a4a: f7f2 fe7b bl 8027744 sprintf(sSettings.sWebParams.mask, "%s", ipaddr_ntoa(&netmask)); 8034a4e: a802 add r0, sp, #8 8034a50: f7fb fa72 bl 802ff38 8034a54: 4936 ldr r1, [pc, #216] ; (8034b30 ) 8034a56: 4602 mov r2, r0 8034a58: 4837 ldr r0, [pc, #220] ; (8034b38 ) 8034a5a: f7f2 fe73 bl 8027744 sprintf(sSettings.sWebParams.gate, "%s", ipaddr_ntoa(&gw)); 8034a5e: a803 add r0, sp, #12 8034a60: f7fb fa6a bl 802ff38 8034a64: 4932 ldr r1, [pc, #200] ; (8034b30 ) 8034a66: 4602 mov r2, r0 8034a68: 4834 ldr r0, [pc, #208] ; (8034b3c ) 8034a6a: f7f2 fe6b bl 8027744 /* Обновляем временные настройки */ sSettings.sWebTempParams.dhcpEnable = sSettings.sWebParams.dhcpEnable; 8034a6e: f895 3032 ldrb.w r3, [r5, #50] ; 0x32 sprintf(sSettings.sWebTempParams.ip, "%s", ipaddr_ntoa(&ipaddr)); 8034a72: a801 add r0, sp, #4 sprintf(sSettings.sWebParams.ip, "%s", ipaddr_ntoa(&ipaddr)); sprintf(sSettings.sWebParams.mask, "%s", ipaddr_ntoa(&netmask)); sprintf(sSettings.sWebParams.gate, "%s", ipaddr_ntoa(&gw)); /* Обновляем временные настройки */ sSettings.sWebTempParams.dhcpEnable = sSettings.sWebParams.dhcpEnable; 8034a74: f885 3063 strb.w r3, [r5, #99] ; 0x63 sprintf(sSettings.sWebTempParams.ip, "%s", ipaddr_ntoa(&ipaddr)); 8034a78: f7fb fa5e bl 802ff38 8034a7c: 492c ldr r1, [pc, #176] ; (8034b30 ) 8034a7e: 4602 mov r2, r0 8034a80: 482f ldr r0, [pc, #188] ; (8034b40 ) 8034a82: f7f2 fe5f bl 8027744 sprintf(sSettings.sWebTempParams.mask, "%s", ipaddr_ntoa(&netmask)); 8034a86: a802 add r0, sp, #8 8034a88: f7fb fa56 bl 802ff38 8034a8c: 4928 ldr r1, [pc, #160] ; (8034b30 ) 8034a8e: 4602 mov r2, r0 8034a90: 482c ldr r0, [pc, #176] ; (8034b44 ) 8034a92: f7f2 fe57 bl 8027744 sprintf(sSettings.sWebTempParams.gate, "%s", ipaddr_ntoa(&gw)); 8034a96: a803 add r0, sp, #12 8034a98: f7fb fa4e bl 802ff38 8034a9c: 4924 ldr r1, [pc, #144] ; (8034b30 ) 8034a9e: 4602 mov r2, r0 8034aa0: 4829 ldr r0, [pc, #164] ; (8034b48 ) 8034aa2: f7f2 fe4f bl 8027744 PRINT_USART("Gateway: "); PRINT_USART(ipaddr_ntoa(&gw)); PRINT_USART("\n\r"); vTaskDelay(50); 8034aa6: 2032 movs r0, #50 ; 0x32 8034aa8: f7f4 ff04 bl 80298b4 /* Установлен динамический IP, можно отправить трап о перезагрузке устройства */ SNMP_SendUserTrap(DEVICE_REBOOTED); 8034aac: 2004 movs r0, #4 8034aae: f000 f9bb bl 8034e28 vTaskDelete(xHandleDHCP); 8034ab2: 4b26 ldr r3, [pc, #152] ; (8034b4c ) 8034ab4: 6818 ldr r0, [r3, #0] 8034ab6: f7f4 fd3b bl 8029530 netmask = xnetif.netmask; gw = xnetif.gw; if (ipaddr.addr != 0) { DHCP_state = DHCP_ADDRESS_ASSIGNED; 8034aba: 2402 movs r4, #2 8034abc: e02f b.n 8034b1e vTaskDelete(xHandleDHCP); } else { /* DHCP timeout */ if (xnetif.dhcp->tries > MAX_DHCP_TRIES) 8034abe: 6a03 ldr r3, [r0, #32] 8034ac0: 7b5b ldrb r3, [r3, #13] 8034ac2: 2b03 cmp r3, #3 8034ac4: d92b bls.n 8034b1e { DHCP_state = DHCP_TIMEOUT; /* Stop DHCP */ dhcp_stop(&xnetif); 8034ac6: f7f7 ff9f bl 802ca08 if (sSettings.sFlags.netsettingsChanged == true) 8034aca: f895 32fc ldrb.w r3, [r5, #764] ; 0x2fc 8034ace: b14b cbz r3, 8034ae4 { ipaddr.addr = ipaddr_addr(sSettings.sWebTempParams.ip); 8034ad0: 481b ldr r0, [pc, #108] ; (8034b40 ) 8034ad2: f7fb f9de bl 802fe92 8034ad6: 9001 str r0, [sp, #4] netmask.addr = ipaddr_addr(sSettings.sWebTempParams.mask); 8034ad8: 481a ldr r0, [pc, #104] ; (8034b44 ) 8034ada: f7fb f9da bl 802fe92 8034ade: 9002 str r0, [sp, #8] gw.addr = ipaddr_addr(sSettings.sWebTempParams.gate); 8034ae0: 4819 ldr r0, [pc, #100] ; (8034b48 ) 8034ae2: e008 b.n 8034af6 } else { ipaddr.addr = ipaddr_addr(sSettings.sWebParams.ip); 8034ae4: 4813 ldr r0, [pc, #76] ; (8034b34 ) 8034ae6: f7fb f9d4 bl 802fe92 8034aea: 9001 str r0, [sp, #4] netmask.addr = ipaddr_addr(sSettings.sWebParams.mask); 8034aec: 4812 ldr r0, [pc, #72] ; (8034b38 ) 8034aee: f7fb f9d0 bl 802fe92 8034af2: 9002 str r0, [sp, #8] gw.addr = ipaddr_addr(sSettings.sWebParams.gate); 8034af4: 4811 ldr r0, [pc, #68] ; (8034b3c ) 8034af6: f7fb f9cc bl 802fe92 } /* Static address used */ netif_set_addr(&xnetif, &ipaddr , &netmask, &gw); 8034afa: a901 add r1, sp, #4 8034afc: aa02 add r2, sp, #8 8034afe: ab03 add r3, sp, #12 } else { ipaddr.addr = ipaddr_addr(sSettings.sWebParams.ip); netmask.addr = ipaddr_addr(sSettings.sWebParams.mask); gw.addr = ipaddr_addr(sSettings.sWebParams.gate); 8034b00: 9003 str r0, [sp, #12] } /* Static address used */ netif_set_addr(&xnetif, &ipaddr , &netmask, &gw); 8034b02: 480a ldr r0, [pc, #40] ; (8034b2c ) 8034b04: f7f8 f9f0 bl 802cee8 PRINT_USART("DHCP timeout\n\r"); PRINT_USART("\n\rStatic IP address\n\r"); PRINT_USART(ipaddr_ntoa(&ipaddr)); PRINT_USART("\n\r"); vTaskDelay(50); 8034b08: 2032 movs r0, #50 ; 0x32 8034b0a: f7f4 fed3 bl 80298b4 /* Установлен статический IP, можно отправить трап о перезагрузке устройства */ SNMP_SendUserTrap(DEVICE_REBOOTED); 8034b0e: 2004 movs r0, #4 8034b10: f000 f98a bl 8034e28 vTaskDelete(xHandleDHCP); 8034b14: 4b0d ldr r3, [pc, #52] ; (8034b4c ) 8034b16: 6818 ldr r0, [r3, #0] 8034b18: f7f4 fd0a bl 8029530 else { /* DHCP timeout */ if (xnetif.dhcp->tries > MAX_DHCP_TRIES) { DHCP_state = DHCP_TIMEOUT; 8034b1c: 2403 movs r4, #3 break; default: break; } vTaskDelay(250); 8034b1e: 20fa movs r0, #250 ; 0xfa 8034b20: f7f4 fec8 bl 80298b4 } 8034b24: e772 b.n 8034a0c 8034b26: bf00 nop 8034b28: 2000e8e4 .word 0x2000e8e4 8034b2c: 2001118c .word 0x2001118c 8034b30: 08035e67 .word 0x08035e67 8034b34: 2000e8e6 .word 0x2000e8e6 8034b38: 2000e906 .word 0x2000e906 8034b3c: 2000e8f6 .word 0x2000e8f6 8034b40: 2000e917 .word 0x2000e917 8034b44: 2000e937 .word 0x2000e937 8034b48: 2000e927 .word 0x2000e927 8034b4c: 2000e4f0 .word 0x2000e4f0 08034b50 : TaskHandle_t xHandleWebReinit = NULL; bool dhcp = false; void LwIP_Init(void) { 8034b50: b530 push {r4, r5, lr} struct ip_addr ipaddr; struct ip_addr netmask; struct ip_addr gw; char str[20]; tcpip_init( NULL, NULL ); 8034b52: 2000 movs r0, #0 sSettings.sFlags.netsettingsChanged = false; 8034b54: 4c36 ldr r4, [pc, #216] ; (8034c30 ) TaskHandle_t xHandleWebReinit = NULL; bool dhcp = false; void LwIP_Init(void) { 8034b56: b08d sub sp, #52 ; 0x34 struct ip_addr ipaddr; struct ip_addr netmask; struct ip_addr gw; char str[20]; tcpip_init( NULL, NULL ); 8034b58: 4601 mov r1, r0 8034b5a: f7f7 f909 bl 802bd70 } } /* Настройки не менялись, используем обычне настройки из флеш памяти */ else { if (sSettings.sWebParams.dhcpEnable) 8034b5e: f894 5032 ldrb.w r5, [r4, #50] ; 0x32 struct ip_addr netmask; struct ip_addr gw; char str[20]; tcpip_init( NULL, NULL ); sSettings.sFlags.netsettingsChanged = false; 8034b62: 2300 movs r3, #0 8034b64: f884 32fc strb.w r3, [r4, #764] ; 0x2fc } } /* Настройки не менялись, используем обычне настройки из флеш памяти */ else { if (sSettings.sWebParams.dhcpEnable) 8034b68: b125 cbz r5, 8034b74 { ipaddr.addr = 0; 8034b6a: 9304 str r3, [sp, #16] netmask.addr = 0; 8034b6c: 9305 str r3, [sp, #20] gw.addr = 0; 8034b6e: 9306 str r3, [sp, #24] netif_add(&xnetif, &ipaddr, &netmask, &gw, NULL, ðernetif_init, &tcpip_input); 8034b70: 9300 str r3, [sp, #0] 8034b72: e028 b.n 8034bc6 netif_set_default(&xnetif); netif_set_up(&xnetif); } else { ipaddr.addr = ipaddr_addr(sSettings.sWebParams.ip); 8034b74: 1ca0 adds r0, r4, #2 8034b76: f7fb f98c bl 802fe92 8034b7a: 9004 str r0, [sp, #16] netmask.addr = ipaddr_addr(sSettings.sWebParams.mask); 8034b7c: f104 0022 add.w r0, r4, #34 ; 0x22 8034b80: f7fb f987 bl 802fe92 8034b84: 9005 str r0, [sp, #20] gw.addr = ipaddr_addr(sSettings.sWebParams.gate); 8034b86: f104 0012 add.w r0, r4, #18 8034b8a: f7fb f982 bl 802fe92 /* Обновляем временные настройки */ sSettings.sWebTempParams.dhcpEnable = sSettings.sWebParams.dhcpEnable; 8034b8e: f894 3032 ldrb.w r3, [r4, #50] ; 0x32 } else { ipaddr.addr = ipaddr_addr(sSettings.sWebParams.ip); netmask.addr = ipaddr_addr(sSettings.sWebParams.mask); gw.addr = ipaddr_addr(sSettings.sWebParams.gate); 8034b92: 9006 str r0, [sp, #24] /* Обновляем временные настройки */ sSettings.sWebTempParams.dhcpEnable = sSettings.sWebParams.dhcpEnable; strcpy(sSettings.sWebTempParams.ip, sSettings.sWebParams.ip); 8034b94: 1ca1 adds r1, r4, #2 8034b96: f104 0033 add.w r0, r4, #51 ; 0x33 ipaddr.addr = ipaddr_addr(sSettings.sWebParams.ip); netmask.addr = ipaddr_addr(sSettings.sWebParams.mask); gw.addr = ipaddr_addr(sSettings.sWebParams.gate); /* Обновляем временные настройки */ sSettings.sWebTempParams.dhcpEnable = sSettings.sWebParams.dhcpEnable; 8034b9a: f884 3063 strb.w r3, [r4, #99] ; 0x63 strcpy(sSettings.sWebTempParams.ip, sSettings.sWebParams.ip); 8034b9e: f7ed f909 bl 8021db4 strcpy(sSettings.sWebTempParams.mask, sSettings.sWebParams.mask); 8034ba2: f104 0122 add.w r1, r4, #34 ; 0x22 8034ba6: f104 0053 add.w r0, r4, #83 ; 0x53 8034baa: f7ed f903 bl 8021db4 strcpy(sSettings.sWebTempParams.gate, sSettings.sWebParams.gate); 8034bae: f104 0112 add.w r1, r4, #18 8034bb2: f104 0043 add.w r0, r4, #67 ; 0x43 8034bb6: f7ed f8fd bl 8021db4 sprintf(str, " %s\n\r", sSettings.sWebParams.ip); 8034bba: a807 add r0, sp, #28 8034bbc: 491d ldr r1, [pc, #116] ; (8034c34 ) 8034bbe: 1ca2 adds r2, r4, #2 8034bc0: f7f2 fdc0 bl 8027744 PRINT_USART("\n\rStatic IP address \n\r"); PRINT_USART(str); netif_add(&xnetif, &ipaddr, &netmask, &gw, NULL, ðernetif_init, &tcpip_input); 8034bc4: 9500 str r5, [sp, #0] 8034bc6: 4b1c ldr r3, [pc, #112] ; (8034c38 ) 8034bc8: 481c ldr r0, [pc, #112] ; (8034c3c ) 8034bca: 9301 str r3, [sp, #4] 8034bcc: 4b1c ldr r3, [pc, #112] ; (8034c40 ) 8034bce: a904 add r1, sp, #16 8034bd0: aa05 add r2, sp, #20 8034bd2: 9302 str r3, [sp, #8] 8034bd4: ab06 add r3, sp, #24 8034bd6: f7f8 f995 bl 802cf04 netif_set_default(&xnetif); 8034bda: 4818 ldr r0, [pc, #96] ; (8034c3c ) 8034bdc: f7f8 f9ba bl 802cf54 netif_set_up(&xnetif); 8034be0: 4816 ldr r0, [pc, #88] ; (8034c3c ) 8034be2: f7f8 f9c7 bl 802cf74 } if (sSettings.sWebParams.dhcpEnable) { 8034be6: 4b12 ldr r3, [pc, #72] ; (8034c30 ) 8034be8: f893 3032 ldrb.w r3, [r3, #50] ; 0x32 8034bec: b17b cbz r3, 8034c0e xTaskCreate(LwIP_DHCP_task, "DHCPClient", configMINIMAL_STACK_SIZE * 2, NULL, 8034bee: 2302 movs r3, #2 8034bf0: 9300 str r3, [sp, #0] 8034bf2: 4b14 ldr r3, [pc, #80] ; (8034c44 ) 8034bf4: 4814 ldr r0, [pc, #80] ; (8034c48 ) 8034bf6: 9301 str r3, [sp, #4] 8034bf8: 2300 movs r3, #0 8034bfa: 9302 str r3, [sp, #8] 8034bfc: 9303 str r3, [sp, #12] 8034bfe: f44f 7280 mov.w r2, #256 ; 0x100 8034c02: 4912 ldr r1, [pc, #72] ; (8034c4c ) 8034c04: f7f4 fbbc bl 8029380 tskIDLE_PRIORITY + 2, &xHandleDHCP); dhcp = true; 8034c08: 4b11 ldr r3, [pc, #68] ; (8034c50 ) 8034c0a: 2201 movs r2, #1 8034c0c: 701a strb r2, [r3, #0] } } /* Если настройки изменились, запускаем задачу по отсчету времени реакции пользователя*/ if (sSettings.sFlags.netsettingsChanged == true) 8034c0e: 4b08 ldr r3, [pc, #32] ; (8034c30 ) 8034c10: f893 32fc ldrb.w r3, [r3, #764] ; 0x2fc 8034c14: b153 cbz r3, 8034c2c xTaskCreate(vTaskWebReinit, "webReinit", configMINIMAL_STACK_SIZE, NULL, 8034c16: 4a0f ldr r2, [pc, #60] ; (8034c54 ) 8034c18: 480f ldr r0, [pc, #60] ; (8034c58 ) 8034c1a: 9201 str r2, [sp, #4] 8034c1c: 2300 movs r3, #0 8034c1e: 9300 str r3, [sp, #0] 8034c20: 9302 str r3, [sp, #8] 8034c22: 9303 str r3, [sp, #12] 8034c24: 490d ldr r1, [pc, #52] ; (8034c5c ) 8034c26: 2280 movs r2, #128 ; 0x80 8034c28: f7f4 fbaa bl 8029380 tskIDLE_PRIORITY, &xHandleWebReinit); } 8034c2c: b00d add sp, #52 ; 0x34 8034c2e: bd30 pop {r4, r5, pc} 8034c30: 2000e8e4 .word 0x2000e8e4 8034c34: 080407ca .word 0x080407ca 8034c38: 080346f5 .word 0x080346f5 8034c3c: 2001118c .word 0x2001118c 8034c40: 0802bd31 .word 0x0802bd31 8034c44: 2000e4f0 .word 0x2000e4f0 8034c48: 08034a05 .word 0x08034a05 8034c4c: 080407d0 .word 0x080407d0 8034c50: 2000e4e8 .word 0x2000e4e8 8034c54: 2000e4ec .word 0x2000e4ec 8034c58: 0803495d .word 0x0803495d 8034c5c: 080407db .word 0x080407db 08034c60 : /** * @brief Возвращает true если сетевые параметры изменились */ bool GetStateWebReinit(void) { 8034c60: b510 push {r4, lr} /* Статус dhcp изменился? */ if (sSettings.sWebParams.dhcpEnable != sSettings.sWebTempParams.dhcpEnable) 8034c62: 4c12 ldr r4, [pc, #72] ; (8034cac ) 8034c64: f894 2032 ldrb.w r2, [r4, #50] ; 0x32 8034c68: f894 3063 ldrb.w r3, [r4, #99] ; 0x63 8034c6c: 429a cmp r2, r3 8034c6e: d004 beq.n 8034c7a { /* Включили dhcp */ if (sSettings.sWebTempParams.dhcpEnable == 1) { /* Устанавилваем флаг */ SetWebReinitFlag(true); 8034c70: 2001 movs r0, #1 8034c72: f7f3 f96d bl 8027f50 return true; 8034c76: 2001 movs r0, #1 8034c78: bd10 pop {r4, pc} return true; } } /* Изменился IP? */ if (strstr(sSettings.sWebParams.ip, sSettings.sWebTempParams.ip) == 0) 8034c7a: 1ca0 adds r0, r4, #2 8034c7c: f104 0133 add.w r1, r4, #51 ; 0x33 8034c80: f7ed fb76 bl 8022370 8034c84: 2800 cmp r0, #0 8034c86: d0f3 beq.n 8034c70 SetWebReinitFlag(true); return true; } /* Изменился шлюз? */ if (strstr(sSettings.sWebParams.gate, sSettings.sWebTempParams.gate) == 0) 8034c88: f104 0012 add.w r0, r4, #18 8034c8c: f104 0143 add.w r1, r4, #67 ; 0x43 8034c90: f7ed fb6e bl 8022370 8034c94: 2800 cmp r0, #0 8034c96: d0eb beq.n 8034c70 SetWebReinitFlag(true); return true; } /* Изменилась маска? */ if (strstr(sSettings.sWebParams.mask, sSettings.sWebTempParams.mask) == 0) 8034c98: f104 0022 add.w r0, r4, #34 ; 0x22 8034c9c: f104 0153 add.w r1, r4, #83 ; 0x53 8034ca0: f7ed fb66 bl 8022370 8034ca4: 2800 cmp r0, #0 8034ca6: d0e3 beq.n 8034c70 /* Устанавилваем флаг */ SetWebReinitFlag(true); return true; } return false; 8034ca8: 2000 movs r0, #0 } 8034caa: bd10 pop {r4, pc} 8034cac: 2000e8e4 .word 0x2000e8e4 08034cb0 : { u8_t id, set_ok; LWIP_UNUSED_ARG(value); set_ok = 0; id = od->id_inst_ptr[0]; 8034cb0: 6883 ldr r3, [r0, #8] switch (id) 8034cb2: 781b ldrb r3, [r3, #0] 8034cb4: 2b02 cmp r3, #2 8034cb6: d001 beq.n 8034cbc 8034cb8: 2b03 cmp r3, #3 8034cba: d103 bne.n 8034cc4 static u8_t signals_set_test (struct obj_def *od, u16_t len, void *value) { u8_t id, set_ok; LWIP_UNUSED_ARG(value); set_ok = 0; 8034cbc: 1f0b subs r3, r1, #4 8034cbe: 4258 negs r0, r3 8034cc0: 4158 adcs r0, r3 8034cc2: 4770 bx lr 8034cc4: 2000 movs r0, #0 } break; }; return set_ok; } 8034cc6: 4770 bx lr 08034cc8 : \param len - длина переменной в байтах \param value - указатель на значение переменной \return нет ------------------------------------------------------------------------------*/ static void signals_get_value (struct obj_def *od, u16_t len, void *value) { 8034cc8: 4613 mov r3, r2 u8_t id; id = od->id_inst_ptr[0]; 8034cca: 6882 ldr r2, [r0, #8] switch (id) 8034ccc: 7812 ldrb r2, [r2, #0] 8034cce: 3a01 subs r2, #1 \param len - длина переменной в байтах \param value - указатель на значение переменной \return нет ------------------------------------------------------------------------------*/ static void signals_get_value (struct obj_def *od, u16_t len, void *value) { 8034cd0: b510 push {r4, lr} 8034cd2: 460c mov r4, r1 u8_t id; id = od->id_inst_ptr[0]; switch (id) 8034cd4: 2a0c cmp r2, #12 8034cd6: d812 bhi.n 8034cfe 8034cd8: e8df f002 tbb [pc, r2] 8034cdc: 0a07070a .word 0x0a07070a 8034ce0: 0a0a0a0a .word 0x0a0a0a0a 8034ce4: 0a0a0a0a .word 0x0a0a0a0a 8034ce8: 0a .byte 0x0a 8034ce9: 00 .byte 0x00 break; case 2: /* RestoreSignal */ *((s32_t*)value) = 0; break; case 3: /* RebootSignal */ *((s32_t*)value) = 0; 8034cea: 2200 movs r2, #0 8034cec: 601a str r2, [r3, #0] break; 8034cee: bd10 pop {r4, pc} break; case 12: /* BatCap */ ocstrncpy((u8_t*)value, (u8_t*)paramStr, len); break; case 13: /* ConnectMonitor */ ocstrncpy((u8_t*)value, (u8_t*)paramStr, len); 8034cf0: 4903 ldr r1, [pc, #12] ; (8034d00 ) 8034cf2: 4618 mov r0, r3 8034cf4: 4622 mov r2, r4 break; default : break; }; } 8034cf6: e8bd 4010 ldmia.w sp!, {r4, lr} break; case 12: /* BatCap */ ocstrncpy((u8_t*)value, (u8_t*)paramStr, len); break; case 13: /* ConnectMonitor */ ocstrncpy((u8_t*)value, (u8_t*)paramStr, len); 8034cfa: f7fc bb77 b.w 80313ec 8034cfe: bd10 pop {r4, pc} 8034d00: 200112d8 .word 0x200112d8 08034d04 : u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8034d04: 2801 cmp r0, #1 \param ident - points to objectname.0 (object id trailer) \param od - points to object definition. указатель на описание переменной \return нет ------------------------------------------------------------------------------*/ static void signals_get_object_def (u8_t ident_len, s32_t *ident, struct obj_def *od) { 8034d06: b538 push {r3, r4, r5, lr} 8034d08: 4614 mov r4, r2 u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; if (ident_len == 2) 8034d0a: d16b bne.n 8034de4 { od->id_inst_len = ident_len; 8034d0c: 2302 movs r3, #2 8034d0e: 7193 strb r3, [r2, #6] { u8_t id; /* return to object name, adding index depth (1) */ ident_len += 1; ident -= 1; 8034d10: 1f0b subs r3, r1, #4 if (ident_len == 2) { od->id_inst_len = ident_len; od->id_inst_ptr = ident; 8034d12: 6093 str r3, [r2, #8] id = ident[0]; switch (id) 8034d14: f811 3c04 ldrb.w r3, [r1, #-4] 8034d18: 3b01 subs r3, #1 8034d1a: 2b0c cmp r3, #12 8034d1c: d862 bhi.n 8034de4 8034d1e: e8df f003 tbb [pc, r3] 8034d22: 0d07 .short 0x0d07 8034d24: 2a241e12 .word 0x2a241e12 8034d28: 423c3630 .word 0x423c3630 8034d2c: 4e48 .short 0x4e48 8034d2e: 54 .byte 0x54 8034d2f: 00 .byte 0x00 { case 1: /* FWVersion */ GetVersionStr(paramStr, ¶mLength); 8034d30: 4d2e ldr r5, [pc, #184] ; (8034dec ) 8034d32: 482f ldr r0, [pc, #188] ; (8034df0 ) 8034d34: 4629 mov r1, r5 8034d36: f7f2 fef1 bl 8027b1c 8034d3a: e04b b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 2: /* RestoreSignal */ GetRestore(paramStr, ¶mLength); 8034d3c: 482c ldr r0, [pc, #176] ; (8034df0 ) 8034d3e: 492b ldr r1, [pc, #172] ; (8034dec ) 8034d40: f7f3 f8ca bl 8027ed8 8034d44: e003 b.n 8034d4e od->access = MIB_OBJECT_READ_WRITE; od->asn_type = SNMP_ASN1_INTEG; od->v_len = sizeof(s32_t); break; case 3: /* RebootSignal */ GetReboot(paramStr, ¶mLength); 8034d46: 482a ldr r0, [pc, #168] ; (8034df0 ) 8034d48: 4928 ldr r1, [pc, #160] ; (8034dec ) 8034d4a: f7f3 f8d3 bl 8027ef4 od->instance = MIB_OBJECT_SCALAR; 8034d4e: 2301 movs r3, #1 8034d50: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_WRITE; 8034d52: 2303 movs r3, #3 8034d54: 7063 strb r3, [r4, #1] od->asn_type = SNMP_ASN1_INTEG; 8034d56: 2302 movs r3, #2 8034d58: 70a3 strb r3, [r4, #2] od->v_len = sizeof(s32_t); 8034d5a: 2304 movs r3, #4 8034d5c: e040 b.n 8034de0 break; case 4: /* IntTemp */ GetInternalTempStr(paramStr, ¶mLength); 8034d5e: 4d23 ldr r5, [pc, #140] ; (8034dec ) 8034d60: 4823 ldr r0, [pc, #140] ; (8034df0 ) 8034d62: 4629 mov r1, r5 8034d64: f7f2 fd92 bl 802788c 8034d68: e034 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 5: /* LineFailBit */ GetLineFailBitStr(paramStr, ¶mLength); 8034d6a: 4d20 ldr r5, [pc, #128] ; (8034dec ) 8034d6c: 4820 ldr r0, [pc, #128] ; (8034df0 ) 8034d6e: 4629 mov r1, r5 8034d70: f7f2 fcf4 bl 802775c 8034d74: e02e b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 6: /* LowBatBit */ GetLowBatteryBitStr(paramStr, ¶mLength); 8034d76: 4d1d ldr r5, [pc, #116] ; (8034dec ) 8034d78: 481d ldr r0, [pc, #116] ; (8034df0 ) 8034d7a: 4629 mov r1, r5 8034d7c: f7f2 fcf3 bl 8027766 8034d80: e028 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 7: /* InFreq */ GetInputFreqStr(paramStr, ¶mLength); 8034d82: 4d1a ldr r5, [pc, #104] ; (8034dec ) 8034d84: 481a ldr r0, [pc, #104] ; (8034df0 ) 8034d86: 4629 mov r1, r5 8034d88: f7f2 fcf2 bl 8027770 8034d8c: e022 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 8: /* OutFreq */ GetOutputFreqStr(paramStr, ¶mLength); 8034d8e: 4d17 ldr r5, [pc, #92] ; (8034dec ) 8034d90: 4817 ldr r0, [pc, #92] ; (8034df0 ) 8034d92: 4629 mov r1, r5 8034d94: f7f2 fd02 bl 802779c 8034d98: e01c b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 9: /* InVoltVAC */ GetInputVoltageStr(paramStr, ¶mLength); 8034d9a: 4d14 ldr r5, [pc, #80] ; (8034dec ) 8034d9c: 4814 ldr r0, [pc, #80] ; (8034df0 ) 8034d9e: 4629 mov r1, r5 8034da0: f7f2 fd12 bl 80277c8 8034da4: e016 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 10: /* OutVoltVAC */ GetOutputVoltageStr(paramStr, ¶mLength); 8034da6: 4d11 ldr r5, [pc, #68] ; (8034dec ) 8034da8: 4811 ldr r0, [pc, #68] ; (8034df0 ) 8034daa: 4629 mov r1, r5 8034dac: f7f2 fd22 bl 80277f4 8034db0: e010 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 11: /* Power */ GetPowerStr(paramStr, ¶mLength); 8034db2: 4d0e ldr r5, [pc, #56] ; (8034dec ) 8034db4: 480e ldr r0, [pc, #56] ; (8034df0 ) 8034db6: 4629 mov r1, r5 8034db8: f7f2 fd32 bl 8027820 8034dbc: e00a b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 12: /* BatCap */ GetBatCapacityStr(paramStr, ¶mLength); 8034dbe: 4d0b ldr r5, [pc, #44] ; (8034dec ) 8034dc0: 480b ldr r0, [pc, #44] ; (8034df0 ) 8034dc2: 4629 mov r1, r5 8034dc4: f7f2 fd3e bl 8027844 8034dc8: e004 b.n 8034dd4 od->access = MIB_OBJECT_READ_ONLY; od->asn_type = SNMP_ASN1_OC_STR; od->v_len = paramLength; break; case 13: /* ConnectMonitor */ GetConnectMonitorStr(paramStr, ¶mLength); 8034dca: 4d08 ldr r5, [pc, #32] ; (8034dec ) 8034dcc: 4808 ldr r0, [pc, #32] ; (8034df0 ) 8034dce: 4629 mov r1, r5 8034dd0: f7f2 fd7c bl 80278cc od->instance = MIB_OBJECT_SCALAR; 8034dd4: 2301 movs r3, #1 8034dd6: 7023 strb r3, [r4, #0] od->access = MIB_OBJECT_READ_ONLY; 8034dd8: 7063 strb r3, [r4, #1] od->asn_type = SNMP_ASN1_OC_STR; 8034dda: 2304 movs r3, #4 8034ddc: 70a3 strb r3, [r4, #2] od->v_len = paramLength; 8034dde: 782b ldrb r3, [r5, #0] 8034de0: 80a3 strh r3, [r4, #4] break; 8034de2: bd38 pop {r3, r4, r5, pc} }; } else { LWIP_DEBUGF(SNMP_MIB_DEBUG,("planar_get_object_def: no scalar\n")); od->instance = MIB_OBJECT_NONE; 8034de4: 2300 movs r3, #0 8034de6: 7023 strb r3, [r4, #0] 8034de8: bd38 pop {r3, r4, r5, pc} 8034dea: bf00 nop 8034dec: 2000e4f6 .word 0x2000e4f6 8034df0: 200112d8 .word 0x200112d8 08034df4 : \param len - длина переменной в байтах \param value - указатель на значение переменной \return нет ------------------------------------------------------------------------------*/ static void signals_set_value (struct obj_def *od, u16_t len, void *value) { 8034df4: b508 push {r3, lr} u8_t id; uint32_t val; id = od->id_inst_ptr[0]; val = *((s32_t*)value); 8034df6: 6813 ldr r3, [r2, #0] static void signals_set_value (struct obj_def *od, u16_t len, void *value) { u8_t id; uint32_t val; id = od->id_inst_ptr[0]; 8034df8: 6882 ldr r2, [r0, #8] val = *((s32_t*)value); switch (id) 8034dfa: 7812 ldrb r2, [r2, #0] 8034dfc: 2a02 cmp r2, #2 8034dfe: d002 beq.n 8034e06 8034e00: 2a03 cmp r2, #3 8034e02: d110 bne.n 8034e26 8034e04: e008 b.n 8034e18 { case 2: /* RestoreSignal */ if (val == 1) { 8034e06: 2b01 cmp r3, #1 8034e08: d10d bne.n 8034e26 SNMP_SendUserTrap(DEVICE_RESTORED); 8034e0a: 2003 movs r0, #3 8034e0c: f000 f80c bl 8034e28 break; default : break; }; } 8034e10: e8bd 4008 ldmia.w sp!, {r3, lr} switch (id) { case 2: /* RestoreSignal */ if (val == 1) { SNMP_SendUserTrap(DEVICE_RESTORED); HTTP_ResetSettings(); 8034e14: f7f6 bf22 b.w 802bc5c } break; case 3: /* RebootSignal */ if (val == 1) 8034e18: 2b01 cmp r3, #1 8034e1a: d104 bne.n 8034e26 HTTP_StartResetTask(false); 8034e1c: 2000 movs r0, #0 break; default : break; }; } 8034e1e: e8bd 4008 ldmia.w sp!, {r3, lr} HTTP_ResetSettings(); } break; case 3: /* RebootSignal */ if (val == 1) HTTP_StartResetTask(false); 8034e22: f7f6 bf2b b.w 802bc7c 8034e26: bd08 pop {r3, pc} 08034e28 : * FIFO буфера. * Если в настройках трапа отправка отключена, то трап игнорируется. * @retval */ void SNMP_SendUserTrap(uint8_t trapName) { 8034e28: b51f push {r0, r1, r2, r3, r4, lr} uint16_t availableSpace; uint8_t dummyTrap; if (traps[trapName].trapEnable) 8034e2a: 4b0d ldr r3, [pc, #52] ; (8034e60 ) * FIFO буфера. * Если в настройках трапа отправка отключена, то трап игнорируется. * @retval */ void SNMP_SendUserTrap(uint8_t trapName) { 8034e2c: f88d 0007 strb.w r0, [sp, #7] uint16_t availableSpace; uint8_t dummyTrap; if (traps[trapName].trapEnable) 8034e30: eb03 00c0 add.w r0, r3, r0, lsl #3 8034e34: 78c3 ldrb r3, [r0, #3] 8034e36: b193 cbz r3, 8034e5e { availableSpace = uxQueueSpacesAvailable(SNMP_TrapQueue); 8034e38: 4c0a ldr r4, [pc, #40] ; (8034e64 ) 8034e3a: 6820 ldr r0, [r4, #0] 8034e3c: f7f4 fa39 bl 80292b2 if (availableSpace == 0) 8034e40: b282 uxth r2, r0 8034e42: b92a cbnz r2, 8034e50 xQueueReceive(SNMP_TrapQueue, &dummyTrap, 0); 8034e44: 6820 ldr r0, [r4, #0] 8034e46: f10d 010f add.w r1, sp, #15 8034e4a: 4613 mov r3, r2 8034e4c: f7f4 f98e bl 802916c xQueueSend(SNMP_TrapQueue, &trapName, 0); 8034e50: 2200 movs r2, #0 8034e52: 6820 ldr r0, [r4, #0] 8034e54: f10d 0107 add.w r1, sp, #7 8034e58: 4613 mov r3, r2 8034e5a: f7f4 f847 bl 8028eec } } 8034e5e: bd1f pop {r0, r1, r2, r3, r4, pc} 8034e60: 200113dc .word 0x200113dc 8034e64: 200113d8 .word 0x200113d8 08034e68 : * @brief Установить SNMP Descriptor * @retval */ // TODO void SNMP_SetObjDescr(void) { 8034e68: b538 push {r3, r4, r5, lr} static uint8_t len; strcpy(sSettings.sSnmp.sysDescr, sSettings.sSnmp.sysName); 8034e6a: 4c15 ldr r4, [pc, #84] ; (8034ec0 ) strcat(sSettings.sSnmp.sysDescr, " "); 8034e6c: 4d15 ldr r5, [pc, #84] ; (8034ec4 ) // TODO void SNMP_SetObjDescr(void) { static uint8_t len; strcpy(sSettings.sSnmp.sysDescr, sSettings.sSnmp.sysName); 8034e6e: f104 01fa add.w r1, r4, #250 ; 0xfa 8034e72: 4620 mov r0, r4 8034e74: f7ec ff9e bl 8021db4 strcat(sSettings.sSnmp.sysDescr, " "); 8034e78: 4629 mov r1, r5 8034e7a: 4620 mov r0, r4 8034e7c: f7ec fe86 bl 8021b8c strcat(sSettings.sSnmp.sysDescr, VERSION); 8034e80: 4620 mov r0, r4 8034e82: 4911 ldr r1, [pc, #68] ; (8034ec8 ) 8034e84: f7ec fe82 bl 8021b8c strcat(sSettings.sSnmp.sysDescr, " "); 8034e88: 4629 mov r1, r5 8034e8a: 4620 mov r0, r4 8034e8c: f7ec fe7e bl 8021b8c strcat(sSettings.sSnmp.sysDescr, sSettings.sSnmp.sysContact); 8034e90: f104 01c8 add.w r1, r4, #200 ; 0xc8 8034e94: 4620 mov r0, r4 8034e96: f7ec fe79 bl 8021b8c strcat(sSettings.sSnmp.sysDescr, " "); 8034e9a: 4629 mov r1, r5 8034e9c: 4620 mov r0, r4 8034e9e: f7ec fe75 bl 8021b8c strcat(sSettings.sSnmp.sysDescr, sSettings.sInfo.serialNumber); 8034ea2: 490a ldr r1, [pc, #40] ; (8034ecc ) 8034ea4: 4620 mov r0, r4 8034ea6: f7ec fe71 bl 8021b8c len = strlen(sSettings.sSnmp.sysDescr); 8034eaa: 4620 mov r0, r4 8034eac: f7ec ffe0 bl 8021e70 8034eb0: 4907 ldr r1, [pc, #28] ; (8034ed0 ) 8034eb2: 7008 strb r0, [r1, #0] snmp_set_sysdesr((u8_t*)sSettings.sSnmp.sysDescr, &len); 8034eb4: 4620 mov r0, r4 } 8034eb6: e8bd 4038 ldmia.w sp!, {r3, r4, r5, lr} strcat(sSettings.sSnmp.sysDescr, sSettings.sSnmp.sysContact); strcat(sSettings.sSnmp.sysDescr, " "); strcat(sSettings.sSnmp.sysDescr, sSettings.sInfo.serialNumber); len = strlen(sSettings.sSnmp.sysDescr); snmp_set_sysdesr((u8_t*)sSettings.sSnmp.sysDescr, &len); 8034eba: f7fc bba1 b.w 8031600 8034ebe: bf00 nop 8034ec0: 2000e948 .word 0x2000e948 8034ec4: 08035f57 .word 0x08035f57 8034ec8: 08035e85 .word 0x08035e85 8034ecc: 2000eb62 .word 0x2000eb62 8034ed0: 2000e4f7 .word 0x2000e4f7 08034ed4 : /** * @brief Установить SNMP SysContact * @retval */ void SNMP_SetSysContact(char *con) { 8034ed4: b510 push {r4, lr} 8034ed6: 4604 mov r4, r0 static uint8_t len; len = strlen(con); 8034ed8: f7ec ffca bl 8021e70 8034edc: 4903 ldr r1, [pc, #12] ; (8034eec ) 8034ede: 7008 strb r0, [r1, #0] snmp_set_syscontact((u8_t*)con, &len); 8034ee0: 4620 mov r0, r4 } 8034ee2: e8bd 4010 ldmia.w sp!, {r4, lr} void SNMP_SetSysContact(char *con) { static uint8_t len; len = strlen(con); snmp_set_syscontact((u8_t*)con, &len); 8034ee6: f7fc bbdd b.w 80316a4 8034eea: bf00 nop 8034eec: 2000e4f8 .word 0x2000e4f8 08034ef0 : /** * @brief Установить SNMP SysLocation * @retval */ void SNMP_SetSysLocation(char *loc) { 8034ef0: b510 push {r4, lr} 8034ef2: 4604 mov r4, r0 static uint8_t len; len = strlen(loc); 8034ef4: f7ec ffbc bl 8021e70 8034ef8: 4903 ldr r1, [pc, #12] ; (8034f08 ) 8034efa: 7008 strb r0, [r1, #0] snmp_set_syslocation((u8_t*)loc, &len); 8034efc: 4620 mov r0, r4 } 8034efe: e8bd 4010 ldmia.w sp!, {r4, lr} void SNMP_SetSysLocation(char *loc) { static uint8_t len; len = strlen(loc); snmp_set_syslocation((u8_t*)loc, &len); 8034f02: f7fc bbd9 b.w 80316b8 8034f06: bf00 nop 8034f08: 2000e4f9 .word 0x2000e4f9 08034f0c : /** * @brief Установить SNMP SysManagerIP * @retval */ void SNMP_SetManagerIP(char *ip) { 8034f0c: b510 push {r4, lr} static ip_addr_t trap_addr; ipaddr_aton(ip, &trap_addr); 8034f0e: 4c05 ldr r4, [pc, #20] ; (8034f24 ) 8034f10: 4621 mov r1, r4 8034f12: f7fa ff40 bl 802fd96 snmp_trap_dst_ip_set(0, &trap_addr); 8034f16: 2000 movs r0, #0 8034f18: 4621 mov r1, r4 } 8034f1a: e8bd 4010 ldmia.w sp!, {r4, lr} void SNMP_SetManagerIP(char *ip) { static ip_addr_t trap_addr; ipaddr_aton(ip, &trap_addr); snmp_trap_dst_ip_set(0, &trap_addr); 8034f1e: f7fe bcd7 b.w 80338d0 8034f22: bf00 nop 8034f24: 2000e4fc .word 0x2000e4fc 08034f28 : SNTP_Enable(sSettings.sSNTP.sntpEnable); } static void recv(void *arg, struct udp_pcb *upcb, struct pbuf *p, struct ip_addr *addr, u16_t port) { 8034f28: b570 push {r4, r5, r6, lr} 8034f2a: 4616 mov r6, r2 time_t t; int utcSec = 0; TM_RTC_t data; if (p->len == sizeof(struct sntp_packet)) 8034f2c: 8952 ldrh r2, [r2, #10] 8034f2e: 2a30 cmp r2, #48 ; 0x30 SNTP_Enable(sSettings.sSNTP.sntpEnable); } static void recv(void *arg, struct udp_pcb *upcb, struct pbuf *p, struct ip_addr *addr, u16_t port) { 8034f30: b094 sub sp, #80 ; 0x50 time_t t; int utcSec = 0; TM_RTC_t data; if (p->len == sizeof(struct sntp_packet)) 8034f32: d149 bne.n 8034fc8 { int i; struct sntp_packet aligned; //myassert(p->len == p->tot_len); /* don't accept chained pbuf */ memcpy(&aligned, p->payload, sizeof(aligned)); 8034f34: a808 add r0, sp, #32 8034f36: 6871 ldr r1, [r6, #4] 8034f38: f7ec fd08 bl 802194c i = (aligned.status >> 3) & 7; 8034f3c: f89d 3020 ldrb.w r3, [sp, #32] if ((i < 1) || (i > 4)) /* SNTP version 1..4 */ 8034f40: f3c3 02c2 ubfx r2, r3, #3, #3 8034f44: 3a01 subs r2, #1 8034f46: 2a03 cmp r2, #3 8034f48: d83e bhi.n 8034fc8 goto out; i = aligned.status & 7; if ((i != 4) && (i != 5)) /* mode 4 or 5: server or broadcast */ 8034f4a: f003 0307 and.w r3, r3, #7 8034f4e: 3b04 subs r3, #4 8034f50: 2b01 cmp r3, #1 8034f52: d839 bhi.n 8034fc8 goto out; if (aligned.xmt == 0) 8034f54: e9dd 4512 ldrd r4, r5, [sp, #72] ; 0x48 8034f58: ea54 0305 orrs.w r3, r4, r5 8034f5c: d034 beq.n 8034fc8 goto out; utcSec = (int)(3600.0*sSettings.sSNTP.timeZone); 8034f5e: 4b20 ldr r3, [pc, #128] ; (8034fe0 ) 8034f60: f8d3 0374 ldr.w r0, [r3, #884] ; 0x374 8034f64: f7eb fad8 bl 8020518 <__aeabi_f2d> 8034f68: a31b add r3, pc, #108 ; (adr r3, 8034fd8 ) 8034f6a: e9d3 2300 ldrd r2, r3, [r3] 8034f6e: f7eb fb27 bl 80205c0 <__aeabi_dmul> 8034f72: f7eb fdbf bl 8020af4 <__aeabi_d2iz> 8034f76: 4605 mov r5, r0 t = (ntohl(aligned.xmt) - 2208988800 + utcSec ); 8034f78: 4620 mov r0, r4 8034f7a: f7f6 ff27 bl 802bdcc 8034f7e: 4b19 ldr r3, [pc, #100] ; (8034fe4 ) 8034f80: 18eb adds r3, r5, r3 TM_RTC_SetDataTimeUnix((uint32_t)t); 8034f82: 1818 adds r0, r3, r0 8034f84: f7f1 fb9c bl 80266c0 /* Сохраним время последней синхронизации */ TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 8034f88: a804 add r0, sp, #16 8034f8a: 2100 movs r1, #0 8034f8c: f7f1 fa7c bl 8026488 memset(sSettings.sSNTP.data, 0, sizeof(sSettings.sSNTP.data)); 8034f90: 2100 movs r1, #0 8034f92: 221e movs r2, #30 8034f94: 4814 ldr r0, [pc, #80] ; (8034fe8 ) 8034f96: f7ec fd93 bl 8021ac0 sprintf(sSettings.sSNTP.data, "%02d.%02d.%02d %02d:%02d:%02d", 8034f9a: f89d 1019 ldrb.w r1, [sp, #25] 8034f9e: f89d 2017 ldrb.w r2, [sp, #23] 8034fa2: 9100 str r1, [sp, #0] 8034fa4: f89d 1015 ldrb.w r1, [sp, #21] 8034fa8: f89d 3018 ldrb.w r3, [sp, #24] 8034fac: 9101 str r1, [sp, #4] 8034fae: f89d 1014 ldrb.w r1, [sp, #20] 8034fb2: 480d ldr r0, [pc, #52] ; (8034fe8 ) 8034fb4: 9102 str r1, [sp, #8] 8034fb6: f89d 1010 ldrb.w r1, [sp, #16] 8034fba: 9103 str r1, [sp, #12] 8034fbc: 490b ldr r1, [pc, #44] ; (8034fec ) 8034fbe: f7f2 fbc1 bl 8027744 data.date, data.month, data.year, data.hours, data.minutes, data.seconds); timeout = VALID_TIMEOUT; 8034fc2: 4a0b ldr r2, [pc, #44] ; (8034ff0 ) 8034fc4: 4b0b ldr r3, [pc, #44] ; (8034ff4 ) 8034fc6: 601a str r2, [r3, #0] } out: pbuf_free(p); 8034fc8: 4630 mov r0, r6 8034fca: f7f8 f831 bl 802d030 } 8034fce: b014 add sp, #80 ; 0x50 8034fd0: bd70 pop {r4, r5, r6, pc} 8034fd2: bf00 nop 8034fd4: f3af 8000 nop.w 8034fd8: 00000000 .word 0x00000000 8034fdc: 40ac2000 .word 0x40ac2000 8034fe0: 2000e8e4 .word 0x2000e8e4 8034fe4: 7c558180 .word 0x7c558180 8034fe8: 2000ec39 .word 0x2000ec39 8034fec: 08040974 .word 0x08040974 8034ff0: 01b77400 .word 0x01b77400 8034ff4: 2000e508 .word 0x2000e508 08034ff8 : void SNTP_Enable(bool enable) { 8034ff8: b538 push {r3, r4, r5, lr} if (enable) 8034ffa: 4605 mov r5, r0 8034ffc: 4c0f ldr r4, [pc, #60] ; (803503c ) 8034ffe: b1b8 cbz r0, 8035030 { if (upcb == 0) 8035000: 6825 ldr r5, [r4, #0] 8035002: b9d5 cbnz r5, 803503a { err_t ret; upcb = udp_new(); 8035004: f7fa fd7c bl 802fb00 8035008: 6020 str r0, [r4, #0] if (upcb != 0) 803500a: b1b0 cbz r0, 803503a { ret = udp_bind(upcb, IP_ADDR_ANY, port); 803500c: 227b movs r2, #123 ; 0x7b 803500e: 490c ldr r1, [pc, #48] ; (8035040 ) 8035010: f7fa fc5e bl 802f8d0 if (ret != ERR_OK) 8035014: 4602 mov r2, r0 { udp_remove(upcb); 8035016: 6820 ldr r0, [r4, #0] upcb = udp_new(); if (upcb != 0) { ret = udp_bind(upcb, IP_ADDR_ANY, port); if (ret != ERR_OK) 8035018: b11a cbz r2, 8035022 { udp_remove(upcb); 803501a: f7fa fd55 bl 802fac8 upcb = 0; 803501e: 6025 str r5, [r4, #0] 8035020: e002 b.n 8035028 } else { udp_recv(upcb, recv, 0); 8035022: 4908 ldr r1, [pc, #32] ; (8035044 ) 8035024: f7fa fd4c bl 802fac0 } timeout = 0; 8035028: 4b07 ldr r3, [pc, #28] ; (8035048 ) 803502a: 2200 movs r2, #0 803502c: 601a str r2, [r3, #0] 803502e: bd38 pop {r3, r4, r5, pc} } } } else if (upcb != 0) 8035030: 6820 ldr r0, [r4, #0] 8035032: b110 cbz r0, 803503a { udp_remove(upcb); 8035034: f7fa fd48 bl 802fac8 upcb = 0; 8035038: 6025 str r5, [r4, #0] 803503a: bd38 pop {r3, r4, r5, pc} 803503c: 2000e504 .word 0x2000e504 8035040: 0803fe88 .word 0x0803fe88 8035044: 08034f29 .word 0x08034f29 8035048: 2000e508 .word 0x2000e508 0803504c : { return upcb != 0; } void SNTP_SetServerAddr(char *addr) { 803504c: b508 push {r3, lr} server.addr = ipaddr_addr(addr); 803504e: f7fa ff20 bl 802fe92 8035052: 4b01 ldr r3, [pc, #4] ; (8035058 ) 8035054: 6018 str r0, [r3, #0] 8035056: bd08 pop {r3, pc} 8035058: 2000e500 .word 0x2000e500 0803505c : /** * @brief Инициализация SNTP. * @retval */ void SNTP_Init(void) { 803505c: b508 push {r3, lr} SNTP_SetServerAddr(sSettings.sSNTP.ip); 803505e: 4805 ldr r0, [pc, #20] ; (8035074 ) 8035060: f7ff fff4 bl 803504c SNTP_Enable(sSettings.sSNTP.sntpEnable); 8035064: 4b04 ldr r3, [pc, #16] ; (8035078 ) 8035066: f893 0344 ldrb.w r0, [r3, #836] ; 0x344 } 803506a: e8bd 4008 ldmia.w sp!, {r3, lr} void SNTP_Init(void) { SNTP_SetServerAddr(sSettings.sSNTP.ip); SNTP_Enable(sSettings.sSNTP.sntpEnable); 803506e: f7ff bfc3 b.w 8034ff8 8035072: bf00 nop 8035074: 2000ec29 .word 0x2000ec29 8035078: 2000e8e4 .word 0x2000e8e4 0803507c : pbuf_free(psend); } } void SNTP_Poll(void) { 803507c: b530 push {r4, r5, lr} if (upcb) 803507e: 4d15 ldr r5, [pc, #84] ; (80350d4 ) 8035080: 682b ldr r3, [r5, #0] pbuf_free(psend); } } void SNTP_Poll(void) { 8035082: b08d sub sp, #52 ; 0x34 if (upcb) 8035084: b31b cbz r3, 80350ce static void send_request(void) { struct sntp_packet packet; struct pbuf* psend; memset(&packet, 0, sizeof(packet)); 8035086: 2100 movs r1, #0 8035088: 2230 movs r2, #48 ; 0x30 803508a: 4668 mov r0, sp 803508c: f7ec fd18 bl 8021ac0 packet.status = (3 << 3) /* SNTP vesion 3 */ | (3 << 0); /* Mode: client */ 8035090: 231b movs r3, #27 psend = pbuf_alloc(PBUF_RAW, sizeof(packet), PBUF_REF); 8035092: 2003 movs r0, #3 8035094: 2130 movs r1, #48 ; 0x30 8035096: 2202 movs r2, #2 static void send_request(void) { struct sntp_packet packet; struct pbuf* psend; memset(&packet, 0, sizeof(packet)); packet.status = (3 << 3) /* SNTP vesion 3 */ | (3 << 0); /* Mode: client */ 8035098: f88d 3000 strb.w r3, [sp] psend = pbuf_alloc(PBUF_RAW, sizeof(packet), PBUF_REF); 803509c: f7f8 f815 bl 802d0ca if (psend != 0) 80350a0: 4604 mov r4, r0 80350a2: b1a0 cbz r0, 80350ce { psend->payload = &packet; 80350a4: ab00 add r3, sp, #0 80350a6: 6043 str r3, [r0, #4] timeout = (udp_sendto(upcb, psend, &server, port) == ERR_OK) ? SENT_TIMEOUT : SENDFAIL_TIMEOUT; 80350a8: 4621 mov r1, r4 80350aa: 4a0b ldr r2, [pc, #44] ; (80350d8 ) 80350ac: 6828 ldr r0, [r5, #0] 80350ae: 237b movs r3, #123 ; 0x7b 80350b0: f7fa fcbf bl 802fa32 80350b4: f64e 2360 movw r3, #60000 ; 0xea60 80350b8: f241 3288 movw r2, #5000 ; 0x1388 80350bc: 4907 ldr r1, [pc, #28] ; (80350dc ) 80350be: 2800 cmp r0, #0 80350c0: bf14 ite ne 80350c2: 4610 movne r0, r2 80350c4: 4618 moveq r0, r3 80350c6: 6008 str r0, [r1, #0] pbuf_free(psend); 80350c8: 4620 mov r0, r4 80350ca: f7f7 ffb1 bl 802d030 void SNTP_Poll(void) { if (upcb) send_request(); } 80350ce: b00d add sp, #52 ; 0x34 80350d0: bd30 pop {r4, r5, pc} 80350d2: bf00 nop 80350d4: 2000e504 .word 0x2000e504 80350d8: 2000e500 .word 0x2000e500 80350dc: 2000e508 .word 0x2000e508 080350e0 : * @brief Периодическая синхронизация времени. * Выполняется раз в сутки с 0 часов. * @retval */ void vTaskPeriodicSynchro(void *arg) { 80350e0: b530 push {r4, r5, lr} static uint8_t fSinhro = 0; for (;;) { vTaskDelay(10000); if (sSettings.sSNTP.sntpEnable) 80350e2: 4d0f ldr r5, [pc, #60] ; (8035120 ) fSinhro = 1; //printf("Periodic time sinhro\n\r"); } if (data.hours > 1) fSinhro = 0; 80350e4: 4c0f ldr r4, [pc, #60] ; (8035124 ) * @brief Периодическая синхронизация времени. * Выполняется раз в сутки с 0 часов. * @retval */ void vTaskPeriodicSynchro(void *arg) { 80350e6: b085 sub sp, #20 static uint8_t fSinhro = 0; for (;;) { vTaskDelay(10000); 80350e8: f242 7010 movw r0, #10000 ; 0x2710 80350ec: f7f4 fbe2 bl 80298b4 if (sSettings.sSNTP.sntpEnable) 80350f0: f895 3344 ldrb.w r3, [r5, #836] ; 0x344 80350f4: 2b00 cmp r3, #0 80350f6: d0f7 beq.n 80350e8 { TM_RTC_GetDateTime(&data, TM_RTC_Format_BIN); 80350f8: 4668 mov r0, sp 80350fa: 2100 movs r1, #0 80350fc: f7f1 f9c4 bl 8026488 /* Если пришло время синхронизации */ if ((data.hours == 0) && (fSinhro == 0)) 8035100: f89d 3005 ldrb.w r3, [sp, #5] 8035104: b92b cbnz r3, 8035112 8035106: 7823 ldrb r3, [r4, #0] 8035108: b91b cbnz r3, 8035112 { SNTP_Poll(); 803510a: f7ff ffb7 bl 803507c fSinhro = 1; 803510e: 2301 movs r3, #1 8035110: 7023 strb r3, [r4, #0] //printf("Periodic time sinhro\n\r"); } if (data.hours > 1) 8035112: f89d 3005 ldrb.w r3, [sp, #5] 8035116: 2b01 cmp r3, #1 8035118: d9e6 bls.n 80350e8 fSinhro = 0; 803511a: 2300 movs r3, #0 803511c: 7023 strb r3, [r4, #0] 803511e: e7e3 b.n 80350e8 8035120: 2000e8e4 .word 0x2000e8e4 8035124: 2000e50c .word 0x2000e50c 08035128 : /** * @brief Синхронизация времени единоразово при включении контроллера * @retval */ void vTaskOnceSynchro(void *arg) { 8035128: b538 push {r3, r4, r5, lr} for (;;) { if (sSettings.sSNTP.sntpEnable) 803512a: 4d07 ldr r5, [pc, #28] ; (8035148 ) 803512c: 4c07 ldr r4, [pc, #28] ; (803514c ) 803512e: f895 3344 ldrb.w r3, [r5, #836] ; 0x344 8035132: b12b cbz r3, 8035140 { vTaskDelay(7000); 8035134: f641 3058 movw r0, #7000 ; 0x1b58 8035138: f7f4 fbbc bl 80298b4 SNTP_Poll(); 803513c: f7ff ff9e bl 803507c //printf("Once time sinhro\n\r"); vTaskDelete(xHandleSntpOnceSinhro); } else vTaskDelete(xHandleSntpOnceSinhro); 8035140: 6820 ldr r0, [r4, #0] 8035142: f7f4 f9f5 bl 8029530 8035146: e7f2 b.n 803512e 8035148: 2000e8e4 .word 0x2000e8e4 803514c: 200028a0 .word 0x200028a0 08035150 : * @brief ETH_BSP_Config * @param None * @retval None */ void ETH_BSP_Config(void) { 8035150: b570 push {r4, r5, r6, lr} { volatile uint32_t i; GPIO_InitTypeDef GPIO_InitStructure; /* Enable GPIOs clocks */ RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOA | RCC_AHB1Periph_GPIOB 8035152: 2007 movs r0, #7 * @brief ETH_BSP_Config * @param None * @retval None */ void ETH_BSP_Config(void) { 8035154: b0b4 sub sp, #208 ; 0xd0 { volatile uint32_t i; GPIO_InitTypeDef GPIO_InitStructure; /* Enable GPIOs clocks */ RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOA | RCC_AHB1Periph_GPIOB 8035156: 2101 movs r1, #1 8035158: f7f0 faf8 bl 802574c | RCC_AHB1Periph_GPIOC, ENABLE); /* Enable SYSCFG clock */ RCC_APB2PeriphClockCmd(RCC_APB2Periph_SYSCFG, ENABLE); 803515c: 2101 movs r1, #1 803515e: f44f 4080 mov.w r0, #16384 ; 0x4000 8035162: f7f0 fb17 bl 8025794 /* MII/RMII Media interface selection --------------------------------------*/ SYSCFG_ETH_MediaInterfaceConfig(SYSCFG_ETH_MediaInterface_RMII); 8035166: 2001 movs r0, #1 8035168: f7f0 fd08 bl 8025b7c ETH_RST_PIN -------> PE2 - замена на PE13 */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; 803516c: 2386 movs r3, #134 ; 0x86 GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; 803516e: 2400 movs r4, #0 */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; 8035170: 2502 movs r5, #2 ETH_RST_PIN -------> PE2 - замена на PE13 */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; 8035172: 9303 str r3, [sp, #12] GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL ; GPIO_Init(GPIOA, &GPIO_InitStructure); 8035174: 4864 ldr r0, [pc, #400] ; (8035308 ) */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; 8035176: f88d 5010 strb.w r5, [sp, #16] */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; 803517a: 2303 movs r3, #3 GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL ; GPIO_Init(GPIOA, &GPIO_InitStructure); 803517c: a903 add r1, sp, #12 */ /* Configure PA1,PA2 and PA7 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2 | GPIO_Pin_7; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz; 803517e: f88d 3011 strb.w r3, [sp, #17] GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; 8035182: f88d 4012 strb.w r4, [sp, #18] GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL ; 8035186: f88d 4013 strb.w r4, [sp, #19] GPIO_Init(GPIOA, &GPIO_InitStructure); 803518a: f7f0 f9ff bl 802558c GPIO_PinAFConfig(GPIOA, GPIO_PinSource1, GPIO_AF_ETH); 803518e: 2101 movs r1, #1 8035190: 220b movs r2, #11 8035192: 485d ldr r0, [pc, #372] ; (8035308 ) 8035194: f7f0 fa43 bl 802561e GPIO_PinAFConfig(GPIOA, GPIO_PinSource2, GPIO_AF_ETH); 8035198: 220b movs r2, #11 803519a: 485b ldr r0, [pc, #364] ; (8035308 ) 803519c: 4629 mov r1, r5 803519e: f7f0 fa3e bl 802561e GPIO_PinAFConfig(GPIOA, GPIO_PinSource7, GPIO_AF_ETH); 80351a2: 220b movs r2, #11 80351a4: 2107 movs r1, #7 80351a6: 4858 ldr r0, [pc, #352] ; (8035308 ) 80351a8: f7f0 fa39 bl 802561e /* Configure PB10,PB11,PB12 and PB13 */ GPIO_InitStructure.GPIO_Pin = /* GPIO_Pin_10 | */ GPIO_Pin_11 | GPIO_Pin_12 | GPIO_Pin_13; 80351ac: f44f 5360 mov.w r3, #14336 ; 0x3800 GPIO_Init(GPIOB, &GPIO_InitStructure); 80351b0: 4856 ldr r0, [pc, #344] ; (803530c ) GPIO_PinAFConfig(GPIOA, GPIO_PinSource1, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOA, GPIO_PinSource2, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOA, GPIO_PinSource7, GPIO_AF_ETH); /* Configure PB10,PB11,PB12 and PB13 */ GPIO_InitStructure.GPIO_Pin = /* GPIO_Pin_10 | */ GPIO_Pin_11 | GPIO_Pin_12 | GPIO_Pin_13; 80351b2: 9303 str r3, [sp, #12] GPIO_Init(GPIOB, &GPIO_InitStructure); 80351b4: a903 add r1, sp, #12 80351b6: f7f0 f9e9 bl 802558c //GPIO_PinAFConfig(GPIOB, GPIO_PinSource10, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOB, GPIO_PinSource11, GPIO_AF_ETH); 80351ba: 210b movs r1, #11 80351bc: 460a mov r2, r1 80351be: 4853 ldr r0, [pc, #332] ; (803530c ) 80351c0: f7f0 fa2d bl 802561e GPIO_PinAFConfig(GPIOB, GPIO_PinSource12, GPIO_AF_ETH); 80351c4: 210c movs r1, #12 80351c6: 220b movs r2, #11 80351c8: 4850 ldr r0, [pc, #320] ; (803530c ) 80351ca: f7f0 fa28 bl 802561e GPIO_PinAFConfig(GPIOB, GPIO_PinSource13, GPIO_AF_ETH); 80351ce: 220b movs r2, #11 80351d0: 210d movs r1, #13 80351d2: 484e ldr r0, [pc, #312] ; (803530c ) 80351d4: f7f0 fa23 bl 802561e /* Configure PC1, PC4 and PC5 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_4 | GPIO_Pin_5; 80351d8: 2332 movs r3, #50 ; 0x32 GPIO_Init(GPIOC, &GPIO_InitStructure); 80351da: 484d ldr r0, [pc, #308] ; (8035310 ) GPIO_PinAFConfig(GPIOB, GPIO_PinSource11, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOB, GPIO_PinSource12, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOB, GPIO_PinSource13, GPIO_AF_ETH); /* Configure PC1, PC4 and PC5 */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_4 | GPIO_Pin_5; 80351dc: 9303 str r3, [sp, #12] GPIO_Init(GPIOC, &GPIO_InitStructure); 80351de: a903 add r1, sp, #12 80351e0: f7f0 f9d4 bl 802558c GPIO_PinAFConfig(GPIOC, GPIO_PinSource1, GPIO_AF_ETH); 80351e4: 484a ldr r0, [pc, #296] ; (8035310 ) 80351e6: 2101 movs r1, #1 80351e8: 220b movs r2, #11 80351ea: f7f0 fa18 bl 802561e GPIO_PinAFConfig(GPIOC, GPIO_PinSource4, GPIO_AF_ETH); 80351ee: 4848 ldr r0, [pc, #288] ; (8035310 ) 80351f0: 2104 movs r1, #4 80351f2: 220b movs r2, #11 80351f4: f7f0 fa13 bl 802561e GPIO_PinAFConfig(GPIOC, GPIO_PinSource5, GPIO_AF_ETH); 80351f8: 220b movs r2, #11 80351fa: 4845 ldr r0, [pc, #276] ; (8035310 ) 80351fc: 2105 movs r1, #5 80351fe: f7f0 fa0e bl 802561e /* Configure the PHY RST pin */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_13; 8035202: f44f 5600 mov.w r6, #8192 ; 0x2000 GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT; 8035206: 2301 movs r3, #1 GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; GPIO_Init(GPIOE, &GPIO_InitStructure); 8035208: 4842 ldr r0, [pc, #264] ; (8035314 ) GPIO_PinAFConfig(GPIOC, GPIO_PinSource4, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOC, GPIO_PinSource5, GPIO_AF_ETH); /* Configure the PHY RST pin */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_13; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT; 803520a: f88d 3010 strb.w r3, [sp, #16] GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; GPIO_Init(GPIOE, &GPIO_InitStructure); 803520e: a903 add r1, sp, #12 /* Configure the PHY RST pin */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_13; GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; 8035210: f88d 3013 strb.w r3, [sp, #19] GPIO_PinAFConfig(GPIOC, GPIO_PinSource1, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOC, GPIO_PinSource4, GPIO_AF_ETH); GPIO_PinAFConfig(GPIOC, GPIO_PinSource5, GPIO_AF_ETH); /* Configure the PHY RST pin */ GPIO_InitStructure.GPIO_Pin = GPIO_Pin_13; 8035214: 9603 str r6, [sp, #12] GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT; GPIO_InitStructure.GPIO_OType = GPIO_OType_PP; 8035216: f88d 4012 strb.w r4, [sp, #18] GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP; GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz; 803521a: f88d 5011 strb.w r5, [sp, #17] GPIO_Init(GPIOE, &GPIO_InitStructure); 803521e: f7f0 f9b5 bl 802558c GPIO_ResetBits(GPIOE, GPIO_Pin_13); 8035222: 483c ldr r0, [pc, #240] ; (8035314 ) 8035224: 4631 mov r1, r6 8035226: f7f0 f9f8 bl 802561a for (i = 0; i < 20000; i++); 803522a: 9401 str r4, [sp, #4] 803522c: f644 631f movw r3, #19999 ; 0x4e1f 8035230: e002 b.n 8035238 8035232: 9a01 ldr r2, [sp, #4] 8035234: 3201 adds r2, #1 8035236: 9201 str r2, [sp, #4] 8035238: 9a01 ldr r2, [sp, #4] 803523a: 429a cmp r2, r3 803523c: d9f9 bls.n 8035232 GPIO_SetBits(GPIOE, GPIO_Pin_13); 803523e: 4835 ldr r0, [pc, #212] ; (8035314 ) 8035240: f44f 5100 mov.w r1, #8192 ; 0x2000 8035244: f7f0 f9e7 bl 8025616 for (i = 0; i < 20000; i++); 8035248: 2300 movs r3, #0 803524a: 9301 str r3, [sp, #4] 803524c: f644 631f movw r3, #19999 ; 0x4e1f 8035250: e002 b.n 8035258 8035252: 9a01 ldr r2, [sp, #4] 8035254: 3201 adds r2, #1 8035256: 9201 str r2, [sp, #4] 8035258: 9a01 ldr r2, [sp, #4] 803525a: 429a cmp r2, r3 803525c: d9f9 bls.n 8035252 static void ETH_MACDMA_Config(void) { ETH_InitTypeDef ETH_InitStructure; /* Enable ETHERNET clock */ RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_ETH_MAC | RCC_AHB1Periph_ETH_MAC_Tx | 803525e: f04f 6060 mov.w r0, #234881024 ; 0xe000000 8035262: 2101 movs r1, #1 8035264: f7f0 fa72 bl 802574c RCC_AHB1Periph_ETH_MAC_Rx, ENABLE); /* Reset ETHERNET on AHB Bus */ ETH_DeInit(); 8035268: f000 f868 bl 803533c /* Software reset */ ETH_SoftwareReset(); 803526c: f000 f9fe bl 803566c /* Wait for software reset */ while (ETH_GetSoftwareResetStatus() == SET); 8035270: f000 fa04 bl 803567c 8035274: 2801 cmp r0, #1 8035276: d0fb beq.n 8035270 /* ETHERNET Configuration --------------------------------------------------*/ /* Call ETH_StructInit if you don't like to configure all ETH_InitStructure parameter */ ETH_StructInit(Ð_InitStructure); 8035278: a805 add r0, sp, #20 803527a: f000 f86c bl 8035356 //ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Disable; // ETH_InitStructure.ETH_Speed = ETH_Speed_10M; // ETH_InitStructure.ETH_Mode = ETH_Mode_FullDuplex; ETH_InitStructure.ETH_LoopbackMode = ETH_LoopbackMode_Disable; ETH_InitStructure.ETH_RetryTransmission = ETH_RetryTransmission_Disable; 803527e: f44f 7300 mov.w r3, #512 ; 0x200 8035282: 930f str r3, [sp, #60] ; 0x3c /* When we use the Checksum offload feature, we need to enable the Store and Forward mode: the store and forward guarantee that a whole frame is stored in the FIFO, so the MAC can insert/verify the checksum, if the checksum is OK the DMA can handle the frame otherwise the frame is dropped */ ETH_InitStructure.ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Enable; ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; 8035284: f04f 7300 mov.w r3, #33554432 ; 0x2000000 8035288: 9326 str r3, [sp, #152] ; 0x98 ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; ETH_InitStructure.ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; ETH_InitStructure.ETH_SecondFrameOperate = ETH_SecondFrameOperate_Enable; ETH_InitStructure.ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; 803528a: 932e str r3, [sp, #184] ; 0xb8 ETH_InitStructure.ETH_FixedBurst = ETH_FixedBurst_Enable; 803528c: f44f 3380 mov.w r3, #65536 ; 0x10000 8035290: 932f str r3, [sp, #188] ; 0xbc ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; 8035292: f44f 0380 mov.w r3, #4194304 ; 0x400000 /* Call ETH_StructInit if you don't like to configure all ETH_InitStructure parameter */ ETH_StructInit(Ð_InitStructure); /* Fill ETH_InitStructure parametrs */ /*------------------------ MAC -----------------------------------*/ ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; 8035296: 2501 movs r5, #1 /* When we use the Checksum offload feature, we need to enable the Store and Forward mode: the store and forward guarantee that a whole frame is stored in the FIFO, so the MAC can insert/verify the checksum, if the checksum is OK the DMA can handle the frame otherwise the frame is dropped */ ETH_InitStructure.ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Enable; ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; 8035298: f44f 1200 mov.w r2, #2097152 ; 0x200000 ETH_InitStructure.ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; ETH_InitStructure.ETH_SecondFrameOperate = ETH_SecondFrameOperate_Enable; ETH_InitStructure.ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; ETH_InitStructure.ETH_FixedBurst = ETH_FixedBurst_Enable; ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; 803529c: 9330 str r3, [sp, #192] ; 0xc0 ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; 803529e: f44f 5300 mov.w r3, #8192 ; 0x2000 ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; //ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Disable; // ETH_InitStructure.ETH_Speed = ETH_Speed_10M; // ETH_InitStructure.ETH_Mode = ETH_Mode_FullDuplex; ETH_InitStructure.ETH_LoopbackMode = ETH_LoopbackMode_Disable; 80352a2: 2400 movs r4, #0 /* When we use the Checksum offload feature, we need to enable the Store and Forward mode: the store and forward guarantee that a whole frame is stored in the FIFO, so the MAC can insert/verify the checksum, if the checksum is OK the DMA can handle the frame otherwise the frame is dropped */ ETH_InitStructure.ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Enable; ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; 80352a4: 9228 str r2, [sp, #160] ; 0xa0 ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; ETH_InitStructure.ETH_SecondFrameOperate = ETH_SecondFrameOperate_Enable; ETH_InitStructure.ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; ETH_InitStructure.ETH_FixedBurst = ETH_FixedBurst_Enable; ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; 80352a6: 9331 str r3, [sp, #196] ; 0xc4 ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; ETH_InitStructure.ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; ETH_InitStructure.ETH_SecondFrameOperate = ETH_SecondFrameOperate_Enable; 80352a8: 2204 movs r2, #4 ETH_InitStructure.ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; ETH_InitStructure.ETH_FixedBurst = ETH_FixedBurst_Enable; ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; ETH_InitStructure.ETH_DMAArbitration = ETH_DMAArbitration_RoundRobin_RxTx_2_1; 80352aa: f44f 4380 mov.w r3, #16384 ; 0x4000 /* Configure Ethernet */ EthInitStatus = ETH_Init(Ð_InitStructure, LAN8720_PHY_ADDRESS); 80352ae: 4629 mov r1, r5 80352b0: a805 add r0, sp, #20 ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; ETH_InitStructure.ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; ETH_InitStructure.ETH_SecondFrameOperate = ETH_SecondFrameOperate_Enable; 80352b2: 922d str r2, [sp, #180] ; 0xb4 ETH_InitStructure.ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; ETH_InitStructure.ETH_FixedBurst = ETH_FixedBurst_Enable; ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; ETH_InitStructure.ETH_DMAArbitration = ETH_DMAArbitration_RoundRobin_RxTx_2_1; 80352b4: 9333 str r3, [sp, #204] ; 0xcc /* Call ETH_StructInit if you don't like to configure all ETH_InitStructure parameter */ ETH_StructInit(Ð_InitStructure); /* Fill ETH_InitStructure parametrs */ /*------------------------ MAC -----------------------------------*/ ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; 80352b6: 9505 str r5, [sp, #20] //ETH_InitStructure.ETH_AutoNegotiation = ETH_AutoNegotiation_Disable; // ETH_InitStructure.ETH_Speed = ETH_Speed_10M; // ETH_InitStructure.ETH_Mode = ETH_Mode_FullDuplex; ETH_InitStructure.ETH_LoopbackMode = ETH_LoopbackMode_Disable; 80352b8: 940c str r4, [sp, #48] ; 0x30 ETH_InitStructure.ETH_RetryTransmission = ETH_RetryTransmission_Disable; ETH_InitStructure.ETH_AutomaticPadCRCStrip = ETH_AutomaticPadCRCStrip_Disable; 80352ba: 9410 str r4, [sp, #64] ; 0x40 ETH_InitStructure.ETH_ReceiveAll = ETH_ReceiveAll_Disable; 80352bc: 9413 str r4, [sp, #76] ; 0x4c ETH_InitStructure.ETH_BroadcastFramesReception = ETH_BroadcastFramesReception_Enable; 80352be: 9416 str r4, [sp, #88] ; 0x58 ETH_InitStructure.ETH_PromiscuousMode = ETH_PromiscuousMode_Disable; 80352c0: 9418 str r4, [sp, #96] ; 0x60 ETH_InitStructure.ETH_MulticastFramesFilter = ETH_MulticastFramesFilter_Perfect; 80352c2: 9419 str r4, [sp, #100] ; 0x64 ETH_InitStructure.ETH_UnicastFramesFilter = ETH_UnicastFramesFilter_Perfect; 80352c4: 941a str r4, [sp, #104] ; 0x68 /*------------------------ DMA -----------------------------------*/ /* When we use the Checksum offload feature, we need to enable the Store and Forward mode: the store and forward guarantee that a whole frame is stored in the FIFO, so the MAC can insert/verify the checksum, if the checksum is OK the DMA can handle the frame otherwise the frame is dropped */ ETH_InitStructure.ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Enable; 80352c6: 9425 str r4, [sp, #148] ; 0x94 ETH_InitStructure.ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; ETH_InitStructure.ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; ETH_InitStructure.ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; 80352c8: 942a str r4, [sp, #168] ; 0xa8 ETH_InitStructure.ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; 80352ca: 942b str r4, [sp, #172] ; 0xac ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; ETH_InitStructure.ETH_DMAArbitration = ETH_DMAArbitration_RoundRobin_RxTx_2_1; /* Configure Ethernet */ EthInitStatus = ETH_Init(Ð_InitStructure, LAN8720_PHY_ADDRESS); 80352cc: f000 fa80 bl 80357d0 80352d0: 4e11 ldr r6, [pc, #68] ; (8035318 ) /* Enable the Ethernet Rx Interrupt */ ETH_DMAITConfig(ETH_DMA_IT_NIS | ETH_DMA_IT_R, ENABLE); 80352d2: 4629 mov r1, r5 ETH_InitStructure.ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStructure.ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; ETH_InitStructure.ETH_DMAArbitration = ETH_DMAArbitration_RoundRobin_RxTx_2_1; /* Configure Ethernet */ EthInitStatus = ETH_Init(Ð_InitStructure, LAN8720_PHY_ADDRESS); 80352d4: 6030 str r0, [r6, #0] /* Enable the Ethernet Rx Interrupt */ ETH_DMAITConfig(ETH_DMA_IT_NIS | ETH_DMA_IT_R, ENABLE); 80352d6: 4811 ldr r0, [pc, #68] ; (803531c ) 80352d8: f000 f9e2 bl 80356a0 void ETH_NVIC_Config(void) { NVIC_InitTypeDef NVIC_InitStructure; /* 2 bit for pre-emption priority, 2 bits for subpriority */ NVIC_PriorityGroupConfig(NVIC_PriorityGroup_4); 80352dc: f44f 7040 mov.w r0, #768 ; 0x300 80352e0: f7ef ffd4 bl 802528c /* Enable the Ethernet global Interrupt */ NVIC_InitStructure.NVIC_IRQChannel = ETH_IRQn; 80352e4: 233d movs r3, #61 ; 0x3d 80352e6: f88d 3008 strb.w r3, [sp, #8] NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 5; NVIC_InitStructure.NVIC_IRQChannelSubPriority = 0; NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE; NVIC_Init(&NVIC_InitStructure); 80352ea: a802 add r0, sp, #8 /* 2 bit for pre-emption priority, 2 bits for subpriority */ NVIC_PriorityGroupConfig(NVIC_PriorityGroup_4); /* Enable the Ethernet global Interrupt */ NVIC_InitStructure.NVIC_IRQChannel = ETH_IRQn; NVIC_InitStructure.NVIC_IRQChannelPreemptionPriority = 5; 80352ec: 2305 movs r3, #5 80352ee: f88d 3009 strb.w r3, [sp, #9] NVIC_InitStructure.NVIC_IRQChannelSubPriority = 0; 80352f2: f88d 400a strb.w r4, [sp, #10] NVIC_InitStructure.NVIC_IRQChannelCmd = ENABLE; 80352f6: f88d 500b strb.w r5, [sp, #11] NVIC_Init(&NVIC_InitStructure); 80352fa: f7ef ffd1 bl 80252a0 ETH_MACDMA_Config(); /* Config NVIC for Ethernet */ ETH_NVIC_Config(); if (EthInitStatus == 0) { 80352fe: 6833 ldr r3, [r6, #0] 8035300: b903 cbnz r3, 8035304 8035302: e7fe b.n 8035302 // LCD_DisplayStringLine(Line5, (uint8_t*)" Ethernet Init "); // LCD_DisplayStringLine(Line6, (uint8_t*)" failed "); // STM_EVAL_LEDOn(LED5); while(1); } } 8035304: b034 add sp, #208 ; 0xd0 8035306: bd70 pop {r4, r5, r6, pc} 8035308: 40020000 .word 0x40020000 803530c: 40020400 .word 0x40020400 8035310: 40020800 .word 0x40020800 8035314: 40021000 .word 0x40021000 8035318: 2000e510 .word 0x2000e510 803531c: 00010040 .word 0x00010040 08035320 : * @brief Inserts a delay time. * @param nCount: specifies the delay time length. * @retval None */ static void ETH_Delay(__IO uint32_t nCount) { 8035320: b084 sub sp, #16 __IO uint32_t index = 0; 8035322: 2300 movs r3, #0 * @brief Inserts a delay time. * @param nCount: specifies the delay time length. * @retval None */ static void ETH_Delay(__IO uint32_t nCount) { 8035324: 9001 str r0, [sp, #4] __IO uint32_t index = 0; 8035326: 9303 str r3, [sp, #12] for(index = nCount; index != 0; index--) 8035328: 9b01 ldr r3, [sp, #4] 803532a: e001 b.n 8035330 803532c: 9b03 ldr r3, [sp, #12] 803532e: 3b01 subs r3, #1 8035330: 9303 str r3, [sp, #12] 8035332: 9b03 ldr r3, [sp, #12] 8035334: 2b00 cmp r3, #0 8035336: d1f9 bne.n 803532c { } } 8035338: b004 add sp, #16 803533a: 4770 bx lr 0803533c : * @brief Deinitializes the ETHERNET peripheral registers to their default reset values. * @param None * @retval None */ void ETH_DeInit(void) { 803533c: b508 push {r3, lr} RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_ETH_MAC, ENABLE); 803533e: 2101 movs r1, #1 8035340: f04f 7000 mov.w r0, #33554432 ; 0x2000000 8035344: f7f0 fa32 bl 80257ac RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_ETH_MAC, DISABLE); 8035348: f04f 7000 mov.w r0, #33554432 ; 0x2000000 803534c: 2100 movs r1, #0 } 803534e: e8bd 4008 ldmia.w sp!, {r3, lr} * @retval None */ void ETH_DeInit(void) { RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_ETH_MAC, ENABLE); RCC_AHB1PeriphResetCmd(RCC_AHB1Periph_ETH_MAC, DISABLE); 8035352: f7f0 ba2b b.w 80257ac 08035356 : /* Ethernet interframe gap set to 96 bits */ ETH_InitStruct->ETH_InterFrameGap = ETH_InterFrameGap_96Bit; /* Carrier Sense Enabled in Half-Duplex mode */ ETH_InitStruct->ETH_CarrierSense = ETH_CarrierSense_Enable; /* PHY speed configured to 100Mbit/s */ ETH_InitStruct->ETH_Speed = ETH_Speed_100M; 8035356: f44f 4280 mov.w r2, #16384 ; 0x4000 803535a: 6142 str r2, [r0, #20] /* Receive own Frames in Half-Duplex mode enabled */ ETH_InitStruct->ETH_ReceiveOwn = ETH_ReceiveOwn_Enable; /* MAC MII loopback disabled */ ETH_InitStruct->ETH_LoopbackMode = ETH_LoopbackMode_Disable; /* Full-Duplex mode selected */ ETH_InitStruct->ETH_Mode = ETH_Mode_FullDuplex; 803535c: f44f 6200 mov.w r2, #2048 ; 0x800 8035360: 6202 str r2, [r0, #32] /* Receive all frames disabled */ ETH_InitStruct->ETH_ReceiveAll = ETH_ReceiveAll_Disable; /* Source address filtering (on the optional MAC addresses) disabled */ ETH_InitStruct->ETH_SourceAddrFilter = ETH_SourceAddrFilter_Disable; /* Do not forward control frames that do not pass the address filtering */ ETH_InitStruct->ETH_PassControlFrames = ETH_PassControlFrames_BlockAll; 8035362: 2240 movs r2, #64 ; 0x40 8035364: 6402 str r2, [r0, #64] ; 0x40 /* Disable reception of Broadcast frames */ ETH_InitStruct->ETH_BroadcastFramesReception = ETH_BroadcastFramesReception_Disable; 8035366: 2220 movs r2, #32 8035368: 6442 str r2, [r0, #68] ; 0x44 /* Initialize hash table high and low regs */ ETH_InitStruct->ETH_HashTableHigh = 0x0; ETH_InitStruct->ETH_HashTableLow = 0x0; /* Flow control config (flow control disabled)*/ ETH_InitStruct->ETH_PauseTime = 0x0; ETH_InitStruct->ETH_ZeroQuantaPause = ETH_ZeroQuantaPause_Disable; 803536a: 2280 movs r2, #128 ; 0x80 { /* ETH_InitStruct members default value */ /*------------------------ MAC Configuration ---------------------------*/ /* PHY Auto-negotiation enabled */ ETH_InitStruct->ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; 803536c: 2301 movs r3, #1 /* Initialize hash table high and low regs */ ETH_InitStruct->ETH_HashTableHigh = 0x0; ETH_InitStruct->ETH_HashTableLow = 0x0; /* Flow control config (flow control disabled)*/ ETH_InitStruct->ETH_PauseTime = 0x0; ETH_InitStruct->ETH_ZeroQuantaPause = ETH_ZeroQuantaPause_Disable; 803536e: 6642 str r2, [r0, #100] ; 0x64 ETH_InitStruct->ETH_VLANTagIdentifier = 0x0; /*---------------------- DMA Configuration -------------------------------*/ /* Drops frames with with TCP/IP checksum errors */ ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Disable; 8035370: f04f 6280 mov.w r2, #67108864 ; 0x4000000 { /* ETH_InitStruct members default value */ /*------------------------ MAC Configuration ---------------------------*/ /* PHY Auto-negotiation enabled */ ETH_InitStruct->ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; 8035374: 6003 str r3, [r0, #0] ETH_InitStruct->ETH_VLANTagIdentifier = 0x0; /*---------------------- DMA Configuration -------------------------------*/ /* Drops frames with with TCP/IP checksum errors */ ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Disable; 8035376: f8c0 2080 str.w r2, [r0, #128] ; 0x80 /*------------------------ MAC Configuration ---------------------------*/ /* PHY Auto-negotiation enabled */ ETH_InitStruct->ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; /* MAC watchdog enabled: cuts-off long frame */ ETH_InitStruct->ETH_Watchdog = ETH_Watchdog_Enable; 803537a: 2300 movs r3, #0 /*---------------------- DMA Configuration -------------------------------*/ /* Drops frames with with TCP/IP checksum errors */ ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Disable; /* Store and forward mode enabled for receive */ ETH_InitStruct->ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; 803537c: f04f 7200 mov.w r2, #33554432 ; 0x2000000 /*------------------------ MAC Configuration ---------------------------*/ /* PHY Auto-negotiation enabled */ ETH_InitStruct->ETH_AutoNegotiation = ETH_AutoNegotiation_Enable; /* MAC watchdog enabled: cuts-off long frame */ ETH_InitStruct->ETH_Watchdog = ETH_Watchdog_Enable; 8035380: 6043 str r3, [r0, #4] /* MAC Jabber enabled in Half-duplex mode */ ETH_InitStruct->ETH_Jabber = ETH_Jabber_Enable; 8035382: 6083 str r3, [r0, #8] /* Ethernet interframe gap set to 96 bits */ ETH_InitStruct->ETH_InterFrameGap = ETH_InterFrameGap_96Bit; 8035384: 60c3 str r3, [r0, #12] /* Carrier Sense Enabled in Half-Duplex mode */ ETH_InitStruct->ETH_CarrierSense = ETH_CarrierSense_Enable; 8035386: 6103 str r3, [r0, #16] /* PHY speed configured to 100Mbit/s */ ETH_InitStruct->ETH_Speed = ETH_Speed_100M; /* Receive own Frames in Half-Duplex mode enabled */ ETH_InitStruct->ETH_ReceiveOwn = ETH_ReceiveOwn_Enable; 8035388: 6183 str r3, [r0, #24] /* MAC MII loopback disabled */ ETH_InitStruct->ETH_LoopbackMode = ETH_LoopbackMode_Disable; 803538a: 61c3 str r3, [r0, #28] /* Full-Duplex mode selected */ ETH_InitStruct->ETH_Mode = ETH_Mode_FullDuplex; /* IPv4 and TCP/UDP/ICMP frame Checksum Offload disabled */ ETH_InitStruct->ETH_ChecksumOffload = ETH_ChecksumOffload_Disable; 803538c: 6243 str r3, [r0, #36] ; 0x24 /* Retry Transmission enabled for half-duplex mode */ ETH_InitStruct->ETH_RetryTransmission = ETH_RetryTransmission_Enable; 803538e: 6283 str r3, [r0, #40] ; 0x28 /* Automatic PAD/CRC strip disabled*/ ETH_InitStruct->ETH_AutomaticPadCRCStrip = ETH_AutomaticPadCRCStrip_Disable; 8035390: 62c3 str r3, [r0, #44] ; 0x2c /* half-duplex mode retransmission Backoff time_limit = 10 slot times*/ ETH_InitStruct->ETH_BackOffLimit = ETH_BackOffLimit_10; 8035392: 6303 str r3, [r0, #48] ; 0x30 /* half-duplex mode Deferral check disabled */ ETH_InitStruct->ETH_DeferralCheck = ETH_DeferralCheck_Disable; 8035394: 6343 str r3, [r0, #52] ; 0x34 /* Receive all frames disabled */ ETH_InitStruct->ETH_ReceiveAll = ETH_ReceiveAll_Disable; 8035396: 6383 str r3, [r0, #56] ; 0x38 /* Source address filtering (on the optional MAC addresses) disabled */ ETH_InitStruct->ETH_SourceAddrFilter = ETH_SourceAddrFilter_Disable; 8035398: 63c3 str r3, [r0, #60] ; 0x3c /* Do not forward control frames that do not pass the address filtering */ ETH_InitStruct->ETH_PassControlFrames = ETH_PassControlFrames_BlockAll; /* Disable reception of Broadcast frames */ ETH_InitStruct->ETH_BroadcastFramesReception = ETH_BroadcastFramesReception_Disable; /* Normal Destination address filtering (not reverse addressing) */ ETH_InitStruct->ETH_DestinationAddrFilter = ETH_DestinationAddrFilter_Normal; 803539a: 6483 str r3, [r0, #72] ; 0x48 /* Promiscuous address filtering mode disabled */ ETH_InitStruct->ETH_PromiscuousMode = ETH_PromiscuousMode_Disable; 803539c: 64c3 str r3, [r0, #76] ; 0x4c /* Perfect address filtering for multicast addresses */ ETH_InitStruct->ETH_MulticastFramesFilter = ETH_MulticastFramesFilter_Perfect; 803539e: 6503 str r3, [r0, #80] ; 0x50 /* Perfect address filtering for unicast addresses */ ETH_InitStruct->ETH_UnicastFramesFilter = ETH_UnicastFramesFilter_Perfect; 80353a0: 6543 str r3, [r0, #84] ; 0x54 /* Initialize hash table high and low regs */ ETH_InitStruct->ETH_HashTableHigh = 0x0; 80353a2: 6583 str r3, [r0, #88] ; 0x58 ETH_InitStruct->ETH_HashTableLow = 0x0; 80353a4: 65c3 str r3, [r0, #92] ; 0x5c /* Flow control config (flow control disabled)*/ ETH_InitStruct->ETH_PauseTime = 0x0; 80353a6: 6603 str r3, [r0, #96] ; 0x60 ETH_InitStruct->ETH_ZeroQuantaPause = ETH_ZeroQuantaPause_Disable; ETH_InitStruct->ETH_PauseLowThreshold = ETH_PauseLowThreshold_Minus4; 80353a8: 6683 str r3, [r0, #104] ; 0x68 ETH_InitStruct->ETH_UnicastPauseFrameDetect = ETH_UnicastPauseFrameDetect_Disable; 80353aa: 66c3 str r3, [r0, #108] ; 0x6c ETH_InitStruct->ETH_ReceiveFlowControl = ETH_ReceiveFlowControl_Disable; 80353ac: 6703 str r3, [r0, #112] ; 0x70 ETH_InitStruct->ETH_TransmitFlowControl = ETH_TransmitFlowControl_Disable; 80353ae: 6743 str r3, [r0, #116] ; 0x74 /* VLANtag config (VLAN field not checked) */ ETH_InitStruct->ETH_VLANTagComparison = ETH_VLANTagComparison_16Bit; 80353b0: 6783 str r3, [r0, #120] ; 0x78 ETH_InitStruct->ETH_VLANTagIdentifier = 0x0; 80353b2: 67c3 str r3, [r0, #124] ; 0x7c /*---------------------- DMA Configuration -------------------------------*/ /* Drops frames with with TCP/IP checksum errors */ ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Disable; /* Store and forward mode enabled for receive */ ETH_InitStruct->ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; 80353b4: f8c0 2084 str.w r2, [r0, #132] ; 0x84 ETH_InitStruct->ETH_ReceiveThresholdControl = ETH_ReceiveThresholdControl_64Bytes; /* Disable Operate on second frame (transmit a second frame to FIFO without waiting status of previous frame*/ ETH_InitStruct->ETH_SecondFrameOperate = ETH_SecondFrameOperate_Disable; /* DMA works on 32-bit aligned start source and destinations addresses */ ETH_InitStruct->ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; 80353b8: f8c0 20a4 str.w r2, [r0, #164] ; 0xa4 /* Enabled Fixed Burst Mode (mix of INC4, INC8, INC16 and SINGLE DMA transactions */ ETH_InitStruct->ETH_FixedBurst = ETH_FixedBurst_Enable; 80353bc: f44f 3280 mov.w r2, #65536 ; 0x10000 80353c0: f8c0 20a8 str.w r2, [r0, #168] ; 0xa8 /* DMA transfer max burst length = 32 beats = 32 x 32bits */ ETH_InitStruct->ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; 80353c4: f44f 0280 mov.w r2, #4194304 ; 0x400000 /* Store and forward mode enabled for receive */ ETH_InitStruct->ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; /* Flush received frame that created FIFO overflow */ ETH_InitStruct->ETH_FlushReceivedFrame = ETH_FlushReceivedFrame_Enable; /* Store and forward mode enabled for transmit */ ETH_InitStruct->ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; 80353c8: f44f 1100 mov.w r1, #2097152 ; 0x200000 /* DMA works on 32-bit aligned start source and destinations addresses */ ETH_InitStruct->ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; /* Enabled Fixed Burst Mode (mix of INC4, INC8, INC16 and SINGLE DMA transactions */ ETH_InitStruct->ETH_FixedBurst = ETH_FixedBurst_Enable; /* DMA transfer max burst length = 32 beats = 32 x 32bits */ ETH_InitStruct->ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; 80353cc: f8c0 20ac str.w r2, [r0, #172] ; 0xac ETH_InitStruct->ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; 80353d0: f44f 5200 mov.w r2, #8192 ; 0x2000 /* Drops frames with with TCP/IP checksum errors */ ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame = ETH_DropTCPIPChecksumErrorFrame_Disable; /* Store and forward mode enabled for receive */ ETH_InitStruct->ETH_ReceiveStoreForward = ETH_ReceiveStoreForward_Enable; /* Flush received frame that created FIFO overflow */ ETH_InitStruct->ETH_FlushReceivedFrame = ETH_FlushReceivedFrame_Enable; 80353d4: f8c0 3088 str.w r3, [r0, #136] ; 0x88 /* Store and forward mode enabled for transmit */ ETH_InitStruct->ETH_TransmitStoreForward = ETH_TransmitStoreForward_Enable; 80353d8: f8c0 108c str.w r1, [r0, #140] ; 0x8c /* Threshold TXFIFO level set to 64 bytes (used when threshold mode is enabled) */ ETH_InitStruct->ETH_TransmitThresholdControl = ETH_TransmitThresholdControl_64Bytes; 80353dc: f8c0 3090 str.w r3, [r0, #144] ; 0x90 /* Disable forwarding frames with errors (short frames, CRC,...)*/ ETH_InitStruct->ETH_ForwardErrorFrames = ETH_ForwardErrorFrames_Disable; 80353e0: f8c0 3094 str.w r3, [r0, #148] ; 0x94 /* Disable undersized good frames */ ETH_InitStruct->ETH_ForwardUndersizedGoodFrames = ETH_ForwardUndersizedGoodFrames_Disable; 80353e4: f8c0 3098 str.w r3, [r0, #152] ; 0x98 /* Threshold RXFIFO level set to 64 bytes (used when Cut-through mode is enabled) */ ETH_InitStruct->ETH_ReceiveThresholdControl = ETH_ReceiveThresholdControl_64Bytes; 80353e8: f8c0 309c str.w r3, [r0, #156] ; 0x9c /* Disable Operate on second frame (transmit a second frame to FIFO without waiting status of previous frame*/ ETH_InitStruct->ETH_SecondFrameOperate = ETH_SecondFrameOperate_Disable; 80353ec: f8c0 30a0 str.w r3, [r0, #160] ; 0xa0 ETH_InitStruct->ETH_AddressAlignedBeats = ETH_AddressAlignedBeats_Enable; /* Enabled Fixed Burst Mode (mix of INC4, INC8, INC16 and SINGLE DMA transactions */ ETH_InitStruct->ETH_FixedBurst = ETH_FixedBurst_Enable; /* DMA transfer max burst length = 32 beats = 32 x 32bits */ ETH_InitStruct->ETH_RxDMABurstLength = ETH_RxDMABurstLength_32Beat; ETH_InitStruct->ETH_TxDMABurstLength = ETH_TxDMABurstLength_32Beat; 80353f0: f8c0 20b0 str.w r2, [r0, #176] ; 0xb0 /* DMA Ring mode skip length = 0 */ ETH_InitStruct->ETH_DescriptorSkipLength = 0x0; 80353f4: f8c0 30b4 str.w r3, [r0, #180] ; 0xb4 /* Equal priority (round-robin) between transmit and receive DMA engines */ ETH_InitStruct->ETH_DMAArbitration = ETH_DMAArbitration_RoundRobin_RxTx_1_1; 80353f8: f8c0 30b8 str.w r3, [r0, #184] ; 0xb8 80353fc: 4770 bx lr 80353fe: 0000 movs r0, r0 08035400 : * @param NewState: new state of the MAC transmission. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_MACTransmissionCmd(FunctionalState NewState) { 8035400: 4b04 ldr r3, [pc, #16] ; (8035414 ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the MAC transmission */ ETH->MACCR |= ETH_MACCR_TE; 8035402: 681a ldr r2, [r3, #0] void ETH_MACTransmissionCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 8035404: b110 cbz r0, 803540c { /* Enable the MAC transmission */ ETH->MACCR |= ETH_MACCR_TE; 8035406: f042 0208 orr.w r2, r2, #8 803540a: e001 b.n 8035410 } else { /* Disable the MAC transmission */ ETH->MACCR &= ~ETH_MACCR_TE; 803540c: f022 0208 bic.w r2, r2, #8 8035410: 601a str r2, [r3, #0] 8035412: 4770 bx lr 8035414: 40028000 .word 0x40028000 08035418 : * @param NewState: new state of the MAC reception. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_MACReceptionCmd(FunctionalState NewState) { 8035418: 4b04 ldr r3, [pc, #16] ; (803542c ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the MAC reception */ ETH->MACCR |= ETH_MACCR_RE; 803541a: 681a ldr r2, [r3, #0] void ETH_MACReceptionCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 803541c: b110 cbz r0, 8035424 { /* Enable the MAC reception */ ETH->MACCR |= ETH_MACCR_RE; 803541e: f042 0204 orr.w r2, r2, #4 8035422: e001 b.n 8035428 } else { /* Disable the MAC reception */ ETH->MACCR &= ~ETH_MACCR_RE; 8035424: f022 0204 bic.w r2, r2, #4 8035428: 601a str r2, [r3, #0] 803542a: 4770 bx lr 803542c: 40028000 .word 0x40028000 08035430 : uint32_t tmpreg; /* Check the parameters */ assert_param(IS_ETH_MAC_ADDRESS0123(MacAddr)); /* Calculate the selected MAC address high register */ tmpreg = ((uint32_t)Addr[5] << 8) | (uint32_t)Addr[4]; 8035430: 790b ldrb r3, [r1, #4] 8035432: 794a ldrb r2, [r1, #5] 8035434: ea43 2202 orr.w r2, r3, r2, lsl #8 /* Load the selected MAC address high register */ (*(__IO uint32_t *) (ETH_MAC_ADDR_HBASE + MacAddr)) = tmpreg; 8035438: 4b07 ldr r3, [pc, #28] ; (8035458 ) 803543a: 50c2 str r2, [r0, r3] /* Calculate the selected MAC address low register */ tmpreg = ((uint32_t)Addr[3] << 24) | ((uint32_t)Addr[2] << 16) | ((uint32_t)Addr[1] << 8) | Addr[0]; 803543c: 788a ldrb r2, [r1, #2] 803543e: 78cb ldrb r3, [r1, #3] 8035440: 0412 lsls r2, r2, #16 8035442: ea42 6203 orr.w r2, r2, r3, lsl #24 8035446: 780b ldrb r3, [r1, #0] 8035448: 431a orrs r2, r3 803544a: 784b ldrb r3, [r1, #1] 803544c: ea42 2203 orr.w r2, r2, r3, lsl #8 /* Load the selected MAC address low register */ (*(__IO uint32_t *) (ETH_MAC_ADDR_LBASE + MacAddr)) = tmpreg; 8035450: 4b02 ldr r3, [pc, #8] ; (803545c ) 8035452: 50c2 str r2, [r0, r3] 8035454: 4770 bx lr 8035456: bf00 nop 8035458: 40028040 .word 0x40028040 803545c: 40028044 .word 0x40028044 08035460 : * the receive frame (should be used with interrupt mode only) * @param None * @retval Structure of type FrameTypeDef */ FrameTypeDef ETH_Get_Received_Frame_interrupt(void) { 8035460: b537 push {r0, r1, r2, r4, r5, lr} FrameTypeDef frame={0,0,0}; __IO uint32_t descriptor_scan_counter = 0; 8035462: 2300 movs r3, #0 8035464: 9301 str r3, [sp, #4] /* check if first segment in frame */ if(((DMARxDescToGet->Status & ETH_DMARxDesc_FS) != (uint32_t)RESET)&& ((DMARxDescToGet->Status & ETH_DMARxDesc_LS) == (uint32_t)RESET)) { DMA_RX_FRAME_infos->FS_Rx_Desc = DMARxDescToGet; 8035466: 4b24 ldr r3, [pc, #144] ; (80354f8 ) 8035468: 681a ldr r2, [r3, #0] 803546a: 4b24 ldr r3, [pc, #144] ; (80354fc ) DMA_RX_FRAME_infos->Seg_Count = 1; 803546c: 2401 movs r4, #1 803546e: 681b ldr r3, [r3, #0] { FrameTypeDef frame={0,0,0}; __IO uint32_t descriptor_scan_counter = 0; /* scan descriptors owned by CPU */ while (((DMARxDescToGet->Status & ETH_DMARxDesc_OWN) == (uint32_t)RESET)&& 8035470: e033 b.n 80354da (descriptor_scan_counterStatus & ETH_DMARxDesc_FS) != (uint32_t)RESET)&& 8035478: 6819 ldr r1, [r3, #0] 803547a: 0589 lsls r1, r1, #22 803547c: d505 bpl.n 803548a ((DMARxDescToGet->Status & ETH_DMARxDesc_LS) == (uint32_t)RESET)) 803547e: 6819 ldr r1, [r3, #0] /* Just by security */ descriptor_scan_counter++; /* check if first segment in frame */ if(((DMARxDescToGet->Status & ETH_DMARxDesc_FS) != (uint32_t)RESET)&& 8035480: 05c9 lsls r1, r1, #23 8035482: d402 bmi.n 803548a ((DMARxDescToGet->Status & ETH_DMARxDesc_LS) == (uint32_t)RESET)) { DMA_RX_FRAME_infos->FS_Rx_Desc = DMARxDescToGet; 8035484: 6013 str r3, [r2, #0] DMA_RX_FRAME_infos->Seg_Count = 1; 8035486: 6094 str r4, [r2, #8] 8035488: e009 b.n 803549e DMARxDescToGet = (ETH_DMADESCTypeDef*) (DMARxDescToGet->Buffer2NextDescAddr); } /* check if intermediate segment */ else if (((DMARxDescToGet->Status & ETH_DMARxDesc_LS) == (uint32_t)RESET)&& 803548a: 6819 ldr r1, [r3, #0] 803548c: 05c9 lsls r1, r1, #23 803548e: d408 bmi.n 80354a2 ((DMARxDescToGet->Status & ETH_DMARxDesc_FS) == (uint32_t)RESET)) 8035490: 6819 ldr r1, [r3, #0] DMA_RX_FRAME_infos->Seg_Count = 1; DMARxDescToGet = (ETH_DMADESCTypeDef*) (DMARxDescToGet->Buffer2NextDescAddr); } /* check if intermediate segment */ else if (((DMARxDescToGet->Status & ETH_DMARxDesc_LS) == (uint32_t)RESET)&& 8035492: 0589 lsls r1, r1, #22 8035494: d500 bpl.n 8035498 8035496: e004 b.n 80354a2 ((DMARxDescToGet->Status & ETH_DMARxDesc_FS) == (uint32_t)RESET)) { (DMA_RX_FRAME_infos->Seg_Count) ++; 8035498: 6891 ldr r1, [r2, #8] 803549a: 3101 adds r1, #1 803549c: 6091 str r1, [r2, #8] DMARxDescToGet = (ETH_DMADESCTypeDef*) (DMARxDescToGet->Buffer2NextDescAddr); 803549e: 68db ldr r3, [r3, #12] 80354a0: e01b b.n 80354da 80354a2: 4a16 ldr r2, [pc, #88] ; (80354fc ) 80354a4: 6013 str r3, [r2, #0] /* should be last segment */ else { /* last segment */ DMA_RX_FRAME_infos->LS_Rx_Desc = DMARxDescToGet; 80354a6: 4a14 ldr r2, [pc, #80] ; (80354f8 ) 80354a8: 6812 ldr r2, [r2, #0] 80354aa: 6053 str r3, [r2, #4] (DMA_RX_FRAME_infos->Seg_Count)++; 80354ac: 6891 ldr r1, [r2, #8] 80354ae: 3101 adds r1, #1 80354b0: 6091 str r1, [r2, #8] /* first segment is last segment */ if ((DMA_RX_FRAME_infos->Seg_Count)==1) 80354b2: 6891 ldr r1, [r2, #8] 80354b4: 2901 cmp r1, #1 DMA_RX_FRAME_infos->FS_Rx_Desc = DMARxDescToGet; 80354b6: bf08 it eq 80354b8: 6013 streq r3, [r2, #0] /* Get the Frame Length of the received packet: substruct 4 bytes of the CRC */ frame.length = ((DMARxDescToGet->Status & ETH_DMARxDesc_FL) >> ETH_DMARxDesc_FrameLengthShift) - 4; 80354ba: 6819 ldr r1, [r3, #0] /* Get the address of the buffer start address */ /* Check if more than one segment in the frame */ if (DMA_RX_FRAME_infos->Seg_Count >1) 80354bc: 6894 ldr r4, [r2, #8] /* first segment is last segment */ if ((DMA_RX_FRAME_infos->Seg_Count)==1) DMA_RX_FRAME_infos->FS_Rx_Desc = DMARxDescToGet; /* Get the Frame Length of the received packet: substruct 4 bytes of the CRC */ frame.length = ((DMARxDescToGet->Status & ETH_DMARxDesc_FL) >> ETH_DMARxDesc_FrameLengthShift) - 4; 80354be: f3c1 410d ubfx r1, r1, #16, #14 80354c2: 3904 subs r1, #4 /* Get the address of the buffer start address */ /* Check if more than one segment in the frame */ if (DMA_RX_FRAME_infos->Seg_Count >1) 80354c4: 2c01 cmp r4, #1 { frame.buffer =(DMA_RX_FRAME_infos->FS_Rx_Desc)->Buffer1Addr; 80354c6: bf8a itet hi 80354c8: 6812 ldrhi r2, [r2, #0] } else { frame.buffer = DMARxDescToGet->Buffer1Addr; 80354ca: 689a ldrls r2, [r3, #8] /* Get the address of the buffer start address */ /* Check if more than one segment in the frame */ if (DMA_RX_FRAME_infos->Seg_Count >1) { frame.buffer =(DMA_RX_FRAME_infos->FS_Rx_Desc)->Buffer1Addr; 80354cc: 6892 ldrhi r2, [r2, #8] } frame.descriptor = DMARxDescToGet; /* Update the ETHERNET DMA global Rx descriptor with next Rx descriptor */ DMARxDescToGet = (ETH_DMADESCTypeDef*) (DMARxDescToGet->Buffer2NextDescAddr); 80354ce: 4c0b ldr r4, [pc, #44] ; (80354fc ) 80354d0: 68dd ldr r5, [r3, #12] /* Return Frame */ return (frame); 80354d2: e880 0006 stmia.w r0, {r1, r2} } frame.descriptor = DMARxDescToGet; /* Update the ETHERNET DMA global Rx descriptor with next Rx descriptor */ DMARxDescToGet = (ETH_DMADESCTypeDef*) (DMARxDescToGet->Buffer2NextDescAddr); 80354d6: 6025 str r5, [r4, #0] 80354d8: e007 b.n 80354ea { FrameTypeDef frame={0,0,0}; __IO uint32_t descriptor_scan_counter = 0; /* scan descriptors owned by CPU */ while (((DMARxDescToGet->Status & ETH_DMARxDesc_OWN) == (uint32_t)RESET)&& 80354da: 6819 ldr r1, [r3, #0] 80354dc: 2900 cmp r1, #0 80354de: da06 bge.n 80354ee 80354e0: 4a06 ldr r2, [pc, #24] ; (80354fc ) 80354e2: 6013 str r3, [r2, #0] /* Return Frame */ return (frame); } } return (frame); 80354e4: 2300 movs r3, #0 80354e6: 6003 str r3, [r0, #0] 80354e8: 6043 str r3, [r0, #4] 80354ea: 6083 str r3, [r0, #8] 80354ec: e003 b.n 80354f6 FrameTypeDef frame={0,0,0}; __IO uint32_t descriptor_scan_counter = 0; /* scan descriptors owned by CPU */ while (((DMARxDescToGet->Status & ETH_DMARxDesc_OWN) == (uint32_t)RESET)&& (descriptor_scan_counterStatus & ETH_DMARxDesc_OWN) == (uint32_t)RESET)&& 80354f0: 2904 cmp r1, #4 80354f2: d9be bls.n 8035472 80354f4: e7f4 b.n 80354e0 /* Return Frame */ return (frame); } } return (frame); } 80354f6: bd3e pop {r1, r2, r3, r4, r5, pc} 80354f8: 200132d0 .word 0x200132d0 80354fc: 20011460 .word 0x20011460 08035500 : { uint32_t buf_count =0, size=0,i=0; __IO ETH_DMADESCTypeDef *DMATxNextDesc; /* Check if the descriptor is owned by the ETHERNET DMA (when set) or CPU (when reset) */ if((DMATxDescToSet->Status & ETH_DMATxDesc_OWN) != (u32)RESET) 8035500: 4b29 ldr r3, [pc, #164] ; (80355a8 ) 8035502: 681b ldr r3, [r3, #0] 8035504: 681a ldr r2, [r3, #0] 8035506: 2a00 cmp r2, #0 * @brief Prepares DMA Tx descriptors to transmit an ethernet frame * @param FrameLength : length of the frame to send * @retval error status */ uint32_t ETH_Prepare_Transmit_Descriptors(u16 FrameLength) { 8035508: b5f0 push {r4, r5, r6, r7, lr} uint32_t buf_count =0, size=0,i=0; __IO ETH_DMADESCTypeDef *DMATxNextDesc; /* Check if the descriptor is owned by the ETHERNET DMA (when set) or CPU (when reset) */ if((DMATxDescToSet->Status & ETH_DMATxDesc_OWN) != (u32)RESET) 803550a: db48 blt.n 803559e return ETH_ERROR; } DMATxNextDesc = DMATxDescToSet; if (FrameLength > ETH_TX_BUF_SIZE) 803550c: f240 52f4 movw r2, #1524 ; 0x5f4 8035510: 4290 cmp r0, r2 8035512: d917 bls.n 8035544 { buf_count = FrameLength/ETH_TX_BUF_SIZE; 8035514: fbb0 f4f2 udiv r4, r0, r2 if (FrameLength%ETH_TX_BUF_SIZE) buf_count++; 8035518: fb02 0214 mls r2, r2, r4, r0 803551c: b292 uxth r2, r2 DMATxNextDesc = DMATxDescToSet; if (FrameLength > ETH_TX_BUF_SIZE) { buf_count = FrameLength/ETH_TX_BUF_SIZE; 803551e: b2a1 uxth r1, r4 if (FrameLength%ETH_TX_BUF_SIZE) buf_count++; 8035520: b10a cbz r2, 8035526 8035522: 3101 adds r1, #1 8035524: e001 b.n 803552a } else buf_count =1; if (buf_count ==1) 8035526: 2901 cmp r1, #1 8035528: d00c beq.n 8035544 if (i== (buf_count-1)) { /* Setting the last segment bit */ DMATxNextDesc->Status |= ETH_DMATxDesc_LS; size = FrameLength - (buf_count-1)*ETH_TX_BUF_SIZE; 803552a: 4d20 ldr r5, [pc, #128] ; (80355ac ) 803552c: f200 50f4 addw r0, r0, #1524 ; 0x5f4 8035530: fb05 0501 mla r5, r5, r1, r0 DMATxNextDesc->ControlBufferSize = (size & ETH_DMATxDesc_TBS1); 8035534: 04ed lsls r5, r5, #19 8035536: 0ced lsrs r5, r5, #19 8035538: 461a mov r2, r3 803553a: 2000 movs r0, #0 /* Setting the first segment bit */ DMATxDescToSet->Status |= ETH_DMATxDesc_FS; } /* Program size */ DMATxNextDesc->ControlBufferSize = (ETH_TX_BUF_SIZE & ETH_DMATxDesc_TBS1); 803553c: f240 56f4 movw r6, #1524 ; 0x5f4 if (i== (buf_count-1)) 8035540: 1e4f subs r7, r1, #1 8035542: e00c b.n 803555e else buf_count =1; if (buf_count ==1) { /*set LAST and FIRST segment */ DMATxDescToSet->Status |=ETH_DMATxDesc_FS|ETH_DMATxDesc_LS; 8035544: 681a ldr r2, [r3, #0] /* Set frame size */ DMATxDescToSet->ControlBufferSize = (FrameLength& ETH_DMATxDesc_TBS1); 8035546: 04c0 lsls r0, r0, #19 else buf_count =1; if (buf_count ==1) { /*set LAST and FIRST segment */ DMATxDescToSet->Status |=ETH_DMATxDesc_FS|ETH_DMATxDesc_LS; 8035548: f042 5240 orr.w r2, r2, #805306368 ; 0x30000000 /* Set frame size */ DMATxDescToSet->ControlBufferSize = (FrameLength& ETH_DMATxDesc_TBS1); 803554c: 0cc0 lsrs r0, r0, #19 else buf_count =1; if (buf_count ==1) { /*set LAST and FIRST segment */ DMATxDescToSet->Status |=ETH_DMATxDesc_FS|ETH_DMATxDesc_LS; 803554e: 601a str r2, [r3, #0] /* Set frame size */ DMATxDescToSet->ControlBufferSize = (FrameLength& ETH_DMATxDesc_TBS1); 8035550: 6058 str r0, [r3, #4] /* Set Own bit of the Tx descriptor Status: gives the buffer back to ETHERNET DMA */ DMATxDescToSet->Status |= ETH_DMATxDesc_OWN; 8035552: 681a ldr r2, [r3, #0] 8035554: f042 4200 orr.w r2, r2, #2147483648 ; 0x80000000 8035558: 601a str r2, [r3, #0] DMATxDescToSet= (ETH_DMADESCTypeDef *)(DMATxDescToSet->Buffer2NextDescAddr); 803555a: 68da ldr r2, [r3, #12] 803555c: e014 b.n 8035588 } else { for (i=0; i< buf_count; i++) { if (i==0) 803555e: b918 cbnz r0, 8035568 { /* Setting the first segment bit */ DMATxDescToSet->Status |= ETH_DMATxDesc_FS; 8035560: 681c ldr r4, [r3, #0] 8035562: f044 5480 orr.w r4, r4, #268435456 ; 0x10000000 8035566: 601c str r4, [r3, #0] } /* Program size */ DMATxNextDesc->ControlBufferSize = (ETH_TX_BUF_SIZE & ETH_DMATxDesc_TBS1); if (i== (buf_count-1)) 8035568: 42b8 cmp r0, r7 /* Setting the first segment bit */ DMATxDescToSet->Status |= ETH_DMATxDesc_FS; } /* Program size */ DMATxNextDesc->ControlBufferSize = (ETH_TX_BUF_SIZE & ETH_DMATxDesc_TBS1); 803556a: 6056 str r6, [r2, #4] if (i== (buf_count-1)) 803556c: d104 bne.n 8035578 { /* Setting the last segment bit */ DMATxNextDesc->Status |= ETH_DMATxDesc_LS; 803556e: 6814 ldr r4, [r2, #0] 8035570: f044 5400 orr.w r4, r4, #536870912 ; 0x20000000 8035574: 6014 str r4, [r2, #0] size = FrameLength - (buf_count-1)*ETH_TX_BUF_SIZE; DMATxNextDesc->ControlBufferSize = (size & ETH_DMATxDesc_TBS1); 8035576: 6055 str r5, [r2, #4] } /*give back descriptor to DMA */ DMATxNextDesc->Status |= ETH_DMATxDesc_OWN; 8035578: 6814 ldr r4, [r2, #0] DMATxDescToSet->Status |= ETH_DMATxDesc_OWN; DMATxDescToSet= (ETH_DMADESCTypeDef *)(DMATxDescToSet->Buffer2NextDescAddr); } else { for (i=0; i< buf_count; i++) 803557a: 3001 adds r0, #1 size = FrameLength - (buf_count-1)*ETH_TX_BUF_SIZE; DMATxNextDesc->ControlBufferSize = (size & ETH_DMATxDesc_TBS1); } /*give back descriptor to DMA */ DMATxNextDesc->Status |= ETH_DMATxDesc_OWN; 803557c: f044 4400 orr.w r4, r4, #2147483648 ; 0x80000000 8035580: 6014 str r4, [r2, #0] DMATxDescToSet->Status |= ETH_DMATxDesc_OWN; DMATxDescToSet= (ETH_DMADESCTypeDef *)(DMATxDescToSet->Buffer2NextDescAddr); } else { for (i=0; i< buf_count; i++) 8035582: 4288 cmp r0, r1 } /*give back descriptor to DMA */ DMATxNextDesc->Status |= ETH_DMATxDesc_OWN; DMATxNextDesc = (ETH_DMADESCTypeDef *)(DMATxNextDesc->Buffer2NextDescAddr); 8035584: 68d2 ldr r2, [r2, #12] DMATxDescToSet->Status |= ETH_DMATxDesc_OWN; DMATxDescToSet= (ETH_DMADESCTypeDef *)(DMATxDescToSet->Buffer2NextDescAddr); } else { for (i=0; i< buf_count; i++) 8035586: d3ea bcc.n 803555e DMATxNextDesc->Status |= ETH_DMATxDesc_OWN; DMATxNextDesc = (ETH_DMADESCTypeDef *)(DMATxNextDesc->Buffer2NextDescAddr); /* Set Own bit of the Tx descriptor Status: gives the buffer back to ETHERNET DMA */ } DMATxDescToSet = DMATxNextDesc ; 8035588: 4b07 ldr r3, [pc, #28] ; (80355a8 ) 803558a: 601a str r2, [r3, #0] } /* When Tx Buffer unavailable flag is set: clear it and resume transmission */ if ((ETH->DMASR & ETH_DMASR_TBUS) != (u32)RESET) 803558c: 4b08 ldr r3, [pc, #32] ; (80355b0 ) 803558e: 695a ldr r2, [r3, #20] 8035590: 0750 lsls r0, r2, #29 8035592: d506 bpl.n 80355a2 { /* Clear TBUS ETHERNET DMA flag */ ETH->DMASR = ETH_DMASR_TBUS; 8035594: 2204 movs r2, #4 8035596: 615a str r2, [r3, #20] /* Resume DMA transmission*/ ETH->DMATPDR = 0; 8035598: 2200 movs r2, #0 803559a: 605a str r2, [r3, #4] 803559c: e001 b.n 80355a2 /* Check if the descriptor is owned by the ETHERNET DMA (when set) or CPU (when reset) */ if((DMATxDescToSet->Status & ETH_DMATxDesc_OWN) != (u32)RESET) { /* Return ERROR: OWN bit set */ return ETH_ERROR; 803559e: 2000 movs r0, #0 80355a0: bdf0 pop {r4, r5, r6, r7, pc} /* Resume DMA transmission*/ ETH->DMATPDR = 0; } /* Return SUCCESS */ return ETH_SUCCESS; 80355a2: 2001 movs r0, #1 } 80355a4: bdf0 pop {r4, r5, r6, r7, pc} 80355a6: bf00 nop 80355a8: 20011464 .word 0x20011464 80355ac: fffffa0c .word 0xfffffa0c 80355b0: 40029000 .word 0x40029000 080355b4 : { uint32_t i = 0; ETH_DMADESCTypeDef *DMARxDesc; /* Set the DMARxDescToGet pointer with the first one of the DMARxDescTab list */ DMARxDescToGet = DMARxDescTab; 80355b4: 4b11 ldr r3, [pc, #68] ; (80355fc ) * @param RxBuff: Pointer on the first RxBuffer list * @param RxBuffCount: Number of the used Rx desc in the list * @retval None */ void ETH_DMARxDescChainInit(ETH_DMADESCTypeDef *DMARxDescTab, uint8_t *RxBuff, uint32_t RxBuffCount) { 80355b6: b5f0 push {r4, r5, r6, r7, lr} uint32_t i = 0; ETH_DMADESCTypeDef *DMARxDesc; /* Set the DMARxDescToGet pointer with the first one of the DMARxDescTab list */ DMARxDescToGet = DMARxDescTab; 80355b8: 6018 str r0, [r3, #0] /* Fill each DMARxDesc descriptor with the right values */ for(i=0; i < RxBuffCount; i++) 80355ba: 2400 movs r4, #0 * @param DMARxDescTab: Pointer on the first Rx desc list * @param RxBuff: Pointer on the first RxBuffer list * @param RxBuffCount: Number of the used Rx desc in the list * @retval None */ void ETH_DMARxDescChainInit(ETH_DMADESCTypeDef *DMARxDescTab, uint8_t *RxBuff, uint32_t RxBuffCount) 80355bc: f100 0320 add.w r3, r0, #32 for(i=0; i < RxBuffCount; i++) { /* Get the pointer on the ith member of the Rx Desc list */ DMARxDesc = DMARxDescTab+i; /* Set Own bit of the Rx descriptor Status */ DMARxDesc->Status = ETH_DMARxDesc_OWN; 80355c0: f04f 4500 mov.w r5, #2147483648 ; 0x80000000 /* Set Buffer1 size and Second Address Chained bit */ DMARxDesc->ControlBufferSize = ETH_DMARxDesc_RCH | (uint32_t)ETH_RX_BUF_SIZE; 80355c4: f244 56f4 movw r6, #17908 ; 0x45f4 /* Set Buffer1 address pointer */ DMARxDesc->Buffer1Addr = (uint32_t)(&RxBuff[i*ETH_RX_BUF_SIZE]); /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (RxBuffCount-1)) 80355c8: 1e57 subs r7, r2, #1 ETH_DMADESCTypeDef *DMARxDesc; /* Set the DMARxDescToGet pointer with the first one of the DMARxDescTab list */ DMARxDescToGet = DMARxDescTab; /* Fill each DMARxDesc descriptor with the right values */ for(i=0; i < RxBuffCount; i++) 80355ca: e00f b.n 80355ec /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (RxBuffCount-1)) { /* Set next descriptor address register with next descriptor base address */ DMARxDesc->Buffer2NextDescAddr = (uint32_t)(DMARxDescTab+i+1); 80355cc: 42bc cmp r4, r7 80355ce: bf2c ite cs 80355d0: 4684 movcs ip, r0 80355d2: 469c movcc ip, r3 DMARxDesc->Status = ETH_DMARxDesc_OWN; /* Set Buffer1 size and Second Address Chained bit */ DMARxDesc->ControlBufferSize = ETH_DMARxDesc_RCH | (uint32_t)ETH_RX_BUF_SIZE; /* Set Buffer1 address pointer */ DMARxDesc->Buffer1Addr = (uint32_t)(&RxBuff[i*ETH_RX_BUF_SIZE]); 80355d4: f843 1c18 str.w r1, [r3, #-24] for(i=0; i < RxBuffCount; i++) { /* Get the pointer on the ith member of the Rx Desc list */ DMARxDesc = DMARxDescTab+i; /* Set Own bit of the Rx descriptor Status */ DMARxDesc->Status = ETH_DMARxDesc_OWN; 80355d8: f843 5c20 str.w r5, [r3, #-32] /* Set Buffer1 size and Second Address Chained bit */ DMARxDesc->ControlBufferSize = ETH_DMARxDesc_RCH | (uint32_t)ETH_RX_BUF_SIZE; 80355dc: f843 6c1c str.w r6, [r3, #-28] /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (RxBuffCount-1)) { /* Set next descriptor address register with next descriptor base address */ DMARxDesc->Buffer2NextDescAddr = (uint32_t)(DMARxDescTab+i+1); 80355e0: f843 cc14 str.w ip, [r3, #-20] ETH_DMADESCTypeDef *DMARxDesc; /* Set the DMARxDescToGet pointer with the first one of the DMARxDescTab list */ DMARxDescToGet = DMARxDescTab; /* Fill each DMARxDesc descriptor with the right values */ for(i=0; i < RxBuffCount; i++) 80355e4: 3401 adds r4, #1 80355e6: 3320 adds r3, #32 80355e8: f201 51f4 addw r1, r1, #1524 ; 0x5f4 80355ec: 4294 cmp r4, r2 80355ee: d1ed bne.n 80355cc DMARxDesc->Buffer2NextDescAddr = (uint32_t)(DMARxDescTab); } } /* Set Receive Descriptor List Address Register */ ETH->DMARDLAR = (uint32_t) DMARxDescTab; 80355f0: 4b03 ldr r3, [pc, #12] ; (8035600 ) DMA_RX_FRAME_infos = &RX_Frame_Descriptor; 80355f2: 4a04 ldr r2, [pc, #16] ; (8035604 ) DMARxDesc->Buffer2NextDescAddr = (uint32_t)(DMARxDescTab); } } /* Set Receive Descriptor List Address Register */ ETH->DMARDLAR = (uint32_t) DMARxDescTab; 80355f4: 60d8 str r0, [r3, #12] DMA_RX_FRAME_infos = &RX_Frame_Descriptor; 80355f6: 4b04 ldr r3, [pc, #16] ; (8035608 ) 80355f8: 601a str r2, [r3, #0] 80355fa: bdf0 pop {r4, r5, r6, r7, pc} 80355fc: 20011460 .word 0x20011460 8035600: 40029000 .word 0x40029000 8035604: 20011454 .word 0x20011454 8035608: 200132d0 .word 0x200132d0 0803560c : { uint32_t i = 0; ETH_DMADESCTypeDef *DMATxDesc; /* Set the DMATxDescToSet pointer with the first one of the DMATxDescTab list */ DMATxDescToSet = DMATxDescTab; 803560c: 4b0e ldr r3, [pc, #56] ; (8035648 ) * @param TxBuff: Pointer on the first TxBuffer list * @param TxBuffCount: Number of the used Tx desc in the list * @retval None */ void ETH_DMATxDescChainInit(ETH_DMADESCTypeDef *DMATxDescTab, uint8_t* TxBuff, uint32_t TxBuffCount) { 803560e: b5f0 push {r4, r5, r6, r7, lr} uint32_t i = 0; ETH_DMADESCTypeDef *DMATxDesc; /* Set the DMATxDescToSet pointer with the first one of the DMATxDescTab list */ DMATxDescToSet = DMATxDescTab; 8035610: 6018 str r0, [r3, #0] /* Fill each DMATxDesc descriptor with the right values */ for(i=0; i < TxBuffCount; i++) 8035612: 2400 movs r4, #0 * @param DMATxDescTab: Pointer on the first Tx desc list * @param TxBuff: Pointer on the first TxBuffer list * @param TxBuffCount: Number of the used Tx desc in the list * @retval None */ void ETH_DMATxDescChainInit(ETH_DMADESCTypeDef *DMATxDescTab, uint8_t* TxBuff, uint32_t TxBuffCount) 8035614: f100 0320 add.w r3, r0, #32 for(i=0; i < TxBuffCount; i++) { /* Get the pointer on the ith member of the Tx Desc list */ DMATxDesc = DMATxDescTab + i; /* Set Second Address Chained bit */ DMATxDesc->Status = ETH_DMATxDesc_TCH; 8035618: f44f 1580 mov.w r5, #1048576 ; 0x100000 /* Set Buffer1 address pointer */ DMATxDesc->Buffer1Addr = (uint32_t)(&TxBuff[i*ETH_TX_BUF_SIZE]); /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (TxBuffCount-1)) 803561c: 1e56 subs r6, r2, #1 ETH_DMADESCTypeDef *DMATxDesc; /* Set the DMATxDescToSet pointer with the first one of the DMATxDescTab list */ DMATxDescToSet = DMATxDescTab; /* Fill each DMATxDesc descriptor with the right values */ for(i=0; i < TxBuffCount; i++) 803561e: e00d b.n 803563c /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (TxBuffCount-1)) { /* Set next descriptor address register with next descriptor base address */ DMATxDesc->Buffer2NextDescAddr = (uint32_t)(DMATxDescTab+i+1); 8035620: 42b4 cmp r4, r6 8035622: bf2c ite cs 8035624: 4607 movcs r7, r0 8035626: 461f movcc r7, r3 DMATxDesc = DMATxDescTab + i; /* Set Second Address Chained bit */ DMATxDesc->Status = ETH_DMATxDesc_TCH; /* Set Buffer1 address pointer */ DMATxDesc->Buffer1Addr = (uint32_t)(&TxBuff[i*ETH_TX_BUF_SIZE]); 8035628: f843 1c18 str.w r1, [r3, #-24] for(i=0; i < TxBuffCount; i++) { /* Get the pointer on the ith member of the Tx Desc list */ DMATxDesc = DMATxDescTab + i; /* Set Second Address Chained bit */ DMATxDesc->Status = ETH_DMATxDesc_TCH; 803562c: f843 5c20 str.w r5, [r3, #-32] /* Initialize the next descriptor with the Next Descriptor Polling Enable */ if(i < (TxBuffCount-1)) { /* Set next descriptor address register with next descriptor base address */ DMATxDesc->Buffer2NextDescAddr = (uint32_t)(DMATxDescTab+i+1); 8035630: f843 7c14 str.w r7, [r3, #-20] ETH_DMADESCTypeDef *DMATxDesc; /* Set the DMATxDescToSet pointer with the first one of the DMATxDescTab list */ DMATxDescToSet = DMATxDescTab; /* Fill each DMATxDesc descriptor with the right values */ for(i=0; i < TxBuffCount; i++) 8035634: 3401 adds r4, #1 8035636: 3320 adds r3, #32 8035638: f201 51f4 addw r1, r1, #1524 ; 0x5f4 803563c: 4294 cmp r4, r2 803563e: d1ef bne.n 8035620 DMATxDesc->Buffer2NextDescAddr = (uint32_t) DMATxDescTab; } } /* Set Transmit Desciptor List Address Register */ ETH->DMATDLAR = (uint32_t) DMATxDescTab; 8035640: 4b02 ldr r3, [pc, #8] ; (803564c ) 8035642: 6118 str r0, [r3, #16] 8035644: bdf0 pop {r4, r5, r6, r7, pc} 8035646: bf00 nop 8035648: 20011464 .word 0x20011464 803564c: 40029000 .word 0x40029000 08035650 : { /* Check the parameters */ assert_param(IS_ETH_DMA_TXDESC_CHECKSUM(DMATxDesc_Checksum)); /* Set the selected DMA Tx desc checksum insertion control */ DMATxDesc->Status |= DMATxDesc_Checksum; 8035650: 6803 ldr r3, [r0, #0] 8035652: 4319 orrs r1, r3 8035654: 6001 str r1, [r0, #0] 8035656: 4770 bx lr 08035658 : * @param NewState: new state of the specified DMA Rx Desc interrupt. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_DMARxDescReceiveITConfig(ETH_DMADESCTypeDef *DMARxDesc, FunctionalState NewState) { 8035658: 6843 ldr r3, [r0, #4] /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 803565a: b111 cbz r1, 8035662 { /* Enable the DMA Rx Desc receive interrupt */ DMARxDesc->ControlBufferSize &=(~(uint32_t)ETH_DMARxDesc_DIC); 803565c: f023 4300 bic.w r3, r3, #2147483648 ; 0x80000000 8035660: e001 b.n 8035666 } else { /* Disable the DMA Rx Desc receive interrupt */ DMARxDesc->ControlBufferSize |= ETH_DMARxDesc_DIC; 8035662: f043 4300 orr.w r3, r3, #2147483648 ; 0x80000000 8035666: 6043 str r3, [r0, #4] 8035668: 4770 bx lr 803566a: 0000 movs r0, r0 0803566c : */ void ETH_SoftwareReset(void) { /* Set the SWR bit: resets all MAC subsystem internal registers and logic */ /* After reset all the registers holds their respective reset values */ ETH->DMABMR |= ETH_DMABMR_SR; 803566c: 4b02 ldr r3, [pc, #8] ; (8035678 ) 803566e: 681a ldr r2, [r3, #0] 8035670: f042 0201 orr.w r2, r2, #1 8035674: 601a str r2, [r3, #0] 8035676: 4770 bx lr 8035678: 40029000 .word 0x40029000 0803567c : * @retval The new state of DMA Bus Mode register SR bit (SET or RESET). */ FlagStatus ETH_GetSoftwareResetStatus(void) { FlagStatus bitstatus = RESET; if((ETH->DMABMR & ETH_DMABMR_SR) != (uint32_t)RESET) 803567c: 4b02 ldr r3, [pc, #8] ; (8035688 ) 803567e: 6818 ldr r0, [r3, #0] else { bitstatus = RESET; } return bitstatus; } 8035680: f000 0001 and.w r0, r0, #1 8035684: 4770 bx lr 8035686: bf00 nop 8035688: 40029000 .word 0x40029000 0803568c : FlagStatus ETH_GetDMAFlagStatus(uint32_t ETH_DMA_FLAG) { FlagStatus bitstatus = RESET; /* Check the parameters */ assert_param(IS_ETH_DMA_GET_IT(ETH_DMA_FLAG)); if ((ETH->DMASR & ETH_DMA_FLAG) != (uint32_t)RESET) 803568c: 4b03 ldr r3, [pc, #12] ; (803569c ) 803568e: 695b ldr r3, [r3, #20] 8035690: 4218 tst r0, r3 else { bitstatus = RESET; } return bitstatus; } 8035692: bf0c ite eq 8035694: 2000 moveq r0, #0 8035696: 2001 movne r0, #1 8035698: 4770 bx lr 803569a: bf00 nop 803569c: 40029000 .word 0x40029000 080356a0 : * @param NewState: new state of the specified ETHERNET DMA interrupts. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_DMAITConfig(uint32_t ETH_DMA_IT, FunctionalState NewState) { 80356a0: 4b04 ldr r3, [pc, #16] ; (80356b4 ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the selected ETHERNET DMA interrupts */ ETH->DMAIER |= ETH_DMA_IT; 80356a2: 69da ldr r2, [r3, #28] { /* Check the parameters */ assert_param(IS_ETH_DMA_IT(ETH_DMA_IT)); assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80356a4: b109 cbz r1, 80356aa { /* Enable the selected ETHERNET DMA interrupts */ ETH->DMAIER |= ETH_DMA_IT; 80356a6: 4310 orrs r0, r2 80356a8: e001 b.n 80356ae } else { /* Disable the selected ETHERNET DMA interrupts */ ETH->DMAIER &=(~(uint32_t)ETH_DMA_IT); 80356aa: ea22 0000 bic.w r0, r2, r0 80356ae: 61d8 str r0, [r3, #28] 80356b0: 4770 bx lr 80356b2: bf00 nop 80356b4: 40029000 .word 0x40029000 080356b8 : { /* Check the parameters */ assert_param(IS_ETH_DMA_IT(ETH_DMA_IT)); /* Clear the selected ETHERNET DMA IT */ ETH->DMASR = (uint32_t) ETH_DMA_IT; 80356b8: 4b01 ldr r3, [pc, #4] ; (80356c0 ) 80356ba: 6158 str r0, [r3, #20] 80356bc: 4770 bx lr 80356be: bf00 nop 80356c0: 40029000 .word 0x40029000 080356c4 : * @retval None */ void ETH_FlushTransmitFIFO(void) { /* Set the Flush Transmit FIFO bit */ ETH->DMAOMR |= ETH_DMAOMR_FTF; 80356c4: 4b02 ldr r3, [pc, #8] ; (80356d0 ) 80356c6: 699a ldr r2, [r3, #24] 80356c8: f442 1280 orr.w r2, r2, #1048576 ; 0x100000 80356cc: 619a str r2, [r3, #24] 80356ce: 4770 bx lr 80356d0: 40029000 .word 0x40029000 080356d4 : * @param NewState: new state of the DMA transmission. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_DMATransmissionCmd(FunctionalState NewState) { 80356d4: 4b04 ldr r3, [pc, #16] ; (80356e8 ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the DMA transmission */ ETH->DMAOMR |= ETH_DMAOMR_ST; 80356d6: 699a ldr r2, [r3, #24] void ETH_DMATransmissionCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80356d8: b110 cbz r0, 80356e0 { /* Enable the DMA transmission */ ETH->DMAOMR |= ETH_DMAOMR_ST; 80356da: f442 5200 orr.w r2, r2, #8192 ; 0x2000 80356de: e001 b.n 80356e4 } else { /* Disable the DMA transmission */ ETH->DMAOMR &= ~ETH_DMAOMR_ST; 80356e0: f422 5200 bic.w r2, r2, #8192 ; 0x2000 80356e4: 619a str r2, [r3, #24] 80356e6: 4770 bx lr 80356e8: 40029000 .word 0x40029000 080356ec : * @param NewState: new state of the DMA reception. * This parameter can be: ENABLE or DISABLE. * @retval None */ void ETH_DMAReceptionCmd(FunctionalState NewState) { 80356ec: 4b04 ldr r3, [pc, #16] ; (8035700 ) assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) { /* Enable the DMA reception */ ETH->DMAOMR |= ETH_DMAOMR_SR; 80356ee: 699a ldr r2, [r3, #24] void ETH_DMAReceptionCmd(FunctionalState NewState) { /* Check the parameters */ assert_param(IS_FUNCTIONAL_STATE(NewState)); if (NewState != DISABLE) 80356f0: b110 cbz r0, 80356f8 { /* Enable the DMA reception */ ETH->DMAOMR |= ETH_DMAOMR_SR; 80356f2: f042 0202 orr.w r2, r2, #2 80356f6: e001 b.n 80356fc } else { /* Disable the DMA reception */ ETH->DMAOMR &= ~ETH_DMAOMR_SR; 80356f8: f022 0202 bic.w r2, r2, #2 80356fc: 619a str r2, [r3, #24] 80356fe: 4770 bx lr 8035700: 40029000 .word 0x40029000 08035704 : * @brief Enables ENET MAC and DMA reception/transmission * @param None * @retval None */ void ETH_Start(void) { 8035704: b508 push {r3, lr} /* Enable transmit state machine of the MAC for transmission on the MII */ ETH_MACTransmissionCmd(ENABLE); 8035706: 2001 movs r0, #1 8035708: f7ff fe7a bl 8035400 /* Flush Transmit FIFO */ ETH_FlushTransmitFIFO(); 803570c: f7ff ffda bl 80356c4 /* Enable receive state machine of the MAC for reception from the MII */ ETH_MACReceptionCmd(ENABLE); 8035710: 2001 movs r0, #1 8035712: f7ff fe81 bl 8035418 /* Start DMA transmission */ ETH_DMATransmissionCmd(ENABLE); 8035716: 2001 movs r0, #1 8035718: f7ff ffdc bl 80356d4 /* Start DMA reception */ ETH_DMAReceptionCmd(ENABLE); 803571c: 2001 movs r0, #1 } 803571e: e8bd 4008 ldmia.w sp!, {r3, lr} ETH_MACReceptionCmd(ENABLE); /* Start DMA transmission */ ETH_DMATransmissionCmd(ENABLE); /* Start DMA reception */ ETH_DMAReceptionCmd(ENABLE); 8035722: f7ff bfe3 b.w 80356ec 8035726: 0000 movs r0, r0 08035728 : * @arg More PHY register could be read depending on the used PHY * @retval ETH_ERROR: in case of timeout * MAC MIIDR register value: Data read from the selected PHY register (correct read ) */ uint16_t ETH_ReadPHYRegister(uint16_t PHYAddress, uint16_t PHYReg) { 8035728: b082 sub sp, #8 uint32_t tmpreg = 0; __IO uint32_t timeout = 0; 803572a: 2300 movs r3, #0 803572c: 9301 str r3, [sp, #4] /* Check the parameters */ assert_param(IS_ETH_PHY_ADDRESS(PHYAddress)); assert_param(IS_ETH_PHY_REG(PHYReg)); /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; 803572e: 4b11 ldr r3, [pc, #68] ; (8035774 ) 8035730: 691a ldr r2, [r3, #16] /* Keep only the CSR Clock Range CR[2:0] bits value */ tmpreg &= ~MACMIIAR_CR_MASK; /* Prepare the MII address register value */ tmpreg |=(((uint32_t)PHYAddress<<11) & ETH_MACMIIAR_PA); /* Set the PHY device address */ 8035732: 06c0 lsls r0, r0, #27 assert_param(IS_ETH_PHY_REG(PHYReg)); /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; /* Keep only the CSR Clock Range CR[2:0] bits value */ tmpreg &= ~MACMIIAR_CR_MASK; 8035734: f002 021c and.w r2, r2, #28 /* Prepare the MII address register value */ tmpreg |=(((uint32_t)PHYAddress<<11) & ETH_MACMIIAR_PA); /* Set the PHY device address */ tmpreg |=(((uint32_t)PHYReg<<6) & ETH_MACMIIAR_MR); /* Set the PHY register address */ 8035738: 0189 lsls r1, r1, #6 /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; /* Keep only the CSR Clock Range CR[2:0] bits value */ tmpreg &= ~MACMIIAR_CR_MASK; /* Prepare the MII address register value */ tmpreg |=(((uint32_t)PHYAddress<<11) & ETH_MACMIIAR_PA); /* Set the PHY device address */ 803573a: ea42 4210 orr.w r2, r2, r0, lsr #16 tmpreg |=(((uint32_t)PHYReg<<6) & ETH_MACMIIAR_MR); /* Set the PHY register address */ 803573e: f401 61f8 and.w r1, r1, #1984 ; 0x7c0 tmpreg &= ~ETH_MACMIIAR_MW; /* Set the read mode */ 8035742: 430a orrs r2, r1 tmpreg |= ETH_MACMIIAR_MB; /* Set the MII Busy bit */ 8035744: f042 0201 orr.w r2, r2, #1 /* Write the result value into the MII Address register */ ETH->MACMIIAR = tmpreg; 8035748: 611a str r2, [r3, #16] /* Check for the Busy flag */ do { timeout++; tmpreg = ETH->MACMIIAR; } while ((tmpreg & ETH_MACMIIAR_MB) && (timeout < (uint32_t)PHY_READ_TO)); 803574a: 4a0b ldr r2, [pc, #44] ; (8035778 ) /* Write the result value into the MII Address register */ ETH->MACMIIAR = tmpreg; /* Check for the Busy flag */ do { timeout++; 803574c: 9901 ldr r1, [sp, #4] 803574e: 3101 adds r1, #1 8035750: 9101 str r1, [sp, #4] tmpreg = ETH->MACMIIAR; 8035752: 6919 ldr r1, [r3, #16] } while ((tmpreg & ETH_MACMIIAR_MB) && (timeout < (uint32_t)PHY_READ_TO)); 8035754: 07c9 lsls r1, r1, #31 8035756: d502 bpl.n 803575e 8035758: 9901 ldr r1, [sp, #4] 803575a: 4291 cmp r1, r2 803575c: d9f6 bls.n 803574c /* Return ERROR in case of timeout */ if(timeout == PHY_READ_TO) 803575e: 4b07 ldr r3, [pc, #28] ; (803577c ) 8035760: 9a01 ldr r2, [sp, #4] 8035762: 429a cmp r2, r3 { return (uint16_t)ETH_ERROR; } /* Return data register value */ return (uint16_t)(ETH->MACMIIDR); 8035764: bf1d ittte ne 8035766: 4b03 ldrne r3, [pc, #12] ; (8035774 ) 8035768: 6958 ldrne r0, [r3, #20] 803576a: b280 uxthne r0, r0 tmpreg = ETH->MACMIIAR; } while ((tmpreg & ETH_MACMIIAR_MB) && (timeout < (uint32_t)PHY_READ_TO)); /* Return ERROR in case of timeout */ if(timeout == PHY_READ_TO) { return (uint16_t)ETH_ERROR; 803576c: 2000 moveq r0, #0 } /* Return data register value */ return (uint16_t)(ETH->MACMIIDR); } 803576e: b002 add sp, #8 8035770: 4770 bx lr 8035772: bf00 nop 8035774: 40028000 .word 0x40028000 8035778: 0004fffe .word 0x0004fffe 803577c: 0004ffff .word 0x0004ffff 08035780 : * @param PHYValue: the value to write * @retval ETH_ERROR: in case of timeout * ETH_SUCCESS: for correct write */ uint32_t ETH_WritePHYRegister(uint16_t PHYAddress, uint16_t PHYReg, uint16_t PHYValue) { 8035780: b513 push {r0, r1, r4, lr} uint32_t tmpreg = 0; __IO uint32_t timeout = 0; 8035782: 2300 movs r3, #0 8035784: 9301 str r3, [sp, #4] /* Check the parameters */ assert_param(IS_ETH_PHY_ADDRESS(PHYAddress)); assert_param(IS_ETH_PHY_REG(PHYReg)); /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; 8035786: 4b0f ldr r3, [pc, #60] ; (80357c4 ) 8035788: 691c ldr r4, [r3, #16] tmpreg |=(((uint32_t)PHYAddress<<11) & ETH_MACMIIAR_PA); /* Set the PHY device address */ tmpreg |=(((uint32_t)PHYReg<<6) & ETH_MACMIIAR_MR); /* Set the PHY register address */ tmpreg |= ETH_MACMIIAR_MW; /* Set the write mode */ tmpreg |= ETH_MACMIIAR_MB; /* Set the MII Busy bit */ /* Give the value to the MII data register */ ETH->MACMIIDR = PHYValue; 803578a: 615a str r2, [r3, #20] assert_param(IS_ETH_PHY_REG(PHYReg)); /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; /* Keep only the CSR Clock Range CR[2:0] bits value */ tmpreg &= ~MACMIIAR_CR_MASK; 803578c: f004 041c and.w r4, r4, #28 /* Prepare the MII register address value */ tmpreg |=(((uint32_t)PHYAddress<<11) & ETH_MACMIIAR_PA); /* Set the PHY device address */ 8035790: f044 0403 orr.w r4, r4, #3 8035794: 06c0 lsls r0, r0, #27 tmpreg |=(((uint32_t)PHYReg<<6) & ETH_MACMIIAR_MR); /* Set the PHY register address */ 8035796: 0189 lsls r1, r1, #6 8035798: ea44 4410 orr.w r4, r4, r0, lsr #16 803579c: f401 61f8 and.w r1, r1, #1984 ; 0x7c0 tmpreg |= ETH_MACMIIAR_MW; /* Set the write mode */ tmpreg |= ETH_MACMIIAR_MB; /* Set the MII Busy bit */ 80357a0: 430c orrs r4, r1 /* Check for the Busy flag */ do { timeout++; tmpreg = ETH->MACMIIAR; } while ((tmpreg & ETH_MACMIIAR_MB) && (timeout < (uint32_t)PHY_WRITE_TO)); 80357a2: 4a09 ldr r2, [pc, #36] ; (80357c8 ) tmpreg |= ETH_MACMIIAR_MW; /* Set the write mode */ tmpreg |= ETH_MACMIIAR_MB; /* Set the MII Busy bit */ /* Give the value to the MII data register */ ETH->MACMIIDR = PHYValue; /* Write the result value into the MII Address register */ ETH->MACMIIAR = tmpreg; 80357a4: 611c str r4, [r3, #16] /* Check for the Busy flag */ do { timeout++; 80357a6: 9901 ldr r1, [sp, #4] 80357a8: 3101 adds r1, #1 80357aa: 9101 str r1, [sp, #4] tmpreg = ETH->MACMIIAR; 80357ac: 6919 ldr r1, [r3, #16] } while ((tmpreg & ETH_MACMIIAR_MB) && (timeout < (uint32_t)PHY_WRITE_TO)); 80357ae: 07c8 lsls r0, r1, #31 80357b0: d502 bpl.n 80357b8 80357b2: 9901 ldr r1, [sp, #4] 80357b4: 4291 cmp r1, r2 80357b6: d9f6 bls.n 80357a6 /* Return ERROR in case of timeout */ if(timeout == PHY_WRITE_TO) 80357b8: 9801 ldr r0, [sp, #4] return ETH_ERROR; } /* Return SUCCESS */ return ETH_SUCCESS; } 80357ba: 4b04 ldr r3, [pc, #16] ; (80357cc ) 80357bc: 1ac0 subs r0, r0, r3 80357be: bf18 it ne 80357c0: 2001 movne r0, #1 80357c2: bd1c pop {r2, r3, r4, pc} 80357c4: 40028000 .word 0x40028000 80357c8: 0004fffe .word 0x0004fffe 80357cc: 0004ffff .word 0x0004ffff 080357d0 : * @param PHYAddress: external PHY address * @retval ETH_ERROR: Ethernet initialization failed * ETH_SUCCESS: Ethernet successfully initialized */ uint32_t ETH_Init(ETH_InitTypeDef* ETH_InitStruct, uint16_t PHYAddress) { 80357d0: b5f0 push {r4, r5, r6, r7, lr} 80357d2: b087 sub sp, #28 uint32_t RegValue = 0, tmpreg = 0; __IO uint32_t i = 0; 80357d4: 2300 movs r3, #0 assert_param(IS_ETH_DMA_DESC_SKIP_LENGTH(ETH_InitStruct->ETH_DescriptorSkipLength)); assert_param(IS_ETH_DMA_ARBITRATION_ROUNDROBIN_RXTX(ETH_InitStruct->ETH_DMAArbitration)); /*-------------------------------- MAC Config ------------------------------*/ /*---------------------- ETHERNET MACMIIAR Configuration -------------------*/ /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; 80357d6: 4f90 ldr r7, [pc, #576] ; (8035a18 ) * ETH_SUCCESS: Ethernet successfully initialized */ uint32_t ETH_Init(ETH_InitTypeDef* ETH_InitStruct, uint16_t PHYAddress) { uint32_t RegValue = 0, tmpreg = 0; __IO uint32_t i = 0; 80357d8: 9300 str r3, [sp, #0] * @param PHYAddress: external PHY address * @retval ETH_ERROR: Ethernet initialization failed * ETH_SUCCESS: Ethernet successfully initialized */ uint32_t ETH_Init(ETH_InitTypeDef* ETH_InitStruct, uint16_t PHYAddress) { 80357da: 4604 mov r4, r0 uint32_t RegValue = 0, tmpreg = 0; __IO uint32_t i = 0; RCC_ClocksTypeDef rcc_clocks; uint32_t hclk = 60000000; __IO uint32_t timeout = 0; 80357dc: 9301 str r3, [sp, #4] /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; /* Clear CSR Clock Range CR[2:0] bits */ tmpreg &= MACMIIAR_CR_MASK; /* Get hclk frequency value */ RCC_GetClocksFreq(&rcc_clocks); 80357de: a802 add r0, sp, #8 * @param PHYAddress: external PHY address * @retval ETH_ERROR: Ethernet initialization failed * ETH_SUCCESS: Ethernet successfully initialized */ uint32_t ETH_Init(ETH_InitTypeDef* ETH_InitStruct, uint16_t PHYAddress) { 80357e0: 460e mov r6, r1 assert_param(IS_ETH_DMA_DESC_SKIP_LENGTH(ETH_InitStruct->ETH_DescriptorSkipLength)); assert_param(IS_ETH_DMA_ARBITRATION_ROUNDROBIN_RXTX(ETH_InitStruct->ETH_DMAArbitration)); /*-------------------------------- MAC Config ------------------------------*/ /*---------------------- ETHERNET MACMIIAR Configuration -------------------*/ /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; 80357e2: 693d ldr r5, [r7, #16] /* Clear CSR Clock Range CR[2:0] bits */ tmpreg &= MACMIIAR_CR_MASK; /* Get hclk frequency value */ RCC_GetClocksFreq(&rcc_clocks); 80357e4: f7ef ff4e bl 8025684 hclk = rcc_clocks.HCLK_Frequency; 80357e8: 9b03 ldr r3, [sp, #12] /* Set CR bits depending on hclk value */ if((hclk >= 20000000)&&(hclk < 35000000)) 80357ea: 4a8c ldr r2, [pc, #560] ; (8035a1c ) 80357ec: 498c ldr r1, [pc, #560] ; (8035a20 ) 80357ee: 189a adds r2, r3, r2 80357f0: 428a cmp r2, r1 /*-------------------------------- MAC Config ------------------------------*/ /*---------------------- ETHERNET MACMIIAR Configuration -------------------*/ /* Get the ETHERNET MACMIIAR value */ tmpreg = ETH->MACMIIAR; /* Clear CSR Clock Range CR[2:0] bits */ tmpreg &= MACMIIAR_CR_MASK; 80357f2: f025 051c bic.w r5, r5, #28 /* Get hclk frequency value */ RCC_GetClocksFreq(&rcc_clocks); hclk = rcc_clocks.HCLK_Frequency; /* Set CR bits depending on hclk value */ if((hclk >= 20000000)&&(hclk < 35000000)) 80357f6: d802 bhi.n 80357fe { /* CSR Clock Range between 20-35 MHz */ tmpreg |= (uint32_t)ETH_MACMIIAR_CR_Div16; 80357f8: f045 0508 orr.w r5, r5, #8 80357fc: e015 b.n 803582a } else if((hclk >= 35000000)&&(hclk < 60000000)) 80357fe: 4a89 ldr r2, [pc, #548] ; (8035a24 ) 8035800: 4989 ldr r1, [pc, #548] ; (8035a28 ) 8035802: 189a adds r2, r3, r2 8035804: 428a cmp r2, r1 8035806: d802 bhi.n 803580e { /* CSR Clock Range between 35-60 MHz */ tmpreg |= (uint32_t)ETH_MACMIIAR_CR_Div26; 8035808: f045 050c orr.w r5, r5, #12 803580c: e00d b.n 803582a } else if((hclk >= 60000000)&&(hclk < 100000000)) 803580e: 4a87 ldr r2, [pc, #540] ; (8035a2c ) 8035810: 4987 ldr r1, [pc, #540] ; (8035a30 ) 8035812: 189a adds r2, r3, r2 8035814: 428a cmp r2, r1 8035816: d908 bls.n 803582a { /* CSR Clock Range between 60-100 MHz */ tmpreg |= (uint32_t)ETH_MACMIIAR_CR_Div42; } else if((hclk >= 100000000)&&(hclk < 150000000)) 8035818: 4a86 ldr r2, [pc, #536] ; (8035a34 ) 803581a: 189a adds r2, r3, r2 803581c: 4b86 ldr r3, [pc, #536] ; (8035a38 ) 803581e: 429a cmp r2, r3 { /* CSR Clock Range between 100-150 MHz */ tmpreg |= (uint32_t)ETH_MACMIIAR_CR_Div62; 8035820: bf94 ite ls 8035822: f045 0504 orrls.w r5, r5, #4 } else /* ((hclk >= 150000000)&&(hclk <= 168000000)) */ { /* CSR Clock Range between 150-168 MHz */ tmpreg |= (uint32_t)ETH_MACMIIAR_CR_Div102; 8035826: f045 0510 orrhi.w r5, r5, #16 } /* Write to ETHERNET MAC MIIAR: Configure the ETHERNET CSR Clock Range */ ETH->MACMIIAR = (uint32_t)tmpreg; 803582a: 613d str r5, [r7, #16] /*-------------------- PHY initialization and configuration ----------------*/ /* Put the PHY in reset mode */ if(!(ETH_WritePHYRegister(PHYAddress, PHY_BCR, PHY_Reset))) 803582c: 4630 mov r0, r6 803582e: 2100 movs r1, #0 8035830: f44f 4200 mov.w r2, #32768 ; 0x8000 8035834: f7ff ffa4 bl 8035780 8035838: b908 cbnz r0, 803583e { /* Return ERROR in case of write timeout */ return ETH_ERROR; 803583a: 2000 movs r0, #0 803583c: e0e9 b.n 8035a12 } /* Delay to assure PHY reset */ _eth_delay_(PHY_RESET_DELAY); 803583e: 487f ldr r0, [pc, #508] ; (8035a3c ) 8035840: f7ff fd6e bl 8035320 if(ETH_InitStruct->ETH_AutoNegotiation != ETH_AutoNegotiation_Disable) 8035844: 6821 ldr r1, [r4, #0] 8035846: 2900 cmp r1, #0 8035848: d050 beq.n 80358ec { /* We wait for linked status... */ do { timeout++; } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_Linked_Status) && (timeout < PHY_READ_TO)); 803584a: 4d7d ldr r5, [pc, #500] ; (8035a40 ) if(ETH_InitStruct->ETH_AutoNegotiation != ETH_AutoNegotiation_Disable) { /* We wait for linked status... */ do { timeout++; 803584c: 9b01 ldr r3, [sp, #4] } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_Linked_Status) && (timeout < PHY_READ_TO)); 803584e: 4630 mov r0, r6 if(ETH_InitStruct->ETH_AutoNegotiation != ETH_AutoNegotiation_Disable) { /* We wait for linked status... */ do { timeout++; 8035850: 3301 adds r3, #1 } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_Linked_Status) && (timeout < PHY_READ_TO)); 8035852: 2101 movs r1, #1 if(ETH_InitStruct->ETH_AutoNegotiation != ETH_AutoNegotiation_Disable) { /* We wait for linked status... */ do { timeout++; 8035854: 9301 str r3, [sp, #4] } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_Linked_Status) && (timeout < PHY_READ_TO)); 8035856: f7ff ff67 bl 8035728 803585a: f000 0004 and.w r0, r0, #4 803585e: b280 uxth r0, r0 8035860: b910 cbnz r0, 8035868 8035862: 9b01 ldr r3, [sp, #4] 8035864: 42ab cmp r3, r5 8035866: d9f1 bls.n 803584c /* Return ERROR in case of timeout */ if(timeout == PHY_READ_TO) 8035868: 9a01 ldr r2, [sp, #4] 803586a: 4b76 ldr r3, [pc, #472] ; (8035a44 ) 803586c: 429a cmp r2, r3 803586e: d0e4 beq.n 803583a { return ETH_ERROR; } /* Reset Timeout counter */ timeout = 0; 8035870: 2100 movs r1, #0 /* Enable Auto-Negotiation */ if(!(ETH_WritePHYRegister(PHYAddress, PHY_BCR, PHY_AutoNegotiation))) 8035872: 4630 mov r0, r6 8035874: f44f 5280 mov.w r2, #4096 ; 0x1000 { return ETH_ERROR; } /* Reset Timeout counter */ timeout = 0; 8035878: 9101 str r1, [sp, #4] /* Enable Auto-Negotiation */ if(!(ETH_WritePHYRegister(PHYAddress, PHY_BCR, PHY_AutoNegotiation))) 803587a: f7ff ff81 bl 8035780 803587e: 2800 cmp r0, #0 8035880: d0db beq.n 803583a /* Wait until the auto-negotiation will be completed */ do { timeout++; } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_AutoNego_Complete) && (timeout < (uint32_t)PHY_READ_TO)); 8035882: 4d6f ldr r5, [pc, #444] ; (8035a40 ) } /* Wait until the auto-negotiation will be completed */ do { timeout++; 8035884: 9b01 ldr r3, [sp, #4] } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_AutoNego_Complete) && (timeout < (uint32_t)PHY_READ_TO)); 8035886: 4630 mov r0, r6 } /* Wait until the auto-negotiation will be completed */ do { timeout++; 8035888: 3301 adds r3, #1 } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_AutoNego_Complete) && (timeout < (uint32_t)PHY_READ_TO)); 803588a: 2101 movs r1, #1 } /* Wait until the auto-negotiation will be completed */ do { timeout++; 803588c: 9301 str r3, [sp, #4] } while (!(ETH_ReadPHYRegister(PHYAddress, PHY_BSR) & PHY_AutoNego_Complete) && (timeout < (uint32_t)PHY_READ_TO)); 803588e: f7ff ff4b bl 8035728 8035892: f000 0020 and.w r0, r0, #32 8035896: b280 uxth r0, r0 8035898: b910 cbnz r0, 80358a0 803589a: 9b01 ldr r3, [sp, #4] 803589c: 42ab cmp r3, r5 803589e: d9f1 bls.n 8035884 /* Return ERROR in case of timeout */ if(timeout == PHY_READ_TO) 80358a0: 9a01 ldr r2, [sp, #4] 80358a2: 4b68 ldr r3, [pc, #416] ; (8035a44 ) 80358a4: 429a cmp r2, r3 80358a6: d0c8 beq.n 803583a { return ETH_ERROR; } /* Reset Timeout counter */ timeout = 0; 80358a8: 2500 movs r5, #0 /* Read the result of the auto-negotiation */ RegValue = ETH_ReadPHYRegister(PHYAddress, PHY_SR); 80358aa: 211f movs r1, #31 80358ac: 4630 mov r0, r6 { return ETH_ERROR; } /* Reset Timeout counter */ timeout = 0; 80358ae: 9501 str r5, [sp, #4] /* Read the result of the auto-negotiation */ RegValue = ETH_ReadPHYRegister(PHYAddress, PHY_SR); 80358b0: f7ff ff3a bl 8035728 switch (RegValue & PHY_DUPLEX_SPEED_STATUS_MASK) 80358b4: f000 001c and.w r0, r0, #28 80358b8: 2808 cmp r0, #8 80358ba: d00b beq.n 80358d4 80358bc: d802 bhi.n 80358c4 80358be: 2804 cmp r0, #4 80358c0: d123 bne.n 803590a 80358c2: e010 b.n 80358e6 80358c4: 280e cmp r0, #14 80358c6: d00a beq.n 80358de 80358c8: 2812 cmp r0, #18 80358ca: d11e bne.n 803590a { case PHY_100BTX_FULL: ETH_InitStruct->ETH_Mode = ETH_Mode_FullDuplex; 80358cc: f44f 6300 mov.w r3, #2048 ; 0x800 80358d0: 6223 str r3, [r4, #32] 80358d2: e000 b.n 80358d6 ETH_InitStruct->ETH_Speed = ETH_Speed_100M; break; case PHY_100BTX_HALF: ETH_InitStruct->ETH_Mode = ETH_Mode_HalfDuplex; 80358d4: 6225 str r5, [r4, #32] ETH_InitStruct->ETH_Speed = ETH_Speed_100M; 80358d6: f44f 4380 mov.w r3, #16384 ; 0x4000 80358da: 6163 str r3, [r4, #20] break; 80358dc: e015 b.n 803590a case PHY_10M_FULL: ETH_InitStruct->ETH_Mode = ETH_Mode_FullDuplex; 80358de: f44f 6300 mov.w r3, #2048 ; 0x800 80358e2: 6223 str r3, [r4, #32] 80358e4: e000 b.n 80358e8 ETH_InitStruct->ETH_Speed = ETH_Speed_10M; break; case PHY_10M_HALF: ETH_InitStruct->ETH_Mode = ETH_Mode_HalfDuplex; 80358e6: 6225 str r5, [r4, #32] ETH_InitStruct->ETH_Speed = ETH_Speed_10M; 80358e8: 6165 str r5, [r4, #20] break; 80358ea: e00e b.n 803590a break; } } else { if(!ETH_WritePHYRegister(PHYAddress, PHY_BCR, ((uint16_t)(ETH_InitStruct->ETH_Mode >> 3) | 80358ec: 6a22 ldr r2, [r4, #32] (uint16_t)(ETH_InitStruct->ETH_Speed >> 1)))) 80358ee: 6963 ldr r3, [r4, #20] break; } } else { if(!ETH_WritePHYRegister(PHYAddress, PHY_BCR, ((uint16_t)(ETH_InitStruct->ETH_Mode >> 3) | 80358f0: 08d2 lsrs r2, r2, #3 80358f2: ea42 0253 orr.w r2, r2, r3, lsr #1 80358f6: 4630 mov r0, r6 80358f8: b292 uxth r2, r2 80358fa: f7ff ff41 bl 8035780 80358fe: 2800 cmp r0, #0 8035900: d09b beq.n 803583a { /* Return ERROR in case of write timeout */ return ETH_ERROR; } /* Delay to assure PHY configuration */ _eth_delay_(PHY_CONFIG_DELAY); 8035902: f06f 407f mvn.w r0, #4278190080 ; 0xff000000 8035906: f7ff fd0b bl 8035320 } /*------------------------ ETHERNET MACCR Configuration --------------------*/ /* Get the ETHERNET MACCR value */ tmpreg = ETH->MACCR; 803590a: 4b43 ldr r3, [pc, #268] ; (8035a18 ) /* Clear WD, PCE, PS, TE and RE bits */ tmpreg &= MACCR_CLEAR_MASK; 803590c: 4a4e ldr r2, [pc, #312] ; (8035a48 ) _eth_delay_(PHY_CONFIG_DELAY); } /*------------------------ ETHERNET MACCR Configuration --------------------*/ /* Get the ETHERNET MACCR value */ tmpreg = ETH->MACCR; 803590e: 6819 ldr r1, [r3, #0] /* Set the IPCO bit according to ETH_ChecksumOffload value */ /* Set the DR bit according to ETH_RetryTransmission value */ /* Set the ACS bit according to ETH_AutomaticPadCRCStrip value */ /* Set the BL bit according to ETH_BackOffLimit value */ /* Set the DC bit according to ETH_DeferralCheck value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_Watchdog | 8035910: 68a0 ldr r0, [r4, #8] } /*------------------------ ETHERNET MACCR Configuration --------------------*/ /* Get the ETHERNET MACCR value */ tmpreg = ETH->MACCR; /* Clear WD, PCE, PS, TE and RE bits */ tmpreg &= MACCR_CLEAR_MASK; 8035912: 400a ands r2, r1 /* Set the IPCO bit according to ETH_ChecksumOffload value */ /* Set the DR bit according to ETH_RetryTransmission value */ /* Set the ACS bit according to ETH_AutomaticPadCRCStrip value */ /* Set the BL bit according to ETH_BackOffLimit value */ /* Set the DC bit according to ETH_DeferralCheck value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_Watchdog | 8035914: 6861 ldr r1, [r4, #4] 8035916: 4308 orrs r0, r1 ETH_InitStruct->ETH_Jabber | 8035918: 68e1 ldr r1, [r4, #12] 803591a: 4308 orrs r0, r1 ETH_InitStruct->ETH_InterFrameGap | 803591c: 6921 ldr r1, [r4, #16] 803591e: 4308 orrs r0, r1 ETH_InitStruct->ETH_CarrierSense | 8035920: 6961 ldr r1, [r4, #20] 8035922: 4308 orrs r0, r1 ETH_InitStruct->ETH_Speed | 8035924: 69a1 ldr r1, [r4, #24] 8035926: 4308 orrs r0, r1 ETH_InitStruct->ETH_ReceiveOwn | 8035928: 69e1 ldr r1, [r4, #28] 803592a: 4308 orrs r0, r1 ETH_InitStruct->ETH_LoopbackMode | 803592c: 6a21 ldr r1, [r4, #32] 803592e: 4308 orrs r0, r1 ETH_InitStruct->ETH_Mode | 8035930: 6a61 ldr r1, [r4, #36] ; 0x24 8035932: 4308 orrs r0, r1 ETH_InitStruct->ETH_ChecksumOffload | 8035934: 6aa1 ldr r1, [r4, #40] ; 0x28 8035936: 4308 orrs r0, r1 ETH_InitStruct->ETH_RetryTransmission | 8035938: 6ae1 ldr r1, [r4, #44] ; 0x2c 803593a: 4308 orrs r0, r1 ETH_InitStruct->ETH_AutomaticPadCRCStrip | 803593c: 6b21 ldr r1, [r4, #48] ; 0x30 803593e: 4308 orrs r0, r1 /* Set the IPCO bit according to ETH_ChecksumOffload value */ /* Set the DR bit according to ETH_RetryTransmission value */ /* Set the ACS bit according to ETH_AutomaticPadCRCStrip value */ /* Set the BL bit according to ETH_BackOffLimit value */ /* Set the DC bit according to ETH_DeferralCheck value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_Watchdog | 8035940: 6b61 ldr r1, [r4, #52] ; 0x34 8035942: 4301 orrs r1, r0 8035944: 430a orrs r2, r1 ETH_InitStruct->ETH_RetryTransmission | ETH_InitStruct->ETH_AutomaticPadCRCStrip | ETH_InitStruct->ETH_BackOffLimit | ETH_InitStruct->ETH_DeferralCheck); /* Write to ETHERNET MACCR */ ETH->MACCR = (uint32_t)tmpreg; 8035946: 601a str r2, [r3, #0] /* Set the DAIF bit according to ETH_DestinationAddrFilter value */ /* Set the PR bit according to ETH_PromiscuousMode value */ /* Set the PM, HMC and HPF bits according to ETH_MulticastFramesFilter value */ /* Set the HUC and HPF bits according to ETH_UnicastFramesFilter value */ /* Write to ETHERNET MACFFR */ ETH->MACFFR = (uint32_t)(ETH_InitStruct->ETH_ReceiveAll | 8035948: 6ba2 ldr r2, [r4, #56] ; 0x38 803594a: 6be1 ldr r1, [r4, #60] ; 0x3c 803594c: 4311 orrs r1, r2 ETH_InitStruct->ETH_SourceAddrFilter | 803594e: 6c22 ldr r2, [r4, #64] ; 0x40 8035950: 4311 orrs r1, r2 ETH_InitStruct->ETH_PassControlFrames | 8035952: 6c62 ldr r2, [r4, #68] ; 0x44 8035954: 4311 orrs r1, r2 ETH_InitStruct->ETH_BroadcastFramesReception | 8035956: 6ca2 ldr r2, [r4, #72] ; 0x48 8035958: 4311 orrs r1, r2 ETH_InitStruct->ETH_DestinationAddrFilter | 803595a: 6ce2 ldr r2, [r4, #76] ; 0x4c 803595c: 4311 orrs r1, r2 ETH_InitStruct->ETH_PromiscuousMode | 803595e: 6d22 ldr r2, [r4, #80] ; 0x50 8035960: 4311 orrs r1, r2 /* Set the DAIF bit according to ETH_DestinationAddrFilter value */ /* Set the PR bit according to ETH_PromiscuousMode value */ /* Set the PM, HMC and HPF bits according to ETH_MulticastFramesFilter value */ /* Set the HUC and HPF bits according to ETH_UnicastFramesFilter value */ /* Write to ETHERNET MACFFR */ ETH->MACFFR = (uint32_t)(ETH_InitStruct->ETH_ReceiveAll | 8035962: 6d62 ldr r2, [r4, #84] ; 0x54 8035964: 430a orrs r2, r1 8035966: 605a str r2, [r3, #4] ETH_InitStruct->ETH_PromiscuousMode | ETH_InitStruct->ETH_MulticastFramesFilter | ETH_InitStruct->ETH_UnicastFramesFilter); /*--------------- ETHERNET MACHTHR and MACHTLR Configuration ---------------*/ /* Write to ETHERNET MACHTHR */ ETH->MACHTHR = (uint32_t)ETH_InitStruct->ETH_HashTableHigh; 8035968: 6da2 ldr r2, [r4, #88] ; 0x58 803596a: 609a str r2, [r3, #8] /* Write to ETHERNET MACHTLR */ ETH->MACHTLR = (uint32_t)ETH_InitStruct->ETH_HashTableLow; 803596c: 6de2 ldr r2, [r4, #92] ; 0x5c 803596e: 60da str r2, [r3, #12] /* Set the DZPQ bit according to ETH_ZeroQuantaPause value */ /* Set the PLT bit according to ETH_PauseLowThreshold value */ /* Set the UP bit according to ETH_UnicastPauseFrameDetect value */ /* Set the RFE bit according to ETH_ReceiveFlowControl value */ /* Set the TFE bit according to ETH_TransmitFlowControl value */ tmpreg |= (uint32_t)((ETH_InitStruct->ETH_PauseTime << 16) | 8035970: 6e62 ldr r2, [r4, #100] ; 0x64 8035972: 6ea1 ldr r1, [r4, #104] ; 0x68 ETH->MACHTHR = (uint32_t)ETH_InitStruct->ETH_HashTableHigh; /* Write to ETHERNET MACHTLR */ ETH->MACHTLR = (uint32_t)ETH_InitStruct->ETH_HashTableLow; /*----------------------- ETHERNET MACFCR Configuration --------------------*/ /* Get the ETHERNET MACFCR value */ tmpreg = ETH->MACFCR; 8035974: 6998 ldr r0, [r3, #24] /* Set the DZPQ bit according to ETH_ZeroQuantaPause value */ /* Set the PLT bit according to ETH_PauseLowThreshold value */ /* Set the UP bit according to ETH_UnicastPauseFrameDetect value */ /* Set the RFE bit according to ETH_ReceiveFlowControl value */ /* Set the TFE bit according to ETH_TransmitFlowControl value */ tmpreg |= (uint32_t)((ETH_InitStruct->ETH_PauseTime << 16) | 8035976: 4311 orrs r1, r2 ETH_InitStruct->ETH_ZeroQuantaPause | 8035978: 6ee2 ldr r2, [r4, #108] ; 0x6c 803597a: 4311 orrs r1, r2 ETH_InitStruct->ETH_PauseLowThreshold | 803597c: 6f22 ldr r2, [r4, #112] ; 0x70 803597e: 4311 orrs r1, r2 ETH_InitStruct->ETH_UnicastPauseFrameDetect | 8035980: 6f62 ldr r2, [r4, #116] ; 0x74 8035982: 4311 orrs r1, r2 ETH->MACHTLR = (uint32_t)ETH_InitStruct->ETH_HashTableLow; /*----------------------- ETHERNET MACFCR Configuration --------------------*/ /* Get the ETHERNET MACFCR value */ tmpreg = ETH->MACFCR; /* Clear xx bits */ tmpreg &= MACFCR_CLEAR_MASK; 8035984: f64f 7241 movw r2, #65345 ; 0xff41 8035988: 4002 ands r2, r0 /* Set the DZPQ bit according to ETH_ZeroQuantaPause value */ /* Set the PLT bit according to ETH_PauseLowThreshold value */ /* Set the UP bit according to ETH_UnicastPauseFrameDetect value */ /* Set the RFE bit according to ETH_ReceiveFlowControl value */ /* Set the TFE bit according to ETH_TransmitFlowControl value */ tmpreg |= (uint32_t)((ETH_InitStruct->ETH_PauseTime << 16) | 803598a: 430a orrs r2, r1 803598c: 6e21 ldr r1, [r4, #96] ; 0x60 803598e: ea42 4101 orr.w r1, r2, r1, lsl #16 ETH_InitStruct->ETH_PauseLowThreshold | ETH_InitStruct->ETH_UnicastPauseFrameDetect | ETH_InitStruct->ETH_ReceiveFlowControl | ETH_InitStruct->ETH_TransmitFlowControl); /* Write to ETHERNET MACFCR */ ETH->MACFCR = (uint32_t)tmpreg; 8035992: 6199 str r1, [r3, #24] /*----------------------- ETHERNET MACVLANTR Configuration -----------------*/ /* Set the ETV bit according to ETH_VLANTagComparison value */ /* Set the VL bit according to ETH_VLANTagIdentifier value */ ETH->MACVLANTR = (uint32_t)(ETH_InitStruct->ETH_VLANTagComparison | 8035994: 6fe1 ldr r1, [r4, #124] ; 0x7c 8035996: 6fa2 ldr r2, [r4, #120] ; 0x78 8035998: 430a orrs r2, r1 803599a: 61da str r2, [r3, #28] ETH_InitStruct->ETH_VLANTagIdentifier); /*-------------------------------- DMA Config ------------------------------*/ /*----------------------- ETHERNET DMAOMR Configuration --------------------*/ /* Get the ETHERNET DMAOMR value */ tmpreg = ETH->DMAOMR; 803599c: f503 5380 add.w r3, r3, #4096 ; 0x1000 /* Clear xx bits */ tmpreg &= DMAOMR_CLEAR_MASK; 80359a0: 4a2a ldr r2, [pc, #168] ; (8035a4c ) ETH_InitStruct->ETH_VLANTagIdentifier); /*-------------------------------- DMA Config ------------------------------*/ /*----------------------- ETHERNET DMAOMR Configuration --------------------*/ /* Get the ETHERNET DMAOMR value */ tmpreg = ETH->DMAOMR; 80359a2: 6999 ldr r1, [r3, #24] /* Set the TTC bit according to ETH_TransmitThresholdControl value */ /* Set the FEF bit according to ETH_ForwardErrorFrames value */ /* Set the FUF bit according to ETH_ForwardUndersizedGoodFrames value */ /* Set the RTC bit according to ETH_ReceiveThresholdControl value */ /* Set the OSF bit according to ETH_SecondFrameOperate value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame | 80359a4: f8d4 0084 ldr.w r0, [r4, #132] ; 0x84 /*-------------------------------- DMA Config ------------------------------*/ /*----------------------- ETHERNET DMAOMR Configuration --------------------*/ /* Get the ETHERNET DMAOMR value */ tmpreg = ETH->DMAOMR; /* Clear xx bits */ tmpreg &= DMAOMR_CLEAR_MASK; 80359a8: 400a ands r2, r1 /* Set the TTC bit according to ETH_TransmitThresholdControl value */ /* Set the FEF bit according to ETH_ForwardErrorFrames value */ /* Set the FUF bit according to ETH_ForwardUndersizedGoodFrames value */ /* Set the RTC bit according to ETH_ReceiveThresholdControl value */ /* Set the OSF bit according to ETH_SecondFrameOperate value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame | 80359aa: f8d4 1080 ldr.w r1, [r4, #128] ; 0x80 80359ae: 4308 orrs r0, r1 ETH_InitStruct->ETH_ReceiveStoreForward | 80359b0: f8d4 1088 ldr.w r1, [r4, #136] ; 0x88 80359b4: 4308 orrs r0, r1 ETH_InitStruct->ETH_FlushReceivedFrame | 80359b6: f8d4 108c ldr.w r1, [r4, #140] ; 0x8c 80359ba: 4308 orrs r0, r1 ETH_InitStruct->ETH_TransmitStoreForward | 80359bc: f8d4 1090 ldr.w r1, [r4, #144] ; 0x90 80359c0: 4308 orrs r0, r1 ETH_InitStruct->ETH_TransmitThresholdControl | 80359c2: f8d4 1094 ldr.w r1, [r4, #148] ; 0x94 80359c6: 4308 orrs r0, r1 ETH_InitStruct->ETH_ForwardErrorFrames | 80359c8: f8d4 1098 ldr.w r1, [r4, #152] ; 0x98 80359cc: 4308 orrs r0, r1 ETH_InitStruct->ETH_ForwardUndersizedGoodFrames | 80359ce: f8d4 109c ldr.w r1, [r4, #156] ; 0x9c 80359d2: 4308 orrs r0, r1 /* Set the TTC bit according to ETH_TransmitThresholdControl value */ /* Set the FEF bit according to ETH_ForwardErrorFrames value */ /* Set the FUF bit according to ETH_ForwardUndersizedGoodFrames value */ /* Set the RTC bit according to ETH_ReceiveThresholdControl value */ /* Set the OSF bit according to ETH_SecondFrameOperate value */ tmpreg |= (uint32_t)(ETH_InitStruct->ETH_DropTCPIPChecksumErrorFrame | 80359d4: f8d4 10a0 ldr.w r1, [r4, #160] ; 0xa0 80359d8: 4301 orrs r1, r0 80359da: 430a orrs r2, r1 ETH_InitStruct->ETH_ForwardErrorFrames | ETH_InitStruct->ETH_ForwardUndersizedGoodFrames | ETH_InitStruct->ETH_ReceiveThresholdControl | ETH_InitStruct->ETH_SecondFrameOperate); /* Write to ETHERNET DMAOMR */ ETH->DMAOMR = (uint32_t)tmpreg; 80359dc: 619a str r2, [r3, #24] /* Set the FB bit according to ETH_FixedBurst value */ /* Set the RPBL and 4*PBL bits according to ETH_RxDMABurstLength value */ /* Set the PBL and 4*PBL bits according to ETH_TxDMABurstLength value */ /* Set the DSL bit according to ETH_DesciptorSkipLength value */ /* Set the PR and DA bits according to ETH_DMAArbitration value */ ETH->DMABMR = (uint32_t)(ETH_InitStruct->ETH_AddressAlignedBeats | 80359de: f8d4 20a8 ldr.w r2, [r4, #168] ; 0xa8 80359e2: f8d4 10a4 ldr.w r1, [r4, #164] ; 0xa4 80359e6: 4311 orrs r1, r2 ETH_InitStruct->ETH_FixedBurst | ETH_InitStruct->ETH_RxDMABurstLength | /* !! if 4xPBL is selected for Tx or Rx it is applied for the other */ 80359e8: f8d4 20ac ldr.w r2, [r4, #172] ; 0xac /* Set the RPBL and 4*PBL bits according to ETH_RxDMABurstLength value */ /* Set the PBL and 4*PBL bits according to ETH_TxDMABurstLength value */ /* Set the DSL bit according to ETH_DesciptorSkipLength value */ /* Set the PR and DA bits according to ETH_DMAArbitration value */ ETH->DMABMR = (uint32_t)(ETH_InitStruct->ETH_AddressAlignedBeats | ETH_InitStruct->ETH_FixedBurst | 80359ec: f441 0100 orr.w r1, r1, #8388608 ; 0x800000 ETH_InitStruct->ETH_RxDMABurstLength | /* !! if 4xPBL is selected for Tx or Rx it is applied for the other */ 80359f0: 4311 orrs r1, r2 ETH_InitStruct->ETH_TxDMABurstLength | 80359f2: f8d4 20b0 ldr.w r2, [r4, #176] ; 0xb0 80359f6: 4311 orrs r1, r2 (ETH_InitStruct->ETH_DescriptorSkipLength << 2) | 80359f8: f8d4 20b8 ldr.w r2, [r4, #184] ; 0xb8 80359fc: 430a orrs r2, r1 80359fe: f8d4 10b4 ldr.w r1, [r4, #180] ; 0xb4 /* Set the FB bit according to ETH_FixedBurst value */ /* Set the RPBL and 4*PBL bits according to ETH_RxDMABurstLength value */ /* Set the PBL and 4*PBL bits according to ETH_TxDMABurstLength value */ /* Set the DSL bit according to ETH_DesciptorSkipLength value */ /* Set the PR and DA bits according to ETH_DMAArbitration value */ ETH->DMABMR = (uint32_t)(ETH_InitStruct->ETH_AddressAlignedBeats | 8035a02: ea42 0281 orr.w r2, r2, r1, lsl #2 8035a06: 601a str r2, [r3, #0] ETH_InitStruct->ETH_DMAArbitration | ETH_DMABMR_USP); /* Enable use of separate PBL for Rx and Tx */ #ifdef USE_ENHANCED_DMA_DESCRIPTORS /* Enable the Enhanced DMA descriptors */ ETH->DMABMR |= ETH_DMABMR_EDE; 8035a08: 681a ldr r2, [r3, #0] 8035a0a: f042 0280 orr.w r2, r2, #128 ; 0x80 8035a0e: 601a str r2, [r3, #0] #endif /* USE_ENHANCED_DMA_DESCRIPTORS */ /* Return Ethernet configuration success */ return ETH_SUCCESS; 8035a10: 2001 movs r0, #1 } 8035a12: b007 add sp, #28 8035a14: bdf0 pop {r4, r5, r6, r7, pc} 8035a16: bf00 nop 8035a18: 40028000 .word 0x40028000 8035a1c: feced300 .word 0xfeced300 8035a20: 00e4e1bf .word 0x00e4e1bf 8035a24: fde9f140 .word 0xfde9f140 8035a28: 017d783f .word 0x017d783f 8035a2c: fc6c7900 .word 0xfc6c7900 8035a30: 026259ff .word 0x026259ff 8035a34: fa0a1f00 .word 0xfa0a1f00 8035a38: 02faf07f .word 0x02faf07f 8035a3c: 000fffff .word 0x000fffff 8035a40: 0004fffe .word 0x0004fffe 8035a44: 0004ffff .word 0x0004ffff 8035a48: ff20810f .word 0xff20810f 8035a4c: f8de3f23 .word 0xf8de3f23 08035a50 <_sbrk>: extern char _ebss; // Defined by the linker extern char __bss_end__; static char *heap_end; char *prev_heap_end; if (heap_end == 0) { 8035a50: 4b0a ldr r3, [pc, #40] ; (8035a7c <_sbrk+0x2c>) 8035a52: 681a ldr r2, [r3, #0] 8035a54: b90a cbnz r2, 8035a5a <_sbrk+0xa> //heap_end = &_ebss; heap_end = &__bss_end__; 8035a56: 4a0a ldr r2, [pc, #40] ; (8035a80 <_sbrk+0x30>) 8035a58: 601a str r2, [r3, #0] } prev_heap_end = heap_end; 8035a5a: 681b ldr r3, [r3, #0] */ __attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_MSP(void) { register uint32_t result; __ASM volatile ("MRS %0, msp\n" : "=r" (result) ); 8035a5c: f3ef 8208 mrs r2, MSP char * stack = (char*) __get_MSP(); if (heap_end + incr > stack) 8035a60: 1818 adds r0, r3, r0 8035a62: 4290 cmp r0, r2 8035a64: d905 bls.n 8035a72 <_sbrk+0x22> { _write (STDERR_FILENO, "Heap and stack collision\n", 25); errno = ENOMEM; 8035a66: 4b07 ldr r3, [pc, #28] ; (8035a84 <_sbrk+0x34>) 8035a68: 220c movs r2, #12 8035a6a: 601a str r2, [r3, #0] return (caddr_t) -1; 8035a6c: f04f 33ff mov.w r3, #4294967295 8035a70: e001 b.n 8035a76 <_sbrk+0x26> //abort (); } heap_end += incr; 8035a72: 4a02 ldr r2, [pc, #8] ; (8035a7c <_sbrk+0x2c>) 8035a74: 6010 str r0, [r2, #0] return (caddr_t) prev_heap_end; } 8035a76: 4618 mov r0, r3 8035a78: 4770 bx lr 8035a7a: bf00 nop 8035a7c: 2000e514 .word 0x2000e514 8035a80: 2001523c .word 0x2001523c 8035a84: 20015138 .word 0x20015138 08035a88 : .weak Reset_Handler .type Reset_Handler, %function Reset_Handler: /* Copy the data segment initializers from flash to SRAM */ movs r1, #0 8035a88: 2100 movs r1, #0 b LoopCopyDataInit 8035a8a: f000 b804 b.w 8035a96 08035a8e : CopyDataInit: ldr r3, =_sidata 8035a8e: 4b0d ldr r3, [pc, #52] ; (8035ac4 ) ldr r3, [r3, r1] 8035a90: 585b ldr r3, [r3, r1] str r3, [r0, r1] 8035a92: 5043 str r3, [r0, r1] adds r1, r1, #4 8035a94: 3104 adds r1, #4 08035a96 : LoopCopyDataInit: ldr r0, =_sdata 8035a96: 480c ldr r0, [pc, #48] ; (8035ac8 ) ldr r3, =_edata 8035a98: 4b0c ldr r3, [pc, #48] ; (8035acc ) adds r2, r0, r1 8035a9a: 1842 adds r2, r0, r1 cmp r2, r3 8035a9c: 429a cmp r2, r3 bcc CopyDataInit 8035a9e: f4ff aff6 bcc.w 8035a8e ldr r2, =_sbss 8035aa2: 4a0b ldr r2, [pc, #44] ; (8035ad0 ) b LoopFillZerobss 8035aa4: f000 b803 b.w 8035aae 08035aa8 : /* Zero fill the bss segment. */ FillZerobss: movs r3, #0 8035aa8: 2300 movs r3, #0 str r3, [r2], #4 8035aaa: f842 3b04 str.w r3, [r2], #4 08035aae : LoopFillZerobss: ldr r3, = _ebss 8035aae: 4b09 ldr r3, [pc, #36] ; (8035ad4 ) cmp r2, r3 8035ab0: 429a cmp r2, r3 bcc FillZerobss 8035ab2: f4ff aff9 bcc.w 8035aa8 /* Call the clock system intitialization function.*/ bl SystemInit 8035ab6: f7f0 f965 bl 8025d84 /* Call static constructors */ bl __libc_init_array 8035aba: f7eb fee9 bl 8021890 <__libc_init_array> /* Call the application's entry point.*/ bl main 8035abe: f7f1 f9dd bl 8026e7c
bx lr 8035ac2: 4770 bx lr /* Copy the data segment initializers from flash to SRAM */ movs r1, #0 b LoopCopyDataInit CopyDataInit: ldr r3, =_sidata 8035ac4: 08040a10 .word 0x08040a10 ldr r3, [r3, r1] str r3, [r0, r1] adds r1, r1, #4 LoopCopyDataInit: ldr r0, =_sdata 8035ac8: 20000000 .word 0x20000000 ldr r3, =_edata 8035acc: 20001900 .word 0x20001900 adds r2, r0, r1 cmp r2, r3 bcc CopyDataInit ldr r2, =_sbss 8035ad0: 20001900 .word 0x20001900 FillZerobss: movs r3, #0 str r3, [r2], #4 LoopFillZerobss: ldr r3, = _ebss 8035ad4: 2001523c .word 0x2001523c 08035ad8 : * @retval None */ .section .text.Default_Handler,"ax",%progbits Default_Handler: Infinite_Loop: b Infinite_Loop 8035ad8: f7ff bffe b.w 8035ad8 08035adc <_ctype_>: 8035adc: 2000 2020 2020 2020 2020 2828 2828 2028 . ((((( 8035aec: 2020 2020 2020 2020 2020 2020 2020 2020 8035afc: 8820 1010 1010 1010 1010 1010 1010 1010 ............... 8035b0c: 0410 0404 0404 0404 0404 1004 1010 1010 ................ 8035b1c: 1010 4141 4141 4141 0101 0101 0101 0101 ..AAAAAA........ 8035b2c: 0101 0101 0101 0101 0101 0101 1010 1010 ................ 8035b3c: 1010 4242 4242 4242 0202 0202 0202 0202 ..BBBBBB........ 8035b4c: 0202 0202 0202 0202 0202 0202 1010 1010 ................ 8035b5c: 0020 0000 0000 0000 0000 0000 0000 0000 ............... 8035b6c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035b7c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035b8c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035b9c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035bac: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035bbc: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035bcc: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8035bdc: 0000 0000 .... 08035be0 : 8035be0: 89bc 97d8 d2b2 3c9c a733 d5a8 f623 3949 .......<3...#.I9 8035bf0: a73d 44f4 0ffd 32a5 979d cf8c ba08 255b =..D...2......[% 8035c00: 6f43 64ac 0628 0e18 Co.d(... 08035c08 : 8035c08: 0005 0000 0019 0000 007d 0000 0000 0000 ........}....... 08035c18 <__mprec_tens>: 8035c18: 0000 0000 0000 3ff0 0000 0000 0000 4024 .......?......$@ 8035c28: 0000 0000 0000 4059 0000 0000 4000 408f ......Y@.....@.@ 8035c38: 0000 0000 8800 40c3 0000 0000 6a00 40f8 .......@.....j.@ 8035c48: 0000 0000 8480 412e 0000 0000 12d0 4163 .......A......cA 8035c58: 0000 0000 d784 4197 0000 0000 cd65 41cd .......A....e..A 8035c68: 0000 2000 a05f 4202 0000 e800 4876 4237 ... _..B....vH7B 8035c78: 0000 a200 1a94 426d 0000 e540 309c 42a2 ......mB..@..0.B 8035c88: 0000 1e90 bcc4 42d6 0000 2634 6bf5 430c .......B..4&.k.C 8035c98: 8000 37e0 c379 4341 a000 85d8 3457 4376 ...7y.AC....W4vC 8035ca8: c800 674e c16d 43ab 3d00 6091 58e4 43e1 ..Ngm..C.=.`.X.C 8035cb8: 8c40 78b5 af1d 4415 ef50 d6e2 1ae4 444b @..x...DP.....KD 8035cc8: d592 064d f0cf 4480 4af6 c7e1 2d02 44b5 ..M....D.J...-.D 8035cd8: 9db4 79d9 7843 44ea ...yCx.D 08035ce0 <__mprec_tinytens>: 8035ce0: 89bc 97d8 d2b2 3c9c a733 d5a8 f623 3949 .......<3...#.I9 8035cf0: a73d 44f4 0ffd 32a5 979d cf8c ba08 255b =..D...2......[% 8035d00: 6f43 64ac 0628 0ac8 Co.d(... 08035d08 <__mprec_bigtens>: 8035d08: 8000 37e0 c379 4341 6e17 b505 b8b5 4693 ...7y.AC.n.....F 8035d18: f9f5 e93f 4f03 4d38 1d32 f930 7748 5a82 ..?..O8M2.0.Hw.Z 8035d28: bf3c 7f73 4fdd 7515 454c 5f44 6c42 6e69 <.s..O.uLED_Blin 8035d38: 006b 7542 7474 6e6f 0073 6e73 7074 6e4f k.Buttons.sntpOn 8035d48: 6563 6953 686e 6f72 7300 746e 5070 7265 ceSinhro.sntpPer 8035d58: 6f69 6964 5363 6e69 7268 006f 6e49 7469 iodicSinhro.Init 8035d68: 6154 6b73 4800 7261 4664 7561 746c 0a3a Task.HardFault:. 8035d78: 000d 0d0a 6552 6967 7473 7265 3a73 0d0a ....Registers:.. 8035d88: 5300 2050 2020 2020 2020 2020 3020 2578 .SP 0x% 8035d98: 3830 786c 0d0a 5200 2030 2020 2020 2020 08lx...R0 8035da8: 2020 3020 2578 3830 786c 0d0a 5200 2031 0x%08lx...R1 8035db8: 2020 2020 2020 2020 3020 2578 3830 786c 0x%08lx 8035dc8: 0d0a 5200 2032 2020 2020 2020 2020 3020 ...R2 0 8035dd8: 2578 3830 786c 0d0a 5200 2033 2020 2020 x%08lx...R3 8035de8: 2020 2020 3020 2578 3830 786c 0d0a 5200 0x%08lx...R 8035df8: 3231 2020 2020 2020 2020 3020 2578 3830 12 0x%08 8035e08: 786c 0d0a 4c00 2052 2020 2020 2020 2020 lx...LR 8035e18: 3020 2578 3830 786c 0d0a 5000 2043 2020 0x%08lx...PC 8035e28: 2020 2020 2020 3020 2578 3830 786c 0d0a 0x%08lx.. 8035e38: 5000 5253 2020 2020 2020 2020 3020 2578 .PSR 0x% 8035e48: 3830 786c 0d0a 2500 2e30 6631 2500 0064 08lx...%0.1f.%d. 8035e58: 3025 6934 252d 3230 2d69 3025 6932 2500 %04i-%02i-%02i.% 8035e68: 0073 6425 d020 d0b4 2ebd 2520 2064 87d1 s.%d ..... %d .. 8035e78: 202e 6425 d020 d0bc d0b8 2ebd 3100 302e . %d ........1.0 8035e88: 7400 7572 0065 6166 736c 0065 6e6f 2d00 .true.false.on.- 8035e98: 3130 252d 3230 3a69 3025 6932 2500 3230 01-%02i:%02i.%02 8035ea8: 2d69 3025 6932 252d 3230 2d69 3130 002d i-%02i-%02i-01-. 8035eb8: 3931 2e32 3631 2e38 2e31 0032 3931 2e32 192.168.1.2.192. 8035ec8: 3631 2e38 2e31 0031 3532 2e35 3532 2e35 168.1.1.255.255. 8035ed8: 3532 2e35 0030 7570 6c62 6369 4200 2d54 255.0.public.BT- 8035ee8: 3736 3130 3000 302e 302e 302e 3000 2e38 6701.0.0.0.0.08. 8035ef8: 3730 322e 3130 0036 4345 342d 2d43 4434 07.2016.EC-4C-4D 8035f08: 302d 2d30 3030 302d 0041 4e4b 302d 2d33 -00-00-0A.KN-03- 8035f18: 3030 3030 0031 6461 696d 006e 3231 3433 00001.admin.1234 8035f28: 0035 7375 7265 3100 3332 0034 3838 312e 5.user.1234.88.1 8035f38: 3734 322e 3435 322e 3533 6e00 6e6f 0065 47.254.235.none. 8035f48: 3231 2e37 2e30 2e30 0031 3254 4b4f 2000 127.0.0.1.T2OK. 8035f58: 7200 7165 6575 7473 745f 7361 006b 3151 .request_task.Q1 8035f68: 000d 4c54 000d 0054 0d51 5300 5200 4300 ..TL..T.Q..S.R.C 8035f78: 000d 5443 000d 0d49 4600 000d 4449 454c ..CT..I..F..IDLE 8035f88: 0900 6325 2509 0975 7525 2509 0d75 000a ..%c.%u.%u.%u... 8035f98: 6d54 2072 7653 0063 Tmr Svc. 08035fa0 : 8035fa0: 722f 746f 6b65 702e 676e 0000 5448 5054 /rotek.png..HTTP 8035fb0: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 8035fc0: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 8035fd0: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 8035fe0: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 8035ff0: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 8036000: 6e65 2d74 654c 676e 6874 203a 3935 3935 ent-Length: 5959 8036010: 0a0d 6f43 6e6e 6365 6974 6e6f 203a 6c43 ..Connection: Cl 8036020: 736f 0d65 430a 6e6f 6574 746e 742d 7079 ose..Content-typ 8036030: 3a65 6920 616d 6567 702f 676e 0a0d 6143 e: image/png..Ca 8036040: 6863 2d65 6f43 746e 6f72 3a6c 7020 6972 che-Control: pri 8036050: 6176 6574 202c 616d 2d78 6761 3d65 3638 vate, max-age=86 8036060: 3034 0d30 0d0a 890a 4e50 0d47 1a0a 000a 400.....PNG..... 8036070: 0000 490d 4448 0052 0100 0057 0000 08ae ...IHDR...W..... 8036080: 0006 0000 db82 7d4e 0000 0e17 4449 5441 ......N}....IDAT 8036090: da78 9ded ac7d 672c c059 a1cf 7a80 3285 x...}.,gY....z.2 80360a0: 4b45 1014 4db6 a62d ae0a b68a 52d8 45c7 EK...M-......R.E 80360b0: 4131 1b2d 1045 0b7a 7a53 bc69 6060 634d 1A-.E.z.Szi.``Mc 80360c0: d894 c326 6c55 d2ac c6c5 285e 2c91 951f ..&.Ul....^(.,.. 80360d0: 4a92 885d 4ad5 dd02 6a3f 9352 1ba2 36ac .J]..J..?jR....6 80360e0: a246 011b 6d69 e76b 72d2 71fb 7729 df7d F...imk..r.q)w}. 80360f0: 7793 9c75 cece 9fbc b333 7e7b fc7f 6f72 .wu.....3.{~..ro 8036100: 39ce fb3b bf39 e67d 9e79 79f7 9677 e5cb .9;.9.}.y..yw... 8036110: 000e f800 1785 0001 b900 0002 5720 0000 ............ W.. 8036120: 0ae4 0000 15c8 0000 02b9 2000 0057 4000 ........... W..@ 8036130: 00ae c800 0015 b900 0002 7200 0005 ae40 ...........r..@. 8036140: 0000 15c8 0000 2b90 0000 0572 4000 00ae .......+..r..@.. 8036150: 8000 015c 9000 002b 7200 0005 e400 000a ..\...+..r...... 8036160: 5c80 0001 2b90 0000 5720 0000 0ae4 8000 .\...+.. W...... 8036170: 015c 0000 02b9 2000 0057 e400 000a c800 \...... W....... 8036180: 0015 b900 0002 5720 0000 eae4 c19f 5f6b ...... W......k_ 8036190: 96b7 8fdd bede 440d 3882 9a47 ff23 def3 .......D.8G.#... 80361a0: 3c96 d6df ed38 377d 7e56 009e c824 3375 .<..8.}7V~..$.u3 80361b0: dae5 8c17 1304 5cc1 b4b0 de40 aa6e 138e .......\..@.n... 80361c0: 4d23 0ae4 75c8 ca3f 4655 89a5 6192 2966 #M...u?.UF...af) 80361d0: 3ad3 7532 44fc 1fdd 4522 80ae b75c ae56 .:2u.D.."E..\.V. 80361e0: 8ab1 974e 202d 3b45 a644 15c8 eb90 c936 ..N.- E;D.....6. 80361f0: 4655 8b8f a496 645a 3441 5c8b b901 ba6e UF....ZdA4.\..n. 8036200: bb5c d524 b4b2 08c1 22b9 4057 9bae d724 \.$......"W@..$. 8036210: a1d8 5530 2cc5 2450 231b e457 c801 cbb5 ..0U.,P$.#W..... 8036220: 9572 da97 0763 cdd1 edd5 1557 48ff 5db3 r...c.....W..H.] 8036230: 512b 9bb7 e63b 2364 0ae4 5c80 26bb bed7 +Q..;.d#...\.&.. 8036240: 0a45 5320 ae05 47a1 45b1 78ea 8b13 844e E. S...G.E.x..N. 8036250: 3f6c bd16 2b90 d720 caee 6475 7971 54df l?...+ ...udqy.T 8036260: 2951 48b1 8c27 2b91 7200 5b6d 13ae a943 Q).H'..+.rm[..C. 8036270: 95b6 ecdf 3c59 08d6 02b9 d720 e5a6 191a ....Y<.... ..... 8036280: 38e4 1d67 1a2a 0cf5 d922 7ef9 2c10 0572 .8g.*..."..~.,r. 8036290: dae4 b91d 8aea b5d5 a9dd 9857 1023 9c7b ..........W.#.{. 80362a0: 302b ccd4 cec9 7db7 017e 0572 dae4 b90d +0.....}~.r..... 80362b0: 8aea 6675 a521 caa1 ce77 722c 63b8 c28b ..uf!...w.,r.c.. 80362c0: a458 04ba 75f6 8b04 015c b6b9 572f b15d X....u..\.../W]. 80362d0: 86a6 9d42 faee ea5f 189a bd16 adf6 9160 ..B..._.......`. 80362e0: 202b 4d57 06b9 ec14 53d4 532b d2a4 a105 + WM.....S+S.... 80362f0: 6f57 4a65 3af4 ec52 a46b e609 15c8 2b90 WoeJ.:R.k......+ 8036300: f572 58cd 6443 8efd 892e 34cd 69a3 c11d r..XCd.....4.i.. 8036310: 904e 202b e457 8bea 07a1 f6b1 2d03 f55f N.+ W........-_. 8036320: d4bd 4755 09b0 0572 8ae4 7d5c 59e4 4733 ..UG..r...\}.Y3G 8036330: 8eb1 bb76 b435 7525 6c14 4db6 041d 15c8 ..v.5.%u.l.M.... 8036340: ab90 5c81 0a3d 2eb6 1acf 88d7 6279 9059 ...\=.......ybY. 8036350: 6b4a 0be6 e6ac 8c0a 872c d76e 122d 13a8 Jk......,.n.-... 8036360: 0cec 02b9 4572 a1ae 01d2 4f23 0c8b 4bf2 ....rE....#O...K 8036370: 5d62 af1f e749 5d41 4007 f0e2 91fc 202b b]..I.A].@....+ 8036380: e457 56ba 8b8e e89a 87d2 2758 2e01 4db1 W..V......X'...M 8036390: ba96 09d6 5c76 1e93 9088 202b 7dd7 5726 ....v\....+ .}&W 80363a0: c147 35a6 a185 51c8 f3ac 9606 eac4 752e G..5...Q.......u 80363b0: 13ad 7cec bb9b 9007 202b e6d7 5ae4 c457 ...|....+ ...ZW. 80363c0: 1d8a b472 8ba6 9a0c da9a af35 bfc9 dd56 ..r.......5...V. 80363d0: 87b6 015c eeb9 b933 0a5a b536 074c 01a4 ..\...3.Z.6.L... 80363e0: a5e6 9e46 0ae6 f6b8 8eb0 35b7 457a 80ae ..F........5zE.. 80363f0: 9b5c 6b91 d45d abda dad8 c7c5 8322 2155 \..k].......".U! 8036400: 6749 b5d8 f6e9 3ad9 1d82 7e7a 905d 202b Ig.....:..z~].+ 8036410: 6dd7 ab95 60a1 8b13 f9cb e2ba 8e97 2358 .m...`........X# 8036420: fc75 376c 52ec 9d57 d61e 22c8 f732 ea91 u.l7.RW...."2... 8036430: 0d58 f1ad 58c5 ae3d 2ab4 afda 6b91 8824 X....X=..*...k$. 8036440: a905 2c60 8198 9277 6bc2 323e bdbc 07ae ..`,..w..k>2.... 8036450: de5c 1ebf 7572 ec17 22c2 ab3a 074b 1ac4 \...ru...":.K... 8036460: 542d 52b6 19b5 5873 d827 4589 baf4 20f0 -T.R..sX'..E... 8036470: a6d7 a956 f38d 65ef 5c89 7523 cf82 4b05 ..V....e.\#u...K 8036480: ce08 f0a8 cffa 6e0c 2bab 89d7 63e5 04cb .......n.+...c.. 8036490: 227d 7757 f6b9 842d 73d3 85ec 049d 4892 }"Ww..-..s.....H 80364a0: 22dd c481 48b2 5a95 14a4 5f5c 50fb d7c8 ."...H.Z..\_.P.. 80364b0: ca3e b5c9 70e7 8212 713d 5ce1 0ccd 3b6e >....p..=q.\..n; 80364c0: 280e c5d6 ac4a d5c8 b05d 4555 be9b 36c5 .(..J...].UE...6 80364d0: 332f 8b8f 6c0c 9377 2c8d 1b3b be6c 5c4c /3...lw..,;.l.L\ 80364e0: 5b0a ddc3 e696 082d c6b9 24ea 7445 90ed .[....-....$Et.. 80364f0: 473f 8e7b 6f51 0af1 f6c4 63ea 6eae ce4f ?G{.Qo.....c.nO. 8036500: 93d5 1760 6d86 914a fae5 26fb aac4 5823 ..`..mJ....&..#X 8036510: 22db b4d5 39e2 e887 0e2b 77ca e07c cb33 ."...9..+..w|.3. 8036520: 5f0b 3177 6b92 4587 fce1 1d8c 5ea3 621f ._w1.k.E.....^.b 8036530: 169d 8ac5 dd5c dae4 b8b3 1fb4 1659 7478 ....\.......Y.xt 8036540: a897 3aae 7a01 8f25 6875 0ab8 a6cb 7607 ...:.z%.uh.....v 8036550: 916c b052 185d dd31 716d cd98 bf99 07fd l.R.].1.mq...... 8036560: ae88 8a1d d339 f0d4 91f6 b167 e84e 7016 ....9.....g.N..p 8036570: ab6c 9430 cf4c d230 aaad 8fb8 fd76 892e l.0.L.0.....v... 8036580: 348d cd66 6dd6 bd97 8c30 a344 5d00 8b03 .4f..m..0.D..].. 8036590: e536 8cfa bd3f d10d 43b5 90ea 5d1f 9c94 6...?....C...].. 80365a0: 7ddb 9cc3 6ead 018a 3ab9 7608 5862 ef05 .}...n...:.vbX.. 80365b0: 885b a7ac 06d1 5b65 8a14 3a35 fa0e 8b1e [.....e[..5:.... 80365c0: 3354 d3cf 5ab2 c51f a3f8 de87 ec85 679a T3...Z.........g 80365d0: 3858 e72f 510e 8baf 1358 5cfa ca3d 20b5 X8/..Q..X..\=.. 80365e0: 45d8 915d f0a6 a9f7 a445 f13b c8b4 f7c0 .E].....E.;..... 80365f0: c098 a2c8 5548 fcf5 be6d 9018 feeb 5fa4 ....HU..m......_ 8036600: 2738 a36d d8de ac52 c959 4063 beae 7ae4 8'm...R.Y.c@...z 8036610: fae0 4ee9 d4dd 57fd e9bc 45ad cf21 f2ea ...N...W...E!... 8036620: 059b d719 6cb5 1af9 52e2 d827 61be 73ce .....l...R'..a.s 8036630: 2161 d344 892f a2c4 accd 508a cd72 9537 a!D./......Pr.7. 8036640: 102f f7a3 814e 65be 99b4 68f8 42b5 feae /...N..e...h.B.. 8036650: dae5 7213 891d 9c76 a4a5 144c eff2 72f2 ...r..v...L....r 8036660: 2715 4ee1 ce5d dcf1 2e4b 8937 7d74 720f .'.N]...K.7.t}.r 8036670: 5919 a244 8255 0c8b dda3 7038 80a7 61af .YD.U.....8p...a 8036680: 3a35 cd72 8454 5654 8938 241d 6b1b 5a92 5:r.T.TV8..$.k.Z 8036690: 0de4 0363 ab4c b1e8 f267 e7af 22d0 b5ea ..c.L...g....".. 80366a0: eb15 cd7c 8a7b 2b5c 845e 87fc 5532 881f ..|.{.\+^...2U.. 80366b0: b455 9b61 598f b90a ab66 88e3 7093 ab26 U.a..Y..f....p&. 80366c0: dfcb d577 f7fb 2c84 795b 62f2 8f91 2563 ..w....,[y.b..c% 80366d0: 9cd7 8d60 5f8a f43f dff6 79da afe5 dc1c ..`.._?....y.... 80366e0: c9f9 5e37 23ba 6bee 95e7 bfaf ef64 1e98 ..7^.#.k....d... 80366f0: 440a 4599 c4b7 593a 9e66 2cbe 8666 6b51 .D.E..:Yf..,f.Qk 8036700: e388 7f2e cde2 56bf 0276 6af6 ba4e 52c8 .......Vv..jN..R 8036710: b1b0 49e6 3a9d 8244 1a3b dd8f f8a5 9be4 ...I.:D.;....... 8036720: e2d4 78f1 b56b ae42 27ff 9ed7 d6fa bb1a ...xk.B..'...... 8036730: d38a f217 14e4 9412 258f 2215 564c 1c97 .........%."LV.. 8036740: e235 8b4a 7d42 a5f9 bebf ae56 1fa2 e773 5.J.B}....V...s. 8036750: 5ffc f64d e67e a970 f7dd cb24 2799 9ab9 ._M.~.p...$..'.. 8036760: fd2c 849d ab92 6443 fb13 4cae 98e7 563a ,.....Cd...L..:V 8036770: 7dcf ee3e b038 675c 9c0d 13a7 b706 cbd4 .}>.8.\g........ 8036780: dd35 bc94 9092 5ce4 ba46 5fa7 e1fd 96bd 5......\F.._.... 8036790: b29f 97e2 a894 5ca9 166b 4444 7d16 a6bb .......\k.DD.}.. 80367a0: 9cb2 8c5a 3465 9c79 e2ae 6ed6 92ef 8def ..Z.e4y....n.... 80367b0: 914d b2c3 6dca 0512 0c2e b223 9190 1462 M....m....#...b. 80367c0: ae58 f3a1 c9d8 a980 db58 d725 08b2 ecf7 X.......X.%..... 80367d0: 8e2b 9dec 52d0 e72e 3c1d 2d64 9ad7 7608 +....R..... ..\.. 8036850: d542 5738 4ac0 bf2d f351 9fb7 28f8 5982 B.8W.J-.Q....(.Y 8036860: 10a6 4216 e3ae 6895 e575 26ba 9045 806e ...B...hu..&E.n. 8036870: 275c 9116 3aeb 3646 68cb 850b 91ac c9e5 \'...:F6.h...... 8036880: 0717 ab90 2569 34dc d195 eb76 7155 6b86 ....i%.4..v.Uq.k 8036890: c8c8 4235 0dae 62b7 d019 2753 fc90 a7c0 ..5B...b..S'.... 80368a0: 70aa 0f35 5a2d d119 810a b6f6 ae58 36b3 .p5.-Z......X..6 80368b0: 0e17 d214 4b01 ee8d 2680 3ae5 841e 14eb .....K...&.:.... 80368c0: b7e8 d620 c799 bae7 341c e9dc 5c80 621b .. ......4...\.b 80368d0: b425 07dc 1135 dbd2 5ceb 3108 4961 5cca %...5....\.1aI.\ 80368e0: 2076 c954 44b5 33b0 82c3 1b53 ed72 5892 v T..D.3..S.r..X 80368f0: 0ee7 099f 28d3 e473 b2f9 167d 8d38 fa11 .....(s...}.8... 8036900: 3cf2 8a74 39c2 457a edae 75c8 290f f93d ...6 8036980: 5791 145d ba15 7fc1 82da e35c f38a edaf .W].......\..... 8036990: 1a82 0d72 d724 62b4 b91d a8f7 1577 cad9 ..r.$..b....w... 80369a0: aa7c bc8f caad c6ff b905 2d8e cb06 ee84 |..........-.... 80369b0: 6d8b 407d 5cb6 b74d 6a26 6d75 3792 c2f9 .m}@.\M.&jum.7.. 80369c0: 0c5c 6fda 6ff0 3663 d442 a742 8b00 5a08 \..o.oc6B.B....Z 80369d0: 6b96 586c 8824 7894 b927 84ee 50c8 7bae .klX$..x'....P.{ 80369e0: 009d d2ea f7be 8b8a 1b2f 4929 16ba 620c ......../.)I...b 80369f0: 8dcb 6304 de8b 9b52 c37d 1f5a 2d90 d823 ...c..R.}.Z..-#. 8036a00: 8235 95b5 30eb 09c0 ba1e bfc1 1ded da07 5....0.......... 8036a10: 514c 90f4 736b ed72 445b d904 0f9a f690 LQ..ksr.[D...... 8036a20: 59e5 ae4e 423b 7bae d3b9 6895 225d 1fda .YN.;B.{...h]".. 8036a30: cb7f 4ce1 15e6 c50d 3a67 b042 a1e7 7fd1 ...L....g:B..... 8036a40: 56de ab31 dbd0 2aea d357 fc66 e7a1 6663 .V1....*W.f...cf 8036a50: 3b81 4c1b c187 d194 b00f e081 32dc 9f02 .;.L.........2.. 8036a60: d720 0b66 a65a b879 a7a9 fa0f 391e eeb9 .f.Z.y......9.. 8036a70: 3ffd 8b97 6d4a e12f 7e64 30b1 a654 09aa .?..Jm/.d~.0T... 8036a80: 6e7f 9c58 1c4a fd1b 1f5b 2d90 dcbe 2c7c .nX.J...[..-..|, 8036a90: 348f 17cd 0166 b872 e9a6 d0ab b3fd cca6 .4..f.r......... 8036aa0: c52d 391a c54c 21ea e6d7 3ae4 5c33 9daf -..9L..!...:3\.. 8036ab0: 4458 2326 bc75 d551 9b9b eb93 bbff bcf4 XD&#u.Q......... 8036ac0: f5e0 b66f 422a b9c8 6a06 c1a6 3578 a620 ..o.*B...j..x5 . 8036ad0: 55d0 b7d0 cb58 363f 3b4c 2eb8 1d7b 1c56 .U..X.?6L;..{.V. 8036ae0: 3527 fe1c c7b2 0ecb a6ff 6a8f 34f2 d450 '5.........j.4P. 8036af0: b214 1e0a 7fb2 67d6 a360 1afb 1236 22bd .......g`...6.." 8036b00: 7b57 86c6 4691 1964 2c49 690a b184 646e W{...Fd.I,.i..nd 8036b10: e420 8f9a 8d66 0e3a 9464 2226 54d9 faae ...f.:.d.&".T.. 8036b20: 912a c4eb 8262 c2d6 6871 e98b ec80 c6be *...b...qh...... 8036b30: 5792 4dd7 b309 11c0 6ea0 64c4 343b a77a .W.M.....n.d;4z. 8036b40: 5103 cfb1 9c94 14ae 26d3 57a2 6ae4 d0cf .Q.......&.W.j.. 8036b50: ef22 b53a e378 15fa ff09 d14a b92a 4f16 ".:.x.....J.*..O 8036b60: a36e 6d6f a139 2e4b cdad b5c9 772a f0ba n.om9.K.....*w.. 8036b70: 53b8 136e b203 8ea7 3572 6969 d9b2 69af .Sn.....r5ii...i 8036b80: 0832 2053 cd33 6715 0683 ebaa 9e81 7f6b 2.S 3..g......k. 8036b90: a04d 8593 5e8e ab91 913d 65c5 6257 8df9 M....^..=..eWb.. 8036ba0: 175f acf1 630a df5a a2ac 3580 8934 d446 _....cZ....54.F. 8036bb0: b20a e554 2746 b79e ef14 b6ed 2037 48db ..T.F'......7 .H 8036bc0: 15d8 badb 45d4 a382 91c0 9752 6406 7977 .....E....R..dwy 8036bd0: 185b cb1f 6367 dae4 0acc 99ad 1145 6162 [...gc......E.ba 8036be0: 1559 189e 965c 3525 cd72 8157 0667 ec51 Y...\.%5r.W.g.Q. 8036bf0: a2a2 a0ab 7b6a 85f0 be63 d435 ec80 d778 ....j{..c.5...x. 8036c00: 9edf 9359 89c2 b7d7 52b9 6cb0 eff2 80d2 ..Y......R.l.... 8036c10: 2eec f731 5858 4e34 207b 3757 1646 ad79 ..1.XX4N{ W7F.y. 8036c20: 61c4 b33d 8449 a992 e76f 855e ad5c 2b24 .a=.I...o.^.\.$+ 8036c30: abb7 2831 c564 5b16 bb8a 0a76 21a4 1ae4 ..1(d..[..v..!.. 8036c40: 0662 8584 5c14 e7ab 07a1 7764 ba89 3ae7 b....\....dw...: 8036c50: 1909 22bd 70d7 81a9 6599 3af4 c8d5 6539 ...".p...e.:..9e 8036c60: 1f16 58b2 4a33 8ad1 64b4 9714 25db 2aa1 ...X3J...d...%.* 8036c70: 9d6a faec f5d9 c435 6c80 e5a3 0db4 2109 j.....5..l.....! 8036c80: 68b3 09fb ecb9 9375 9ae5 fc0e c716 a28c .h....u......... 8036c90: e457 ceea e2d4 ae1b 292e d63f fa90 32c4 W........)?....2 8036ca0: d222 14a9 3a27 9702 9c91 01da b477 1ada "...':......w... 8036cb0: a07c 3dbf dcf8 df70 df2c b203 728d f2ae |..=..p.,....r.. 8036cc0: a48b b121 03f6 b65f 0e9b 4ec8 5836 f1ae ..!..._....N6X.. 8036cd0: 6fc0 8427 b1d1 6b91 a5d8 33b0 3c87 8e99 .o'....k...3.<.. 8036ce0: 7b04 b24a 91a6 42ec 1073 5688 22d4 6ea7 .{J....Bs..V.".n 8036cf0: 96c9 12ad 4eb9 862c b8c1 ceae 42ca d16c .....N,......Bl. 8036d00: bf2d 3a44 d628 1a26 7bfc 2c1b 5ed7 9cc0 -.D:(.&..{.,.^.. 8036d10: 0cf2 36b9 7233 6170 0df1 d3a7 620e 0972 ...63rpa.....br. 8036d20: 1c37 dfac 36d9 edcb 30c0 5c34 de57 f9d3 7....6...04\W... 8036d30: 9776 5b2d e3ab f46a 6691 6286 e935 3573 v.-[..j..f.b5.s5 8036d40: 0d99 ed3b 5c88 0e17 9aab 7642 b40a bdb9 ..;..\....Bv.... 8036d50: c84b 014e 435f 6269 1ae4 ae5e 6589 5675 K.N._Cib..^..euV 8036d60: 5be7 3273 bf08 a68b bcae bab3 b1d9 1252 .[s2..........R. 8036d70: be2f daf2 d6ba d4a9 ae42 edba e358 00dd /.......B...X... 8036d80: 1abb 9404 d4eb fdf1 a26d dfc1 47a6 6db7 ........m....G.m 8036d90: 0d66 3ea4 c866 99b5 d961 cb0b 3408 ccd1 f..>f...a....4.. 8036da0: f695 203b 48d8 3fa3 1330 9d72 44d6 91ad ..; .H.?0.r..D.. 8036db0: 5ca5 8d23 3368 2109 35d7 5b83 a35c a1d5 .\#.h3.!.5.[\... 8036dc0: f787 a9a4 ff06 4b7e 0763 1a9b 9d74 8ef9 ......~Kc...t... 8036dd0: 915e 336b d7b9 5cba 6e97 7343 301a cd8a ^.k3...\.nCs.0.. 8036de0: 58e7 35a7 aaf9 aeda ef82 723d 75d4 5645 .X.5......=r.uEV 8036df0: 0b5d 64d5 1e4d de36 b40d 971f e8a7 316d ]..dM.6.......m1 8036e00: b0f0 736d 9d43 6502 919f 8a91 bad8 da2e ..msC..e........ 8036e10: a0d1 ae99 0588 6d72 b226 399b 9114 ab74 ......rm&..9..t. 8036e20: 99ff c967 1546 07b3 eeaa 36a7 3d8a 8afb ..g.F......6.=.. 8036e30: ae23 021d 229d 9727 c5b9 3809 b1f6 057b #...."'....8..{. 8036e40: 0e6c d5c8 f6ff 992f 0f43 c8eb 5f22 5897 l...../.C..."_.X 8036e50: 768a d9a8 5069 f977 995a 958b 0c63 a32d .v..iPw.Z...c.-. 8036e60: 2eca b5ca e5f8 ab12 2cf7 435d 91dc 397c .........,]C..|9 8036e70: d720 d8ad 30a0 cc75 0d7b 2f2d e73f 9db9 ....0u.{.-/?... 8036e80: 860e c325 d387 375c cd81 4fe5 26bf 9dfa ..%...\7...O.&.. 8036e90: 08d5 3c76 df28 7671 e553 800a 5b5c fdd8 ..v<(.qvS...\[.. 8036ea0: 4eb5 8960 0446 ef3c ee48 a4ca b698 8bf6 .N`.F.<.H....... 8036eb0: bce5 8783 ad8a c85a 9015 722b cab5 6663 ......Z...+r..cf 8036ec0: f703 0245 a0e9 16dd 9b18 4802 f15c f798 ..E........H\... 8036ed0: 8b04 015c 22b9 90d7 03dd f2ba 39ea 980c ..\..".......9.. 8036ee0: d970 b2f1 f9a7 8cd8 6f22 d8b9 a1c0 0b15 p......."o...... 8036ef0: 02b9 4572 daae ac3d bdba 3d87 3395 150d ..rE..=....=.3.. 8036f00: 66c9 5206 77cd ac37 e45b 3550 c0ff dfa8 .f.R.w7.[.P5.... 8036f10: b912 7202 ae45 fdb6 7373 49c3 8948 14ea ...rE...ss.IH... 8036f20: 21f0 d35a 838e e2b2 5555 365e 16dd 22c1 .!Z.....UU^6..." 8036f30: 400c ddae ab92 0f6e 666b f8d1 5abc 3339 .@....n.kf...Z93 8036f40: f752 d551 bddc 2f9a c930 09b5 5cf9 9b02 R.Q..../0....\.. 8036f50: cc59 ddb0 c128 0c22 ae40 93dd e9ab 024e Y...(.".@.....N. 8036f60: 8ebd 507d 037a 69fd 89f7 fae1 64f4 0453 ..}Pz..i.....dS. 8036f70: 308b b900 5376 a6ae 2203 1dc6 4068 0c8f .0..vS..."..h@.. 8036f80: 163b 1ac6 7651 3ae6 1463 02b9 4572 d6ae ;...Qv.:c...rE.. 8036f90: a883 3507 b55b 1034 9aa9 81b6 0625 9ec7 ...5[.4.....%... 8036fa0: 98fb 8a65 015c 22b9 b2d7 ce08 9174 d4c0 ..e.\.."....t... 8036fb0: c0f3 aa8f b125 67a1 4691 cf25 617f a913 ....%..g.F%..a.. 8036fc0: 5723 ae40 d5c8 7c66 badf 7668 da25 87be #W@...f|..hv%... 8036fd0: 3508 d819 66ed 3ae0 b48b b04c f3b6 9146 .5...f.:..L...F. 8036fe0: 202b e457 bf6a 6029 174d b8c0 ae62 ac40 + W.j.)`M...b.@. 8036ff0: 9e7e 2f9f d2e0 e5c6 166b 9969 c760 c72e ~../....k.i.`... 8037000: ae44 5c80 6b91 96d7 b6ba ee31 9d70 8760 D..\.k....1.p.`. 8037010: 5e21 e463 c80a 7f75 d5ca 3aa6 c5df b125 !^c...u....:..%. 8037020: 043e 859b 94e8 ae40 5c80 aff7 8b5c 5d92 >.....@..\..\..] 8037030: 2474 6d52 5ba2 df21 35a6 7221 e405 5c8a t$Rm.[!..5!r...\ 8037040: 3343 6834 f7e0 69b9 d25e 73c2 bbed 5ce6 C34h...i^..s...\ 8037050: 2b91 5720 6ae4 cd13 5aae 7ca5 b447 750b .+ W.j...Z.|G..u 8037060: 64dc c5b0 f393 2b91 5720 aae4 db2b 0ed5 .d.....+ W..+... 8037070: 7503 0573 12f2 a99d 74c8 59d5 dbd0 1f2f .us......t.Y../. 8037080: e476 c80a 0015 9000 002b 7200 0005 ae40 v.......+..r..@. 8037090: 0000 5c80 0001 2b90 0000 0572 0000 0ae4 ...\...+..r..... 80370a0: 8000 015c 9000 002b 2000 0057 e400 000a ..\...+.. W..... 80370b0: 5c80 0001 b900 0002 5720 0000 0ae4 0000 .\...... W...... 80370c0: 15c8 0000 02b9 2000 0057 4000 00ae c800 ....... W..@.... 80370d0: 0015 b900 0002 7200 0005 ae40 0000 15c8 .......r..@..... 80370e0: 0000 2b90 0000 0572 4000 00ae fb00 ae5c ...+..r..@....\. 80370f0: f63f 6685 ca79 1883 db0e 3781 001f 6b90 ?..fy......7...k 8037100: b940 75b6 9aff 3f92 cb76 ad45 89c3 d002 @..u...?v.E..... 8037110: b96d 761e eb90 0433 0917 283e 82f8 41e0 m..v..3...>(...A 8037120: 49c1 23c1 7f82 dc13 7822 e087 0d79 f5cb .I.#...."x..y... 8037130: 824d 3af3 d72c 0b97 412e 00ae 2bdb 8bd7 M..:,....A...+.. 8037140: 9905 5c85 2e9f 4cb8 9ff0 a582 2706 d704 ...\...L.....'.. 8037150: be0b 01bb 1eb9 7c10 7045 60a7 83b7 dd72 .......|Ep.`..r. 8037160: dc15 f821 e09a c859 6015 e4fb 103a 213c ..!...Y..`..:...\?.F.:r.[ 8037450: 0a70 0572 2308 a4d7 9044 ac7f d621 9577 p.r..#..D...!.w. 8037460: eedc 6a4b 9665 c8e9 7cc1 7ae4 8543 de8c ..Kje....|.zC... 8037470: 905d 3dd7 bfaa 4ab5 7160 e661 8980 0f5c ]..=...J`qa...\. 8037480: f455 eab4 75c8 eea9 943f 2f5c b5c8 d95e U....u..?.\/..^. 8037490: 55c8 1872 02b9 9184 6cab fffa 495c d4fb .Ur......l..\I.. 80374a0: 2a6b 7924 e091 92c9 0245 5967 73ce e7cd k*$y....E.gY.s.. 80374b0: 6f5c 235b b7a2 a417 eff5 456a 9d56 df20 \o[#......jEV. . 80374c0: 996a 3d73 7055 079f ceb9 8a4b 3e6c 2ae4 j.s=Up....K.l>.* 80374d0: 0317 55dc 4d21 b95d 2fde 9088 402b 8298 ...U!M]../..+@.. 80374e0: 19d6 8782 b20b 4fbc 3df0 c31a 9658 572a .......O.=..X.*W 80374f0: ae7b b0c3 7cec c0b7 3531 35bf a12f 8583 {....|..15.5/... 8037500: a725 0472 59e1 c59a 8fa8 6ee5 9377 5c81 %.r..Y.....nw..\ 8037510: a9af bc99 2ba5 65d7 12e5 7b5e 26b9 c215 .....+.e..^{.&.. 8037520: 9134 e4ab e45a 100a 5bae 6de0 9725 b7f9 4...Z....[.m%... 8037530: c8a9 f576 cf37 7c13 f0a5 4f37 48aa 65d6 ..v.7..|..7O.H.e 8037540: 8227 3eaa d7d7 9e0a fdcc 01ee 4795 6dd5 '..>.........G.m 8037550: fffc 45ba eb9f 0bf7 f71e d728 52ff b091 ...E......(..R.. 8037560: b92f 5b3e af70 b947 109e 04bc 02b9 9184 /.>[p.G......... 8037570: 94ab 5fe8 0897 a476 7f7e 64a0 cb18 1653 ..._..v.~..d..S. 8037580: 3809 f36c b652 eb42 8555 5909 6252 1ae7 .8l.R.B.U..YRb.. 8037590: fe34 5717 3d68 5357 53ae 998d 26b1 9572 4..Wh=WS.S...&r. 80375a0: a1fc b947 5d5e 4b23 b953 6e4a ae45 e100 ..G.^]#KS.JnE... 80375b0: 1116 5f3c 50f0 9e41 0b8f 447e 5370 5889 ..<_.PA...~DpS.X 80375c0: f3af 87b8 a0d6 3664 f1c0 d4c2 9fa9 1036 ......d6......6. 80375d0: 4beb ab0a 74b3 0b67 4abc 2073 a9b7 1f5c .K...tg..Js ..\. 80375e0: 1157 abb1 cf5c f350 7d59 55cb 6af2 0ae4 W...\.P.Y}.U.j.. 80375f0: 6e10 d685 4b1b fa24 4988 ab2f 06c3 7f85 .n...K$..I/..... 8037600: 46b5 324c fd7a 0379 cab1 b4bd a5fe dfd0 .FL2z.y......... 8037610: 02fa b90d c2ca ddd3 729a e995 9b89 2715 .........r.....' 8037620: 6f34 69f3 720f 94fd 28a6 a84f ae19 0792 4o.i.r...(O..... 8037630: 6f34 8f73 e9e0 15c8 dc20 d7f2 28b2 cf35 4os..... ....(5. 8037640: aabc d597 ae41 2e2f 73cc ed5d f040 0306 ....A./..s].@... 8037650: feb1 daa0 70b4 9a59 ad6b eb96 cb61 656d .....pY.k...a.me 8037660: f84c 0719 c6b9 929a e174 c89d 2015 5c9c L.......t.... .\ 8037670: 134f 797c 588d 4165 85eb b701 2ed6 89db O.|y.XeA........ 8037680: e640 cf40 28d6 fd5e c39e 044e c872 fdcb @.@..(^...N.r... 8037690: 9206 57bc e4f5 50de 78f2 b8ab 6d5b 68bc ...W...P.x..[m.h 80376a0: d72a d453 563c 495d 213e 41b8 af71 edc1 *.S.!.Aq... 80376b0: 141e 177c 0572 3708 65b8 3250 f03e d511 ..|.r..7.eP2>... 80376c0: b58a 5013 abae b43d 978e b044 0bb7 54ae ...P..=...D....T 80376d0: 3fbf ed5f 25a5 cda3 af8f 7bc9 6f5e 87b0 .?_..%.....{^o.. 80376e0: b5d6 1186 69a8 35ce 61cf b90b 321e 408c .....i.5.a...2.@ 80376f0: 726d 2bae 43ae 00ae a761 bd62 b6cf cae5 mr.+.C..a.b..... 8037700: ae51 be92 eec3 8faf ee18 fafe 0603 d379 Q.............y. 8037710: dcfc 33d6 0f15 de1b 01f6 2915 caeb 54f5 ...3.......)...T 8037720: ecd5 226f 87c8 6705 ee2a bc32 1cad 7dae ..o"...g*.2....} 8037730: 720e 0805 5727 6339 1fe0 5c95 f0af 9e31 .r..'W9c...\..1. 8037740: 40d0 3bae f2ea f2f9 90c2 2aea a84e f568 .@.;.......*N.h. 8037750: ed74 fd35 dd4f a65e c629 7206 a3fd 7206 t.5.O.^.)..r...r 8037760: 45ad 8b3e 015c cec2 7d73 bad9 81f1 c80d .E>.\...s}...... 8037770: 3f35 fb14 9522 94df 5a83 541e fa82 5a86 5?.."....Z.T...Z 8037780: fb06 8217 a877 012e 21b3 76d5 bfbb c3fa ....w....!.v.... 8037790: b0df 60ec a270 9800 3ff3 637f aecb 24e6 ...`p....?.c...$ 80377a0: 24ed 0000 0000 4549 444e 42ae 8260 .$....IEND.B`. 080377ae : 80377ae: 6d2f 6961 2e6e 736a 0000 0000 5448 5054 /main.js....HTTP 80377be: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 80377ce: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 80377de: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 80377ee: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 80377fe: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 803780e: 6e65 2d74 654c 676e 6874 203a 3239 3136 ent-Length: 9261 803781e: 0a0d 6f43 6e6e 6365 6974 6e6f 203a 6c43 ..Connection: Cl 803782e: 736f 0d65 430a 6e6f 6574 746e 742d 7079 ose..Content-typ 803783e: 3a65 6120 7070 696c 6163 6974 6e6f 782f e: application/x 803784e: 6a2d 7661 7361 7263 7069 0d74 430a 6e6f -javascript..Con 803785e: 6574 746e 452d 636e 646f 6e69 3a67 6720 tent-Encoding: g 803786e: 697a 0d70 430a 6361 6568 432d 6e6f 7274 zip..Cache-Contr 803787e: 6c6f 203a 7270 7669 7461 2c65 6d20 7861 ol: private, max 803788e: 612d 6567 383d 3436 3030 0a0d 0a0d 8b1f -age=86400...... 803789e: 0008 0000 0000 0a04 7dcd 737b c71c e791 .........}{s.... 80378ae: 6957 caf4 b4e0 31a6 f018 c921 6833 804c Wi.....1..!.3hL. 80378be: 490f 23dc 1e29 4909 0bbb 88c2 d47e 34cc .I.#)..I....~..4 80378ce: d331 ea3d 21ee 1308 9088 ddec 46f5 b1d8 1.=..!.......F.. 80378de: f3ba dc5d 6c5d f3ec fbbf f693 3e99 f25a ..].]l.......>Z. 80378ee: 11c9 09f7 6f80 bf74 aacc aeea 19ee 9080 .....ot......... 80378fe: dde4 08bd 988b caae 657a 6665 abe5 c3ca ........zeef.... 803790e: 1279 7116 589a b56f e77c 2645 798a 5896 y..q.Xo.|.E&.y.X 803791e: 1a51 a7ce 2922 233a dc51 0899 79fa e8f3 Q..."):#Q....y.. 803792e: 046e 9388 86a1 fa1f b891 e49b cad4 e4ef n............... 803793e: d1c5 7444 99d2 c61f 91c5 75d7 a84b e5a0 ..Dt.......uK... 803794e: 78bc 67e6 e856 fccd 172c 4fef bf52 3568 .x.gV...,..OR.h5 803795e: 9de0 3c7e b56c b6c2 e9d7 735e 36b6 bc56 ..~...x?...e./..G. 803798e: 39c0 6939 f319 fc8c 7fc2 e79f a98a d30c .99i............ 803799e: 45ac f8fd aede ba1f e851 c9c6 10fe ddad .E......Q....... 80379ae: 5e74 1fc8 c3b3 0dcc 62fc f43f a867 444c t^.......b?.g.LD 80379be: 5fb6 e988 8a8c 788a 262a 5862 f9b8 f4c3 ._.....x*&bX.... 80379ce: 6450 7e6e 6513 3b22 73da af03 0fdb fd36 Pdn~.e";.s....6. 80379de: 44ce a324 dc62 da0f a76d cec4 b06e 4c67 .D$.b...m...n.gL 80379ee: 1c26 f08b 71e0 17e1 9302 70a9 e1f9 fdce &....q.....p.... 80379fe: 617b a826 e818 09a4 5e06 07b9 e2b2 dab6 {a&......^...... 8037a0e: ac12 4478 d1fb dc72 09b0 b6a3 65aa f147 ..xD..r......eG. 8037a1e: e033 1682 761b 1178 8034 f7e7 cec3 ce30 3....vx.4.....0. 8037a2e: e2f2 38d6 449e 277d f8e8 99b3 2248 04fe ...8.D}'....H".. 8037a3e: 5564 f4e7 2115 d504 e51c 5a8a 1bbe 6e2c dU...!.....Z..,n 8037a4e: d74e 5bd5 c51a 6cf9 1fe2 c179 b1f1 4c1d N..[...l..y....L 8037a5e: f0d2 aec0 2168 b454 bc10 1691 a202 1b85 ....h!T......... 8037a6e: d2e7 7042 5a59 1b08 90b4 2288 d817 64c8 ..BpYZ....."...d 8037a7e: ef94 6387 193f 2c09 3b1e 8982 0481 22ed ...c?..,.;....." 8037a8e: 0b9b f3db 4096 aead 98ae e2a5 08b9 85e7 .....@.......... 8037a9e: 9c88 cb17 414a 3cbf df41 f633 caf5 3626 ....JA..}.. 8037aee: bfb3 50b2 f2fa 8bec 9fb3 f200 141b 457e ...P..........~E 8037afe: af05 f3f0 6757 857f 7f7f cdc3 b1bf 12d0 ....Wg.......... 8037b0e: 7fa0 12a0 fdb4 7a35 9cf8 d0ea 17ec eb1d ......5z........ 8037b1e: 7ff4 2770 3b3f 657d 0001 58a3 fd68 4053 ..p'?;}e...Xh.S@ 8037b2e: f4fe 27ec dc34 a8af b3ef a1bf 9c19 dcfd ...'4........... 8037b3e: fd3a 45b5 9fc3 9c01 0160 d1bd 30b5 d7f9 :..E....`....0.. 8037b4e: 45a8 ce83 fae6 6b6c b7d3 99c6 7a18 9876 .E....lk.....zv. 8037b5e: a026 69ab 1c27 b6c5 4e15 3cfc ecf7 48a0 &..i'....N.<...H 8037b6e: fc2c 16b7 0ed1 f664 e9d6 2d3f d69b bae6 ,.....d...?-.... 8037b7e: b5bf 0eb9 6dac 015d 6b5f 1489 d1a4 6811 .....m]._k.....h 8037b8e: 173a 7159 8053 c1c2 6e31 32bd ea24 907e :.YqS...1n.2$.~. 8037b9e: 2246 eddf 39ee a2ae b7db 4d5a 3bc4 8e20 F"...9....ZM.; . 8037bae: 4e52 a7a1 27e9 24fe b486 3080 8454 5a0a RN...'.$...0T..Z 8037bbe: 2177 5c25 0ee1 91dd 763b f763 7ba9 4ee0 w!%\....;vc..{.N 8037bce: 69dc f7df 1fd0 3618 0fda e9d3 9e74 ea40 .i.....6....t.@. 8037bde: 0ed9 00e4 0f4a b8b3 b510 90e2 a78a e27e ....J.........~. 8037bee: b163 1f77 2e02 15aa 455c a889 5c95 c943 c.w.....\E...\C. 8037bfe: 56b0 1d72 a325 c95a 940d a98c 9e24 51f9 .Vr.%.Z.....$..Q 8037c0e: e194 a62b d1af 7e21 953d f990 7e01 d01f ..+...!~=....~.. 8037c1e: 2cef 07df 9ec2 d701 3b8e 0551 34b3 f02b .,.......;Q..4+. 8037c2e: 5539 079f 2b02 b260 884d 157e a3ff 346d 9U...+`.M.~...m4 8037c3e: 670e d3b6 c961 a225 e3e3 4296 b893 90fb .g..a.%....B.... 8037c4e: 1606 de79 bb1a 75b6 e1f7 a81a 37f7 9420 ..y....u.....7 . 8037c5e: 6757 585f 03a0 914d a3bf 205f 97b8 83b6 Wg_X..M..._ .... 8037c6e: e8c6 c37c 1771 88bb bb17 1bf8 c070 9edf ..|.q.......p... 8037c7e: effe 3437 ea7c a7da ad2f bfd3 1e27 fd38 ..74|.../...'.8. 8037c8e: 7e8a 1a4a 3c97 baf2 d41a 2571 4422 07e2 .~J..<....q%"D.. 8037c9e: 1113 4b55 5d5a b25d 83a4 f985 da3c 7dbe ..UKZ]].....<..} 8037cae: e3f7 92c7 3ef9 0c57 6cb4 0f4d d3e6 6440 .....>W..lM...@d 8037cbe: 09ad 203a 3eba 1cfb 742c b6d9 93db a419 ..: .>..,t...... 8037cce: 8e12 2cde 5b0e ea53 efe1 3388 2c2c d88e ...,.[S....3,,.. 8037cde: 35fb 2571 f990 f2d2 10c3 7f88 bf53 10cb .5q%........S... 8037cee: 521d ffaf ecc2 42cf 7ac0 e0fc 43fe a36b .R.....B.z...Ck. 8037cfe: 53c2 39b9 c9b5 aef8 08fd 6ee4 aadd 7dc8 .S.9.......n...} 8037d0e: 3761 0d6b d702 94fe e138 16c2 0915 4b45 a7k.....8.....EK 8037d1e: 05a7 58d6 a518 236a b696 f301 d05c b866 ...X..j#....\.f. 8037d2e: 0db4 ebd8 3682 a5a3 c06d 6580 a49b 2412 .....6..m..e...$ 8037d3e: a48b 27cd d4a6 4a81 2541 f4cf bcf2 c49e ...'...JA%...... 8037d4e: 3de0 72c5 89e6 9f6d 03fe 2c64 019d 412f .=.r..m...d,../A 8037d5e: af71 10c1 80bf 85c4 0730 4057 e37a b0b4 q.......0.W@z... 8037d6e: 41db 5edb ddb1 1ff5 aeb5 d8de aeed d8dd .A.^............ 8037d7e: be3b 3f8a f7d7 cff0 f70f 778e 1bbb 037b ;..?.......w..{. 8037d8e: c9fe 0cff 279c 7f9d b81f d6b7 053b 35f4 .....'......;..5 8037d9e: 7ea8 fccf 5cc9 8338 6e95 05af c486 9297 .~...\8..n...... 8037dae: 6bb9 fa41 4c1c 5359 1c49 d217 1162 8ab7 .kA..LYSI...b... 8037dbe: fec5 108d 36bb 7dd8 7512 daf6 41ad ac4f .....6.}.u...AO. 8037dce: 9e0d 6d44 f067 5d47 8d4d 2e6d 26b9 211c ..Dmg.G]M.m..&.! 8037dde: 3feb 2da2 d7f5 bc7e f6bd 7b17 b7ed 97d6 .?.-..~....{.... 8037dee: 0fd3 ac9d e35f 6758 a13a fa43 d39b 82df ...._.Xg:.C..... 8037dfe: f9f9 2754 80e5 80d4 b2df f978 1d05 00ea ..T'......x..... 8037e0e: 8906 457d f624 9535 99f2 724e 35f5 06a9 ..}E$.5...Nr.5.. 8037e1e: 13a4 457c 075a 09b4 eceb a1af fc3d c425 ..|EZ.......=.%. 8037e2e: cfdb 376d 23fa 6e6c 0f3e 71a6 3ef1 e1ce ..m7.#ln>..q.>.. 8037e3e: c71c 52af 5a1b e9f6 312f c61c 1a95 548b ...R.Z../1.....T 8037e4e: ce40 467e b553 bf48 29a1 3fe2 ce4c 94d4 @.~FS.H..).?L... 8037e5e: ad58 2ba9 bf46 45a3 6c0c d207 641e 1497 X..+F..E.l...d.. 8037e6e: b5b3 c138 56b9 d27e 18f9 41d3 ce97 0348 ..8..V~....A..H. 8037e7e: 77c8 edaf 5249 f3a5 04b1 d457 36eb 85d5 .w..IR....W..6.. 8037e8e: 7501 854a a410 b91d 2812 a6e8 5872 3757 .uJ......(..rXW7 8037e9e: de9d da32 5697 5694 95a1 6cfe 3fd0 a78c ..2..V.V...l.?.. 8037eae: cfe8 dfee 2983 6a40 1bb8 534a ea21 5697 .....)@j..JS!..V 8037ebe: 2a11 2c3f d98a 6923 0d1c 7112 d568 7a8b .*?,..#i...qh..z 8037ece: b454 830d 99ef b3f8 828f 22a7 5a2c fdf6 T..........",Z.. 8037ede: cc38 3cd2 161d 821d d9dd 0879 20ad 1a02 8..<......y.. .. 8037eee: d244 5c0a 85df c631 816a a3e8 2130 e79d D..\..1.j...0!.. 8037efe: 2728 4603 c82e 1ad3 f614 baec 45e7 cc30 ('.F.........E0. 8037f0e: c000 0e16 2b50 4050 f3c0 bddc edda 9e7a ....P+P@......z. 8037f1e: b418 8766 ddd1 56fc 659a 9b18 f3c1 b019 ..f....V.e...... 8037f2e: 762d f3c4 b5c2 6775 c250 a38b 4899 5687 -v....ugP....H.V 8037f3e: bab8 921a 984c b51c c722 81e9 f22c 9614 ....L..."...,... 8037f4e: 24e6 b51d 3bec 9659 a342 4e71 dd30 761c .$...;Y.B.qN0..v 8037f5e: 698c b1f5 f2ba d3f0 98db 3016 a61d a4f3 .i.........0.... 8037f6e: 3b58 7ccc e0da 58a5 e526 a180 5c60 e726 X;.|...X&...`\&. 8037f7e: 9502 e610 6450 4217 df9b 84c1 7ac9 32c3 ....Pd.B.....z.2 8037f8e: 583d 3043 4315 0858 9377 3c48 ea67 0d00 =XC0.CX.w.H\...Y:a..)- 803800e: 8aef dee0 95d0 2d1a d313 99f4 8658 c679 .......-....X.y. 803801e: ea85 02e8 8728 bf4f b772 08eb 3e5b 12bb ....(.O.r...[>.. 803802e: 0df8 3453 2ee1 8198 b6a2 1886 926c 12c5 ..S4........l... 803803e: 966c 04b4 3f5e 0b17 206f e589 3c2b 328f l...^?..o ..+<.2 803804e: 4c96 9162 1a3a d48c 8b24 f546 4922 012c .Lb.:...$.F."I,. 803805e: 1130 a8dd dd56 825f 0839 8acf 2e1e 6d01 0...V._.9......m 803806e: fb48 d84a 3e94 1ba1 747d 3771 d781 7a09 H.J..>..}tq7...z 803807e: 4b53 4b4b 38c8 3ba5 786e b05e eaba 0243 SKKK.8.;nx^...C. 803808e: 74ad f007 b0be 8b31 a26d a383 4105 53de .t....1.m....A.S 803809e: 2b00 0004 a051 699c a425 d934 71d7 0400 .+..Q..i%.4..q.. 80380ae: a85b d60f 4ad6 b8b9 b306 7604 500d 3952 [....J.....v.PR9 80380be: 0294 3837 3771 35c4 d263 2d64 ff6a 1616 ..78q7.5c.d-j... 80380ce: 375e 591e 6a0e 157b f222 a252 2c8b cbda ^7.Y.j{.".R..,.. 80380de: 4ec2 b27d 2f79 2d03 aff9 cb9c 9405 184c .N}.y/.-......L. 80380ee: 39e0 01bc 8d46 017d 8194 cca6 e28f 6e79 .9..F.}.......yn 80380fe: 0a20 fa16 6182 e8ca 4c32 8bf7 8df8 0966 ....a..2L....f. 803810e: 6950 5fd4 f006 2c90 0be0 ab26 643a c0b7 Pi._...,..&.:d.. 803811e: 7045 9112 2ce6 b92f d5af bf6c 0345 f59e Ep...,/...l.E... 803812e: e1e5 ece5 012f 6c6f 9c4d 530c c465 3c35 ..../.olM..Se.5< 803813e: d241 03eb 80fd 80d9 18ed f2e9 fcd1 8c03 A............... 803814e: 52ca f8f6 6790 8e08 5d5a 7ca8 9596 456f .R...g..Z].|..oE 803815e: 220d fd4c 2aff 3b14 bca8 7ca4 7293 aa4e ."L..*.;...|.rN. 803816e: d9fb b35f 19a1 1cd5 f527 b036 e1b5 8100 .._.....'.6..... 803817e: 85df 62d4 7ff6 2d7c 7cf5 cf76 7abd 7b63 ...b..|-.|v..zc{ 803818e: 04f8 d1d8 7bf0 07d8 61a4 c3c3 dec0 e906 .....{...a...... 803819e: 913d 4723 668b 7d58 df12 72cd 6279 ed91 =.#G.fX}...ryb.. 80381ae: fd32 c1ff 8178 bf39 7fe2 bb27 2a54 77fc 2...x.9...'.T*.w 80381be: 3841 2c7f e5cb 2c35 de7c e90b 3d62 52fb A8.,..5,|...b=.R 80381ce: 2e5a da4d 801c c9eb 437f 24e5 d8f7 6a84 Z.M......C.$...j 80381de: 377d 02e3 9ea1 7d3f d1fc ef83 5965 f3a8 }7....?}....eY.. 80381ee: f2e4 8606 c1fd 1d9d 1a5b 6419 2473 9917 ........[..ds$.. 80381fe: 1c17 71b7 7f45 ccd1 1bf0 8666 803f 41e5 ...qE.....f.?..A 803820e: e98b d070 45a9 4956 6665 70e0 096b 25b2 ..p..EVIef.pk..% 803821e: ada0 b52f 801d 5b89 dc1f 232d 6e31 a8a8 ../....[..-#1n.. 803822e: 0e13 885f f612 4364 c7c5 19f1 df7a 4cda .._...dC....z..L 803823e: 9d2d 5fe9 df48 1b3b d2a9 f39f f06b 6fec -.._H.;.....k..o 803824e: 89d8 c6c9 e9b6 d7d5 abc6 62e3 410e 7e9a ...........b.A.~ 803825e: 49cf 4440 dd90 8aff 48dd 0bff fc26 f14f .I@D.....H..&.O. 803826e: da4b 4bcc b71c 80df 30f6 7cf0 3a46 f7cf K..K.....0.|F:.. 803827e: 3d5b f856 722b 9160 8b33 0f22 6ad2 c8a7 [=V.+r`.3."..j.. 803828e: 6bc2 7d14 f675 a5d3 638e 3f1e b41c 1d02 .k.}u....c.?.... 803829e: abfc b4db 99e7 97b9 c627 5a40 26bb 0631 ........'.@Z.&1. 80382ae: 2250 5812 6494 f6fe a59e 6471 2b75 b801 P".X.d....qdu+.. 80382be: f13d 29b3 8a31 6d8e 0422 6321 d05a 10cd =..)1..m".!cZ... 80382ce: 4348 2c08 6186 07cd 9c2c 39ee 7d82 a79d HC.,.a..,..9.}.. 80382de: 9c69 9150 957b fdbc 68ad 6375 3373 b670 i.P.{....hucs3p. 80382ee: 02b6 fa2d d544 083f aa50 5006 f2fc b8c3 ..-.D.?.P..P.... 80382fe: c708 8c44 9fa1 ab0b 0bdb 23c0 7d07 d8fe ..D........#.}.. 803830e: 19e8 0c11 2690 da37 1f49 89fa 9898 0bd3 .....&7.I....... 803831e: 9ee0 5e79 82dc 8445 a8f3 a58f b471 c616 ..y^..E.....q... 803832e: 9a54 54c1 bfe5 606e 75e8 677e 67ea ed07 T..T..n`.u~g.g.. 803833e: 9ab0 f811 9fc8 8fe6 6204 f9a5 4218 0b4e .........b...BN. 803834e: 9b0b e47e 4269 3164 dbb0 fdf7 dc62 7cc9 ..~.iBd1....b..| 803835e: 6844 40a7 a95d 969f abfa 5c42 27c7 ba04 Dh.@].....B\.'.. 803836e: 9c37 bd7e 3ae0 7044 e4bd c75d 17ad 6b5c 7.~..:Dp..]...\k 803837e: 2016 509a 5887 7828 09a7 d571 43e9 6e6e . .P.X(x..q..Cnn 803838e: c2df 54fe 6cba 3c2d 7dbd 69cb 4dc3 4bfe ...T.l-<.}.i.M.K 803839e: 1eb6 5f6f 7800 04db b154 f3e4 55bb dc00 ..o_.x..T....U.. 80383ae: 7ff7 b9c1 3a4e 0e96 9f3c 4adf d443 219a ....N:..<..JC..! 80383be: 7d4c 0b7e 1254 0ff0 8078 14d9 b0a1 6c1a L}~.T...x......l 80383ce: b030 ff4f 7827 0e9e d7fa 0390 8ec4 f02a 0.O.'x........*. 80383de: b568 1e6e 10cd 73a3 9eec fa7d 219f fe0c h.n....s..}..!.. 80383ee: 2592 1d05 2f47 e1d9 25f7 d220 2f34 34ac .%..G/...% .4/.4 80383fe: 6eb3 c3ce 4703 918e 4793 36a8 ab48 2bbe .n...G...G.6H..+ 803840e: 1cd7 fa0c 140f c10e f6b9 7a92 67ff 9fc8 ...........z.g.. 803841e: 82df 7fef 214f fa47 fec1 4c6c 4be8 69db ....O!G...lL.K.i 803842e: 5a37 232f 818c 1d6d a75b 89ff 8ee6 294e 7Z/#..m.[.....N) 803843e: 8a2e 175e 6e9b 6060 8402 111b 401e 9444 ..^..n``.....@D. 803844e: b0ca 2be5 a786 503d fef1 fcda f46b 00a0 ...+..=P....k... 803845e: a42a 9956 e701 aa37 a860 ffdd 797d 518b *.V...7.`...}y.Q 803846e: 5d45 e349 a913 e704 ae37 f181 73ce 557c E]I.....7....s|U 803847e: b176 ed88 b23a 02c1 0690 f03b 8066 5a76 v...:.....;.f.vZ 803848e: de35 e695 8d5a bb35 06b0 34e9 27f3 a988 5...Z.5....4.'.. 803849e: e1c2 908a 3903 695c a03b 4246 24a9 8d31 .....9\i;.FB.$1. 80384ae: fa3d e41a 33f0 b72d 66e5 1a21 fa7c 03aa =....3-..f!.|... 80384be: 76a1 70fe 6037 3a1e 8627 0d7e f189 9110 .v.p7`.:'.~..... 80384ce: 9250 a568 1914 79c7 6691 2c47 6645 f4a8 P.h....y.fG,Ef.. 80384de: b6ec cd5f 6211 9b16 60a4 71f6 f90a 9bc0 .._..b...`.q.... 80384ee: d121 db3c e566 f43a 1c02 23f8 dc41 ce1d !.<.f.:....#A... 80384fe: 61e1 a784 9f02 6600 dcad 69f3 a9af 1264 .a.....f...i..d. 803850e: d3c3 c35c 6cbd 7398 04ca 19e9 1591 9627 ..\..l.s......'. 803851e: aff2 89c2 83a9 8dcf 4db0 1e01 a044 f776 .........M..D.v. 803852e: 7adc 58d8 7055 d9ba 7bf8 ee55 87f5 6e88 .z.XUp...{U....n 803853e: f21b dc2b f68d c1f4 b7d3 dd9d f70f 6e1f ..+............n 803854e: da3f bfbe 4ae7 e438 8c1d 99f7 f612 36ed ?....J8........6 803855e: da22 38b5 810b 2160 1bbb 90e8 c501 e033 "..8..`!......3. 803856e: 018e 2165 c1e5 0a70 e2c9 7728 b93e 60f3 ..e!..p...(w>..` 803857e: 6f67 c3a1 ee0d aaf0 90ee 4037 4875 1785 go........7@uH.. 803858e: f874 f6c9 8fbd 2cef 7876 3b95 5384 ce5e t......,vx.;.S^. 803859e: 7490 6611 5a23 90cd f59c f517 7b79 e77b .t.f#Z......y{{. 80385ae: cece fbdd ba4b 86bd 176e cb89 420c e709 ....K...n....B.. 80385be: d404 2b7d 0f4d 7862 9758 f4b8 9c6d 4b9d ..}+M.bxX...m..K 80385ce: 998a 7429 59b3 0e96 89e3 99cf 3a56 84f3 ..)t.Y......V:.. 80385de: 2dda af2b 4c35 a084 031c a1ce 0390 df55 .-+.5L........U. 80385ee: 00c8 089a d33f 3e7c 938d f102 fc7c 19eb ....?.|>....|... 80385fe: 68ec 0db2 3212 e25c 93c7 b78a b598 720a .h...2\........r 803860e: 831a ca1f 43c8 2692 4582 790d a551 5b0d .....C.&.E.yQ..[ 803861e: f7a1 e6ca 6378 f4eb 41bf 7c1a 5d0e 420e ....xc...A.|.].B 803862e: 6282 94e2 f26e 3a73 4e4f b77f 8eb9 ce7a .b..n.s:ON....z. 803863e: 5176 1ee9 d870 898a ffc5 45ae e862 27cf vQ..p......Eb..' 803864e: b205 285e c61d 5804 231b 8072 1ccc 83a4 ..^(...X.#r..... 803865e: 23fc 842b 82bf 7ebc 1329 3640 1667 2ceb .#+....~).@6g.., 803866e: 4d9e bf6c 9886 28e1 59e9 6621 b226 1a3e .Ml....(.Y!f&.>. 803867e: 57fc bf3e 1a58 34e1 6681 05f9 4766 22ff .W>.X..4.f..fG." 803868e: 00f1 febf 2756 c8a5 126c 1a53 d035 d503 ....V'..l.S.5... 803869e: cd86 4a8c 5b9b 4b2e fe9c 6525 a957 f8fa ...J.[.K..%eW... 80386ae: 3452 4621 09c4 2168 1809 3fa5 3a72 c548 R4!F..h!...?r:H. 80386be: a19d 074a ef19 366b 0944 83a7 f78c 1f35 ..J...k6D.....5. 80386ce: 84a1 41d3 24c6 350e 8423 9348 d831 d820 ...A.$.5#.H.1. . 80386de: 970d 044b 2171 6290 e1e8 4085 498a 1747 ..K.q!.b...@.IG. 80386ee: 5502 775c dcae 5895 4fc9 2bbe 1b21 4ae7 .U\w...X.O.+!..J 80386fe: ca02 0878 7ee1 2df9 37f4 90f9 9d27 31bd ..x..~.-.7..'..1 803870e: e341 a170 a108 f6df dc36 dcea 0632 659d A.p.....6...2..e 803871e: d9e2 1bb7 e914 7c8d aed8 d79d 0525 c8a0 .......|....%... 803872e: 7b5f f1eb 7427 d646 7e62 42d2 f529 4d6a _{..'tF.b~.B).jM 803873e: 86ac 5ba9 a080 d6eb 9f6e 776a 7452 0307 ...[....n.jwRt.. 803874e: d600 0e08 445a e9e1 2418 c6db 85e4 3179 ....ZD...$....y1 803875e: 6f7c 123f f421 1a45 9359 806a 15f3 86b9 |o?.!.E.Y.j..... 803876e: d85d dd38 547e 39a5 4846 0c73 7ec9 fb18 ].8.~T.9FHs..~.. 803877e: 2dd9 d9b4 102e 73a2 adc3 ab8d 0eef 6ff0 .-.....s.......o 803878e: eaf7 a075 7f0e 786e 385e bd08 ee8d 3bc6 ..u...nx^8.....; 803879e: 8dbd 2e8d b27d bced bdd1 5b06 a908 8f7e ....}......[..~. 80387ae: bf11 464a 619d 4e96 a96f 5abe dae1 d77b ..JF.a.No..Z..{. 80387be: 83df 8e91 396a f702 6dae 2325 712d ead9 ....j9...m%#-q.. 80387ce: c32a 330c 81c7 7c86 4a97 bd3e 9fea 0bfe *..3...|.J>..... 80387de: 864b ce6f 94be b1fe e9fe 277f 5641 8629 K.o........'AV). 80387ee: 687d 648b ff1e ecfe 27cb 13d9 e604 7204 }h.d.....'.....r 80387fe: 3527 863a b9c4 41c2 aaba 1dd8 b5ee 866d '5:....A......m. 803880e: fd60 4463 088a 08f2 3421 20cb 3125 db6a `.cD....!4. %1j. 803881e: da8b b170 a821 8de9 e51c 67a9 5293 5c6b ..p.!......g.Rk\ 803882e: 166f 2a5f 6b35 dc8c 43c4 36eb 1e58 5ed9 o._*5k...C.6X..^ 803883e: ca63 a5ce 2ddf 87e8 5b38 fbf9 043e 0c36 c....-..8[..>.6. 803884e: aab4 c3e0 9e74 a021 6aae 04e3 4271 d27c ....t.!..j..qB|. 803885e: a734 0c79 9301 ece5 94e5 f4a4 5b54 1cd8 4.y.........T[.. 803886e: 75fd 4ffa a53b c36a 6d69 3b2d 3317 cfaf .u.O;.j.im-;.3.. 803887e: 6e4b e49b 8232 c087 0e00 2927 bd19 1166 Kn..2.....')..f. 803888e: 4ca5 f252 8c10 f843 7cac cf04 1b72 e804 .LR...C..|..r... 803889e: 6dc6 13bb 48e6 0557 6ab0 2276 b926 3960 .m...HW..jv"&.`9 80388ae: e07c 90d9 7e6f 028f b1c0 668c 03ac 4fb8 |...o~.....f...O 80388be: 8724 ce33 14c3 ded6 ed73 c8b6 ae91 5a2b $.3.....s.....+Z 80388ce: 19cd ce4d dcd5 41a0 27f6 0e1d 2077 4fa1 ..M....A.'..w .O 80388de: c41a fd9e ce2c 20e3 ed86 d47e 21d3 09d9 ....,.. ..~..!.. 80388ee: 2030 d1f9 33d3 34ad ce3a 3445 8575 d209 0 ...3.4:.E4u... 80388fe: b0eb 988a 4a32 601b d5d2 532e 276d e666 ....2J.`...Sm'f. 803890e: 6d61 d41b a3e9 175c ff89 1e2c 60f9 ced8 am....\...,..`.. 803891e: a11c ede3 ce11 383b 7d9c 5d08 9504 423f ......;8.}.]..?B 803892e: eac2 c7fd ef77 6558 d0ea 641a f20b 976e ....w.Xe...d..n. 803893e: 82b4 4f3d 844e 9df5 462c b9a0 bce8 3d9d ..=ON...,F.....= 803894e: 027b 7c5e 59d2 44e7 959c ca8d e7d2 f9c0 {.^|.Y.D........ 803895e: c547 2918 906c 2001 6b93 e10b 496c 0b2b G..)l.. .k..lI+. 803896e: ca19 3665 1213 e62b af50 68e1 20a0 3cbe ..e6..+.P..h. .< 803897e: 49b3 2977 de63 78cd 7c1e e00f 1d52 0457 .Iw)c..x.|..R.W. 803898e: d4a4 cbd7 e640 9427 8432 e962 80b7 626f ....@.'.2.b...ob 803899e: 2714 e93b b3cc ba37 e7b3 1f70 9a42 b291 .';...7...p.B... 80389ae: 394f c09f 500d 53a5 9143 00bf ecd5 f179 O9...P.SC.....y. 80389be: 0e38 1026 0e31 9653 4585 de41 e1eb b91c 8.&.1.S..EA..... 80389ce: 761c 97d9 fd65 9f5a dee6 4a51 16b1 16c0 .v..e.Z...QJ.... 80389de: 9068 8993 c5e1 9d34 ba22 9d98 9565 25ae h.....4."...e..% 80389ee: 89f1 8da1 505c 9a6d 8760 7e54 a928 e4a3 ....\Pm.`.T~(... 80389fe: 3506 4853 a84b 057a 2e81 9ba4 b096 1a8d .5SHK.z......... 8038a0e: 2e02 b907 195a d545 57c8 206b a3c8 bb2b ....Z.E..Wk ..+. 8038a1e: db2a ab5d 5c81 065f bd72 8206 b92c 5ec5 *.]..\_.r...,..^ 8038a2e: 106e 1448 ae53 dc8c b6e9 dd0f 8373 b34a n.H.S.......s.J. 8038a3e: 56b4 4f8a 5a59 184d 59b0 53ca a32d b277 .V.OYZM..Y.S-.w. 8038a4e: f013 a705 52c2 0e03 e9d8 d1e2 1521 f8a9 .....R......!... 8038a5e: 2e9c 4fa4 ae2a 2847 5cc1 c054 5663 b339 ...O*.G(.\T.cV9. 8038a6e: 0ae5 30ca 0297 e150 dd36 0aa7 e969 0e4a ...0..P.6...i.J. 8038a7e: 9956 8775 aa91 7192 a329 050a 6aaa 0a21 V.u....q)....j!. 8038a8e: 2988 5fa1 4c55 acf4 48f3 5456 d266 e642 .)._UL...HVTf.B. 8038a9e: ec12 ee42 911a 4be0 c340 fbe8 d016 de30 ..B....K@.....0. 8038aae: fa18 5f5f 9c06 ecc3 b2d8 0312 1fa0 5b23 ..__..........#[ 8038abe: a74b 78dc a438 f264 9b0d e730 6b40 97e4 K..x8.d...0.@k.. 8038ace: 84d5 f2ff 3d03 2f9f 1a53 a680 7180 e4b5 .....=./S....q.. 8038ade: 9bd6 09f4 2e89 616c 73d9 dd29 4296 014a ......la.s)..BJ. 8038aee: b4b5 d6aa 6349 720a 4b31 919b 6433 845e ....Ic.r1K..3d^. 8038afe: ab25 1df9 d17c 715a 1ab0 91ae 7d0e 3152 %...|.Zq.....}R1 8038b0e: d519 3006 527d 2371 4335 cf63 562c 3408 ...0}Rq#5Cc.,V.4 8038b1e: 631a 2ed1 93b1 6674 6e3b ea2d 52ed 64d7 .c....tf;n-..R.d 8038b2e: 52a8 14de 0046 c530 9619 d258 f2b4 8bc5 .R..F.0...X..... 8038b3e: 351b 5623 526b c1df 6577 c06a 4714 40fb .5#VkR..wej..G.@ 8038b4e: 6ee0 e54d a29a 45a2 8e39 cef9 2791 a8c8 .nM....E9....'.. 8038b5e: 2caa e063 0b96 1309 75e4 44a5 b32f cb96 .,c......u.D/... 8038b6e: 12a8 bf66 bf42 ad59 094a 7860 34a8 46b3 ..f.B.Y.J.`x.4.F 8038b7e: 650f 0f39 87e1 f532 3ebf 2c88 0025 8648 .e9...2..>.,%.H. 8038b8e: e284 e682 5c20 9546 38b5 5036 dfcc d154 .... \F..86P..T. 8038b9e: 668c 2ea3 ca3f a9ef 126c 6882 b644 a001 .f..?...l..hD... 8038bae: a84a 3e72 f7cb 69cb 0636 d5af e069 9865 J.r>...i6...i.e. 8038bbe: 4022 ad89 3b25 6fff 0f47 678f 7271 7d33 "@..%;.oG..gqr3} 8038bce: 632e 7629 76ce 954a c89b 5c76 62a5 1b42 .c)v.vJ...v\.bB. 8038bde: 2a57 ba90 e72b 6cb8 298d e511 8305 f7a0 W*..+..l.)...... 8038bee: c4e2 4bb5 c835 2186 4261 9d20 fcdc f534 ...K5..!aB ...4. 8038bfe: 5ca5 044e 325a 2166 6f66 496a 1e30 c0bc .\N.Z2f!fojI0... 8038c0e: ac36 78b9 4fea 37f2 d035 9e70 f64a bb24 6..x.O.75.p.J.$. 8038c1e: 5aae 7e4f 68f3 1fc7 b651 ae22 289b 8ee5 .ZO~.h..Q."..(.. 8038c2e: 1cd2 7543 6de3 e720 55cd 3e15 fe1a d54e ..Cu.m ..U.>..N. 8038c3e: e250 7c04 92cf 1391 71c0 aae9 8981 0d41 P..|.....q....A. 8038c4e: 2c0f 7a6c 855d 344e 3395 3049 8b9f 121b .,lz].N4.3I0.... 8038c5e: c504 7004 9a6a 3a5a ce77 81d3 6981 3d4e ...pj.Z:w....iN= 8038c6e: 1f84 31b4 c5bf 2c89 5b9b a3d5 1d3a ca65 ...1...,.[..:.e. 8038c7e: 746c 322e 8928 1a11 5472 579b 6b69 3035 lt.2(...rT.Wik50 8038c8e: 8127 2929 62b7 bb64 7a4d b9af 48aa e9a5 '.)).bd.Mz...H.. 8038c9e: 69be bacc f7eb 634d be9a 7b22 39ad 20a6 .i....Mc.."{.9. 8038cae: 96d4 4cf4 7229 bb76 b186 0eb2 2f93 7b7f ...L)rv....../.{ 8038cbe: 41cb f6da 33c7 da98 8097 0dbb 6559 8dcb .A...3......Ye.. 8038cce: 0082 43bc eace 887b 0820 a978 ed8d 2174 ...C..{. .x...t! 8038cde: 6183 1d37 058e b104 c684 9ae5 2268 53ee .a7.........h".S 8038cee: a7f1 ec54 eeee 1391 12e4 dd5d e8fe 373e ..T.......]...>7 8038cfe: 8c7b e95c f7c9 0eef 1efa 1a27 d39b 0ffa {.\.......'..... 8038d0e: 88e2 7616 39f9 13a1 9ff8 d872 8cd1 b950 ...v.9....r...P. 8038d1e: f438 90f2 bf0a 3755 2073 fb9e 1840 7666 8.....U7s ..@.fv 8038d2e: 3a1e 4570 1187 4c6a 811c aca8 7770 2857 .:pE..jL....pwW( 8038d3e: c07c 17ed 43b6 fa37 2356 6a20 8975 e0f9 |....C7.V# ju... 8038d4e: cffa f379 e8a1 f2c3 e8f9 9746 8f9a 6e06 ..y.......F....n 8038d5e: e7cc 2944 395a 54f8 9d24 38c3 c62a ef9b ..D)Z9.T$..8*... 8038d6e: f3be 7843 70b5 c1fe c6fc 27a9 d7b5 43ba ..Cx.p.....'...C 8038d7e: 239d 480d 9b09 c5af 1170 2801 d84d e057 .#.H....p..(M.W. 8038d8e: 7b69 7a12 85c7 781d f1ac f62f 503f 0557 i{.z...x../.?PW. 8038d9e: 367a ee3b d84f e51b 45b3 514b dc6e a673 z6;.O....EKQn.s. 8038dae: 1486 d6c7 9df7 bbe9 570c 9797 a99f 4754 .........W....TG 8038dbe: 019b 308b 9532 a870 df59 a689 3282 6a5c ...02.p.Y....2\j 8038dce: 905c 1d96 ebea 68d2 200c 8fd2 c2e8 6eb4 \......h. .....n 8038dde: df43 54fb 6a80 329f a800 7f82 40a0 aa5e C..T.j.2.....@^. 8038dee: 12a6 8bf9 6e8a 0bca 5cd6 7ea8 9eab 2571 .....n...\.~..q% 8038dfe: 56fb 4d91 f2f8 88ae eddc db7b ee8f 3fef .V.M......{....? 8038e0e: 73ba b3db 64ff bc38 bdd1 b5d1 d955 df9f .s...d8.....U... 8038e1e: 77b9 a3ef a94f ebb8 d747 d411 a090 3c1f .w..O...G......< 8038e2e: 73ba 01e7 af4a 0b5d 2ec3 9780 1968 32b5 .s..J.].....h..2 8038e3e: e17d 4917 b578 dc14 ed25 4e78 46ee 9d57 }..Ix...%.xN.FW. 8038e4e: e6a4 077d 0397 b9b7 82f7 bd17 8f9f 05e7 ..}............. 8038e5e: 5331 05ef 5ba5 aef4 926c d7a0 1131 422a 1S...[..l...1.*B 8038e6e: 63a0 3fea ac45 9d64 b66a b8ae aa9c 2bd1 .c.?E.d.j......+ 8038e7e: 7b57 d122 8fb8 936e 3828 b0ba 389f a739 W{"...n.(8...89. 8038e8e: 891f 13a1 9ab7 c9cd 4709 5c91 4215 e784 .........G.\.B.. 8038e9e: c3f7 8e7d c00a fd65 3ee1 febb abbd a5f8 ..}...e..>...... 8038eae: fbfd b5de 52be 2894 559e e4a4 21f5 81ed .....R.(.U...!.. 8038ebe: 784f b893 ef95 bd93 f2ee 0025 5266 8a3e Ox........%.fR>. 8038ece: c1d5 e279 762e 4ea5 aafc 3827 8c52 7486 ..y..v.N..'8R..t 8038ede: 7bca 39fe 1b0d 4073 1b4b b211 3a78 369f .{.9..s@K...x:.6 8038eee: 0755 f3f2 9c7b 32c0 9ff5 15d7 d531 45c2 U...{..2....1..E 8038efe: 18be 8e64 fcff cd0d e891 d3c3 8a53 1c1f ..d.........S... 8038f0e: dc2c 9a82 6733 b9e2 2d80 807f 14d3 09ba ,...3g...-...... 8038f1e: 4a72 4c79 a03f 1497 3ab8 2594 f4b3 de10 rJyL?....:.%.... 8038f2e: 2973 74c6 5a4f 734d b374 170c f05b c32c s).tOZMst...[.,. 8038f3e: 08db 68fd 74ff b5e4 35fc 07ff b3a1 c21e ...h.t...5...... 8038f4e: 6d6f 9223 83fe 8fb0 331b 36fc 66c1 626d om#......3.6.fmb 8038f5e: bbba 03be 2ec0 a8dc 16e4 3036 8acb 1797 ..........60.... 8038f6e: a3b4 7d76 ba41 56dd 6077 d077 758c ba2c ..v}A..Vw`w..u,. 8038f7e: 3271 3723 9f23 25c7 a576 c59e cd7e bf61 q2#7#..%v...~.a. 8038f8e: 8ec8 0c5e 87d9 40cd 24b0 6870 4221 beef ..^....@.$ph!B.. 8038f9e: e608 6201 7990 1e0f d0e1 424f a131 2490 ...b.y....OB1..$ 8038fae: 60be c19d 0bef e5df 0108 0589 86d5 7e4e .`............N~ 8038fbe: 03dc 3fa2 0c10 b214 8b8a cf46 90e8 1cc2 ...?......F..... 8038fce: aac6 f36a 0d6c cfe1 425b cd73 cc83 3e20 ..j.l...[Bs... > 8038fde: 79ba 9745 31c2 f2a1 0c2d 95f2 d0fa 7ddf .yE..1..-......} 8038fee: 40ed 3417 4427 4843 c345 a5dd bb91 efeb .@.4'DCHE....... 8038ffe: 4ac1 b04a ba18 e4c8 020a bb06 dc30 196d .JJ.........0.m. 803900e: 1d14 0b34 c990 e709 3f0f 21c9 98e9 436e ..4......?.!..nC 803901e: 7c52 c472 142a 949c 69cd 8ba2 1166 712e R|r.*....i..f..q 803902e: e90d 251a 82ba f538 fed5 d040 b827 e813 ...%..8...@.'... 803903e: f962 564b d4df 8c93 3bd5 4a2f 9195 d9c2 b.KV.....;/J.... 803904e: 84cf 79b2 6370 428b bc4f c4dd 1d4a bbd6 ...ypc.BO...J... 803905e: 8b6e e149 8d4b 7599 5805 6652 16cd 2b4f n.I.K..u.XRf..O+ 803906e: 8512 4f1f 5756 83b9 4c0a 6f16 8cc2 1551 ...OVW...L.o..Q. 803907e: 0ce9 f55e 8e26 872e 73b4 a8d7 ae94 02da ..^.&....s...... 803908e: bdaf 2e47 686f 1457 6ad5 8b4c c5b4 b0eb ..G.ohW..jL..... 803909e: ce7d c7ad 5d0e 1834 66eb d1b5 3f68 6211 }....]4..f..h?.b 80390ae: 51d3 6234 1f1c d28b d8df 3536 3e93 5c99 .Q4b......65.>.\ 80390be: eff0 1f63 0527 4de6 42bf 821c e7ea 5814 ..c.'..M.B.....X 80390ce: 9fe4 ebad 3837 700e a0be a95b b3b3 6f12 ....78.p..[....o 80390de: 5d9b 8287 d79d e1df 244b f38c dca6 ead9 .]......K$...... 80390ee: 1f1e 5b07 f5de 56f7 6f57 bbbc 9345 6ef9 ...[...VWo..E..n 80390fe: bc44 4714 f3bc 6a06 8a28 d157 2514 f027 D..G...j(.W..%'. 803910e: 36dd 2c3c 8a42 e904 ca64 d46a b376 50cc .6<,B...d.j.v..P 803911e: 4c7d 6fb6 b750 c8d2 ee1e d5ad 4496 9245 }L.oP........DE. 803912e: 54b0 206f bc55 725b aba3 ae44 acec 1945 .To U.[r..D...E. 803913e: 4bc2 244e c9a8 4cd5 a671 6634 3404 1d2a .KN$...Lq.4f.4*. 803914e: 16b1 e6d8 2809 6850 5065 708e be3f b856 .....(PheP.p?.V. 803915e: 306c 1339 3873 4523 9ce1 b463 e71f 7c0f l09.s8#E..c....| 803916e: 72e4 f473 461a 62bd 6d21 fb75 4ad2 10ab .rs..F.b!mu..J.. 803917e: 00a6 a86a cf28 abc2 975d 0f7f 2927 c762 ..j.(...]...')b. 803918e: 1f9d 6dbe 994e 56d1 6c1e d354 ab37 3cb5 ...mN..V.lT.7..< 803919e: 4724 dc9f f335 52da 8700 3919 70c2 729d $G..5..R...9.p.r 80391ae: 2f71 a91c dec7 f3fe fb07 de9f e9b9 bfa9 q/.............. 80391be: c7c7 4e2f eafa 8777 3d65 a9d4 ea28 5255 ../N..w.e=..(.UR 80391ce: 61a9 0e11 94b4 2f26 490e 486e 0f30 58ef .a....&/.InH0..X 80391de: 6cac 0190 00dd b086 8824 5e93 11bd 78bd .l......$..^...x 80391ee: 44b3 2278 e416 d8ca 3550 fcbc 89e6 9b69 .Dx"....P5....i. 80391fe: c2f4 2c19 bf81 1260 1324 121b 269c eb01 ...,..`.$....&.. 803920e: 2e34 398c 1797 7cc2 b20f a7a4 9168 1acf 4..9...|....h... 803921e: 1a2c 1b46 33b4 5de6 13f9 2cd2 42cf c825 ,.F..3.]...,.B%. 803922e: 4517 12ec 372e 51a9 7569 93cd 670a 09ce .E...7.Qiu...g.. 803923e: 45f5 e526 0cc3 434f 9221 5089 7733 28d6 .E&...OC!..P3w.( 803924e: 7b33 4c83 f3e3 26ff 042b a6b8 9d46 509c 3{.L...&+...F..P 803925e: c5f6 4f0e b6bb 244a 1ffe 33ee 3bae 028c ...O..J$...3.;.. 803926e: 42ad 9051 2e54 674d 500c b468 4093 939e .BQ.T.Mg.Ph..@.. 803927e: 19bb 19ec ae70 8ea0 c21a 815c a016 4aa9 ....p.....\....J 803928e: 6d26 2f79 b340 68c6 d8fa 91c7 dac9 1e0c &my/@..h........ 803929e: e984 eadb 9c52 5d79 35b9 82aa 23f4 8aba ....R.y].5...#.. 80392ae: 7446 1adf 4291 bfcc f69c ebd5 876f bf6f Ft...B......o.o. 80392be: a5d3 d1ff 39e5 e33c ea32 e914 f707 6477 .....9<.2.....wd 80392ce: 0422 4e64 3b15 390e ccef dbf3 7236 4522 ".dN.;.9....6r"E 80392de: b942 1f19 ba3f 408b 6e3a 934d 13f2 5720 B...?..@:nM... W 80392ee: 3c76 fbb0 7896 8b3e f761 6a03 d32c 2360 v<...x>.a..j,.`# 80392fe: 852a 3642 5146 8b24 1504 3721 8fdb ea13 *.B6FQ$...!7.... 803930e: 164d a90e c730 467b e099 5884 b5c6 6eb1 M...0.{F...X...n 803931e: 1123 f6a4 14e2 4c4f 1c65 f7ae e49f 23eb #.....OLe......# 803932e: 1b4c 2219 2294 a7d8 10dc 92e8 4781 2e5f L..".".......G_. 803933e: 5c1f 0d50 d464 d79a e8e2 0844 92e8 6b0b .\P.d.....D....k 803934e: e4ea a108 0723 2945 edad 040d a44d 0afe ....#.E)....M... 803935e: a341 2dc8 4f99 b826 2df8 c626 6954 c08b A..-.O&..-&.Ti.. 803936e: 87dd 72fb 0907 52e5 9604 a1c2 ce86 1216 ...r...R........ 803937e: 4ba1 0514 1b12 0d61 2145 0217 6348 6777 .K....a.E!..Hcwg 803938e: 773c eead dac6 fa9f dac9 5dbb dbab d1ed .]....z..... 803941e: 0f41 e360 1ceb d260 25e2 fd20 006a 3e41 A.`...`..% .j.A> 803942e: 93a4 ca5d d818 8d63 1213 a086 545a 9ce2 ..]...c.....ZT.. 803943e: b294 4008 c61e 6d27 5951 dea4 950b dc13 ...@..'mQY...... 803944e: a493 e3e3 b895 362a f72f d7c1 4ca7 3687 ......*6/....L.6 803945e: b910 1a16 2c5f 4063 fafe 625b f406 0bae ...._,c@..[b.... 803946e: a108 8fa4 2dcb 456e 492e f98f daac b521 .....-nE.I....!. 803947e: 30d1 76c9 c8f7 8acc 9768 666f 21e9 3202 .0.v....h.of.!.2 803948e: e78f 8a33 8324 cbf1 aba4 7121 0792 c789 ..3.$.....!q.... 803949e: f0ef c8e5 ea34 290f 0adf 32b9 c539 3975 ....4..)...29.u9 80394ae: ffb8 ee98 3c71 2386 2e93 a09d 6602 0005 ....q<.#.....f.. 80394be: 10bd 1799 d838 0a94 22e2 e3a0 d547 6c33 ....8...."..G.3l 80394ce: 17d8 2a6d 18fa c044 e930 e8fb 329a a28b ..m*..D.0....2.. 80394de: 7d16 5252 89d8 30bb 733d 0a2d e7cf db10 .}RR...0=s-..... 80394ee: eaea 8a92 882a bab0 c36a 156a 38c3 33c1 ....*...j.j..8.3 80394fe: 2b4c a5fa 5287 8010 cbca cde6 f9f3 b8f8 L+...R.......... 803950e: aaaa 198c c49d 7f02 7994 ea0c edfc ebe6 .........y...... 803951e: 6e5d a6e2 31b8 7446 ee14 33b9 e4fc 05d3 ]n...1Ft...3.... 803952e: 3816 b5b2 c33e 81d1 8fcf dd1f d22b 7d0f .8..>.......+..} 803953e: 765c e1d1 a730 953f 6c55 bd8a 648f ffb5 \v..0.?.Ul...d.. 803954e: c738 7feb 664a 65a3 706a d609 e480 f923 8...Jf.ejp....#. 803955e: 9668 15a4 4df4 744f 074d ded3 3064 1a61 h....MOtM...d0a. 803956e: 4d2c 8cf6 c1f6 ed9b 7b66 4cfd 4e0a 254a ,M......f{.L.NJ% 803957e: b9c3 7f80 cd86 c0f9 9ee7 32c8 1e9e 053e ...........2..>. 803958e: d291 7578 33f5 1bcf 6062 3f9c 4228 4d46 ..xu.3..b`.?(BFM 803959e: 2c88 e430 4185 c32e 2678 7bd3 768c c16f .,0..A..x&.{.vo. 80395ae: 5692 7526 0e0e 0a7d f529 6914 2e69 fbda .V&u..}.)..ii... 80395be: cfd4 842d f374 3c16 d29f 03ba d35d 2923 ..-.t..<....].#) 80395ce: 1546 fb1e 5592 910f cbd6 a80f 3e20 b32a F....U...... >*. 80395de: bded ea03 1249 7a1f e760 41a6 7c78 4a61 ....I..z`..Ax|aJ 80395ee: 4e51 2529 6048 f277 7a71 8b78 a6d2 d444 QN)%H`w.qzx...D. 80395fe: 710a 301d 0100 66c2 ca06 624e 88ac e802 .q.0...f..Nb.... 803960e: e16f 4881 4e5e 56cc 5c8a 7e0a 5a0f ab07 o..H^N.V.\.~.Z.. 803961e: 07ab c2b8 4000 14f0 d204 392d 7419 4074 .....@....-9.tt@ 803962e: 07fa 6848 9ad9 9acc 92c6 93b0 417a d3b1 ..Hh........zA.. 803963e: 415b 4fff 0931 27a3 3663 e14f 3211 6530 [A.O1..'c6O..20e 803964e: 4af6 5550 c4b5 d196 aa35 1252 2c86 20bd .JPU....5.R..,. 803965e: 15cd 560d a65c 83b2 d7d9 08c0 3808 6f6d ...V\........8mo 803966e: 3845 18c5 c372 8622 27e5 5a50 83f6 82d4 E8..r."..'PZ.... 803967e: 4131 8db7 29ad 4b79 eb90 1564 4890 c0a2 1A...)yK..d..H.. 803968e: 838b 90d6 449c 841d 209b 1676 7b02 1b8c .....D... v..{.. 803969e: 5019 0b43 af38 4e11 e7b0 7088 b080 18cc .PC.8..N...p.... 80396ae: d2df 5541 0b0b 61cf 390a 250c 2247 4c79 ..AU...a.9.%G"yL 80396be: 4e8d 6a83 0151 0055 2989 a9d5 c954 3803 .N.jQ.U..)..T..8 80396ce: 7181 c278 5901 4112 0485 b0f8 854a 1bcb .qx..Y.A....J... 80396de: 0a4a e010 c90c 90be 638a f4f3 cd01 3810 J........c.....8 80396ee: 4d82 2126 dd0c deb1 1ad0 4841 a866 1fed .M&!......AHf... 80396fe: a87b 3b1a 440d 28d4 715e 4c4f 64e7 1f63 {..;.D.(^qOL.dc. 803970e: 258c 5058 af63 1614 5c84 a9c4 16ef 2ad8 .%XPc....\.....* 803971e: 630d 819c 8591 7d2b c263 c750 6762 fd31 .c....+}c.P.bg1. 803972e: 88b4 2d85 71b8 7025 fb4c 4fa5 72b3 1ef6 ...-.q%pL..O.r.. 803973e: 5e56 3213 eef4 be8d 309a 1da4 9b1b abc7 V^.2.....0...... 803974e: 06c6 dba5 4a06 8641 0a9c 6e1b d227 a137 .....JA....n'.7. 803975e: bbab ca06 fc2a 46b3 f645 2466 5049 00ee ....*..FE.f$IP.. 803976e: 517a 093c 244f 543c 0cf4 6488 c432 ea7b zQ<.O$VC 803978e: 95c2 3ec6 f211 21b1 0cc4 418a cab2 fee1 ...>...!...A.... 803979e: e80e d259 3c30 916f f427 1765 8517 40fa ..Y.0......... 803985e: e3c0 2406 121d ae3c 7b85 3f1f b216 6ae7 ...$..<..{.?...j 803986e: 2d3c bd26 27f5 fa39 bb30 51e0 7a02 42e6 <-&..'9.0..Q.z.B 803987e: 4576 1f6f 5f52 98fa 3aab ee31 92f2 7d58 vEo.R_...:1...X} 803988e: 4624 9e77 5acf 93f6 0127 9c3f 7f46 bb5d $Fw..Z..'.?.F.]. 803989e: 48f6 7a9f 2ecd e3a4 c492 a967 e883 a6f3 .H.z......g..... 80398ae: 9cea c879 4138 1be9 647b c426 8c2a 4518 ..y.8A..{d&.*..E 80398be: 32b8 b768 00e9 1e54 6606 46af 069f b838 .2h...T..f.F..8. 80398ce: 81b3 b321 06ff d006 4d69 970e 4067 3fd5 ..!.....iM..g@.? 80398de: 4afb 2778 c971 107d fe96 480d e58f f54d .Jx'q.}....H..M. 80398ee: 9ede 4f57 39a6 6e8c ef78 b6de 7e4b a08d ..WO.9.nx...K~.. 80398fe: 830c 1786 0e50 2d32 0e51 a80d a7d1 45ce ....P.2-Q......E 803990e: e809 4c12 1717 14e1 08d7 0a5c 13c4 f483 ...L......\..... 803991e: 255d 4011 8979 b33a 1439 2a39 8eaf 4623 ]%.@y.:.9.9*..#F 803992e: 32c1 ae55 0386 05e7 8ce6 1dbc 41e5 bad1 .2U..........A.. 803993e: 1320 0e2e 3a66 e951 b8a6 859f 9fd0 aff4 ...f:Q......... 803994e: 6592 2129 411b 179f 3174 0251 1129 81b3 .e)!.A..t1Q.)... 803995e: b100 23bc 6abe 2f48 c581 bb84 af62 a42f ...#.jH/....b./. 803996e: 8008 8706 0d2f 21e9 11c2 08e1 ef85 4b19 ..../..!.......K 803997e: 5dc2 8d3d fa71 c4ad 6d93 b2f3 e54a 58d5 .]=.q....m..J..X 803998e: 5c0b a658 a82f 12b6 9772 2e50 0c3c ba1c .\X./...r.P.<... 803999e: ae06 cb92 84ff f406 0d68 40e1 46cb 6744 ........h..@.FDg 80399ae: 2770 3343 c469 7da3 9388 d2eb 2103 a5e2 p'C3i..}.....!.. 80399be: 2f04 0433 06b0 8127 59fc 86e2 31bc c36e ./3...'..Y...1n. 80399ce: 31c0 d006 1682 a593 8c77 0636 6c57 2a6b .1......w.6.Wlk* 80399de: d8a2 e247 4727 6de4 7d6b 49eb a572 c577 ..G.'G.mk}.Ir.w. 80399ee: bfe6 dbd5 dcc1 eb67 93ca 1364 e0d9 1607 ......g...d..... 80399fe: 45de 1342 a1b2 b272 f0a1 1b0e 58bf 057c .EB...r......X|. 8039a0e: 9352 6a9c 0cd5 cd1e 8b11 352a 4356 e856 R..j......*5VCV. 8039a1e: 3409 dfc6 d2ba b7b3 65ec f2e3 5668 1695 .4.......e..hV.. 8039a2e: db8f b90c a57d 921d 46a0 9794 b2e6 28b5 ....}....F.....( 8039a3e: 7182 ea22 add1 0c80 f2f4 9e8b 2ed4 023f .q"...........?. 8039a4e: e1e9 5d2c 0801 0548 f283 ca36 9fa1 6425 ..,]..H...6...%d 8039a5e: 20e0 d182 25ab a3fc b50b 4f25 0107 572c . ...%....%O..,W 8039a6e: 2ddc 0861 ea7d 8a1f 20e0 d42e 829b 88db .-a.}.... ...... 8039a7e: b29d 8f1f 5e5f ef07 a092 a7e6 1bd8 4335 ...._^........5C 8039a8e: 96af e11e fbbd 7bce b6f4 bc0a 23ae 056f .......{.....#o. 8039a9e: 1fcf 92ac 82b6 70d6 e071 46f4 7982 0628 .......pq..F.y(. 8039aae: 1b2b ff14 298b 9781 657d f1f0 715b 056e +....)..}e..[qn. 8039abe: f482 b859 2220 5128 6f96 99e1 bc93 8b88 ..Y. "(Q.o...... 8039ace: 4e78 273a f9ae 192e 8ade 5950 00a4 e60e xN:'......PY.... 8039ade: d623 a0b7 c697 3d1f deb6 0141 879e 9286 #......=..A..... 8039aee: ab0b 7567 f615 58d2 2413 7970 e252 de92 ..gu...X.$pyR... 8039afe: 7fba 7351 9bde df6f fdf3 7928 dd78 4686 ..Qs..o...(yx..F 8039b0e: d107 887b 5323 6e05 7c29 59fc e37b d01d ..{.#S.n)|.Y{... 8039b1e: eea9 5aba e98f f6fd 9f5b 4479 e168 605a ...Z....[.yDh.Z` 8039b2e: 3c8c f6ac 3b63 fccb caa3 8183 da07 b827 .<..c;........'. 8039b3e: 08f0 c78b 77f3 4771 d780 b76d 3dd3 8244 .....wqG..m..=D. 8039b4e: 1376 5b55 000d 513a 2afb afdf 6ba0 bbde v.U[..:Q.*...k.. 8039b5e: 7b41 07b6 a679 b45e f070 7c75 5c2c 7d2c A{..y.^.p.u|,\,} 8039b6e: 7a20 4e07 7ccf a284 5a4e 887c 3d69 ea2b z.N.|..NZ|.i=+. 8039b7e: 9b87 25da 0fd7 b4a5 df42 a730 48f7 51c1 ...%....B.0..H.Q 8039b8e: 953f a23e 2d15 5c8e fbb2 9543 9734 f537 ?.>..-.\..C.4.7. 8039b9e: 8367 8256 f970 5aac 7604 4241 daef d8b7 g.V.p..Z.vAB.... 8039bae: 8c2f 5873 50fe 6904 d5ef 601b 42d5 7bca /.sX.P.i...`.B.{ 8039bbe: 4f1f a6e3 cbe4 37a0 81af e930 9657 c2f8 .O.....7..0.W... 8039bce: 300b 176e 7087 4bc4 7a8f a713 3c67 4470 .0n..p.K.z..g..W....N...... 8039c2e: da07 d2a9 bc3a cb9b 894a 46ee e15d 7065 ....:...J..F].ep 8039c3e: e64a f57d 893c 02e6 79f2 862a dd30 128b J.}.<....y*.0... 8039c4e: 2d99 e73a daa9 1d21 3a42 b1c3 d839 7a31 .-:...!.B:..9.1z 8039c5e: a4cd e824 7f1e bdd9 87a9 907d c434 9dcf ..$.......}.4... 8039c6e: 0de8 0544 c136 48ac 9120 c19e 8d7b 503d ..D.6..H ...{.=P 8039c7e: eac5 719a c16f 5342 652b 05e9 8b53 effe ...qo.BS+e..S... 8039c8e: c023 2452 9265 80b4 e0b8 15dc 6048 fdb5 #.R$e.......H`.. 8039c9e: 13d3 e53b 5267 591b 7abf b997 0f1f 8bec ..;.gR.Y.z...... 8039cae: e7bc a5d2 4655 a403 30d6 7178 f4a2 a707 ....UF...0xq.... 8039cbe: ffff 1200 611b 6ebc 0063 2f00 .....a.nc.. 08039cc9 : 8039cc9: 6c2f 676f 6e69 682e 6d74 006c 5448 5054 /login.html.HTTP 8039cd9: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 8039ce9: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 8039cf9: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 8039d09: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 8039d19: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 8039d29: 6e65 2d74 654c 676e 6874 203a 3835 0d37 ent-Length: 587. 8039d39: 430a 6e6f 656e 7463 6f69 3a6e 4320 6f6c .Connection: Clo 8039d49: 6573 0a0d 6f43 746e 6e65 2d74 7974 6570 se..Content-type 8039d59: 203a 6574 7478 682f 6d74 0d6c 430a 6e6f : text/html..Con 8039d69: 6574 746e 452d 636e 646f 6e69 3a67 6720 tent-Encoding: g 8039d79: 697a 0d70 0d0a 1f0a 088b 0000 0000 0400 zip............. 8039d89: 7d0a cd54 d46e 1030 157e 2463 754e 7bb7 .}T.n.0.~.c$Nu.{ 8039d99: a841 91c4 e950 1381 401c a382 cc93 5c6e A...P....@....n\ 8039da9: db1c 93d8 eeec e2ad 09c0 c409 2415 015e .............$^. 8039db9: 03d1 8845 433e 8df6 2718 6ddb a423 e21e ..E.>C...'.m#... 8039dc9: d8f5 e333 67ef d9b4 a7bd 4fcf be5e 7179 ..3..g.....O^.yq 8039dd9: 6aca 4c6c a59e 1995 9765 7392 408a 7955 .jlL....e..s.@Uy 8039de9: 00d6 562a 2ad6 4044 5bc9 885c 7447 9c37 ..*V.*D@.[\.Gt7. 8039df9: 88d6 c05e 56bb 9277 16bf 9eaf 1388 78d7 ..^..Vw........x 8039e09: ba85 c030 e959 822c 92a5 a767 aa12 5c25 ..0.Y.,...g...%\ 8039e19: 5917 80d5 9de4 9586 0177 e56f 74ad b585 .Y......w.o..t.. 8039e29: a0ac 25d3 2188 d038 a356 4656 52c4 9019 ...%.!8.V.VF.R.. 8039e39: 83f3 ad46 d375 fb36 8db8 8610 d140 f293 ..F.u.6.....@... 8039e49: 9e88 8d40 f206 5bfe d57f edff b72f fbef ..@....[..../... 8039e59: edab 7f79 fb49 6c8b de36 4665 b7db 0eac ..y.I..l6.eF.... 8039e69: 90b0 51bc 1eda 3196 1672 48c0 711e 2063 ...Q...1r..H.qc 8039e79: 00d6 9d48 1962 47b4 1b86 704f d611 3b38 ..H.b..G..Op..8; 8039e89: 9d53 4f1a 8b39 94a1 383c 8703 9167 6792 S..O9...<8..g..g 8039e99: 39e3 466d 0ad1 6d57 acf2 1dd2 8d2b 518a .9mF..Wm....+..Q 8039ea9: ab72 42ba 3605 88fe 160a 35aa 1d78 f42e r..B.6.....5x... 8039eb9: 2a1a ce81 a753 6aff ea44 6108 cabc b533 .*..S..jD..a..3. 8039ec9: 7e83 949f 5b1b b71b 0974 a282 aa8f eba7 .~...[..t....... 8039ed9: 76ad a0ab a7bc 4c46 9257 dcef baa1 9e7a .v....FLW.....z. 8039ee9: 9ff7 9ffb a97b f57e b63f 481f 4fba 65c4 ....{.~.?..H.O.e 8039ef9: c13e 95e3 c305 f586 c19a f014 9578 d3b8 >...........x... 8039f09: c2f9 8685 12a9 b3b5 1392 a4c6 52f4 4673 .............RsF 8039f19: 5393 423b 5de0 ee4c 39ef 2b68 0952 1a55 .S;B.]L..9h+R.U. 8039f29: d055 143b eaec de78 257f 2f3f 8f92 0fc7 U.;...x..%?/.... 8039f39: 116c e3fd 366c e524 b699 bdbe d26d 63be l...l6$.....m..c 8039f49: 25ea 4b12 8932 d093 e869 1406 ff23 96dd .%.K2...i...#... 8039f59: ca06 5d80 dcd2 f9f1 7243 0d35 1a40 408b ...]....Cr5.@..@ 8039f69: 4570 cbd0 8f1a fcd9 afc8 a8a7 593c a04a pE..........hB...S. 8039fa9: 2a25 17fd f802 cc9b 24bd b30a ca24 3e74 %*.......$..$.t> 8039fb9: 1376 ce33 6ceb 17f8 07f8 a233 8ac5 0415 v.3..l....3..... 8039fc9: 0000 .. 08039fcb : 8039fcb: 6f43 746e 6e65 2d74 654c 676e 6874 203a Content-Length: 8039fdb: 1800 . 08039fdc : 8039fdc: a018 0803 5fa0 0803 5fac 0803 1802 0000 ....._..._...... 8039fec: 0001 0000 .... 08039ff0 : 8039ff0: c2d0 0803 a3c7 0803 a3d3 0803 04d0 0000 ................ 803a000: 0001 0000 .... 0803a004 : 803a004: 9ff0 0803 f5e3 0803 f5ef 0803 04f5 0000 ................ 803a014: 0001 0000 .... 0803a018 : 803a018: cd3c 0803 b9a5 0803 b9b1 0803 091f 0000 <............... 803a028: 0001 0000 5825 4c00 676f 756f 5474 726d ....%X.LogoutTmr 803a038: 2600 6c00 676f 6e69 003d 6170 7373 6f77 .&.login=.passwo 803a048: 6472 003d 5448 5054 312f 302e 3220 3030 rd=.HTTP/1.0 200 803a058: 4f20 0d4b 430a 6e6f 6574 746e 542d 7079 OK..Content-Typ 803a068: 3a65 6574 7478 682f 6d74 0d6c 530a 7465 e:text/html..Set 803a078: 432d 6f6f 696b 3a65 7520 616e 656d 003d -Cookie: uname=. 803a088: 0a0d 6553 2d74 6f43 6b6f 6569 203a 6469 ..Set-Cookie: id 803a098: 003d 0a0d 6553 2d74 6f43 6b6f 6569 203a =...Set-Cookie: 803a0a8: 6f72 656c 003d 213c 4f44 5443 5059 2045 role=.< 803a108: 682f 6165 3e64 2f3c 7468 6c6d 0d3e 0d0a /head>... 803a118: 000a 90d0 b4d0 bcd0 b8d0 bdd0 b8d0 81d1 ................ 803a128: 82d1 80d1 b0d0 82d1 bed0 80d1 d000 d09f ................ 803a138: d0be d1bb d08c d0b7 d0be d0b2 d1b0 d082 ................ 803a148: d0b5 d1bb 008c 6f72 6574 756b 7370 3b00 ......rotekups.; 803a158: 4800 5454 0050 6572 6461 635f 6d6f 756d .HTTP.read_commu 803a168: 696e 7974 003d 7277 7469 5f65 6f63 6d6d nity=.write_comm 803a178: 6e75 7469 3d79 6d00 6e61 6761 7265 5049 unity=.managerIP 803a188: 003d 616d 616e 6567 4972 3250 003d 616d =.managerIP2=.ma 803a198: 616e 6567 4972 3350 003d 616d 616e 6567 nagerIP3=.manage 803a1a8: 4972 3450 003d 616d 616e 6567 4972 3550 rIP4=.managerIP5 803a1b8: 003d 6864 7063 003d 7069 6461 7264 003d =.dhcp=.ipaddr=. 803a1c8: 7767 003d 616d 6b73 003d 7372 655f 616e gw=.mask=.rs_ena 803a1d8: 6c62 6465 003d 7372 735f 7265 6576 3d72 bled=.rs_server= 803a1e8: 7200 5f73 6f70 7472 003d 7372 705f 6477 .rs_port=.rs_pwd 803a1f8: 003d 7372 6b5f 7965 003d 6964 3d31 7200 =.rs_key=.di1=.r 803a208: 316f 003d 6f72 3d32 6e00 7074 003d 746e o1=.ro2=.ntp=.nt 803a218: 7370 7265 6976 3d70 7400 6d69 3d65 7500 pservip=.time=.u 803a228: 6374 003d 003f 7270 646f 7461 3d65 4800 tc=.?.prodate=.H 803a238: 5454 2f50 2e31 2030 3032 2030 4b4f 0a0d TTP/1.0 200 OK.. 803a248: 6f43 746e 6e65 2d74 7954 6570 743a 7865 Content-Type:tex 803a258: 2f74 7468 6c6d 0a0d 0a0d 7254 6575 6f00 t/html....True.o 803a268: 6e77 7265 003d 7973 4c73 636f 7461 6f69 wner=.sysLocatio 803a278: 3d6e 6300 6d6f 656d 746e 003d 4547 2054 n=.comment=.GET 803a288: 6d2f 6961 2e6e 7363 0073 4547 2054 722f /main.css.GET /r 803a298: 746f 6b65 702e 676e 4700 5445 2f20 6166 otek.png.GET /fa 803a2a8: 6976 6f63 2e6e 6369 006f 4547 2054 722f vicon.ico.GET /r 803a2b8: 6c6f 2e65 736a 5000 534f 2054 6c2f 676f ole.js.POST /log 803a2c8: 6e69 632e 6967 2f00 6f6c 6967 2e6e 7468 in.cgi./login.ht 803a2d8: 6c6d 5400 6f6f 6c20 6e6f 2067 4f50 5453 ml.Too long POST 803a2e8: 7220 7165 6575 7473 0d21 000a 4547 2054 request!...GET 803a2f8: 6d2f 6961 2e6e 736a 4700 5445 2f20 6573 /main.js.GET /se 803a308: 7474 6e69 7367 682e 6d74 006c 4547 2054 ttings.html.GET 803a318: 692f 666e 2e6f 7468 6c6d 4700 5445 2f20 /info.html.GET / 803a328: 6567 4a74 6f73 2e6e 6763 0069 4547 2054 getJson.cgi.GET 803a338: 732f 7465 6974 676e 2e73 6763 0069 4547 /settings.cgi.GE 803a348: 2054 692f 666e 2e6f 6763 0069 4547 2054 T /info.cgi.GET 803a358: 722f 7365 7465 632e 6967 4700 5445 2f20 /reset.cgi.GET / 803a368: 6572 6f62 746f 632e 6967 4700 5445 2f20 reboot.cgi.GET / 803a378: 6f63 666e 7269 2e6d 6763 0069 692f 646e confirm.cgi./ind 803a388: 7865 682e 6d74 006c 4f50 5453 2f20 6863 ex.html.POST /ch 803a398: 6365 706b 6477 632e 6967 4700 5445 2f20 eckpwd.cgi.GET / 803a3a8: 6573 5074 6f72 6164 6574 632e 6967 4700 setProdate.cgi.G 803a3b8: 5445 2f20 7270 676f 6e6f 632e 6967 2f00 ET /progon.cgi. 0803a3c7 : 803a3c7: 692f 646e 7865 682e 6d74 006c 5448 5054 /index.html.HTTP 803a3d7: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 803a3e7: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 803a3f7: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 803a407: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 803a417: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 803a427: 6e65 2d74 654c 676e 6874 203a 3031 3036 ent-Length: 1060 803a437: 0a0d 6f43 6e6e 6365 6974 6e6f 203a 6c43 ..Connection: Cl 803a447: 736f 0d65 430a 6e6f 6574 746e 742d 7079 ose..Content-typ 803a457: 3a65 7420 7865 2f74 7468 6c6d 0a0d 6f43 e: text/html..Co 803a467: 746e 6e65 2d74 6e45 6f63 6964 676e 203a ntent-Encoding: 803a477: 7a67 7069 0a0d 0a0d 8b1f 0008 0000 0000 gzip............ 803a487: 0a04 56ad 6f5b 351c fe14 662b 92fa 9948 ...V[o.5..+f..H. 803a497: aa6c 12aa 9d82 4291 a45a 513e 8a21 29e0 l......BZ.>Q!..) 803a4a7: cef2 3378 3c4e da97 ddde 5bec 409a 0a0b ..x3N<.....[.@.. 803a4b7: 1162 a812 802f 2fc4 8148 5c85 e936 f05f b.../../H..\6._. 803a4c7: 23fc db3e 6499 1ddb 8b42 9878 19cb dcfb .#>..d..B.x..... 803a4d7: f3be 339d beee ef73 8da3 3e4f 787f 649f ...3..s...O>.x.d 803a4e7: 173a d771 89de c5a0 1456 9004 4d18 6ee3 :.q.....V....M.n 803a4f7: 34ce 4925 a546 3a62 060a 1fba 8bbe f735 .4%IF.b:......5. 803a507: d335 0aba e3d9 1f01 c146 e167 f5a3 a370 5.......F.g...p. 803a517: 2bcc 79aa b04f 2480 a165 0159 0795 23f7 .+.yO..$e.Y....# 803a527: 6e96 46b1 a0a9 8b39 2182 a367 94aa 6e7a .n.F..9..!g...zn 803a537: 88df 3aa7 528b e436 0b09 b09d 0bc2 39ae ...:.R6........9 803a547: a115 a84a d160 95ed ee9c 7cf2 5f90 03c9 ..J.`......|._.. 803a557: a4c5 2813 465c 706b b9a1 2c16 bf36 a398 ...(\Fkp...,6... 803a567: cf7a 991c 9999 fbd6 5ef5 d87d f8ed ae95 z........^}..... 803a577: c5e0 c90e eb24 4147 794e 9ab1 1528 c910 ....$.GANy..(... 803a587: 1444 3d28 4c16 8c65 d869 8951 95e4 7a26 D.(=.Le.i.Q...&z 803a597: 215c cd58 7576 9b67 a90e 1aff 2510 2893 \!X.vug......%.( 803a5a7: a590 ab60 0adb 3b9b 3bfe 3c5e bd64 1d32 ..`....;.;^o.<... 803a627: 3e52 d8fc 84fc 3d5a 55b1 1732 c4e6 9a9c R>....Z=.U2..... 803a637: 9f63 ebc3 bc6a 97e8 ca8d 7373 7f5e 2e61 c...j.....ss^.a. 803a647: 32a0 f283 7353 4f5c 95da ae32 2974 8dc7 .2..Ss\O..2.t).. 803a657: 8fde 01f5 ce74 8c41 ebb3 9dfd 9801 21ef ....t.A........! 803a667: 839b 247f 5569 7801 da87 9725 4581 bb76 ...$iU.x..%..Ev. 803a677: 4f35 9e7c 5daf 0b45 8826 37bb 86d5 9cee 5O|..]E.&..7.... 803a687: bf75 6b64 240b 0fbc b0f5 591c 8e7f 5186 u.dk.$.....Y...Q 803a697: 9490 94a2 91ef fd5b ddfe bbb5 d996 3a0a ......[........: 803a6a7: ad4d 2a72 4277 722a 8dba 8e85 895d 7989 M.r*wB*r....]..y 803a6b7: 516e 2804 90cf b1e0 2539 25e6 d970 ae47 nQ.(....9%.%p.G. 803a6c7: eb10 5909 df32 87d7 f780 feac 5b16 6ea6 ...Y2........[.n 803a6d7: 74d3 3179 1f71 a59a 6c30 db6b 8d58 2f57 .ty1q...0lk.X.W/ 803a6e7: 5ee8 34a8 3db5 25a2 34ae dd86 512f 3fba .^.4.=.%.4../Q.? 803a6f7: f160 4cc2 1e09 e647 7a25 626e 6cfe 90dc `..L..G.%znb.l.. 803a707: 4fa5 37d7 0be0 adbb cf86 d2c5 7d71 2ae3 .O.7........q}.* 803a717: bf01 71da af46 1f0c 77fe f7d3 c5fe 1374 ...qF....w....t. 803a727: 11f3 01b0 8e20 4083 800f c4b5 8bc9 becd .... ..@........ 803a737: 8f64 83db f06d 78c9 329a 58db 941e d8eb d...m..x.2.X.... 803a747: c8df 3945 37d0 f0f8 d146 e62a 4077 607b ..E9.7..F.*.w@{` 803a757: 42fe db25 ad02 7646 7856 b44a fa20 2a2b .B%...FvVxJ. .+* 803a767: 8a72 f826 0c1a 2139 85e8 8a29 6c74 2d66 r.&...9!..).tlf- 803a777: 5729 9979 a1da 62dd 35ab 6be1 53d3 a0b0 )Wy....b.5.k.S.. 803a787: 027e 3d2c 271f 6a9e 2e6d 912c c6de fa07 ~.,=.'.jm.,..... 803a797: 3c1e b903 ae9b 0027 37e4 7b08 1f36 050c .<....'..7.{6... 803a7a7: 6e60 835d c0f7 4dc8 7306 e2d2 0a98 f32a `n]....M.s....*. 803a7b7: dcb6 8e3a 2de3 a0e3 61ad a03f 335a 5e39 ..:..-...a?.Z39^ 803a7c7: d968 773b 6492 b5ad cb65 2b9d c4a7 877c h.;w.d..e..+..|. 803a7d7: 5034 330b 75c3 4f56 ef5c 3862 49a1 44d1 4P.3.uVO\.b8.I.D 803a7e7: 102f a83d 2ae8 8184 06e8 c2fa 78fc 269b /.=..*.......x.& 803a7f7: 01fd f2a3 d7d4 fea4 c166 42fe f663 dea8 ........f..Bc... 803a807: a84c 25fd d4b5 92ff 88e1 c0f5 6dcd 4c3b L..%.........m;L 803a817: 91ce 1a01 1f69 9a8c f261 114c 3239 f370 ....i...a.L.92p. 803a827: 8db6 bca7 9828 d4dc ff2c 1707 17ff 7ac5 ....(...,......z 803a837: 5037 a7cc b3f1 29a3 5468 857f a7d8 2690 7P.....)hT.....& 803a847: 8204 8d6d cd99 1ec8 5e23 c1d8 0ee0 af11 ..m.....#^...... 803a857: 300f 938b 39e6 14db 6fac e267 5a02 32af .0...9...og..Z.2 803a867: fe6a dccf c7f1 3784 6938 83b8 abca 8d27 j......78i....'. 803a877: b51b 94e2 fa6a ce21 0f0d a58a 95e5 4a8a ....j.!........J 803a887: ab9a 198f 9806 96ca df96 8c47 70ee 6083 ..........G..p.` 803a897: a9dd 6fef d09c 6b2e 0a05 0000 ...o...k.... 0803a8a3 : 803a8a3: 732f 7465 6974 676e 2e73 7468 6c6d 0000 /settings.html.. 803a8b3: 5448 5054 312f 312e 3220 3030 4f20 0d4b HTTP/1.1 200 OK. 803a8c3: 530a 7265 6576 3a72 6c20 4977 2f50 2e31 .Server: lwIP/1. 803a8d3: 2e33 2031 6828 7474 3a70 2f2f 6173 6176 3.1 (http://sava 803a8e3: 6e6e 6861 6e2e 6e6f 6e67 2e75 726f 2f67 nnah.nongnu.org/ 803a8f3: 7270 6a6f 6365 7374 6c2f 6977 2970 0a0d projects/lwip).. 803a903: 6f43 746e 6e65 2d74 654c 676e 6874 203a Content-Length: 803a913: 3134 3636 0a0d 6f43 6e6e 6365 6974 6e6f 4166..Connection 803a923: 203a 6c43 736f 0d65 430a 6e6f 6574 746e : Close..Content 803a933: 742d 7079 3a65 7420 7865 2f74 7468 6c6d -type: text/html 803a943: 0a0d 6f43 746e 6e65 2d74 6e45 6f63 6964 ..Content-Encodi 803a953: 676e 203a 7a67 7069 0a0d 0a0d 8b1f 0008 ng: gzip........ 803a963: 0000 0000 0a04 5bdd 73eb d713 ff15 1657 .......[.s....W. 803a973: 66d1 31ec 2d92 783f 5245 0527 e19a 1243 .f.1.-?xER'...C. 803a983: 3826 f34d 5989 6b4b 836b abb4 56ae 6e36 &8M..YKkk....V6n 803a993: 1986 490c 199b 6268 6908 9432 a010 2fcf ...I..hb.i2..../ 803a9a3: 0d69 61e6 e36c 0bfc ffab bfa8 b9df 5f77 i..al.........w_ 803a9b3: 5696 6016 e97f d907 b8fb 9cf7 cf73 9cfb .V.`........s... 803a9c3: b77b e874 07f4 66a7 393f c677 fba8 46cd {.t....f?9w....F 803a9d3: c4a5 46bf 74c3 ca16 1cb9 2cee 56b3 3529 ...F.t.....,.V)5 803a9e3: df2d aa34 d375 5b6b 397e f1d7 f3e7 f1c7 -.4.u.k[~9...... 803a9f3: 9e4e 7dd6 95bf 7eb7 b1df cb17 dfb9 3fe5 N..}...~.......? 803aa03: 277a ca7f b66d df4c 6b9e 3958 eaa3 be3a z'..m.L..kX9..:. 803aa13: 60e5 d9ca 6533 b6ab 8560 1c93 69b3 7395 .`..3e..`....i.s 803aa23: b68b d4b5 3d72 313f c96e f9ae 72f5 5acd ....r=?1n....r.Z 803aa33: abb4 5e56 8e6e 8ed8 dbed 2366 aedf 0d9a ..V^n.....f#.... 803aa43: 5cab d23c 2f34 cdd9 334e efba 2db4 6e4f .\<.4/..N3...-On 803aa53: a04c 4f2c 8500 fb6f ab0d fc12 ac10 5775 L.,O..o.......uW 803aa63: 57ba 57bb 9d82 45e0 19b0 946c d5c6 529b .W.W...E..l....R 803aa73: 76c3 1a2e cf75 2f9a 9ae7 eda6 aa14 76ed .v..u../.......v 803aa83: f0ce 46ac d739 97f6 561b 6ebb 3e59 b4e0 ...F9....V.nY>.. 803aa93: 9eab f2dd 7f0d 05b9 7d62 92eb fe3f b9a9 ........b}..?... 803aaa3: aa68 39a7 eda3 cb55 cf39 586d 4f85 18db h..9..U.9.mX.O.. 803aab3: ae3c e39e b142 ce6c 2dad 4a57 7b35 b0d1 <...B.l..-WJ5{.. 803aac3: e56b d55c 38ed 7e7e 33c9 185b 7a9a 7358 k.\..8~~.3[..zXs 803aad3: 1c97 6b3c 8255 a03b a5f3 77a6 d82b 9e0a ..... 803ada3: 418c 8f8e c3a5 8aa3 dc8b 6a4e 2ec9 53a9 .A........Nj...S 803adb3: 6934 8146 70cb 96f0 6a48 be11 61db a5ac 4iF..p..Hj...a.. 803adc3: 3448 f9b7 21b2 09e6 0edd 1999 feb9 20d4 H4...!......... 803add3: 2e46 6da3 cb89 1637 b73c cbb3 abd4 c36e F..m..7.<.....n. 803ade3: 3460 50b9 e0bc 5fce a498 cd00 ab39 4061 `4.P..._....9.a@ 803adf3: 1857 1d4f 2e13 ecef 48b9 3dfe 85c3 e4dd W.O......H.=.... 803ae03: 0316 115c c3a6 29d9 7b62 a4a6 241c 7123 ..\....)b{...$#q 803ae13: 9d04 1a0a 7f7b 25f2 8141 e572 83f1 70d0 ....{..%A.r....p 803ae23: d1fa 193b ec81 9ec1 7822 e0f2 0608 bb09 ..;....."x...... 803ae33: 2628 9573 f7ad 7923 486a a792 8e0e 9064 (&s...#yjH....d. 803ae43: 8bb0 a9e4 2481 0f4f f249 c1f4 0c91 7612 .....$O.I......v 803ae53: 3c91 903d 99e4 4921 8e46 5075 0c9a 7612 .<=...!IF.uP...v 803ae63: 3c91 9113 13dc 7a0a 37d4 9e69 e21e 85f3 .<.....z.7i..... 803ae73: dbaa 766c 5590 672f ecaf 8c43 9033 abc9 ..lv.U/g..C.3... 803ae83: fb71 b2be 64dd d5a8 7eed 4c9a e2cc 2705 q....d...~.L...' 803ae93: 612c b3c9 6b7d e598 cc7c 0781 9eb8 421e ,a..}k..|......B 803aea3: 82d4 1e7a 5ff7 1291 f261 186f 554b 0b60 ..z.._..a.o.KU`. 803aeb3: b87d f1f6 7d10 63b6 181f f703 dfcb a7d7 }....}.c........ 803aec3: 9243 6522 d49b 20b1 8db8 66f4 4105 9517 C."e... ...f.A.. 803aed3: 620a 4bea 5115 0175 38c0 9f5c 8146 52c6 .b.K.Qu..8\.F..R 803aee3: 042d 3721 9358 eaaf 1f26 b6d9 8f5f 21aa -.!7X...&..._..! 803aef3: c015 b951 d5d5 dbe3 d308 582f 31d6 06da ..Q......./X.1.. 803af03: d54f 718b c24e a910 7d55 7955 9c09 055a O..qN...U}Uy..Z. 803af13: c5f1 0147 5fcb 6adb a820 4b69 d9aa 50c8 ..G.._.j .iK...P 803af23: 2e18 42e4 bfc7 3054 94a9 16dc a2f3 6730 ...B..T0......0g 803af33: 322f 2332 d8af 9032 ddd0 7e0c 8d2c f7ab /22#..2....~,... 803af43: c7bb 67c1 5533 6631 9291 63c5 15c6 9276 ...g3U1f...c..v. 803af53: 5209 c134 d28a e171 e840 13e8 8da2 1b98 .R4...q.@....... 803af63: da05 8c41 0fbf b0ce 7a8a 3311 bafd bbaa ..A......z.3.... 803af73: 81f6 dfed cb0b 5077 a26a 0b48 c936 68ec ......wPj.H.6..h 803af83: af15 76c2 d5cf 976c 618b 7ed9 da07 f2c4 ...v..l..a.~.... 803af93: 4372 5d4a 1768 68d2 8a14 68ac df58 3e49 rCJ]h..h...hX.I> 803afa3: 299d 640c 2cec 5f79 0217 99e2 f388 99fc .).d.,y_........ 803afb3: 81d9 d4d2 86fa a0f4 beaf 2e79 3ba2 4df5 ..........y..;.M 803afc3: fe2e 169f ae3e 2e0d c6ad bcfd 6499 09db ....>........d.. 803afd3: 67b3 ba4e 3387 33db df31 972f 3496 d63b .gN..3.31./..4;. 803afe3: 28d1 d086 d2bd 6e89 dce8 2454 a4ad 51b2 .(.....n..T$...Q 803aff3: baa9 3a59 8e85 5ea5 696d 22cf a857 ebd2 ..Y:...^mi."W... 803b003: 02ec d3c0 fee0 8fbc cace 28c8 7e6a a394 ...........(j~.. 803b013: e83b 5c8e 4a83 554b 9c6e 973d 4687 113f ;..\.JKUn.=..F?. 803b023: b9c7 ca22 8d0d 91df 3192 f9a9 62e8 34e9 .."......1...b.4 803b033: b143 1138 ed0e 5996 a1ab d406 15da 1f91 C.8....Y........ 803b043: 8fba 0634 8ea0 63ba a1da 45ae 93b0 08ec ..4....c...E.... 803b053: 10b9 4982 7f2d 648f 243c c549 7d43 ba17 ...I-..d<$I.C}.. 803b063: 04ba 0be9 434b fd93 b825 15f6 609b 4efb ....KC..%....`.N 803b073: 892c 8450 aae2 910f b34d 317d cc9b 2ee0 ,.P.....M.}1.... 803b083: 919c 26f8 c136 eed0 0dc2 6043 b02c 62fd ...&6.....C`,..b 803b093: a2aa 5143 d72a ad21 a349 d753 2944 a2c5 ..CQ*.!.I.S.D).. 803b0a3: 552e dd43 2e18 6095 1685 b556 d480 ef27 .UC....`..V...'. 803b0b3: b578 915a c1b5 10a0 0ab6 cecf e4e6 7e36 x.Z...........6~ 803b0c3: 1c68 ff52 8041 21ce 811e 57bd dfc5 253f h.R.A..!...W..?% 803b0d3: 994f a847 9c2e 0c6e 2d86 ad39 61fd 4cdf O.G...n..-9..a.L 803b0e3: afb7 4994 8422 13df 5f5d 6dd3 4447 0312 ...I"...]_.mGD.. 803b0f3: 9f50 87aa 71a5 0405 b91d 01d7 1dfd f7ec P....q.......... 803b103: 9a67 b055 0099 2eca 0ee8 9ebb c16b 7473 g.U.........k.st 803b113: be9d 1f66 40f4 4510 9340 ff09 7d00 da8d ..f..@.E@....}.. 803b123: 490c 4762 b5a8 e6c1 7ee8 571a 3d5a ad33 .IbG.....~.WZ=3. 803b133: 2f60 d0ed d759 0beb 6a3e a2b9 8d0d 14bc `/..Y...>j...... 803b143: 5ca9 2bf7 1466 f1aa b11c f5ef 7f84 012b .\.+f.........+. 803b153: 1c51 047a 686f c471 a924 c088 9fd6 9071 Q.z.ohq.$.....q. 803b163: 4902 e038 7a41 7112 914a 4925 6c98 1c44 .I8.Az.qJ.%I.lD. 803b173: 7128 03b1 1beb f6cf 96d2 bb3e af29 34ef (q........>.)..4 803b183: 841e facd fee4 9a06 afb8 2eef c5b0 f795 ................ 803b193: 39ac 65d7 efc3 7147 c9b4 9d9d cce7 df71 .9.e..Gq......q. 803b1a3: 7e14 f647 e871 76f3 b36f cbb0 6d89 0896 .~G.q..vo....m.. 803b1b3: b241 0ca0 9a13 4bd7 427f 6b3f 5aa8 0c49 A......K.B?k.ZI. 803b1c3: 6b4c d233 ed75 37d1 be18 11a5 55fe 67e4 Lk3.u..7.....U.g 803b1d3: 637a ac57 9200 ab37 ea06 04ab d530 8d6b zcW...7.....0.k. 803b1e3: 2952 e0b8 3118 b784 111f 0d8d a4ba 7b43 R)...1........C{ 803b1f3: d4a3 6bd1 b05f 961c d8c6 9228 2725 e3ee ...k_.....(.%'.. 803b203: 1234 649d d3bb 244e 5292 c694 de8c d1c5 4..d..N$.R...... 803b213: 8d84 3e03 d65b 26dc 6be8 5852 c04c b856 ...>[..&.kRXL.V. 803b223: cdee 8046 0b92 937c 3064 5f81 2f25 83f1 ..F...|.d0._%/.. 803b233: 4430 a9a4 9bd5 6ac3 ac23 9d27 0665 808d 0D.....j#.'.e... 803b243: f57a e820 9854 2a23 6dd5 7ba2 b7d3 851d z. .T.#*.m.{.... 803b253: c8e5 6546 7326 db13 af91 744e 23b4 0a19 ..Fe&s....Nt.#.. 803b263: d52f 08ad 4615 8808 c6e9 69be d67f b45e /....F.....i..^. 803b273: 7406 64ff fa2b f609 b812 78e3 9450 050a .t.d+......xP... 803b283: a511 0bbc ed29 0575 40d4 845a 906c eb84 ....).u..@Z.l... 803b293: 2a1f fd87 4f5b c7ba 8bfc 425b b046 3cc1 .*..[O....[BF..< 803b2a3: 8180 ed4c 22c4 dca9 972f 5090 8ee3 1d5f ..L.."../..P.._. 803b2b3: 6e60 02ff 2b2d 1628 e31e 42f7 06ea bda4 `n..-+(....B.... 803b2c3: 43d8 0012 d769 63d2 ba79 a59f 2db5 0dad .C..i..cy....-.. 803b2d3: af8a 9b82 e37c eec5 553e 38be 9859 55c8 ....|...>U.8Y..U 803b2e3: de46 6f7d c0d6 c9f5 8989 2351 49f8 3bfa F.}o......Q#.I.; 803b2f3: 9adc ed61 79b9 80c4 a02a 02c9 3d9e 5fc3 ..a..y..*....=._ 803b303: 5edd fb8a e920 590e 58be 404c 2a2c 9288 .^.. ..Y.XL@,*.. 803b313: 836f 58cb 81a3 6912 7503 b5d1 9fee 1783 o..X...i.u...... 803b323: fd00 2000 f1b7 8102 7fae 26f7 9c5f 0048 ... .......&_.H. 803b333: 509c bf00 2cc1 f492 5582 c640 13bc b4f1 .P...,...U@..... 803b343: 6a13 aad6 1414 9e52 ce65 1e3a 3acf 66ae .j....R.e.:..:.f 803b353: 443d ce6d 0ba3 0560 04d4 0345 c584 459d =Dm...`...E....E 803b363: 4f84 39ad 43e8 608d ff21 560e 9f45 70ee .O.9.C.`!..VE..p 803b373: 7e10 31d0 d0a4 d419 8b1d 1cf1 d70b 8524 .~.1..........$. 803b383: 1bce 3e43 431a aa3e ff20 e993 b72d 41bb ..C>.C>. ...-..A 803b393: 8e14 8064 21b8 87a9 ee7c 0d42 9db8 158a ..d..!..|.B..... 803b3a3: ae67 2665 38c6 30a3 82de 6657 567f 0b35 g.e&.8.0..Wf.V5. 803b3b3: c787 1376 ad94 1663 3c6a fee0 f02b b762 ..v...c.j<..+.b. 803b3c3: 133c 74ef 778c e15a c55d 2dcc 5191 5db2 <..t.wZ.]..-.Q.] 803b3d3: 83d2 293f 5121 766f b110 4c4b 1443 6bbc ..?)!Qov..KLC..k 803b3e3: 0479 dc16 a264 2a9e fbc0 b32b 3a99 4539 y...d..*..+..:9E 803b3f3: f9ab 7ba1 f103 73f7 92cc 3583 30fa 93cb ...{...s...5.0.. 803b403: 1001 c322 529b dfc4 2214 639e 5bd1 676c .."..R...".c.[lg 803b413: 9082 629b 1026 7757 1f25 a2ac cde7 3a86 ...b&.Ww%......: 803b423: bc29 530d b6a4 24c0 2bc9 cca2 9444 70b0 )..S...$.+..D..p 803b433: e06d 080f 7307 a037 0009 d00e 6c19 2883 m....s7......l.( 803b443: c132 cd26 335c 191f 831d cd31 f643 45df 2.&.\3....1.C..E 803b453: 8007 ae8b f28d dd4c c11b 2077 1d42 11f9 ......L...w B... 803b463: 43a1 bad7 31d7 5339 91de 001f a5b7 16cc .C...19S........ 803b473: 831b b1a5 fc0f 18ad 0ee3 1e8f 0489 8c71 ..............q. 803b483: 2b0a 5fc4 c3b9 0476 2321 5605 a04f fa00 .+._..v.!#.VO... 803b493: b45e 9285 5acf bc68 31ce cded 2720 9a48 ^....Zh..1.. 'H. 803b4a3: 4100 f77f 1006 ceb0 c9c0 a02c 075c 7592 .A........,.\..u 803b4b3: e15e 7a29 d241 83ca c3bb 8a9d 1bfb b3c1 ^.)zA........... 803b4c3: 442c 9cb1 b4c6 ee9c 8d90 63c1 4041 4bc7 ,D.........cA@.K 803b4d3: f179 8387 045f e78d 81ff 681e ac06 3f76 y..._......h..v? 803b4e3: 63c7 6a1a 52e6 22a6 197b 2ad3 9777 c132 .c.j.R."{..*w.2. 803b4f3: 2514 fa1f 97e2 2b3c ed41 f7a7 1a67 c388 .%....<+A...g... 803b503: f867 0ebb 3764 6d65 6af0 fa82 eea7 7c95 g...d7em.j.....| 803b513: 9f70 1a8a 2a64 6c79 4025 5628 10f2 020b p...d*yl%@(V.... 803b523: 007f a811 38b2 db11 d8f5 a874 205a 0f23 .....8....t.Z #. 803b533: a7b5 3708 cb40 d55d 8162 af18 eee2 c05b ...7@.].b.....[. 803b543: a303 5308 89d3 120e 1eae b472 d358 764a ...S......r.X.Jv 803b553: 98a0 4c8e d819 4884 8768 b99c 89c3 fe9b ...L...Hh....... 803b563: 3bde 7876 da63 7de1 be4b 8e6b 4451 d731 .;vxc..}K.k.QD1. 803b573: 6bb0 0a02 e418 bb48 1de2 9010 6c03 0afb .k....H......l.. 803b583: 6b95 2fdd 5f31 749c ca36 e1d0 a500 4950 .k./1_.t6.....PI 803b593: b95f 900d edd8 1001 4cd2 8edf c385 2bd3 _........L.....+ 803b5a3: 19ff a02a 6af2 a0e2 43c8 5d5a d866 299c ..*..j...CZ]f..) 803b5b3: 4b1c 9a20 819e 91ad b65a a84d 081c 59dc .K .....Z.M....Y 803b5c3: c614 6771 c74c c41d 4e5b a263 0a05 3c29 ..qgL...[Nc...)< 803b5d3: f6b4 a782 2d42 defa fe9a 174c 8713 31c8 ....B-....L....1 803b5e3: 221d 81a9 31b4 5f86 25e6 90ff 647b 024d ."...1._.%..{dM. 803b5f3: d99e a509 7280 db20 e206 3ef8 e3a6 543b .....r ....>..;T 803b603: d31d 3420 9100 5c22 ea54 b281 8034 3764 .. 4.."\T...4.d7 803b613: 0aef 7dde a403 0eb0 bbf9 c59e 3884 18e9 ...}.........8.. 803b623: 49d3 7fc7 48b5 6660 f200 9490 f403 ae0e .I...H`f........ 803b633: 6659 c7a1 ab89 d07b a111 9e5d 2502 c79b Yf....{...]..%.. 803b643: 90d0 d64c 889c f675 d284 5586 3b78 760a ..L...u....Ux;.v 803b653: c00d a261 0400 037e 7704 3348 2d0d 5a91 ..a...~..wH3.-.Z 803b663: 158d 6a75 4b75 3080 2038 551f 5c41 4f28 ..ujuK.08 .UA\(O 803b673: 7487 b9f1 f0ab 6ab9 40fb 93bc ac84 b06f .t.....j.@....o. 803b683: 2824 167b 127f e1d9 5158 53fb e9aa 7e3a $({.....XQ.S..:~ 803b693: 5b20 f084 3c00 ca52 8641 7823 4f30 c54f [.......*, 803b763: 097d 9d4d ae64 4fd7 9b36 eee1 9a54 7eb4 }.M.d..O6...T..~ 803b773: 43c4 e40f a270 89de 6e8c 2e07 95e3 3f5b .C..p....n....[? 803b783: 177b 11a0 c562 c4c9 ac6d d29b fc6f 8700 {...b...m...o... 803b793: bc37 d50c 513c 4c2c 1e4e 142d e4a7 ab97 7...: 803b9a5: 722f 6c6f 2e65 736a 0000 0000 5448 5054 /role.js....HTTP 803b9b5: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 803b9c5: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 803b9d5: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 803b9e5: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 803b9f5: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 803ba05: 6e65 2d74 654c 676e 6874 203a 3132 3930 ent-Length: 2109 803ba15: 0a0d 6f43 6e6e 6365 6974 6e6f 203a 6c43 ..Connection: Cl 803ba25: 736f 0d65 430a 6e6f 6574 746e 742d 7079 ose..Content-typ 803ba35: 3a65 6120 7070 696c 6163 6974 6e6f 782f e: application/x 803ba45: 6a2d 7661 7361 7263 7069 0d74 430a 6e6f -javascript..Con 803ba55: 6574 746e 452d 636e 646f 6e69 3a67 6720 tent-Encoding: g 803ba65: 697a 0d70 430a 6361 6568 432d 6e6f 7274 zip..Cache-Contr 803ba75: 6c6f 203a 7270 7669 7461 2c65 6d20 7861 ol: private, max 803ba85: 612d 6567 383d 3436 3030 0a0d 0a0d 8b1f -age=86400...... 803ba95: 0008 0000 0000 0a04 58bd 6ee1 b91b 7e11 .........X.n...~ 803baa5: 3595 e0ef 46ec adeb bb94 88a6 6b36 7621 .5...F......6k!v 803bab5: 8bd2 760f c41c f43e c30a b830 6524 bcf1 ...v..>...0.$e.. 803bac5: 6e5a 94b9 d56d 5016 d01c ed5f 3eaf fb40 Zn..m..P.._..>@. 803bad5: 450a 0771 47f4 67db df90 1fa8 bbb9 4ad2 .Eq..G.g.......J 803bae5: 93b6 3fa0 c40a 3481 921c 99c3 be6f d199 ...?...4....o... 803baf5: 9270 2333 ee55 e97d e0d3 0b46 d133 c7b9 p.3#U.}...F.3... 803bb05: 9b15 458c a26e 6173 64de 7ec2 99dc 71ee ...En.sa.d.~...q 803bb15: cc68 8d86 cb3e bb14 b990 7634 cb1f d504 h...>.....4v.... 803bb25: b97b fa11 6692 91be a163 2626 d908 34a4 {....f..c.&&...4 803bb35: bc6a 356b 15a1 f2d6 14a4 a166 52db 7b09 j.k5......f..R.{ 803bb45: abe2 05d6 3a99 9c3f 7f18 5461 28a6 feff .....:?...aT.(.. 803bb55: ff60 62b5 c13e 2e1a d888 1cb9 ce90 3501 `..b>..........5 803bb65: 48a3 9cd3 b1ab 841f 9be4 c737 6c24 c4cc .H........7.$l.. 803bb75: 2e76 6132 aec4 1752 f852 ab44 904c 5c20 v.2a..R.R.D.L. \ 803bb85: 4a15 d10e c495 5709 8c11 d6a5 d121 8b48 .J.....W....!.H. 803bb95: 4261 817e 24ab 98be 4671 4166 d1b8 7a5b aB~..$..qFfA..[z 803bba5: 65a0 0d10 90d3 3705 5497 3c7b 49e6 147d .e.....7.T{<.I}. 803bbb5: 7dac 4c6b 41f1 6efc 4a22 c833 95c5 2ab7 .}kL.A.n"J3....* 803bbc5: 5bea ad51 0afc b861 df14 a61f 083f 7c66 .[Q...a.....?.f| 803bbd5: 2072 5699 1aa5 c89a 396e 7e3e 8d6f 548e r .V....n9>~o..T 803bbe5: 7221 0d3f b869 0dd1 7b62 889b cc21 a0b5 !r?.i...b{..!... 803bbf5: 5a7c 6a1a 1b04 fcd1 245c e7ad 9d7f 3c24 |Z.j....\$....$< 803bc05: 0a72 5647 7361 17d3 5810 49e5 3e19 76eb r.GVas...X.I.>.v 803bc15: 4493 fc0c 8ae2 95ef 4abb dc6b d4ed 42cb .D.......Jk....B 803bc25: a5e5 1638 26d7 cd24 2461 cc49 10b4 e86a ..8..&$.a$I...j. 803bc35: cdb1 164d a2d1 a6c8 0f3e 3e82 2e83 0adc ..M.....>..>.... 803bc45: 9dd7 e4fb d68d 934a 9820 dcc1 e452 6fdc ......J. ...R..o 803bc55: 9485 7e72 b4a4 cc43 6950 3edf 4d20 001e ..r~..C.Pi.> M.. 803bc65: b95b dd33 68cd be59 63a3 ac84 16c4 ba9a [.3..hY..c...... 803bc75: b1b0 1ba4 97b3 9469 fc89 8cdc d662 04e9 ......i.....b... 803bc85: 09e9 8d3b f070 4b9b 74a0 965f e446 fb42 ..;.p..K.t_.F.B. 803bc95: 6584 5d92 e0ac baa0 8ccd 6964 fd61 18ca .e.]......dia... 803bca5: d32d a989 87cf 5977 c0f2 971a 25d6 0380 -.....wY.....%.. 803bcb5: e209 4af2 361a 7072 a5a7 3420 7aa3 925c ...J.6rp.. 4.z\. 803bcc5: 0bbe b27a 0d84 472d 5951 4864 f20c 0905 ..z...-GQYdH.... 803bcd5: 7a4e b1a7 cebd fb29 e1dc 4e24 8f11 988b Nz....)...$N.... 803bce5: 53d9 9eb8 bcca 1898 041c d7b5 ba7a bee7 .S..........z... 803bcf5: c821 682c 69eb 5191 2959 707d 9d1f acc6 !.,h.i.QY)}p.... 803bd05: 2497 e06c 46ec b552 b4de 3bb4 5b24 123d .$l..FR....;$[=. 803bd15: 3ff4 03a1 5995 502b a530 184e b724 5c73 .?...Y+P0.N.$.s\ 803bd25: e2c8 a856 cb98 b826 6d2c 1a9e f07b 1350 ..V...&.,m..{.P. 803bd35: 8e54 f130 ac97 1309 9847 29dc 6122 fc27 T.0.....G..)"a'. 803bd45: d9b4 6092 1c87 e2fa 7ba4 249a a834 67b9 ...`.....{.$4..g 803bd55: 8b92 d192 4042 3bde 660d 9495 6590 e1da ....B@.;.f...e.. 803bd65: 8da1 ad6d 4bac 8768 a424 ef53 dd4d 6cc9 ..m..Kh.$.S.M..l 803bd75: dbbb 6bdc ed13 e035 0b1f d280 831c 7ca0 ...k..5........| 803bd85: 6161 3ee0 9d05 9eaf bb77 d94f 4b53 2140 aa.>....w.O.SK@! 803bd95: 784f c487 b89e 102e d2fb 199e f519 c1cd Ox.............. 803bda5: 11f1 9300 039f 0bce 56c0 485e d2f8 15b6 .........V^H.... 803bdb5: 815a d6eb ad55 cb91 8fa3 9347 ebd0 bcf6 Z...U.....G..... 803bdc5: 696f f5ee fc5e ebaa bb75 fb7d e7af bae1 oi..^...u.}..... 803bdd5: f5b8 1864 edfa e1d1 ff3b 42ff 1533 24af ..d.....;..B3..$ 803bde5: e404 8c8a 4da7 22b4 4412 2a85 60fc 4780 .....M.".D.*.`.G 803bdf5: 480c ff1f 126f 3ecb 9296 d22a 1d15 0672 .H..o..>..*...r. 803be05: f97f b38d a583 2d87 5961 fafe 5528 a059 .......-aY..(UY. 803be15: 50d1 f7c4 8b29 51ae 1d16 c580 4bac 82a2 .P..)..Q.....K.. 803be25: 52ea 96f8 96e1 1594 a984 2c2f 212f 1f57 .R......../,/!W. 803be35: 21e4 1236 e2ec 329d 3872 8145 4620 044f .!6....2r8E. FO. 803be45: ba9e 3d04 85c9 4c01 e20c 9e5d 9455 0a8a ...=...L..].U... 803be55: 7031 778c 2cd6 ae44 05f8 35fd ea29 0c22 1p.w.,D....5).". 803be65: 1d42 7fba a16a 50d5 d466 49f1 58eb 2e2e B...j..Pf..I.X.. 803be75: 1325 ed67 e6d5 87ec 3e96 4172 042e 033f %.g......>rA..?. 803be85: 0f1b 1ea5 dec3 d2c6 09b3 1aa8 b3d5 6a59 ..............Yj 803be95: 7f4e bd74 62be 6b89 e6b8 d53d 6c74 1811 N.t..b.k..=.tl.. 803bea5: d4dc 8844 964f bcc2 bf6e d24e c5fa 3316 ..D.O...n.N....3 803beb5: b8f9 fc70 f5e6 581e 971c dad5 fbb3 626b ..p....X......kb 803bec5: 654c 5b36 cc5e 9305 9a63 ab1d 991d 3d53 Le6[^...c.....S= 803bed5: e4b5 5d5b d3e6 6ded 37a4 b352 cbce 2d67 ..[]...m.7R...g- 803bee5: 4afa f29d 7ab1 ed5d ee5e 1cf2 d05c e07c .J...z].^...\.|. 803bef5: ed21 2c0d 37b5 2958 651e c861 db12 450f !..,.7X).ea....E 803bf05: 280e 0f82 fd7a 5c6e 13f3 f97b 5d32 47da .(..z.n\..{.2].G 803bf15: a6b5 b753 80f7 b696 a9c9 32d8 0e69 2c24 ..S........2i.$, 803bf25: 92ed 0d0e 7e81 16d6 acf6 17b0 8734 1bae .....~......4... 803bf35: febc f4ec 0196 4dc9 f621 741c d565 eca7 .......M!..te... 803bf45: eba8 6cca f0c7 2792 7434 549f cb61 9956 ...l...'4t.Ta.V. 803bf55: 83a4 7fb4 0b33 58c9 2594 173d e644 7b5e ....3..X.%=.D.^{ 803bf65: f6fd 6fd6 8d7f b56a ac84 d1dd def7 2c8a ...o..j........, 803bf75: de53 946f f8ce ca06 4925 99cf 50ca 3fea S.o.....%I...P.? 803bf85: 6071 96ad 2f90 ddba 2f17 3f9e 5bb7 fa0d q`.../.../.?.[.. 803bf95: cf8a bcda c450 e1f6 6870 4ef7 7674 caff ....P...ph.Ntv.. 803bfa5: 0e95 9ee4 efe5 9dd1 a702 1268 3abc bc39 ..........h..:9. 803bfb5: 3eef 7bec bc30 1276 5f8a f92b 16ab f6f1 .>.{0.v.._+..... 803bfc5: 25b6 0db2 ede2 4aed 9833 5d34 a2de 17f2 .%.....J3.4].... 803bfd5: 43e8 7473 702c a7e9 c97b 7c20 a165 2113 .Cst,p..{. |e..! 803bfe5: 8deb 6db2 9215 8b92 c3eb 7621 b23f 3492 ...m......!v?..4 803bff5: aff1 9de2 e926 6ded 5177 eb73 a5f6 8ce9 ....&..mwQs..... 803c005: d3b6 b838 7541 c1b5 493d 6051 1597 8d36 ..8.Au..=IQ`..6. 803c015: 9d3b 2eb4 5bac 59bd 48d5 bdd6 bb79 5f65 ;....[.Y.H..y.e_ 803c025: 17de 34dc 7b57 9974 7e4c bbaf 074d 4ba4 ...4W{t.L~..M..K 803c035: 84fa 1d04 84ba ea67 8b23 74ea 7ea1 ab6a ......g.#..t.~j. 803c045: ad80 7ebd 7410 0448 57e0 03a2 9b95 1f91 ...~.tH..W...... 803c055: 7a74 d495 fda9 927a bf65 28c5 3101 16f1 tz....z.e..(.1.. 803c065: 6f9a 44d5 6e97 7f77 3b21 3990 b79a e975 .o.D.nw.!;.9..u. 803c075: 4091 b980 ce95 165c f937 98d5 24df 0f28 .@....\.7....$(. 803c085: d245 a954 a298 5e27 6a14 dad8 789e 47d0 E.T...'^.j...x.G 803c095: 7862 d549 aa35 695f 68a6 5572 9941 d334 bxI.5._i.hrUA.4. 803c0a5: f484 5a08 e685 d410 d71b 56ef 050d 88fa ...Z.......V.... 803c0b5: 4ba7 09a6 cf3a d7c5 794f 0c53 af7f 7172 .K..:...OyS...rq 803c0c5: 1c38 7c82 2661 4158 f16c 65a0 2f8e 18b6 8..|a&XAl..e./.. 803c0d5: 7ace 0264 d96b 99f3 cb56 fd1c dbf0 83e3 .zd.k...V....... 803c0e5: c4fd c515 ccd9 e20f 9e1a b72a a155 661d ..........*.U..f 803c0f5: 6600 e405 8f1b bca3 3a62 e614 2cc7 e9cd .f......b:...,.. 803c105: f225 ddb5 a234 35eb f6a2 662e 8938 b665 %...4..5...f8.e. 803c115: cfdc 9756 ba29 5643 610f d03f 5a4b 2d32 ..V.).CV.a?.KZ2- 803c125: d30b 54bf fb92 7e18 c848 3190 d3cd fcc8 ...T...~H..1.... 803c135: 772f ba7f e3fb 3ffc 9ff3 9f3c 5a74 3b99 /w.....?..<.tZ.; 803c145: 19b1 7809 c092 50ee 9bb9 d00b dbad 32d9 ...x...P.......2 803c155: 234c 65f0 4c3d 7c12 cd63 d1d0 a216 63be L#.e=L.|c......c 803c165: d98c c91d fb8c 0c88 83b5 42cf 0690 59b3 ...........B...Y 803c175: 46b8 2b38 2d39 9acd 377f acbe 5708 7262 .F8+9-...7...Wbr 803c185: c572 e5a2 35c2 7017 0f09 d4c6 e91a 5a38 r....5.p......8Z 803c195: dc72 b2de 7731 cc1d 4596 1627 782a 94a6 r...1w...E'.*x.. 803c1a5: 9c5d 356b c581 9d96 8dab cd35 3545 2f17 ].k5......5.E5./ 803c1b5: 1d94 af07 2caa d718 81b5 478f 80af 6965 .....,.....G..ei 803c1c5: b564 9177 18c7 56bd a98f c8cb 6f3d 53b9 d.w....V....=o.S 803c1d5: 0f1f 063a e332 2d66 9100 9fb5 9a9a c3dc ..:.2.f-........ 803c1e5: 16df e3b7 dead f992 d0a5 7046 d31b 0db6 ..........Fp.... 803c1f5: fe64 8b37 bb81 e71f 98ff 7cff 87f7 4ff9 d.7........|...O 803c205: 7ff3 fdde f778 ab67 7c86 cd6b 3547 4810 ....x.g..|k.G5.H 803c215: e888 7e2f 7856 3a42 b52b a510 43a6 849e ../~VxB:+....C.. 803c225: f04f c28b d093 149b f01c 502d 0343 7700 O.........-PC..w 803c235: 0615 c5c0 4eca 7346 b226 f71d 2a9a 98ca .....NFs&....*.. 803c245: 9a2a 5944 f28b cde2 a1fc 5f07 9d51 0da3 *.DY......._Q... 803c255: bd6d 0ed8 96ef c688 e354 8997 317d 0934 m.......T...}14. 803c265: 65f9 0801 35f0 fc57 6e15 d7f8 e7fc bff9 .e...5W..n...... 803c275: 7fe7 8bb7 83ff aa03 7c67 d9f7 e06e e1ad ........g|..n... 803c285: 5528 8a7c 2d0c a711 811d 50c1 6aa0 5c2d (U|..-.....P.j-\ 803c295: 16e0 4d99 77a9 8b8a 1312 e2e0 97f7 e521 ...M.w........!. 803c2a5: 2f62 5bf7 f259 0cd1 ad73 5aea b58a d6f6 b/.[Y...s..Z.... 803c2b5: b619 c494 36ab 3168 9756 4aa2 fc6e 35ba .....6h1V..Jn..5 803c2c5: ff8b 220b 3862 10e8 0013 1400 ..."b8..... 0803c2d0 : 803c2d0: cd14 0803 c2e4 0803 c2f4 0803 04bd 0000 ................ 803c2e0: 0001 0000 .... 0803c2e4 : 803c2e4: 682f 7369 6f74 7972 682e 6d74 006c 0000 /history.html... 803c2f4: 5448 5054 312f 312e 3220 3030 4f20 0d4b HTTP/1.1 200 OK. 803c304: 530a 7265 6576 3a72 6c20 4977 2f50 2e31 .Server: lwIP/1. 803c314: 2e33 2031 6828 7474 3a70 2f2f 6173 6176 3.1 (http://sava 803c324: 6e6e 6861 6e2e 6e6f 6e67 2e75 726f 2f67 nnah.nongnu.org/ 803c334: 7270 6a6f 6365 7374 6c2f 6977 2970 0a0d projects/lwip).. 803c344: 6f43 746e 6e65 2d74 654c 676e 6874 203a Content-Length: 803c354: 3031 3134 0a0d 6f43 6e6e 6365 6974 6e6f 1041..Connection 803c364: 203a 6c43 736f 0d65 430a 6e6f 6574 746e : Close..Content 803c374: 742d 7079 3a65 7420 7865 2f74 7468 6c6d -type: text/html 803c384: 0a0d 6f43 746e 6e65 2d74 6e45 6f63 6964 ..Content-Encodi 803c394: 676e 203a 7a67 7069 0a0d 0a0d 8b1f 0008 ng: gzip........ 803c3a4: 0000 0000 0a04 568d 6ecd 46db 7e10 8615 .......V.n.F.~.. 803c3b4: 0c09 1011 0b25 14bd c895 50a0 0873 a050 ....%......Ps.P. 803c3c4: fa01 e683 ac14 11c8 f1b9 9772 5dd9 5652 ..........r..]RV 803c3d4: 02eb fa49 4393 040a 21e8 a5ed fa28 6e06 ..I..C...!..(..n 803c3e4: 0301 eb4e 19e4 6f96 59d4 a92e b5d2 fae0 ..N....o.Y...... 803c3f4: 7160 667f 6676 f9be c666 5b8b 7d1f fcb2 `q.fvf..f..[.}.. 803c404: e1ec 7b83 ae5e 160b ec2f c7af cf08 df22 ...{^.../.....". 803c414: 1dc7 3490 145e 89a0 e497 2a44 91d0 e95f ...4^.....D*.._. 803c424: f875 de3e a7b5 d6b9 0865 2a4f 475a 97fe u.>.....e.O*ZG.. 803c434: e7e1 861f 514b 4494 15d3 df03 044b c0d7 ....KQ.D....K... 803c444: e551 bdfe d208 7a0c 4e25 880a 9afc a6c2 Q......z%N...... 803c454: 5214 e40f 3436 79d5 4294 134d db08 98cd .R..64.y.BM..... 803c464: aa72 6129 4aa1 8308 3668 c82e 2d31 62aa r.)a.J..h6..1-.b 803c474: afb7 c814 4376 64d0 8874 3426 0cd5 f362 ....vC.dt.&4..b. 803c484: f9ba 79b6 de6a 539a b7f3 3cd7 ef33 1fcc ...yj..S...<3... 803c494: cbcd b9e6 3739 166f 2753 60b2 1f94 b979 ....97o.S'.`..y. 803c4a4: 7584 17e4 f284 a249 ef94 6049 af91 96f4 .u....I...I`.... 803c4b4: ca81 3401 a83e 4912 ed4b 6de9 5e89 386b ...4>..IK..m.^k8 803c4c4: d3d6 a4c7 ee26 f7d4 4c94 5f22 060a c793 ....&....L"_.... 803c4d4: 850a eea7 171c bb0e 4895 f1b7 a522 97b5 .........H.."... 803c4e4: a230 e454 5273 88af dcf4 4c27 4d61 a62a 0.T.sR....'LaM*. 803c4f4: edfb 1e9a 1a43 516a 4be2 7457 fb42 4822 ....C.jQ.KWtB."H 803c504: 1577 482f 3ae7 29e5 4f1c de6c 4910 8367 w./H.:.).Ol..Ig. 803c514: 4c89 5f58 fe08 33e1 6ffd 71af f7db 8a68 .LX_...3.o.q..h. 803c524: 0331 42af 498a 44ea d62b a3eb bd73 b847 1..B.I.D+...s.G. 803c534: d274 1176 6423 0d7b e6c7 7337 708a 9a9f t.v.#d{...7s.p.. 803c544: 730b 3cd6 9e6f 2f36 759d 3f2b 41d4 6906 .s.. 803c5a4: caf4 9615 fde1 8930 32da 9434 4aa0 55c1 ......0..24..J.U 803c5b4: c3eb 3da2 5f6a 576d fcbb f3b9 6cce 11cf ...=j_mW.....l.. 803c5c4: a8b4 a71d b4b4 3ecb 6559 d18e 3efc f820 .......>Ye...> . 803c5d4: 1219 df3c 6127 4691 5ee0 5561 9b9c 52fd ..<.'a.F.^aU...R 803c5e4: db3f 698a 985e 6bb3 7e64 e842 cccf 8585 ?..i^..kd~B..... 803c5f4: dadd 5a99 7077 b6d5 6d0a def9 d446 ffa1 ...Zwp...m..F... 803c604: 2528 589a b582 f637 616b 6fc0 4bcb b20b (%.X..7.ka.o.K.. 803c614: a2a5 1505 c86b 5016 847f a37c 7619 a412 ....k..P..|..v.. 803c624: 1f67 4ae9 30f3 a293 d5b2 aab1 16b4 707c g..J.0........|p 803c634: d9e3 aedb 7c9c f04f d184 28e4 33f2 0fd0 .....|O....(.3.. 803c644: 0648 59a3 4a80 24aa 23dc 9292 a730 0a69 H..Y.J.$.#..0.i. 803c654: cb1c 5659 8648 0393 9e46 6254 d58e 128b ..YVH...F.Tb.... 803c664: 9ce8 3d7b 6ef6 a66c 5094 76b7 33ae 5683 ..{=.nl..P.v.3.V 803c674: bca4 6462 91c8 6492 bb94 e3a0 e505 3565 ..bd...d......e5 803c684: 3b6c ff1d 292a a9b1 24a2 5876 bf45 9ec2 l;..*)...$vXE... 803c694: f334 03e3 52be 7ce5 3eea 4e2e ab8b 6295 4....R.|.>.N...b 803c6a4: a0b4 c6d8 770e b5c1 dfc8 3f14 fd8e ffee .....w.....?.... 803c6b4: 9303 02fb 39bb 7d7a 4a92 623b 73ee ba3d .....9z}.J;b.s=. 803c6c4: 3a33 7cc0 f9e8 7fce 0db7 b626 2efd 58dd 3:.|......&....X 803c6d4: ae09 5a85 09b6 d93d dd05 b465 dde3 e8fe ...Z..=...e..... 803c6e4: 494b 220b 21b7 35e5 0d48 03a9 653c a482 KI.".!.5H.....+...{~ 803c784: f114 a3bb dcde f320 31ff 135a 4156 8c10 ...... ..1Z.VA.. 803c794: cd6f 0f82 416a ef53 1bf0 425b 4ced 4ac6 o...jAS...[B.L.J 803c7a4: ff6d f96b bd07 325e c546 0008 2f00 m.k...^2F.... 0803c7b1 : 803c7b1: 662f 7661 6369 6e6f 692e 6f63 0000 0000 /favicon.ico.... 803c7c1: 5448 5054 312f 312e 3220 3030 4f20 0d4b HTTP/1.1 200 OK. 803c7d1: 530a 7265 6576 3a72 6c20 4977 2f50 2e31 .Server: lwIP/1. 803c7e1: 2e33 2031 6828 7474 3a70 2f2f 6173 6176 3.1 (http://sava 803c7f1: 6e6e 6861 6e2e 6e6f 6e67 2e75 726f 2f67 nnah.nongnu.org/ 803c801: 7270 6a6f 6365 7374 6c2f 6977 2970 0a0d projects/lwip).. 803c811: 6f43 746e 6e65 2d74 654c 676e 6874 203a Content-Length: 803c821: 3131 3035 0a0d 6f43 6e6e 6365 6974 6e6f 1150..Connection 803c831: 203a 6c43 736f 0d65 430a 6e6f 6574 746e : Close..Content 803c841: 742d 7079 3a65 6920 616d 6567 782f 692d -type: image/x-i 803c851: 6f63 0d6e 430a 6361 6568 432d 6e6f 7274 con..Cache-Contr 803c861: 6c6f 203a 7270 7669 7461 2c65 6d20 7861 ol: private, max 803c871: 612d 6567 383d 3436 3030 0a0d 0a0d 0000 -age=86400...... 803c881: 0001 0001 1010 0000 0000 0020 0468 0000 .......... .h... 803c891: 0016 0000 0028 0000 0010 0000 0020 0000 ....(....... ... 803c8a1: 0001 0020 0000 0000 0440 0000 0000 0000 .. .....@....... 803c8b1: 0000 0000 0000 0000 0000 0000 ffff 01ff ................ 803c8c1: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803c8d1: ffff 01ff ffff 01ff d2d2 ffd2 d2d2 ffd2 ................ 803c8e1: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803c8f1: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803c901: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803c911: 8d8d ff8d 8484 ff84 8989 ff89 8989 ff89 ................ 803c921: 8484 ff84 8d8d ff8d ffff 01ff ffff 01ff ................ 803c931: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803c941: ffff 01ff ffff 01ff a4a4 ffa4 8484 ff84 ................ 803c951: aeae ffae ffff 01ff ffff 01ff ffff 01ff ................ 803c961: ffff 01ff aeae ffae 8484 ff84 a4a4 ffa4 ................ 803c971: ffff 01ff ffff 01ff 8181 ff81 ffff 01ff ................ 803c981: ffff 01ff a0a0 ffa0 9a9a ff9a ffff 01ff ................ 803c991: c7c7 ffc7 8f8f ff8f 8585 ff85 8585 ff85 ................ 803c9a1: 8f8f ff8f caca ffca ffff 01ff d5d5 ffd5 ................ 803c9b1: ffff 01ff 7777 ff77 ffff 01ff ffff 01ff ....www......... 803c9c1: d5d5 ffd5 8484 ff84 ffff 01ff a8a8 ffa8 ................ 803c9d1: 8c8c ff8c bbbb ffbb ffff 01ff ffff 01ff ................ 803c9e1: baba ffba afaf ffaf ffff 01ff ffff 01ff ................ 803c9f1: 6465 ff5b ffff 01ff ffff 01ff ffff 01ff ed[............. 803ca01: 9898 ff98 b0b0 ffb0 d5d5 ffd5 8484 ff84 ................ 803ca11: dada ffda 9595 ff95 8484 ff84 9d9d ff9d ................ 803ca21: d7d7 ffd7 ffff 01ff 9898 ff97 7a7b ff73 ............{zs. 803ca31: cedb ff79 c0d2 ff55 ffff 01ff ffff 01ff ..y...U......... 803ca41: 9393 ff93 ffff 01ff a4a4 ffa4 bebe ffbe ................ 803ca51: bdbd ffbd d1d1 ffd1 ffff 01ff ffff 01ff ................ 803ca61: b4b5 ffae 5f5f ff5d 979d ff6b c0d2 ff55 ....__]...k...U. 803ca71: ffff 01ff b5c9 ff35 ffff 01ff ffff 01ff ......5......... 803ca81: f0f0 fff0 ffff 01ff f1f1 fff1 ffff 01ff ................ 803ca91: d5d5 ffd5 cfd0 ffce 8585 ff85 6060 ff60 ............```. 803caa1: 9194 ff85 b5ca ff37 ffff 01ff b9cc ff41 ......7.......A. 803cab1: ffff 01ff b4c9 ff33 ffff 01ff 6262 ff62 ......3.....bbb. 803cac1: 5d5e ff5c 5c5c ff5c 5d5e ff5c 6161 ff60 ^]\.\\\.^]\.aa`. 803cad1: 6567 ff5b 8486 ff7b ffff 01ff ffff 01ff ge[...{......... 803cae1: ffff 01ff b5ca ff37 ffff 01ff b9cc ff41 ......7.......A. 803caf1: ffff 01ff b4c9 ff33 ffff 01ff ffff 01ff ......3......... 803cb01: b5c9 ff35 ffff 01ff c0d2 ff55 ffff 01ff ..5.......U..... 803cb11: c4d4 ff5e c3d4 ff5c ffff 01ff ffff 01ff ..^...\......... 803cb21: c3d4 ff5c c4d4 ff5e cedb ff79 c0d2 ff55 ..\...^...y...U. 803cb31: ffff 01ff b5c9 ff35 ffff 01ff ffff 01ff ......5......... 803cb41: c0d1 ff54 cfdc ff7d ffff 01ff b4c9 ff33 ..T...}.......3. 803cb51: ffff 01ff bed0 ff50 b4c9 ff33 b4c9 ff33 ......P...3...3. 803cb61: c0d2 ff55 ffff 01ff b4c9 ff33 ffff 01ff ..U.......3..... 803cb71: cedb ff79 c0d2 ff55 ffff 01ff ffff 01ff ..y...U......... 803cb81: ffff 01ff b4c9 ff33 ffff 01ff cad9 ff6f ......3.......o. 803cb91: b9cc ff41 d6e1 ff8f ffff 01ff ffff 01ff ..A............. 803cba1: d5e0 ff8c b9cc ff40 cedb ff79 ffff 01ff ......@...y..... 803cbb1: b4c9 ff33 ffff 01ff ffff 01ff ffff 01ff ..3............. 803cbc1: ffff 01ff c5d5 ff62 c1d2 ff58 ffff 01ff ......b...X..... 803cbd1: ffff 01ff bbce ff46 b5c9 ff35 b5c9 ff35 ......F...5...5. 803cbe1: bbce ff46 ffff 01ff ffff 01ff c0d2 ff55 ..F...........U. 803cbf1: c5d5 ff62 ffff 01ff ffff 01ff ffff 01ff ..b............. 803cc01: ffff 01ff ffff 01ff c8d7 ff69 b4c9 ff33 ..........i...3. 803cc11: cedb ff79 ffff 01ff ffff 01ff ffff 01ff ..y............. 803cc21: ffff 01ff cedb ff79 b4c9 ff33 c8d7 ff69 ......y...3...i. 803cc31: ffff 01ff ffff 01ff ffff 01ff ffff 0dff ................ 803cc41: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803cc51: b9cd ff42 b4c9 ff33 b7cb ff3b b7cb ff3b ..B...3...;...;. 803cc61: b4c9 ff33 b9cd ff42 ffff 01ff ffff 01ff ..3...B......... 803cc71: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803cc81: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803cc91: ffff 01ff ffff 01ff e4eb ffb5 e4eb ffb5 ................ 803cca1: ffff 01ff ffff 01ff ffff 01ff ffff 01ff ................ 803ccb1: ffff 01ff ffff 01ff ffff 01ff 0000 ffff ................ 803ccc1: 0000 ffff 0000 ffff 0000 ffff 0000 ffff ................ 803ccd1: 0000 ffff 0000 ffff 0000 ffff 0000 ffff ................ 803cce1: 0000 ffff 0000 ffff 0000 ffff 0000 ffff ................ 803ccf1: 0000 ffff 0000 ffff 0000 ffff 0000 5000 ............... 0803cd00 : 803cd00: cd50 0803 cd64 0803 cd70 0803 2873 0000 P...d...p...s(.. 803cd10: 0001 0000 .... 0803cd14 : 803cd14: 0000 0000 c7b1 0803 c7c1 0803 053c 0000 ............<... 803cd24: 0001 0000 .... 0803cd28 : 803cd28: 9fdc 0803 a8a3 0803 a8b3 0803 10f2 0000 ................ 803cd38: 0001 0000 .... 0803cd3c : 803cd3c: cd00 0803 77ae 0803 77ba 0803 250f 0000 .....w...w...%.. 803cd4c: 0001 0000 .... 0803cd50 : 803cd50: a004 0803 9cc9 0803 9cd5 0803 02f6 0000 ................ 803cd60: 0001 0000 .... 0803cd64 : 803cd64: 6d2f 6961 2e6e 7363 0073 0000 5448 5054 /main.css...HTTP 803cd74: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 803cd84: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 803cd94: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 803cda4: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 803cdb4: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 803cdc4: 6e65 2d74 654c 676e 6874 203a 3031 3431 ent-Length: 1014 803cdd4: 0d34 430a 6e6f 656e 7463 6f69 3a6e 4320 4..Connection: C 803cde4: 6f6c 6573 0a0d 6f43 746e 6e65 2d74 7974 lose..Content-ty 803cdf4: 6570 203a 6574 7478 632f 7373 0a0d 6f43 pe: text/css..Co 803ce04: 746e 6e65 2d74 6e45 6f63 6964 676e 203a ntent-Encoding: 803ce14: 7a67 7069 0a0d 6143 6863 2d65 6f43 746e gzip..Cache-Cont 803ce24: 6f72 3a6c 7020 6972 6176 6574 202c 616d rol: private, ma 803ce34: 2d78 6761 3d65 3638 3034 0d30 0d0a 1f0a x-age=86400..... 803ce44: 088b 0000 0000 0400 d50a db7d 238e 7239 ..........}..#9r 803ce54: afe8 53c8 e3e8 6dae a349 dd5b d854 3d82 ...S...mI.[.T..= 803ce64: 2beb 05e0 d80c d4fb 2c6e 5252 94aa 92db .+......n,RR.... 803ce74: 9052 bab2 47ab 3fd6 0618 180c 3838 ecbe R....G.?....88.. 803ce84: f80f fa57 1c93 3257 64c8 d4a6 7ded de38 ..W...W2.d...}8. 803ce94: 99da f251 8c12 0608 c183 9060 f1fc 7f17 ..Q.......`..... 803cea4: d9d4 fb96 b64d 7e2e fbce c3f3 f3a1 dc69 ....M..~......i. 803ceb4: f41f 9d47 ec7f fafc ffaf f3be c537 df3c ..G.........7.<. 803cec4: 721e 7af8 aa2e 517e e8fe 76ca f17e 7f63 .r.z..~Q...v~.c. 803ced4: 3e5d dd97 5f6c f315 de75 0ecd 22c5 2eef ]>..l_..u....".. 803cee4: 2af2 d62b ee87 78b2 679e aabb b728 f3f8 .*+....x.g..(... 803cef4: 9f65 9777 5965 fbe5 2aee 16cf 9ff8 7de7 e.w.eY...*.....} 803cf04: b2f9 6eeb 62b2 dddb dbe4 ee97 fb36 3dd4 ...n.b......6..= 803cf14: 73e4 71aa d978 b26c 97fd a2e3 ec38 d9d6 .s.qx.l.....8... 803cf24: e997 5d6c 3fce fa9e 5d87 9db1 af95 cebf ..l].?...]...... 803cf34: 1ff6 8bbb f6e5 2cb8 55b7 50ef 597d d3e7 .......,.U.P}Y.. 803cf44: 02a2 e602 3ea7 9940 fb65 e1ee 0665 ecff .....>@.e...e... 803cf54: bb8e 50f2 c420 3ee9 675f f155 3f29 33f5 ...P ..>_gU.)?.3 803cf64: e268 de53 cfed 6daa 597f 5fce f40e 6a73 h.S....m.Y._..sj 803cf74: ae7e 4fca 2080 7a82 175a 994f b966 ca6f ~..O. .zZ.O.f.o. 803cf84: 563f 6bf9 5bd5 f3e4 0f72 a180 6d85 05b9 ?V.k.[..r....m.. 803cf94: 00e8 b7b5 b6c8 f9cf 57be 016c 954c 082f .........Wl.L./. 803cfa4: 943e 665c eb2f 3f8a ed8a 8cb2 77f2 02fb >.\f/..?.....w.. 803cfb4: 8e49 0f52 f32f 7e79 4438 9fa9 fdb3 d8b6 I.R./.y~8D...... 803cfc4: bb3e 63d4 cfb5 42b6 b668 775e e3fa 2743 >..c...Bh.^w..C' 803cfd4: 0ecf 1439 95e8 152f ee33 f2a7 4bb5 841c ..9.../.3....K.. 803cfe4: 9d1f bb62 a97b f4ba f7ef 97d5 fe5d 43cb ..b.{.......]..C 803cff4: ed9e abe7 c70f e7de f67c a8b1 d97a 076e ........|...z.n. 803d004: d929 9e76 612b e2d9 b999 fc76 2abc bcaa ).v.+a....v..*.. 803d014: d877 9465 79f9 ed9f ef88 97dd bf75 66ca w.e..y......u..f 803d024: a6c0 71c3 1c5d 67b4 2f98 f9d2 ea7d 69f5 ...q]..g./..}..i 803d034: 44b6 e849 774b 411f b27a 74fd 5656 53ab .DI.Kw.Az..tVV.S 803d044: 79b1 aeee e7f3 bb7c ce38 3dca ca08 7074 .y....|.8..=..tp 803d054: efe2 b56e 56e8 e3ab 5b2e 802c 4876 555e ..n..V...[,.vH^U 803d064: 359b c08b db32 eb14 d32f dd3f d917 fbba .5..2.../.?..... 803d074: f957 53fa 120e 7599 c00f de94 df21 cb17 W..S...u....!... 803d084: 2547 3a8b 00ed de92 16cb 7bbf 5439 e1d3 G%.:.......{9T.. 803d094: f060 b1e6 39b7 92f4 a739 b959 72f8 7e84 `....9..9.Y..r.~ 803d0a4: 2e79 d3b6 e3c1 9b2c 447f b602 de8b 5cbc y.....,..D.....\ 803d0b4: fb97 d5e9 df9f f9ff 7f4f 7c31 af94 78f1 ........O.1|...x 803d0c4: 88fc b3b2 975c 7b9f a65f f987 5cbe 1faf ....\..{_....\.. 803d0d4: 7957 bcf1 96e2 d94e a2cb bb28 6cf3 29fb Wy....N...(..l.) 803d0e4: 743b fb77 79f2 bd0f fddb 0304 74a7 5ec2 ;tw..y.......t.^ 803d0f4: d76c 36c5 91ef 3fcc 08a2 2d01 1eeb f788 l..6...?...-.... 803d104: 76f3 833a c55e 065c 5d04 bd53 3f7d 5187 .v:.^.\..]S.}?.Q 803d114: 0d00 3e1d 3b5c c810 6d73 7077 bf7a 162a ...>\;..smwpz.*. 803d124: 7c8b a1fb e55b 181b 554e 941e 653b 1ac7 .|..[...NU..;e.. 803d134: 245d bb4f 9f6c ab6f 3653 1195 4d93 f059 ]$O.l.o.S6...MY. 803d144: a241 0510 81e8 366c bfdb 8aaf 9d6a 907f A.....l6....j... 803d154: eade 2741 e556 3a66 bddc 1676 33f0 9c5f ..A'V.f:..v..3_. 803d164: dd66 5772 60f1 003f db9e ee67 cfb3 95cc f.rW.`?...g..... 803d174: 01bb e474 5950 bfdc cbbd 9d37 23c1 6c0f ..t.PY....7..#.l 803d184: a6e8 28e9 9cdf ff80 8f1f e2c2 c0c1 c376 ...(..........v. 803d194: 6af4 1cb9 0e9c bca0 1244 6bb0 f7a7 3783 .j......D..k...7 803d1a4: 5527 1e00 ddd2 9bcd 6247 f4ac a0c7 b791 'U......Gb...... 803d1b4: 38a8 72aa ed37 6ff5 75a0 0480 11c4 bd55 .8.r7..o.u....U. 803d1c4: 88fe 3e52 133d a7e7 d07b d768 ed47 29f1 ..R>=...{.h.G..) 803d1d4: f9b3 eac4 494e 021a 9341 eec1 b4f5 1fda ....NI..A....... 803d1e4: cb5d 8e2a cca0 807a ca32 f633 b022 181b ].*...z.2.3."... 803d1f4: 0af8 58f2 8cfe 523f e979 d3e4 140e 8a2c ...X..?Ry.....,. 803d204: f430 e659 ca31 aa5e 34f2 412f 7f2d 2d9c 0.Y.1.^..4/A-..- 803d214: de40 1872 9b13 305d 3668 b6e5 a1a4 75dc @.r...]0h6.....u 803d224: 0cbf 01fb d3fb 05ec df88 5976 f865 ccbe ..........vYe... 803d234: a0d7 7dac 6e9b 2090 a7c7 76c5 e305 92ae ...}.n. ...v.... 803d244: 2181 025f a3c9 a9f7 1438 75b3 2dae 6880 .!_.....8..u.-.h 803d254: 4803 ac56 8124 984b 5897 08fd 380e 59e4 .HV.$.K..X...8.Y 803d264: b177 e2d6 0fe4 1b8c c127 ca80 20ab 3a05 w.......'.... .: 803d274: 5370 4954 c6d5 1ff5 2fe7 03fb e68c 595d pSTI...../....]Y 803d284: 1f40 05ec f79d f930 8064 e2dd d743 eb34 @.....0.d...C.4. 803d294: 8f12 4952 faf4 e8c9 f9d2 9f2a 847f 0a7e ..RI......*...~. 803d2a4: d8b0 3067 3df2 a612 591b 25cf de3b a564 ..g0.=...Y.%;.d. 803d2b4: 782b 686d dfda 6cbe f966 c3fe aa74 5662 +xmh...lf...t.bV 803d2c4: b76c 1f30 ece1 b3d9 c99d ab0c 8695 1df1 l.0............. 803d2d4: 5696 25b9 3269 c4ed 8673 f141 267f 4ecd .V.%i2..s.A..&.N 803d2e4: 9b5d 0859 7b85 e459 85eb b4e5 e060 e529 ].Y..{Y.....`.). 803d2f4: 1e84 d828 be79 104e 54db cfc1 2de3 2033 ..(.y.N..T...-3 803d304: ed4c c7a4 aa7a 9f94 ba68 a60f 9c34 9bff L...z...h...4... 803d314: cd0b 1072 9e69 7b45 5955 c1ae d154 10b9 ..r.i.E{UY..T... 803d324: 6a2b 1692 79a3 5971 6abc f719 0aed 58c0 +j...yqY.j.....X 803d334: 0303 ba0a b96b 297e ae16 945c 2b5c 2b5e ....k.~)..\.\+^+ 803d344: d538 8b22 6f75 ee55 9f8b c211 b3ba 2070 8.".uoU.......p 803d354: e96b 015a a8c7 02ad 1536 0424 693c a22b k.Z.....6.$...? 803d684: 9f18 c9fd fee8 6ee6 1938 6bc7 0de9 1c78 .......n8..k..x. 803d694: 74c0 f611 2f52 717b 2c59 2716 d8c5 a2b4 .t..R/{qY,.'.... 803d6a4: b556 3aba 8068 0828 2e19 aa28 7422 8a06 V..:h.(...(."t.. 803d6b4: ffb0 255d a6d0 62cb fe0f f9a7 58aa 5503 ..]%...b.....X.U 803d6c4: 3d8e c5ed 331c 87a0 7cc8 0b3d bdae 839c .=...3...|=..... 803d6d4: 5847 2885 c3ed 874f f9e1 2ba2 5915 29e4 GX.(..O....+.Y.) 803d6e4: 2c28 f1d3 48ef 6c22 927e 1d5b 93ae 8a9e (,...H"l~.[..... 803d6f4: 2004 4e4c 5030 efc0 ec0b 89ab 3259 a953 . LN0P......Y2S. 803d704: 99b5 ce4e be94 6664 a6aa 8a93 4d54 e997 ..N...df....TM.. 803d714: 9305 06d4 02b1 1a86 688e baf4 df86 4229 .........h....)B 803d724: acb4 73c9 f8d8 3abc 8919 44bc 873d 0267 ...s...:...D=.g. 803d734: 9717 fda7 1e49 9ab3 3b64 9e6a b454 38bd ....I...d;j.T..8 803d744: f2a7 9a14 1c28 2451 0620 afda 81e0 762b ....(.Q$ .....+v 803d754: 57a6 dba7 d56a 972b f43d bf01 172d eb8b .W..j.+.=...-... 803d764: 5894 2c3c 4fe1 9021 d00f 4c31 850c 699a .X<,.O!...1L...i 803d774: b570 c1bc 40bf 593e f4bf ca77 432a 0ad3 p....@>Y..w.*C.. 803d784: 5352 df2d e12f 554f 9fe6 eafe f1a7 06af RS-./.OU........ 803d794: b9e9 0c8c ef01 7233 1f33 f9ab 0c0e f7e9 ......3r3....... 803d7a4: 75f3 3876 e2fc f097 f7b3 cfc1 8744 bc0a .uv8........D... 803d7b4: 73f7 a337 ccb2 9940 cd97 6c56 f266 535f .s7...@...Vlf._S 803d7c4: a77a 045a ba50 ba92 520a c1cf c1ce cc25 z.Z.P....R....%. 803d7d4: 0936 c67b 8809 2863 2ff4 c2f2 9bac ff60 6.{...c(./....`. 803d7e4: 9d05 3a52 bdd2 60e4 9a39 c503 3a95 d701 ..R:...`9....:.. 803d7f4: a9a8 b6c7 133e 4e04 5db1 3b09 9f04 6b72 ....>..N.].;..rk 803d804: f6a2 c307 de37 0d5f 065e 16f4 c9fe 5f26 ....7._.^.....&_ 803d814: 5914 7c07 79d7 edbe 6d80 79d9 a7eb bba4 .Y.|.y...m.y.... 803d824: 305b aff8 328f 0cb4 c6d4 0b19 5d97 8dbe [0...2.......].. 803d834: e22f 2523 bb8f 4dfa 0765 9d07 88f0 7801 /.#%...Me......x 803d844: 7151 836f e79d a160 0cca 30d0 3c40 4f0e Qqo...`....0@<.O 803d854: d7a2 19c2 5553 ac24 94fb 5205 b2d0 955c ....SU$....R..\. 803d864: 5b45 1521 14db baa4 488a 7240 da85 b920 E[!......H@r.. . 803d874: 75ee 234a c901 5a15 f725 e262 173e 9d82 .uJ#...Z%.b.>... 803d884: 90c2 c229 1f4d 8a75 515c 24cb 673b 3235 ..).M.u.\Q.$;g52 803d894: 552c f573 35ad a71d df16 f35d db9b 3c74 ,Us..5....]...t< 803d8a4: e6fd 5d36 a0cd 9d4d d987 57ea 59ed cceb ..6]..M....W.Y.. 803d8b4: bf14 5316 5550 be62 237c bfa3 a2ad f3e1 ...SPUb.|#...... 803d8c4: 5677 7d5c aa23 578e 4adf aba3 5b68 1e54 wV\}#..W.J..h[T. 803d8d4: e2f3 79a1 d7a8 6c99 36d0 ea33 bd05 5413 ...y...l.63....T 803d8e4: 1e6c a6c8 6145 5072 79b1 9f70 18a9 f04d l...EarP.yp...M. 803d8f4: 8430 bb61 9c09 b0e2 41e7 9d9a f0f5 1740 0.a......A....@. 803d904: 6e1e 89b9 979b 1864 a0e1 cf27 31e4 93d4 .n....d...'..1.. 803d914: b2b8 afa8 6071 0d7b 13bd 0fb4 eb8b 3628 ....q`{.......(6 803d924: cc50 dfba cc3b b770 cdaa 3185 b9bc 4806 P...;.p....1...H 803d934: 0be7 7a09 da3d ec56 ae32 0ce0 fdc4 b264 ...z=.V.2.....d. 803d944: 5dca fb12 6157 26aa af87 122d a691 8314 .]..Wa.&..-..... 803d954: 0157 60f6 ff60 3751 704d d9e1 09a1 498a W..``.Q7Mp.....I 803d964: de04 cdbb 3acb d0a5 ee12 7ef8 1597 64c2 .....:.....~...d 803d974: 0228 fd4f bec5 81dc 67b7 71db c0bf f08f (.O......g.q.... 803d984: 0cfc 1441 d252 cf52 78ac d3ea 6736 4050 ..A.R.R..x..6gP@ 803d994: 9ed2 30b2 fa35 d44c 24a3 4258 4d33 3dba ...05.L..$XB3M.= 803d9a4: db67 1e56 32d2 7223 68bb a117 8364 38bf g.V..2#r.h..d..8 803d9b4: 4ec1 22ef ae15 1da1 9607 f09c b539 a41e .N."........9... 803d9c4: b4ee d8bd 9d31 83de 8380 05cd 5f3d 73ab ....1.......=_.s 803d9d4: 1694 3ec5 fe81 81d6 c3d0 b90d 8397 0f1b ...>............ 803d9e4: 69b6 eb3b 40d4 ccda 500b c5b2 615b aa29 .i;..@...P..[a). 803d9f4: 71cc a9cf ce1e 8a20 382d 0d65 d913 6bdf .q.... .-8e....k 803da04: a4f2 0267 bc5a af66 ef37 2ef3 c4a1 6e97 ..g.Z.f.7......n 803da14: a483 3874 5707 b830 286a 392b 3c5c d626 ..t8.W0.j(+9\<&. 803da24: c411 5da3 f046 913b d4d4 afe0 66a3 019c ...]F.;......f.. 803da34: 1b8a 38f0 c968 0509 d066 a26c 054c e1e5 ...8h...f.l.L... 803da44: 8f75 cbb6 af82 ce83 e521 5e0b 848c 6be8 u.......!..^...k 803da54: 5321 e696 7d8d 8641 cb9d 306d 74f3 2ae4 !S...}A...m0.t.* 803da64: fdff 4dfe 4cc4 3dcf d482 6dd1 661b 18ae ...M.L.=...m.f.. 803da74: e98d bad4 a8c5 54e5 e81b 0456 ff9a 19ea .......T..V..... 803da84: 5325 f508 846d 7a08 de18 f5b1 88ee fee3 %S..m..z........ 803da94: 3936 49a6 8857 d6f0 c14e 61b2 a98e 0b62 69.IW...N..a..b. 803daa4: 2119 2da8 442a 110b b660 ed7d 85f8 ac15 .!.-*D..`.}..... 803dab4: 84fd 60f5 e0d8 3505 04dc c34e 31dc 36c2 ...`...5..N..1.6 803dac4: 87e8 b619 bfe7 9a9a 25f3 f2e2 b1ae c4da .........%...... 803dad4: 4576 33de ad4b 5661 412c 4432 aa9d 89e4 vE.3K.aV,A2D.... 803dae4: 2a38 aec5 ee49 9a36 3ba8 472c 3151 d237 8*..I.6..;,GQ17. 803daf4: f522 30cb 8ea5 96f4 4556 7956 09a9 ea4a "..0....VEVy..J. 803db04: aa94 aa7d 2f42 4d8c 5596 f059 eff2 ae07 ..}.B/.M.UY..... 803db14: e7f4 f585 90bc fb6a aa88 9437 970c 8843 ......j...7...C. 803db24: 7332 257a f11f f856 fb20 31e1 9ac2 128b 2sz%..V. ..1.... 803db34: 0daf f5b7 eeb0 68f1 9959 bd93 6808 2781 .......hY....h.' 803db44: abd1 286a 4149 7931 4e12 cb9e f566 f006 ..j(IA1y.N..f... 803db54: 5931 bada 0b25 f1f5 e8a5 fa76 abb0 9cf7 1Y..%.....v..... 803db64: a6eb 7b05 12a0 2d36 e944 78a9 16c8 b683 ...{..6-D..x.... 803db74: ddcc 0972 cc5e 00ee 8c35 8483 16fd 60eb ..r.^...5......` 803db84: e0a1 b342 ecbd b155 666e 0953 c4b6 eb61 ..B...U.nfS...a. 803db94: dd0f 9d1f b45b 79c4 785e dfa0 29b4 11c0 ....[..y^x...).. 803dba4: 5c88 5582 0428 a08c 42b4 2264 9fc5 60ea .\.U(....Bd"...` 803dbb4: 11d1 5d60 ec41 6242 ce2b 8b38 8722 fb3b ..`]A.Bb+.8.".;. 803dbc4: 4fec 217d 03a4 7961 6e4d 1ab5 e928 bba3 .O}!..ayMn..(... 803dbd4: ddc9 3dcd 0ab8 8405 7c76 b5ca c977 27b6 ...=....v|..w..' 803dbe4: 19ac b06a a360 8212 651b d499 5b8d fe32 ..j.`....e...[2. 803dbf4: 550a b27e c829 8c41 1c22 1fe0 f53e cfc1 .U~.).A."...>... 803dc04: e105 c876 43c5 09f6 5620 835b f427 40c6 ..v..C.. V[.'..@ 803dc14: 8f1d 1ca3 4eff b314 1bd0 f975 63bf 3bb3 .....N....u..c.; 803dc24: 66e8 d938 a2c5 1a5d 708c 8de8 8224 7261 .f8...]..p..$.ar 803dc34: 46f7 8fea 6525 410c 0c8a d269 090c 4f67 .F..%e.A..i...gO 803dc44: 8516 a4d1 813f 1c0a e862 0262 1590 a846 ....?...b.b...F. 803dc54: dc4a abdf a0be 5132 64e2 07cc 694a 80b4 J.....2Q.d..Ji.. 803dc64: 47bf 3e51 87aa 27c5 1449 c040 e3b0 bc48 .GQ>...'I.@...H. 803dc74: bbf8 cac2 eaf5 2ba7 e20c 15ee 7540 9d80 .......+....@u.. 803dc84: 7fa0 4283 bbad 03ba 60fc 2817 6735 e8c6 ...B.....`.(5g.. 803dc94: f754 2912 b724 997c 7aaf 71d8 5e10 c9bd T..)$.|..z.q.^.. 803dca4: c5b6 05ee b883 2dcb 1b6c e536 a184 6e7c .......-l.6...|n 803dcb4: fa79 6102 10c0 8c0a 3361 0f24 ca1c 4891 y..a....a3$....H 803dcc4: f43d 896a 0271 c444 1392 50dc 55ec f4e3 =.j.q.D....P.U.. 803dcd4: 326a 8099 67b7 5e06 0ccd de36 9950 e3b1 j2...g.^..6.P... 803dce4: ccdb 2ae4 9302 f537 4a51 3175 fc3e 5d6c ...*..7.QJu1>.l] 803dcf4: d575 db96 97f5 840e 6f8f a3ab c2ec c44b u........o....K. 803dd04: d3ee 9acb 91b6 89c1 3f0a 6e83 0539 9395 .........?.n9... 803dd14: dece f4ce 16ee fc36 dbd4 d16b f669 87e1 ......6...k.i... 803dd24: b27b d918 53eb 7d86 ee08 c94d 0d89 d678 {....S.}..M...x. 803dd34: dfdd 24f3 ba3c 7ed8 9bb7 2bac 3051 dc32 ...$<..~...+Q02. 803dd44: 140a 8443 0f9d c603 6e93 ca1f b59e b11f ..C......n...... 803dd54: 17b4 946d 0def 8604 0dfb 1863 b052 8cff ..m.......c.R... 803dd64: 1301 0dbc 18ed 2ebb 4b58 5872 6a94 8a5a ........XKrX.jZ. 803dd74: c1b6 29d1 4ff2 de7a e7a1 9d60 e2db 960e ...).Oz...`..... 803dd84: ac4e 20c8 1ec8 0830 d191 bd89 046e 79e4 N.. ..0.....n..y 803dd94: 4a7e b0d5 98c2 0468 43c1 8210 9913 0f54 ~J....h..C....T. 803dda4: 1871 ed84 885e 568d 884d 882a 8061 4197 q...^..VM.*.a..A 803ddb4: c6e9 6850 ae93 0641 afb6 3bf2 53fc 1bc5 ..Ph..A....;.S.. 803ddc4: 1dc4 b8f0 c3ad 054a 70b1 b5d3 03b0 ecde ......J..p...... 803ddd4: 98b9 86fb 4336 5099 d3a1 ccbd 10d4 ae5c ....6C.P......\. 803dde4: 0da8 143a ce37 4167 14c8 030e ed46 1409 ..:.7.gA....F... 803ddf4: 0b36 7cc3 b78d c1f7 51a5 3fbe 92aa 4eac 6..|.....Q.?...N 803de04: 89ca 99cf eb50 a514 6f5a 9294 6deb 7271 ....P...Zo...mqr 803de14: 04dc 32a7 8864 13ce 7f68 210b 478e 231d ...2d...h..!.G.# 803de24: 2223 0e58 84bb 6027 c682 d3a3 0131 3206 #"X...'`....1..2 803de34: c21e 7cf2 2670 1728 9f9c 4a09 3907 1d41 ...|p&(....J.9A. 803de44: 6039 9413 b496 5ca0 e47c a826 6710 3506 9`.....\|.&..g.5 803de54: 63e3 4139 38cd d6d3 05b4 7a5d cbb9 deb7 .c9A.8....]z.... 803de64: 2853 c1fe f9f4 96a2 7aa2 a8ea 48b9 b1c0 S(.......z...H.. 803de74: bf6e a0b9 ab30 48ad 9ecc b2b6 4331 31ac n...0..H....1C.1 803de84: 54fb f9e0 8e24 474f f41b 7443 c972 6a18 .T..$.OG..Ctr..j 803de94: 383d f536 872c 6494 92ef c426 4e60 b083 =86.,..d..&.`N.. 803dea4: 45bc 09fe b28e 8ef1 4eb8 7e6d 337b 85cc .E.......Nm~{3.. 803deb4: 20f8 6e88 e6ba 886c 8686 581d 3bb2 a03a . .n..l....X.;:. 803dec4: b736 038b 4a38 c972 10d4 0c5c 13fc bb18 6...8Jr...\..... 803ded4: 15e2 7ee2 50e9 74d8 b308 e827 5022 7651 ...~.P.t..'."PQv 803dee4: f059 d300 19ea 1425 3784 8461 9827 2f64 Y.....%..7a.'.d/ 803def4: b478 634a c7f1 9530 cb79 734f 8a29 a6af x.Jc..0.y.Os)... 803df04: 7198 5fff a706 2f5f d774 2cd9 a7b7 fa66 .q._.._/t..,..f. 803df14: a00f c2e4 3460 833e a6a4 b042 cc0f 0196 ....`4>...B..... 803df24: b8db 116a 7fcb 6227 44de 1e73 b9ae 62dc ..j...'b.Ds....b 803df34: ebc5 21ca 1760 1504 fa8d 0993 0260 9eab ...!`.......`... 803df44: 39fa 3133 ad5a 3b35 cf9f ba75 e3c0 7e57 .931Z.5;..u...W~ 803df54: d132 99c5 fe9f e5d9 5c67 8a6e 4d4e c2dc 2.......g\n.NM.. 803df64: c428 58fe a1f0 6768 f0f9 2014 8001 58ad (..X..hg... ...X 803df74: 80b7 053e c5d7 0f07 96eb 925e 4ad9 cdcb ..>.......^..J.. 803df84: cdcd 5a79 9160 2122 c823 3505 e9e8 59b4 ..yZ`."!#..5...Y 803df94: 872a 4e5c 1a89 64ba 644c d5b9 1001 b2a8 *.\N...dLd...... 803dfa4: 766e 0a71 1108 3aaa b31c 6e8a 1b0f 3ab3 nvq....:...n...: 803dfb4: 83b8 1f1d f6a8 c50d 574f 300b 169c 5dbf ........OW.0...] 803dfc4: 6ec1 094f 3fc7 1acd ccc1 34a6 f117 c7cc .nO..?.....4.... 803dfd4: 8db3 9b1c f580 2e3f e0e6 a05f e92c 056c ......?..._.,.l. 803dfe4: 24a5 924b 917e 7f1c b16c 2eb3 103a 6857 .$K.~...l...:.Wh 803dff4: a542 5171 3da8 318d 35c1 1d69 6ff6 3841 B.qQ.=.1.5i..oA8 803e004: 3ffe ad5e 87d4 dd8c 53be 7199 217b 3dc8 .?^......S.q{!.= 803e014: 356f 4ff0 f3eb 2b04 7aac ac6b 6bc7 0cb6 o5.O...+.zk..k.. 803e024: 0fbc 3632 2e3c a102 61fb 176e 442c 15a3 ..26<....an.,D.. 803e034: c201 de28 bb47 d00e 8af0 3be7 a920 8d71 ..(.G......; .q. 803e044: 28ae 2d5a adb8 1d01 e271 0a0c d333 6b02 .(Z-....q...3..k 803e054: c738 349c 139b 4ac2 1293 0110 692c 1dad 8..4...J....,i.. 803e064: 8e14 5a18 2b6f 6d28 e3f8 b23b c75e c272 ...Zo+(m..;.^.r. 803e074: 4a6e 9f39 30ae c822 7c33 bde8 481e 825a nJ9..0".3|...HZ. 803e084: 5db6 d74f e3db 8f14 3311 ae28 417d 2a3d .]O......3(.}A=* 803e094: b172 9088 9b84 b85e e1ae 06d1 e20f 3f63 r.....^.......c? 803e0a4: 8a32 07af 9865 516a 85e2 7b18 1270 cf46 2...e.jQ...{p.F. 803e0b4: 4b9e 068a 03e6 4c47 d8a6 f583 5314 7f9c .K....GL.....S.. 803e0c4: f51e 2e60 bc1f 54ed 62ab a8fb aa69 a9bc ..`....T.b..i... 803e0d4: 9055 8863 22b0 1d9f 147b cfd1 2524 1a21 U.c.."..{...$%!. 803e0e4: 0970 7d4a a3da c1a8 1708 738f 4278 5c80 p.J}.......sxB.\ 803e0f4: 58aa 1cd6 17ae 1dc4 0356 8ce7 cc49 7808 .X......V...I..x 803e104: 04d8 e717 0276 8e19 90c2 9d01 9a6c 32ca ....v.......l..2 803e114: f577 2680 c1f5 fd7b 00fa 1097 9870 4f84 w..&..{.....p..O 803e124: d9a2 a201 e8f5 67d0 ff2f 5604 01de 167a .......g/..V..z. 803e134: ecd6 44e2 4102 5880 3864 0dcb e3a1 62cb ...D.A.Xd8.....b 803e144: 7b0d d3dd bd6c 655b c56f f6cf 5bcb 5040 .{..l.[eo....[@P 803e154: 6b19 2288 f118 fab7 fae6 10b7 8915 2f42 .k."..........B/ 803e164: 9d6b b8a3 cf4e 2f1a 0e52 fa66 bea0 b965 k...N../R.f...e. 803e174: 34c2 a2c2 6e49 6159 369a e412 c98a b1e2 .4..InYa.6...... 803e184: 1579 1170 f9da fe2d 7ea9 cc14 05b3 85fe y.p...-..~...... 803e194: 6bc8 f0ff d188 9fe5 26a6 7369 5e99 1518 .k.......&is.^.. 803e1a4: befb a5e6 f5a8 6d99 cd15 59e2 f1b0 1302 .......m...Y.... 803e1b4: e920 5393 9a58 7adc 3e6b 8533 c9a7 ad6d ..SX..zk>3...m. 803e1c4: 98ca 8836 72b5 49a4 35ec 715f 033f 0446 ..6..r.I.5_q?.F. 803e1d4: 4cea a529 5ce6 2631 5ceb a229 2ecf 44f4 .L)..\1&.\)....D 803e1e4: 8c8c df3d 2430 8de2 f420 39ff a07f 0b2e ..=.0$.. ..9.... 803e1f4: 6554 64f5 ab59 90e3 27c0 e34a aac1 a048 Te.dY....'J...H. 803e204: 0bc7 6d3e 4385 c5aa 60bb 6347 e1ca 69a0 ..>m.C...`Gc...i 803e214: b7a6 e935 68ec 8294 c8ed 608f 6630 9cb0 ..5..h.....`0f.. 803e224: 5720 d2be fa3f cdd5 3dfd aa78 f22d 7c3a W..?....=x.-.:| 803e234: d058 b605 371b 2b2a 2ac9 2209 455d 8b95 X....7*+.*."]E.. 803e244: 4564 84ab 16e2 9279 b009 a3f1 21a3 8539 dE....y......!9. 803e254: afa5 4094 67d3 f0a6 b934 fef5 9931 a3ed ...@.g..4...1... 803e264: 0851 1c6b 4a8d 4cb8 4d9f 4343 b58b 200f Q.k..J.L.MCC... 803e274: a529 9cd4 2601 3ffc aa57 3469 b9ca 50bc )....&.?W.i4...P 803e284: 12b6 2303 931a ad5a d036 f860 3205 2709 ...#..Z.6.`..2.' 803e294: 70b6 329b 47f7 691c d5d0 7407 5562 ea23 .p.2.G.i...tbU#. 803e2a4: 8121 838d 929a 9f16 ef59 9771 dca7 32b5 !.......Y.q....2 803e2b4: 33ed 2adb 3a5e 1da6 3fb4 e0cc e076 495a .3.*^:...?..v.ZI 803e2c4: 6476 1b35 2200 0e5e 559e c6d1 9717 8c64 vd5.."^..U....d. 803e2d4: 0953 e0c1 a075 765c 8e2b 54be 9b0b 215d S...u.\v+..T..]! 803e2e4: 9147 7451 06f5 5a13 5128 ba48 052e abc9 G.Qt...Z(QH..... 803e2f4: 3482 3e69 95bf 5336 85ac 5f38 95aa 533a .4i>..6S..8_..:S 803e304: 32ec 1760 3129 97c7 da73 15cc 8a54 e8cf .2`.)1..s...T... 803e314: 5f18 b19e b4bd f2b8 e2e0 dff2 fe08 aa7f ._.............. 803e324: 1cfa df5d 03ac 7763 6aba c982 cb3c e027 ..]...cw.j..<.'. 803e334: 8bf0 67b5 0eb3 1ae4 59ac a863 3dda 6234 ...g.....Yc..=4b 803e344: 996b 7246 3ce2 7c65 a2b2 511d 8ab5 7567 k.Fr.........~.}... 803e3e4: 091a da90 3431 8356 ecc6 0ad0 9432 f5d9 ....14V.....2... 803e3f4: 762a 8508 ce55 9d6a b8a0 99d2 3956 e1e3 *v..U.j.....V9.. 803e404: b06c ada8 6ea9 b21f b899 0267 6e58 f2e8 l....n....g.Xn.. 803e414: 4ca0 b5e7 2170 69a5 40d2 f99a 70e2 6468 .L..p!.i.@...phd 803e424: 2f90 1461 d04c 1f8c 09c9 7c42 3366 a625 ./a.L.....B|f3%. 803e434: 518c 0d05 346d e2d3 34c1 6312 b48a 93ab .Q..m4...4.c.... 803e444: f1a0 5d46 9412 fa52 469a 587a 5db8 048b ..F]..R..FzX.].. 803e454: 9565 8be2 9f00 1fd1 e021 e546 9b31 160f e.......!.F.1... 803e464: a2ee 5506 4d1e 3503 1cd6 b952 7359 9bc4 ...U.M.5..R.Ys.. 803e474: 3afc f2a8 1b3c c18d 1841 6cd7 60b6 06b8 .:..<...A..l.`.. 803e484: 8f2b aa18 07f6 8329 a65a b411 4f38 9df9 +.....).Z...8O.. 803e494: 68ac ab45 f156 2eac 6b89 e528 7569 cf92 .hE.V....k(.iu.. 803e4a4: ee1f 1a86 a6a6 9a2e cdc5 cdfd c390 7a6a ..............jz 803e4b4: 3831 5637 2079 6636 b3b7 a526 1a57 b541 187Vy 6f..&.W.A. 803e4c4: cb32 d3e1 35c6 c85f 9828 3db8 703f a4d3 2....5_.(..=?p.. 803e4d4: fcf9 da56 b14c 0116 a5f0 a95a c533 032e ..V.L.....Z.3... 803e4e4: aed6 6272 1b92 4eb5 505c 6e29 0fd2 f2b5 ..rb...N\P)n.... 803e4f4: baed 2e27 3cae 14b8 19fc 540d df03 84a4 ..'..<.....T.... 803e504: 8396 316c 9589 db50 8f80 90f4 8fd6 89b5 ..l1..P......... 803e514: 60b7 a0a2 1d33 8b8c 78c9 fe39 1b26 6b86 .`..3....x9.&..k 803e524: 1ab0 808a e76a 3290 f389 d88c 5944 f4ca ....j..2....DY.. 803e534: 3554 983b 6ae2 3567 5450 6941 2b4e f9a0 T5;..jg5PTAiN+.. 803e544: 78c3 8a30 c88d 3e6c 187a 76e9 1455 a7d2 .x0...l>z..vU... 803e554: 83aa 6907 96d4 e81b 3cad 1051 c8d6 026b ...i..... 803e634: a6ed be78 a05b dedc c2de 2101 4ab9 835a ..x.[......!.JZ. 803e644: a8d0 0410 c04a a8b1 6ae1 e458 d436 1fd2 ....J....jX.6... 803e654: 81af 4283 5e28 c714 aac5 0c2c f743 1457 ...B(^....,.C.W. 803e664: b3e9 8f08 8ba0 a5e9 1b05 9fe9 d4be c0cd ................ 803e674: e30e 4dd2 f54b 1f30 621f 6894 8a3c 63b8 ...MK.0..b.h<..c 803e684: 61c4 55d4 77db 2ff8 d803 d627 a3a8 4e2c .a.U.w./..'...,N 803e694: d64d 5932 ba89 3f1e acaa e9a7 c8e8 0f72 M.2Y...?......r. 803e6a4: 1b42 6a99 2b89 730c 3ba9 df90 6b92 b788 B..j.+.s.;...k.. 803e6b4: b629 9751 e26e 0310 0ea0 8fa6 b3c5 6ba1 ).Q.n..........k 803e6c4: 2386 7678 e351 6d58 0091 9c1c 70ba 5102 .#xvQ.Xm.....p.Q 803e6d4: 73bb 1822 d4d5 051e d781 f9ca 1e48 8d03 .s".........H... 803e6e4: 7d88 c717 3956 e571 35e3 6f78 44a0 5251 .}..V9q..5xo.DQR 803e6f4: 2e0c 8dde c318 ade8 cf9f a181 cbe0 0e00 ................ 803e704: 18a6 0d40 2778 de34 58b9 d822 772c 9557 ..@.x'4..X".,wW. 803e714: 2b9c 167b e201 aa3d 6389 9302 b054 8190 .+{...=..c..T... 803e724: 3bd8 8c6c 1d3c ca36 3c59 4d10 7697 51f2 .;l.<.6.Y<.M.v.Q 803e734: ba4c 3889 9c11 3cea 4154 1a08 628b 8e18 L..8....7. v.C.).8 803e764: fe11 70dc 14fc a9af a9ff b57c cd9a f49d ...p......|..... 803e774: 576a 2a57 121a 4ccf 4863 f1a0 01a3 a616 jWW*...LcH...... 803e784: 3c2a 56be e299 e994 9b9a e0fe 1f16 d079 *<.V..........y. 803e794: e858 807c 097f 95ec 2059 1dca 14b8 32cd X.|.....Y .....2 803e7a4: 2f0b 1664 7e25 8c2e 8e3b 4f64 8808 1f8a ./d.%~..;.dO.... 803e7b4: 4af6 c632 213a 4daa 5d65 319f 783f 3c5a .J2.:!.Me].1?xZ< 803e7c4: 9b86 b7f7 d9b7 7f32 70d0 b840 e838 703b ......2..p@.8.;p 803e7d4: c2ea d9e9 720e e286 e0f9 4538 7877 d377 .....r....8Ewxw. 803e7e4: 8d1d ddc7 6dfe 0d70 39d0 5ae2 4501 f8d4 .....mp..9.Z.E.. 803e7f4: dd49 496c f1c3 01bf b9fe b1b2 3ab4 72d9 I.lI.........:.r 803e804: 08a7 c943 e390 20b7 1ac7 0fe0 993f 7063 ..C.... ....?.cp 803e814: 6e8f 564a f5bc 8d05 09f3 e8f9 2a54 2c1d .nJV........T*., 803e824: 0f33 b8a0 be69 1643 9c02 90a3 1f69 0eb6 3...i.C.....i... 803e834: 5ad1 f6e8 f871 9a96 1f4b 5592 3333 1075 .Z..q...K..U33u. 803e844: ccd0 b745 453a 878d 3ef7 c679 bbc8 ba1a ..E.:E...>y..... 803e854: fb28 0ef0 c52e e3f5 993a 454b cc12 00d6 (.......:.KE.... 803e864: ba4a 5050 1cdf c642 0277 bf98 d1d9 31f7 J.PP..B.w......1 803e874: 70c5 6538 0ca7 37c7 1448 a808 9e17 3c52 .p8e...7H.....R< 803e884: 08de 48f7 4ad4 8c1a 5f87 8be3 f531 359e ...H.J..._..1..5 803e894: 23b7 41ca 1d4d 74c5 43c4 a80d 0dfe 851c .#.AM..t.C...... 803e8a4: 6539 b6a8 548f d8c5 64a0 bdc7 e787 f276 9e...T...d....v. 803e8b4: ca5f 23e3 10fa be88 821e e3c7 3ae0 ba0f _..#.........:.. 803e8c4: 8b91 0e1f 13a2 8f83 482c 0193 b610 d381 ........,H...... 803e8d4: fc42 8439 87e7 baf0 ac7b b781 3849 d05e B.9.....{...I8^. 803e8e4: e0b4 45df e9d2 2e93 b64b 5677 0559 8722 ...E....K.wVY.". 803e8f4: bd27 a9fc 9123 fc96 427e df4b 8e31 ed87 '...#...~BK.1... 803e904: a3c3 f67d a741 8fb0 eaf4 7d46 c6f2 c050 ..}.A.....F}..P. 803e914: 19cf b380 1e41 f82d db3f 61d9 f8f7 23c3 ....A.-.?..a...# 803e924: f5bd ac52 78f1 bcba e393 5dcf ad88 6782 ..R..x.....]...g 803e934: e1ee 7ea2 2c6f 0240 0e5d 786d 2be5 61c1 ...~o,@.].mx.+.a 803e944: c70d 1e2d ee26 eeb8 cf18 02bc e147 d4bc ..-.&.......G... 803e954: cf81 a474 b1ba 7dee e1d6 c32a b51b 9ca8 ..t....}..*..... 803e964: 11af aad6 f8b8 c39b dddc 3d0d c34a 035b ...........=J.[. 803e974: 5b18 fd94 2747 6e82 c2e2 10c9 c6e0 4e08 .[..G'.n.......N 803e984: 3cd1 fc30 ac26 c8a7 1333 74fa 8b7f b57f .<0.&...3..t.... 803e994: 4daa 5ccb f5e8 acb8 312c 3eff 259b 341b .M.\....,1.>.%.4 803e9a4: 51d9 6dd3 5af1 581a d328 e1ae a5da e772 .Q.m.Z.X(.....r. 803e9b4: 6e3a 67a8 2ecd c238 be37 0983 8e5e e1e1 :n.g..8.7...^... 803e9c4: a50d 11e1 5bbe a9be cbd4 9381 1a15 46c1 .....[.........F 803e9d4: 5d60 5b06 d202 34f7 42fe 8955 ac1d 1563 `].[...4.BU...c. 803e9e4: b747 4a91 1f30 4354 9605 fdc6 8de8 a439 G..J0.TC......9. 803e9f4: 4cd7 0d5c 397d 7f7a c385 df08 eaf6 c20a .L\.}9z......... 803ea04: bb51 707f 5cf2 ac83 ecf8 f6a1 cb93 2b33 Q..p.\........3+ 803ea14: 5d2d 4865 d3df 137c 8aa8 2d64 68b2 3b03 -]eH..|...d-.h.; 803ea24: 8c71 4257 e8e8 a672 70ad 8e18 bdd4 70f1 q.WB..r..p.....p 803ea34: b2b8 fe67 f4a3 8e12 6a2c ec3f ba35 c897 ..g.....,j?.5... 803ea44: eea0 4b57 a532 f3d1 7477 54c8 347a abba ..WK2...wt.Tz4.. 803ea54: 8de2 c036 0f13 955a ddd0 04df 8f11 ea0c ..6...Z......... 803ea64: 82e4 cdef a539 2241 0495 7015 d467 c7bf ....9.A"...pg... 803ea74: 9123 f34c fc64 1106 2f38 8e6f 689f 0d88 #.L.d...8/o..h.. 803ea84: 0ea8 c4bd 3223 e465 c8d7 4028 9dae 0dbd ....#2e...(@.... 803ea94: 76d3 8d70 67f2 f070 107c f700 8137 bf8c .vp..gp.|...7... 803eaa4: afac 813e 2cd8 c0e8 5c2c f2d3 c6ea 0d17 ..>..,..,\...... 803eab4: ed29 d263 d496 7eeb 9aba b592 1a38 74df ).c....~....8..t 803eac4: 1f6f fff0 7bfd 15b4 cba3 a327 c332 356b o....{....'.2.k5 803ead4: 51b5 81dd 1927 1f1e 0252 1055 9f03 1186 .Q..'...R.U..... 803eae4: c51c 1dc5 33ec fe07 86d1 d347 3bcb dc6a .....3....G..;j. 803eaf4: f755 4de7 ef7b f419 9101 4a75 ecae 4da1 U..M{.....uJ...M 803eb04: 8039 3df7 36c6 ae40 55ad 0951 3fe3 3cf6 9..=.6@..UQ..?.< 803eb14: 1e0d 0cc8 f439 debf b7fe 0ddd 808f b3e1 ....9........... 803eb24: e079 9ac5 abe7 0d72 42ae 4230 cae8 87ce y.....r..B0B.... 803eb34: 5807 c8ce 38d5 88c3 7803 9372 309d 8ae9 .X...8...xr..0.. 803eb44: 7151 a4f3 1c1a 6f50 ac68 0756 c8da c15f Qq....Poh.V..._. 803eb54: 5bbc 5b18 6c59 e333 551d 0109 d633 f5d2 .[.[Yl3..U..3... 803eb64: c41e de58 0ba1 e1d3 bfa5 ce05 e993 4db3 ..X............M 803eb74: 4416 d9bd b82b a418 2789 c1a6 5b94 0034 .D..+....'...[4. 803eb84: 3f5c 7529 5542 af8a 0610 eac8 75b1 115a \?)uBU.......uZ. 803eb94: 3e80 dc49 ae32 4ccb 8e34 4713 07e9 c7d7 .>I.2..L4..G.... 803eba4: 0f50 8681 6781 373e 0f79 86de d6cd 821f P....g>7y....... 803ebb4: bae6 5161 d978 5ab0 96b5 6040 05ad a5b0 ..aQx..Z..@`.... 803ebc4: 00b0 83a2 b3ff 625a 278c bdf5 56d7 6dd6 ......Zb.'...V.m 803ebd4: 257e cce2 5540 6c4d 9873 0c19 a2f5 384e ~%..@UMls.....N8 803ebe4: 506a dda1 96e1 c184 9022 ec3f 02dd dd34 jP......".?...4. 803ebf4: c2f9 9746 9aeb ee12 d052 b29f b486 5f1a ..F.....R......_ 803ec04: a0b3 af14 0d39 4a04 8cd0 5d44 f7ce bad4 ....9..J..D].... 803ec14: b515 0fa1 f418 0f0f 204a 577b 9443 39df ........J {WC..9 803ec24: 04ec 7783 c88c 00d1 17c1 3cbd 0447 2913 ...w.........jv.V.z......1 803ecb4: 2449 0644 00f8 5b8c f874 66fc 6a87 6fe8 I$D....[t..f.j.o 803ecc4: bec1 82ea f84d adb2 e816 a8da 21af 6ed5 ....M........!.n 803ecd4: 57c1 52ca 588b ef38 16e6 b4e8 550c 436d .W.R.X8......UmC 803ece4: 9816 16b1 1d9a 5701 81aa 25f7 7c9c 2be5 .......W...%.|.+ 803ecf4: e0d8 abca 2ab2 5f96 a8c8 984b ec51 b0e6 .....*._..K.Q... 803ed04: adbe f09b 0a45 c979 6982 e1eb 4a05 00c7 ....E.y..i...J.. 803ed14: 4733 3c29 0979 6e47 6fd9 9ecc b11d d17d 3G)..D 803ed34: 7150 4b88 6508 f92a ec03 86ea 9b5a db58 Pq.K.e*.....Z.X. 803ed44: 389c e6a7 9a27 e288 900a 1360 790f eb54 .8..'.....`..yT. 803ed54: fabe 89e2 c3c0 7f95 f3d2 d8e0 f020 c5cc ............ ... 803ed64: 5d31 e788 c201 262d f56c 42e2 5a48 20e5 1]....-&l..BHZ. 803ed74: 6c5d e309 5030 d046 ef06 bd5e f0ec 8cc6 ]l..0PF...^..... 803ed84: 83bf bdf7 48e0 1eb7 a738 01cd c8a9 772b .....H..8.....+w 803ed94: 6eb8 f7c6 4b1d e09f 7700 f06e 38cd 1af0 .n...K...wn..8.. 803eda4: ebb5 b0ea 825f 46f2 e0e0 beb2 5b87 7e6b ...._..F.....[k~ 803edb4: c15f 961b 0cf0 f562 5ca9 c357 fdae 051a _.....b..\W..... 803edc4: e35f 6be0 3f12 3e5f 5e8c 872f e657 26c1 _..k.?_>.^/.W..& 803edd4: bb40 2643 6501 0e9f 5a04 3047 ef2f 5af0 @.C&.e...ZG0/..Z 803ede4: 5f45 4ec1 6e6d d2e1 286d 1760 d881 663d E_.Nmn..m(`...=f 803edf4: d459 b378 be90 a5d6 0a57 2d1d de6c 35ef Y.x.....W..-l..5 803ee04: 2543 f71c 8b34 01fd c570 e151 8d71 0b94 C%..4...p.Q.q... 803ee14: 1419 28ca e3ba 8587 ddcb d162 2ec4 367d ...(......b...}6 803ee24: a0d9 c16f b3c0 9f8f 0f7b e803 7d11 ecaf ..o.....{....}.. 803ee34: 5d81 7099 78f9 5cf9 4f4a d2a9 4783 e3dc .].p.x.\JO...G.. 803ee44: 86eb cdf0 6b36 f53b 1e1f addc 6f84 ce37 ....6k;......o7. 803ee54: fa43 0f70 0fe6 a35c d7c4 e91f 4705 a776 C.p...\......Gv. 803ee64: af13 6fbf 95cb 0aab bed4 c88c 4797 693d ...o.........G=i 803ee74: 39c0 c89e 7400 60df e1d3 9a85 8668 e6f7 .9...t.`....h... 803ee84: 62eb b1fe 8e8b ceec 8925 517a f042 b4c4 .b......%.zQB... 803ee94: 9a0e fdc1 78af 296b 30f2 fb6b 4132 e82c .....xk).0k.2A,. 803eea4: 3af9 d05a 415d b815 b222 91d8 7616 d31a .:Z.]A.."....v.. 803eeb4: 5a99 8b5e a2dc a1ed 337d c3ba 42b9 8ffb .Z^.....}3...B.. 803eec4: c264 4eab 22bd add1 1b22 05e7 3cbf 4bf5 d..N.".."....<.K 803eed4: e05c 6ec7 902a 2911 20a3 5790 5e51 9cbc \..n*..). .WQ^.. 803eee4: 45c7 a3b0 0fa7 5f2a 0705 3fb5 54f9 2e7d .E....*_...?.T}. 803eef4: 6039 df34 5418 8dc2 733e 0b4b 0020 b836 9`4..T..>sK. .6. 803ef04: 1f34 68ab 552e e10f 3bf3 470b 1265 4d7a 4..h.U...;.Ge.zM 803ef14: dbcc b0aa 1611 07b9 033c 9f9d 6efd 7f09 ........<....n.. 803ef24: e751 7f19 3e68 3fc3 47cd 856b 201f 0410 Q...h>.?.Gk.. .. 803ef34: 71c9 b701 3850 1e14 0504 82c7 7ea7 07b6 .q..P8.......~.. 803ef44: 0b1d c28f 00b0 b7c8 dcf8 d2eb d3a0 2f2b ..............+/ 803ef54: 7833 0f24 0274 d775 f0b6 b932 12be 8795 3x$.t.u...2..... 803ef64: 6899 3922 1d5d e556 b867 0999 92de 7b97 .h"9].V.g......{ 803ef74: 1596 b5b8 63a7 8f4c da32 8944 2f00 12e2 .....cL.2.D../.. 803ef84: 7ef1 0fc1 1eca 3bd5 8aa6 70f4 b540 45e3 .~.....;...p@..E 803ef94: bb1f 21b4 248b 21a7 e40f c824 af01 7f81 ...!.$.!..$..... 803efa4: 596f 8d19 2992 80a5 7a24 a425 0437 e06a oY...)..$z%.7.j. 803efb4: 3235 d478 e473 7626 6f0e 2ce0 1d21 aa6a 52x.s.&v.o.,!.j. 803efc4: a07c a223 6a96 162d f1be 3d04 a25e 6538 |.#..j-....=^.8e 803efd4: 089b 025c c42a 111e 9ce1 83a0 c8c8 e2f4 ..\.*........... 803efe4: bb65 9ade 0db9 b1b5 cb09 23ad 37b4 abc5 e..........#.7.. 803eff4: 0550 69a8 7306 4a02 5ea9 5682 de9b 2d40 P..i.s.J.^.V..@- 803f004: af42 6ad3 0911 a5a9 cb91 2138 aa46 f1d3 B..j......8!F... 803f014: 33ea 8045 1f37 9788 e869 38cc 55ed 0d4f .3E.7...i..8.UO. 803f024: 8a51 8724 34ec 40ed 4559 9b56 6066 b6da Q.$..4.@YEV.f`.. 803f034: e8e9 2320 dea2 6af7 8b80 8a90 1918 4b76 .. #...j......vK 803f044: a007 c07f 90c8 698e 0a49 e35a 67f0 1c15 .......iI.Z..g.. 803f054: 6fac 4589 890a d2c1 4289 e7ad c043 a8d4 .o.E.....B..C... 803f064: e21d 71a8 49af 9359 48dc c1aa 0843 2c65 ...q.IY..H..C.e, 803f074: bf98 b432 950c 3d2c ed2d e393 1557 ad22 ..2...,=-...W.". 803f084: 82f8 9a65 1053 7c4f 73ff a990 a97e ac31 ..e.S.O|.s..~.1. 803f094: 8cca 538a 21cf 67df dbae b2d9 fbc3 33ad ...S.!.g.......3 803f0a4: 00b6 6d09 773f 7b87 caaf 760f 492f 173a ...m?w.{...v/I:. 803f0b4: 1ba6 2f61 b1c9 6e9b 57a7 5c7a b42f 3858 ..a/...n.Wz\/.X8 803f0c4: 0864 0561 a461 6094 8782 3bf1 f788 84a2 d.a.a..`...;.... 803f0d4: 00b8 1207 5cb7 8a05 94b5 2147 3a7e 9202 .....\....G!~:.. 803f0e4: 7247 62ff 7f88 a82d d43a af9a a01f cda6 Gr.b..-.:....... 803f0f4: ebd4 ec3d 2e06 4d4c 32e4 38e5 ac39 56e2 ..=...LM.2.89..V 803f104: 75fd 68f6 1061 bd0c 8b91 c53a 7155 5158 .u.ha.....:.UqXQ 803f114: 9f90 6605 4ae3 5683 cdec 9825 dde1 1e0a ...f.J.V..%..... 803f124: 9f25 c356 64c9 4845 9cf9 561a ab26 12b9 %.V..dEH...V&... 803f134: 6d77 edc2 4142 886a 636a 3168 7811 86e6 wm..BAj.jch1.x.. 803f144: 2a12 adc3 b5b7 b8a1 96b7 00b9 d34c f7d6 .*..........L... 803f154: 887c aa7f 6527 e920 d891 fde7 7f4f 3c69 |...'e .....O.i< 803f164: 3ee2 8748 0b76 f79e 17f9 2490 497a afc2 .>H.v......$zI.. 803f174: 8242 1455 405e 8516 e17c a01d f3d6 0771 B.U.^@..|.....q. 803f184: 0f9e b8bb da19 5cd1 3e77 bd24 8190 cd21 .......\w>$...!. 803f194: 193b 64f4 e107 cd36 bb37 cbea 6d51 da30 ;..d..6.7...Qm0. 803f1a4: c6d4 842e 59bd dd42 82d9 fdce 8ac9 d41d .....YB......... 803f1b4: 041c 60b6 9111 fd5d 5662 9d1a 5843 ebc6 ...`..].bV..CX.. 803f1c4: 3092 4896 04f8 8aef e0e7 a306 1760 f77d .0.H........`.}. 803f1d4: 1507 bdb8 53be d016 0ee6 31d9 c244 1f5c .....S.....1D.\. 803f1e4: 4d69 f7d5 ef0f 28f5 9f01 69ba a1cc 6b37 iM.....(...i..7k 803f1f4: 6de9 b7e7 bf70 9fae e90b 36ee f07e 06b5 .m..p......6~... 803f204: 7e30 c227 bff4 2c68 fe63 b59a 71b4 2196 0~'...h,c....q.! 803f214: 7d8b 434e 703b 1ee9 caec dd84 fb02 4c04 .}NC;p.........L 803f224: 748b 1216 4f57 f15b 827e 3eae 0ae8 cbf1 .t..WO[.~..>.... 803f234: 3058 e59d 1be0 77c1 d84f fd6e afe3 f4ff X0.....wO.n..... 803f244: 9ff5 9fe1 f8ff affa ff5f 8feb 111b 185d ........_.....]. 803f254: 8e3e ebae fe40 009d 1bfc fbfd 5ff7 e5ff >...@........_.. 803f264: efeb 032f 4e35 fa80 a80f 7ffe febf 65cb ../.5N.........e 803f274: 2600 0009 f9ff dff5 febe d7e7 c3df ffbf .&.............. 803f284: ebeb 03ff 2eb2 3504 bebc 8a48 9746 1b15 .......5..H.F... 803f294: 565f 726c ebad 5e37 800c f153 3ea2 2a18 _Vlr..7^..S..>.* 803f2a4: 17dd 2ce2 763d 6951 29d7 9517 3df6 b4e0 ...,=vQi.)...=.. 803f2b4: f388 a02f 36f5 e145 6754 1302 fa49 9451 ../..6E.Tg..I.Q. 803f2c4: de07 0864 6df2 e1d5 f60c 9b63 d099 d488 ..d..m....c..... 803f2d4: 0dde 5a24 36c0 8042 0837 d76b 472d 16e6 ..$Z.6B.7.k.-G.. 803f2e4: 6c20 068c e6a3 cad4 0dd5 3378 d9e2 820d l........x3.... 803f2f4: 05a4 e8fb 6ba3 0770 dfb1 9d95 4d92 538d .....kp......M.S 803f304: 0a38 7a3b 5875 1147 6a0f 992d 8ab5 057a 8.;zuXG..j-...z. 803f314: f260 c0ba 431f 5e4c 9b66 fd62 7a65 b6c8 `....CL^f.b.ez.. 803f324: 7807 64e3 605f 441c ceb1 437f e1ae 6b04 .x.d_`.D...C...k 803f334: e6dc 0480 99e2 ecd2 152f 7cea d755 38fd ......../..|U..8 803f344: 0c89 d964 7ba0 905b e4a0 dc0d 329e 4b78 ..d..{[......2xK 803f354: 3752 0e66 8dae 8517 75a2 19a2 8385 bb2a R7f......u....*. 803f364: 6aab b6b3 5bbe b589 360c 727b 8608 760a .j...[...6{r...v 803f374: d486 a963 3e9e 8f7c db29 db67 3e79 fae5 ..c..>|.).g.y>.. 803f384: 2191 2a7f f877 8c9a 9bb7 accc a530 bbb7 .!.*w.......0... 803f394: 9ab8 1644 3d90 bb02 db5b cf7c d478 75d3 ..D..=..[.|.x..u 803f3a4: 03e4 584b e0ae 0c1d 915a e104 5b3c 64f0 ..KX....Z...<[.d 803f3b4: 6b67 20ce c3de 229b 9c9b b261 d8fb 41c1 gk. ..."..a....A 803f3c4: 8353 96c6 3df1 ada1 d811 fd16 189b 5d96 S....=.........] 803f3d4: 28d6 b026 d2be 04cd e68d 970b 8f10 4c6a .(&...........jL 803f3e4: b7b0 1cc8 e1ca 1545 aa79 e825 8467 595e ......E.y.%.g.^Y 803f3f4: 2475 5091 e387 046d 6dbe 586d 9d76 2568 u$.P..m..mmXv.h% 803f404: d2ae 06ed 3e90 a1a3 4412 6da3 41d0 a0d1 .....>...D.m.A.. 803f414: 0833 05ea c582 44aa 8d50 2bc1 0566 c29c 3......DP..+f... 803f424: 3d74 dab2 25aa ae57 0b8c 3dc9 9181 4730 t=...%W....=..0G 803f434: c16f 5976 c33c 3c51 7cb0 296b eef4 5aa8 o.vY<.Q<.|k)...Z 803f444: bc36 26b6 629f 11a2 cd32 8862 0fda da23 6..&.b..2.b...#. 803f454: d1e1 d771 42fb ad4f 4dbb deba 3eab 6e8b ..q..BO..M...>.n 803f464: 50b9 8fc7 a1b1 eac7 d50e 3597 7a3f abc0 .P.........5?z.. 803f474: de51 42ca ece5 62c6 8c7f 18c7 bae0 40d9 Q..B...b.......@ 803f484: 4df5 f231 c203 81a9 1074 277d 7e67 9f2c .M1.....t.}'g~,. 803f494: 74fa 8804 e697 f95d 2c88 1f8c 707e 42b2 .t....]..,..~p.B 803f4a4: 8a26 39d4 5cfe 9b96 ac29 40ef 86bd 5b9a &..9.\..)..@...[ 803f4b4: 414c 8fc2 6505 7c3a f783 bfc6 ff81 c62b LA...e:|......+. 803f4c4: 61b4 dd0a 5a76 744d 496d e067 d5d0 dbfe .a..vZMtmIg..... 803f4d4: 6fd1 e5cb f56f 2d35 9a8a 0086 4838 da1f .o..o.5-....8H.. 803f4e4: c9f4 9bc3 18d6 164b 89a6 28ec 9620 1906 ......K....( ... 803f4f4: 318c 0077 3cf1 b24b 2955 c635 f566 2f29 .1w..: 803f5e3: 692f 666e 2e6f 7468 6c6d 0000 5448 5054 /info.html..HTTP 803f5f3: 312f 312e 3220 3030 4f20 0d4b 530a 7265 /1.1 200 OK..Ser 803f603: 6576 3a72 6c20 4977 2f50 2e31 2e33 2031 ver: lwIP/1.3.1 803f613: 6828 7474 3a70 2f2f 6173 6176 6e6e 6861 (http://savannah 803f623: 6e2e 6e6f 6e67 2e75 726f 2f67 7270 6a6f .nongnu.org/proj 803f633: 6365 7374 6c2f 6977 2970 0a0d 6f43 746e ects/lwip)..Cont 803f643: 6e65 2d74 654c 676e 6874 203a 3031 3739 ent-Length: 1097 803f653: 0a0d 6f43 6e6e 6365 6974 6e6f 203a 6c43 ..Connection: Cl 803f663: 736f 0d65 430a 6e6f 6574 746e 742d 7079 ose..Content-typ 803f673: 3a65 7420 7865 2f74 7468 6c6d 0a0d 6f43 e: text/html..Co 803f683: 746e 6e65 2d74 6e45 6f63 6964 676e 203a ntent-Encoding: 803f693: 7a67 7069 0a0d 0a0d 8b1f 0008 0000 0000 gzip............ 803f6a3: 0a04 569d 6edd 36db 7e14 5615 69bb 2881 ...V.n.6.~.V.i.( 803f6b3: 766e 6035 8096 0b22 028a 56eb 1d60 5db0 nv5`.."....V`..] 803f6c3: b415 db44 256c 9352 c728 4bbe add2 68bb ..D.l%R.(..K...h 803f6d3: 0e81 30c1 4114 aed7 827b 6b74 b4b6 d389 ...0.A..{.tk.... 803f6e3: a057 68de 21df 272d 9c5e e7ec 3642 c88f W..h.!-'^...B6.. 803f6f3: f7f3 ef9d aa1c e57b cf93 efd7 7d7e 8367 ......{.....~}g. 803f703: 4d0d c59e fa5d 1965 8357 0828 0920 c69e .M..].e.W.(. ... 803f713: 5cdd ce18 2192 2b2f a261 36a0 f0fd ec23 .\...!/+a..6..#. 803f723: b7b9 6343 508a 537c 51cb 7c14 7e15 2379 ..Cc.P|S.Q.|.~y# 803f733: d75c c179 ec8d 2265 8960 4656 a828 dadc \.y...e"`.VF(... 803f743: 4488 103a 92ad b9e2 8288 1491 859b cd2e .D:............. 803f753: 7399 329b c335 1528 9923 d088 2b09 4952 .s.25.(.#....+RI 803f763: 7923 5616 cf09 b444 92b6 b1f3 ebcc 2e7c #y.V..D.......|. 803f773: 95d7 9d28 e1c0 ba32 170e 9a46 c44c 99f6 ..(...2...F.L... 803f783: 369d dadf 6693 1ecb fddb 91e6 6c3d 769e .6...f......=l.v 803f793: 7e3b 9baf f549 0d80 d14b 828f 4b9c 9ab5 ;~..I...K....K.. 803f7a3: 5554 4ac0 4591 6541 9926 86a8 1842 aa58 TU.J.EAe&...B.X. 803f7b3: 5292 8616 4999 7081 188d ce9b 3e7d fee2 .R...I.p....}>.. 803f7c3: c06d 32aa 8289 6752 f562 857e 1dc3 1eff m..2..Rgb.~..... 803f7d3: 0f0b 4f5a 93a7 9bb8 11ca 324b 555e a051 ..ZO......K2^UQ. 803f7e3: a8f8 4bc7 ffe6 54c2 79f4 999d ec56 b1cb ...K...T.y..V... 803f7f3: 4348 0ba3 3a58 13a7 4592 fa51 b8ad 67cb HC..X:...EQ....g 803f803: 4ba1 8a95 2af1 0c15 7a10 991f 681e 858a .K...*...z...h.. 803f813: 81e3 f699 d5b7 20f8 3260 ce45 d542 44a1 ....... `2E.B..D 803f823: 6675 eb47 d5ac 7047 446d fa58 b4d3 0188 ufG...GpmDX..... 803f833: 52d9 b1c7 097d b774 3eec 3e50 7668 ad9a .R..}.t..>P>hv.. 803f843: b1e6 4ef7 cfe7 80ea 463a 41aa e3e5 ed8d ...N....:F.A.... 803f853: 50cf 26db 7b05 df62 77da 70f6 9ab9 7d54 .P.&.{b..w.p..T} 803f863: 98bd 4f22 1c8c 4a81 0bcb 894c ddff 50f5 .."O...J..L....P 803f873: 4656 9397 f3d6 cd4f 7843 229d a3e4 9f53 VF....O.Cx."..S. 803f883: 1a9d f7dc 9d90 7f81 e4b3 0145 1de0 336a ..........E...j3 803f893: 0336 e18b 05da b1de 05d1 8498 88f1 3267 6.............g2 803f8a3: 2345 1568 f4f6 8098 0f26 5d7d 6ee6 8bfb E#h.....&.}].n.. 803f8b3: 6ecf a1df 02dc f946 1568 2e05 64d3 0320 .n....F.h....d . 803f8c3: c686 6a1a b898 71b9 7a17 8886 d6dd 0bc7 ...j...q.z...... 803f8d3: b0b3 1ce6 bd32 d9d0 61c2 3dcf d253 fd12 ....2....a.=S... 803f8e3: 5597 8705 0fed d701 801e ce9e 3f00 47b2 .U...........?.G 803f8f3: d6a8 fa16 8861 e8c0 5634 d5ae a78d 33ad ....a...4V.....3 803f903: b690 955e 0256 9459 838e 1776 1de8 e3d8 ..^.V.Y...v..... 803f913: 29e6 7573 8d7f db1e aaa1 4c1b b30a c754 .)su.......L..T. 803f923: 5c65 4617 34e6 dc02 e741 7bd4 ed89 8473 e\.F.4..A..{..s. 803f933: 06f6 8f36 279a 3373 a78e 153a 52d9 1f8d ..6..'s3..:..R.. 803f943: 9ec1 bb1d eccf 477b 43a0 a7fb 8dfd 108c ......{G.C...... 803f953: b0a5 5fda 5330 1a94 5895 7aee 7097 b668 ..._0S...X.z.ph. 803f963: 3a69 5030 c5f9 6282 737f ca24 d50a 1659 i:0P...b.s$...Y. 803f973: edc3 eb1b 1c0c 437a 3468 0bdb 397a 784f ......zCh4..z9Ox 803f983: 529a 9ebf f5cf 3915 87b4 fce0 79b4 df6c .R.....9.....yl. 803f993: 1032 c4f1 0ef5 c355 4823 63a9 29aa c9d7 2.....U.#H.c.).. 803f9a3: 6ef4 ac01 d45d 6e0e 2e09 7a98 6ad4 5dc5 .n..]..n...z.j.] 803f9b3: 8aa9 ecfa 0ab0 c9d0 6734 a6f5 296a 5b3c ........4g..j)<[ 803f9c3: 86ce 9105 2431 6356 8188 7c75 099c c035 ....1$Vc..u|..5. 803f9d3: 0dfc aed6 1cd3 1f3d 73fb 14ca 9f00 f7d8 ......=..s...... 803f9e3: 8e78 fcf0 3081 c8a6 e0e6 c39f 26a8 a7d5 x....0.......&.. 803f9f3: 713a e11d 29fb 4b9b 37ff a21e 31f4 4781 :q...).K.7...1.G 803fa03: 76c4 e863 e690 8788 62f1 1240 639d e202 .vc......b@..c.. 803fa13: 21de e7a0 7fc2 a20d b6d3 c5ca f72d a3cc .!..........-... 803fa23: 7cd5 30ef c77a 6bec 1002 11e0 0e05 d120 .|.0z..k...... . 803fa33: a3e8 fffa 4f6e 6540 1090 d059 7759 5d55 ....nO@e..Y.YwU] 803fa43: 9ada 9fbe a18f aa74 ca70 b41e 0ffb 05f6 ......t.p....... 803fa53: 300b 5f65 3dda 7f66 8f81 e15f 2f71 5a58 .0e_.=f..._.q/XZ 803fa63: e5d5 57dd d517 fcbd 0ec2 b4bc 4871 7975 ...W........qHuy 803fa73: b4f3 75a8 24dc bb8b dabd ad18 5766 17ac ...u.$......fW.. 803fa83: a602 9255 e4c9 6e01 6157 52ea aab1 e5ee ..U....nWa.R.... 803fa93: dcd2 b8c2 7abc e56d daca b6fc 19eb f0c5 .....zm......... 803faa3: 4584 7329 4e5e f590 0c2b efa3 ae00 6507 .E)s^N..+......e 803fab3: e687 3789 3a0a dd13 e7f1 45af e63f c5fe ...7.:.....E?... 803fac3: ef05 0fbe 2f16 4bf8 62b5 c49a 8537 7ab9 ...../.K.b..7..z 803fad3: e3ed 9fb3 f404 f56d 2017 d96f 6b71 0009 ......m.. o.qk.. 803fae3: 4800 5454 2f50 2e31 2030 3032 2030 4b4f .HTTP/1.0 200 OK 803faf3: 0a0d 6f43 746e 6e65 2d74 7954 6570 743a ..Content-Type:t 803fb03: 7865 2f74 7468 6c6d 0a0d 0a0d 7b00 4122 ext/html.....{"A 803fb13: 2243 223a 2200 222c 4344 3a22 0022 2c22 C":".","DC":".", 803fb23: 6922 5f6e 7266 7165 3a22 0022 2c22 6f22 "in_freq":".","o 803fb33: 7475 665f 6572 2271 223a 2200 222c 7770 ut_freq":".","pw 803fb43: 2272 223a 2200 222c 696c 656e 665f 6961 r":".","line_fai 803fb53: 226c 223a 2200 222c 6f6c 5f77 6162 7474 l":".","low_batt 803fb63: 7265 2279 223a 2200 222c 6162 5f74 6163 ery":".","bat_ca 803fb73: 2270 223a 2200 222c 6e69 656e 5f72 6574 p":".","inner_te 803fb83: 706d 3a22 0022 2c22 6222 7461 745f 6d69 mp":".","bat_tim 803fb93: 5f65 656c 7466 3a22 0022 2c22 6c22 616f e_left":".","loa 803fba3: 5f64 6f6d 696e 6f74 2272 223a 2200 222c d_monitor":"."," 803fbb3: 6574 706d 6d5f 6e6f 7469 726f 3a22 0022 temp_monitor":". 803fbc3: 2c22 6322 6e6f 656e 7463 6d5f 6e6f 7469 ","connect_monit 803fbd3: 726f 3a22 0022 2c22 6122 616c 6d72 3a22 or":".","alarm": 803fbe3: 0022 2c22 6e22 7465 6573 7474 6e69 7367 ".","netsettings 803fbf3: 635f 6168 676e 6465 3a22 0022 7d22 7b00 _changed":"."}.{ 803fc03: 7222 6165 5f64 6f63 6d6d 6e75 7469 2279 "read_community" 803fc13: 223a 2200 222c 7277 7469 5f65 6f63 6d6d :".","write_comm 803fc23: 6e75 7469 2279 223a 2200 222c 616d 616e unity":".","mana 803fc33: 6567 4972 2250 223a 2200 222c 616d 616e gerIP":".","mana 803fc43: 6567 4972 3250 3a22 0022 2c22 6d22 6e61 gerIP2":".","man 803fc53: 6761 7265 5049 2233 223a 2200 222c 616d agerIP3":".","ma 803fc63: 616e 6567 4972 3450 3a22 0022 2c22 6d22 nagerIP4":".","m 803fc73: 6e61 6761 7265 5049 2235 223a 2200 222c anagerIP5":"."," 803fc83: 6964 2231 223a 2200 222c 6f72 2231 223a di1":".","ro1":" 803fc93: 2200 222c 6f72 2232 223a 2200 222c 7069 .","ro2":".","ip 803fca3: 6461 7264 3a22 0022 2c22 6722 2277 223a addr":".","gw":" 803fcb3: 2200 222c 616d 6b73 3a22 0022 2c22 6422 .","mask":".","d 803fcc3: 6368 2270 003a 222c 7372 735f 7265 6576 hcp":.,"rs_serve 803fcd3: 2272 223a 2200 222c 7372 705f 726f 2274 r":".","rs_port" 803fce3: 223a 2200 222c 7372 705f 6477 3a22 0022 :".","rs_pwd":". 803fcf3: 2c22 7222 5f73 656b 2279 223a 2200 222c ","rs_key":"."," 803fd03: 7372 655f 616e 6c62 6465 3a22 2c00 6422 rs_enabled":.,"d 803fd13: 7461 2265 223a 2200 222c 6974 656d 3a22 ate":".","time": 803fd23: 0022 2c22 6e22 7074 3a22 0022 2c22 6e22 ".","ntp":".","n 803fd33: 7074 6573 7672 7069 3a22 0022 2c22 7522 tpservip":".","u 803fd43: 6374 3a22 0022 2c22 7522 6d74 3a22 0022 tc":".","utm":". 803fd53: 2c22 6c22 7361 7374 6e79 7463 6d69 2265 ","lastsynctime" 803fd63: 223a 7b00 7522 7470 6d69 2265 223a 2200 :".{"uptime":"." 803fd73: 222c 6f6d 6564 226c 223a 2200 222c 7270 ,"model":".","pr 803fd83: 646f 7461 2265 223a 2200 222c 7766 6576 odate":".","fwve 803fd93: 7372 6f69 226e 223a 2200 222c 616d 6163 rsion":".","maca 803fda3: 6464 2272 223a 2200 222c 6573 6e72 226f ddr":".","serno" 803fdb3: 223a 2200 222c 776f 656e 2272 223a 2200 :".","owner":"." 803fdc3: 222c 7973 4c73 636f 7461 6f69 226e 223a ,"sysLocation":" 803fdd3: 2200 222c 6f63 6d6d 6e65 2274 223a 2200 .","comment":"." 803fde3: 222c 7075 5f73 6f6d 6564 226c 223a 2200 ,"ups_model":"." 803fdf3: 222c 7075 5f73 7766 6576 7372 6f69 226e ,"ups_fwversion" 803fe03: 223a 5200 6265 6f6f 5474 7361 006b 6374 :".RebootTask.tc 803fe13: 6970 5f70 6874 6572 6461 0400 pip_thread. 0803fe1e : 803fe1e: 0004 0006 000c 0005 0019 0010 0006 0008 ................ 803fe2e: 0014 000a 001e 0032 0005 0009 0032 0019 ......2.....2... 0803fe3e : 803fe3e: 001c 0020 0094 001c 0010 0010 002c 0014 .. .........,... 803fe4e: 0014 0010 0020 0010 0024 0080 0010 0614 .... ...$....... 803fe5e: 0000 .. 0803fe60 : 803fe60: 0fe4 2001 0fec 2001 0fdc 2001 0ff0 2001 ... ... ... ... 0803fe70 : 803fe70: 0201 0403 0605 0707 0707 0707 0307 ............. 0803fe7d : 803fe7d: 0603 180c 6030 ff78 ....0`x 0803fe84 : 803fe84: ffff ffff .... 0803fe88 : 803fe88: 0000 0000 .... 0803fe8c : 803fe8c: 0000 0000 .... 0803fe90 : 803fe90: 1375 0803 0e29 0803 13b9 0803 0f3d 0803 u...).......=... 803fea0: 0001 0000 .... 0803fea4 : 803fea4: 1644 2000 1644 2000 D.. D.. 0803feac : 803feac: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 803febc: 0002 0001 ffdc 0803 0104 0804 ............ 0803fec8 : 803fec8: 06d4 0804 029c 0804 160c 2000 0778 0804 ........... x... 803fed8: 009c 0804 026c 0804 04c8 0804 0038 0804 ....l.......8... 0803fee8 : 803fee8: 1674 2000 1674 2000 1674 2000 1674 2000 t.. t.. t.. t.. 803fef8: 1674 2000 1674 2000 1674 2000 1674 2000 t.. t.. t.. t.. 803ff08: 1674 2000 1674 2000 1674 2000 1674 2000 t.. t.. t.. t.. 803ff18: 1674 2000 t.. 0803ff1c : 803ff1c: 0002 0000 0000 0000 0000 0000 0000 0000 ................ 803ff2c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff3c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff4c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff5c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff6c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff7c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff8c: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 803ff9c: 0000 0000 .... 0803ffa0 : 803ffa0: 5146 4e44 752d 6b6e 0000 0000 FQDN-unk.... 0803ffac : 803ffac: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 0803ffbc : 803ffbc: 0a7d 0803 0a9d 0803 09cb 0803 09cf 0803 }............... 803ffcc: 0001 0000 .... 0803ffd0 : 803ffd0: 0000 0000 .... 0803ffd4 : 803ffd4: 0001 0000 0002 0000 ........ 0803ffdc : 803ffdc: 0001 0000 .... 0803ffe0 : 803ffe0: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 803fff0: 0002 0001 06d0 0804 04c4 0804 ............ 0803fffc : 803fffc: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 804000c: 0005 0000 0006 0000 0007 0000 000b 0000 ................ 0804001c : 804001c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804002c: 0002 0008 fffc 0803 fec8 0803 ............ 08040038 : 8040038: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040048: 0002 001c 05bc 0804 0454 0804 ........T... 08040054 : 8040054: 12e9 0803 0d21 0803 09cb 0803 09cf 0803 ....!........... 8040064: 0001 0000 .... 08040068 : 8040068: 01a8 0804 01a8 0804 01a8 0804 01a8 0804 ................ 8040078: 01a8 0804 01a8 0804 01a8 0804 ............ 08040084 : 8040084: 0002 0000 .... 08040088 : 8040088: 00f0 0804 00f0 0804 00f0 0804 00f0 0804 ................ 8040098: 1628 2000 (.. 0804009c : 804009c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80400ac: 0002 001a 0368 0804 01f8 0804 ....h....... 080400b8 : 80400b8: 11fd 0803 0ab1 0803 0b71 0803 09cf 0803 ........q....... 80400c8: 0001 0000 .... 080400cc : 80400cc: 0001 0000 0002 0000 ........ 080400d4 : 80400d4: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80400e4: 0002 0004 ffac 0803 028c 0804 ............ 080400f0 : 80400f0: 0dc5 0803 0df1 0803 09cb 0803 09cf 0803 ................ 8040100: 0001 0000 .... 08040104 : 8040104: 018c 0804 .... 08040108 : 8040108: 0002 0000 0000 0000 0000 0000 0000 0000 ................ 8040118: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040128: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040138: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040148: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040158: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040168: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040178: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 8040188: 0000 0000 .... 0804018c : 804018c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804019c: 0002 0003 02ec 0804 03e4 0804 ............ 080401a8 : 80401a8: 09d1 0803 1631 0803 1161 0803 1401 0803 ....1...a....... 80401b8: 0001 0000 .... 080401bc : 80401bc: 0054 0804 0054 0804 0054 0804 0054 0804 T...T...T...T... 80401cc: 0054 0804 0054 0804 0054 0804 0054 0804 T...T...T...T... 80401dc: 0054 0804 0054 0804 0054 0804 0054 0804 T...T...T...T... 80401ec: 1774 2000 0054 0804 0054 0804 t.. T...T... 080401f8 : 80401f8: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040208: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040218: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040228: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040238: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040248: 06a0 0804 06a0 0804 06a0 0804 06a0 0804 ................ 8040258: 06a0 0804 06a0 0804 ........ 08040260 : 8040260: 0004 0000 .... 08040264 : 8040264: ffbc 0803 1814 2000 ....... 0804026c : 804026c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804027c: 0002 000f 0418 0804 01bc 0804 ............ 08040288 : 8040288: 0000 0000 .... 0804028c : 804028c: 18d8 2000 18d8 2000 18d8 2000 18d8 2000 ... ... ... ... 0804029c : 804029c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80402ac: 0002 0002 ffd4 0803 0264 0804 ........d... 080402b8 : 80402b8: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 80402c8: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 80402d8: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 80402e8: 000d 0000 .... 080402ec : 80402ec: 0001 0000 0002 0000 0003 0000 ............ 080402f8 : 80402f8: 179c 2000 179c 2000 179c 2000 179c 2000 ... ... ... ... 8040308: 179c 2000 ... 0804030c : 804030c: 00b8 0804 00b8 0804 00b8 0804 00b8 0804 ................ 804031c: 00b8 0804 00b8 0804 00b8 0804 00b8 0804 ................ 804032c: 00b8 0804 00b8 0804 00b8 0804 00b8 0804 ................ 804033c: 00b8 0804 00b8 0804 00b8 0804 00b8 0804 ................ 804034c: 00b8 0804 00b8 0804 00b8 0804 17c8 2000 ............... 804035c: 1830 2000 15f0 2000 00b8 0804 0.. ... .... 08040368 : 8040368: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 8040378: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 8040388: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 8040398: 000d 0000 000e 0000 000f 0000 0010 0000 ................ 80403a8: 0011 0000 0012 0000 0013 0000 0014 0000 ................ 80403b8: 0015 0000 0016 0000 0017 0000 0018 0000 ................ 80403c8: 0019 0000 001a 0000 ........ 080403d0 : 80403d0: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 80403e0: 0005 0000 .... 080403e4 : 80403e4: 17e8 2000 17e8 2000 17e8 2000 ... ... ... 080403f0 : 80403f0: 1744 2000 1744 2000 1744 2000 1744 2000 D.. D.. D.. D.. 8040400: 1744 2000 D.. 08040404 : 8040404: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 8040414: 0005 0000 .... 08040418 : 8040418: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 8040428: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 8040438: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 8040448: 000d 0000 000e 0000 000f 0000 ............ 08040454 : 8040454: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 8040464: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 8040474: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 8040484: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 8040494: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 80404a4: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 80404b4: fe90 0803 fe90 0803 fe90 0803 fe90 0803 ................ 080404c4 : 80404c4: 001c 0804 .... 080404c8 : 80404c8: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80404d8: 0002 0005 03d0 0804 0088 0804 ............ 080404e4 : 80404e4: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80404f4: 0002 000d 02b8 0804 fee8 0803 ............ 08040500 : 8040500: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040510: 0002 0016 0648 0804 0720 0804 ....H... ... 0804051c : 804051c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804052c: 0002 0002 00cc 0804 fea4 0803 ............ 08040538 : 8040538: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 8040548: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 8040558: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 8040568: 000d 0000 000e 0000 000f 0000 0010 0000 ................ 8040578: 0011 0000 0012 0000 0013 0000 0014 0000 ................ 8040588: 0015 0000 0016 0000 0017 0000 ............ 08040594 : 8040594: 776c 5049 0800 lwIP. 08040599 : 8040599: 0008 c300 ... 0804059c : 804059c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80405ac: 0002 0005 070c 0804 02f8 0804 ............ 080405b8 : 80405b8: 0000 0000 .... 080405bc : 80405bc: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 80405cc: 0005 0000 0006 0000 0008 0000 0009 0000 ................ 80405dc: 000a 0000 000b 0000 000c 0000 000d 0000 ................ 80405ec: 000e 0000 000f 0000 0010 0000 0011 0000 ................ 80405fc: 0012 0000 0013 0000 0014 0000 0015 0000 ................ 804060c: 0016 0000 0018 0000 0019 0000 001a 0000 ................ 804061c: 001b 0000 001c 0000 001d 0000 001e 0000 ................ 0804062c : 804062c: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 804063c: 0005 0000 0006 0000 0007 0000 ............ 08040648 : 8040648: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 8040658: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 8040668: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 8040678: 000d 0000 000e 0000 000f 0000 0010 0000 ................ 8040688: 0011 0000 0012 0000 0013 0000 0014 0000 ................ 8040698: 0015 0000 0016 0000 ........ 080406a0 : 80406a0: 0bf9 0803 0c25 0803 09cb 0803 09cf 0803 ....%........... 80406b0: 0001 0000 .... 080406b4 : 80406b4: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80406c4: 0002 0002 17bc 2000 0794 0804 ....... .... 080406d0 : 80406d0: 0001 0000 .... 080406d4 : 80406d4: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 80406e4: 0002 0007 062c 0804 0068 0804 ....,...h... 080406f0 : 80406f0: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040700: 0002 0005 0404 0804 03f0 0804 ............ 0804070c : 804070c: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 804071c: 0005 0000 .... 08040720 : 8040720: 169c 2000 169c 2000 169c 2000 169c 2000 ... ... ... ... 8040730: 169c 2000 169c 2000 169c 2000 169c 2000 ... ... ... ... 8040740: 169c 2000 169c 2000 169c 2000 169c 2000 ... ... ... ... 8040750: 169c 2000 169c 2000 169c 2000 169c 2000 ... ... ... ... 8040760: 169c 2000 169c 2000 169c 2000 169c 2000 ... ... ... ... 8040770: 169c 2000 169c 2000 ... ... 08040778 : 8040778: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040788: 0002 0017 0538 0804 030c 0804 ....8....... 08040794 : 8040794: ffe0 0803 0830 0804 ....0... 0804079c : 804079c: 0001 0000 0003 0000 0006 0000 0001 0000 ................ 080407ac : 80407ac: 0000 0000 .... 080407b0 : 80407b0: 7570 6c62 6369 ff00 public. 080407b7 : 80407b7: ffff ffff ffff ...... 080407bd : 80407bd: 0000 0000 0000 7445 5f68 6669 2000 7325 ......Eth_if. %s 80407cd: 0d0a 4400 4348 4350 696c 6e65 0074 6577 ...DHCPClient.we 80407dd: 5262 6965 696e 0074 6552 6e69 7469 6557 bReinit.ReinitWe 80407ed: 0062 0400 b.. 080407f0 : 80407f0: 0904 0804 .... 080407f4 : 80407f4: 0870 0804 p... 080407f8 : 80407f8: 0924 0804 0924 0804 0924 0804 0924 0804 $...$...$...$... 8040808: 0924 0804 0924 0804 0924 0804 0924 0804 $...$...$...$... 8040818: 0924 0804 0924 0804 0924 0804 0924 0804 $...$...$...$... 8040828: 0924 0804 $... 0804082c : 804082c: 038f 0000 .... 08040830 : 8040830: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040840: 0002 0001 08fc 0804 07f0 0804 ............ 0804084c : 804084c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804085c: 0002 0001 08f8 0804 07f4 0804 ............ 08040868 : 8040868: a318 0000 .... 0804086c : 804086c: 093c 0804 <... 08040870 : 8040870: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040880: 0002 000d 088c 0804 07f8 0804 ............ 0804088c : 804088c: 0001 0000 0002 0000 0003 0000 0004 0000 ................ 804089c: 0005 0000 0006 0000 0007 0000 0008 0000 ................ 80408ac: 0009 0000 000a 0000 000b 0000 000c 0000 ................ 80408bc: 000d 0000 0000 0000 0000 0000 0000 0000 ................ 80408cc: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 80408dc: 0000 0000 0000 0000 0000 0000 0000 0000 ................ 80408ec: 0000 0000 0000 0000 0000 0000 ............ 080408f8 : 80408f8: 0001 0000 .... 080408fc : 80408fc: 0001 0000 .... 08040900 : 8040900: 0958 0804 X... 08040904 : 8040904: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040914: 0002 0001 0868 0804 0900 0804 ....h....... 08040920 : 8040920: 0001 0000 .... 08040924 : 8040924: 4d05 0803 4cc9 0803 4cb1 0803 4df5 0803 .M...L...L...M.. 8040934: 0001 0000 .... 08040938 : 8040938: 084c 0804 L... 0804093c : 804093c: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 804094c: 0002 0001 0920 0804 0938 0804 .... ...8... 08040958 : 8040958: 09c3 0803 09c9 0803 09cb 0803 09cf 0803 ................ 8040968: 0002 0001 082c 0804 086c 0804 3025 6432 ....,...l...%02d 8040978: 252e 3230 2e64 3025 6432 2520 3230 3a64 .%02d.%02d %02d: 8040988: 3025 6432 253a 3230 0064 6425 252e 2e64 %02d:%02d.%d.%d. 8040998: 6425 2520 3a64 6425 253a 2064 0d0a 0000 %d %d:%d:%d .... 80409a8: 666e 0000 6e69 7469 0079 0000 6e61 0000 nf..inity...an.. 80409b8: 4241 4443 4645 0000 6261 6463 6665 0000 ABCDEF..abcdef.. 80409c8: 3130 3332 3534 3736 3938 0000 0043 0000 0123456789..C... 80409d8: 4f50 4953 0058 0000 0000 0000 002e 0000 POSIX........... 080409e8 <_init>: 80409e8: b5f8 push {r3, r4, r5, r6, r7, lr} 80409ea: bf00 nop 80409ec: bcf8 pop {r3, r4, r5, r6, r7} 80409ee: bc08 pop {r3} 80409f0: 469e mov lr, r3 80409f2: 4770 bx lr 080409f4 <_fini>: 80409f4: b5f8 push {r3, r4, r5, r6, r7, lr} 80409f6: bf00 nop 80409f8: bcf8 pop {r3, r4, r5, r6, r7} 80409fa: bc08 pop {r3} 80409fc: 469e mov lr, r3 80409fe: 4770 bx lr