Index: head/lib/libc/gen/nlist.c =================================================================== --- head/lib/libc/gen/nlist.c +++ head/lib/libc/gen/nlist.c @@ -47,8 +47,8 @@ #include #include "un-namespace.h" -/* There is no a.out support on arm64 */ -#ifndef __aarch64__ +/* i386 is the only current FreeBSD architecture that used a.out format. */ +#ifdef __i386__ #define _NLIST_DO_AOUT #endif #define _NLIST_DO_ELF Index: head/sys/boot/efi/include/amd64/efibind.h =================================================================== --- head/sys/boot/efi/include/amd64/efibind.h +++ head/sys/boot/efi/include/amd64/efibind.h @@ -37,11 +37,11 @@ #if (__STDC_VERSION__ < 199901L ) - // No ANSI C 1999/2000 stdint.h integer width declarations + // No ANSI C 1999/2000 stdint.h integer width declarations #if _MSC_EXTENSIONS - // Use Microsoft C compiler integer width declarations + // Use Microsoft C compiler integer width declarations typedef unsigned __int64 uint64_t; typedef __int64 int64_t; @@ -51,10 +51,10 @@ typedef short int16_t; typedef unsigned char uint8_t; typedef char int8_t; - #else + #else #ifdef UNIX_LP64 - // Use LP64 programming model from C_FLAGS for integer width declarations + // Use LP64 programming model from C_FLAGS for integer width declarations typedef unsigned long uint64_t; typedef long int64_t; @@ -66,7 +66,7 @@ typedef char int8_t; #else - // Assume P64 programming model from C_FLAGS for integer width declarations + // Assume P64 programming model from C_FLAGS for integer width declarations typedef unsigned long long uint64_t; typedef long long int64_t; @@ -112,17 +112,17 @@ #ifdef EFI_NT_EMULATOR #define POST_CODE(_Data) -#else +#else #ifdef EFI_DEBUG #define POST_CODE(_Data) __asm mov eax,(_Data) __asm out 0x80,al #else #define POST_CODE(_Data) - #endif + #endif #endif #define EFIERR(a) (0x8000000000000000 | a) #define EFI_ERROR_MASK 0x8000000000000000 -#define EFIERR_OEM(a) (0xc000000000000000 | a) +#define EFIERR_OEM(a) (0xc000000000000000 | a) #define BAD_POINTER 0xFBFBFBFBFBFBFBFB @@ -156,18 +156,18 @@ // BOOTSERVICE - prototype for implementation of a boot service interface // RUNTIMESERVICE - prototype for implementation of a runtime service interface // RUNTIMEFUNCTION - prototype for implementation of a runtime function that is not a service -// RUNTIME_CODE - pragma macro for declaring runtime code +// RUNTIME_CODE - pragma macro for declaring runtime code // #ifdef __amd64__ #define EFIAPI __attribute__((ms_abi)) #endif -#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options +#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options #if _MSC_EXTENSIONS - #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler + #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler #else - #define EFIAPI // Substitute expresion to force C calling convention + #define EFIAPI // Substitute expresion to force C calling convention #endif #endif @@ -184,7 +184,7 @@ #define VOLATILE volatile -#define MEMORY_FENCE() +#define MEMORY_FENCE() #ifdef EFI_NO_INTERFACE_DECL #define EFI_FORWARD_DECLARATION(x) @@ -233,9 +233,9 @@ #define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \ - (_if)->LoadInternal(type, name, NULL) + (_if)->LoadInternal(type, name, NULL) -#else // EFI_NT_EMULATOR +#else // EFI_NT_EMULATOR // // When build similiar to FW, then link everything together as @@ -247,7 +247,7 @@ #define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \ (_if)->LoadInternal(type, name, entry) -#endif // EFI_FW_NT +#endif // EFI_FW_NT #ifdef __FreeBSD__ #define INTERFACE_DECL(x) struct x Index: head/sys/boot/efi/include/amd64/pe.h =================================================================== --- head/sys/boot/efi/include/amd64/pe.h +++ head/sys/boot/efi/include/amd64/pe.h @@ -1,5 +1,5 @@ /* $FreeBSD$ */ -/* +/* PE32+ header file */ #ifndef _PE_H @@ -8,7 +8,7 @@ #define IMAGE_DOS_SIGNATURE 0x5A4D // MZ #define IMAGE_OS2_SIGNATURE 0x454E // NE #define IMAGE_OS2_SIGNATURE_LE 0x454C // LE -#define IMAGE_NT_SIGNATURE 0x00004550 // PE00 +#define IMAGE_NT_SIGNATURE 0x00004550 // PE00 #define IMAGE_EDOS_SIGNATURE 0x44454550 // PEED @@ -130,7 +130,7 @@ UINT32 AddressOfEntryPoint; UINT32 BaseOfCode; UINT32 BaseOfData; - + // // NT additional fields. // Index: head/sys/boot/efi/include/arm64/efibind.h =================================================================== --- head/sys/boot/efi/include/arm64/efibind.h +++ head/sys/boot/efi/include/arm64/efibind.h @@ -37,11 +37,11 @@ #if (__STDC_VERSION__ < 199901L ) - // No ANSI C 1999/2000 stdint.h integer width declarations + // No ANSI C 1999/2000 stdint.h integer width declarations #if _MSC_EXTENSIONS - // Use Microsoft C compiler integer width declarations + // Use Microsoft C compiler integer width declarations typedef unsigned __int64 uint64_t; typedef __int64 int64_t; @@ -51,10 +51,10 @@ typedef __int16 int16_t; typedef unsigned __int8 uint8_t; typedef __int8 int8_t; - #else + #else #ifdef UNIX_LP64 - // Use LP64 programming model from C_FLAGS for integer width declarations + // Use LP64 programming model from C_FLAGS for integer width declarations typedef unsigned long uint64_t; typedef long int64_t; @@ -66,7 +66,7 @@ typedef char int8_t; #else - // Assume P64 programming model from C_FLAGS for integer width declarations + // Assume P64 programming model from C_FLAGS for integer width declarations typedef unsigned long long uint64_t; typedef long long int64_t; @@ -108,10 +108,10 @@ // #define BIT63 0x8000000000000000 -#define PLATFORM_IOBASE_ADDRESS (0xffffc000000 | BIT63) +#define PLATFORM_IOBASE_ADDRESS (0xffffc000000 | BIT63) #define PORT_TO_MEMD(_Port) (PLATFORM_IOBASE_ADDRESS | ( ( ( (_Port) & 0xfffc) << 10 ) | ( (_Port) & 0x0fff) ) ) - -// + +// // Macro's with casts make this much easier to use and read. // #define PORT_TO_MEM8D(_Port) (*(UINT8 *)(PORT_TO_MEMD(_Port))) @@ -122,12 +122,12 @@ #define EFIERR(a) (0x8000000000000000 | a) #define EFI_ERROR_MASK 0x8000000000000000 -#define EFIERR_OEM(a) (0xc000000000000000 | a) +#define EFIERR_OEM(a) (0xc000000000000000 | a) #define BAD_POINTER 0xFBFBFBFBFBFBFBFB #define MAX_ADDRESS 0xFFFFFFFFFFFFFFFF -#pragma intrinsic (__break) +#pragma intrinsic (__break) #define BREAKPOINT() __break(0) // @@ -155,14 +155,14 @@ // BOOTSERVICE - prototype for implementation of a boot service interface // RUNTIMESERVICE - prototype for implementation of a runtime service interface // RUNTIMEFUNCTION - prototype for implementation of a runtime function that is not a service -// RUNTIME_CODE - pragma macro for declaring runtime code +// RUNTIME_CODE - pragma macro for declaring runtime code // -#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options +#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options #if _MSC_EXTENSIONS - #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler + #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler #else - #define EFIAPI // Substitute expresion to force C calling convention + #define EFIAPI // Substitute expresion to force C calling convention #endif #endif @@ -179,8 +179,8 @@ // // BugBug: Need to find out if this is portable accross compliers. // -void __mfa (void); -#pragma intrinsic (__mfa) +void __mfa (void); +#pragma intrinsic (__mfa) #define MEMORY_FENCE() __mfa() #ifdef EFI_NO_INTERFACE_DECL Index: head/sys/boot/efi/include/efi.h =================================================================== --- head/sys/boot/efi/include/efi.h +++ head/sys/boot/efi/include/efi.h @@ -54,10 +54,10 @@ #include "efierr.h" #include "efigop.h" -#define EFI_STRINGIZE(a) #a -#define EFI_PROTOCOL_DEFINITION(a) EFI_STRINGIZE(Protocol/a/a.h) +#define EFI_STRINGIZE(a) #a +#define EFI_PROTOCOL_DEFINITION(a) EFI_STRINGIZE(Protocol/a/a.h) -#define EFI_GUID_DEFINITION(a) EFI_STRINGIZE(Guid/a/a##.h) +#define EFI_GUID_DEFINITION(a) EFI_STRINGIZE(Guid/a/a##.h) #define EFI_GUID_STRING(guidpointer, shortstring, longstring) #endif Index: head/sys/boot/efi/include/efi_nii.h =================================================================== --- head/sys/boot/efi/include/efi_nii.h +++ head/sys/boot/efi/include/efi_nii.h @@ -21,7 +21,7 @@ 2000-Feb-18 M(f)J GUID updated. Structure order changed for machine word alignment. Added StringId[4] to structure. - + 2000-Feb-14 M(f)J Genesis. --*/ Index: head/sys/boot/efi/include/efidebug.h =================================================================== --- head/sys/boot/efi/include/efidebug.h +++ head/sys/boot/efi/include/efidebug.h @@ -33,12 +33,12 @@ #define DBGASSERT(a) DbgAssert(__FILE__, __LINE__, #a) #define DEBUG(a) DbgPrint a - + #else #define DBGASSERT(a) #define DEBUG(a) - + #endif #if EFI_DEBUG_CLEAR_MEMORY @@ -60,7 +60,7 @@ #define D_INFO 0x00000040 // Verbose #define D_VARIABLE 0x00000100 // Variable #define D_VAR 0x00000100 // Variable -#define D_BM 0x00000400 // Boot Manager +#define D_BM 0x00000400 // Boot Manager #define D_BLKIO 0x00001000 // BlkIo Driver #define D_BLKIO_ULTRA 0x00002000 // BlkIo Driver #define D_NET 0x00004000 // SNI Driver @@ -91,9 +91,9 @@ #else - #define ASSERT(a) - #define ASSERT_LOCKED(l) - #define ASSERT_STRUCT(p,t) + #define ASSERT(a) + #define ASSERT_LOCKED(l) + #define ASSERT_STRUCT(p,t) #endif Index: head/sys/boot/efi/include/efidef.h =================================================================== --- head/sys/boot/efi/include/efidef.h +++ head/sys/boot/efi/include/efidef.h @@ -70,11 +70,11 @@ // A GUID // -typedef struct { +typedef struct { UINT32 Data1; UINT16 Data2; UINT16 Data3; - UINT8 Data4[8]; + UINT8 Data4[8]; } EFI_GUID; @@ -82,7 +82,7 @@ // Time // -typedef struct { +typedef struct { UINT16 Year; // 1998 - 20XX UINT8 Month; // 1 - 12 UINT8 Day; // 1 - 31 @@ -165,9 +165,9 @@ #define EFI_MEMORY_WC 0x0000000000000002 #define EFI_MEMORY_WT 0x0000000000000004 #define EFI_MEMORY_WB 0x0000000000000008 -#define EFI_MEMORY_UCE 0x0000000000000010 +#define EFI_MEMORY_UCE 0x0000000000000010 -// physical memory protection on range +// physical memory protection on range #define EFI_MEMORY_WP 0x0000000000001000 #define EFI_MEMORY_RP 0x0000000000002000 #define EFI_MEMORY_XP 0x0000000000004000 Index: head/sys/boot/efi/include/efidevp.h =================================================================== --- head/sys/boot/efi/include/efidevp.h +++ head/sys/boot/efi/include/efidevp.h @@ -150,8 +150,8 @@ // bits[31:16] - binary number // Compressed ASCII is 5 bits per character 0b00001 = 'A' 0b11010 = 'Z' // -#define PNP_EISA_ID_CONST 0x41d0 -#define EISA_ID(_Name, _Num) ((UINT32) ((_Name) | (_Num) << 16)) +#define PNP_EISA_ID_CONST 0x41d0 +#define EISA_ID(_Name, _Num) ((UINT32) ((_Name) | (_Num) << 16)) #define EISA_PNP_ID(_PNPId) (EISA_ID(PNP_EISA_ID_CONST, (_PNPId))) #define EFI_PNP_ID(_PNPId) (EISA_ID(PNP_EISA_ID_CONST, (_PNPId))) @@ -160,7 +160,7 @@ /* * */ -#define MESSAGING_DEVICE_PATH 0x03 +#define MESSAGING_DEVICE_PATH 0x03 #define MSG_ATAPI_DP 0x01 typedef struct _ATAPI_DEVICE_PATH { @@ -174,7 +174,7 @@ typedef struct _SCSI_DEVICE_PATH { EFI_DEVICE_PATH Header; UINT16 Pun; - UINT16 Lun; + UINT16 Lun; } SCSI_DEVICE_PATH; #define MSG_FIBRECHANNEL_DP 0x03 @@ -281,9 +281,9 @@ #define DEVICE_PATH_MESSAGING_VT_100_PLUS \ { 0x7baec70b, 0x57e0, 0x4c76, 0x8e, 0x87, 0x2f, 0x9e, 0x28, 0x08, 0x83, 0x43 } - + #define DEVICE_PATH_MESSAGING_VT_UTF8 \ - { 0xad15a0d6, 0x8bec, 0x4acf, 0xa0, 0x73, 0xd0, 0x1d, 0xe7, 0x7e, 0x2d, 0x88 } + { 0xad15a0d6, 0x8bec, 0x4acf, 0xa0, 0x73, 0xd0, 0x1d, 0xe7, 0x7e, 0x2d, 0x88 } #define MEDIA_DEVICE_PATH 0x04 @@ -356,7 +356,7 @@ PCCARD_DEVICE_PATH PcCard; MEMMAP_DEVICE_PATH MemMap; VENDOR_DEVICE_PATH Vendor; - UNKNOWN_DEVICE_VENDOR_DEVICE_PATH UnknownVendor; + UNKNOWN_DEVICE_VENDOR_DEVICE_PATH UnknownVendor; CONTROLLER_DEVICE_PATH Controller; ACPI_HID_DEVICE_PATH Acpi; @@ -390,7 +390,7 @@ PCCARD_DEVICE_PATH *PcCard; MEMMAP_DEVICE_PATH *MemMap; VENDOR_DEVICE_PATH *Vendor; - UNKNOWN_DEVICE_VENDOR_DEVICE_PATH *UnknownVendor; + UNKNOWN_DEVICE_VENDOR_DEVICE_PATH *UnknownVendor; CONTROLLER_DEVICE_PATH *Controller; ACPI_HID_DEVICE_PATH *Acpi; ACPI_EXTENDED_HID_DEVICE_PATH *ExtendedAcpi; Index: head/sys/boot/efi/include/efifs.h =================================================================== --- head/sys/boot/efi/include/efifs.h +++ head/sys/boot/efi/include/efifs.h @@ -101,7 +101,7 @@ UINT32 ArrayCount; } EFI_LBAL; -// Array size +// Array size #define EFI_LBAL_ARRAY_SIZE(lbal,offs,blks) \ (((blks) - (offs) - (lbal)->Hdr.HeaderSize) / sizeof(EFI_RL)) Index: head/sys/boot/efi/include/efinet.h =================================================================== --- head/sys/boot/efi/include/efinet.h +++ head/sys/boot/efi/include/efinet.h @@ -173,8 +173,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_START) ( IN struct _EFI_SIMPLE_NETWORK *This ); @@ -182,8 +182,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_STOP) ( IN struct _EFI_SIMPLE_NETWORK *This ); @@ -191,8 +191,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_INITIALIZE) ( IN struct _EFI_SIMPLE_NETWORK *This, IN UINTN ExtraRxBufferSize OPTIONAL, @@ -202,8 +202,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_RESET) ( IN struct _EFI_SIMPLE_NETWORK *This, IN BOOLEAN ExtendedVerification @@ -212,8 +212,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_SHUTDOWN) ( IN struct _EFI_SIMPLE_NETWORK *This ); @@ -221,8 +221,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_RECEIVE_FILTERS) ( IN struct _EFI_SIMPLE_NETWORK *This, IN UINT32 Enable, @@ -235,8 +235,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_STATION_ADDRESS) ( IN struct _EFI_SIMPLE_NETWORK *This, IN BOOLEAN Reset, @@ -246,8 +246,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_STATISTICS) ( IN struct _EFI_SIMPLE_NETWORK *This, IN BOOLEAN Reset, @@ -258,8 +258,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_MCAST_IP_TO_MAC) ( IN struct _EFI_SIMPLE_NETWORK *This, IN BOOLEAN IPv6, @@ -270,8 +270,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_NVDATA) ( IN struct _EFI_SIMPLE_NETWORK *This, IN BOOLEAN ReadWrite, @@ -283,8 +283,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_GET_STATUS) ( IN struct _EFI_SIMPLE_NETWORK *This, OUT UINT32 *InterruptStatus OPTIONAL, @@ -294,8 +294,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_TRANSMIT) ( IN struct _EFI_SIMPLE_NETWORK *This, IN UINTN HeaderSize, @@ -309,8 +309,8 @@ /////////////////////////////////////////////////////////////////////////////// // -typedef -EFI_STATUS +typedef +EFI_STATUS (EFIAPI *EFI_SIMPLE_NETWORK_RECEIVE) ( IN struct _EFI_SIMPLE_NETWORK *This, OUT UINTN *HeaderSize OPTIONAL, Index: head/sys/boot/efi/include/efipart.h =================================================================== --- head/sys/boot/efi/include/efipart.h +++ head/sys/boot/efi/include/efipart.h @@ -16,8 +16,8 @@ Module Name: efipart.h - -Abstract: + +Abstract: Info about disk partitions and Master Boot Records @@ -55,7 +55,7 @@ #define MIN_MBR_DEVICE_SIZE 0x80000 #define MBR_ERRATA_PAD 0x40000 // 128 MB -#define MAX_MBR_PARTITIONS 4 +#define MAX_MBR_PARTITIONS typedef struct { UINT8 BootStrapCode[440]; UINT8 UniqueMbrSignature[4]; Index: head/sys/boot/efi/include/efipciio.h =================================================================== --- head/sys/boot/efi/include/efipciio.h +++ head/sys/boot/efi/include/efipciio.h @@ -1,16 +1,16 @@ /* $FreeBSD$ */ /** @file - EFI PCI I/O Protocol provides the basic Memory, I/O, PCI configuration, + EFI PCI I/O Protocol provides the basic Memory, I/O, PCI configuration, and DMA interfaces that a driver uses to access its PCI controller. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.
- This program and the accompanying materials - are licensed and made available under the terms and conditions of the BSD License - which accompanies this distribution. The full text of the license may be found at - http://opensource.org/licenses/bsd-license.php + This program and the accompanying materials + are licensed and made available under the terms and conditions of the BSD License + which accompanies this distribution. The full text of the license may be found at + http://opensource.org/licenses/bsd-license.php - THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, - WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, + WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. **/ Index: head/sys/boot/efi/include/efiprot.h =================================================================== --- head/sys/boot/efi/include/efiprot.h +++ head/sys/boot/efi/include/efiprot.h @@ -307,9 +307,9 @@ // // The FileName field of the EFI_FILE_INFO data structure is variable length. // Whenever code needs to know the size of the EFI_FILE_INFO data structure, it needs to -// be the size of the data structure without the FileName field. The following macro +// be the size of the data structure without the FileName field. The following macro // computes this size correctly no matter how big the FileName array is declared. -// This is required to make the EFI_FILE_INFO data structure ANSI compilant. +// This is required to make the EFI_FILE_INFO data structure ANSI compilant. // #define SIZE_OF_EFI_FILE_INFO EFI_FIELD_OFFSET(EFI_FILE_INFO,FileName) @@ -329,9 +329,9 @@ // // The VolumeLabel field of the EFI_FILE_SYSTEM_INFO data structure is variable length. // Whenever code needs to know the size of the EFI_FILE_SYSTEM_INFO data structure, it needs -// to be the size of the data structure without the VolumeLable field. The following macro +// to be the size of the data structure without the VolumeLable field. The following macro // computes this size correctly no matter how big the VolumeLable array is declared. -// This is required to make the EFI_FILE_SYSTEM_INFO data structure ANSI compilant. +// This is required to make the EFI_FILE_SYSTEM_INFO data structure ANSI compilant. // #define SIZE_OF_EFI_FILE_SYSTEM_INFO EFI_FIELD_OFFSET(EFI_FILE_SYSTEM_INFO,VolumeLabel) @@ -411,7 +411,7 @@ EFI_DEVICE_IO Write; } EFI_IO_ACCESS; -typedef +typedef EFI_STATUS (EFIAPI *EFI_PCI_DEVICE_PATH) ( IN struct _EFI_DEVICE_IO_INTERFACE *This, Index: head/sys/boot/efi/include/efipxebc.h =================================================================== --- head/sys/boot/efi/include/efipxebc.h +++ head/sys/boot/efi/include/efipxebc.h @@ -151,7 +151,7 @@ // Discover() definitions // -#define EFI_PXE_BASE_CODE_BOOT_TYPE_BOOTSTRAP 0 +#define EFI_PXE_BASE_CODE_BOOT_TYPE_BOOTSTRAP 0 #define EFI_PXE_BASE_CODE_BOOT_TYPE_MS_WINNT_RIS 1 #define EFI_PXE_BASE_CODE_BOOT_TYPE_INTEL_LCM 2 #define EFI_PXE_BASE_CODE_BOOT_TYPE_DOSUNDI 3 @@ -356,7 +356,7 @@ EFI_STATUS (EFIAPI *EFI_PXE_BASE_CODE_ARP) ( IN struct _EFI_PXE_BASE_CODE *This, - IN EFI_IP_ADDRESS *IpAddr, + IN EFI_IP_ADDRESS *IpAddr, IN EFI_MAC_ADDRESS *MacAddr OPTIONAL ); @@ -455,7 +455,7 @@ } EFI_PXE_BASE_CODE_CALLBACK_STATUS; typedef -EFI_PXE_BASE_CODE_CALLBACK_STATUS +EFI_PXE_BASE_CODE_CALLBACK_STATUS (EFIAPI *EFI_PXE_CALLBACK) ( IN struct _EFI_PXE_BASE_CODE_CALLBACK *This, IN EFI_PXE_BASE_CODE_FUNCTION Function, Index: head/sys/boot/efi/include/efiser.h =================================================================== --- head/sys/boot/efi/include/efiser.h +++ head/sys/boot/efi/include/efiser.h @@ -35,8 +35,8 @@ INTERFACE_DECL(_SERIAL_IO_INTERFACE); typedef enum { - DefaultParity, - NoParity, + DefaultParity, + NoParity, EvenParity, OddParity, MarkParity, @@ -44,7 +44,7 @@ } EFI_PARITY_TYPE; typedef enum { - DefaultStopBits, + DefaultStopBits OneStopBit, // 1 stop bit OneFiveStopBits, // 1.5 stop bits TwoStopBits // 2 stop bits Index: head/sys/boot/efi/include/efiuga.h =================================================================== --- head/sys/boot/efi/include/efiuga.h +++ head/sys/boot/efi/include/efiuga.h @@ -102,33 +102,33 @@ The following table defines actions for BltOperations: - EfiUgaVideoFill - Write data from the BltBuffer pixel (SourceX, SourceY) - directly to every pixel of the video display rectangle - (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). + EfiUgaVideoFill - Write data from the BltBuffer pixel (SourceX, SourceY) + directly to every pixel of the video display rectangle + (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). Only one pixel will be used from the BltBuffer. Delta is NOT used. - EfiUgaVideoToBltBuffer - Read data from the video display rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in - the BltBuffer rectangle (DestinationX, DestinationY ) - (DestinationX + Width, DestinationY + Height). If DestinationX or - DestinationY is not zero then Delta must be set to the length in bytes + EfiUgaVideoToBltBuffer - Read data from the video display rectangle + (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in + the BltBuffer rectangle (DestinationX, DestinationY ) + (DestinationX + Width, DestinationY + Height). If DestinationX or + DestinationY is not zero then Delta must be set to the length in bytes of a row in the BltBuffer. - EfiUgaBltBufferToVideo - Write data from the BltBuffer rectangle - (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the - video display rectangle (DestinationX, DestinationY) - (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is - not zero then Delta must be set to the length in bytes of a row in the + EfiUgaBltBufferToVideo - Write data from the BltBuffer rectangle + (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the + video display rectangle (DestinationX, DestinationY) + (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is + not zero then Delta must be set to the length in bytes of a row in the BltBuffer. EfiUgaVideoToVideo - Copy from the video display rectangle (SourceX, SourceY) - (SourceX + Width, SourceY + Height) .to the video display rectangle - (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). + (SourceX + Width, SourceY + Height) .to the video display rectangle + (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). The BltBuffer and Delta are not used in this mode. @param[in] This - Protocol instance pointer. - @param[in] BltBuffer - Buffer containing data to blit into video buffer. This + @param[in] BltBuffer - Buffer containing data to blit into video buffer. This buffer has a size of Width*Height*sizeof(EFI_UGA_PIXEL) @param[in] BltOperation - Operation to perform on BlitBuffer and video memory @param[in] SourceX - X coordinate of source for the BltBuffer. @@ -138,7 +138,7 @@ @param[in] Width - Width of rectangle in BltBuffer in pixels. @param[in] Height - Hight of rectangle in BltBuffer in pixels. @param[in] Delta - OPTIONAL - + @retval EFI_SUCCESS - The Blt operation completed. @retval EFI_INVALID_PARAMETER - BltOperation is not valid. @retval EFI_DEVICE_ERROR - A hardware error occured writting to the video buffer. Index: head/sys/boot/efi/include/i386/efibind.h =================================================================== --- head/sys/boot/efi/include/i386/efibind.h +++ head/sys/boot/efi/include/i386/efibind.h @@ -37,11 +37,11 @@ #if (__STDC_VERSION__ < 199901L ) - // No ANSI C 1999/2000 stdint.h integer width declarations + // No ANSI C 1999/2000 stdint.h integer width declarations #if _MSC_EXTENSIONS - // Use Microsoft C compiler integer width declarations + // Use Microsoft C compiler integer width declarations typedef unsigned __int64 uint64_t; typedef __int64 int64_t; @@ -51,10 +51,10 @@ typedef short int16_t; typedef unsigned char uint8_t; typedef char int8_t; - #else + #else #ifdef UNIX_LP64 - // Use LP64 programming model from C_FLAGS for integer width declarations + // Use LP64 programming model from C_FLAGS for integer width declarations typedef unsigned long uint64_t; typedef long int64_t; @@ -66,7 +66,7 @@ typedef char int8_t; #else - // Assume P64 programming model from C_FLAGS for integer width declarations + // Assume P64 programming model from C_FLAGS for integer width declarations typedef unsigned long long uint64_t; typedef long long int64_t; @@ -112,17 +112,17 @@ #ifdef EFI_NT_EMULATOR #define POST_CODE(_Data) -#else +#else #ifdef EFI_DEBUG #define POST_CODE(_Data) __asm mov eax,(_Data) __asm out 0x80,al #else #define POST_CODE(_Data) - #endif + #endif #endif #define EFIERR(a) (0x80000000 | a) #define EFI_ERROR_MASK 0x80000000 -#define EFIERR_OEM(a) (0xc0000000 | a) +#define EFIERR_OEM(a) (0xc0000000 | a) #define BAD_POINTER 0xFBFBFBFB @@ -156,14 +156,14 @@ // BOOTSERVICE - prototype for implementation of a boot service interface // RUNTIMESERVICE - prototype for implementation of a runtime service interface // RUNTIMEFUNCTION - prototype for implementation of a runtime function that is not a service -// RUNTIME_CODE - pragma macro for declaring runtime code +// RUNTIME_CODE - pragma macro for declaring runtime code // -#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options +#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options #if _MSC_EXTENSIONS - #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler + #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler #else - #define EFIAPI // Substitute expresion to force C calling convention + #define EFIAPI // Substitute expresion to force C calling convention #endif #endif @@ -180,7 +180,7 @@ #define VOLATILE volatile -#define MEMORY_FENCE() +#define MEMORY_FENCE() #ifdef EFI_NO_INTERFACE_DECL #define EFI_FORWARD_DECLARATION(x) @@ -229,9 +229,9 @@ #define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \ - (_if)->LoadInternal(type, name, NULL) + (_if)->LoadInternal(type, name, NULL) -#else // EFI_NT_EMULATOR +#else // EFI_NT_EMULATOR // // When build similiar to FW, then link everything together as @@ -243,7 +243,7 @@ #define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \ (_if)->LoadInternal(type, name, entry) -#endif // EFI_FW_NT +#endif // EFI_FW_NT #ifdef __FreeBSD__ #define INTERFACE_DECL(x) struct x Index: head/sys/boot/efi/include/i386/pe.h =================================================================== --- head/sys/boot/efi/include/i386/pe.h +++ head/sys/boot/efi/include/i386/pe.h @@ -1,5 +1,5 @@ /* $FreeBSD$ */ -/* +/* PE32+ header file */ #ifndef _PE_H @@ -8,7 +8,7 @@ #define IMAGE_DOS_SIGNATURE 0x5A4D // MZ #define IMAGE_OS2_SIGNATURE 0x454E // NE #define IMAGE_OS2_SIGNATURE_LE 0x454C // LE -#define IMAGE_NT_SIGNATURE 0x00004550 // PE00 +#define IMAGE_NT_SIGNATURE 0x00004550 // PE00 #define IMAGE_EDOS_SIGNATURE 0x44454550 // PEED @@ -130,7 +130,7 @@ UINT32 AddressOfEntryPoint; UINT32 BaseOfCode; UINT32 BaseOfData; - + // // NT additional fields. // @@ -607,7 +607,7 @@ UINT32 Signature; // "NB10" UINT32 Unknown; UINT32 Unknown2; - UINT32 Unknown3; + UINT32 Unknown3; // // Filename of .PDB goes here // @@ -619,9 +619,9 @@ UINT32 Signature; // "RSDS" UINT32 Unknown; UINT32 Unknown2; - UINT32 Unknown3; - UINT32 Unknown4; - UINT32 Unknown5; + UINT32 Unknown3; + UINT32 Unknown4; + UINT32 Unknown5; // // Filename of .PDB goes here // Index: head/sys/boot/efi/libefi/efinet.c =================================================================== --- head/sys/boot/efi/libefi/efinet.c +++ head/sys/boot/efi/libefi/efinet.c @@ -50,7 +50,7 @@ static int efinet_probe(struct netif *, void *); static int efinet_put(struct iodesc *, void *, size_t); -struct netif_driver efinetif = { +struct netif_driver efinetif = { .netif_bname = "efinet", .netif_match = efinet_match, .netif_probe = efinet_probe, @@ -132,7 +132,7 @@ buf = 0; /* XXX Is this needed? */ status = net->GetStatus(net, 0, &buf); /* - * XXX EFI1.1 and the E1000 card returns a different + * XXX EFI1.1 and the E1000 card returns a different * address than we gave. Sigh. */ } while (status == EFI_SUCCESS && buf == 0); @@ -234,7 +234,7 @@ static void efinet_end(struct netif *nif) { - EFI_SIMPLE_NETWORK *net = nif->nif_devdata; + EFI_SIMPLE_NETWORK *net = nif->nif_devdata; net->Shutdown(net); } Index: head/sys/boot/efi/libefi/efipart.c =================================================================== --- head/sys/boot/efi/libefi/efipart.c +++ head/sys/boot/efi/libefi/efipart.c @@ -60,7 +60,7 @@ }; static int -efipart_init(void) +efipart_init(void) { EFI_BLOCK_IO *blkio; EFI_DEVICE_PATH *devpath, *devpathcpy, *tmpdevpath, *node; @@ -174,7 +174,7 @@ } } -static int +static int efipart_open(struct open_file *f, ...) { va_list args; @@ -202,7 +202,7 @@ return (0); } -static int +static int efipart_close(struct open_file *f) { struct devdesc *dev; @@ -255,7 +255,7 @@ return (efi_status_to_errno(status)); } -static int +static int efipart_strategy(void *devdata, int rw, daddr_t blk, size_t size, char *buf, size_t *rsize) { Index: head/sys/boot/efi/libefi/time.c =================================================================== --- head/sys/boot/efi/libefi/time.c +++ head/sys/boot/efi/libefi/time.c @@ -2,28 +2,28 @@ * Copyright (c) 1999, 2000 * Intel Corporation. * All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: - * + * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * + * * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: - * + * * This product includes software developed by Intel Corporation and * its contributors. - * + * * 4. Neither the name of Intel Corporation or its contributors may be * used to endorse or promote products derived from this software * without specific prior written permission. - * + * * THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION AND CONTRIBUTORS ``AS IS'' * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -35,7 +35,7 @@ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF * THE POSSIBILITY OF SUCH DAMAGE. - * + * */ #include @@ -96,7 +96,7 @@ 31 + 29 + 31 + 30 + 31 + 30 + 31 + 31 + 30 + 31 + 30, 31 + 29 + 31 + 30 + 31 + 30 + 31 + 31 + 30 + 31 + 30 + 31 }}; - time_t UTime; + time_t UTime; int Year; /* @@ -124,7 +124,7 @@ /* // UTime should now be set to 00:00:00 on Jan 1 of the file's year. // - // Months + // Months */ UTime += (CumulativeDays[isleap(ETime->Year)][ETime->Month] * SECSPERDAY); @@ -160,7 +160,7 @@ */ UTime += (ETime->TimeZone * 60); } - + return UTime; }