/*---------------------------------------------------------------------------* Project: Boot block format for CAFE-boot1 File: bootosBootBlock.h Copyright (C) Nintendo. All rights reserved. These coded instructions, statements, and computer programs contain proprietary information of Nintendo of America Inc. and/or Nintendo Company Ltd., and are protected by Federal copyright law. They may not be disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written consent of Nintendo. *---------------------------------------------------------------------------*/ #ifndef __BOOTOS_BOOT_BLOCK_H__ #define __BOOTOS_BOOT_BLOCK_H__ #ifdef __cplusplus extern "C" { #endif /* * bsf offset dlf offset * 0x0000_0000 +-------------------+ 0x0040_0000 * | Image Header | * 0x0000_0020 +-------------------+ * | Data Infos | * 0xXXXX_XXXX +-------------------+ * | Data Images | * | | * | | * | | * +-------------------+ * */ #define BOOTOS_BOOT_BLOCK_MAGIC 0xFD9B5B7A #define BOOTOS_BOOT_BLOCK_MAGIC_OFF 0 #define BOOTOS_BOOT_BLOCK_FLAG_LOAD_PKG_IN_IOS 0x80000000 #define BOOTOS_BOOT_BLOCK_PASS_OPTS_VIA_CFG_REG 0x40000000 typedef unsigned char u8; typedef unsigned int u32; typedef int s32; // Header size should be 32 bytes typedef struct { u32 magic; // magic number u32 num; // data info number u32 platform_info_paddr; // physical address of platform info. u32 package_info_paddr; // physical address of package info. u32 flags; // flags for boot1 u32 ccrsyscfg1; // Sticky register bits u32 pad[2]; // pad to 32B } bootosBootBlockHeader; typedef struct bootosBootBlockDataInfo { u32 address; // address u32 length; // length } bootosBootBlockDataInfo; #ifdef __cplusplus } #endif #endif // __BOOTOS_BOOT_BLOCK_H__