Clean up DxeIpl:

1. Remove the assembly by using IoLib & BaseLib in MdePkg
2. Refine code to pass CYGWIN GCC tool chain build 

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7404 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
qhuang8
2009-02-03 00:48:56 +00:00
parent 3eb90413ba
commit 9008db4a28
14 changed files with 232 additions and 384 deletions

View File

@@ -542,21 +542,6 @@ STATUS_CODE_LOOKUP_TABLE mOperationToken[] = {
};
//
// Private function declarations
//
UINT8
CpuIoRead8 (
UINT16 Port
);
VOID
CpuIoWrite8 (
UINT16 Port,
UINT32 Data
);
EFI_STATUS
MatchString (
IN STATUS_CODE_LOOKUP_TABLE *Table,
@@ -648,10 +633,10 @@ Returns:
// Wait for the serail port to be ready.
//
do {
Data = CpuIoRead8 ((UINT16) (gComBase + LSR_OFFSET));
Data = IoRead8 (gComBase + LSR_OFFSET);
} while ((Data & LSR_TXRDY) == 0);
CpuIoWrite8 (gComBase, Character);
IoWrite8 (gComBase, Character);
}
VOID
@@ -865,19 +850,19 @@ Returns:
// Set communications format
//
OutputData = (UINT8)((DLAB << 7) | ((gBreakSet << 6) | ((gParity << 3) | ((gStop << 2) | Data))));
CpuIoWrite8 ((UINT16) (gComBase + LCR_OFFSET), OutputData);
IoWrite8 (gComBase + LCR_OFFSET, OutputData);
//
// Configure baud rate
//
CpuIoWrite8 ((UINT16) (gComBase + BAUD_HIGH_OFFSET), (UINT8)(Divisor >> 8));
CpuIoWrite8 ((UINT16) (gComBase + BAUD_LOW_OFFSET), (UINT8)(Divisor & 0xff));
IoWrite8 (gComBase + BAUD_HIGH_OFFSET, (UINT8)(Divisor >> 8));
IoWrite8 (gComBase + BAUD_LOW_OFFSET, (UINT8)(Divisor & 0xff));
//
// Switch back to bank 0
//
OutputData = (UINT8)((~DLAB<<7)|((gBreakSet<<6)|((gParity<<3)|((gStop<<2)| Data))));
CpuIoWrite8 ((UINT16) (gComBase + LCR_OFFSET), OutputData);
IoWrite8 (gComBase + LCR_OFFSET, OutputData);
*ReportStatusCode = SerialReportStatusCode;
}