u-boot-nanopi-r2s: Import u-boot-nanopi-r2s-2020.07 as wip/u-boot-nanopi-r2s
U-Boot is a bootloader for embedded boards based on PowerPC, ARM, MIPS and several other processors, which can be installed in a boot ROM and used to initialize and test the hardware or to download and run application code. This package provides U-Boot for the FriendlyElec NanoPi R2S.
This commit is contained in:
parent
6374e5ad44
commit
e7bc8c39bf
1
Makefile
1
Makefile
|
@ -4824,6 +4824,7 @@ SUBDIR+= typespeed
|
|||
SUBDIR+= typhoon
|
||||
SUBDIR+= u-boot
|
||||
SUBDIR+= u-boot-full
|
||||
SUBDIR+= u-boot-nanopi-r2s
|
||||
SUBDIR+= u-boot-orangepi-pc
|
||||
SUBDIR+= u-boot-pinebook-crust
|
||||
SUBDIR+= uTox-git
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
U-Boot is a bootloader for embedded boards based on PowerPC, ARM, MIPS and
|
||||
several other processors, which can be installed in a boot ROM and used to
|
||||
initialize and test the hardware or to download and run application code.
|
||||
|
||||
This package provides U-Boot for the FriendlyElec NanoPi R2S.
|
|
@ -0,0 +1,30 @@
|
|||
# $NetBSD: Makefile,v 1.1 2020/06/30 14:40:05 thorpej Exp $
|
||||
|
||||
UBOOT_TARGET= nanopi-r2s
|
||||
UBOOT_CONFIG= nanopi-r2s-rk3328_defconfig
|
||||
UBOOT_BIN= u-boot-rockchip.bin
|
||||
|
||||
UBOOT_INSTALLBOOT_PLIST= installboot.plist
|
||||
|
||||
UBOOT_VERSION= 2020.07
|
||||
MASTER_SITES= ${MASTER_SITE_GITHUB:=blocktrron/}
|
||||
GITHUB_PROJECT= uboot-nanopi-r2s
|
||||
GITHUB_TAG= b8c2aded187e23779a9f565d3577cd46027f0946
|
||||
|
||||
DISTINFO_FILE= ${.CURDIR}/../../wip/u-boot-nanopi-r2s/distinfo
|
||||
PATCHDIR= ${.CURDIR}/../../wip/u-boot-nanopi-r2s/patches
|
||||
DISTFILES= ${DEFAULT_DISTFILES}
|
||||
EXTRACT_SUFX= .tar.gz # keep
|
||||
|
||||
# This could be moved to u-boot.mk as long as we don't have support for
|
||||
# any imx8 boards.
|
||||
CHECK_PORTABILITY_SKIP+= tools/imx8m_image.sh
|
||||
|
||||
# Switch to EL1 before booting kernel (required for 32-bit support)
|
||||
PKG_DEFAULT_OPTIONS+= el1
|
||||
|
||||
post-extract:
|
||||
${CP} ${PREFIX}/share/arm-trusted-firmware/rk3328/bl31.elf ${WRKSRC}
|
||||
|
||||
.include "../../sysutils/arm-trusted-firmware-rk3328/buildlink3.mk"
|
||||
.include "../../sysutils/u-boot/u-boot-arm64.mk"
|
|
@ -0,0 +1,3 @@
|
|||
@comment $NetBSD$
|
||||
share/u-boot/nanopi-r2s/installboot.plist
|
||||
share/u-boot/nanopi-r2s/u-boot-rockchip.bin
|
|
@ -0,0 +1,6 @@
|
|||
* There's a Linux dts patch to add support for the USB3.0 bus required for the
|
||||
RTL8153, not sure if it would be worth adding the patch to U-Boot
|
||||
(patch url: https://gitlab.manjaro.org/manjaro-arm/packages/core/linux/-/raw/3e1568437d566bc49c49e68062c7b8bd75fa6e73/0002-arm64-dts-rockchip-add-usb3-controller-node-for-RK33.patch)
|
||||
* There was some effort to get this device upstreamed in U-Boot
|
||||
(https://lists.denx.de/pipermail/u-boot/2020-July/420889.html), if/when
|
||||
that happens this package should use upstream instead
|
|
@ -0,0 +1,7 @@
|
|||
$NetBSD: distinfo,v 1.1 2020/06/30 14:40:05 thorpej Exp $
|
||||
|
||||
SHA1 (u-boot-2020.07-b8c2aded187e23779a9f565d3577cd46027f0946.tar.gz) = bfb3012d6a9c8f3f4c607966c928bed707e2f339
|
||||
RMD160 (u-boot-2020.07-b8c2aded187e23779a9f565d3577cd46027f0946.tar.gz) = ace45cd6c0eed70675690ae22456b6da32fca30f
|
||||
SHA512 (u-boot-2020.07-b8c2aded187e23779a9f565d3577cd46027f0946.tar.gz) = 6c45cb274132b3b4acb8c17e00b29e7c9106b57b05d861a408abdee083ab499ee67ecc9eaafc9082e1c07b4f431e790ad810abae7574b0a82043a7830a56dc96
|
||||
Size (u-boot-2020.07-b8c2aded187e23779a9f565d3577cd46027f0946.tar.gz) = 19693336 bytes
|
||||
SHA1 (patch-include_image.h) = 46f9efc0b9bbeea407e18f2b7e02b265dc0b58e1
|
|
@ -0,0 +1,47 @@
|
|||
<!-- $NetBSD: installboot.plist,v 1.1 2020/06/30 14:40:05 thorpej Exp $ -->
|
||||
<!--
|
||||
Copyright (c) 2020 The NetBSD Foundation, Inc.
|
||||
All rights reserved.
|
||||
|
||||
This code is derived from software contributed to The NetBSD Foundation
|
||||
by Jason R. Thorpe.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
1. Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
2. Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
|
||||
``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
|
||||
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGE.
|
||||
-->
|
||||
<plist>
|
||||
<dict>
|
||||
<key>friendlyarm,nanopi-r2s</key>
|
||||
<dict>
|
||||
<key>description</key>
|
||||
<string>FriendlyElec NanoPi R2S</string>
|
||||
<key>u-boot-install</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>file-name</key>
|
||||
<string>u-boot-rockchip.bin</string>
|
||||
<key>image-offset</key>
|
||||
<integer>32768</integer>
|
||||
</dict>
|
||||
</array>
|
||||
</dict>
|
||||
</dict>
|
||||
</plist>
|
|
@ -0,0 +1,37 @@
|
|||
$NetBSD: patch-include_image.h,v 1.1 2020/06/30 14:40:05 thorpej Exp $
|
||||
|
||||
Ensure the correct byte order macros are used when image.h is included
|
||||
in a host tool.
|
||||
|
||||
--- include/image.h.orig 2020-06-20 13:48:00.000000000 +0000
|
||||
+++ include/image.h 2020-06-20 13:51:12.000000000 +0000
|
||||
@@ -16,7 +16,6 @@
|
||||
#define __IMAGE_H__
|
||||
|
||||
#include "compiler.h"
|
||||
-#include <asm/byteorder.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
/* Define this to avoid #ifdefs later on */
|
||||
@@ -26,6 +25,13 @@ struct fdt_region;
|
||||
#ifdef USE_HOSTCC
|
||||
#include <sys/types.h>
|
||||
|
||||
+#include <endian.h>
|
||||
+#if _BYTE_ORDER == _BIG_ENDIAN
|
||||
+# include <linux/byteorder/big_endian.h>
|
||||
+#else
|
||||
+# include <linux/byteorder/little_endian.h>
|
||||
+#endif
|
||||
+
|
||||
/* new uImage format support enabled on host */
|
||||
#define IMAGE_ENABLE_FIT 1
|
||||
#define IMAGE_ENABLE_OF_LIBFDT 1
|
||||
@@ -40,6 +46,7 @@ struct fdt_region;
|
||||
|
||||
#else
|
||||
|
||||
+#include <asm/byteorder.h>
|
||||
#include <lmb.h>
|
||||
#include <asm/u-boot.h>
|
||||
#include <command.h>
|
Loading…
Reference in New Issue