2014-10-15 00:48:49 +00:00
|
|
|
From b51bfda152ff4f738a96a0864cac2b4b039500e8 Mon Sep 17 00:00:00 2001
|
2014-10-14 05:46:23 +00:00
|
|
|
From: Dennis Gilmore <dennis@ausil.us>
|
|
|
|
Date: Mon, 13 Oct 2014 23:58:13 -0500
|
2014-10-15 00:48:49 +00:00
|
|
|
Subject: [PATCH 11/11] port utilite to distro generic boot commands
|
2014-10-14 05:46:23 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
include/configs/cm_fx6.h | 112 +++++++++++------------------------------------
|
|
|
|
1 file changed, 26 insertions(+), 86 deletions(-)
|
|
|
|
|
|
|
|
diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h
|
2014-10-15 00:48:49 +00:00
|
|
|
index 7cf241e..3c7615f 100644
|
2014-10-14 05:46:23 +00:00
|
|
|
--- a/include/configs/cm_fx6.h
|
|
|
|
+++ b/include/configs/cm_fx6.h
|
|
|
|
@@ -12,7 +12,6 @@
|
|
|
|
#define __CONFIG_CM_FX6_H
|
|
|
|
|
|
|
|
#include <asm/arch/imx-regs.h>
|
|
|
|
-#include <config_distro_defaults.h>
|
|
|
|
#include "mx6_common.h"
|
|
|
|
|
|
|
|
/* Machine config */
|
|
|
|
@@ -92,98 +91,39 @@
|
|
|
|
#define CONFIG_ENV_SIZE (8 * 1024)
|
|
|
|
#define CONFIG_ENV_OFFSET (768 * 1024)
|
|
|
|
|
|
|
|
+#ifndef CONFIG_SPL_BUILD
|
|
|
|
+#include <config_distro_defaults.h>
|
|
|
|
+#include <config_distro_bootcmd.h>
|
|
|
|
+
|
|
|
|
+#ifdef CONFIG_AHCI
|
|
|
|
+#define BOOT_TARGET_DEVICES_SCSI(func) func(SCSI, scsi, 0)
|
|
|
|
+#else
|
|
|
|
+#define BOOT_TARGET_DEVICES_SCSI(func)
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
+#define BOOT_TARGET_DEVICES(func) \
|
|
|
|
+ func(MMC, mmc, 2) \
|
|
|
|
+ BOOT_TARGET_DEVICES_SCSI(func) \
|
|
|
|
+ func(PXE, pxe, na) \
|
|
|
|
+ func(DHCP, dhcp, na)
|
|
|
|
+
|
|
|
|
#define CONFIG_EXTRA_ENV_SETTINGS \
|
|
|
|
- "kernel=uImage-cm-fx6\0" \
|
|
|
|
- "autoload=no\0" \
|
|
|
|
"loadaddr=0x10800000\0" \
|
|
|
|
"fdtaddr=0x11000000\0" \
|
|
|
|
+ "fdt_addr_r=0x18000000\0" \
|
|
|
|
+ "pxefile_addr_r=0x17f00000\0" \
|
|
|
|
+ "scriptaddr=0x17e00000\0" \
|
|
|
|
+ "kernel_addr_r=0x11000000\0" \
|
|
|
|
+ "ramdisk_addr_r=0x18100000\0" \
|
|
|
|
+ "bootm_size=0x20000000\0" \
|
|
|
|
"console=ttymxc3,115200\0" \
|
|
|
|
"ethprime=FEC0\0" \
|
|
|
|
- "bootscr=boot.scr\0" \
|
|
|
|
- "bootm_low=18000000\0" \
|
|
|
|
- "video_hdmi=mxcfb0:dev=hdmi,1920x1080M-32@50,if=RGB32\0" \
|
|
|
|
- "video_dvi=mxcfb0:dev=dvi,1280x800M-32@50,if=RGB32\0" \
|
|
|
|
"fdtfile=cm-fx6.dtb\0" \
|
|
|
|
- "doboot=bootm ${loadaddr}\0" \
|
|
|
|
- "loadfdt=false\0" \
|
|
|
|
- "setboottypez=setenv kernel zImage-cm-fx6;" \
|
|
|
|
- "setenv doboot bootz ${loadaddr} - ${fdtaddr};" \
|
|
|
|
- "setenv loadfdt true;\0" \
|
|
|
|
- "setboottypem=setenv kernel uImage-cm-fx6;" \
|
|
|
|
- "setenv doboot bootm ${loadaddr};" \
|
|
|
|
- "setenv loadfdt false;\0"\
|
|
|
|
- "run_eboot=echo Starting EBOOT ...; "\
|
|
|
|
- "mmc dev ${mmcdev} && " \
|
|
|
|
- "mmc rescan && mmc read 10042000 a 400 && go 10042000\0" \
|
|
|
|
- "mmcdev=2\0" \
|
|
|
|
- "mmcroot=/dev/mmcblk0p2 rw rootwait\0" \
|
|
|
|
- "loadmmcbootscript=load mmc ${mmcdev} ${loadaddr} ${bootscr}\0" \
|
|
|
|
- "mmcbootscript=echo Running bootscript from mmc ...; "\
|
|
|
|
- "source ${loadaddr}\0" \
|
|
|
|
- "mmcargs=setenv bootargs console=${console} " \
|
|
|
|
- "root=${mmcroot} " \
|
|
|
|
- "${video}\0" \
|
|
|
|
- "mmcloadkernel=load mmc ${mmcdev} ${loadaddr} ${kernel}\0" \
|
|
|
|
- "mmcloadfdt=load mmc ${mmcdev} ${fdtaddr} ${fdtfile}\0" \
|
|
|
|
- "mmcboot=echo Booting from mmc ...; " \
|
|
|
|
- "run mmcargs; " \
|
|
|
|
- "run doboot\0" \
|
|
|
|
- "satadev=0\0" \
|
|
|
|
- "sataroot=/dev/sda2 rw rootwait\0" \
|
|
|
|
- "sataargs=setenv bootargs console=${console} " \
|
|
|
|
- "root=${sataroot} " \
|
|
|
|
- "${video}\0" \
|
|
|
|
- "loadsatabootscript=load sata ${satadev} ${loadaddr} ${bootscr}\0" \
|
|
|
|
- "satabootscript=echo Running bootscript from sata ...; " \
|
|
|
|
- "source ${loadaddr}\0" \
|
|
|
|
- "sataloadkernel=load sata ${satadev} ${loadaddr} ${kernel}\0" \
|
|
|
|
- "sataloadfdt=load sata ${satadev} ${fdtaddr} ${fdtfile}\0" \
|
|
|
|
- "sataboot=echo Booting from sata ...; "\
|
|
|
|
- "run sataargs; " \
|
|
|
|
- "run doboot\0" \
|
|
|
|
- "nandroot=/dev/mtdblock4 rw\0" \
|
|
|
|
- "nandrootfstype=ubifs\0" \
|
|
|
|
- "nandargs=setenv bootargs console=${console} " \
|
|
|
|
- "root=${nandroot} " \
|
|
|
|
- "rootfstype=${nandrootfstype} " \
|
|
|
|
- "${video}\0" \
|
|
|
|
- "nandloadfdt=nand read ${fdtaddr} 780000 80000;\0" \
|
|
|
|
- "nandboot=echo Booting from nand ...; " \
|
|
|
|
- "run nandargs; " \
|
|
|
|
- "nand read ${loadaddr} 0 780000; " \
|
|
|
|
- "if ${loadfdt}; then " \
|
|
|
|
- "run nandloadfdt;" \
|
|
|
|
- "fi; " \
|
|
|
|
- "run doboot\0" \
|
|
|
|
- "boot=mmc dev ${mmcdev}; " \
|
|
|
|
- "if mmc rescan; then " \
|
|
|
|
- "if run loadmmcbootscript; then " \
|
|
|
|
- "run mmcbootscript;" \
|
|
|
|
- "else " \
|
|
|
|
- "if run mmcloadkernel; then " \
|
|
|
|
- "if ${loadfdt}; then " \
|
|
|
|
- "run mmcloadfdt;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "run mmcboot;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "if sata init; then " \
|
|
|
|
- "if run loadsatabootscript; then " \
|
|
|
|
- "run satabootscript;" \
|
|
|
|
- "else "\
|
|
|
|
- "if run sataloadkernel; then " \
|
|
|
|
- "if ${loadfdt}; then " \
|
|
|
|
- "run sataloadfdt; " \
|
|
|
|
- "fi;" \
|
|
|
|
- "run sataboot;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "fi;" \
|
|
|
|
- "run nandboot\0"
|
|
|
|
+ BOOTENV
|
|
|
|
|
|
|
|
-#define CONFIG_BOOTCOMMAND \
|
|
|
|
- "run setboottypem; run boot"
|
|
|
|
+#else /* ifndef CONFIG_SPL_BUILD */
|
|
|
|
+#define CONFIG_EXTRA_ENV_SETTINGS
|
|
|
|
+#endif
|
|
|
|
|
|
|
|
/* SPI */
|
|
|
|
#define CONFIG_SPI
|
|
|
|
--
|
|
|
|
2.1.0
|
|
|
|
|