samsung-zerofltexx: new device Samsung Galaxy S6 (G920F) (MR 1865)

Port based on an unofficial LineageOS port
from https://www.los-legacy.de/17.1/zerofltexx, using kernel from https://github.com/Exynos7420/android_kernel_samsung_exynos7420/

What works:
- Kernel boots
- Display and touch input (tested with Weston)
- USB networking

Note: I removed camera support in kernel config for now, as there were related kernel crashes.
Wifi doesn't work either yet because the firmware dependencies/paths need to be fixed first.
This commit is contained in:
Stefan 2021-01-09 22:12:12 +01:00 committed by Bart Ribbers
parent 144b88ef16
commit c395f9c94b
No known key found for this signature in database
GPG key ID: 699D16185DAFAE61
6 changed files with 4706 additions and 0 deletions

View file

@ -0,0 +1,22 @@
# Reference: <https://postmarketos.org/devicepkg>
pkgname=device-samsung-zerofltexx
pkgdesc="Samsung Galaxy S6"
pkgver=0.1
pkgrel=0
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="postmarketos-base linux-samsung-zerofltexx mkbootimg mesa-dri-gallium msm-fb-refresher"
makedepends="devicepkg-dev"
source="deviceinfo"
build() {
devicepkg_build $startdir $pkgname
}
package() {
devicepkg_package $startdir $pkgname
}
sha512sums="a77cb40856b63d0c2646d000a7be2e2afc46d4c8353a495749ff54be7a9ae5b50c2849d1d01e69e793e8b6685d857fce19c674a4bf40c00d2afc19ac6f6e13bb deviceinfo"

View file

@ -0,0 +1,35 @@
# Reference: <https://postmarketos.org/deviceinfo>
# Please use double quotes only. You can source this file in shell
# scripts.
deviceinfo_format_version="0"
deviceinfo_name="Samsung Galaxy S6"
deviceinfo_manufacturer="Samsung"
deviceinfo_codename="samsung-zerofltexx"
deviceinfo_year="2015"
deviceinfo_dtb=""
deviceinfo_modules_initfs=""
deviceinfo_arch="aarch64"
# Device related
deviceinfo_chassis="handset"
deviceinfo_keyboard="false"
deviceinfo_external_storage="false"
deviceinfo_screen_width="1440"
deviceinfo_screen_height="2560"
# Bootloader related
deviceinfo_flash_method="heimdall-bootimg"
deviceinfo_kernel_cmdline=""
deviceinfo_generate_bootimg="true"
deviceinfo_bootimg_qcdt="true"
deviceinfo_bootimg_mtk_mkimage="false"
deviceinfo_bootimg_dtb_second="false"
deviceinfo_flash_offset_base="0x10000000"
deviceinfo_flash_offset_kernel="0x00008000"
deviceinfo_flash_offset_ramdisk="0x01000000"
deviceinfo_flash_offset_second="0x00f00000"
deviceinfo_flash_offset_tags="0x00000100"
deviceinfo_flash_pagesize="2048"
deviceinfo_flash_heimdall_partition_kernel=""
deviceinfo_flash_heimdall_partition_system=""

View file

@ -0,0 +1,57 @@
# Reference: <https://postmarketos.org/vendorkernel>
# Kernel config based on: arch/arm64/configs/lineageos_zerofltexx_defconfig
pkgname=linux-samsung-zerofltexx
pkgver=3.10.108
pkgrel=0
pkgdesc="Samsung Galaxy S6 kernel fork"
arch="aarch64"
_carch="arm64"
_flavor="samsung-zerofltexx"
url="https://github.com/Exynos7420/android_kernel_samsung_exynos7420"
license="GPL-2.0-only"
options="!strip !check !tracedeps pmb:cross-native"
makedepends="bash bc linux-headers installkernel devicepkg-dev dtbtool-exynos"
# Source
_repository="android_kernel_samsung_exynos7420"
_commit="31cf7c95814358c4cd76feacf2f29bebc057fefc"
_config="config-$_flavor.$arch"
source="
$pkgname-$_commit.tar.gz::https://github.com/Exynos7420/$_repository/archive/$_commit.tar.gz
$_config
Makefile_fix_paths.patch
gcc10-extern_YYLOC_global_declaration.patch
"
builddir="$srcdir/$_repository-$_commit"
_outdir="out"
prepare() {
default_prepare
. downstreamkernel_prepare
}
build() {
unset LDFLAGS
make O="$_outdir" ARCH="$_carch" CC="${CC:-gcc}" \
KBUILD_BUILD_VERSION="$((pkgrel + 1 ))-postmarketOS"
# Master DTB (deviceinfo_bootimg_qcdt)
dtbTool-exynos --pagesize 2048 \
--platform 0x50a6 \
--subtype 0x217584da \
-o "$_outdir/arch/$_carch/boot"/dt.img \
$(find "$_outdir/arch/$_carch/boot/dts/" -name *zeroflte_eur_open_*.dtb)
}
package() {
KERNEL_IMAGE_NAME="Image" downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor" "$_outdir"
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img \
"$pkgdir"/boot/dt.img
}
sha512sums="1f8917dfaf01865cbc0385579cad1565dcb1ec4445bbeaf3e70d0bd8a6a572a457813c311f54360f54c79b373e621d280982f560cf01091d156c90efcc98067b linux-samsung-zerofltexx-31cf7c95814358c4cd76feacf2f29bebc057fefc.tar.gz
8b6064ce3cb8b085f06b8512b71728e01985b8b5154305473655059ff0af73fc391b54448875d0a5c35581b8f2fe6f65925f85632044d4969a14dbf9cde1af3e config-samsung-zerofltexx.aarch64
00aac98cfbaa68bd30c41622b12f38106f6595e2d74ee5cdd05add56f03facb4db45deb43b5df997143b54497d621b9fc5bae7207898c70df0672ebb482c4b46 Makefile_fix_paths.patch
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch"

View file

@ -0,0 +1,15 @@
diff --git a/Makefile b/Makefile
--- a/Makefile
+++ b/Makefile
@@ -197,11 +197,6 @@
CROSS_COMPILE ?= ../PLATFORM/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-
#CROSS_COMPILE ?= /opt/toolchains/aarch64-linux-android-4.9/bin/aarch64-linux-android-
-ifeq ($(shell uname -s),Linux)
- ifeq ($(shell uname -m),x86_64)
- override CROSS_COMPILE := $(srctree)/../../../prebuilts/linaro/linux-x86/aarch64/bin/aarch64-linux-gnu-
- endif
-endif
# Architecture as present in compile.h
UTS_MACHINE := $(ARCH)

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1 @@
../../.shared-patches/linux/gcc10-extern_YYLOC_global_declaration.patch