3 * Texas Instruments, <www.ti.com>
5 * SPDX-License-Identifier: GPL-2.0+
10 /* Platform-specific defines */
11 #include <linux/compiler.h>
16 #define MMCSD_MODE_UNDEFINED 0
17 #define MMCSD_MODE_RAW 1
18 #define MMCSD_MODE_FAT 2
20 struct spl_image_info {
29 #define SPL_COPY_PAYLOAD_ONLY 1
31 extern struct spl_image_info spl_image;
33 /* SPL common functions */
34 void preloader_console_init(void);
35 u32 spl_boot_device(void);
36 u32 spl_boot_mode(void);
37 void spl_parse_image_header(const struct image_header *header);
38 void spl_board_prepare_for_linux(void);
39 void __noreturn jump_to_image_linux(void *arg);
40 int spl_start_uboot(void);
41 void spl_display_print(void);
43 /* NAND SPL functions */
44 void spl_nand_load_image(void);
46 /* OneNAND SPL functions */
47 void spl_onenand_load_image(void);
49 /* NOR SPL functions */
50 void spl_nor_load_image(void);
52 /* MMC SPL functions */
53 void spl_mmc_load_image(void);
55 /* YMODEM SPL functions */
56 void spl_ymodem_load_image(void);
58 /* SPI SPL functions */
59 void spl_spi_load_image(void);
61 /* Ethernet SPL functions */
62 void spl_net_load_image(const char *device);
64 /* USB SPL functions */
65 void spl_usb_load_image(void);
67 /* SPL FAT image functions */
68 int spl_load_image_fat(block_dev_desc_t *block_dev, int partition, const char *filename);
69 int spl_load_image_fat_os(block_dev_desc_t *block_dev, int partition);
71 #ifdef CONFIG_SPL_BOARD_INIT
72 void spl_board_init(void);