amazon-tank: new device (Amazon Fire TV Stick) (!939)
This commit is contained in:
parent
efd8c6cde2
commit
9d9f36604d
24
device/device-amazon-tank/APKBUILD
Normal file
24
device/device-amazon-tank/APKBUILD
Normal file
|
@ -0,0 +1,24 @@
|
|||
# Reference: <https://postmarketos.org/devicepkg>
|
||||
# Contributor: Federico Amedeo Izzo <federico.izzo42@gmail.com>
|
||||
pkgname="device-amazon-tank"
|
||||
pkgdesc="Amazon Fire TV Stick (2nd Gen)"
|
||||
pkgver=0.1
|
||||
pkgrel=0
|
||||
url="https://postmarketos.org"
|
||||
license="MIT"
|
||||
arch="armv7"
|
||||
options="!check !archcheck"
|
||||
depends="postmarketos-base linux-amazon-tank mkbootimg mesa-dri-swrast"
|
||||
makedepends="devicepkg-dev"
|
||||
source="deviceinfo"
|
||||
|
||||
build() {
|
||||
devicepkg_build $startdir $pkgname
|
||||
}
|
||||
|
||||
package() {
|
||||
devicepkg_package $startdir $pkgname
|
||||
}
|
||||
|
||||
|
||||
sha512sums="9db55fdf7012d2b7be1bf54fa13a21f8eee9a6c3f8adc4d0e82a344bbd6f0cbff458e4f9125e8bb38dd4a1377c1c27ceed80c8dc2890cbd9b7b7b5b68cfd6a68 deviceinfo"
|
34
device/device-amazon-tank/deviceinfo
Normal file
34
device/device-amazon-tank/deviceinfo
Normal file
|
@ -0,0 +1,34 @@
|
|||
# Reference: <https://postmarketos.org/deviceinfo>
|
||||
# Please use double quotes only. You can source this file in shell scripts.
|
||||
|
||||
deviceinfo_format_version="0"
|
||||
deviceinfo_name="Amazon Fire TV Stick (2nd Gen)"
|
||||
deviceinfo_manufacturer="Amazon"
|
||||
deviceinfo_codename="amazon-tank"
|
||||
deviceinfo_date=""
|
||||
deviceinfo_dtb=""
|
||||
deviceinfo_modules_initfs=""
|
||||
deviceinfo_arch="armv7"
|
||||
|
||||
# Device related
|
||||
deviceinfo_keyboard="false"
|
||||
deviceinfo_external_storage="false"
|
||||
deviceinfo_screen_width="1920"
|
||||
deviceinfo_screen_height="1080"
|
||||
deviceinfo_dev_touchscreen=""
|
||||
deviceinfo_dev_touchscreen_calibration=""
|
||||
deviceinfo_dev_keyboard=""
|
||||
|
||||
# Bootloader related
|
||||
deviceinfo_flash_method="fastboot"
|
||||
deviceinfo_kernel_cmdline="androidboot.selinux=permissive"
|
||||
deviceinfo_generate_bootimg="true"
|
||||
deviceinfo_bootimg_qcdt="false"
|
||||
deviceinfo_bootimg_dtb_second="false"
|
||||
deviceinfo_flash_offset_base="0x80000000"
|
||||
deviceinfo_flash_offset_kernel="0x00008000"
|
||||
deviceinfo_flash_offset_ramdisk="0x04000000"
|
||||
deviceinfo_flash_offset_second="0x00f00000"
|
||||
deviceinfo_flash_offset_tags="0x00000100"
|
||||
deviceinfo_flash_pagesize="2048"
|
||||
|
13
device/linux-amazon-tank/01_ozmo_fix_trace.patch
Normal file
13
device/linux-amazon-tank/01_ozmo_fix_trace.patch
Normal file
|
@ -0,0 +1,13 @@
|
|||
diff --git a/drivers/misc/ozmo/ozeventtrace.h b/drivers/misc/ozmo/ozeventtrace.h
|
||||
index 94e19477..4617e7e5 100644
|
||||
--- a/drivers/misc/ozmo/ozeventtrace.h
|
||||
+++ b/drivers/misc/ozmo/ozeventtrace.h
|
||||
@@ -226,7 +226,7 @@ DEFINE_EVENT(debug_msg, info_msg_evt,
|
||||
#endif /*_OZEVENTTRACE_H*/
|
||||
|
||||
#undef TRACE_INCLUDE_PATH
|
||||
-#define TRACE_INCLUDE_PATH .
|
||||
+#define TRACE_INCLUDE_PATH ../../drivers/misc/ozmo
|
||||
#undef TRACE_INCLUDE_FILE
|
||||
#define TRACE_INCLUDE_FILE ozeventtrace
|
||||
#include <trace/define_trace.h>
|
13
device/linux-amazon-tank/02_thermal_fix_include.patch
Normal file
13
device/linux-amazon-tank/02_thermal_fix_include.patch
Normal file
|
@ -0,0 +1,13 @@
|
|||
diff --git a/drivers/thermal/virtual_sensor_cpufreq_cooling.c b/drivers/thermal/virtual_sensor_cpufreq_cooling.c
|
||||
index 99c4cae1..705993b1 100644
|
||||
--- a/drivers/thermal/virtual_sensor_cpufreq_cooling.c
|
||||
+++ b/drivers/thermal/virtual_sensor_cpufreq_cooling.c
|
||||
@@ -29,7 +29,7 @@
|
||||
#include <linux/thermal.h>
|
||||
#include <linux/cpumask.h>
|
||||
#include <linux/cpu_cooling.h>
|
||||
-#include <thermal_core.h>
|
||||
+#include "thermal_core.h"
|
||||
|
||||
#define MAX_STATE 4 /* 0-4 total 5 */
|
||||
|
70
device/linux-amazon-tank/APKBUILD
Normal file
70
device/linux-amazon-tank/APKBUILD
Normal file
|
@ -0,0 +1,70 @@
|
|||
# Reference: <https://postmarketos.org/vendorkernel>
|
||||
# Contributor: Federico Amedeo Izzo <federico.izzo42@gmail.com>
|
||||
# Kernel config based on: arch/arm/configs/tank_defconfig
|
||||
|
||||
pkgname="linux-amazon-tank"
|
||||
pkgver=3.10.54
|
||||
pkgrel=0
|
||||
pkgdesc="Amazon Fire TV Stick (2nd Gen) kernel fork"
|
||||
arch="armv7"
|
||||
_carch="arm"
|
||||
_flavor="amazon-tank"
|
||||
url="https://kernel.org"
|
||||
license="GPL-2.0-only"
|
||||
options="!strip !check !tracedeps"
|
||||
makedepends="perl sed installkernel bash gmp-dev bc linux-headers elfutils-dev devicepkg-dev gcc4 xz"
|
||||
|
||||
# Compiler: GCC 4 (doesn't compile with newer versions)
|
||||
if [ "${CC:0:5}" != "gcc4-" ]; then
|
||||
CC="gcc4-$CC"
|
||||
HOSTCC="gcc4-gcc"
|
||||
CROSS_COMPILE="gcc4-$CROSS_COMPILE"
|
||||
fi
|
||||
|
||||
# Source
|
||||
_repository="android_kernel_amazon_mt8127"
|
||||
_commit="2861aa5f5e0bbb526072d75f24ef3af875519234"
|
||||
_config="config-$_flavor.$arch"
|
||||
source="
|
||||
$pkgname-$_commit.tar.gz::https://github.com/cmtank/$_repository/archive/$_commit.tar.gz
|
||||
$_config
|
||||
01_ozmo_fix_trace.patch
|
||||
02_thermal_fix_include.patch
|
||||
"
|
||||
builddir="$srcdir/$_repository-$_commit"
|
||||
|
||||
prepare() {
|
||||
default_prepare
|
||||
downstreamkernel_prepare "$srcdir" "$builddir" "$_config" "$_carch" "$HOSTCC"
|
||||
}
|
||||
|
||||
build() {
|
||||
unset LDFLAGS
|
||||
make ARCH="$_carch" CC="${CC:-gcc}" \
|
||||
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
|
||||
}
|
||||
|
||||
package() {
|
||||
# kernel.release
|
||||
install -D "$builddir/include/config/kernel.release" \
|
||||
"$pkgdir/usr/share/kernel/$_flavor/kernel.release"
|
||||
|
||||
# zImage (find the right one)
|
||||
cd "$builddir/arch/$_carch/boot"
|
||||
_target="$pkgdir/boot/vmlinuz-$_flavor"
|
||||
for _zimg in zImage-dtb Image.gz-dtb *zImage Image; do
|
||||
[ -e "$_zimg" ] || continue
|
||||
msg "zImage found: $_zimg"
|
||||
install -Dm644 "$_zimg" "$_target"
|
||||
break
|
||||
done
|
||||
if ! [ -e "$_target" ]; then
|
||||
error "Could not find zImage in $PWD!"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
sha512sums="bef51789afd0174f0c88d7cd1f038a754e85a8fa2a159036f154d08b8812e7fcee762d9e231cf1397b66afb846f453e00aae98f74c4c143d83b57b7c83616fe9 linux-amazon-tank-2861aa5f5e0bbb526072d75f24ef3af875519234.tar.gz
|
||||
5b68ab1da2e0def064b778b0dd9b869b503c9e373db52e2ff01a2da00c576716cde6f8ffaf90ce41fd96c45207a14b558ec3a0c69eeebe3d583e867dc31ed2eb config-amazon-tank.armv7
|
||||
0aa0b433e0b74751351c6782b168b91ffb1cf4c4d305ff1e3e39f3cc4f6321d5e3488a531a1fcac0bb92a2997002d5c1608a55573a7bbf43e32cb612b04793b8 01_ozmo_fix_trace.patch
|
||||
158eeb7905fd341432f21a9a16921468285c14dd4a044228119a232e1ce9c77e30c513f62737ebdb40fb27cf4d30542cdb4e62bf2982f8827e195c10d7d40d16 02_thermal_fix_include.patch"
|
3288
device/linux-amazon-tank/config-amazon-tank.armv7
Normal file
3288
device/linux-amazon-tank/config-amazon-tank.armv7
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user