Changeset 118
- Timestamp:
- Apr 8, 2017, 12:27:17 AM (8 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bootcode/regular/bootmenu.asm
r117 r118 721 721 722 722 mov dl, byte ptr [si+LocIPT_Drive] 723 mov cx, [si+LocIPT_AbsoluteBegin+00h]723 mov ax, [si+LocIPT_AbsoluteBegin+00h] 724 724 mov bx, [si+LocIPT_AbsoluteBegin+02h] 725 725 -
trunk/bootcode/regular/driveio.asm
r117 r118 741 741 742 742 mov di, ds ; segment for transfer address 743 mov cx, ax ; low word of lba744 743 call DriveIO_ReadSectorLBA ; extended read 745 744 jc DriveIO_GotLoadError ; halt on error … … 792 791 ;# EFFECTS : Modifies DAP structure and fills transfer buffer 793 792 ;# ---------------------------------------------------------------------------- 794 ;# IN : BX: CX - LBA address of sector793 ;# IN : BX:AX - LBA address of sector 795 794 ;# : DI:SI - SEG:OFF of transfer buffer 796 795 ;# ---------------------------------------------------------------------------- 797 ;# OUT : CF=1 - failure , AH failure code796 ;# OUT : CF=1 - failure 798 797 ;############################################################################## 799 DriveIO_ReadSectorLBA Proc Near Uses bx cx dx si di ds es798 DriveIO_ReadSectorLBA Proc Near 800 799 801 800 IFDEF AUX_DEBUG … … 818 817 ENDIF 819 818 819 ; Push all registers 820 pusha 821 push ds 822 push es 823 820 824 ; One sector to read 821 825 mov cs:[INT13X_DAP_NumBlocks], 1 … … 826 830 827 831 ; Setup LBA64 address of requested sector 828 mov wptr cs:[INT13X_DAP_Absolute+0], cx ; low word lower part832 mov wptr cs:[INT13X_DAP_Absolute+0], ax ; low word lower part 829 833 mov wptr cs:[INT13X_DAP_Absolute+2], bx ; high word lower part 830 834 mov wptr cs:[INT13X_DAP_Absolute+4], 0 ; low word upper part … … 850 854 851 855 DriveIO_ReadSectorLBA_exit: 852 ret 853 856 857 ; Pop all registers 858 pop es 859 pop ds 860 popa 861 862 ret 854 863 DriveIO_ReadSectorLBA EndP 855 864 … … 861 870 ;# EFFECTS : Modifies DAP structure and mofifies the disk 862 871 ;# ---------------------------------------------------------------------------- 863 ;# IN : AL - write flags, AL.0 verify (1.0,2.0), AL.1 verify (2.1+) 864 ;# : BX:CX - LBA address of sector 872 ;# IN : BX:AX - LBA address of sector 865 873 ;# : DI:SI - SEG:OFF of transfer buffer 866 874 ;# ---------------------------------------------------------------------------- 867 ;# OUT : CF=1 - failure , AH failure code875 ;# OUT : CF=1 - failure 868 876 ;############################################################################## 869 DriveIO_WriteSectorLBA Proc Near Uses bx cx dx si di ds es877 DriveIO_WriteSectorLBA Proc Near 870 878 871 879 IFDEF AUX_DEBUG … … 886 894 ENDIF 887 895 888 ; Mask reserved bits for write flags -- should check version here 889 and al, 03h 890 891 ; Actually, force 'no-write-verify' for now... 892 xor al, al 896 ; Push all registers 897 pusha 898 push ds 899 push es 893 900 894 901 ; One sector to read … … 900 907 901 908 ; Setup LBA64 address of requested sector 902 mov wptr cs:[INT13X_DAP_Absolute+0], cx ; low word lower part909 mov wptr cs:[INT13X_DAP_Absolute+0], ax ; low word lower part 903 910 mov wptr cs:[INT13X_DAP_Absolute+2], bx ; high word lower part 904 911 mov wptr cs:[INT13X_DAP_Absolute+4], 0 ; low word upper part … … 909 916 910 917 ; Do the extended write 918 xor al, al ; no write verify 911 919 mov ah, 43h ; write function 912 920 int 13h ; transfer to bios … … 924 932 925 933 DriveIO_WriteSectorLBA_exit: 926 ret 927 934 935 ; Pop all registers 936 pop es 937 pop ds 938 popa 939 940 ret 928 941 DriveIO_WriteSectorLBA EndP 929 942 … … 1017 1030 1018 1031 ; Now read the LBA sector specified in CX 1019 xor bx, bx ; LBA high, CX already has LBA low 1032 mov ax, cx ; LBA low 1033 xor bx, bx ; LBA high 1020 1034 mov di, ds ; Segment of temp buffer 1021 1035 mov si, offset [TmpSector] ; Offset of temp buffer … … 1054 1068 ; For now we assume this is the correct Master LVM sector for the disk. 1055 1069 inc cx ; CX was prepared to read next, correct that 1056 stc ; Indicate we have found aMaster LVM sector1070 stc ; Indicate we have found the Master LVM sector 1057 1071 1058 1072 DriveIO_LocateMasterLVMSector_done: … … 1364 1378 1365 1379 mov di, ds ; segment for transfer address 1366 mov cx, ax ; low word of lba1367 xor ax, ax ; no verify1368 1380 call DriveIO_WriteSectorLBA ; extended write 1369 1381 jc MBR_SaveError ; halt on error -
trunk/bootcode/regular/partmain.asm
r117 r118 2263 2263 ; Load LBA sector 0 from the disk specified in DL 2264 2264 xor bx,bx 2265 xor cx,cx2265 xor ax,ax 2266 2266 mov di,ds 2267 2267 mov si,offset [TmpSector] … … 2467 2467 ; mov di,ds 2468 2468 ; mov si,offset [TmpSector] 2469 ; mov ax, cx ; LBA low is now in AX 2469 2470 ; call DriveIO_ReadSectorLBA 2470 2471 -
trunk/bootcode/special/lvm.asm
r117 r118 320 320 mov si,offset [LVMSector] 321 321 mov di,ds 322 mov ax, cx ; LBA low is now in AX 322 323 call DriveIO_ReadSectorLBA 323 324 pop di … … 541 542 mov si,offset [LVMSector] 542 543 mov di,ds 544 mov ax, cx ; LBA low is now in AX 543 545 call DriveIO_ReadSectorLBA 544 546 pop di -
trunk/include/version.h
r113 r118 32 32 #define BLDLVL_YEAR "2017" 33 33 #define BLDLVL_MONTH "03" 34 #define BLDLVL_DAY "2 4"34 #define BLDLVL_DAY "25" 35 35 // Build time 36 36 //~ #define BLDLVL_HOURS "01" -
trunk/include/version.inc
r113 r118 70 70 AB_YEAR EQU 2017h 71 71 AB_MONTH EQU 03h 72 AB_DAY EQU 2 4h72 AB_DAY EQU 25h 73 73 74 74 ; The Hours, Minutes and Seconds, again in BCD for easy manipulation.
Note:
See TracChangeset
for help on using the changeset viewer.