Initial unified commit for Android 12, syncing up to v400.a

This commit is contained in:
Andy CrossGate Yan
2021-10-20 14:54:55 +00:00
commit 796726eb09
166 changed files with 20826 additions and 0 deletions

View File

@@ -0,0 +1,46 @@
From 3b33cbc0f0f6642bcb609a3d88e516452147debe Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Mon, 5 Oct 2020 01:51:46 +0000
Subject: [PATCH] build: Don't handle apns-conf
Leave it to vendor/lineage instead
Change-Id: I51fb1436ee0ee2e33b20ca0810b69e827f3f34dc
---
target/product/aosp_product.mk | 7 -------
target/product/full_base_telephony.mk | 5 -----
2 files changed, 12 deletions(-)
diff --git a/target/product/aosp_product.mk b/target/product/aosp_product.mk
index b41c35fb7..bdaa57aac 100644
--- a/target/product/aosp_product.mk
+++ b/target/product/aosp_product.mk
@@ -37,10 +37,3 @@ PRODUCT_PACKAGES += \
PhotoTable \
preinstalled-packages-platform-aosp-product.xml \
WallpaperPicker \
-
-# Telephony:
-# Provide a APN configuration to GSI product
-ifeq ($(LINEAGE_BUILD),)
-PRODUCT_COPY_FILES += \
- device/sample/etc/apns-full-conf.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/apns-conf.xml
-endif
diff --git a/target/product/full_base_telephony.mk b/target/product/full_base_telephony.mk
index e4f5a162b..5470ad2be 100644
--- a/target/product/full_base_telephony.mk
+++ b/target/product/full_base_telephony.mk
@@ -26,10 +26,5 @@ PRODUCT_VENDOR_PROPERTIES := \
PRODUCT_COPY_FILES := \
frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml
-ifeq ($(LINEAGE_BUILD),)
-PRODUCT_COPY_FILES += \
- device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml
-endif
-
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony.mk)
--
2.25.1

View File

@@ -0,0 +1,192 @@
From defdefa842a5673bac917c9f5c2508aece8eebb8 Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Sun, 8 Aug 2021 01:43:40 +0000
Subject: [PATCH 1/4] treble: Lineage-ify
Squash of:
- Revert "Update lineage.mk for LineageOS 16.0"
- Remove fsck SELinux labels
- treble: Add overlay-lineage
- treble: Don't specify config_wallpaperCropperPackage
- treble: Don't handle apns-conf
---
base-pre.mk | 3 -
base.mk | 16 ++--
lineage.mk | 1 +
.../lineage/res/res/values/config.xml | 81 +++++++++++++++++++
.../base/core/res/res/values/config.xml | 1 -
sepolicy/file_contexts | 3 -
6 files changed, 91 insertions(+), 14 deletions(-)
create mode 100644 overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
diff --git a/base-pre.mk b/base-pre.mk
index 6a317e4..e69de29 100644
--- a/base-pre.mk
+++ b/base-pre.mk
@@ -1,3 +0,0 @@
-#Use a more decent APN config
-PRODUCT_COPY_FILES += \
- device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml
diff --git a/base.mk b/base.mk
index 3697c49..0bd6bf0 100644
--- a/base.mk
+++ b/base.mk
@@ -8,12 +8,14 @@ PRODUCT_COPY_FILES := \
frameworks/native/data/etc/android.hardware.bluetooth_le.xml:system/etc/permissions/android.hardware.bluetooth_le.xml \
frameworks/native/data/etc/android.hardware.usb.host.xml:system/etc/permissions/android.hardware.usb.host.xml \
-#Use a more decent APN config
-PRODUCT_COPY_FILES += \
- device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml
-
BOARD_PLAT_PRIVATE_SEPOLICY_DIR += device/phh/treble/sepolicy
-PRODUCT_PACKAGE_OVERLAYS += device/phh/treble/overlay
+
+PRODUCT_PACKAGE_OVERLAYS += \
+ device/phh/treble/overlay \
+ device/phh/treble/overlay-lineage
+
+PRODUCT_ENFORCE_RRO_EXCLUDED_OVERLAYS += \
+ device/phh/treble/overlay-lineage/lineage-sdk
$(call inherit-product, vendor/hardware_overlay/overlay.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
@@ -30,11 +32,11 @@ PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
ro.build.version.security_patch=$(PLATFORM_SECURITY_PATCH) \
ro.adb.secure=0 \
ro.logd.auditd=true
-
+
#Huawei HiSuite (also other OEM custom programs I guess) it's of no use in AOSP builds
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
persist.sys.usb.config=adb \
- ro.cust.cdrom=/dev/null
+ ro.cust.cdrom=/dev/null
#VNDK config files
PRODUCT_COPY_FILES += \
diff --git a/lineage.mk b/lineage.mk
index 172bb01..f6315b9 100644
--- a/lineage.mk
+++ b/lineage.mk
@@ -1,3 +1,4 @@
$(call inherit-product, vendor/lineage/config/common_full_phone.mk)
+$(call inherit-product, device/lineage/sepolicy/common/sepolicy.mk)
-include vendor/lineage/build/core/config.mk
-include vendor/lineage/build/core/apicheck.mk
diff --git a/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml b/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
new file mode 100644
index 0000000..8df673a
--- /dev/null
+++ b/overlay-lineage/lineage-sdk/lineage/res/res/values/config.xml
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2015-2016 The CyanogenMod Project
+ 2017-2018 The LineageOS Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+ http://www.apache.org/licenses/LICENSE-2.0
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<resources>
+ <!-- Whether device has screen with higher aspect ratio -->
+ <bool name="config_haveHigherAspectRatioScreen">true</bool>
+
+ <!-- All the capabilities of the LEDs on this device, stored as a bit field.
+ This integer should equal the sum of the corresponding value for each
+ of the following capabilities present:
+ // Device has a color adjustable battery light.
+ LIGHTS_RGB_NOTIFICATION_LED = 1
+ // Device has a color adjustable notification light.
+ LIGHTS_RGB_BATTERY_LED = 2
+ LIGHTS_MULTIPLE_NOTIFICATION_LED = 4 (deprecated)
+ // The notification light has adjustable pulsing capability.
+ LIGHTS_PULSATING_LED = 8
+ // Device has a multi-segment battery light that is able to
+ // use the light brightness value to determine how many
+ // segments to show (in order to represent battery level).
+ LIGHTS_SEGMENTED_BATTERY_LED = 16
+ // The notification light supports HAL adjustable brightness
+ // via the alpha channel.
+ // Note: if a device notification light supports LIGHTS_RGB_NOTIFICATION_LED
+ // then HAL support is not necessary for brightness control. In this case,
+ // brightness support will be provided by lineage-sdk through the scaling of
+ // RGB color values.
+ LIGHTS_ADJUSTABLE_NOTIFICATION_LED_BRIGHTNESS = 32
+ // Device has a battery light.
+ LIGHTS_BATTERY_LED = 64
+ // The battery light supports HAL adjustable brightness via
+ // the alpha channel.
+ // Note: if a device battery light supports LIGHTS_RGB_BATTERY_LED then HAL
+ // support is not necessary for brightness control. In this case,
+ // brightness support will be provided by lineage-sdk through the scaling of
+ // RGB color values.
+ 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. -->
+ <integer name="config_deviceLightCapabilities">255</integer>
+
+ <!-- Hardware keys present on the device, stored as a bit field.
+ This integer should equal the sum of the corresponding value for each
+ of the following keys present:
+ 1 - Home
+ 2 - Back
+ 4 - Menu
+ 8 - Assistant (search)
+ 16 - App switch
+ 32 - Camera
+ 64 - Volume rocker
+ For example, a device with Home, Back and Menu keys would set this
+ config to 7. -->
+ <integer name="config_deviceHardwareKeys">127</integer>
+
+ <!-- Hardware keys present on the device with the ability to wake, stored as a bit field.
+ This integer should equal the sum of the corresponding value for each
+ of the following keys present:
+ 1 - Home
+ 2 - Back
+ 4 - Menu
+ 8 - Assistant (search)
+ 16 - App switch
+ 32 - Camera
+ 64 - Volume rocker
+ For example, a device with Home, Back and Menu keys would set this
+ config to 7. -->
+ <integer name="config_deviceHardwareWakeKeys">127</integer>
+</resources>
diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml
index 2d5c21e..7a15163 100644
--- a/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/overlay/frameworks/base/core/res/res/values/config.xml
@@ -22,7 +22,6 @@
<string name="config_icon_mask" translatable="false">"M50 0C77.6 0 100 22.4 100 50C100 77.6 77.6 100 50 100C22.4 100 0 77.6 0 50C0 22.4 22.4 0 50 0Z"</string>
<bool name="config_useRoundIcon">true</bool>
- <string name="config_wallpaperCropperPackage">com.android.wallpaperpicker</string>
<bool name="config_unplugTurnsOnScreen">true</bool>
<integer name="config_multiuserMaximumUsers">5</integer>
<bool name="config_enableMultiUserUI">true</bool>
diff --git a/sepolicy/file_contexts b/sepolicy/file_contexts
index 4ae5095..5e39d5b 100644
--- a/sepolicy/file_contexts
+++ b/sepolicy/file_contexts
@@ -6,9 +6,6 @@
/system/bin/phh-on-data.sh u:object_r:phhsu_exec:s0
/system/bin/asus-motor u:object_r:phhsu_exec:s0
-#/system/bin/fsck\.exfat u:object_r:fsck_exec:s0
-/system/bin/fsck\.ntfs u:object_r:fsck_exec:s0
-
/bt_firmware(/.*)? u:object_r:bt_firmware_file:s0
/sec_storage(/.*)? u:object_r:teecd_data_file:s0
--
2.25.1

View File

@@ -0,0 +1,23 @@
From 0edf02638abc9086f1c5b9264e2429c1bd0fc7eb Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Sun, 8 Aug 2021 09:29:32 +0000
Subject: [PATCH 2/4] treble: Set BOARD_EXT4_SHARE_DUP_BLOCKS explicitly
Change-Id: I725443154fabde548d2e6c1b072d34c27596c421
---
board-base.mk | 2 ++
1 file changed, 2 insertions(+)
diff --git a/board-base.mk b/board-base.mk
index 1ddacaf..e363dd5 100644
--- a/board-base.mk
+++ b/board-base.mk
@@ -7,3 +7,5 @@ BOARD_ROOT_EXTRA_FOLDERS += bt_firmware sec_storage efs persist
BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true
BOARD_ROOT_EXTRA_SYMLINKS := $(filter-out $(BOARD_ROOT_EXTRA_SYMLINKS),/mnt/vendor/persist:/persist)
+
+BOARD_EXT4_SHARE_DUP_BLOCKS := true
--
2.25.1

View File

@@ -0,0 +1,25 @@
From 5be43b2a36ba7aefef95e5b3dc624a1d6c8d3e4d Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Wed, 20 Oct 2021 11:30:25 +0000
Subject: [PATCH 3/4] treble: Set TARGET_NO_KERNEL_OVERRIDE
Taken from Lineage generic targets - skips building kernel cleanly
Change-Id: Id71d3a3aed56fd4e815a64ef4191b125fc5026ce
---
board-base.mk | 2 ++
1 file changed, 2 insertions(+)
diff --git a/board-base.mk b/board-base.mk
index e363dd5..3900f97 100644
--- a/board-base.mk
+++ b/board-base.mk
@@ -9,3 +9,5 @@ BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true
BOARD_ROOT_EXTRA_SYMLINKS := $(filter-out $(BOARD_ROOT_EXTRA_SYMLINKS),/mnt/vendor/persist:/persist)
BOARD_EXT4_SHARE_DUP_BLOCKS := true
+
+TARGET_NO_KERNEL_OVERRIDE := true
--
2.25.1

View File

@@ -0,0 +1,20 @@
From 4a99143b5d49cf82a20f3057d26e7775de6db7d6 Mon Sep 17 00:00:00 2001
From: Victor Bo <bvoid@yandex.ru>
Date: Tue, 15 Sep 2020 21:26:45 -0400
Subject: [PATCH 4/4] add offline charger sepolicy
---
sepolicy/gsicharger.te | 1 +
1 file changed, 1 insertion(+)
create mode 100644 sepolicy/gsicharger.te
diff --git a/sepolicy/gsicharger.te b/sepolicy/gsicharger.te
new file mode 100644
index 0000000..91cfb5c
--- /dev/null
+++ b/sepolicy/gsicharger.te
@@ -0,0 +1 @@
+permissive charger;
--
2.25.1

View File

@@ -0,0 +1,42 @@
From 21961afe4adcc0e4d56420afaa28ded058178436 Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Sun, 8 Aug 2021 01:43:40 +0000
Subject: [PATCH] Revert "Add suspend_resume trace events to the atrace 'freq'
category."
This reverts commit 581c22f979af05e48ad4843cdfa9605186d286da.
Change-Id: I48895242e8567e91418c61d67a51de2b42f1008b
---
cmds/atrace/atrace.cpp | 1 -
cmds/atrace/atrace.rc | 2 --
2 files changed, 3 deletions(-)
diff --git a/cmds/atrace/atrace.cpp b/cmds/atrace/atrace.cpp
index 783a475829..8feba981da 100644
--- a/cmds/atrace/atrace.cpp
+++ b/cmds/atrace/atrace.cpp
@@ -173,7 +173,6 @@ static const TracingCategory k_categories[] = {
{ OPT, "events/clk/clk_disable/enable" },
{ OPT, "events/clk/clk_enable/enable" },
{ OPT, "events/power/cpu_frequency_limits/enable" },
- { OPT, "events/power/suspend_resume/enable" },
{ OPT, "events/cpuhp/cpuhp_enter/enable" },
{ OPT, "events/cpuhp/cpuhp_exit/enable" },
{ OPT, "events/cpuhp/cpuhp_pause/enable" },
diff --git a/cmds/atrace/atrace.rc b/cmds/atrace/atrace.rc
index e3c4edebbd..94e4796f45 100644
--- a/cmds/atrace/atrace.rc
+++ b/cmds/atrace/atrace.rc
@@ -61,8 +61,6 @@ on late-init
chmod 0666 /sys/kernel/tracing/events/cpuhp/cpuhp_pause/enable
chmod 0666 /sys/kernel/debug/tracing/events/power/gpu_frequency/enable
chmod 0666 /sys/kernel/tracing/events/power/gpu_frequency/enable
- chmod 0666 /sys/kernel/debug/tracing/events/power/suspend_resume/enable
- chmod 0666 /sys/kernel/tracing/events/power/suspend_resume/enable
chmod 0666 /sys/kernel/debug/tracing/events/cpufreq_interactive/enable
chmod 0666 /sys/kernel/tracing/events/cpufreq_interactive/enable
chmod 0666 /sys/kernel/debug/tracing/events/vmscan/mm_vmscan_direct_reclaim_begin/enable
--
2.25.1

View File

@@ -0,0 +1,38 @@
From ed8e7d31d3d96f9ce4f30aa452038d1eb2e9b561 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 4 Sep 2019 21:11:48 +0200
Subject: [PATCH 1/3] Panic into recovery rather than bootloader
Getting last_kmsg/pstore from bootloader isn't possible for other people
than the OEM, but we have TWRP to access last_kmsg/pstore
Change-Id: If04bb6572dc66677d7b44f7d302b2d69ce526200
---
init/reboot_utils.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/init/reboot_utils.cpp b/init/reboot_utils.cpp
index b3fa9fd3b..03b5a6f0e 100644
--- a/init/reboot_utils.cpp
+++ b/init/reboot_utils.cpp
@@ -36,7 +36,7 @@
namespace android {
namespace init {
-static std::string init_fatal_reboot_target = "bootloader";
+static std::string init_fatal_reboot_target = "recovery";
static bool init_fatal_panic = false;
// this needs to read the /proc/* files directly because it is called before
@@ -73,7 +73,7 @@ void SetFatalRebootTarget(const std::optional<std::string>& reboot_target) {
init_fatal_reboot_target = value;
}
});
- // We already default to bootloader if no setting is provided.
+ // We already default to recovery if no setting is provided.
} else {
const std::string kRebootTargetStringPattern = kRebootTargetString + "=";
start_pos += sizeof(kRebootTargetStringPattern) - 1;
--
2.25.1

View File

@@ -0,0 +1,87 @@
From fd8c95c473df2b62fd22ce3711b8ec7cfd2a337b Mon Sep 17 00:00:00 2001
From: Victor Bo <bvoid@yandex.ru>
Date: Wed, 3 Mar 2021 06:31:17 -0500
Subject: [PATCH 2/3] Restore /sbin for Magisk compatibility
Squash of:
- Revert "Do not create /sbin"
- Revert "Remove sbin from fs_config.cpp"
- add /sbin to the PATH
Change-Id: I1224c9b64ce8eb14f7d15c8441c0633a7e6a20de
---
CleanSpec.mk | 2 --
libcutils/fs_config.cpp | 3 +++
rootdir/Android.mk | 2 +-
rootdir/init.environ.rc.in | 1 +
4 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 0a534a2bd..81150a0fa 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -80,8 +80,6 @@ $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/etc/vndksp.libraries.txt)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/root/sbin/charger)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/sbin/charger)
-$(call add-clean-step, rm -rf $(PRODUCT_OUT)/root/sbin)
-$(call add-clean-step, rm -rf $(PRODUCT_OUT)/recovery/root/sbin)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/product_services)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/product_services.img)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/product_services)
diff --git a/libcutils/fs_config.cpp b/libcutils/fs_config.cpp
index e9497a806..8661c1684 100644
--- a/libcutils/fs_config.cpp
+++ b/libcutils/fs_config.cpp
@@ -80,6 +80,7 @@ static const struct fs_path_config android_dirs[] = {
{ 00771, AID_SYSTEM, AID_SYSTEM, 0, "data" },
{ 00755, AID_ROOT, AID_SYSTEM, 0, "mnt" },
{ 00751, AID_ROOT, AID_SHELL, 0, "product/bin" },
+ { 00750, AID_ROOT, AID_SHELL, 0, "sbin" },
{ 00751, AID_ROOT, AID_SHELL, 0, "product/apex/*/bin" },
{ 00777, AID_ROOT, AID_ROOT, 0, "sdcard" },
{ 00751, AID_ROOT, AID_SDCARD_R, 0, "storage" },
@@ -166,6 +167,7 @@ static const struct fs_path_config android_files[] = {
{ 00600, AID_ROOT, AID_ROOT, 0, "system_ext/build.prop" },
{ 00444, AID_ROOT, AID_ROOT, 0, system_ext_conf_dir + 1 },
{ 00444, AID_ROOT, AID_ROOT, 0, system_ext_conf_file + 1 },
+ { 00750, AID_ROOT, AID_SHELL, 0, "sbin/fs_mgr" },
{ 00755, AID_ROOT, AID_SHELL, 0, "system/bin/crash_dump32" },
{ 00755, AID_ROOT, AID_SHELL, 0, "system/bin/crash_dump64" },
{ 00755, AID_ROOT, AID_SHELL, 0, "system/bin/debuggerd" },
@@ -217,6 +219,7 @@ static const struct fs_path_config android_files[] = {
{ 00750, AID_ROOT, AID_SHELL, 0, "init*" },
{ 00755, AID_ROOT, AID_SHELL, 0, "odm/bin/*" },
{ 00755, AID_ROOT, AID_SHELL, 0, "product/bin/*" },
+ { 00750, AID_ROOT, AID_SHELL, 0, "sbin/*" },
{ 00755, AID_ROOT, AID_SHELL, 0, "product/apex/*bin/*" },
{ 00755, AID_ROOT, AID_SHELL, 0, "system/bin/*" },
{ 00755, AID_ROOT, AID_SHELL, 0, "system/xbin/*" },
diff --git a/rootdir/Android.mk b/rootdir/Android.mk
index 99d8f9a83..6788d2ebf 100644
--- a/rootdir/Android.mk
+++ b/rootdir/Android.mk
@@ -85,7 +85,7 @@ endif
#
# create some directories (some are mount points) and symlinks
LOCAL_POST_INSTALL_CMD := mkdir -p $(addprefix $(TARGET_ROOT_OUT)/, \
- dev proc sys system data data_mirror odm oem acct config storage mnt apex debug_ramdisk \
+ sbin dev proc sys system data data_mirror odm oem acct config storage mnt apex debug_ramdisk \
linkerconfig second_stage_resources postinstall $(BOARD_ROOT_EXTRA_FOLDERS)); \
ln -sf /system/bin $(TARGET_ROOT_OUT)/bin; \
ln -sf /system/etc $(TARGET_ROOT_OUT)/etc; \
diff --git a/rootdir/init.environ.rc.in b/rootdir/init.environ.rc.in
index bf6e986c4..090fa5a78 100644
--- a/rootdir/init.environ.rc.in
+++ b/rootdir/init.environ.rc.in
@@ -10,6 +10,7 @@ on early-init
export ANDROID_TZDATA_ROOT /apex/com.android.tzdata
export EXTERNAL_STORAGE /sdcard
export ASEC_MOUNTPOINT /mnt/asec
+ export PATH /sbin:/product/bin:/apex/com.android.runtime/bin:/apex/com.android.art/bin:/system_ext/bin:/system/bin:/system/xbin:/odm/bin:/vendor/bin:/vendor/xbin
%EXPORT_GLOBAL_ASAN_OPTIONS%
%EXPORT_GLOBAL_GCOV_OPTIONS%
%EXPORT_GLOBAL_CLANG_COVERAGE_OPTIONS%
--
2.25.1

View File

@@ -0,0 +1,52 @@
From 786f091175fad5b95b27e3806f5dd775f992826b Mon Sep 17 00:00:00 2001
From: Victor Bo <bvoid@yandex.ru>
Date: Wed, 26 Feb 2020 07:23:44 +0200
Subject: [PATCH 3/3] fix offline charger v7
modified: rootdir/init.rc
---
rootdir/init.rc | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/rootdir/init.rc b/rootdir/init.rc
index 376a678a8..6434d06bf 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -11,6 +11,11 @@ import /vendor/etc/init/hw/init.${ro.hardware}.rc
import /system/etc/init/hw/init.usb.configfs.rc
import /system/etc/init/hw/init.${ro.zygote}.rc
+service gsicharger /bin/charger
+ class gsicharger
+ user system
+ group system shell input graphics wakelock
+
# Cgroups are mounted right before early-init using list from /etc/cgroups.json
on early-init
# Disable sysrq from keyboard
@@ -452,7 +457,7 @@ on init
# Healthd can trigger a full boot from charger mode by signaling this
# property when the power button is held.
on property:sys.boot_from_charger_mode=1
- class_stop charger
+ class_stop gsicharger
trigger late-init
on load_persist_props_action
@@ -1090,8 +1095,12 @@ on nonencrypted
on property:sys.init_log_level=*
loglevel ${sys.init_log_level}
+on charger && property:ro.hardware=mt*
+ write /sys/class/leds/lcd-backlight/trigger "backlight"
+ write /sys/class/android_usb/android0/enable 1
+
on charger
- class_start charger
+ class_start gsicharger
on property:vold.decrypt=trigger_load_persist_props
load_persist_props
--
2.25.1

View File

@@ -0,0 +1,24 @@
From 4f035a6b34ee9f42774998de1c5008f6bce30a18 Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Sun, 8 Aug 2021 01:43:40 +0000
Subject: [PATCH] Revert "system_suspend: start early"
This reverts commit cb732f9b635b5f6f79e447ddaf743ebb800b8535.
---
suspend/1.0/default/android.system.suspend@1.0-service.rc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/suspend/1.0/default/android.system.suspend@1.0-service.rc b/suspend/1.0/default/android.system.suspend@1.0-service.rc
index 965ca16..c5d3869 100644
--- a/suspend/1.0/default/android.system.suspend@1.0-service.rc
+++ b/suspend/1.0/default/android.system.suspend@1.0-service.rc
@@ -1,5 +1,5 @@
service system_suspend /system/bin/hw/android.system.suspend@1.0-service
- class early_hal
+ class hal
user system
group system wakelock
capabilities BLOCK_SUSPEND
--
2.25.1

View File

@@ -0,0 +1,42 @@
From ce636dec0d85d9b74352a4defab35697ceffbf5d Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Mon, 5 Oct 2020 01:29:18 +0000
Subject: [PATCH] Revert "sepolicy: Relabel wifi. properties as wifi_prop"
This reverts commit bf52f194873840546c996c232eb44c8427ddcd5c.
Change-Id: I0446540331684eb57f7e17bcc3273d6247915854
---
private/property_contexts | 1 -
private/system_server.te | 3 ---
2 files changed, 4 deletions(-)
diff --git a/private/property_contexts b/private/property_contexts
index 4cec7348d..349e93141 100644
--- a/private/property_contexts
+++ b/private/property_contexts
@@ -201,7 +201,6 @@ qemu.hw.mainkeys u:object_r:qemu_hw_prop:s0 exact string
qemu.sf.lcd_density u:object_r:qemu_sf_lcd_density_prop:s0 exact int
# Shared between system server and wificond
-wifi. u:object_r:wifi_prop:s0
wlan. u:object_r:wifi_prop:s0
# Lowpan properties
diff --git a/private/system_server.te b/private/system_server.te
index 73301c1e9..befe6814e 100644
--- a/private/system_server.te
+++ b/private/system_server.te
@@ -748,9 +748,6 @@ get_prop(system_server, mock_ota_prop)
# Read the property as feature flag for protecting apks with fs-verity.
get_prop(system_server, apk_verity_prop)
-# Read wifi.interface
-get_prop(system_server, wifi_prop)
-
# Read the vendor property that indicates if Incremental features is enabled
get_prop(system_server, incremental_prop)
--
2.25.1

View File

@@ -0,0 +1,45 @@
From 4c8b1d00c09fa89e02174db9742e5cd214d0afea Mon Sep 17 00:00:00 2001
From: AndyCGYan <GeForce8800Ultra@gmail.com>
Date: Sun, 3 Mar 2019 14:07:33 +0800
Subject: [PATCH 1/2] build_soong: Disable generated_kernel_headers
...but done in a way so that there's no need to remove generated_kernel_headers from individual projects - thanks @ExpressLuke
Change-Id: I630857cec208f1830e776bf5031d7bb9bc4435d0
---
build/soong/Android.bp | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/build/soong/Android.bp b/build/soong/Android.bp
index ecfa9ac5..d8ad460d 100644
--- a/build/soong/Android.bp
+++ b/build/soong/Android.bp
@@ -20,9 +20,6 @@ bootstrap_go_package {
lineage_generator {
name: "generated_kernel_includes",
- // The headers make command
- cmd: "$(PATH_OVERRIDE_SOONG) $(KERNEL_MAKE_CMD) $(KERNEL_MAKE_FLAGS) -C $(TARGET_KERNEL_SOURCE) O=$(KERNEL_BUILD_OUT_PREFIX)$(genDir) ARCH=$(KERNEL_ARCH) $(KERNEL_CROSS_COMPILE) headers_install",
-
// Directories that can be imported by a cc_* module generated_headers property
export_include_dirs: [
"usr/audio/include/uapi",
@@ -31,15 +28,6 @@ lineage_generator {
"usr/include/audio/include/uapi",
"usr/techpack/audio/include",
],
-
- // Sources for dependency tracking
- dep_root: "$(TARGET_KERNEL_SOURCE)",
- dep_files: [
- "Makefile",
- "include/**/*",
- "arch/$(KERNEL_ARCH)/include/**/*",
- "techpack/audio/include/**/*",
- ],
}
cc_library_headers {
--
2.25.1

View File

@@ -0,0 +1,34 @@
From 39b514256d6808d950595331e0ba7bc72d860290 Mon Sep 17 00:00:00 2001
From: Andy CrossGate Yan <GeForce8800Ultra@gmail.com>
Date: Tue, 19 Oct 2021 15:48:43 +0000
Subject: [PATCH 2/2] vendor_lineage: Disable ADB authentication
Change-Id: I4370583ecab1c88ef6f42e29d3eaa52c24d13f09
---
config/common.mk | 5 -----
1 file changed, 5 deletions(-)
diff --git a/config/common.mk b/config/common.mk
index 55aab3f9..f85a7330 100644
--- a/config/common.mk
+++ b/config/common.mk
@@ -13,16 +13,11 @@ PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
ro.com.google.clientidbase=$(PRODUCT_GMS_CLIENTID_BASE)
endif
-ifeq ($(TARGET_BUILD_VARIANT),eng)
# Disable ADB authentication
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += ro.adb.secure=0
-else
-# Enable ADB authentication
-PRODUCT_SYSTEM_DEFAULT_PROPERTIES += ro.adb.secure=1
# Disable extra StrictMode features on all non-engineering builds
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += persist.sys.strictmode.disable=true
-endif
# Backup Tool
PRODUCT_COPY_FILES += \
--
2.25.1