Add TI DaVinci DM36x (#583)

pull/586/head
Dmitry Ermakov 2022-12-02 21:22:41 +03:00 committed by GitHub
parent a2e2e7b343
commit 2b76afad80
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
63 changed files with 162270 additions and 0 deletions

View File

@ -36,6 +36,7 @@ jobs:
matrix:
platform:
- ak3918ev300
- dm36x
- fh8852v100
- fh8852v200
- gk7102
@ -257,6 +258,9 @@ jobs:
- platform: ak3918ev300
release: lite
custom: onlyci
- platform: dm36x
release: lite
custom: onlyci
- platform: gk7102
release: lite
custom: onlyci

View File

@ -0,0 +1,37 @@
source "$BR2_EXTERNAL_TI_PATH/linux/Config.ext.in"
#source "$BR2_EXTERNAL_TI_PATH/package/ti-osdrv-dm36x/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/ti_patcher/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/aura-httpd/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/comgt/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/dropbear-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/fdk-aac-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/ffmpeg-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/fwprintenv-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/i2c-telemetry/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/ipctool/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/json-c-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/jsonfilter/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/lame-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libcurl-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libevent-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libhv-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libogg-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libsrt-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/libwebsockets-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/linux-firmware-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/majestic-fonts/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/majestic/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/mavfwd/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/mbedtls-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/microbe-web/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/microsnander/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/motors/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/node-exporter/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/opus-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/quirc-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/rtl8188fu-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/uacme-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/vtund-openipc/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/xmdp/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/yaml-cli/Config.in"
source "$BR2_EXTERNAL_TI_PATH/package/zerotier-one/Config.in"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1 @@
../../../../../patches/linux/3.9.x/fix_yylloc_for_modern_host_compilers.patch

View File

@ -0,0 +1 @@
../../../../../patches/linux/3.9.x/gcc8_err_encountered.patch

View File

@ -0,0 +1 @@
../../../../../patches/linux/3.9.x/overlayfs.v17-3.9-rc2.patch

View File

@ -0,0 +1,109 @@
# Architecture
BR2_arm=y
BR2_arm926t=y
BR2_ARM_EABI=y
BR2_ARM_INSTRUCTIONS_THUMB=y
BR2_KERNEL_HEADERS_VERSION=y
BR2_DEFAULT_KERNEL_VERSION="3.9"
BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_9=y
# Toolchain
BR2_PER_PACKAGE_DIRECTORIES=y
BR2_GCC_VERSION_8_X=y
# BR2_TOOLCHAIN_USES_UCLIBC is not set
# BR2_TOOLCHAIN_BUILDROOT_UCLIBC is not set
# BR2_TOOLCHAIN_BUILDROOT_LIBC="uclibc"
# BR2_EXTRA_GCC_CONFIG_OPTIONS=""
BR2_TOOLCHAIN_USES_MUSL=y
BR2_TOOLCHAIN_BUILDROOT_MUSL=y
BR2_TOOLCHAIN_BUILDROOT_LIBC="musl"
BR2_TOOLCHAIN_BUILDROOT_CXX=y
BR2_TOOLCHAIN_BUILDROOT_LOCALE=y
BR2_TOOLCHAIN_BUILDROOT_USE_SSP=y
# Kernel
BR2_LINUX_KERNEL=y
BR2_LINUX_KERNEL_CUSTOM_VERSION=y
BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="3.9"
BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y
BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="$(BR2_EXTERNAL_TI_PATH)/board/dm36x/kernel/dm36x.generic.config"
BR2_LINUX_KERNEL_UIMAGE=y
BR2_LINUX_KERNEL_LZMA=y
BR2_LINUX_KERNEL_EXT_TI_PATCHER=y
BR2_LINUX_KERNEL_EXT_TI_PATCHER_LIST="$(BR2_EXTERNAL_TI_PATH)/board/dm36x/kernel/patches/ $(BR2_EXTERNAL_TI_PATH)/board/dm36x/kernel/overlay"
# Filesystem
# BR2_TARGET_TZ_INFO is not set
BR2_TARGET_ROOTFS_CPIO=y
BR2_TARGET_ROOTFS_SQUASHFS=y
BR2_TARGET_ROOTFS_SQUASHFS4_XZ=y
BR2_ROOTFS_OVERLAY="$(TOPDIR)/../general/overlay"
BR2_ROOTFS_POST_BUILD_SCRIPT="$(TOPDIR)/../scripts/executing_commands_for_$(BR2_TOOLCHAIN_BUILDROOT_LIBC).sh"
# OpenIPC configuration
BR2_TOOLCHAIN_BUILDROOT_VENDOR="openipc"
BR2_TARGET_GENERIC_ISSUE="Welcome to OpenIPC"
BR2_TARGET_GENERIC_HOSTNAME="openipc-dm36x"
BR2_GLOBAL_PATCH_DIR="$(TOPDIR)/../general/package/all-patches"
# OpenIPC packages
BR2_PACKAGE_BUSYBOX_CONFIG="$(TOPDIR)/../general/package/busybox/busybox.config"
BR2_PACKAGE_DROPBEAR_OPENIPC=y
# BR2_PACKAGE_FDK_AAC_OPENIPC is not set
BR2_PACKAGE_FWPRINTENV_OPENIPC=y
# BR2_PACKAGE_TI_OSDRV_DM36X=y
BR2_PACKAGE_HASERL=y
# BR2_PACKAGE_HISI_GPIO is not set
BR2_PACKAGE_IPCTOOL=y
BR2_PACKAGE_JSON_C=y
BR2_PACKAGE_JSONFILTER=y
BR2_PACKAGE_LIBCURL_OPENIPC=y
BR2_PACKAGE_LIBCURL_OPENIPC_CURL=y
# BR2_PACKAGE_LIBCURL_OPENIPC_VERBOSE is not set
# BR2_PACKAGE_LIBCURL_OPENIPC_PROXY_SUPPORT is not set
# BR2_PACKAGE_LIBCURL_OPENIPC_COOKIES_SUPPORT is not set
# BR2_PACKAGE_LIBCURL_OPENIPC_EXTRA_PROTOCOLS_FEATURES is not set
BR2_PACKAGE_LIBCURL_OPENIPC_MBEDTLS=y
BR2_PACKAGE_LIBEVENT_OPENIPC=y
BR2_PACKAGE_LIBEVENT_OPENIPC_REMOVE_PYSCRIPT=y
BR2_PACKAGE_LIBOGG_OPENIPC=y
BR2_PACKAGE_LIBYAML=y
BR2_PACKAGE_MAJESTIC_FONTS=y
# BR2_PACKAGE_MAJESTIC is not set
BR2_PACKAGE_MBEDTLS_OPENIPC=y
# BR2_PACKAGE_MBEDTLS_OPENIPC_PROGRAMS is not set
# BR2_PACKAGE_MBEDTLS_OPENIPC_COMPRESSION is not set
BR2_PACKAGE_MICROBE_WEB=y
# BR2_PACKAGE_MINI_SNMPD is not set
BR2_PACKAGE_MOTORS=y
# BR2_PACKAGE_OPUS_OPENIPC is not set
BR2_PACKAGE_OPUS_OPENIPC_FIXED_POINT=y
# BR2_PACKAGE_SSHPASS is not set
BR2_PACKAGE_UACME_OPENIPC=y
BR2_PACKAGE_VTUND_OPENIPC=y
BR2_PACKAGE_YAML_CLI=y
BR2_PACKAGE_QUIRC_OPENIPC=y
# V4L
BR2_PACKAGE_LIBV4L=y
BR2_PACKAGE_LIBV4L_UTILS=y
# WiFi
BR2_PACKAGE_WIRELESS_TOOLS=y
BR2_PACKAGE_WPA_SUPPLICANT=y
BR2_PACKAGE_WPA_SUPPLICANT_CLI=y
BR2_PACKAGE_WPA_SUPPLICANT_NL80211=y
BR2_PACKAGE_WPA_SUPPLICANT_PASSPHRASE=y
BR2_PACKAGE_LINUX_FIRMWARE_OPENIPC=y
BR2_PACKAGE_LINUX_FIRMWARE_OPENIPC_MT7601U=y
# BR2_PACKAGE_RTL8188EU is not set
# WIREGUARD
# BR2_PACKAGE_WIREGUARD_LINUX_COMPAT is not set
# BR2_PACKAGE_WIREGUARD_TOOLS is not set
# DEBUG
BR2_PACKAGE_HOST_GDB=y
BR2_PACKAGE_GDB=y
BR2_PACKAGE_ZLIB=y

View File

@ -0,0 +1,2 @@
name: TI
desc: Buildroot external tree for TI based IP cameras

View File

@ -0,0 +1,2 @@
include $(BR2_EXTERNAL_TI_PATH)/linux/linux-ext-ti_patcher.mk
include $(sort $(wildcard $(BR2_EXTERNAL_TI_PATH)/package/*/*.mk))

View File

@ -0,0 +1,15 @@
config BR2_LINUX_KERNEL_EXT_TI_PATCHER
bool "TI kernel patches"
select BR2_PACKAGE_TI_PATCHER
help
Patch Kernel for TI boards
if BR2_LINUX_KERNEL_EXT_TI_PATCHER
config BR2_LINUX_KERNEL_EXT_TI_PATCHER_LIST
string "Patch list"
help
Space-separated list of patches to be applied
endif # BR2_LINUX_KERNEL_EXT_TI_PATCHER

View File

@ -0,0 +1,11 @@
################################################################################
#
# linux_kernel_ext_ti_patcher
#
################################################################################
LINUX_EXTENSIONS += ti_patcher
define TI_PATCHER_PREPARE_KERNEL
$(TI_PATCHER_PKGDIR)/apply.sh $(@D) $(BR2_LINUX_KERNEL_EXT_TI_PATCHER_LIST)
endef

View File

@ -0,0 +1 @@
../../general/package/aura-httpd

View File

@ -0,0 +1 @@
../../general/package/aws-producer

View File

@ -0,0 +1 @@
../../general/package/aws-webrtc

View File

@ -0,0 +1 @@
../../general/package/baresip-openipc

View File

@ -0,0 +1 @@
../../general/package/comgt

View File

@ -0,0 +1 @@
../../general/package/dropbear-openipc

View File

@ -0,0 +1 @@
../../general/package/fdk-aac-openipc

View File

@ -0,0 +1 @@
../../general/package/ffmpeg-openipc

View File

@ -0,0 +1 @@
../../general/package/fwprintenv-openipc

View File

@ -0,0 +1 @@
../../general/package/gdbserver-lite

View File

@ -0,0 +1 @@
../../general/package/i2c-telemetry

View File

@ -0,0 +1 @@
../../general/package/ipctool

View File

@ -0,0 +1 @@
../../general/package/json-c-openipc

View File

@ -0,0 +1 @@
../../general/package/jsonfilter

View File

@ -0,0 +1 @@
../../general/package/lame-openipc

View File

@ -0,0 +1 @@
../../general/package/libcurl-openipc

View File

@ -0,0 +1 @@
../../general/package/libevent-openipc

View File

@ -0,0 +1 @@
../../general/package/libhv-openipc

View File

@ -0,0 +1 @@
../../general/package/libogg-openipc

View File

@ -0,0 +1 @@
../../general/package/libre-openipc

View File

@ -0,0 +1 @@
../../general/package/librem-openipc

View File

@ -0,0 +1 @@
../../general/package/libsrt-openipc

View File

@ -0,0 +1 @@
../../general/package/libsrtp-openipc

View File

@ -0,0 +1 @@
../../general/package/libwebsockets-openipc

View File

@ -0,0 +1 @@
../../general/package/linux-firmware-openipc

View File

@ -0,0 +1 @@
../../general/package/majestic

View File

@ -0,0 +1 @@
../../general/package/majestic-fonts

View File

@ -0,0 +1 @@
../../general/package/mavfwd

View File

@ -0,0 +1 @@
../../general/package/mbedtls-openipc

View File

@ -0,0 +1 @@
../../general/package/microbe-web

View File

@ -0,0 +1 @@
../../general/package/microsnander

View File

@ -0,0 +1 @@
../../general/package/motors

View File

@ -0,0 +1 @@
../../general/package/mt7601u-ap-openipc

View File

@ -0,0 +1 @@
../../general/package/node-exporter

View File

@ -0,0 +1 @@
../../general/package/opus-openipc

View File

@ -0,0 +1 @@
../../general/package/quirc-openipc

View File

@ -0,0 +1 @@
../../general/package/rtl8188fu-openipc

View File

@ -0,0 +1 @@
../../general/package/ti_patcher

View File

@ -0,0 +1 @@
../../general/package/uacme-openipc

View File

@ -0,0 +1 @@
../../general/package/uqmi-openipc

View File

@ -0,0 +1 @@
../../general/package/usrsctp

View File

@ -0,0 +1 @@
../../general/package/vtund-openipc

View File

@ -0,0 +1 @@
../../general/package/xmdp

View File

@ -0,0 +1 @@
../../general/package/yaml-cli

View File

@ -0,0 +1 @@
../../general/package/zerotier-one

View File

@ -0,0 +1,3 @@
config BR2_PACKAGE_TI_PATCHER
bool

View File

@ -0,0 +1,44 @@
#!/bin/bash
function log() {
echo "--- $@"
}
function apply_patch() {
DST=$1
SRC=$2
if [[ -d $SRC ]]; then
if [[ ${SRC:${#SRC}-1} != '/' ]]; then
log Apply \"$SRC\" as overlay directory
cp -r $SRC/* $DST/
else
log Apply \"$SRC\" as patches directory
for P in $SRC/*.patch; do
patch -d $DST -p1 < $P
done
fi
else
log Apply \"$SRC\" as single patch
patch -d $DST -p1 < $SRC
fi
}
function apply_patches() {
log Gonna apply "$@"
while [[ $# -ge 1 ]]; do
apply_patch $DST $1
shift
done
}
DST=$1
shift
if [ -f $DST/.ti-patched ]; then
log Patched already
exit
fi
apply_patches $@
touch $DST/.ti-patched

View File

@ -0,0 +1,12 @@
################################################################################
#
# ti_patcher
#
################################################################################
TI_PATCHER_VERSION = 0.1
TI_PATCHER_INSTALL_TARGET = NO
TI_PATCHER_SITE =
TI_PATCHER_SOURCE =
$(eval $(generic-package))

View File

@ -0,0 +1,54 @@
diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
index 3b41bfc..5e62bc0 100644
--- a/scripts/dtc/dtc-lexer.l
+++ b/scripts/dtc/dtc-lexer.l
@@ -39,7 +39,7 @@ LINECOMMENT "//".*\n
#include "srcpos.h"
#include "dtc-parser.tab.h"
-YYLTYPE yylloc;
+YYLTYPE yylloc ;
/* CAUTION: this will stop working if we ever use yyless() or yyunput() */
#define YY_USER_ACTION \
diff --git a/scripts/dtc/dtc-lexer.lex.c_shipped b/scripts/dtc/dtc-lexer.lex.c_shipped
index 2d30f41..e073c9b 100644
--- a/scripts/dtc/dtc-lexer.lex.c_shipped
+++ b/scripts/dtc/dtc-lexer.lex.c_shipped
@@ -637,7 +637,9 @@ char *yytext;
#include "srcpos.h"
#include "dtc-parser.tab.h"
-YYLTYPE yylloc;
+#if (__GNUC__ << 16) + __GNUC_MINOR__ < 0x1000000
+extern YYLTYPE yylloc ;
+#endif
/* CAUTION: this will stop working if we ever use yyless() or yyunput() */
#define YY_USER_ACTION \
diff --git a/scripts/dtc/dtc-parser.tab.c_shipped b/scripts/dtc/dtc-parser.tab.c_shipped
index c8769d5..f7fbb2e 100644
--- a/scripts/dtc/dtc-parser.tab.c_shipped
+++ b/scripts/dtc/dtc-parser.tab.c_shipped
@@ -70,7 +70,7 @@
#include "dtc.h"
#include "srcpos.h"
-YYLTYPE yylloc;
+YYLTYPE yylloc ;
extern int yylex(void);
extern void print_error(char const *fmt, ...);
diff --git a/scripts/dtc/dtc-parser.y b/scripts/dtc/dtc-parser.y
index f412460..e00a3c4 100644
--- a/scripts/dtc/dtc-parser.y
+++ b/scripts/dtc/dtc-parser.y
@@ -24,7 +24,7 @@
#include "dtc.h"
#include "srcpos.h"
-YYLTYPE yylloc;
+YYLTYPE yylloc ;
extern int yylex(void);
extern void print_error(char const *fmt, ...);

View File

@ -0,0 +1,21 @@
--- a/arch/arm/include/asm/uaccess.h
+++ b/arch/arm/include/asm/uaccess.h
@@ -121,7 +121,7 @@
#define __get_user_check(x,p) \
({ \
unsigned long __limit = current_thread_info()->addr_limit - 1; \
- register const typeof(*(p)) __user *__p asm("r0") = (p);\
+ register typeof(*(p)) __user *__p asm("r0") = (p);\
register unsigned long __r2 asm("r2"); \
register unsigned long __l asm("r1") = __limit; \
register int __e asm("r0"); \
@@ -165,7 +165,7 @@
({ \
unsigned long __limit = current_thread_info()->addr_limit - 1; \
- register const typeof(*(p)) __r2 asm("r2") = (x); \
- register const typeof(*(p)) __user *__p asm("r0") = (p);\
+ register typeof(*(p)) __r2 asm("r2") = (x); \
+ register typeof(*(p)) __user *__p asm("r0") = (p); \
register unsigned long __l asm("r1") = __limit; \
register int __e asm("r0"); \
switch (sizeof(*(__p))) { \

File diff suppressed because it is too large Load Diff