mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
202 lines
6 KiB
Diff
202 lines
6 KiB
Diff
diff -urN a/include/config_distro_defaults.h b/include/config_distro_defaults.h
|
|
--- a/include/config_distro_defaults.h 2014-06-03 11:30:04.000000000 -0600
|
|
+++ b/include/config_distro_defaults.h 2014-06-11 20:20:44.881069479 -0600
|
|
@@ -45,7 +45,7 @@
|
|
|
|
#define CONFIG_CMDLINE_EDITING
|
|
#define CONFIG_AUTO_COMPLETE
|
|
-#define CONFIG_BOOTDELAY 2
|
|
+#define CONFIG_BOOTDELAY 1
|
|
#define CONFIG_SYS_LONGHELP
|
|
#define CONFIG_MENU
|
|
#define CONFIG_DOS_PARTITION
|
|
diff -urN a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
|
|
--- a/include/configs/sunxi-common.h 2014-06-03 11:30:04.000000000 -0600
|
|
+++ b/include/configs/sunxi-common.h 2014-06-11 20:21:15.295967969 -0600
|
|
@@ -126,7 +126,7 @@
|
|
#define CONFIG_SYS_NO_FLASH
|
|
|
|
#define CONFIG_SYS_MONITOR_LEN (512 << 10) /* 512 KiB */
|
|
-#define CONFIG_IDENT_STRING " Allwinner Technology"
|
|
+#define CONFIG_IDENT_STRING " Arch Linux ARM"
|
|
|
|
#define CONFIG_ENV_OFFSET (544 << 10) /* (8 + 24 + 512) KiB */
|
|
#define CONFIG_ENV_SIZE (128 << 10) /* 128 KiB */
|
|
@@ -137,99 +137,55 @@
|
|
#define RUN_BOOT_RAM ""
|
|
#endif
|
|
|
|
-#define CONFIG_BOOTCOMMAND \
|
|
- RUN_BOOT_RAM \
|
|
- "if run loadbootenv; then " \
|
|
- "echo Loaded environment from ${bootenv};" \
|
|
- "env import -t ${scriptaddr} ${filesize};" \
|
|
- "fi;" \
|
|
- "if test -n \\\"${uenvcmd}\\\"; then " \
|
|
- "echo Running uenvcmd ...;" \
|
|
- "run uenvcmd;" \
|
|
- "fi;" \
|
|
- "if run loadbootscr; then "\
|
|
- "echo Jumping to ${bootscr};" \
|
|
- "source ${scriptaddr};" \
|
|
- "fi;" \
|
|
- "run autoboot;" \
|
|
- ""
|
|
-
|
|
#ifdef CONFIG_CMD_WATCHDOG
|
|
#define RESET_WATCHDOG "watchdog 0"
|
|
#else
|
|
#define RESET_WATCHDOG "true"
|
|
#endif
|
|
|
|
+#if defined(CONFIG_CUBIEBOARD2)
|
|
+ #define CONFIG_DEFAULT_FDT_FILE "sun7i-a20-cubieboard2.dtb"
|
|
+#elif defined(CONFIG_CUBIETRUCK)
|
|
+ #define CONFIG_DEFAULT_FDT_FILE "sun7i-a20-cubietruck.dtb"
|
|
+#elif defined(CONFIG_A20_OLINUXINO_M)
|
|
+ #define CONFIG_DEFAULT_FDT_FILE "sun7i-a20-olinuxino-micro.dtb"
|
|
+#elif defined(CONFIG_HACKBERRY)
|
|
+ #define CONFIG_DEFAULT_FDT_FILE "sun4i-a10-hackberry.dtb"
|
|
+#else
|
|
+ #define CONFIG_DEFAULT_FDT_FILE ""
|
|
+#endif
|
|
+
|
|
#define CONFIG_EXTRA_ENV_SETTINGS \
|
|
"bootm_size=0x10000000\0" \
|
|
- "console=ttyS0,115200\0" \
|
|
- "panicarg=panic=10\0" \
|
|
- "extraargs=\0" \
|
|
- "loglevel=8\0" \
|
|
- "scriptaddr=0x44000000\0" \
|
|
- "device=mmc\0" \
|
|
- "partition=0:1\0" \
|
|
- "setargs=" \
|
|
- "if test -z \\\\\"$root\\\\\"; then"\
|
|
- " if test \\\\\"$bootpath\\\\\" = \"/boot/\"; then"\
|
|
- " root=\"/dev/mmcblk0p1 rootwait\";"\
|
|
- " else" \
|
|
- " root=\"/dev/mmcblk0p2 rootwait\";"\
|
|
- " fi;"\
|
|
- " fi;"\
|
|
- " setenv bootargs console=${console} root=${root}" \
|
|
- " loglevel=${loglevel} ${panicarg} ${extraargs}" \
|
|
- "\0" \
|
|
- "kernel=uImage\0" \
|
|
- "bootenv=uEnv.txt\0" \
|
|
- "bootscr=boot.scr\0" \
|
|
- "script=script.bin\0" \
|
|
- "loadbootscr=" \
|
|
- "fatload $device $partition $scriptaddr ${bootscr}" \
|
|
- " || " \
|
|
- "ext2load $device $partition $scriptaddr boot/${bootscr}" \
|
|
- " ||" \
|
|
- "ext2load $device $partition $scriptaddr ${bootscr}" \
|
|
- "\0" \
|
|
- "loadbootenv=" \
|
|
- "fatload $device $partition $scriptaddr ${bootenv}" \
|
|
- " || " \
|
|
- "ext2load $device $partition $scriptaddr boot/${bootenv}" \
|
|
- " || " \
|
|
- "ext2load $device $partition $scriptaddr ${bootenv}" \
|
|
- "\0" \
|
|
- "loadkernel=" \
|
|
- "if "\
|
|
- "bootpath=/boot/" \
|
|
- " && " \
|
|
- "ext2load $device $partition 0x43000000 ${bootpath}${script}" \
|
|
- " && " \
|
|
- "ext2load $device $partition 0x48000000 ${bootpath}${kernel}" \
|
|
- ";then true; elif " \
|
|
- "bootpath=/" \
|
|
- " && " \
|
|
- "fatload $device $partition 0x43000000 ${script}" \
|
|
- " && " \
|
|
- "fatload $device $partition 0x48000000 ${kernel}" \
|
|
- ";then true; elif " \
|
|
- "bootpath=/" \
|
|
- " && " \
|
|
- "ext2load $device $partition 0x43000000 ${bootpath}${script}" \
|
|
- " && " \
|
|
- "ext2load $device $partition 0x48000000 ${bootpath}${kernel}" \
|
|
- ";then true; else "\
|
|
- "false" \
|
|
- ";fi" \
|
|
- "\0" \
|
|
- "autoboot=" \
|
|
- "run loadkernel" \
|
|
- " && " \
|
|
- "run setargs" \
|
|
- " && " \
|
|
- RESET_WATCHDOG \
|
|
- " && " \
|
|
- "bootm 0x48000000" \
|
|
- "\0" \
|
|
+ "console=ttyS0\0" \
|
|
+ "loadaddr=0x48000000\0" \
|
|
+ "scriptaddr=0x43000000\0" \
|
|
+ "fdt_addr=0x44000000\0" \
|
|
+ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \
|
|
+ "optargs=\0" \
|
|
+ "video=\0" \
|
|
+ "mmcdev=0\0" \
|
|
+ "mmcpart=1\0" \
|
|
+ "mmcroot=/dev/mmcblk0p1 rw rootwait\0" \
|
|
+ "mmcargs=setenv bootargs console=${console},${baudrate} " \
|
|
+ "${optargs} " \
|
|
+ "root=${mmcroot} " \
|
|
+ "video=${video}\0" \
|
|
+ "loadbootenv=load mmc ${mmcdev}:${mmcpart} ${loadaddr} /boot/uEnv.txt\0" \
|
|
+ "importbootenv=echo Importing environment from mmc (uEnv.txt)...; " \
|
|
+ "env import -t $loadaddr $filesize\0" \
|
|
+ "loadscript=load mmc ${mmcdev}:${mmcpart} ${scriptaddr} /boot/script.bin\0" \
|
|
+ "loaduimage=load mmc ${mmcdev}:${mmcpart} ${loadaddr} /boot/uImage\0" \
|
|
+ "loadzimage=load mmc ${mmcdev}:${mmcpart} ${loadaddr} /boot/zImage\0" \
|
|
+ "loadfdt=load mmc ${mmcdev}:${mmcpart} ${fdt_addr} /boot/dtbs/${fdt_file}\0" \
|
|
+ "mmcbootm=echo Booting from mmc ...; " \
|
|
+ "run mmcargs; " \
|
|
+ RESET_WATCHDOG ";" \
|
|
+ "bootm ${loadaddr};\0" \
|
|
+ "mmcbootz=echo Booting from mmc ...; " \
|
|
+ "run mmcargs; " \
|
|
+ RESET_WATCHDOG ";" \
|
|
+ "bootz ${loadaddr} - ${fdt_addr};\0" \
|
|
"boot_ram=" \
|
|
"saved_stdout=$stdout;setenv stdout nc;"\
|
|
"if iminfo 0x41000000; then" \
|
|
@@ -238,9 +194,33 @@
|
|
" source 0x41000000;" \
|
|
"else" \
|
|
" setenv stdout $saved_stdout;" \
|
|
- "fi" \
|
|
- "\0" \
|
|
- ""
|
|
+ "fi;\0"
|
|
+
|
|
+#define CONFIG_BOOTCOMMAND \
|
|
+ "run boot_ram;" \
|
|
+ "mmc dev ${mmcdev};" \
|
|
+ "if mmc rescan; then " \
|
|
+ "echo SD/MMC found on device ${mmcdev};" \
|
|
+ "if run loadbootenv; then " \
|
|
+ "run importbootenv;" \
|
|
+ "fi;" \
|
|
+ "echo Checking if uenvcmd is set ...;" \
|
|
+ "if test -n $uenvcmd; then " \
|
|
+ "echo Running uenvcmd ...;" \
|
|
+ "run uenvcmd;" \
|
|
+ "fi;" \
|
|
+ "echo Running default loaduimage ...;" \
|
|
+ "if run loaduimage; then " \
|
|
+ "run loadscript;" \
|
|
+ "run mmcbootm;" \
|
|
+ "fi;" \
|
|
+ "echo Running default loadzimage ...;" \
|
|
+ "if run loadzimage; then " \
|
|
+ "if run loadfdt; then " \
|
|
+ "run mmcbootz;" \
|
|
+ "fi;" \
|
|
+ "fi;" \
|
|
+ "fi;"
|
|
|
|
#define CONFIG_SYS_BOOT_GET_CMDLINE
|
|
|