xref: /openbmc/u-boot/include/environment/ti/dfu.h (revision 33b78476)
1 /*
2  * Copyright (C) 2016 Texas Instruments Incorporated - http://www.ti.com
3  *
4  * Environment variable definitions for DFU on TI boards.
5  *
6  * SPDX-License-Identifier:	GPL-2.0+
7  */
8 
9 #define DFU_ALT_INFO_MMC \
10 	"dfu_alt_info_mmc=" \
11 	"boot part 0 1;" \
12 	"rootfs part 0 2;" \
13 	"MLO fat 0 1;" \
14 	"MLO.raw raw 0x100 0x100;" \
15 	"u-boot.img.raw raw 0x300 0x400;" \
16 	"spl-os-args.raw raw 0x80 0x80;" \
17 	"spl-os-image.raw raw 0x900 0x2000;" \
18 	"spl-os-args fat 0 1;" \
19 	"spl-os-image fat 0 1;" \
20 	"u-boot.img fat 0 1;" \
21 	"uEnv.txt fat 0 1\0"
22 
23 #define DFU_ALT_INFO_EMMC \
24 	"dfu_alt_info_emmc=" \
25 	"rawemmc raw 0 3751936;" \
26 	"boot part 1 1;" \
27 	"rootfs part 1 2;" \
28 	"MLO fat 1 1;" \
29 	"MLO.raw raw 0x100 0x100;" \
30 	"u-boot.img.raw raw 0x300 0x1000;" \
31 	"spl-os-args.raw raw 0x80 0x80;" \
32 	"spl-os-image.raw raw 0x900 0x2000;" \
33 	"spl-os-args fat 1 1;" \
34 	"spl-os-image fat 1 1;" \
35 	"u-boot.img fat 1 1;" \
36 	"uEnv.txt fat 1 1\0"
37 
38 #ifdef CONFIG_NAND
39 #define DFU_ALT_INFO_NAND \
40 	"dfu_alt_info_nand=" \
41 	"SPL part 0 1;" \
42 	"SPL.backup1 part 0 2;" \
43 	"SPL.backup2 part 0 3;" \
44 	"SPL.backup3 part 0 4;" \
45 	"u-boot part 0 5;" \
46 	"u-boot-spl-os part 0 6;" \
47 	"kernel part 0 8;" \
48 	"rootfs part 0 9\0"
49 #else
50 #define DFU_ALT_INFO_NAND ""
51 #endif
52 
53 #define DFU_ALT_INFO_RAM \
54 	"dfu_alt_info_ram=" \
55 	"kernel ram 0x80200000 0x4000000;" \
56 	"fdt ram 0x80f80000 0x80000;" \
57 	"ramdisk ram 0x81000000 0x4000000\0"
58 
59 #define DFU_ALT_INFO_QSPI_XIP \
60 	"dfu_alt_info_qspi=" \
61 	"u-boot.bin raw 0x0 0x080000;" \
62 	"u-boot.backup raw 0x080000 0x080000;" \
63 	"u-boot-spl-os raw 0x100000 0x010000;" \
64 	"u-boot-env raw 0x110000 0x010000;" \
65 	"u-boot-env.backup raw 0x120000 0x010000;" \
66 	"kernel raw 0x130000 0x800000\0"
67 
68 #define DFU_ALT_INFO_QSPI \
69 	"dfu_alt_info_qspi=" \
70 	"MLO raw 0x0 0x040000;" \
71 	"u-boot.img raw 0x040000 0x0100000;" \
72 	"u-boot-spl-os raw 0x140000 0x080000;" \
73 	"u-boot-env raw 0x1C0000 0x010000;" \
74 	"u-boot-env.backup raw 0x1D0000 0x010000;" \
75 	"kernel raw 0x1E0000 0x800000\0"
76