mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-28 16:14:04 +02:00
Fix the errors detected by the GCC compiler:
* Add EFIAPI to the timer callbacks * Fix 32-bit pointer casts Signed-off-by: lpleahy git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13024 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
7700f0f5c0
commit
53c31c5164
@ -834,6 +834,7 @@ SocketPoll (
|
|||||||
@param [in] pContext Context for this routine
|
@param [in] pContext Context for this routine
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
|
EFIAPI
|
||||||
TimerCallback (
|
TimerCallback (
|
||||||
IN EFI_EVENT Event,
|
IN EFI_EVENT Event,
|
||||||
IN VOID * pContext
|
IN VOID * pContext
|
||||||
|
@ -1318,6 +1318,7 @@ Tcp4Open (
|
|||||||
@param [in] pContext Context for this routine
|
@param [in] pContext Context for this routine
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
|
EFIAPI
|
||||||
TimerCallback (
|
TimerCallback (
|
||||||
IN EFI_EVENT Event,
|
IN EFI_EVENT Event,
|
||||||
IN VOID * pContext
|
IN VOID * pContext
|
||||||
|
@ -65,7 +65,7 @@ main (
|
|||||||
Print ( L"ERROR - network not found, errno: %d\r\n", errno );
|
Print ( L"ERROR - network not found, errno: %d\r\n", errno );
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
pIpAddress = (UINT8 *)pNetwork->n_net;
|
pIpAddress = (UINT8 *)(UINTN)&pNetwork->n_net;
|
||||||
Print ( L"%a: Type %d, %d.%d.%d.%d\r\n",
|
Print ( L"%a: Type %d, %d.%d.%d.%d\r\n",
|
||||||
pNetwork->n_name,
|
pNetwork->n_name,
|
||||||
pNetwork->n_addrtype,
|
pNetwork->n_addrtype,
|
||||||
|
@ -180,14 +180,14 @@ LocateRsdt (
|
|||||||
//
|
//
|
||||||
Status = EfiGetSystemConfigurationTable ( &gEfiAcpiTableGuid, (VOID **)&pRsdp30 );
|
Status = EfiGetSystemConfigurationTable ( &gEfiAcpiTableGuid, (VOID **)&pRsdp30 );
|
||||||
if ( !EFI_ERROR ( Status )) {
|
if ( !EFI_ERROR ( Status )) {
|
||||||
pRsdt = (ACPI_RSDT *)pRsdp30->RsdtAddress;
|
pRsdt = (ACPI_RSDT *)(UINTN)pRsdp30->RsdtAddress;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Status = EfiGetSystemConfigurationTable (&gEfiAcpi10TableGuid, (VOID **)&pRsdp10b );
|
Status = EfiGetSystemConfigurationTable (&gEfiAcpi10TableGuid, (VOID **)&pRsdp10b );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pRsdt = (ACPI_RSDT *)pRsdp10b->RsdtAddress;
|
pRsdt = (ACPI_RSDT *)(UINTN)pRsdp10b->RsdtAddress;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -229,14 +229,14 @@ LocateTable (
|
|||||||
//
|
//
|
||||||
Status = EfiGetSystemConfigurationTable ( &gEfiAcpiTableGuid, (VOID **)&pRsdp30 );
|
Status = EfiGetSystemConfigurationTable ( &gEfiAcpiTableGuid, (VOID **)&pRsdp30 );
|
||||||
if ( !EFI_ERROR ( Status )) {
|
if ( !EFI_ERROR ( Status )) {
|
||||||
pRsdt = (ACPI_RSDT *)pRsdp30->RsdtAddress;
|
pRsdt = (ACPI_RSDT *)(UINTN)pRsdp30->RsdtAddress;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Status = EfiGetSystemConfigurationTable (&gEfiAcpi10TableGuid, (VOID **)&pRsdp10b );
|
Status = EfiGetSystemConfigurationTable (&gEfiAcpi10TableGuid, (VOID **)&pRsdp10b );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pRsdt = (ACPI_RSDT *)pRsdp10b->RsdtAddress;
|
pRsdt = (ACPI_RSDT *)(UINTN)pRsdp10b->RsdtAddress;
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -249,9 +249,9 @@ LocateTable (
|
|||||||
// The entry is actually a 32-bit physical table address
|
// The entry is actually a 32-bit physical table address
|
||||||
// The first entry in the table is the 32-bit table signature
|
// The first entry in the table is the 32-bit table signature
|
||||||
//
|
//
|
||||||
pSignature = (UINT32 *)*pEntry;
|
pSignature = (UINT32 *)(UINTN)*pEntry;
|
||||||
if ( *pSignature == Signature ) {
|
if ( *pSignature == Signature ) {
|
||||||
return (CONST VOID *) *pEntry;
|
return (CONST VOID *)(UINTN)*pEntry;
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -1082,7 +1082,7 @@ AcpiFadtPage (
|
|||||||
Status = RowPointer ( SocketFD,
|
Status = RowPointer ( SocketFD,
|
||||||
pPort,
|
pPort,
|
||||||
"FIRMWARE_CTRL",
|
"FIRMWARE_CTRL",
|
||||||
(CONST VOID *)pFadt->FirmwareCtrl,
|
(CONST VOID *)(UINTN)pFadt->FirmwareCtrl,
|
||||||
NULL );
|
NULL );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
@ -1090,7 +1090,7 @@ AcpiFadtPage (
|
|||||||
Status = RowPointer ( SocketFD,
|
Status = RowPointer ( SocketFD,
|
||||||
pPort,
|
pPort,
|
||||||
"DSDT",
|
"DSDT",
|
||||||
(CONST VOID *)pFadt->DSDT,
|
(CONST VOID *)(UINTN)pFadt->DSDT,
|
||||||
( pFadt->DSDT == pFadt->XDsdt ) ? PAGE_ACPI_DSDT : NULL );
|
( pFadt->DSDT == pFadt->XDsdt ) ? PAGE_ACPI_DSDT : NULL );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
@ -1593,7 +1593,7 @@ AcpiRsdp10Page (
|
|||||||
Status = RowPointer ( SocketFD,
|
Status = RowPointer ( SocketFD,
|
||||||
pPort,
|
pPort,
|
||||||
"RsdtAddress",
|
"RsdtAddress",
|
||||||
(VOID *)pRsdp10b->RsdtAddress,
|
(VOID *)(UINTN)pRsdp10b->RsdtAddress,
|
||||||
PAGE_ACPI_RSDT );
|
PAGE_ACPI_RSDT );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
@ -1696,7 +1696,7 @@ AcpiRsdp30Page (
|
|||||||
Status = RowPointer ( SocketFD,
|
Status = RowPointer ( SocketFD,
|
||||||
pPort,
|
pPort,
|
||||||
"RsdtAddress",
|
"RsdtAddress",
|
||||||
(VOID *)pRsdp30->RsdtAddress,
|
(VOID *)(UINTN)pRsdp30->RsdtAddress,
|
||||||
PAGE_ACPI_RSDT );
|
PAGE_ACPI_RSDT );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
@ -1881,7 +1881,7 @@ AcpiRsdtPage (
|
|||||||
// The entry is actually a 32-bit physical table address
|
// The entry is actually a 32-bit physical table address
|
||||||
// The first entry in the table is the 32-bit table signature
|
// The first entry in the table is the 32-bit table signature
|
||||||
//
|
//
|
||||||
TableName[ 0 ] = *(UINT32 *)*pEntry;
|
TableName[ 0 ] = *(UINT32 *)(UINTN)*pEntry;
|
||||||
pWebPage = SignatureLookup ( &TableName[ 0 ], &pTableName );
|
pWebPage = SignatureLookup ( &TableName[ 0 ], &pTableName );
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -1890,7 +1890,7 @@ AcpiRsdtPage (
|
|||||||
Status = RowPointer ( SocketFD,
|
Status = RowPointer ( SocketFD,
|
||||||
pPort,
|
pPort,
|
||||||
pTableName,
|
pTableName,
|
||||||
(VOID *)*pEntry,
|
(VOID *)(UINTN)*pEntry,
|
||||||
pWebPage );
|
pWebPage );
|
||||||
if ( EFI_ERROR ( Status )) {
|
if ( EFI_ERROR ( Status )) {
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user