diff options
author | Tomasz Maciej Nowak <tomek_n@o2.pl> | 2019-04-01 19:25:41 +0200 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2019-04-06 14:48:46 +0200 |
commit | 1b3dda179a6b2ec819aa3f863662c6f00f89c961 (patch) | |
tree | 4d20c71d568d3ef498aceccff8bda921e0147ce1 /package/boot/uboot-tegra | |
parent | b8744376445692062c7d4e59a9814dc70c76a88d (diff) | |
download | upstream-1b3dda179a6b2ec819aa3f863662c6f00f89c961.tar.gz upstream-1b3dda179a6b2ec819aa3f863662c6f00f89c961.tar.bz2 upstream-1b3dda179a6b2ec819aa3f863662c6f00f89c961.zip |
uboot-tegra: add U-Boot for tegra boards
Add U-Boot for NVIDIA Tegra based boards, with the first being CompuLab
TrimSlice. This is part of initial support for this board.
Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Diffstat (limited to 'package/boot/uboot-tegra')
-rw-r--r-- | package/boot/uboot-tegra/Makefile | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/package/boot/uboot-tegra/Makefile b/package/boot/uboot-tegra/Makefile new file mode 100644 index 0000000000..191d108771 --- /dev/null +++ b/package/boot/uboot-tegra/Makefile @@ -0,0 +1,64 @@ +# +# Copyright (C) 2017-2019 Tomasz Maciej Nowak <tomek_n@o2.pl> +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# +include $(TOPDIR)/rules.mk + +PKG_VERSION := 2019.01 +PKG_RELEASE := 1 + +PKG_HASH := 50bd7e5a466ab828914d080d5f6a432345b500e8fba1ad3b7b61e95e60d51c22 + +PKG_MAINTAINER := Tomasz Maciej Nowak <tomek_n@o2.pl> + +include $(INCLUDE_DIR)/u-boot.mk +include $(INCLUDE_DIR)/package.mk + +define U-Boot/Default + BUILD_TARGET := tegra + HIDDEN := y +endef + +define U-Boot/trimslice + NAME := CompuLab TrimSlice + BUILD_DEVICES := trimslice + UBOOT_IMAGE := trimslice-mmc.img trimslice-spi.img + SOC := tegra20 + VENDOR := compulab +endef + +UBOOT_TARGETS := trimslice + +define Build/bct-image + $(CP) $(PKG_BUILD_DIR)/u-boot-dtb-tegra.bin $(PKG_BUILD_DIR)/u-boot.bin + $(foreach bct,$(basename $(UBOOT_IMAGE)), \ + cd $(PKG_BUILD_DIR); \ + cbootimage -s $(SOC) -gbct \ + $(STAGING_DIR_HOST)/share/cbootimage-configs/$(SOC)/$(VENDOR)/$(VARIANT)/$(bct).bct.cfg \ + $(bct).bct; \ + cbootimage -s $(SOC) \ + $(STAGING_DIR_HOST)/share/cbootimage-configs/$(SOC)/$(VENDOR)/$(VARIANT)/$(bct).img.cfg \ + $(PKG_BUILD_DIR)/$(bct).img; \ + rm -f $(bct).bct; \ + ) +endef + +define Build/Configure + sed '/select BINMAN/d' -i $(PKG_BUILD_DIR)/arch/arm/mach-tegra/Kconfig + $(call Build/Configure/U-Boot) +endef + +define Build/Compile + $(call Build/Compile/U-Boot) + $(call Build/bct-image) +endef + +define Build/InstallDev + $(INSTALL_DIR) $(STAGING_DIR_IMAGE) + $(foreach img,$(UBOOT_IMAGE), \ + $(CP) $(PKG_BUILD_DIR)/$(img) $(STAGING_DIR_IMAGE)/;) +endef + +$(eval $(call BuildPackage/U-Boot)) |