📄 ddma2.lst
字号:
434 0240 00110200 sll $2,$2,4 435 0244 21104300 addu $2,$2,$3 436 0248 0000448C lw $4,0($2) 437 024c 00A0023C li $2,-1610612736 # 0xffffffffa0000000 438 0250 0800838C lw $3,8($4) 439 0254 21186200 addu $3,$3,$2 148:/mnt/hgfs/boot/booter/source/ddma2.c **** } 440 .loc 1 148 0 441 0258 0800E003 j $31 442 025c 0000628C lw $2,0($3) 443 444 .set macro 445 .set reorder 446 $LFE15: 447 .end ddma2_get_channel_status 448 .align 2 449 .globl ddma2_enable_descriptor 450 .ent ddma2_enable_descriptor 451 .type ddma2_enable_descriptor, @function 452 ddma2_enable_descriptor: 453 $LFB16: 149:/mnt/hgfs/boot/booter/source/ddma2.c **** 150:/mnt/hgfs/boot/booter/source/ddma2.c **** int ddma2_enable_descriptor(DDMA_DESCRIPTOR* ddma_desc, int enable) 151:/mnt/hgfs/boot/booter/source/ddma2.c **** { 454 .loc 1 151 0 455 .frame $sp,0,$31 # vars= 0, regs= 0/0, args= 0, gp= 0 456 .mask 0x00000000,0 457 .fmask 0x00000000,0 458 .set noreorder 459 .set nomacro 460 152:/mnt/hgfs/boot/booter/source/ddma2.c **** if(enable) 461 .loc 1 152 0 462 0260 0700A010 beq $5,$0,$L24 463 0264 00000000 nop 464 153:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma_desc->u.std.cmd0 |= DDMA_DESCCMD_V; //Enable valid bit 465 .loc 1 153 0 466 0268 0000838C lw $3,0($4) 467 026c 0080023C li $2,-2147483648 # 0xffffffff80000000 468 0270 25186200 or $3,$3,$2 469 0274 000083AC sw $3,0($4)GAS LISTING /tmp/ccSUImwK.s page 12 470 0278 0800E003 j $31 471 027c 00000000 nop 472 473 $L24: 154:/mnt/hgfs/boot/booter/source/ddma2.c **** else 155:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma_desc->u.std.cmd0 &= ~DDMA_DESCCMD_V; //Disable valid bit 474 .loc 1 155 0 475 0280 0000838C lw $3,0($4) 476 0284 FF7F023C li $2,2147418112 # 0x7fff0000 477 0288 FFFF4234 ori $2,$2,0xffff 478 028c 24186200 and $3,$3,$2 479 0290 000083AC sw $3,0($4) 156:/mnt/hgfs/boot/booter/source/ddma2.c **** } 480 .loc 1 156 0 481 0294 0800E003 j $31 482 0298 00000000 nop 483 484 .set macro 485 .set reorder 486 $LFE16: 487 .end ddma2_enable_descriptor 488 .align 2 489 .globl ddma2_insert_descriptor 490 .ent ddma2_insert_descriptor 491 .type ddma2_insert_descriptor, @function 492 ddma2_insert_descriptor: 493 $LFB17: 157:/mnt/hgfs/boot/booter/source/ddma2.c **** 158:/mnt/hgfs/boot/booter/source/ddma2.c **** int ddma2_insert_descriptor(CHANNEL_ID id, DDMA_DESCRIPTOR* ddma_desc) 159:/mnt/hgfs/boot/booter/source/ddma2.c **** { 494 .loc 1 159 0 495 .frame $sp,0,$31 # vars= 0, regs= 0/0, args= 0, gp= 0 496 .mask 0x00000000,0 497 .fmask 0x00000000,0 498 .set noreorder 499 .set nomacro 500 160:/mnt/hgfs/boot/booter/source/ddma2.c **** if(ddma_desc) 161:/mnt/hgfs/boot/booter/source/ddma2.c **** { 162:/mnt/hgfs/boot/booter/source/ddma2.c **** //Point this descriptor back to itself 163:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma_desc->u.std.nxt_ptr = (ddma_desc->u.std.nxt_ptr & ~(0x07FFFFFF)) //mask off existing next po 501 .loc 1 163 0 502 029c FF5F023C li $2,1610547200 # 0x5fff0000 503 02a0 FFFF4234 ori $2,$2,0xffff 164:/mnt/hgfs/boot/booter/source/ddma2.c **** | VIRT_TO_NXTPTR(ddma_desc); //Or in next pointer to current descriptor 165:/mnt/hgfs/boot/booter/source/ddma2.c **** 166:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma_desc->u.std.cmd0 |= DDMA_DESCCMD_V; //set valid 167:/mnt/hgfs/boot/booter/source/ddma2.c **** 168:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma2_irq_lock(id); 169:/mnt/hgfs/boot/booter/source/ddma2.c **** if(channels[id].d_tail == NULL) 504 .loc 1 169 0 505 02a4 40180400 sll $3,$4,1 506 .loc 1 163 0 507 02a8 2438A200 and $7,$5,$2 508 .loc 1 169 0 509 02ac 21186400 addu $3,$3,$4 510 02b0 0000023C lui $2,%hi(channels)GAS LISTING /tmp/ccSUImwK.s page 13 511 02b4 00004224 addiu $2,$2,%lo(channels) 512 02b8 00190300 sll $3,$3,4 513 02bc 21206200 addu $4,$3,$2 514 .loc 1 163 0 515 02c0 00F8083C li $8,-134217728 # 0xfffffffff8000000 516 02c4 42310700 srl $6,$7,5 170:/mnt/hgfs/boot/booter/source/ddma2.c **** { //List is empty, insert the descriptor 171:/mnt/hgfs/boot/booter/source/ddma2.c **** channels[id].d_head = ddma_desc; 172:/mnt/hgfs/boot/booter/source/ddma2.c **** channels[id].d_tail = ddma_desc; 173:/mnt/hgfs/boot/booter/source/ddma2.c **** 174:/mnt/hgfs/boot/booter/source/ddma2.c **** channels[id].ptr->des_ptr = CPHYSADDR(ddma_desc); 175:/mnt/hgfs/boot/booter/source/ddma2.c **** } 176:/mnt/hgfs/boot/booter/source/ddma2.c **** else 177:/mnt/hgfs/boot/booter/source/ddma2.c **** { //Insert descriptor at end of list 178:/mnt/hgfs/boot/booter/source/ddma2.c **** channels[id].d_tail->u.std.nxt_ptr = (channels[id].d_tail->u.std.nxt_ptr & ~(0x07FFFFFF)) //mas 179:/mnt/hgfs/boot/booter/source/ddma2.c **** | VIRT_TO_NXTPTR(ddma_desc); //Or in next pointer to current descriptor 180:/mnt/hgfs/boot/booter/source/ddma2.c **** channels[id].d_tail = ddma_desc; 181:/mnt/hgfs/boot/booter/source/ddma2.c **** } 182:/mnt/hgfs/boot/booter/source/ddma2.c **** ddma2_irq_unlock(id); 183:/mnt/hgfs/boot/booter/source/ddma2.c **** 184:/mnt/hgfs/boot/booter/source/ddma2.c **** //au1550_ddma2_enable_channel(id); 185:/mnt/hgfs/boot/booter/source/ddma2.c **** 186:/mnt/hgfs/boot/booter/source/ddma2.c **** return 1; 187:/mnt/hgfs/boot/booter/source/ddma2.c **** } 188:/mnt/hgfs/boot/booter/source/ddma2.c **** 189:/mnt/hgfs/boot/booter/source/ddma2.c **** return 0; 517 .loc 1 189 0 518 .loc 1 160 0 519 02c8 1100A010 beq $5,$0,$L32 520 02cc 21100000 move $2,$0 521 522 .loc 1 163 0 523 02d0 1C00A28C lw $2,28($5) 524 02d4 24104800 and $2,$2,$8 525 02d8 25104600 or $2,$2,$6 526 02dc 1C00A2AC sw $2,28($5) 527 .loc 1 166 0 528 02e0 0000A38C lw $3,0($5) 529 02e4 0080023C li $2,-2147483648 # 0xffffffff80000000 530 02e8 25186200 or $3,$3,$2 531 02ec 0000A3AC sw $3,0($5) 532 .loc 1 169 0 533 02f0 1000838C lw $3,16($4) 534 02f4 08006014 bne $3,$0,$L29 535 02f8 00000000 nop 536 537 .loc 1 174 0 538 02fc 0000828C lw $2,0($4) 539 .loc 1 172 0 540 0300 100085AC sw $5,16($4) 541 .loc 1 171 0 542 0304 0C0085AC sw $5,12($4) 543 .loc 1 174 0 544 0308 040047AC sw $7,4($2) 545 .loc 1 186 0 546 030c 01000224 li $2,1 # 0x1 547 $L32:GAS LISTING /tmp/ccSUImwK.s page 14 190:/mnt/hgfs/boot/booter/source/ddma2.c **** } 548 .loc 1 190 0 549 0310 0800E003 j $31 550 0314 00000000 nop 551 552 $L29: 553 .loc 1 178 0 554 0318 1C00628C lw $2,28($3) 555 031c 24104800 and $2,$2,$8 556 0320 25104600 or $2,$2,$6 557 0324 1C0062AC sw $2,28($3) 558 .loc 1 186 0 559 0328 01000224 li $2,1 # 0x1 560 .loc 1 180 0 561 032c 0800E003 j $31 562 0330 100085AC sw $5,16($4) 563 564 .set macro 565 .set reorder 566 $LFE17: 567 .end ddma2_insert_descriptor 568 .section .rodata.str1.4,"aMS",@progbits,1 569 .align 2 570 $LC0: 571 0000 4368616E .ascii "Channel %d Descriptor Chain:\n\000" 571 6E656C20 571 25642044 571 65736372 571 6970746F 572 001e 0000 .align 2 573 $LC2: 574 0020 255800 .ascii "%X\000" 575 0023 00 .align 2 576 $LC1: 577 0024 202D3E20 .ascii " -> \000" 577 00 578 0029 000000 .align 2 579 $LC3: 580 002c 0A00 .ascii "\n\000" 581 002e 0000 .text 582 .align 2 583 .globl ddma2_print_descriptor_chain 584 .ent ddma2_print_descriptor_chain 585 .type ddma2_print_descriptor_chain, @function 586 ddma2_print_descriptor_chain: 587 $LFB18: 191:/mnt/hgfs/boot/booter/source/ddma2.c **** 192:/mnt/hgfs/boot/booter/source/ddma2.c **** void ddma2_print_descriptor_chain(CHANNEL_ID id) 193:/mnt/hgfs/boot/booter/source/ddma2.c **** { 588 .loc 1 193 0 589 .frame $sp,40,$31 # vars= 0, regs= 6/0, args= 16, gp= 0 590 .mask 0x801f0000,-4 591 .fmask 0x00000000,0 592 .set noreorder 593 .set nomacro 594 595 0334 D8FFBD27 addiu $sp,$sp,-40GAS LISTING /tmp/ccSUImwK.s page 15 596 $LCFI8: 597 0338 1000B0AF sw $16,16($sp) 598 $LCFI9: 599 033c 21808000 move $16,$4 194:/mnt/hgfs/boot/booter/source/ddma2.c **** DDMA_DESCRIPTOR* dsc; 195:/mnt/hgfs/boot/booter/source/ddma2.c **** printf("Channel %d Descriptor Chain:\n", id); 600 .loc 1 195 0 601 0340 0000043C lui $4,%hi($LC0) 602 0344 21280002 move $5,$16 603 .loc 1 193 0 604 0348 2000B4AF sw $20,32($sp) 605 $LCFI10: 606 034c 1C00B3AF sw $19,28($sp) 607 $LCFI11: 608 0350 1800B2AF sw $18,24($sp) 609 $LCFI12: 610 0354 1400B1AF sw $17,20($sp) 611 $LCFI13: 612 0358 2400BFAF sw $31,36($sp) 613 $LCFI14: 614 .loc 1 195 0 615 035c 0000000C jal printf 616 0360 00008424 addiu $4,$4,%lo($LC0) 617 618 0364 40181000 sll $3,$16,1 619 0368 21187000 addu $3,$3,$16 620 036c 0000023C lui $2,%hi(channels) 621 0370 00190300 sll $3,$3,4 622 0374 00004224 addiu $2,$2,%lo(channels) 623 0378 21A06200 addu $20,$3,$2 196:/mnt/hgfs/boot/booter/source/ddma2.c **** dsc = 0; 624 .loc 1 196 0 625 037c 21800000 move $16,$0 626 0380 0000133C lui $19,%hi($LC2) 627 0384 00A0113C li $17,-1610612736 # 0xffffffffa0000000 628 0388 F0000008 j $L34 629 038c 0000123C lui $18,%hi($LC1) 630 631 $L37: 197:/mnt/hgfs/boot/booter/source/ddma2.c **** do 198:/mnt/hgfs/boot/booter/source/ddma2.c **** { 199:/mnt/hgfs/boot/booter/source/ddma2.c **** if(dsc == 0) 200:/mnt/hgfs/boot/booter/source/ddma2.c **** dsc = channels[id].d_head; 201:/mnt/hgfs/boot/booter/source/ddma2.c **** else 202:/mnt/hgfs/boot/booter/source/ddma2.c **** { 203:/mnt/hgfs/boot/booter/source/ddma2.c **** dsc = (DDMA_DESCRIPTOR*) KSEG1(NXTPTR_TO_PHYS(dsc->u.std.nxt_ptr)); 632 .loc 1 203 0 633 0390 1C00028E lw $2,28($16) 634 0394 40110200 sll $2,$2,5 204:/mnt/hgfs/boot/booter/source/ddma2.c **** printf(" -> "); 635 .loc 1 204 0 636 0398 0000000C jal printf 637 039c 21805100 addu $16,$2,$17 638 205:/mnt/hgfs/boot/booter/source/ddma2.c **** } 206:/mnt/hgfs/boot/booter/source/ddma2.c **** 207:/mnt/hgfs/boot/booter/source/ddma2.c **** printf("%X", dsc);GAS LISTING /tmp/ccSUImwK.s page 16 639 .loc 1 207 0 640 03a0 00006426 addiu $4,$19,%lo($LC2) 641 03a4 0000000C jal printf 642 03a8 21280002 move $5,$16 643 208:/mnt/hgfs/boot/booter/source/ddma2.c **** } while(KSEG1(NXTPTR_TO_PHYS(dsc->u.std.nxt_ptr)) != (uint32) dsc); 644 .loc 1 208 0 645 03ac 1C00028E lw $2,28($16) 646 03b0 40110200 sll $2,$2,5 647 03b4 21105100 addu $2,$2,$17 209:/mnt/hgfs/boot/booter/source/ddma2.c **** 210:/mnt/hgfs/boot/booter/source/ddma2.c **** printf("\n"); 648 .loc 1 210 0 649 .loc 1 208 0 650 03b8 0C005010 beq $2,$16,$L40 651 03bc 0000043C lui $4,%hi($LC3) 652 653 $L34: 654 .loc 1 204 0 655 .loc 1 199 0 656 03c0 F3FF0016 bne $16,$0,$L37 657 03c4 00004426 addiu $4,$18,%lo($LC1) 658 659 .loc 1 200 0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -