From b0e658080f05333585f81bb96be678ead18e45b7 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:30:44 +0800
Subject: [PATCH 01/23] Update setup-makefiles.sh
change device
---
setup-makefiles.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup-makefiles.sh b/setup-makefiles.sh
index 9d6bcb51..5ddcfa6e 100755
--- a/setup-makefiles.sh
+++ b/setup-makefiles.sh
@@ -19,7 +19,7 @@
set -e
# Required!
-export DEVICE=z2_plus
+export DEVICE=z2x
export DEVICE_COMMON=msm8996-common
export VENDOR=zuk
From ccae05d6c184b51540855fc7775cd685fde128de Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:39:10 +0800
Subject: [PATCH 02/23] Change to z2x
---
proprietary-files.txt | 140 +++++++++++++++++++++++++++---------------
1 file changed, 90 insertions(+), 50 deletions(-)
diff --git a/proprietary-files.txt b/proprietary-files.txt
index 28c8478e..4d91d27b 100644
--- a/proprietary-files.txt
+++ b/proprietary-files.txt
@@ -1,50 +1,90 @@
-# Audio ACDB - from z2_plus - OPR1.170623.032.4.0.199_181018
-vendor/etc/acdbdata/MTP/MTP_Speaker_cal.acdb|40ce9f6df7e42530ab55fa2412281ffd3b40822d
-vendor/etc/acdbdata/MTP/MTP_General_cal.acdb|476ad92e2e5e1df46d19161f33225a2b04b856eb
-vendor/etc/acdbdata/MTP/MTP_Handset_cal.acdb|c1c7bc9892997c13fbdb66c127d1a18d37ab2f0c
-vendor/etc/acdbdata/MTP/MTP_Headset_cal.acdb|6f82ff71637cff91712510dc607647c5c8b7b83c
-vendor/etc/acdbdata/MTP/MTP_Global_cal.acdb|2cd48125ec3343bc813bb18e8e5c473b22661310
-vendor/etc/acdbdata/MTP/MTP_Hdmi_cal.acdb|afdc6c398a71c139abcfef880a53c1600f3ed3ab
-vendor/etc/acdbdata/MTP/MTP_Bluetooth_cal.acdb|442a76790dcb364a02fc9ac10535dec9d4d9bbdf
-
-# Camera actuator - from z2_plus - OPR1.170623.032.4.0.199_181018
-vendor/lib/libactuator_dw9767.so|9f6792ef634727ea3f08c7acc7f01b782e9a5fc7
-
-# Camera chromatix - from z2_plus - OPR1.170623.032.4.0.199_181018
-vendor/lib/libchromatix_s5k2m8sx_common.so|fac9335897f14269818efbcc29bae85f251dc703
-vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_120.so|d691f7cb32f3b50680ca7d74c35cd9cbd2b1ea3d
-vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_60.so|439a4c92804b6aa9b1d0d88ab068834c3d34efc1
-vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_90.so|2391da37688eca11556d3af4737e37b04130a04f
-vendor/lib/libchromatix_s5k2m8sx_cpp_liveshot.so|0da7ee003368c56a3041fb83dad1e68f9e710bb9
-vendor/lib/libchromatix_s5k2m8sx_cpp_preview.so|ac40d5f1b01dd42cf1290560965e2c03cb866245
-vendor/lib/libchromatix_s5k2m8sx_cpp_snapshot.so|24a663162eff6ca50d053c49a7054c3fb0ff09fc
-vendor/lib/libchromatix_s5k2m8sx_cpp_video.so|bf7fe8911a23afbddecf38001d2ba20ff1e82ebe
-vendor/lib/libchromatix_s5k2m8sx_default_preview_dw9767.so|9de12025a7da70d7d4c63f6bc26d347af74d89f1
-vendor/lib/libchromatix_s5k2m8sx_default_video_dw9767.so|9d9a4b2f26e23f5739f9f665e7b2845eb204d1cc
-vendor/lib/libchromatix_s5k2m8sx_default_video.so|761663e7fcd8de8d1ad998e46461eb4c6f216885
-vendor/lib/libchromatix_s5k2m8sx_hfr_120_dw9767.so|273b7c6463a260f2422e0f609292b72cef86d5ef
-vendor/lib/libchromatix_s5k2m8sx_hfr_120.so|64bc2fbcc68f4be26003e7ab98bbd407fc381eba
-vendor/lib/libchromatix_s5k2m8sx_hfr_60_dw9767.so|fac378b57980e0c90489684dcea9ddc5e1191e15
-vendor/lib/libchromatix_s5k2m8sx_hfr_60.so|ad2cff3da21ce4daadaafa49c34e190f18c9518b
-vendor/lib/libchromatix_s5k2m8sx_hfr_90_dw9767.so|dba5e2614cd2d863ef0bff2c8928550a276b087c
-vendor/lib/libchromatix_s5k2m8sx_hfr_90.so|afa3abbc2f27d844b3143b388a1aa061c2bcda32
-vendor/lib/libchromatix_s5k2m8sx_liveshot.so|f5fc0030a7b7d0bf756f8e904dc71325c3377846
-vendor/lib/libchromatix_s5k2m8sx_postproc.so|656605162345755105e6e7dbb75f37b0c6f20f49
-vendor/lib/libchromatix_s5k2m8sx_preview.so|a749d8a8e3f0f81bc8cd9c215a69c8225f1eee24
-vendor/lib/libchromatix_s5k2m8sx_snapshot.so|cac63771096543a0120f23329de2b57a61c7323f
-vendor/lib/libchromatix_s5k2m8sx_zsl_preview_dw9767.so|e4d5e1d7b515ac977fee8637531185a3341eeed1
-vendor/lib/libchromatix_s5k2m8sx_zsl_video_dw9767.so|703c956388e1393693b22f831106e978db6da0b1
-
-# Camera configs - from z2_plus - OPR1.170623.032.4.0.199_181018
-etc/camera/msm8996_camera.xml:vendor/etc/camera/msm8996_camera.xml|427dfce1771b9b6924f7067c9e8d2421678836bd
-etc/camera/s5k2m8sx_chromatix.xml:vendor/etc/camera/s5k2m8sx_chromatix.xml|570ac2d28ff639e1b5c18a28395de0520158e55d
-
-# Camera eeproms - from z2_plus - OPR1.170623.032.4.0.199_181018
-vendor/lib/libmmcamera_onsemi_cat24c64_eeprom.so|281544658c71f99e2791e8ab85fb4f3d02c7abef
-
-# Camera sensors - from z2_plus - OPR1.170623.032.4.0.199_181018a_ov8865.so
-vendor/lib/libmmcamera_ov8865.so|fe23ab9aa92c7528ebadf8a042d2f1a5933e3e4b
-vendor/lib/libmmcamera_s5k2m8sx.so|41f6dd85b55b6320bcd4447900d7b4a03ecca9c0
-
-# Sensors - from z2_plus - OPR1.170623.032.4.0.199_181018
-vendor/etc/sensors/sensor_def_qcomdev.conf|02f8f2f0ede4d62f733938fd4971bb1fb3dc2acd
+# Audio ACDB
+etc/acdbdata/MTP/MTP_Bluetooth_cal.acdb
+etc/acdbdata/MTP/MTP_General_cal.acdb
+etc/acdbdata/MTP/MTP_Global_cal.acdb
+etc/acdbdata/MTP/MTP_Handset_cal.acdb
+etc/acdbdata/MTP/MTP_Hdmi_cal.acdb
+etc/acdbdata/MTP/MTP_Headset_cal.acdb
+etc/acdbdata/MTP/MTP_Speaker_cal.acdb
+
+# Audio libraries
+etc/aanc_tuning_mixer.txt
+etc/tfa98xx/coldboot.patch
+etc/tfa98xx/shenqi_music.eq
+etc/tfa98xx/shenqi_music.preset
+etc/tfa98xx/shenqi.speaker
+etc/tfa98xx/shenqi_speech.eq
+etc/tfa98xx/shenqi_speech.preset
+etc/tfa98xx/TFA9890_N1B12_N1C3_v2.config
+etc/tfa98xx/TFA9890_N1C3_2_1_1.patch
+
+# Camera actuators
+vendor/lib/libactuator_dw9767.so
+
+# Camera chromatix
+vendor/lib/libchromatix_s5k2m8sx_common.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_120.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_60.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_hfr_90.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_liveshot.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_preview.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_snapshot.so
+vendor/lib/libchromatix_s5k2m8sx_cpp_video.so
+vendor/lib/libchromatix_s5k2m8sx_default_preview_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_default_video_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_default_video.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_120_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_120.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_60_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_60.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_90_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_hfr_90.so
+vendor/lib/libchromatix_s5k2m8sx_liveshot.so
+vendor/lib/libchromatix_s5k2m8sx_postproc.so
+vendor/lib/libchromatix_s5k2m8sx_preview.so
+vendor/lib/libchromatix_s5k2m8sx_snapshot.so
+vendor/lib/libchromatix_s5k2m8sx_zsl_preview_dw9767.so
+vendor/lib/libchromatix_s5k2m8sx_zsl_video_dw9767.so
+
+# Camera configs
+etc/camera/msm8996_camera.xml
+etc/camera/s5k2m8sx_chromatix.xml
+
+# Camera eeproms
+vendor/lib/libmmcamera_onsemi_cat24c64_eeprom.so
+
+# Camera sensors
+vendor/lib/libmmcamera_ov8865.so
+vendor/lib/libmmcamera_s5k2m8sx.so
+
+# IMS
+etc/permissions/imscm.xml
+framework/imscmlibrary.jar
+framework/rcsimssettings.jar
+
+# Media
+vendor/lib64/libmmosal.so
+
+# RIL
+vendor/lib/libimsmedia_jni.so
+
+# Sensors
+bin/sensorservice
+etc/sensors/hals.conf
+etc/sensors/sensor_def_qcomdev.conf
+etc/permissions/com.maxim.biosensor.xml
+framework/com.maxim.biosensor.jar
+-priv-app/XuiUHealth/XuiUHealth.apk|59a276a0913333448da66b61503135efccf10afd
+lib/libsensorservice.so
+lib/libmaximsensor-jni.so
+lib/libmaximsensormgr-jni.so
+lib64/libsensorservice.so
+lib64/libmaximsensor-jni.so
+lib64/libmaximsensormgr-jni.so
+vendor/lib64/libmxbio.so
+vendor/lib64/libmxbio_uv.so
+vendor/lib/sensors.maxim-bio.so
+vendor/lib64/sensors.maxim-bio.so
+
+# Other files (todo categorize)
+bin/hvdcp_opti
From c1b24c54b957c730e0b6530ea50bfac7d3f24d38 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:40:27 +0800
Subject: [PATCH 03/23] z2x
new.device
---
lineage.dependencies | 1 +
1 file changed, 1 insertion(+)
diff --git a/lineage.dependencies b/lineage.dependencies
index d4b50dc7..cba2aff4 100644
--- a/lineage.dependencies
+++ b/lineage.dependencies
@@ -1,3 +1,4 @@
+#z2x
[
{
"repository": "android_device_zuk_msm8996-common",
From 5d874e3f02390a41c7090edd45c1d6c597d98625 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:41:32 +0800
Subject: [PATCH 04/23] z2x.opretion
---
extract-files.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/extract-files.sh b/extract-files.sh
index 88a8de0a..b246b0eb 100755
--- a/extract-files.sh
+++ b/extract-files.sh
@@ -25,10 +25,10 @@ fi
set -e
# Required!
-export DEVICE=z2_plus
+export DEVICE=z2x
export DEVICE_COMMON=msm8996-common
export VENDOR=zuk
-export DEVICE_BRINGUP_YEAR=2016
+export DEVICE_BRINGUP_YEAR=2017
source "./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@"
From 98e72deb8c280e5ef663235af109a6d9ae96f745 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:46:34 +0800
Subject: [PATCH 05/23] z2x update
---
lineage_z2_plus.mk | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/lineage_z2_plus.mk b/lineage_z2_plus.mk
index 6c7d48c1..a90a15d1 100644
--- a/lineage_z2_plus.mk
+++ b/lineage_z2_plus.mk
@@ -17,29 +17,29 @@
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/full_base_telephony.mk)
-# Inherit from z2_plus device
-$(call inherit-product, device/zuk/z2_plus/device.mk)
+# Inherit from z2x device
+$(call inherit-product, device/zuk/z2x/device.mk)
# Inherit some common Lineage stuff.
$(call inherit-product, vendor/lineage/config/common_full_phone.mk)
# Device identifier. This must come after all inclusions.
-PRODUCT_NAME := lineage_z2_plus
-PRODUCT_DEVICE := z2_plus
+PRODUCT_NAME := lineage_z2x
+PRODUCT_DEVICE := z2x
PRODUCT_BRAND := ZUK
-PRODUCT_MODEL := Z2 Plus
+PRODUCT_MODEL := z2x
PRODUCT_MANUFACTURER := ZUK
PRODUCT_GMS_CLIENTID_BASE := android-zuk
-TARGET_VENDOR_PRODUCT_NAME := z2_plus
-TARGET_VENDOR_DEVICE_NAME := z2_plus
+TARGET_VENDOR_PRODUCT_NAME := z2x
+TARGET_VENDOR_DEVICE_NAME := z2x
# Fingerprint
PRODUCT_BUILD_PROP_OVERRIDES += \
- TARGET_DEVICE="z2_plus" \
- PRODUCT_NAME="z2_plus" \
- PRIVATE_BUILD_DESC="z2_plus-user 7.0 NRD90M 3.1.117_171110 release-keys"
+ TARGET_DEVICE="z2x" \
+ PRODUCT_NAME="z2x" \
+ PRIVATE_BUILD_DESC="z2x-user 7.0 NRD90M 3.1.193_171023 release-keys"
# Set BUILD_FINGERPRINT variable to be picked up by both system and vendor build.prop
-BUILD_FINGERPRINT := "ZUK/z2_plus/z2_plus:7.0/NRD90M/3.1.117_171110:user/release-keys"
+BUILD_FINGERPRINT := "ZUK/z2x/z2x:7.0/NRD90M/3.1.193_171023:user/release-keys"
TARGET_VENDOR := zuk
From edaf456726bf83519443810d644c14c7d057cce1 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 20:47:57 +0800
Subject: [PATCH 06/23] Rename lineage_z2_plus.mk to lineage_z2x.mk
---
lineage_z2_plus.mk => lineage_z2x.mk | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename lineage_z2_plus.mk => lineage_z2x.mk (100%)
diff --git a/lineage_z2_plus.mk b/lineage_z2x.mk
similarity index 100%
rename from lineage_z2_plus.mk
rename to lineage_z2x.mk
From 0658c8bd70aa562d550ba4a4a39bf855fe47e309 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:26:40 +0800
Subject: [PATCH 07/23] ZUK2X TARGET
---
device.mk | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/device.mk b/device.mk
index 32715477..a30b5c58 100755
--- a/device.mk
+++ b/device.mk
@@ -22,14 +22,15 @@
#
# Inherit from vendor
-$(call inherit-product-if-exists, vendor/zuk/z2_plus/z2_plus-vendor.mk)
+$(call inherit-product-if-exists, vendor/zuk/z2/z2x-vendor.mk)
# Inherit from msm8996-common
$(call inherit-product, device/zuk/msm8996-common/msm8996.mk)
+# Audio
PRODUCT_COPY_FILES += \
- $(LOCAL_PATH)/audio/audio_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info.xml \
- $(LOCAL_PATH)/audio/mixer_paths_tasha.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths.xml
+ $(LOCAL_PATH)/audio/mixer_paths_tasha.xml:system/etc/mixer_paths_tasha.xml \
+ $(LOCAL_PATH)/audio/audio_platform_info.xml:system/etc/audio_platform_info.xml
# Overlays
DEVICE_PACKAGE_OVERLAYS += \
@@ -42,3 +43,10 @@ PRODUCT_PACKAGES += \
# Vendor properties
-include $(LOCAL_PATH)/vendor_prop.mk
+
+# Fix ADB
+ADDITIONAL_DEFAULT_PROPERTIES += \
+ro.secure=0 \
+ro.debuggable=1 \
+persist.sys.usb.config=mtp \
+ro.adb.secure=0
From e09acd5a16ad7cb6b8de1c68e7916d1b58b49454 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:28:03 +0800
Subject: [PATCH 08/23] z2x audio prop opration
---
vendor_prop.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vendor_prop.mk b/vendor_prop.mk
index c5c984f0..fc0870f0 100644
--- a/vendor_prop.mk
+++ b/vendor_prop.mk
@@ -1,3 +1,3 @@
-# Audio
+# Audio Z2X
PRODUCT_PROPERTY_OVERRIDES += \
persist.vendor.audio.speaker.prot.enable=true
From 72b1eebe66587edbb3453802e5bffcf47900597c Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:30:27 +0800
Subject: [PATCH 09/23] add z2x support
---
BoardConfig.mk | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/BoardConfig.mk b/BoardConfig.mk
index dab431b9..0267ff6a 100644
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -24,16 +24,18 @@
# Inherit from common msm8996-common
-include device/zuk/msm8996-common/BoardConfigCommon.mk
-DEVICE_PATH := device/zuk/z2_plus
+DEVICE_PATH := device/zuk/z2x
# Assert
-TARGET_OTA_ASSERT_DEVICE := z2,Z2,z2plus,z2_plus
+TARGET_OTA_ASSERT_DEVICE := z2x
# Audio
AUDIO_FEATURE_ENABLED_SPKR_PROTECTION := true
# Kernel
-TARGET_KERNEL_CONFIG := z2_plus_defconfig
+TARGET_KERNEL_CONFIG := z2x_defconfig
+
+TARGET_SYSTEM_PROP += $(DEVICE_PATH)/system.prop
# inherit from the proprietary version
--include vendor/zuk/z2_plus/BoardConfigVendor.mk
+-include vendor/zuk/z2x/BoardConfigVendor.mk
From c2060e12d47e244486ffed536df382f808eba269 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:34:26 +0800
Subject: [PATCH 10/23] z2x ;sprop
---
system.prop | 4 ++++
1 file changed, 4 insertions(+)
create mode 100644 system.prop
diff --git a/system.prop b/system.prop
new file mode 100644
index 00000000..27f61602
--- /dev/null
+++ b/system.prop
@@ -0,0 +1,4 @@
+# Display (Qualcomm AD)
+ro.qualcomm.cabl=0
+# Graphics
+ro.sf.lcd_density=460
From 9aefd7e98a99706c50054d834401752284a623a9 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:36:15 +0800
Subject: [PATCH 11/23] z2x changes
---
Android.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Android.mk b/Android.mk
index a34a8792..6f633105 100644
--- a/Android.mk
+++ b/Android.mk
@@ -26,6 +26,6 @@
LOCAL_PATH := $(call my-dir)
-ifeq ($(TARGET_DEVICE),z2_plus)
+ifeq ($(TARGET_DEVICE),z2x)
include $(call all-makefiles-under,$(LOCAL_PATH))
endif
From 057b6a29794500e5ee236128794bc0586f1fa812 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:37:27 +0800
Subject: [PATCH 12/23] Update AndroidProducts.mk
---
AndroidProducts.mk | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/AndroidProducts.mk b/AndroidProducts.mk
index 7e04fbe7..de2279fe 100644
--- a/AndroidProducts.mk
+++ b/AndroidProducts.mk
@@ -14,9 +14,9 @@
# limitations under the License.
PRODUCT_MAKEFILES := \
- $(LOCAL_DIR)/lineage_z2_plus.mk
+ $(LOCAL_DIR)/lineage_z2x.mk
COMMON_LUNCH_CHOICES := \
- lineage_z2_plus-user \
- lineage_z2_plus-userdebug \
- lineage_z2_plus-eng
+ lineage_z2x-user \
+ lineage_z2x-userdebug \
+ lineage_z2x-eng
From 300a6b283638fb8249d849e05e5ac81811680b82 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:38:07 +0800
Subject: [PATCH 13/23] 2016-2017
---
setup-makefiles.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup-makefiles.sh b/setup-makefiles.sh
index 5ddcfa6e..fece4dc4 100755
--- a/setup-makefiles.sh
+++ b/setup-makefiles.sh
@@ -23,6 +23,6 @@ export DEVICE=z2x
export DEVICE_COMMON=msm8996-common
export VENDOR=zuk
-export DEVICE_BRINGUP_YEAR=2016
+export DEVICE_BRINGUP_YEAR=2017
source "./../../${VENDOR}/${DEVICE_COMMON}/setup-makefiles.sh" "$@"
From 3657f2cd48fe6d8e407c78b4b2cb42b449bfa727 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:41:40 +0800
Subject: [PATCH 14/23] Update init.zuk.rc
---
rootdir/etc/init.zuk.rc | 49 +++++++----------------------------------
1 file changed, 8 insertions(+), 41 deletions(-)
diff --git a/rootdir/etc/init.zuk.rc b/rootdir/etc/init.zuk.rc
index 8349e052..c21674ac 100644
--- a/rootdir/etc/init.zuk.rc
+++ b/rootdir/etc/init.zuk.rc
@@ -1,44 +1,11 @@
-# Copyright (c) 2019, The Linux Foundation. All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions are met:
-# * Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# * 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.
-# * Neither the name of The Linux Foundation nor
-# the names of its contributors may be used to endorse or promote
-# products derived from this software without specific prior written
-# permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-# NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER 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.
-#
+# Device-specific init script for zuk msm8996 devices
-on init
- # Disable MMC powersaving
- write /sys/devices/soc/${ro.boot.bootdevice}/mmc_host/mmc0/clk_scaling/enable 0
- write /sys/devices/soc/74a4900.sdhci/mmc_host/mmc1/clk_scaling/enable 0
- write /sys/devices/soc/${ro.boot.bootdevice}/pm_qos_irq_enable 0
+service hvdcp_opti /system/bin/hvdcp_opti
+ class main
+ user root
+ group root
on charger
- # Enable MMC powersaving
- write /sys/devices/soc/${ro.boot.bootdevice}/mmc_host/mmc0/clk_scaling/enable 1
- write /sys/devices/soc/74a4900.sdhci/mmc_host/mmc1/clk_scaling/enable 1
- write /sys/devices/soc/${ro.boot.bootdevice}/pm_qos_irq_enable 1
-
-on sys.post_boot.parsed=1
- # Enable MMC powersaving
- write /sys/devices/soc/${ro.boot.bootdevice}/mmc_host/mmc0/clk_scaling/enable 1
- write /sys/devices/soc/74a4900.sdhci/mmc_host/mmc1/clk_scaling/enable 1
- write /sys/devices/soc/${ro.boot.bootdevice}/pm_qos_irq_enable 1
+ wait /dev/block/bootdevice/by-name/system
+ mount ext4 /dev/block/bootdevice/by-name/system /system ro barrier=1
+ start hvdcp_opti
From 551780c0117c3978cf657f9903927dff4ba0dc0f Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:42:29 +0800
Subject: [PATCH 15/23] zuk msm8996 device
---
rootdir/Android.mk | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/rootdir/Android.mk b/rootdir/Android.mk
index 2c2ffeb3..73cb584c 100644
--- a/rootdir/Android.mk
+++ b/rootdir/Android.mk
@@ -1,11 +1,11 @@
-LOCAL_PATH:= $(call my-dir)
+LOCAL_PATH := $(call my-dir)
-# Device specific init script
+# Device init scripts
include $(CLEAR_VARS)
-LOCAL_MODULE := init.zuk.rc
-LOCAL_MODULE_TAGS := optional
-LOCAL_MODULE_CLASS := ETC
-LOCAL_SRC_FILES := etc/init.zuk.rc
-LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)/init/hw
+LOCAL_MODULE := init.zuk.rc
+LOCAL_MODULE_TAGS := optional eng
+LOCAL_MODULE_CLASS := ETC
+LOCAL_SRC_FILES := etc/init.zuk.rc
+LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT)
include $(BUILD_PREBUILT)
From 6021581124e6affb30c8949d2156767b7f94a65d Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:44:06 +0800
Subject: [PATCH 16/23] Update audio_platform_info.xml
---
audio/audio_platform_info.xml | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/audio/audio_platform_info.xml b/audio/audio_platform_info.xml
index 7612497a..a9d499fc 100644
--- a/audio/audio_platform_info.xml
+++ b/audio/audio_platform_info.xml
@@ -53,5 +53,13 @@
+
+
+
+
+
+
+
+
From f86df5c65ea7d9643c144c5b5d33815a67ce3e86 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:45:33 +0800
Subject: [PATCH 17/23] Update mixer_paths_tasha.xml
---
audio/mixer_paths_tasha.xml | 267 ++++++++++++++++++++----------------
1 file changed, 151 insertions(+), 116 deletions(-)
diff --git a/audio/mixer_paths_tasha.xml b/audio/mixer_paths_tasha.xml
index 375a1bd1..7837328d 100644
--- a/audio/mixer_paths_tasha.xml
+++ b/audio/mixer_paths_tasha.xml
@@ -26,15 +26,15 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
@@ -510,20 +510,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -548,12 +534,16 @@
+
+
+
+
-
+
@@ -572,11 +562,20 @@
+
+
+
+
+
+
+
+
+
@@ -601,7 +600,7 @@
-
+
@@ -620,6 +619,10 @@
+
+
+
+
@@ -635,6 +638,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -648,28 +665,24 @@
-
-
-
-
-
-
-
-
-
+
+
+
+
+
-
+
@@ -718,6 +731,10 @@
+
+
+
+
@@ -733,6 +750,11 @@
+
+
+
+
+
@@ -747,10 +769,6 @@
-
-
-
-
@@ -762,6 +780,10 @@
+
+
+
+
@@ -795,7 +817,7 @@
-
+
@@ -839,7 +861,7 @@
-
+
@@ -883,7 +905,7 @@
-
+
@@ -927,7 +949,7 @@
-
+
@@ -971,7 +993,7 @@
-
+
@@ -1015,7 +1037,7 @@
-
+
@@ -1059,7 +1081,7 @@
-
+
@@ -1103,7 +1125,7 @@
-
+
@@ -1180,16 +1202,17 @@
-
-
-
-
-
+
+
+
+
+
+
@@ -1215,11 +1238,6 @@
-
-
-
-
-
@@ -1230,6 +1248,12 @@
+
+
+
+
+
+
@@ -1255,12 +1279,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1395,14 +1432,6 @@
-
-
-
-
-
-
-
-
@@ -1413,16 +1442,17 @@
-
-
-
-
-
+
+
+
+
+
+
@@ -1454,7 +1484,7 @@
-
+
@@ -1489,11 +1519,6 @@
-
-
-
-
-
@@ -1530,10 +1555,21 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1570,7 +1606,12 @@
-
+
+
+
+
+
+
@@ -1781,13 +1822,6 @@
-
-
-
-
-
-
-
@@ -1843,10 +1877,12 @@
-
-
-
+
+
+
+
+
@@ -1876,6 +1912,7 @@
+
@@ -1886,7 +1923,7 @@
-
+
@@ -1934,16 +1971,11 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
@@ -2020,6 +2052,16 @@
+
+
+
+
+
+
+
+
+
+
@@ -2198,17 +2240,11 @@
-
+
-
-
-
-
-
-
@@ -2252,7 +2288,7 @@
-
+
@@ -2261,23 +2297,23 @@
-
-
+
+
-
-
-
-
+
+
+
+
-
+
@@ -2289,8 +2325,7 @@
-
-
+
From 3a68618c2356c587e685430eca3ad7d705eab79c Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:47:50 +0800
Subject: [PATCH 18/23] Update config.xml
---
overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml b/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
index 09565b32..29d8d959 100644
--- a/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
+++ b/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
@@ -45,5 +45,6 @@
LIGHTS_ADJUSTABLE_BATTERY_LED_BRIGHTNESS = 128
For example, a device with notification and battery lights that supports
pulsating and RGB control would set this config to 75. -->
- 232
+ 43
+
From 85cd6346f5ca04a2975f283e648aad95ad91d442 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:50:50 +0800
Subject: [PATCH 19/23] Update power_profile.xml
---
.../base/core/res/res/xml/power_profile.xml | 87 +++++++------------
1 file changed, 33 insertions(+), 54 deletions(-)
diff --git a/overlay/frameworks/base/core/res/res/xml/power_profile.xml b/overlay/frameworks/base/core/res/res/xml/power_profile.xml
index 22fdbdf8..117947c3 100644
--- a/overlay/frameworks/base/core/res/res/xml/power_profile.xml
+++ b/overlay/frameworks/base/core/res/res/xml/power_profile.xml
@@ -1,57 +1,32 @@
- - 200
- - 360
+ - 0
+ - 120
+ - 200
+ - 20
+ - 1
+ - 2
+ - 30
+ - 100
+ - 10
- 100
+ - 50
- 800
- - 0
- - 0.5
- - 100
- - 100
- - 3700
-
-
- 49
- 11
+ - 350
+ - 10
+
+ 30
+ 30
+ 25
+ 10
+ 5
+ 5
- - 3700
-
-
- - 0.01
-
- - 8
-
- - 7
-
- - 3300
-
2
2
-
-
- - 50.93
-
- - 75.60
-
-
- - 5.734
-
- - 1.389
-
-
- - 18.760
-
-
- - 14.748
-
- - 21.155
-
-
+
307200
422400
480000
@@ -68,7 +43,7 @@
1401600
1593600
-
+
307200
403200
480000
@@ -95,7 +70,9 @@
2073600
2150400
-
+ - 10
+ - 30
+
40
48
52
@@ -112,7 +89,7 @@
238
300
-
+
38
42
45
@@ -139,10 +116,12 @@
425
456
- - 3500
- - 0.5
- - 40
- - 40
-
- - 3700
+ - 3090
+
+ 0.015
+ 0.122
+ 0.962
+ 7.682
+ 61.488
+
From 79e823acaeb7e54734fd008f70b85b44cad9044a Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Wed, 4 Aug 2021 21:52:44 +0800
Subject: [PATCH 20/23] Update config.xml
---
.../base/core/res/res/values/config.xml | 75 ++++++++++---------
1 file changed, 38 insertions(+), 37 deletions(-)
diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml
index 063c2cab..767b2f0e 100644
--- a/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/overlay/frameworks/base/core/res/res/values/config.xml
@@ -1,9 +1,12 @@
-
true
- - 1
- - 11
- - 25
- - 50
- - 100
- - 200
- - 300
- - 500
- - 750
- - 1000
- - 5000
- - 10000
+ - 8
+ - 45
+ - 90
+ - 135
+ - 225
+ - 300
+ - 525
+ - 675
+ - 825
+ - 1200
+ - 1500
+ - 2250
+ - 3000
- - 7
- - 12
- - 17
- - 29
- - 35
- - 47
- - 75
- - 114
- - 130
- - 152
- - 175
- - 200
+ - 33
+ - 49
+ - 113
+ - 128
+ - 128
+ - 128
+ - 143
+ - 169
+ - 191
+ - 202
+ - 216
+ - 225
+ - 238
- 255
- 1
+ 10
@@ -80,21 +87,15 @@
brightness changes occur in response to an observed change in light level that exceeds the
hysteresis threshold. -->
2000
- 2000
+ 5000
- 200%
+ 300%
- 5000
-
-
- 0xFFFFFFFF
-
-
- 0xFFFFFFFF
+ 10000
-
- 0xFFFFFFFF
+
+ false
From 0dd036035119edc0ec37eacb9f690c808deaa893 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Thu, 5 Aug 2021 14:48:56 +0800
Subject: [PATCH 21/23] Update README.md
---
README.md | 29 +----------------------------
1 file changed, 1 insertion(+), 28 deletions(-)
diff --git a/README.md b/README.md
index 16c3a695..d89a7652 100644
--- a/README.md
+++ b/README.md
@@ -1,28 +1 @@
-Unified device configuration for Lenovo ZUK Z2/Z2 Plus
-==============
-
-Lenovo ZUK Z2/Z2 Plus (codenamed _"z2_plus"_) are high-end smartphones from Lenovo.
-
-Lenovo ZUK Z2 was announced in May 2016. Release date was June 2016.
-Lenovo Z2 Plus was announced in September 2016. Release date was September 2016.
-
-## Device specifications
-
-| Device | Lenovo ZUK Z2 / Z2 Plus (Z2131/Z2132) |
-| -----------: | :---------------------------------------------- |
-| SoC | Qualcomm MSM8996 Snapdragon 820 |
-| CPU | Quad-core (2x2.15 GHz Kryo & 2x1.6 GHz Kryo) |
-| GPU | 624MHz Adreno 530 |
-| Memory | 3 / 4 GB (LPDDR4 1866MHz dual-channel) |
-| Shipped Android version | 6.0.1
-| Upgradable Android version| 7.0/(8.0 china only)
-| Storage | 32 / 64 GB (eMMC 5.1) |
-| Battery | Non-removable Li-Po 3500 mAh |
-| Dimensions | 68.88 x 141.65 x 8.45 mm |
-| Display | 1920 x 1080 px, 5.0 inches (441 PPI) |
-| Rear camera | 13 MPx, f/2.0, PDAF autofocus, LED flash |
-| Front camera | 8 MPx, f/2.0, 1.4 µm pixel size |
-
-## Device picture
-
-![Lenovo ZUK Z2](https://raw.githubusercontent.com/LineageOS/lineage_wiki/0895ca77a9ebe7ba399ebf574e5afe334aa6d138/images/devices/z2_plus.png "ZUK Z2 in Titanium Black")
+Device configuration for ZUK EDGE (z2x).
From 6f42ee5d8a0a7b6e372848af21fe5614c1601539 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Fri, 6 Aug 2021 18:42:50 +0800
Subject: [PATCH 22/23] remove android 7 old opration
---
rootdir/Android.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rootdir/Android.mk b/rootdir/Android.mk
index 73cb584c..643cafb6 100644
--- a/rootdir/Android.mk
+++ b/rootdir/Android.mk
@@ -4,7 +4,7 @@ LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := init.zuk.rc
-LOCAL_MODULE_TAGS := optional eng
+LOCAL_MODULE_TAGS := optional
LOCAL_MODULE_CLASS := ETC
LOCAL_SRC_FILES := etc/init.zuk.rc
LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT)
From 0fcbcc25bc9223eea4166e1918063faea0b34d99 Mon Sep 17 00:00:00 2001
From: Xpsoted <37337416+Xpsoted@users.noreply.github.com>
Date: Fri, 6 Aug 2021 18:45:57 +0800
Subject: [PATCH 23/23] Remove
---
device.mk | 6 ------
1 file changed, 6 deletions(-)
diff --git a/device.mk b/device.mk
index a30b5c58..039d3b44 100755
--- a/device.mk
+++ b/device.mk
@@ -44,9 +44,3 @@ PRODUCT_PACKAGES += \
# Vendor properties
-include $(LOCAL_PATH)/vendor_prop.mk
-# Fix ADB
-ADDITIONAL_DEFAULT_PROPERTIES += \
-ro.secure=0 \
-ro.debuggable=1 \
-persist.sys.usb.config=mtp \
-ro.adb.secure=0