123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- #include <stdint.h>
- #define __packed __attribute__((packed))
- #define IFDTOOL_VERSION "1.1-U-Boot"
- #define WRITE_MAX 16
- enum spi_frequency {
- SPI_FREQUENCY_20MHZ = 0,
- SPI_FREQUENCY_33MHZ = 1,
- SPI_FREQUENCY_50MHZ = 4,
- };
- enum component_density {
- COMPONENT_DENSITY_512KB = 0,
- COMPONENT_DENSITY_1MB = 1,
- COMPONENT_DENSITY_2MB = 2,
- COMPONENT_DENSITY_4MB = 3,
- COMPONENT_DENSITY_8MB = 4,
- COMPONENT_DENSITY_16MB = 5,
- };
- struct __packed fdbar_t {
- uint32_t flvalsig;
- uint32_t flmap0;
- uint32_t flmap1;
- uint32_t flmap2;
- uint8_t reserved[0xefc - 0x20];
- uint32_t flumap1;
- };
- #define MAX_REGIONS 5
- struct __packed frba_t {
- uint32_t flreg[MAX_REGIONS];
- };
- struct __packed fcba_t {
- uint32_t flcomp;
- uint32_t flill;
- uint32_t flpb;
- };
- #define MAX_STRAPS 18
- struct __packed fpsba_t {
- uint32_t pchstrp[MAX_STRAPS];
- };
- struct __packed fmba_t {
- uint32_t flmstr1;
- uint32_t flmstr2;
- uint32_t flmstr3;
- };
- struct __packed fmsba_t {
- uint32_t data[8];
- };
- struct vscc_t {
- uint32_t jid;
- uint32_t vscc;
- };
- struct vtba_t {
-
- struct vscc_t entry[8];
- };
- struct region_t {
- int base, limit, size;
- };
|