?? nand.lst
字號:
GAS LISTING /tmp/cc4NTrNa.s page 1 1 .section .mdebug.abi32 2 .previous 3 .section .debug_abbrev,"",@progbits 4 $Ldebug_abbrev0: 5 .section .debug_info,"",@progbits 6 $Ldebug_info0: 7 .section .debug_line,"",@progbits 8 $Ldebug_line0: 9 0000 2B020000 .text 9 0200A100 9 00000101 9 FB0E0A00 9 01010101 10 $Ltext0: 11 .align 2 12 .globl nand_irq_handler 13 .ent nand_irq_handler 14 .type nand_irq_handler, @function 15 nand_irq_handler: 16 $LFB2: 17 .file 1 "/mnt/hgfs/boot/booter/source/nand.c" 1:/mnt/hgfs/boot/booter/source/nand.c **** 2:/mnt/hgfs/boot/booter/source/nand.c **** #include "example.h" 3:/mnt/hgfs/boot/booter/source/nand.c **** #include "nand.h" 4:/mnt/hgfs/boot/booter/source/nand.c **** 5:/mnt/hgfs/boot/booter/source/nand.c **** void* nand_virtual_address; //Mapped by NandConfig from Physical address 0x20000000 6:/mnt/hgfs/boot/booter/source/nand.c **** #define NAND_REG_CMD *(volatile short*)(nand_virtual_address + MEM_STNAND_CMD) 7:/mnt/hgfs/boot/booter/source/nand.c **** #define NAND_REG_ADDR *(volatile short*)(nand_virtual_address + MEM_STNAND_ADDR) 8:/mnt/hgfs/boot/booter/source/nand.c **** #define NAND_REG_DATA *(volatile short*)(nand_virtual_address + MEM_STNAND_DATA) 9:/mnt/hgfs/boot/booter/source/nand.c **** 10:/mnt/hgfs/boot/booter/source/nand.c **** static volatile nand_irq_fired; 11:/mnt/hgfs/boot/booter/source/nand.c **** static NandDevice nand_device; 12:/mnt/hgfs/boot/booter/source/nand.c **** 13:/mnt/hgfs/boot/booter/source/nand.c **** // IRQ Handler Function 14:/mnt/hgfs/boot/booter/source/nand.c **** void nand_irq_handler() 15:/mnt/hgfs/boot/booter/source/nand.c **** { 18 .loc 1 15 0 19 .frame $sp,0,$31 # vars= 0, regs= 0/0, args= 0, gp= 0 20 .mask 0x00000000,0 21 .fmask 0x00000000,0 22 .set noreorder 23 .set nomacro 24 16:/mnt/hgfs/boot/booter/source/nand.c **** IC_REG_RISINGCLR = (1 << NAND_IRQ); //Clear rising edge interrupt 25 .loc 1 16 0 26 0000 40B0023C li $2,-1337982976 # 0xffffffffb0400000 27 0004 78004234 ori $2,$2,0x78 28 0008 8000043C li $4,8388608 # 0x800000 29 000c 000044AC sw $4,0($2) 17:/mnt/hgfs/boot/booter/source/nand.c **** nand_irq_fired = 1; 30 .loc 1 17 0 31 0010 01000324 li $3,1 # 0x1 32 0014 0000023C lui $2,%hi(nand_irq_fired) 33 0018 000043AC sw $3,%lo(nand_irq_fired)($2) 34 001c 0800E003 j $31 35 0020 00000000 nop 36 GAS LISTING /tmp/cc4NTrNa.s page 2 37 .set macro 38 .set reorder 39 $LFE2: 40 .end nand_irq_handler 41 .align 2 42 .globl nand_wait_busy 43 .ent nand_wait_busy 44 .type nand_wait_busy, @function 45 nand_wait_busy: 46 $LFB3: 18:/mnt/hgfs/boot/booter/source/nand.c **** } 19:/mnt/hgfs/boot/booter/source/nand.c **** 20:/mnt/hgfs/boot/booter/source/nand.c **** void nand_wait_busy() 21:/mnt/hgfs/boot/booter/source/nand.c **** { 47 .loc 1 21 0 48 .frame $sp,0,$31 # vars= 0, regs= 0/0, args= 0, gp= 0 49 .mask 0x00000000,0 50 .fmask 0x00000000,0 22:/mnt/hgfs/boot/booter/source/nand.c **** int spin = 0; 23:/mnt/hgfs/boot/booter/source/nand.c **** 24:/mnt/hgfs/boot/booter/source/nand.c **** while(!nand_irq_fired) 25:/mnt/hgfs/boot/booter/source/nand.c **** { 26:/mnt/hgfs/boot/booter/source/nand.c **** spin++; 27:/mnt/hgfs/boot/booter/source/nand.c **** asm("nop"); 28:/mnt/hgfs/boot/booter/source/nand.c **** 29:/mnt/hgfs/boot/booter/source/nand.c **** if(spin == NAND_IRQ_TIMEOUT && (NAND_SB_REG_STSTAT & NAND_STSTAT_RNB)) //Timeout IRQ 30:/mnt/hgfs/boot/booter/source/nand.c **** { 31:/mnt/hgfs/boot/booter/source/nand.c **** DPRINTF("IRQ Timeout!\n"); 32:/mnt/hgfs/boot/booter/source/nand.c **** nand_irq_fired = 1; 51 .loc 1 32 0 52 0024 0000053C lui $5,%hi(nand_irq_fired) 53 0028 0000A28C lw $2,%lo(nand_irq_fired)($5) 54 .loc 1 22 0 55 002c 21200000 move $4,$0 56 .loc 1 32 0 57 .set noreorder 58 .set nomacro 59 0030 0B004014 bne $2,$0,$L8 60 0034 2130A000 move $6,$5 61 .set macro 62 .set reorder 63 64 $L12: 65 .loc 1 26 0 66 0038 01008424 addiu $4,$4,1 67 .loc 1 27 0 68 #APP 69 003c 00000000 nop 70 .loc 1 29 0 71 #NO_APP 72 0040 0F00023C li $2,983040 # 0xf0000 73 0044 40424234 ori $2,$2,0x4240 74 .set noreorder 75 .set nomacro 76 0048 08008210 beq $4,$2,$L11 77 004c 00B4023C li $2,-1275068416 # 0xffffffffb4000000 78 .set macroGAS LISTING /tmp/cc4NTrNa.s page 3 79 .set reorder 80 81 $L3: 82 .loc 1 32 0 83 0050 0000A28C lw $2,%lo(nand_irq_fired)($5) 84 0054 0000063C lui $6,%hi(nand_irq_fired) 85 $L13: 86 0058 F7FF4010 beq $2,$0,$L12 86 00000000 87 $L8: 33:/mnt/hgfs/boot/booter/source/nand.c **** } 34:/mnt/hgfs/boot/booter/source/nand.c **** } 35:/mnt/hgfs/boot/booter/source/nand.c **** nand_irq_fired = 0; 88 .loc 1 35 0 89 0060 0000A0AC sw $0,%lo(nand_irq_fired)($5) 90 0064 0800E003 j $31 90 00000000 91 $L11: 92 .loc 1 29 0 93 006c 04114234 ori $2,$2,0x1104 94 0070 0000438C lw $3,0($2) 95 0074 01006330 andi $3,$3,0x1 96 .loc 1 32 0 97 .loc 1 29 0 98 .set noreorder 99 .set nomacro 100 0078 F5FF6010 beq $3,$0,$L3 101 007c 01000224 li $2,1 # 0x1 102 .set macro 103 .set reorder 104 105 .loc 1 32 0 106 0080 0000C2AC sw $2,%lo(nand_irq_fired)($6) 107 0084 0000A28C lw $2,%lo(nand_irq_fired)($5) 108 .set noreorder 109 .set nomacro 110 0088 16000008 j $L13 111 008c 0000063C lui $6,%hi(nand_irq_fired) 112 .set macro 113 .set reorder 114 115 $LFE3: 116 .end nand_wait_busy 117 .align 2 118 .globl nand_load_device 119 .ent nand_load_device 120 .type nand_load_device, @function 121 nand_load_device: 122 $LFB4: 36:/mnt/hgfs/boot/booter/source/nand.c **** } 37:/mnt/hgfs/boot/booter/source/nand.c **** 38:/mnt/hgfs/boot/booter/source/nand.c **** int nand_load_device(int maker, int device_id) 39:/mnt/hgfs/boot/booter/source/nand.c **** { 123 .loc 1 39 0 124 .frame $sp,0,$31 # vars= 0, regs= 0/0, args= 0, gp= 0 125 .mask 0x00000000,0 126 .fmask 0x00000000,0GAS LISTING /tmp/cc4NTrNa.s page 4 127 .set noreorder 128 .set nomacro 129 40:/mnt/hgfs/boot/booter/source/nand.c **** DPRINTF("%s, Maker: %d, Device: %d\n", __FUNCTION__, maker, device_id); 41:/mnt/hgfs/boot/booter/source/nand.c **** 42:/mnt/hgfs/boot/booter/source/nand.c **** switch(device_id) 130 .loc 1 42 0 131 0090 A1000224 li $2,161 # 0xa1 43:/mnt/hgfs/boot/booter/source/nand.c **** { 44:/mnt/hgfs/boot/booter/source/nand.c **** case 0x73: 45:/mnt/hgfs/boot/booter/source/nand.c **** case 0x33: 46:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 47:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 512; 48:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 1024 * 32; 49:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 128Mbit (16M) NAND */ 50:/mnt/hgfs/boot/booter/source/nand.c **** case 0x75: 51:/mnt/hgfs/boot/booter/source/nand.c **** case 0x35: 52:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 53:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 512; 54:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 2048 * 32; 55:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 256Mbit (32M) NAND */ 56:/mnt/hgfs/boot/booter/source/nand.c **** case 0x76: 57:/mnt/hgfs/boot/booter/source/nand.c **** case 0x36: 58:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 59:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 512; 60:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 4096 * 32; 61:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 512Mbit (64M) NAND */ 62:/mnt/hgfs/boot/booter/source/nand.c **** case 0x78: 63:/mnt/hgfs/boot/booter/source/nand.c **** case 0x79: 64:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 65:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 512; 66:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 8192 * 32; 67:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 1Gbit(128M) NAND */ 68:/mnt/hgfs/boot/booter/source/nand.c **** case 0xa1: 69:/mnt/hgfs/boot/booter/source/nand.c **** case 0xf1: 70:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 132 .loc 1 70 0 133 .loc 1 42 0 134 0094 4100A210 beq $5,$2,$L49 135 0098 0000043C lui $4,%hi(nand_device) 136 137 009c A200A228 slt $2,$5,162 138 00a0 1A004010 beq $2,$0,$L35 139 00a4 D3000224 li $2,211 # 0xd3 140 141 00a8 73000224 li $2,115 # 0x73 142 .loc 1 48 0 143 .loc 1 42 0 144 00ac 0E00A210 beq $5,$2,$L50 145 00b0 00800234 li $2,32768 # 0x8000 146 147 00b4 7400A228 slt $2,$5,116 148 00b8 41004010 beq $2,$0,$L36 149 00bc 76000224 li $2,118 # 0x76 150 151 00c0 35000224 li $2,53 # 0x35 152 .loc 1 54 0GAS LISTING /tmp/cc4NTrNa.s page 5 153 .loc 1 42 0 154 00c4 7000A210 beq $5,$2,$L51 155 00c8 0100023C li $2,65536 # 0x10000 156 157 00cc 3600A228 slt $2,$5,54 158 00d0 5F004010 beq $2,$0,$L37 159 00d4 36000224 li $2,54 # 0x36 160 161 00d8 33000224 li $2,51 # 0x33 162 00dc 1C00A214 bne $5,$2,$L34 163 00e0 00000000 nop 164 165 .loc 1 48 0 166 00e4 00800234 li $2,32768 # 0x8000 167 $L50: 168 .loc 1 47 0 169 00e8 04008524 addiu $5,$4,%lo(nand_device) 170 .loc 1 52 0 171 00ec 08000324 li $3,8 # 0x8 172 .loc 1 54 0 173 00f0 0800A2AC sw $2,8($5) 174 .loc 1 52 0 175 00f4 040083AC sw $3,%lo(nand_device)($4) 176 .loc 1 53 0 177 00f8 00020224 li $2,512 # 0x200 178 $L43: 71:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 2048; 72:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 1024 * 64; 73:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 1Gbit(128M) NAND */ 74:/mnt/hgfs/boot/booter/source/nand.c **** case 0xaa: 75:/mnt/hgfs/boot/booter/source/nand.c **** case 0xda: 76:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 77:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 2048; 78:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 2048 * 64; 79:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 2Gbit(256M) NAND */ 80:/mnt/hgfs/boot/booter/source/nand.c **** case 0xac: 81:/mnt/hgfs/boot/booter/source/nand.c **** case 0xdc: 82:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 83:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 2048; 84:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 4096 * 64; 85:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 4Gbit(512M) NAND */ 86:/mnt/hgfs/boot/booter/source/nand.c **** case 0xa3: 87:/mnt/hgfs/boot/booter/source/nand.c **** case 0xd3: 88:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 89:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 2048; 90:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 8192 * 64; 91:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 8Gbit(1G) NAND */ 92:/mnt/hgfs/boot/booter/source/nand.c **** case 0xa5: 93:/mnt/hgfs/boot/booter/source/nand.c **** case 0xd5: 94:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 8; 95:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 2048; 179 .loc 1 95 0 180 00fc 0400A2AC sw $2,4($5) 96:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 16384 * 64; 97:/mnt/hgfs/boot/booter/source/nand.c **** break; /* 16Gbit(2G) NAND */ 98:/mnt/hgfs/boot/booter/source/nand.c **** default: 99:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.data_width = 0;GAS LISTING /tmp/cc4NTrNa.s page 6 100:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_size = 0; 101:/mnt/hgfs/boot/booter/source/nand.c **** nand_device.page_count = 0; 102:/mnt/hgfs/boot/booter/source/nand.c **** return 0; 103:/mnt/hgfs/boot/booter/source/nand.c **** } 104:/mnt/hgfs/boot/booter/source/nand.c **** 105:/mnt/hgfs/boot/booter/source/nand.c **** return 1; 181 .loc 1 105 0 182 0100 01000424 li $4,1 # 0x1 183 $L14: 106:/mnt/hgfs/boot/booter/source/nand.c **** } 184 .loc 1 106 0 185 0104 0800E003 j $31 186 0108 21108000 move $2,$4 187 188 $L35: 189 .loc 1 88 0 190 .loc 1 42 0 191 010c 3F00A210 beq $5,$2,$L52 192 0110 0000043C lui $4,%hi(nand_device) 193 194 0114 D400A228 slt $2,$5,212 195 0118 15004010 beq $2,$0,$L39 196 011c DA000224 li $2,218 # 0xda 197 198 0120 A5000224 li $2,165 # 0xa5
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -