/** @file
Copyright (c) 1999 - 2008, Intel Corporation. All rights reserved.<BR>
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
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Module Name:
Abstract:
This file contains the relevant declarations required
to generate Boot Strap File
**/
//
// Module Coded to EFI 2.0 Coding Conventions
//
#ifndef __GEN_VTF_H__
#define __GEN_VTF_H__
//
// External Files Referenced
//
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#ifndef __GNUC__
#include <io.h>
#endif
#include "assert.h"
#include <Common/PiFirmwareFile.h>
#include "ParseInf.h"
//
// Internal Constants
//
#define CV_N_TYPE(a,b) (UINT8)(((UINT8)a << 7) + (UINT8)b) // Keeps the CV and Type in same byte field
//
//Fit Type Definition
//
//
// This is generic PAL_A
//
//
//This is processor Specific PAL_A
//
//
// IPF processor address is cached bit
//
//
// Size definition to calculate the location from top of address for
// each component
//
//
// Utility Name
//
//
// Utility version information
//
#define UTILITY_MAJOR_VERSION 0
//
// The maximum number of arguments accepted from the command line.
//
//
// Internal Data Structure
//
typedef enum _LOC_TYPE
{
} LOC_TYPE;
typedef struct _PARSED_VTF_INFO {
//
// Fixed - warning C4133: '=' : incompatible types - from 'struct _ParsedVtfInfo *' to 'struct _PARSED_VTF_INFO *'
// Fixed - warning C4133: '=' : incompatible types - from 'struct _ParsedVtfInfo *' to 'struct _PARSED_VTF_INFO *'
// Fixed - warning C4133: '=' : incompatible types - from 'struct _ParsedVtfInfo *' to 'struct _PARSED_VTF_INFO *'
// Fixed - warning C4133: '=' : incompatible types - from 'struct _ParsedVtfInfo *' to 'struct _PARSED_VTF_INFO *'
//
#pragma pack (1)
typedef struct {
} FIT_TABLE;
#pragma pack ()
//
// Function Prototype Declarations
//
)
/*++
Routine Description:
Update the Firmware Volume Buffer with requested buffer data
Arguments:
StartAddress - StartAddress in buffer. This number will automatically
point to right address in buffer where data needed
to be updated.
Buffer - Buffer pointer from data will be copied to memory mapped buffer.
DataSize - Size of the data needed to be copied.
LocType - The type of the VTF
Returns:
EFI_ABORTED - The input parameter is error
EFI_SUCCESS - The function completed successfully
--*/
;
)
/*++
Routine Description:
This function adds the SYM tokens in the source file to the destination file.
The SYM tokens are updated to reflect the base address.
Arguments:
BaseAddress - The base address for the new SYM tokens.
DestFileName - The destination file.
SourceFileName - The source file.
FileSize - Size of bin file.
Returns:
EFI_SUCCESS - The function completed successfully.
EFI_INVALID_PARAMETER - One of the input parameters was invalid.
EFI_ABORTED - An error occurred.
--*/
;
)
/*++
Routine Description:
This function will perform byte checksum on the FIT table, if the the checksum required
field is set to CheckSum required. If the checksum is not required then checksum byte
will have value as 0;.
Arguments:
NONE
Returns:
Status - Value returned by call to CalculateChecksum8 ()
EFI_SUCCESS - The function completed successfully
--*/
;
)
/*++
Routine Description:
This is the main function which will be called from application.
Arguments:
StartAddress1 - The start address of the first VTF
Size1 - The size of the first VTF
StartAddress2 - The start address of the second VTF
Size2 - The size of the second VTF
Returns:
EFI_OUT_OF_RESOURCES - Can not allocate memory
The return value can be any of the values
returned by the calls to following functions:
GetVtfRelatedInfoFromInfFile
ProcessAndCreateVtf
UpdateIA32ResetVector
UpdateFfsHeader
WriteVtfBinary
--*/
;
)
/*++
Routine Description:
This function is an entry point to fixup SAL-E entry point.
Arguments:
StartAddress - StartAddress for PEIM.....
Returns:
EFI_SUCCESS - The function completed successfully
EFI_ABORTED - Error Opening File
--*/
;
Usage (
)
/*++
Routine Description:
Displays the utility usage syntax to STDOUT
Arguments:
None
Returns:
None
--*/
;
#endif