diff options
author | Ian Lepore <ian@FreeBSD.org> | 2014-12-22 15:07:53 +0000 |
---|---|---|
committer | Ian Lepore <ian@FreeBSD.org> | 2014-12-22 15:07:53 +0000 |
commit | 6a8d5a268e5325be8597af2e6f6012e94fd79647 (patch) | |
tree | 2e945752f1165f51852ef1067f925246dfff41a5 /sysutils/u-boot-beaglebone | |
parent | 4ecbb0c75bc728daff01eed0c8f14113ef6ff5b9 (diff) |
Notes
Diffstat (limited to 'sysutils/u-boot-beaglebone')
-rw-r--r-- | sysutils/u-boot-beaglebone/Makefile | 6 | ||||
-rw-r--r-- | sysutils/u-boot-beaglebone/files/patch-include_configs_am335x__evm.h | 66 |
2 files changed, 33 insertions, 39 deletions
diff --git a/sysutils/u-boot-beaglebone/Makefile b/sysutils/u-boot-beaglebone/Makefile index 8cec4289cd1e..e56db592c1a6 100644 --- a/sysutils/u-boot-beaglebone/Makefile +++ b/sysutils/u-boot-beaglebone/Makefile @@ -20,7 +20,7 @@ USES= gmake tar:bzip2 SSP_UNSAFE= yes # cross-LD does not support -fstack-protector U_BOOT_DIR= share/u-boot/${PORTNAME}${PKGNAMESUFFIX} -PLIST_FILES= ${U_BOOT_DIR}/bb-uboot.img \ +PLIST_FILES= ${U_BOOT_DIR}/u-boot.img \ ${U_BOOT_DIR}/MLO \ ${U_BOOT_DIR}/README @@ -28,12 +28,12 @@ MAKE_ARGS+= ARCH=arm \ CROSS_COMPILE=arm-none-eabi- do-configure: - (cd ${WRKSRC}; ${GMAKE} am335x_evm_config) + (cd ${WRKSRC}; ${GMAKE} am335x_boneblack_defconfig) do-install: ${MKDIR} ${STAGEDIR}/${PREFIX}/${U_BOOT_DIR} ${CP} ${WRKSRC}/MLO ${STAGEDIR}/${PREFIX}/${U_BOOT_DIR} - ${CP} ${WRKSRC}/u-boot.img ${STAGEDIR}/${PREFIX}/${U_BOOT_DIR}/bb-uboot.img + ${CP} ${WRKSRC}/u-boot.img ${STAGEDIR}/${PREFIX}/${U_BOOT_DIR}/u-boot.img ${CP} ${.CURDIR}/pkg-descr ${STAGEDIR}/${PREFIX}/${U_BOOT_DIR}/README .include <bsd.port.mk> diff --git a/sysutils/u-boot-beaglebone/files/patch-include_configs_am335x__evm.h b/sysutils/u-boot-beaglebone/files/patch-include_configs_am335x__evm.h index deb61c3838f1..add727fd84b6 100644 --- a/sysutils/u-boot-beaglebone/files/patch-include_configs_am335x__evm.h +++ b/sysutils/u-boot-beaglebone/files/patch-include_configs_am335x__evm.h @@ -1,6 +1,6 @@ --- include/configs/am335x_evm.h.orig 2014-10-14 08:47:15 UTC +++ include/configs/am335x_evm.h -@@ -479,4 +479,82 @@ +@@ -479,4 +479,76 @@ #endif #endif /* NOR support */ @@ -8,78 +8,72 @@ + * FreeBSD customizations from here down. + ****************************************************************************/ + -+/* No watchdog. (Why?) */ -+#undef CONFIG_HW_WATCHDOG -+#undef CONFIG_OMAP_WATCHDOG -+#undef CONFIG_SPL_WATCHDOG_SUPPORT -+ +/* Add the API and ELF features needed for ubldr. */ +#ifndef CONFIG_SPL_BUILD +#define CONFIG_API +#define CONFIG_CMD_ELF +#define CONFIG_CMD_ENV_EXISTS +#define CONFIG_EFI_PARTITION -+#define CONFIG_PREBOOT +#define CONFIG_SYS_MMC_MAX_DEVICE 2 +#endif + -+/* SPL loads bb-uboot.img. */ -+#ifdef CONFIG_SPL_BUILD -+#undef CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME -+#define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME "bb-uboot.img" -+#endif -+ +/* Save the env to the fat partition. */ +#ifndef CONFIG_SPL_BUILD +#undef CONFIG_ENV_IS_NOWHERE +#undef CONFIG_ENV_IS_IN_NAND ++#undef CONFIG_ENV_IS_IN_MMC +#define CONFIG_ENV_IS_IN_FAT +#define CONFIG_FAT_WRITE +#define FAT_ENV_INTERFACE "mmc" +#define FAT_ENV_DEVICE_AND_PART "0" -+#define FAT_ENV_FILE "uboot.env" ++#define FAT_ENV_FILE "u-boot.env" +#endif + +/* Create a small(ish) boot environment for FreeBSD. */ +#ifndef CONFIG_SPL_BUILD +#undef CONFIG_EXTRA_ENV_SETTINGS +#define CONFIG_EXTRA_ENV_SETTINGS \ -+ "bootfile=bbubldr\0" \ -+ "fdt_file=undefined\0" \ -+ "fatdev=mmc 0:1\0" \ -+ "loadaddr=0x88000000\0" \ -+ "loaderdev=disk\0" \ -+ "uenv_file=bb-uEnv.txt\0" \ -+ \ -+ "fatboot=" \ -+ "env exists user_fatboot && run user_fatboot; " \ ++ "loadaddr=88000000\0" \ ++ "Fatboot=" \ ++ "env exists loaderdev || env set loaderdev ${fatdev}; " \ ++ "env exists UserFatboot && run UserFatboot; " \ ++ "echo Booting from: ${fatdev} ${bootfile}; " \ + "fatload ${fatdev} ${loadaddr} ${bootfile} && bootelf; " \ + "\0" \ -+ "netboot=" \ -+ "env exists user_netboot && run user_netboot; " \ ++ "Netboot=" \ ++ "env exists loaderdev || env set loaderdev net; " \ ++ "env exists UserNetboot && run UserNetboot; " \ + "dhcp ${loadaddr} ${bootfile} && bootelf; " \ + "\0" \ -+ "preboot=" \ -+ "env exists setfdt && run setfdt; " \ -+ "env exists uenv_import && run uenv_import; " \ -+ "env exists user_preboot && run user_preboot; " \ ++ "Preboot=" \ ++ "env exists bootfile || bootfile=ubldr; " \ ++ "env exists uenv_file || uenv_file=uEnv.txt; " \ ++ "env exists SetupFdtfile && run SetupFdtfile; " \ ++ "env exists SetupFatdev && run SetupFatdev; " \ ++ "env exists SetupUenv && run SetupUenv; " \ ++ "env exists UserPreboot && run UserPreboot; " \ + "\0" \ -+ "setfdt=" \ ++ "SetupFdtfile=" \ + "if test ${board_name} = A335BONE; then " \ -+ "env set fdt_file bbone.dtb; " \ ++ "env set fdt_file beaglebone.dtb; " \ + "elif test ${board_name} = A335BNLT; then " \ -+ "env set fdt_file bboneblk.dtb; " \ -+ "else " \ -+ "echo WARNING: Could not determine device tree to use; " \ ++ "env set fdt_file beaglebone-black.dtb; " \ + "fi; " \ + "\0" \ -+ "uenv_import=" \ ++ "SetupFatdev=" \ ++ "env exists fatdev || " \ ++ "fatsize ${fatdev:=mmc 0} ${bootfile} || " \ ++ "fatdev='mmc 1'; " \ ++ "\0" \ ++ "SetupUenv=" \ + "fatload ${fatdev} ${loadaddr} ${uenv_file} && " \ + "env import -t ${loadaddr} ${filesize}; " \ + "\0" + +#undef CONFIG_BOOTCOMMAND -+#define CONFIG_BOOTCOMMAND "run fatboot" ++#define CONFIG_BOOTCOMMAND "run Fatboot" ++#undef CONFIG_PREBOOT ++#define CONFIG_PREBOOT "run Preboot" +#endif + #endif /* ! __CONFIG_AM335X_EVM_H */ |