#ifndef __COMMON_H_ #define __COMMON_H_ #include "asm/types.h" typedef struct bd_info { unsigned long bi_arch_number; /* unique id for this board */ unsigned long bi_boot_params; /* where this board expects params */ unsigned long bi_memstart; /* start of DRAM memory */ unsigned long bi_memsize; /* size of DRAM memory in bytes */ unsigned long bi_flashstart; /* start of FLASH memory */ unsigned long bi_flashsize; /* size of FLASH memory */ unsigned long bi_flashoffset; /* reserved area for startup monitor */ unsigned char bi_enetaddr[6]; struct /* RAM configuration */ { unsigned long start; unsigned long size; } bi_dram[ 2 ]; } bd_t; typedef struct global_data { bd_t *bd; unsigned long flags; unsigned int baudrate; unsigned long cpu_clk; // CPU clock in Hz! unsigned long bus_clk; phys_size_t ram_size; } gd_t; extern gd_t* gd; enum { BOOT_DEVICE_RAM, BOOT_DEVICE_MMC1, BOOT_DEVICE_MMC2, BOOT_DEVICE_MMC2_2, BOOT_DEVICE_NAND, BOOT_DEVICE_ONENAND, BOOT_DEVICE_NOR, BOOT_DEVICE_UART, BOOT_DEVICE_SPI, BOOT_DEVICE_USB, BOOT_DEVICE_SATA, BOOT_DEVICE_I2C, BOOT_DEVICE_BOARD, BOOT_DEVICE_DFU, BOOT_DEVICE_XIP, BOOT_DEVICE_NONE }; /* Boot type */ #define MMCSD_MODE_UNDEFINED 0 #define MMCSD_MODE_RAW 1 #define MMCSD_MODE_FS 2 #define MMCSD_MODE_EMMCBOOT 3 #endif /* __COMMON_H_ */