Changeset 445 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs
- Timestamp:
- Aug 29, 2012, 12:59:23 PM (12 years ago)
- google:author:
- krille_n_@hotmail.com
- Location:
- trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/AtaGeometry.asm
r423 r445 4 4 ; 5 5 ; These algorithms are taken from: http://www.mossywell.com/boot-sequence 6 ; Take a look at it for more detailed information. 6 ; Take a look at it for more detailed information. 7 7 ; 8 8 ; This file is shared with BIOS Drive Information Tool. 9 9 10 10 ; 11 ; XTIDE Universal BIOS and Associated Tools 11 ; XTIDE Universal BIOS and Associated Tools 12 12 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2012 by XTIDE Universal BIOS Team. 13 13 ; … … 16 16 ; the Free Software Foundation; either version 2 of the License, or 17 17 ; (at your option) any later version. 18 ; 18 ; 19 19 ; This program is distributed in the hope that it will be useful, 20 20 ; but WITHOUT ANY WARRANTY; without even the implied warranty of 21 21 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 ; GNU General Public License for more details. 22 ; GNU General Public License for more details. 23 23 ; Visit http://www.gnu.org/licenses/old-licenses/gpl-2.0.html 24 24 ; 25 25 26 26 ; Section containing code 27 27 SECTION .text … … 33 33 ; ES:SI: Ptr to 512-byte ATA information read from the drive 34 34 ; Returns: 35 ; BX:DX:AX: 48-bit secto hr count35 ; BX:DX:AX: 48-bit sector count 36 36 ; CL: FLGL_DPT_LBA48 if LBA48 supported 37 37 ; Zero if only LBA28 is supported … … 239 239 jbe SHORT ReturnLCHSinAXBLBH 240 240 shr ax, 1 ; Halve cylinders 241 shlbl, 1 ; Double heads241 eSHL_IM bl, 1 ; Double heads 242 242 inc cx ; Increment bit shift count 243 243 mov dl, TRANSLATEMODE_LARGE … … 300 300 cmp ax, cx 301 301 jbe SHORT .NumberOfHeadsNowInCX 302 shl cx, 1 ; Double number of heads 303 test ch, ch ; Reached 256 heads? 304 jz SHORT .CompareNextValidNumberOfHeads 305 dec cx ; If so, limit heads to 255 302 eSHL_IM cl, 1 ; Double number of heads 303 jnz SHORT .CompareNextValidNumberOfHeads ; Reached 256 heads? 304 dec cl ; If so, limit heads to 255 306 305 .NumberOfHeadsNowInCX: 307 306 mov bx, cx ; Number of heads are returned in BL -
trunk/XTIDE_Universal_BIOS/Src/VariablesAndDPTs/CreateDPT.asm
r422 r445 3 3 4 4 ; 5 ; XTIDE Universal BIOS and Associated Tools 5 ; XTIDE Universal BIOS and Associated Tools 6 6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2012 by XTIDE Universal BIOS Team. 7 7 ; … … 10 10 ; the Free Software Foundation; either version 2 of the License, or 11 11 ; (at your option) any later version. 12 ; 12 ; 13 13 ; This program is distributed in the hope that it will be useful, 14 14 ; but WITHOUT ANY WARRANTY; without even the implied warranty of 15 15 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 ; GNU General Public License for more details. 16 ; GNU General Public License for more details. 17 17 ; Visit http://www.gnu.org/licenses/old-licenses/gpl-2.0.html 18 ; 18 ; 19 19 20 20 ; Section containing code … … 145 145 146 146 ; Compare user defined and ATA-ID sector count and select smaller 147 xor dx, dx148 x chg bx, dx ; User defined LBA now in BX:DX:AX147 mov dx, bx 148 xor bx, bx ; User defined LBA now in BX:DX:AX 149 149 cmp bx, [di+DPT.twLbaSectors+4] 150 150 jb SHORT .StoreUserDefinedSectorCountToDPT
Note:
See TracChangeset
for help on using the changeset viewer.