blob: 68539b264bb7d553d424f83cfc83df62a8ccea8f [file] [log] [blame]
/********************************************************************************
* Marvell GPL License Option
*
* If you received this File from Marvell, you may opt to use, redistribute and/or
* modify this File in accordance with the terms and conditions of the General
* Public License Version 2, June 1991 (the "GPL License"), a copy of which is
* available along with the File in the license.txt file or by writing to the Free
* Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 or
* on the worldwide web at http://www.gnu.org/licenses/gpl.txt.
*
* THE FILE IS DISTRIBUTED AS-IS, WITHOUT WARRANTY OF ANY KIND, AND THE IMPLIED
* WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE ARE EXPRESSLY
* DISCLAIMED. The GPL License provides additional details about this warranty
* disclaimer.
******************************************************************************/
#ifndef _BLOCK1_LAYOUT_H_
#define _BLOCK1_LAYOUT_H_
// MV_Block1_Item param usage:
typedef enum {
BLOCK1_IMAGE_TYPE_MASK = 0x000000FF,
BLOCK1_IMAGE_TYPE_LAYOUT = 0x00,
BLOCK1_IMAGE_TYPE_EROM = 0x01,
BLOCK1_IMAGE_TYPE_IMAGE2 = 0x02,
BLOCK1_IMAGE_TYPE_LOADER = 0x03,
BLOCK1_IMAGE_TYPE_VT = 0x08, // version table
BLOCK1_IMAGE_TYPE_DATA = 0x10,
BLOCK1_IMAGE_LOADER_SEQ_MASK = 0x0000FF00,
BLOCK1_IMAGE_DESTINATION_TYPE_MASK = 0x000F0000,
BLOCK1_IMAGE_DESTINATION_IN_SOC = 0x00000,
BLOCK1_IMAGE_DESTINATION_IN_BCM = 0x10000,
BLOCK1_IMAGE_DESTINATION_NA = 0x20000,
BLOCK1_IMAGE_SIGNING_OPTIONS_MASK = 0x0F0000000,
BLOCK1_IMAGE_IS_SIGNED = 0x00000000,
BLOCK1_IMAGE_NOT_SIGNED = 0x10000000,
BLOCK1_IMAGE_HANDSHAKE_MASK = 0xF0000000,
BLOCK1_IMAGE_HANDSHAKE_ACK = 0x80000000,
} MV_Block1_Type;
typedef struct tMV_Block1_Item {
unsigned int param; // image type, loading parameters
unsigned int start; // start location of image
unsigned int len; // length of image
unsigned int dst; // suggested destination to load
} MV_Block1_Item;
typedef struct tMV_Block1_Head {
union {
struct {
unsigned int HeaderVersion;
unsigned short MagicNumber;
unsigned short OffsetSignature;
unsigned char NumItems;
unsigned char RootAesKey;
unsigned char SubKeyIndex;
unsigned char SubKeyParam;
};
unsigned int a32[4];
};
} MV_Block1_Head;
typedef struct tMV_Block1 {
MV_Block1_Head head;
MV_Block1_Item item[1];
} MV_Block1;
#endif