Changeset 124
- Timestamp:
- Apr 8, 2017, 12:27:24 AM (8 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bootcode/regular/driveio.asm
r123 r124 878 878 ;# ACTION : Locates the Master LVM sector on the specified disk 879 879 ;# ---------------------------------------------------------------------------- 880 ;# EFFECTS : None880 ;# EFFECTS : Leaves [Scratch] with last sector read or cleared 881 881 ;# ---------------------------------------------------------------------------- 882 882 ;# IN : DL - BIOS disk number of drive to search … … 909 909 ; This is of course no problem since it is the MBR. 910 910 DriveIO_LocateMasterLVMSector_next: 911 mov si, offset [Scratch] ; Use scratch area to load sectors 912 call ClearSectorBuffer ; Clear the scratch area 911 913 clc ; Indicate Master LVM sector not found 912 914 jcxz DriveIO_LocateMasterLVMSector_done 913 915 914 ; Clear the sector buffer 915 mov bx, cx ; Save our precious sector LBA 916 mov cx, 100h ; Clear 256 words is 512 bytes 917 mov di, offset [TmpSector] ; Offset of buffer 918 xor ax, ax ; Value to sture 919 cld ; Increment DI each time 920 rep stosw ; Store the value 921 mov cx, bx ; Restore our precious sector LBA 922 923 ; Now read the LBA sector specified in CX 916 ; Read the LBA sector specified in CX 924 917 mov ax, cx ; LBA low 925 918 xor bx, bx ; LBA high 926 mov di, ds ; Segment of tempbuffer927 mov si, offset [ TmpSector] ; Offset of tempbuffer919 mov di, ds ; Segment of scratch buffer 920 mov si, offset [Scratch] ; Offset of scratch buffer 928 921 call DriveIO_ReadSectorLBA ; Read the sector 929 922 lahf ; Save CF … … 944 937 ; of the SPT value its OS/2 geometery specifies, which, in LBA terms 945 938 ; is LVM SPT-1 -- let's check that... 946 mov bx, offset [ TmpSector]; Offset of the loaded LVM sector939 mov bx, offset [Scratch] ; Offset of the loaded LVM sector 947 940 mov al, [bx+LocLVM_Secs] ; Get the LVM SPT value (<=255) 948 941 dec al ; Adjust to LVM LBA … … 950 943 inc ah ; This one was found here 951 944 cmp al, ah ; If same, LVM LBA location OK 952 call DEBUG_DumpRegisters953 945 jne DriveIO_LocateMasterLVMSector_next 954 946 -
trunk/bootcode/regular/other.asm
r123 r124 639 639 ; Check if a loaded sector is all zeros 640 640 ;------------------------------------------------------------------------------ 641 ; IN : BX pointer to memblock641 ; IN : SI pointer to sector buffer 642 642 ; OUT : ZF=1 block if all zeros 643 643 ; NOTE : Segment used is DS 644 644 ;------------------------------------------------------------------------------ 645 IsSectorZero Proc Near Uses cx 645 IsSectorBufferZero Proc Near Uses bx cx 646 mov bx, si ; Address of sector buffer 646 647 mov cx, sector_size ; Normal size of a sector (512 bytes) 647 648 call IsMemBlockZero ; Check the memory block 648 649 ret 649 IsSector ZeroEndP650 IsSectorBufferZero EndP 650 651 651 652 ;------------------------------------------------------------------------------ … … 685 686 ; Clears a sector buffer 686 687 ;------------------------------------------------------------------------------ 687 ; IN : BXpointer to sector buffer688 ; IN : SI pointer to sector buffer 688 689 ; OUT : Nothing 689 690 ; NOTE : Segment used is DS 690 691 ;------------------------------------------------------------------------------ 691 ClearSectorBuffer Proc Near Uses cx 692 ClearSectorBuffer Proc Near Uses bx cx 693 mov bx, si ; Address of sector buffer 692 694 mov cx, sector_size ; Normal size of a sector (512 bytes) 693 695 call ClearMemBlock ; Clear the sector buffer -
trunk/bootcode/special/lvm.asm
r123 r124 125 125 ; Destroyed: None 126 126 LVM_CheckSectorCRC Proc Near Uses ax bx dx 127 mov bx, si 128 call IsSectorZero ; Zero sector implies bad CRC 127 call IsSectorBufferZero ; Zero sector implies bad CRC 129 128 jz LVMCSCRC_BadCRC 130 129 call LVM_GetSectorCRC ; Only use after CRC table is valid -
trunk/include/version.h
r121 r124 32 32 #define BLDLVL_YEAR "2017" 33 33 #define BLDLVL_MONTH "03" 34 #define BLDLVL_DAY "2 7"34 #define BLDLVL_DAY "28" 35 35 // Build time 36 36 //~ #define BLDLVL_HOURS "01" -
trunk/include/version.inc
r121 r124 70 70 AB_YEAR EQU 2017h 71 71 AB_MONTH EQU 03h 72 AB_DAY EQU 2 7h72 AB_DAY EQU 28h 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.