samsung-j7eltetmo: new port (MR 2409)
[ci:skip-build] already built successfully in CI
This commit is contained in:
parent
ad75c18077
commit
c926c7803e
18 changed files with 4596 additions and 0 deletions
38
device/testing/device-samsung-j7eltetmo/APKBUILD
Normal file
38
device/testing/device-samsung-j7eltetmo/APKBUILD
Normal file
|
@ -0,0 +1,38 @@
|
|||
# Reference: <https://postmarketos.org/devicepkg>
|
||||
pkgname=device-samsung-j7eltetmo
|
||||
pkgdesc="Samsung Galaxy J7 (T-Mobile)"
|
||||
pkgver=0.1
|
||||
pkgrel=0
|
||||
url="https://postmarketos.org"
|
||||
license="MIT"
|
||||
arch="aarch64"
|
||||
options="!check !archcheck"
|
||||
depends="
|
||||
linux-samsung-j7eltetmo
|
||||
mesa-dri-gallium
|
||||
mkbootimg
|
||||
msm-fb-refresher
|
||||
postmarketos-base
|
||||
"
|
||||
makedepends="devicepkg-dev"
|
||||
source="
|
||||
deviceinfo
|
||||
"
|
||||
|
||||
build() {
|
||||
devicepkg_build $startdir $pkgname
|
||||
}
|
||||
|
||||
package() {
|
||||
devicepkg_package $startdir $pkgname
|
||||
# Disable v4l udev rules, because if enabled the device will fail to boot
|
||||
# when VIDEO_EXYNOS_FIMC_IS is enabled.
|
||||
mkdir -p "$pkgdir"/etc/udev/rules.d
|
||||
ln -s /dev/null "$pkgdir"/etc/udev/rules.d/60-persistent-v4l.rules
|
||||
}
|
||||
|
||||
|
||||
|
||||
sha512sums="
|
||||
e77705ad43d3e62a6b1abfcb960e223454074c234aef17f2cbc59775b06d24db278a46f4ad426df3895ece542c74e22964ad881b717892c96d49a08d7c14a405 deviceinfo
|
||||
"
|
35
device/testing/device-samsung-j7eltetmo/deviceinfo
Normal file
35
device/testing/device-samsung-j7eltetmo/deviceinfo
Normal 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 J7 (T-Mobile)"
|
||||
deviceinfo_manufacturer="Samsung"
|
||||
deviceinfo_codename="samsung-j7eltetmo"
|
||||
deviceinfo_year="2015"
|
||||
deviceinfo_dtb=""
|
||||
deviceinfo_modules_initfs=""
|
||||
deviceinfo_arch="aarch64"
|
||||
|
||||
# Device related
|
||||
deviceinfo_chassis="handset"
|
||||
deviceinfo_keyboard="false"
|
||||
deviceinfo_external_storage="true"
|
||||
deviceinfo_screen_width="720"
|
||||
deviceinfo_screen_height="1280"
|
||||
|
||||
# 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_pagesize="2048"
|
||||
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_heimdall_partition_kernel=""
|
||||
deviceinfo_flash_heimdall_partition_system=""
|
45
device/testing/linux-samsung-j7eltetmo/01-Fix-Makefile.patch
Normal file
45
device/testing/linux-samsung-j7eltetmo/01-Fix-Makefile.patch
Normal file
|
@ -0,0 +1,45 @@
|
|||
From 26e578b095d2ae3ae9adf24e660ac2903909c07e Mon Sep 17 00:00:00 2001
|
||||
From: nbe1233 <nbe1233@sdf.org>
|
||||
Date: Mon, 2 Aug 2021 22:20:27 -0700
|
||||
Subject: [PATCH 1/4] Fix Makefile
|
||||
Explicitly use gnu89 standard, and clears CROSS_COMPILE in the use case
|
||||
that the host machine is also aarch64.
|
||||
---
|
||||
Makefile | 7 ++++---
|
||||
1 file changed, 4 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 8627ce8a..b202de97 100755
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -194,7 +194,7 @@ SUBARCH := $(shell uname -m | sed -e s/i.86/x86/ -e s/x86_64/x86/ \
|
||||
# Note: Some architectures assign CROSS_COMPILE in their arch/*/Makefile
|
||||
export KBUILD_BUILDHOST := $(SUBARCH)
|
||||
ARCH ?=arm64
|
||||
-CROSS_COMPILE ?=../PLATFORM/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-
|
||||
+CROSS_COMPILE ?=
|
||||
|
||||
# Architecture as present in compile.h
|
||||
UTS_MACHINE := $(ARCH)
|
||||
@@ -242,7 +242,7 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
|
||||
|
||||
HOSTCC = gcc
|
||||
HOSTCXX = g++
|
||||
-HOSTCFLAGS = -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer
|
||||
+HOSTCFLAGS = -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89
|
||||
HOSTCXXFLAGS = -O2
|
||||
|
||||
# Decide whether to build built-in, modular, or both.
|
||||
@@ -380,7 +380,8 @@ KBUILD_CFLAGS := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \
|
||||
-Werror-implicit-function-declaration \
|
||||
-Wno-format-security \
|
||||
-fno-delete-null-pointer-checks \
|
||||
- -fdiagnostics-show-option -Werror
|
||||
+ -fdiagnostics-show-option -Werror \
|
||||
+ -std=gnu89
|
||||
KBUILD_AFLAGS_KERNEL :=
|
||||
KBUILD_CFLAGS_KERNEL :=
|
||||
KBUILD_AFLAGS := -D__ASSEMBLY__
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
diff --git a/init/_vmm.S b/init/_vmm.S
|
||||
index b2ef92fa..1a1d898f 100755
|
||||
--- a/init/_vmm.S
|
||||
+++ b/init/_vmm.S
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
#include <linux/vmm.h>
|
||||
|
||||
-#define vmm_ELF_PATH "init/vmm.elf"
|
||||
+#define vmm_ELF_PATH "../init/vmm.elf"
|
||||
|
||||
#define SMC_64BIT_RET_MAGIC 0xC2000401
|
||||
|
81
device/testing/linux-samsung-j7eltetmo/03-Removed-knox.patch
Normal file
81
device/testing/linux-samsung-j7eltetmo/03-Removed-knox.patch
Normal file
|
@ -0,0 +1,81 @@
|
|||
Based on ../linux-samsung-a5y17lte/disable_knox.patch
|
||||
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
|
||||
index c39199a9..fa44c276 100755
|
||||
--- a/net/ipv4/af_inet.c
|
||||
+++ b/net/ipv4/af_inet.c
|
||||
@@ -440,64 +440,6 @@ out_rcu_unlock:
|
||||
goto out;
|
||||
}
|
||||
|
||||
-/** The function is used to check if the ncm feature is enabled or not; if enabled then collect the socket meta-data information; **/
|
||||
-static void knox_collect_metadata(struct socket *sock) {
|
||||
- if(check_ncm_flag()) {
|
||||
- struct knox_socket_metadata* ksm = kzalloc(sizeof(struct knox_socket_metadata),GFP_KERNEL);
|
||||
-
|
||||
- struct sock *sk = sock->sk;
|
||||
- struct inet_sock *inet = inet_sk(sk);
|
||||
-
|
||||
- struct pid *pid_struct;
|
||||
- struct task_struct *task;
|
||||
-
|
||||
- struct pid *parent_pid_struct;
|
||||
- struct task_struct *parent_task;
|
||||
-
|
||||
- struct timespec close_timespec;
|
||||
-
|
||||
- if(ksm == NULL) return;
|
||||
-
|
||||
- if((sock->ops->family == AF_INET) && (sk->inet_src_masq != 0)) {
|
||||
- pid_struct = find_get_pid(current->tgid);
|
||||
- task = pid_task(pid_struct,PIDTYPE_PID);
|
||||
- if(task != NULL) {
|
||||
- memcpy(ksm->process_name,task->comm, sizeof(task->comm));
|
||||
- if(task->parent != NULL) {
|
||||
- parent_pid_struct = find_get_pid(task->parent->tgid);
|
||||
- parent_task = pid_task(parent_pid_struct,PIDTYPE_PID);
|
||||
- if(parent_task != NULL) {
|
||||
- memcpy(ksm->parent_process_name,parent_task->comm,sizeof(ksm->parent_process_name));
|
||||
- ksm->knox_puid = parent_task->cred->uid;
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- ksm->srcport = ntohs(inet->inet_sport);
|
||||
- ksm->dstport = ntohs(inet->inet_dport);
|
||||
-
|
||||
- sprintf(ksm->srcaddr,"%pI4",(void *)&sk->inet_src_masq);
|
||||
- sprintf(ksm->dstaddr,"%pI4",(void *)&inet->inet_daddr);
|
||||
-
|
||||
- ksm->knox_sent = sock->knox_sent;
|
||||
- ksm->knox_recv = sock->knox_recv;
|
||||
- ksm->knox_uid = sk->knox_uid;
|
||||
- ksm->knox_pid = sk->knox_pid;
|
||||
- ksm->trans_proto = sk->sk_protocol;
|
||||
-
|
||||
- memcpy(ksm->domain_name,sk->domain_name,sizeof(ksm->domain_name)-1);
|
||||
-
|
||||
- ksm->open_time = sk->open_time;
|
||||
-
|
||||
- close_timespec = current_kernel_time();
|
||||
- ksm->close_time = close_timespec.tv_sec;
|
||||
-
|
||||
- insert_data_kfifo_kthread(ksm);
|
||||
- } else {
|
||||
- kfree(ksm);
|
||||
- }
|
||||
- }
|
||||
-}
|
||||
|
||||
/*
|
||||
* The peer socket should always be NULL (or else). When we call this
|
||||
@@ -527,7 +469,6 @@ int inet_release(struct socket *sock)
|
||||
if (sock_flag(sk, SOCK_LINGER) &&
|
||||
!(current->flags & PF_EXITING))
|
||||
timeout = sk->sk_lingertime;
|
||||
- knox_collect_metadata(sock);
|
||||
sock->sk = NULL;
|
||||
sk->sk_prot->close(sk, timeout);
|
||||
}
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
Create a symlink to platform.h. Fixes errors regarding about a missing
|
||||
platform.h file.
|
||||
diff --git a/drivers/gud/gud-exynos7580/MobiCoreDriver/platform.h b/drivers/gud/gud-exynos7580/MobiCoreDriver/platform.h
|
||||
new file mode 120000
|
||||
index 00000000..526bc961
|
||||
--- /dev/null
|
||||
+++ b/drivers/gud/gud-exynos7580/MobiCoreDriver/platform.h
|
||||
@@ -0,0 +1 @@
|
||||
+platforms/EXYNOS_7580_STD/platform.h
|
||||
\ No newline at end of file
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
This patch was found at https://github.com/LineageOS/android_kernel_samsung_universal7580
|
||||
From 07b641581bc9678835f912c504017f86a23a8e95 Mon Sep 17 00:00:00 2001
|
||||
From: Apavayan Sinha <info@apavayan.com>
|
||||
Date: Sun, 24 Jul 2016 15:02:04 +0530
|
||||
Subject: [PATCH] security: Fix tima compile
|
||||
|
||||
Signed-off-by: Apavayan Sinha <info@apavayan.com>
|
||||
---
|
||||
security/Makefile | 2 +-
|
||||
security/tima_uevent/Makefile | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/security/Makefile b/security/Makefile
|
||||
index 5123df02374..965390f17cc 100644
|
||||
--- a/security/Makefile
|
||||
+++ b/security/Makefile
|
||||
@@ -33,7 +33,7 @@ obj-$(CONFIG_INTEGRITY) += integrity/built-in.o
|
||||
obj-$(CONFIG_MST_LDO) += mstdrv/
|
||||
|
||||
# TIMA uevent
|
||||
-obj-$(CONFIG_TIMA) += tima_uevent/tima_uevent.o
|
||||
+obj-$(CONFIG_TIMA) += tima_uevent/
|
||||
#ICCC
|
||||
obj-$(CONFIG_TZ_ICCC) += tz_iccc/
|
||||
|
||||
diff --git a/security/tima_uevent/Makefile b/security/tima_uevent/Makefile
|
||||
index 4f1ca82645b..1621efaf56d 100644
|
||||
--- a/security/tima_uevent/Makefile
|
||||
+++ b/security/tima_uevent/Makefile
|
||||
@@ -2,5 +2,5 @@
|
||||
# Makefile for TIMA kernel uevent drivers.
|
||||
#
|
||||
|
||||
-#obj-$(CONFIG_TIMA) += tima_uevent.o
|
||||
+obj-$(CONFIG_TIMA) += tima_uevent.o
|
||||
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
This patch was found at https://github.com/LineageOS/android_kernel_samsung_universal7580
|
||||
From 86f1b726b84414148ca2eb81229f8e595d6beacd Mon Sep 17 00:00:00 2001
|
||||
From: Apavayan Sinha <info@apavayan.com>
|
||||
Date: Sun, 24 Jul 2016 15:21:31 +0530
|
||||
Subject: [PATCH] drivers: muic: fix the compile
|
||||
|
||||
Signed-off-by: Apavayan Sinha <info@apavayan.com>
|
||||
---
|
||||
drivers/muic/Makefile | 18 +++++-------------
|
||||
drivers/muic/universal/Makefile | 19 +++++++++++++++++++
|
||||
2 files changed, 24 insertions(+), 13 deletions(-)
|
||||
create mode 100644 drivers/muic/universal/Makefile
|
||||
|
||||
diff --git a/drivers/muic/Makefile b/drivers/muic/Makefile
|
||||
index 86f76acb663..b727ab5a14e 100755
|
||||
--- a/drivers/muic/Makefile
|
||||
+++ b/drivers/muic/Makefile
|
||||
@@ -20,17 +20,9 @@ obj-$(CONFIG_MUIC_SM5705_AFC) += sm5703-muic-afc.o
|
||||
obj-$(CONFIG_MUIC_S2MU005) += s2mu005-muic.o
|
||||
|
||||
# MUIC_UNIVERSAL
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_task.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_state.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_apis.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_sysfs.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_debug.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_dt.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_i2c.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_regmap.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL) += universal/muic_vps.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL_SM5703) += universal/muic_regmap_sm5703.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL_SM5705) += universal/muic_regmap_sm5705.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL_SM5705_AFC) += universal/muic_afc.o
|
||||
-obj-$(CONFIG_MUIC_UNIVERSAL_SM5504) += universal/muic_regmap_sm5504.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += universal/
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5703) += universal/
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5705) += universal/
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5705_AFC) += universal/
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5504) += universal/
|
||||
|
||||
diff --git a/drivers/muic/universal/Makefile b/drivers/muic/universal/Makefile
|
||||
new file mode 100644
|
||||
index 00000000000..adadefa2de1
|
||||
--- /dev/null
|
||||
+++ b/drivers/muic/universal/Makefile
|
||||
@@ -0,0 +1,19 @@
|
||||
+#
|
||||
+# Makefile for muic devices
|
||||
+#
|
||||
+
|
||||
+# MUIC_UNIVERSAL
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_task.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_state.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_apis.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_sysfs.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_debug.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_dt.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_i2c.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_regmap.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL) += muic_vps.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5703) += muic_regmap_sm5703.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5705) += muic_regmap_sm5705.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5705_AFC) += muic_afc.o
|
||||
+obj-$(CONFIG_MUIC_UNIVERSAL_SM5504) += muic_regmap_sm5504.o
|
||||
+
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,41 @@
|
|||
This patch was found at https://github.com/LineageOS/android_kernel_samsung_universal7580
|
||||
From 9e05ad50d4d9c63ec149ee4f8d902e84a1077000 Mon Sep 17 00:00:00 2001
|
||||
From: Apavayan Sinha <info@apavayan.com>
|
||||
Date: Sun, 24 Jul 2016 15:51:34 +0530
|
||||
Subject: [PATCH] drivers: media: fix compiling
|
||||
|
||||
Signed-off-by: Apavayan Sinha <info@apavayan.com>
|
||||
---
|
||||
drivers/media/platform/exynos/fimc-is2/Makefile | 2 +-
|
||||
.../media/platform/exynos/fimc-is2/hardware/api/Makefile | 6 ++++++
|
||||
2 files changed, 7 insertions(+), 1 deletion(-)
|
||||
create mode 100644 drivers/media/platform/exynos/fimc-is2/hardware/api/Makefile
|
||||
|
||||
diff --git a/drivers/media/platform/exynos/fimc-is2/Makefile b/drivers/media/platform/exynos/fimc-is2/Makefile
|
||||
index 6d95fe1e5fd..116e6112ade 100644
|
||||
--- a/drivers/media/platform/exynos/fimc-is2/Makefile
|
||||
+++ b/drivers/media/platform/exynos/fimc-is2/Makefile
|
||||
@@ -33,7 +33,7 @@ obj-$(CONFIG_VIDEO_EXYNOS_FIMC_IS) += fimc-is.o
|
||||
obj-$(CONFIG_VIDEO_EXYNOS_FIMC_IS) += sensor/
|
||||
obj-$(CONFIG_VIDEO_EXYNOS_FIMC_IS) += ischain/
|
||||
obj-$(CONFIG_VIDEO_EXYNOS_FIMC_IS) += vendor/
|
||||
-obj-$(CONFIG_USE_HOST_FD_LIBRARY) += hardware/api/fimc-is-api-fd.o
|
||||
+obj-$(CONFIG_USE_HOST_FD_LIBRARY) += hardware/api/
|
||||
|
||||
EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2
|
||||
EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2/include
|
||||
diff --git a/drivers/media/platform/exynos/fimc-is2/hardware/api/Makefile b/drivers/media/platform/exynos/fimc-is2/hardware/api/Makefile
|
||||
new file mode 100644
|
||||
index 00000000000..6baa7336c69
|
||||
--- /dev/null
|
||||
+++ b/drivers/media/platform/exynos/fimc-is2/hardware/api/Makefile
|
||||
@@ -0,0 +1,6 @@
|
||||
+obj-$(CONFIG_USE_HOST_FD_LIBRARY) += fimc-is-api-fd.o
|
||||
+
|
||||
+EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2
|
||||
+EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2/include
|
||||
+EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2/vendor
|
||||
+EXTRA_CFLAGS += -Idrivers/media/platform/exynos/fimc-is2/hardware/api
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
This patch was found at https://github.com/LineageOS/android_kernel_samsung_universal7580
|
||||
From ac118d424b82200b42290ca855f97804dcf8e897 Mon Sep 17 00:00:00 2001
|
||||
From: Apavayan Sinha <info@apavayan.com>
|
||||
Date: Tue, 21 Feb 2017 07:47:04 +0530
|
||||
Subject: [PATCH] fs: Fix the compile w/o ROOT Restriction enabled
|
||||
|
||||
Change-Id: I2cb687617eb1228ad7f62da25449afeb11cdf701
|
||||
---
|
||||
fs/exec.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/fs/exec.c b/fs/exec.c
|
||||
index cb5f418b67b..c4bb850a17a 100644
|
||||
--- a/fs/exec.c
|
||||
+++ b/fs/exec.c
|
||||
@@ -1876,7 +1876,6 @@ SYSCALL_DEFINE3(execve,
|
||||
return -EACCES;
|
||||
}
|
||||
}
|
||||
-#endif // End of CONFIG_SEC_RESTRICT_FORK
|
||||
#ifdef CONFIG_RKP_KDP
|
||||
if(CHECK_ROOT_UID(current) && rkp_cred_enable) {
|
||||
if(rkp_restrict_fork()){
|
||||
@@ -1888,6 +1887,7 @@ SYSCALL_DEFINE3(execve,
|
||||
}
|
||||
}
|
||||
#endif
|
||||
+#endif // End of CONFIG_SEC_RESTRICT_FORK
|
||||
error = do_execve(path->name, argv, envp);
|
||||
putname(path);
|
||||
}
|
||||
--
|
||||
2.32.0
|
||||
|
16
device/testing/linux-samsung-j7eltetmo/09-build-dtb.patch
Normal file
16
device/testing/linux-samsung-j7eltetmo/09-build-dtb.patch
Normal file
|
@ -0,0 +1,16 @@
|
|||
diff --git a/arch/arm64/boot/dts/Makefile b/arch/arm64/boot/dts/Makefile
|
||||
index e684367f..86cd49c6 100755
|
||||
--- a/arch/arm64/boot/dts/Makefile
|
||||
+++ b/arch/arm64/boot/dts/Makefile
|
||||
@@ -5,7 +5,7 @@ dtb-$(CONFIG_ARCH_XGENE) += apm-mustang.dtb
|
||||
dtb-$(CONFIG_MACH_ESPRESSO7420) += exynos7420-espresso7420.dtb
|
||||
dtb-$(CONFIG_MACH_UNIVERSAL7420) += exynos7420-universal7420.dtb exynos7420-universal7420-ufs.dtb exynos7420-universal7420-ufs_rev00.dtb
|
||||
dtb-$(CONFIG_MACH_SMDK7580) += exynos7580-smdk7580.dtb
|
||||
-dtb-$(CONFIG_MACH_UNIVERSAL7580) += exynos7580-universal7580.dtb exynos7580-universal7580_rev01.dtb exynos7580-universal7580_q.dtb
|
||||
+dtb-$(CONFIG_MACH_UNIVERSAL7580) += exynos7580-universal7580.dtb exynos7580-universal7580_rev01.dtb exynos7580-universal7580_q.dtb exynos7580-j7elte_usa_tmo_00.dtb exynos7580-j7elte_usa_tmo_01.dtb
|
||||
|
||||
dtb-$(CONFIG_MACH_UNIVERSAL5433) += exynos5433-universal5433_rev02.dtb exynos5433-universal5433.dtb
|
||||
targets += dtbs
|
||||
--
|
||||
2.32.0
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
Based on ../../.shared-patches/linux/samsung-usb-ethaddr.patch
|
||||
|
||||
diff --git a/drivers/usb/gadget/u_ether.c b/drivers/usb/gadget/u_ether.c
|
||||
index 80294f32..d7268e50 100755
|
||||
--- a/drivers/usb/gadget/u_ether.c
|
||||
+++ b/drivers/usb/gadget/u_ether.c
|
||||
@@ -1193,7 +1193,7 @@ struct eth_dev *gether_setup_name(struct usb_gadget *g, u8 ethaddr[ETH_ALEN],
|
||||
if (get_ether_addr(dev_addr, net->dev_addr))
|
||||
dev_warn(&g->dev,
|
||||
"using random %s ethernet address\n", "self");
|
||||
-#ifdef CONFIG_USB_ANDROID_SAMSUNG_COMPOSITE
|
||||
+#if 0
|
||||
memcpy(dev->host_mac, ethaddr, ETH_ALEN);
|
||||
printk(KERN_DEBUG "usb: set unique host mac\n");
|
||||
#else
|
||||
--
|
||||
2.32.0
|
||||
|
19
device/testing/linux-samsung-j7eltetmo/11-fix-argb.patch
Normal file
19
device/testing/linux-samsung-j7eltetmo/11-fix-argb.patch
Normal file
|
@ -0,0 +1,19 @@
|
|||
Based on Error1001's patch, 02-fix-video-argb-setting.patch
|
||||
diff --git a/drivers/video/exynos/decon_7580/decon-int_drv.c b/drivers/video/exynos/decon_7580/decon-int_drv.c
|
||||
index c37ec143..27375b6f 100755
|
||||
--- a/drivers/video/exynos/decon_7580/decon-int_drv.c
|
||||
+++ b/drivers/video/exynos/decon_7580/decon-int_drv.c
|
||||
@@ -453,11 +453,11 @@ int decon_check_var(struct fb_var_screeninfo *var, struct fb_info *info)
|
||||
case 24:
|
||||
/* our 24bpp is unpacked, so 32bpp */
|
||||
var->bits_per_pixel = 32;
|
||||
- var->red.offset = 16;
|
||||
+ var->red.offset = 0;
|
||||
var->red.length = 8;
|
||||
var->green.offset = 8;
|
||||
var->green.length = 8;
|
||||
- var->blue.offset = 0;
|
||||
+ var->blue.offset = 16;
|
||||
var->blue.length = 8;
|
||||
break;
|
||||
|
91
device/testing/linux-samsung-j7eltetmo/APKBUILD
Normal file
91
device/testing/linux-samsung-j7eltetmo/APKBUILD
Normal file
|
@ -0,0 +1,91 @@
|
|||
# Reference: <https://postmarketos.org/vendorkernel>
|
||||
# Kernel config based on: arch/arm64/configs/j7eltetmo_00_defconfig
|
||||
|
||||
pkgname=linux-samsung-j7eltetmo
|
||||
pkgver=3.10.61
|
||||
pkgrel=0
|
||||
pkgdesc="Samsung Galaxy J7 (T-Mobile) kernel fork"
|
||||
arch="aarch64"
|
||||
_carch="arm64"
|
||||
_flavor="samsung-j7eltetmo"
|
||||
url="https://kernel.org"
|
||||
license="GPL-2.0-only"
|
||||
options="!strip !check !tracedeps pmb:cross-native"
|
||||
makedepends="
|
||||
bash
|
||||
bc
|
||||
bison
|
||||
devicepkg-dev
|
||||
dtbtool-exynos
|
||||
flex
|
||||
linux-headers
|
||||
openssl-dev
|
||||
perl
|
||||
"
|
||||
|
||||
# Source
|
||||
_repository="android_kernel_samsung_j7eltetmo"
|
||||
_commit="67155b79fcc54fad91e765e29a6c3c3d1a42c644"
|
||||
_config="config-$_flavor.$arch"
|
||||
source="
|
||||
$pkgname-$_commit.tar.gz::https://github.com/nbe1233/$_repository/archive/$_commit.tar.gz
|
||||
$_config
|
||||
gcc7-give-up-on-ilog2-const-optimizations.patch
|
||||
gcc8-fix-put-user.patch
|
||||
gcc10-extern_YYLOC_global_declaration.patch
|
||||
01-Fix-Makefile.patch
|
||||
02-fix-vmm-blob-include.patch
|
||||
03-Removed-knox.patch
|
||||
04-create-a-file-platform.h-which-is-a-symlink.patch
|
||||
05-security-Fix-tima-compile.patch
|
||||
06-drivers-muic-fix-the-compile.patch
|
||||
07-drivers-media-fix-compiling.patch
|
||||
08-fs-Fix-the-compile-w-o-ROOT-Restriction-enabled.patch
|
||||
09-build-dtb.patch
|
||||
10-samsung-usb-ethaddr.patch
|
||||
11-fix-argb.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 -o "$_outdir/arch/$_carch/boot"/dt.img \
|
||||
$(find "$_outdir/arch/$_carch/boot/dts/" -name *j7elte_usa_tmo*.dtb)
|
||||
}
|
||||
|
||||
package() {
|
||||
downstreamkernel_package "$builddir" "$pkgdir" "$_carch" "$_flavor" "$_outdir"
|
||||
install -Dm644 "$_outdir/arch/$_carch/boot"/dt.img \
|
||||
"$pkgdir"/boot/dt.img
|
||||
|
||||
}
|
||||
|
||||
sha512sums="
|
||||
2ed06731921feab677c225e8d30b277a1262ed3e9cdcc0d331895ad5a1d740bae3a30548b882b9c8f694311b78ce512c39e63507dedfe36a07deb06ba8215df1 linux-samsung-j7eltetmo-67155b79fcc54fad91e765e29a6c3c3d1a42c644.tar.gz
|
||||
a2e3afe49b93e11ceda9b8c75c8b56e41d08811cc83a0fa5858f26a448a0eac898dee2a122f3b464905d99010da16b9037612c67dd5fc33a2a4b1bcbe1869219 config-samsung-j7eltetmo.aarch64
|
||||
77eba606a71eafb36c32e9c5fe5e77f5e4746caac292440d9fb720763d766074a964db1c12bc76fe583c5d1a5c864219c59941f5e53adad182dbc70bf2bc14a7 gcc7-give-up-on-ilog2-const-optimizations.patch
|
||||
197d40a214ada87fcb2dfc0ae4911704b9a93354b75179cd6b4aadbb627a37ec262cf516921c84a8b1806809b70a7b440cdc8310a4a55fca5d2c0baa988e3967 gcc8-fix-put-user.patch
|
||||
2b48f1bf0e3f70703d2cdafc47d5e615cc7c56c70bec56b2e3297d3fa4a7a1321d649a8679614553dde8fe52ff1051dae38d5990e3744c9ca986d92187dcdbeb gcc10-extern_YYLOC_global_declaration.patch
|
||||
0536bb86affaff4964fca71f8b0da2ab09a696bd5a7868309030f8843c0c6b551afbee52a8c9b9e516fc5fe36e426a0c9a43bdbe07f3c62b648e9dd95d4a90dc 01-Fix-Makefile.patch
|
||||
23bf8ef0ad38b38ffa9ddfdee76a32c43b021169c6db6f5b733fd6434169f7c7bb27cdb1232be89475f34f9053211d943e13f5fba565c928256b92b18d636130 02-fix-vmm-blob-include.patch
|
||||
b452b7ca8a93d2f7c8bc4c729295b1d303686b5a0953ee058d0be2fa62cfcdecfc3773d3830b605dc41bb7d54940dfd154a2687cb04328d101ad87f148c0d4c5 03-Removed-knox.patch
|
||||
b2b8020948dfa4dc24eec4402aa7c2845ba56e844b2cfb591b4326b372a7748063c9e67d54bf70d841141c7a9203c25766538522d1a6a08e3ca3b8054eface43 04-create-a-file-platform.h-which-is-a-symlink.patch
|
||||
43975cd6bf7a1094da5b7c154872664fb38cca122137d2ecd2ec168a13e76bfbbaed374706d1c6991a3151932d9487e75c13be8fcb731e86897220b8528a98b1 05-security-Fix-tima-compile.patch
|
||||
f6dcf35fdfc0de4f3c30caf3512ad442644c218f2e0a0c3ce0487f83872ed0d49e79cefbd1423690c7134973797113a148620f24a6253dcdf27c06dd753a2b20 06-drivers-muic-fix-the-compile.patch
|
||||
962a7c738f58972724836c43e3241037a5e2db646a8a2258e2757757e81d09638504c9ce82d8b70f37c54b7f1f36e40d9c03e6e736ba46be5d7d9bc5c92d693b 07-drivers-media-fix-compiling.patch
|
||||
d58c5f8772435c70713013f63e36913dafb532a16ab68c440f0b2042073ba18d97b67ccaeb00d94b00afc41f132f8b4fdd669f65a6a1068395508751fe0e39ae 08-fs-Fix-the-compile-w-o-ROOT-Restriction-enabled.patch
|
||||
972b02316164822e46c00b69f4745fb993ef401039518a7ae3e3f0d2e713ba9ac9814a18d7f5527acb36768df18e78672e783f213eba2d7c8db47d7a6cd102df 09-build-dtb.patch
|
||||
bfd0332076724bea2d10e96c81fae41eefb60bfc19f7a21ec849cf2a6b48e4cada694ed6b389ed600e182755d6fdb96f12dcbe81c8e691a2b4602f432fae165a 10-samsung-usb-ethaddr.patch
|
||||
aff2f127c44de0fc3e523834766a5851b48ade0e5cd95f594b36fc17adf3fb0549c70e4cba34a4bbea272fca80d61e0f4615a7195662f38794a1cd96213c7ca2 11-fix-argb.patch
|
||||
"
|
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1 @@
|
|||
../../.shared-patches/linux/gcc10-extern_YYLOC_global_declaration.patch
|
|
@ -0,0 +1 @@
|
|||
../../.shared-patches/linux/gcc7-give-up-on-ilog2-const-optimizations.patch
|
1
device/testing/linux-samsung-j7eltetmo/gcc8-fix-put-user.patch
Symbolic link
1
device/testing/linux-samsung-j7eltetmo/gcc8-fix-put-user.patch
Symbolic link
|
@ -0,0 +1 @@
|
|||
../../.shared-patches/linux/gcc8-fix-put-user.patch
|
Loading…
Reference in a new issue