Skip to content

Commit

Permalink
Synced with latest DerpFest source
Browse files Browse the repository at this point in the history
  • Loading branch information
KoysX committed Aug 22, 2023
1 parent d7e2006 commit cbeffa2
Show file tree
Hide file tree
Showing 28 changed files with 234 additions and 195 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
From e99b4ad1cd44f00c7a8be67f7c3949212a731caf Mon Sep 17 00:00:00 2001
From: ChonDoit <thphantomblog@gmail.com>
Date: Thu, 27 Jul 2023 21:34:49 +0000
Subject: [PATCH] Address a QcRilAudio denial

07-27 14:17:12.726 547 547 I auditd : avc: denied { find } for interface=vendor.qti.qcril.am::IQcRilAudio sid=u:r:system_app:s0 pid=3172 scontext=u:r:system_app:s0 tcontext=u:object_r:default_android_hwservice:s0 tclass=hwservice_manager permissive=0
07-27 14:17:12.734 547 547 I auditd : avc: denied { find } for interface=vendor.qti.qcril.am::IQcRilAudio sid=u:r:system_app:s0 pid=3172 scontext=u:r:system_app:s0 tcontext=u:object_r:default_android_hwservice:s0 tclass=hwservice_manager permissive=0
---
sepolicy/qcrilam_app.te | 3 +++
1 file changed, 3 insertions(+)

diff --git a/sepolicy/qcrilam_app.te b/sepolicy/qcrilam_app.te
index 2b8e76e..025bea5 100644
--- a/sepolicy/qcrilam_app.te
+++ b/sepolicy/qcrilam_app.te
@@ -20,3 +20,6 @@ allow qcrilam_app radio_service:service_manager find;
hal_client_domain(qcrilam_app, hal_telephony)

allow qcrilam_app cgroup:file w_file_perms;
+
+# Allow to find service
+allow system_app hal_telephony_hwservice:hwservice_manager find;
--
2.34.1

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
From 8c62135950a5e402d218b4be10f98055245c2049 Mon Sep 17 00:00:00 2001
From ba2ce1fd343673206b23ab1c1e229cea3f1352ad Mon Sep 17 00:00:00 2001
From: KoysX <2685697179b@gmail.com>
Date: Sun, 13 Aug 2023 10:34:10 +0800
Date: Tue, 22 Aug 2023 17:24:03 +0800
Subject: [PATCH] add-hide-status-bar-on-lock-screen

---
Expand All @@ -9,18 +9,20 @@ Subject: [PATCH] add-hide-status-bar-on-lock-screen
2 files changed, 10 insertions(+)

diff --git a/res/values/strings.xml b/res/values/strings.xml
index 8323f67..fd8498e 100644
index 65b7558..016f32d 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -586,4 +586,8 @@
<!-- Brightness slider haptic feedback -->
<string name="qs_brightness_slider_haptic_title">Haptic feedback</string>
<string name="qs_brightness_slider_haptic_summary">Provide haptic feedback on changing brightness using slider</string>
+
@@ -580,6 +580,10 @@
<string name="status_bar_battery_text_charging_title">Battery percentage when charging</string>
<string name="status_bar_battery_text_charging_summary">Always display battery percentage when charging</string>

+ <!-- Hide statusbar on lockscreen -->
+ <string name="lockscreen_hide_status_bar_title">Hide Statusbar</string>
+ <string name="lockscreen_hide_status_bar_summary">When enabled, statusbar will be hidden on lockscreen</string>
</resources>
+
<!-- QS battery -->
<string name="qs_use_status_bar_battery_style">Follow status bar style</string>

diff --git a/res/xml/lockscreen_ui.xml b/res/xml/lockscreen_ui.xml
index 822d33d..c16cf19 100644
--- a/res/xml/lockscreen_ui.xml
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
From 66b2552ddebfec8d865dbbf875caa834f4a1601e Mon Sep 17 00:00:00 2001
From a4f394dbe507e2eab074c2284e624d499ff33644 Mon Sep 17 00:00:00 2001
From: KoysX <2685697179b@gmail.com>
Date: Sun, 13 Aug 2023 10:38:07 +0800
Date: Tue, 22 Aug 2023 17:27:22 +0800
Subject: [PATCH] add-Lock-screen-clock-top-margin-settings

---
Expand All @@ -9,20 +9,22 @@ Subject: [PATCH] add-Lock-screen-clock-top-margin-settings
2 files changed, 19 insertions(+)

diff --git a/res/values/strings.xml b/res/values/strings.xml
index fd8498e..489b747 100644
index 016f32d..497900b 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -590,4 +590,8 @@
<!-- Hide statusbar on lockscreen -->
@@ -584,6 +584,10 @@
<string name="lockscreen_hide_status_bar_title">Hide Statusbar</string>
<string name="lockscreen_hide_status_bar_summary">When enabled, statusbar will be hidden on lockscreen</string>
+
+ <!-- Lockscreen Clock -->
+ <string name="lockscreen_clock_title">Clock</string>
+ <string name="kg_custom_clock_top_margin_title">Double-line clock position</string>
</resources>
+
<!-- QS battery -->
<string name="qs_use_status_bar_battery_style">Follow status bar style</string>

diff --git a/res/xml/lockscreen_ui.xml b/res/xml/lockscreen_ui.xml
index c16cf19..33f213e 100644
index c16cf19..304da54 100644
--- a/res/xml/lockscreen_ui.xml
+++ b/res/xml/lockscreen_ui.xml
@@ -43,12 +43,27 @@
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
From 676bfc4aa4b904cc65ae850f96f406bf8867860d Mon Sep 17 00:00:00 2001
From fdd8d5bbf75f80a6c06ce208872b949b62bc2d01 Mon Sep 17 00:00:00 2001
From: KoysX <2685697179b@gmail.com>
Date: Sun, 13 Aug 2023 10:42:12 +0800
Date: Tue, 22 Aug 2023 18:31:05 +0800
Subject: [PATCH] add-Lockscreen-text-size-settings

---
Expand All @@ -9,20 +9,22 @@ Subject: [PATCH] add-Lockscreen-text-size-settings
2 files changed, 22 insertions(+)

diff --git a/res/values/strings.xml b/res/values/strings.xml
index 489b747..35b8cce 100644
index 497900b..8fb97a5 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -594,4 +594,8 @@
<!-- Lockscreen Clock -->
@@ -588,6 +588,10 @@
<string name="lockscreen_clock_title">Clock</string>
<string name="kg_custom_clock_top_margin_title">Double-line clock position</string>
+
+ <!-- Lockscreen Clock size -->
+ <string name="kg_small_clock_text_size_title">Small Lockscreen clock size</string>
+ <string name="kg_big_clock_text_size_title">Double-line Lockscreen clock size</string>
</resources>
+
<!-- QS battery -->
<string name="qs_use_status_bar_battery_style">Follow status bar style</string>

diff --git a/res/xml/lockscreen_ui.xml b/res/xml/lockscreen_ui.xml
index 33f213e..ce6535f 100644
index 304da54..a4d06bc 100644
--- a/res/xml/lockscreen_ui.xml
+++ b/res/xml/lockscreen_ui.xml
@@ -64,6 +64,24 @@
Expand Down
Original file line number Diff line number Diff line change
@@ -1,39 +1,33 @@
From 75e8f7bbe3606b393759f143e9d932dab17bdf4d Mon Sep 17 00:00:00 2001
From 6e72ff95b3b1ad5f3481080cd6bf073b04c31219 Mon Sep 17 00:00:00 2001
From: KoysX <2685697179b@gmail.com>
Date: Sun, 13 Aug 2023 10:59:24 +0800
Date: Tue, 22 Aug 2023 18:37:29 +0800
Subject: [PATCH] add-Chinese-translation

---
res/values-zh-rCN/strings.xml | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
res/values-zh-rCN/strings.xml | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

diff --git a/res/values-zh-rCN/strings.xml b/res/values-zh-rCN/strings.xml
index 4d774fc..ca4deb8 100644
index 4d774fc..9bb4654 100644
--- a/res/values-zh-rCN/strings.xml
+++ b/res/values-zh-rCN/strings.xml
@@ -511,6 +511,12 @@
<!-- Fingerprint authentication vibration -->
@@ -512,6 +512,12 @@
<string name="fprint_sucess_vib_title">指纹识别振动</string>
<string name="fprint_sucess_vib_summary">当指纹识别成功时振动</string>

+ <!-- QS Header -->
+ <string name="qs_header_image_title">QS 标题图片</string>
+
+ <!-- Brightness slider styles -->
+ <string name="theme_customization_brightness_slider_title">亮度滑块样式</string>
+ <string name="theme_customization_brightness_slider_summary">设置自定义亮度滑块样式</string>

<!-- Navbar styles -->
<string name="theme_customization_navbar_title">导航栏样式</string>
@@ -571,4 +577,22 @@
<string name="theme_customization_navbar_summary">自定义导航栏样式</string>
@@ -571,4 +577,27 @@
<string name="status_bar_battery_percent_text_next_left">在图标左侧显示</string>
<string name="status_bar_battery_text_charging_title">充电时显示百分比</string>
<string name="status_bar_battery_text_charging_summary">充电时总是显示百分比</string>
+ <!-- QS battery -->
+ <string name="qs_use_status_bar_battery_style">遵循状态栏样式</string>
+
+ <!-- Brightness slider haptic feedback -->
+ <string name="qs_brightness_slider_haptic_title">触觉反馈</string>
+ <string name="qs_brightness_slider_haptic_summary">使用滑块提供有关更改亮度的触觉反馈</string>
+
+ <!-- Hide statusbar on lockscreen -->
+ <string name="lockscreen_hide_status_bar_title">隐藏状态栏</string>
Expand All @@ -46,6 +40,17 @@ index 4d774fc..ca4deb8 100644
+ <!-- Lockscreen Clock size -->
+ <string name="kg_small_clock_text_size_title">小锁屏时钟尺寸</string>
+ <string name="kg_big_clock_text_size_title">双线锁屏时钟尺寸</string>
+
+ <!-- QS battery -->
+ <string name="qs_use_status_bar_battery_style">遵循状态栏样式</string>
+
+ <!-- Brightness slider haptic feedback -->
+ <string name="qs_brightness_slider_haptic_title">触觉反馈</string>
+ <string name="qs_brightness_slider_haptic_summary">使用滑块提供有关更改亮度的触觉反馈</string>
+
+ <!-- Custom Data icons -->
+ <string name="theme_customization_data_title">数据图标样式</string>
+ <string name="theme_customization_data_summary">设置自定义数据图标样式</string>
</resources>
--
2.34.1
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
From 04a0ae146c09fe0e9da2d959df253a03ecb0edf5 Mon Sep 17 00:00:00 2001
From: ChonDoit <thphantomblog@gmail.com>
Date: Mon, 19 Jun 2023 22:26:48 +0000
Subject: [PATCH] Add Bluetooth BQR props and Nuke SAP Profile

---
system.prop | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/system.prop b/system.prop
index fa2a5c9..bfb6145 100644
--- a/system.prop
+++ b/system.prop
@@ -30,6 +30,7 @@ bluetooth.device.class_of_device=90,2,12

# Enable system-side generic bluetooth audio HAL
persist.bluetooth.system_audio_hal.enabled=1
+
# Set commonly-supported Bluetooth profiles to enabled
# TODO: Enable BLE Audio profiles on newer vendors
bluetooth.profile.asha.central.enabled?=true
@@ -45,7 +46,14 @@ bluetooth.profile.opp.enabled?=true
bluetooth.profile.pan.nap.enabled?=true
bluetooth.profile.pan.panu.enabled?=true
bluetooth.profile.pbap.server.enabled?=true
-bluetooth.profile.sap.server.enabled?=true
+#bluetooth.profile.sap.server.enabled?=true
+
+# System props to enable Bluetooth Quality Report (BQR) feature
+# BQR event mask configuration
+persist.bluetooth.bqr.event_mask=14
+
+# BQR minimum report interval configuration
+persist.bluetooth.bqr.min_interval_ms=500

# Samsung vendors default to a Samsung-specific gadget for MTP. Set this to use AOSP's functionfs MTP
vendor.usb.use_ffs_mtp=1
--
2.34.1

Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
From 4a7c81ca9da035f9aa03c41fa087fbdc5d2d87af Mon Sep 17 00:00:00 2001
From: ChonDoit <thphantomblog@gmail.com>
Date: Fri, 11 Nov 2022 21:09:06 +0000
Subject: [PATCH 3/5] Allow servicemanager to access hal_audio_sysbta

---
sepolicy/hal_audio_sysbta.te | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/sepolicy/hal_audio_sysbta.te b/sepolicy/hal_audio_sysbta.te
index d871ed3..e5c6087 100644
--- a/sepolicy/hal_audio_sysbta.te
+++ b/sepolicy/hal_audio_sysbta.te
@@ -8,3 +8,7 @@ hal_client_domain(hal_audio_sysbta, hal_allocator)

# allow audioserver to call hal_audio dump with its own fd to retrieve status
allow hal_audio_sysbta audioserver:fifo_file write;
+
+# Allow servicemanager to access hal_audio_sysbta
+allow servicemanager hal_audio_sysbta:dir r_dir_perms;
+allow servicemanager hal_audio_sysbta:file r_file_perms;
--
2.34.1

Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
From 24b3713d636c6869b35a511a00495642c9b23ccd Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Thu, 20 Jul 2023 14:21:21 -0400
Subject: [PATCH 10/10] Allow /sys/vm/watermark_scale_factor conflict -- seen
on Freebox Player Pop

---
libsepol/cil/src/cil_post.c | 9 +++++++++
1 file changed, 9 insertions(+)

diff --git a/libsepol/cil/src/cil_post.c b/libsepol/cil/src/cil_post.c
index 97bf54f8..4cf1f2d3 100644
--- a/libsepol/cil/src/cil_post.c
+++ b/libsepol/cil/src/cil_post.c
@@ -502,6 +502,15 @@ int cil_post_genfscon_context_compare(const void *a, const void *b)
*/
if(strcmp(a_genfscon->path_str, "/devices/virtual/block/") == 0)
bypass = 1;
+ /*
+ * This conflict has been seen on Freebox Player Pop
+ * - AOSP T says (genfscon proc "/sys/vm/watermark_scale_factor" (u object_r proc_watermark_scale_factor ((s0) (s0))))
+ * - stock rom says proc_vm_writable
+ *
+ * Stock ROM uses it only in recovery so it's safe to ignore
+ */
+ if(strcmp(a_genfscon->path_str, "/sys/vm/watermark_scale_factor") == 0)
+ bypass = 1;
if(strcmp(a_genfscon->fs_str, "exfat") == 0 || strcmp(a_genfscon->fs_str, "esdfs") == 0) {
if(strcmp(a_genfscon->path_str, "/") == 0)
bypass = 1;
--
2.25.1

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 0e03861ed56e34e1939568663de2417e5b0472d5 Mon Sep 17 00:00:00 2001
From 108a6882f66d5754bdb1083cb06ed6d57da69a1b Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 23 Feb 2022 17:37:47 -0500
Subject: [PATCH 01/16] Let system override ro.apex.updatable
Subject: [PATCH 01/19] Let system override ro.apex.updatable

APEX are broken because of a kernel bug in Android 10 devices
So we have system set ro.apex.updatable = false
Expand Down
4 changes: 2 additions & 2 deletions patches/trebledroid/platform_system_core/0002-If-Vboot2-fails-fall-back-to-Vboot1.patch
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From e5e70656233bb1baccd4e03970d938df7e01b660 Mon Sep 17 00:00:00 2001
From eb47cb08272eaa5c6b9e7adf33ba65bd03a41043 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Thu, 12 Sep 2019 13:05:37 +0200
Subject: [PATCH 02/16] If Vboot2 fails, fall-back to Vboot1
Subject: [PATCH 02/19] If Vboot2 fails, fall-back to Vboot1

Some devices, for instance Honor View 10, running Pie vendor declares
vbmeta in their device-tree, but doesn't have a vbmeta partition.
Expand Down
Loading

0 comments on commit cbeffa2

Please sign in to comment.