Index: trunk/XTIDE_Universal_BIOS/Src/Boot/BootMenuPrintCfg.asm
===================================================================
--- trunk/XTIDE_Universal_BIOS/Src/Boot/BootMenuPrintCfg.asm	(revision 127)
+++ trunk/XTIDE_Universal_BIOS/Src/Boot/BootMenuPrintCfg.asm	(revision 150)
@@ -17,5 +17,5 @@
 ;		Nothing
 ;	Corrupts registers:
-;		AX, BX, CX, DX, SI, DI, ES
+;		AX, BX, CX, DX, SI, DI
 ;--------------------------------------------------------------------
 ALIGN JUMP_ALIGN
@@ -24,7 +24,7 @@
 	mov		si, g_szCfgHeader
 	call	BootMenuPrint_NullTerminatedStringFromCSSIandSetCF
-	call	BootMenuPrintCfg_GetPointers
+	eMOVZX	ax, BYTE [di+DPT.bIdevarsOffset]
+	xchg	si, ax						; CS:SI now points to IDEVARS
 	; Fall to PushAndFormatCfgString
-
 
 ;--------------------------------------------------------------------
@@ -32,5 +32,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -48,5 +47,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -56,18 +54,6 @@
 ;--------------------------------------------------------------------
 PushAddressingMode:
-	xchg	ax, bx
-	mov		bx, MASK_DPT_ADDR	; Load addressing mode mask
-	and		bl, [di+DPT.bFlags]	; Addressing mode now in BX
-	push	WORD [cs:bx+.rgszAddressingModeString]
-	xchg	bx, ax
-	jmp		SHORT .NextPush
-ALIGN WORD_ALIGN
-.rgszAddressingModeString:
-	dw		g_szLCHS
-	dw		g_szPCHS
-	dw		g_szLBA28
-	dw		g_szLBA48
-ALIGN JUMP_ALIGN
-.NextPush:
+	call	AccessDPT_GetAddressingModeForWordLookToBX
+	push	WORD [cs:bx+rgszAddressingModeString]
 
 ;--------------------------------------------------------------------
@@ -75,5 +61,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -83,5 +68,9 @@
 ;--------------------------------------------------------------------
 PushBlockMode:
-	eMOVZX	ax, BYTE [di+DPT.bSetBlock]
+	mov		ax, 1
+	test	WORD [di+DPT.wFlags], FLG_DPT_BLOCK_MODE_SUPPORTED
+	jz		SHORT .PushBlockSizeFromAX
+	mov		al, [di+DPT_ATA.bSetBlock]
+.PushBlockSizeFromAX:
 	push	ax
 
@@ -90,5 +79,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -99,19 +87,10 @@
 PushBusType:
 	xchg	ax, bx		; Store BX to AX
-	eMOVZX	bx, BYTE [cs:si+IDEVARS.bBusType]
-	mov		bx, [cs:bx+.rgwBusTypeValues]	; Char to BL, Int to BH
+	eMOVZX	bx, BYTE [cs:si+IDEVARS.bDevice]
+	mov		bx, [cs:bx+rgwBusTypeValues]	; Char to BL, Int to BH
 	eMOVZX	dx, bh
 	push	bx			; Push character
-	push	dx			; Push 8, 16 or 32
+	push	dx			; Push 1, 8, 16 or 32
 	xchg	bx, ax		; Restore BX
-	jmp		SHORT .NextPush
-ALIGN WORD_ALIGN
-.rgwBusTypeValues:
-	db		'D', 8		; BUS_TYPE_8_DUAL
-	db		' ', 16		; BUS_TYPE_16
-	db		' ', 32		; BUS_TYPE_32
-	db		'S', 8		; BUS_TYPE_8_SINGLE
-ALIGN JUMP_ALIGN
-.NextPush:
 
 ;--------------------------------------------------------------------
@@ -119,5 +98,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -152,5 +130,4 @@
 ;	Parameters:
 ;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
 ;		CS:SI:	Ptr to IDEVARS
 ;	Returns:
@@ -160,5 +137,6 @@
 ;--------------------------------------------------------------------
 PushResetStatus:
-	eMOVZX	ax, BYTE [di+DPT.bReset]
+	mov		ax, [di+DPT.wFlags]
+	and		ax, MASK_DPT_RESET
 	push	ax
 
@@ -177,21 +155,16 @@
 
 
-;--------------------------------------------------------------------
-; BootMenuPrintCfg_GetPointers
-;	Parameters:
-;		DS:DI:	Ptr to DPT
-;	Returns:
-;		DS:DI:	Ptr to DPT
-;		ES:BX:	Ptr to BOOTNFO
-;		CS:SI:	Ptr to IDEVARS
-;	Corrupts registers:
-;		AX, DL
-;--------------------------------------------------------------------
-ALIGN JUMP_ALIGN
-BootMenuPrintCfg_GetPointers:
-	mov		dl, [di+DPT.bDrvNum]		; Load Drive number to DL
-	call	BootInfo_GetOffsetToBX		; ES:BX now points...
-	LOAD_BDA_SEGMENT_TO	es, ax, !		; ...to BOOTNFO
-	mov		al, [di+DPT.bIdeOff]
-	xchg	si, ax						; CS:SI now points to IDEVARS
-	ret
+ALIGN WORD_ALIGN
+rgszAddressingModeString:
+	dw		g_szLCHS
+	dw		g_szPCHS
+	dw		g_szLBA28
+	dw		g_szLBA48
+
+rgwBusTypeValues:
+	db		'D', 8		; DEVICE_8BIT_DUAL_PORT_XTIDE
+	db		'X', 8		; DEVICE_XTIDE_WITH_REVERSED_A3_AND_A0
+	db		'S', 8		; DEVICE_8BIT_SINGLE_PORT
+	db		' ', 16		; DEVICE_16BIT_ATA
+	db		' ', 32		; DEVICE_32BIT_ATA
+	db		' ', 1		; DEVICE_SERIAL_PORT
