⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 diskmain.cod

📁 PXA270的BSP
💻 COD
📖 第 1 页 / 共 5 页
字号:
; 453  : 		
; 454  : 		if(!IdeIsBusy())		
; 455  : 			break;
; 456  : 	}
; 457  : 	  
; 458  : 	if ( i>=10 )
; 459  : 		{
; 460  : 		   RETAILMSG(1,(TEXT("WriteCommand failed\r\n")));
; 461  : 		}
; 462  : 		*/
; 463  : 		
; 464  :     }

  0000c	e49de004	 ldr         lr, [sp], #4
  00010	e12fff1e	 bx          lr
  00014		 |$L33505|
  00014	b6a000e0	 DCD         0xb6a000e0
  00018		 |$M33501|

			 ENDP  ; |?WriteCommand@CDisk@@QAAXE@Z|, CDisk::WriteCommand

	EXPORT	|?WriteSectorCount@CDisk@@QAAXE@Z|	; CDisk::WriteSectorCount

  00000			 AREA	 |.text| { |?WriteSectorCount@CDisk@@QAAXE@Z| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?WriteSectorCount@CDisk@@QAAXE@Z|, PDATA, SELECTION=5, ASSOC=|.text| { |?WriteSectorCount@CDisk@@QAAXE@Z| } ; comdat associative
|$T33512| DCD	|$L33511|
	DCD	0x40000601
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?WriteSectorCount@CDisk@@QAAXE@Z| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?WriteSectorCount@CDisk@@QAAXE@Z| PROC ; CDisk::WriteSectorCount

; 473  :     	{

  00000		 |$L33511|
  00000	e52de004	 str         lr, [sp, #-4]!
  00004		 |$M33509|

; 474  :     	    ATA_WRITE_BYTE((volatile PBYTE)m_pATAReg + m_dwSectCntReasonOffset, bValue);

  00004	e59f0008	 ldr         r0, [pc, #8]
  00008	eb000000	 bl          WRITE_PORT_UCHAR

; 475  :     	}

  0000c	e49de004	 ldr         lr, [sp], #4
  00010	e12fff1e	 bx          lr
  00014		 |$L33514|
  00014	b6a00040	 DCD         0xb6a00040
  00018		 |$M33510|

			 ENDP  ; |?WriteSectorCount@CDisk@@QAAXE@Z|, CDisk::WriteSectorCount

	EXPORT	|?ReadByteBuffer@CDisk@@QAAXPAEK@Z|	; CDisk::ReadByteBuffer
	IMPORT	|READ_PORT_BUFFER_UCHAR|

  00000			 AREA	 |.text| { |?ReadByteBuffer@CDisk@@QAAXPAEK@Z| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?ReadByteBuffer@CDisk@@QAAXPAEK@Z|, PDATA, SELECTION=5, ASSOC=|.text| { |?ReadByteBuffer@CDisk@@QAAXPAEK@Z| } ; comdat associative
|$T33522| DCD	|$L33521|
	DCD	0x40000601
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?ReadByteBuffer@CDisk@@QAAXPAEK@Z| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?ReadByteBuffer@CDisk@@QAAXPAEK@Z| PROC ; CDisk::ReadByteBuffer

; 509  : 	 inline void ReadByteBuffer(PBYTE pBuffer, DWORD dwCount) {

  00000		 |$L33521|
  00000	e52de004	 str         lr, [sp, #-4]!
  00004		 |$M33519|

; 510  :         READ_PORT_BUFFER_UCHAR( (volatile PBYTE) m_pATAReg + m_dwDataDrvCtrlOffset, pBuffer, dwCount);

  00004	e3a004b6	 mov         r0, #0xB6, 8
  00008	e380060a	 orr         r0, r0, #0xA, 12
  0000c	eb000000	 bl          READ_PORT_BUFFER_UCHAR

; 511  :     }

  00010	e49de004	 ldr         lr, [sp], #4
  00014	e12fff1e	 bx          lr
  00018		 |$M33520|

			 ENDP  ; |?ReadByteBuffer@CDisk@@QAAXPAEK@Z|, CDisk::ReadByteBuffer

	EXPORT	|?IsAtapiDevice@CDisk@@QAAHXZ|		; CDisk::IsAtapiDevice

  00000			 AREA	 |.text| { |?IsAtapiDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?IsAtapiDevice@CDisk@@QAAHXZ|, PDATA, SELECTION=5, ASSOC=|.text| { |?IsAtapiDevice@CDisk@@QAAHXZ| } ; comdat associative
|$T33532| DCD	|$L33531|
	DCD	0x40000200
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?IsAtapiDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?IsAtapiDevice@CDisk@@QAAHXZ| PROC	; CDisk::IsAtapiDevice

; 526  :     {

  00000		 |$L33531|
  00000		 |$M33529|

; 527  : //        return (m_Id.GeneralConfiguration & IDE_IDDATA_ATAPI_DEVICE);
; 528  :         return m_fAtapiDevice;

  00000	e5900644	 ldr         r0, [r0, #0x644]

; 529  :     }    

  00004	e12fff1e	 bx          lr
  00008		 |$M33530|

			 ENDP  ; |?IsAtapiDevice@CDisk@@QAAHXZ|, CDisk::IsAtapiDevice

	EXPORT	|?AtapiSoftReset@CDisk@@QAAXXZ|		; CDisk::AtapiSoftReset
	IMPORT	|?WaitForDisc@CDisk@@QAAHEKK@Z|		; CDisk::WaitForDisc

  00000			 AREA	 |.text| { |?AtapiSoftReset@CDisk@@QAAXXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?AtapiSoftReset@CDisk@@QAAXXZ|, PDATA, SELECTION=5, ASSOC=|.text| { |?AtapiSoftReset@CDisk@@QAAXXZ| } ; comdat associative
|$T33544| DCD	|$L33543|
	DCD	0x40001201
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?AtapiSoftReset@CDisk@@QAAXXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?AtapiSoftReset@CDisk@@QAAXXZ| PROC	; CDisk::AtapiSoftReset

; 531  :     {

  00000		 |$L33543|
  00000	e92d4010	 stmdb       sp!, {r4, lr}
  00004		 |$M33541|
  00004	e1a04000	 mov         r4, r0

; 532  :         WriteCommand( ATAPI_CMD_SOFT_RESET);

  00008	e59f0034	 ldr         r0, [pc, #0x34]
  0000c	e3a01008	 mov         r1, #8
  00010	eb000000	 bl          WRITE_PORT_UCHAR

; 533  :         WaitForDisc(WAIT_TYPE_NOT_BUSY,400);

  00014	e3a03000	 mov         r3, #0
  00018	e3a02e19	 mov         r2, #0x19, 28
  0001c	e3a01002	 mov         r1, #2
  00020	e1a00004	 mov         r0, r4
  00024	eb000000	 bl          |?WaitForDisc@CDisk@@QAAHEKK@Z|

; 534  :         WaitForDisc(WAIT_TYPE_READY,500);

  00028	e3a03000	 mov         r3, #0
  0002c	e3a02f7d	 mov         r2, #0x7D, 30
  00030	e3a01003	 mov         r1, #3
  00034	e1a00004	 mov         r0, r4
  00038	eb000000	 bl          |?WaitForDisc@CDisk@@QAAHEKK@Z|

; 535  :     }

  0003c	e8bd4010	 ldmia       sp!, {r4, lr}
  00040	e12fff1e	 bx          lr
  00044		 |$L33546|
  00044	b6a000e0	 DCD         0xb6a000e0
  00048		 |$M33542|

			 ENDP  ; |?AtapiSoftReset@CDisk@@QAAXXZ|, CDisk::AtapiSoftReset

	EXPORT	|?IsCDRomDevice@CDisk@@QAAHXZ|		; CDisk::IsCDRomDevice

  00000			 AREA	 |.text| { |?IsCDRomDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?IsCDRomDevice@CDisk@@QAAHXZ|, PDATA, SELECTION=5, ASSOC=|.text| { |?IsCDRomDevice@CDisk@@QAAHXZ| } ; comdat associative
|$T33557| DCD	|$L33556|
	DCD	0x40000800
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?IsCDRomDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?IsCDRomDevice@CDisk@@QAAHXZ| PROC	; CDisk::IsCDRomDevice

; 538  :     {

  00000		 |$L33556|
  00000		 |$M33554|

; 539  :         return (((m_Id.GeneralConfiguration >> 8) & 0x1f) == ATA_IDDEVICE_CDROM);

  00000	e5d02444	 ldrb        r2, [r0, #0x444]
  00004	e5d03445	 ldrb        r3, [r0, #0x445]
  00008	e1823403	 orr         r3, r2, r3, lsl #8
  0000c	e2033c1f	 and         r3, r3, #0x1F, 24
  00010	e3530c05	 cmp         r3, #5, 24
  00014	03a00001	 moveq       r0, #1
  00018	13a00000	 movne       r0, #0

; 540  :     }    

  0001c	e12fff1e	 bx          lr
  00020		 |$M33555|

			 ENDP  ; |?IsCDRomDevice@CDisk@@QAAHXZ|, CDisk::IsCDRomDevice

	EXPORT	|?IsRemoveableDevice@CDisk@@QAAHXZ|	; CDisk::IsRemoveableDevice

  00000			 AREA	 |.text| { |?IsRemoveableDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?IsRemoveableDevice@CDisk@@QAAHXZ|, PDATA, SELECTION=5, ASSOC=|.text| { |?IsRemoveableDevice@CDisk@@QAAHXZ| } ; comdat associative
|$T33567| DCD	|$L33566|
	DCD	0x40000500
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?IsRemoveableDevice@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?IsRemoveableDevice@CDisk@@QAAHXZ| PROC ; CDisk::IsRemoveableDevice

; 553  :     {

  00000		 |$L33566|
  00000		 |$M33564|

; 554  :         return (m_Id.GeneralConfiguration & IDE_IDDATA_REMOVABLE);

  00000	e5d02444	 ldrb        r2, [r0, #0x444]
  00004	e5d03445	 ldrb        r3, [r0, #0x445]
  00008	e1823403	 orr         r3, r2, r3, lsl #8
  0000c	e2030080	 and         r0, r3, #0x80

; 555  :     }    

  00010	e12fff1e	 bx          lr
  00014		 |$M33565|

			 ENDP  ; |?IsRemoveableDevice@CDisk@@QAAHXZ|, CDisk::IsRemoveableDevice

	EXPORT	|?IsDMASupported@CDisk@@QAAHXZ|		; CDisk::IsDMASupported

  00000			 AREA	 |.text| { |?IsDMASupported@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000			 AREA	 |.pdata$$?IsDMASupported@CDisk@@QAAHXZ|, PDATA, SELECTION=5, ASSOC=|.text| { |?IsDMASupported@CDisk@@QAAHXZ| } ; comdat associative
|$T33582| DCD	|$L33581|
	DCD	0x40001800
; Function compile flags: /Ogsy

  00000			 AREA	 |.text| { |?IsDMASupported@CDisk@@QAAHXZ| }, CODE, ARM, SELECTION=2 ; comdat any

  00000		 |?IsDMASupported@CDisk@@QAAHXZ| PROC	; CDisk::IsDMASupported

; 566  :     {

  00000		 |$L33581|
  00000		 |$M33579|

; 567  :         return ((m_Id.Capabilities & IDENTIFY_CAPABILITIES_DMA_SUPPORTED) && m_fDMAActive &&
; 568  :                 (((int)m_dwBestUDmaMode!=-1 && m_fUDMAActive) || ((int)m_dwBestMwDmaMode!=-1 && !m_fUDMAActive )));

  00000	e5d024a6	 ldrb        r2, [r0, #0x4A6]
  00004	e5d034a7	 ldrb        r3, [r0, #0x4A7]
  00008	e1823403	 orr         r3, r2, r3, lsl #8
  0000c	e3130c01	 tst         r3, #1, 24
  00010	0a000010	 beq         |$L33571|
  00014	e5903648	 ldr         r3, [r0, #0x648]
  00018	e3530000	 cmp         r3, #0
  0001c	0a00000d	 beq         |$L33571|
  00020	e59036b0	 ldr         r3, [r0, #0x6B0]
  00024	e3730001	 cmn         r3, #1
  00028	0a000002	 beq         |$L33572|
  0002c	e59036b8	 ldr         r3, [r0, #0x6B8]
  00030	e3530000	 cmp         r3, #0
  00034	1a000005	 bne         |$L33574|
  00038		 |$L33572|
  00038	e59036ac	 ldr         r3, [r0, #0x6AC]
  0003c	e3730001	 cmn         r3, #1
  00040	0a000004	 beq         |$L33571|
  00044	e59036b8	 ldr         r3, [r0, #0x6B8]
  00048	e3530000	 cmp         r3, #0
  0004c	1a000001	 bne         |$L33571|
  00050		 |$L33574|
  00050	e3a00001	 mov         r0, #1

; 569  :     }    

  00054	e12fff1e	 bx          lr
  00058		 |$L33571|

; 567  :         return ((m_Id.Capabilities & IDENTIFY_CAPABILITIES_DMA_SUPPORTED) && m_fDMAActive &&
; 568  :                 (((int)m_dwBestUDmaMode!=-1 && m_fUDMAActive) || ((int)m_dwBestMwDmaMode!=-1 && !m_fUDMAActive )));

  00058	e3a00000	 mov         r0, #0

; 569  :     }    

  0005c	e12fff1e	 bx          lr
  00060		 |$M33580|

			 ENDP  ; |?IsDMASupported@CDisk@@QAAHXZ|, CDisk::IsDMASupported

	EXPORT	|?ResetController@CDisk@@QAAHH@Z|	; CDisk::ResetController

  00000			 AREA	 |.text| { |?ResetController@CDisk@@QAAHH@Z| }, CODE, ARM, SELECTION=1 ; comdat noduplicate

  00000			 AREA	 |.pdata$$?ResetController@CDisk@@QAAHH@Z|, PDATA, SELECTION=5, ASSOC=|.text| { |?ResetController@CDisk@@QAAHH@Z| } ; comdat associative
|$T33630| DCD	|$L33629|
	DCD	0x40004e01
; Function compile flags: /Ogsy
; File d:\wince500\platform\bvdmain\drivers\atapi\diskmain.cpp

  00000			 AREA	 |.text| { |?ResetController@CDisk@@QAAHH@Z| }, CODE, ARM, SELECTION=1 ; comdat noduplicate

  00000		 |?ResetController@CDisk@@QAAHH@Z| PROC	; CDisk::ResetController

; 174  : {

  00000		 |$L33629|
  00000	e92d4030	 stmdb       sp!, {r4, r5, lr}
  00004		 |$M33627|
  00004	e1a04001	 mov         r4, r1
  00008	e1a05000	 mov         r5, r0

; 175  :     DWORD dwAttempts;
; 176  :     BYTE   bStatus;
; 177  :     
; 178  : 
; 179  :     DEBUGMSG(ZONE_INIT, (TEXT("ATAPI:ResetController entered\r\n")));
; 180  : 
; 181  : 
; 182  : //    WriteAltDriveController( 0x8);
; 183  :     // Read the status first
; 184  :     bStatus = GetBaseStatus();

  0000c	e59f0118	 ldr         r0, [pc, #0x118]
  00010	eb000000	 bl          READ_PORT_UCHAR

; 185  : //    DEBUGMSG(ZONE_INIT, (TEXT("ATADISK:ResetController - ATA_STATUS = %02X Error=%x!\r\n"), bStatus, GetError()));
; 186  : 
; 187  :     //
; 188  :     // We select the secondary device , that way we will get a response through the shadow
; 189  :     // if only the master is connected.  Otherwise we will get a response from
; 190  :     // the secondary device
; 191  :     //
; 192  :     
; 193  :     WriteAltDriveController(ATA_CTRL_RESET | ATA_CTRL_DISABLE_INTR);

  00014	e59f0118	 ldr         r0, [pc, #0x118]
  00018	e3a01006	 mov         r1, #6
  0001c	eb000000	 bl          WRITE_PORT_UCHAR

; 194  :     
; 195  :     WaitForDisc( WAIT_TYPE_BUSY, 500);

  00020	e3a03000	 mov         r3, #0
  00024	e3a02f7d	 mov         r2, #0x7D, 30
  00028	e3a01001	 mov         r1, #1
  0002c	e1a00005	 mov         r0, r5
  00030	eb000000	 bl          |?WaitForDisc@CDisk@@QAAHEKK@Z|

; 196  :     
; 197  :     WriteAltDriveController(ATA_CTRL_DISABLE_INTR);

  00034	e59f00f8	 ldr         r0, [pc, #0xF8]
  00038	e3a01002	 mov         r1, #2
  0003c	eb000000	 bl          WRITE_PORT_UCHAR

; 198  : 
; 199  :     WaitForDisc( WAIT_TYPE_READY, 400);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -