From d718f7563281352641f907d219a984ed6200c7c2 Mon Sep 17 00:00:00 2001 From: xiaoleGun <1592501605@qq.com> Date: Fri, 6 May 2022 13:11:40 +0800 Subject: [PATCH] Syncing up PHH v413 patches Signed-off-by: xiaoleGun <1592501605@qq.com> --- build.sh | 2 +- .../0001-Fix-BT-in-call-on-CAF-devices.patch | 2 +- ...id-is-hardcoded-support-for-Asus-ZF6.patch | 2 +- ...again-with-trimmed-audio-port-name-i.patch | 2 +- ...SCO-devices.-Fallback-from-one-to-th.patch | 2 +- ...phh.samsung.camera_ids-property-to-a.patch | 2 +- ...rty-to-force-camera-timestamp-source.patch | 2 +- ...IH-devices-Fix-Earpiece-audio-output.patch | 2 +- ...onger-make-re-assigning-legacy-audio.patch | 2 +- ...phh.disable_a2dp_offload-property-to.patch | 2 +- ...-Make-camera-IDs-filter-out-optional.patch | 2 +- .../0011-Support-Samsung-R-multi-cams.patch | 2 +- ...Don-t-crash-on-unknown-audio-devices.patch | 2 +- ...Y_ROUTING.-This-is-a-leftover-of-tri.patch | 2 +- ...lume-policy-when-none-has-been-found.patch | 2 +- ...in-a-route-are-valid.-Dont-ignore-th.patch | 2 +- ...-are-enabled-ignore-system-only-came.patch | 2 +- ...d-Q-behavior-respectively-for-teleph.patch | 2 +- ...pport-for-audio-HAL-V2-from-the-fram.patch | 2 +- ...parsing-audio-hal-7.0-audio-policies.patch | 2 +- ...urces-in-a-route-are-valid.-Dont-ign.patch | 2 +- ...rce-disable-a2dp-offload-erase-all-m.patch | 2 +- ...rop-to-change-Samsung-flash-strength.patch | 57 +++++++++++++ ...le-flash-strength-on-samsung-hal-4.0.patch | 52 ++++++++++++ ...id-autobrightness-if-brightness-valu.patch | 4 +- ...uirement-for-visible-flag-to-sdcards.patch | 4 +- ...h-if-there-is-IR-HAL-is-not-declared.patch | 4 +- ...-Show-APN-Settings-for-CDMA-carriers.patch | 4 +- ...s-so-that-it-works-even-without-qtag.patch | 4 +- ...-Support-samsung-Pie-and-Q-light-hal.patch | 4 +- ...samsung-touch-physical-and-hover-pro.patch | 4 +- ...erriding-the-number-of-work-profiles.patch | 4 +- ...-wake-up-devices-just-as-well-as-bac.patch | 4 +- ...e-proximity-sensor-reporting-NaN-as-.patch | 4 +- ...ange-not-being-complete-on-Samsung-d.patch | 4 +- ...atch-like-behaviour-for-RRO-java-sid.patch | 8 +- ...ners-padding-overridable-with-persis.patch | 4 +- ...otification-about-console-service-be.patch | 4 +- ...t-Remove-unused-SystemProperties.set.patch | 4 +- ...nyManager-bring-back-getNetworkClass.patch | 4 +- ...-add-API-annotations-for-setTelephon.patch | 4 +- .../0018-Fix-Wakelock-issue.patch | 4 +- ...tect-pick-up-sensor-so-that-an-overl.patch | 4 +- ...nBuiltInDisplayCutoutRectApproximati.patch | 4 +- ...t-Fix-backlight-control-on-Galaxy-S9.patch | 4 +- ...d-support-for-app-signature-spoofing.patch | 10 +-- ...ch-long-press-power-behavior-in-AOSP.patch | 4 +- ...of-udfps-enroll-progress-bar.-Some-d.patch | 4 +- ...dd-UDFPS-support-for-various-devices.patch | 4 +- ...ze-boot-animation-to-match-screen-si.patch | 4 +- ...e-Samsung-Power-hal-in-libpowermanag.patch | 4 +- ...phh.ultrasonic_udfps-property-to-dis.patch | 4 +- ...A1-IPSec-keys.-This-is-required-to-i.patch | 4 +- .../0030-Fix-FOD-on-ZF8.patch | 4 +- ...of-fingerprint-cleanups-needed-on-so.patch | 4 +- .../0032-Switch-FOD-to-WHITE.patch | 25 ++++++ ...033-Support-samsung-ultrasonic-udfps.patch | 83 +++++++++++++++++++ ...e-when-there-is-no-hal-but-we-believ.patch | 6 +- ...-fingerprint-events-they-are-expecte.patch | 40 +++++++++ 59 files changed, 349 insertions(+), 92 deletions(-) create mode 100644 patches/phh/platform_frameworks_av/0022-Add-a-prop-to-change-Samsung-flash-strength.patch create mode 100644 patches/phh/platform_frameworks_av/0023-Support-variable-flash-strength-on-samsung-hal-4.0.patch create mode 100644 patches/phh/platform_frameworks_base/0032-Switch-FOD-to-WHITE.patch create mode 100644 patches/phh/platform_frameworks_base/0033-Support-samsung-ultrasonic-udfps.patch create mode 100644 patches/phh/platform_packages_apps_Settings/0002-Ignore-cancelled-fingerprint-events-they-are-expecte.patch diff --git a/build.sh b/build.sh index 5cdad3e..a186c9a 100755 --- a/build.sh +++ b/build.sh @@ -12,7 +12,7 @@ BUILD_DATE="$(date +%Y%m%d)" WITHOUT_CHECK_API=true BL=$PWD/treble_build_miku BD=$HOME/builds -VERSION="0.3.0" +VERSION="0.3.1" if [ ! -d .repo ] then diff --git a/patches/phh/platform_frameworks_av/0001-Fix-BT-in-call-on-CAF-devices.patch b/patches/phh/platform_frameworks_av/0001-Fix-BT-in-call-on-CAF-devices.patch index 965f78f..22cada7 100644 --- a/patches/phh/platform_frameworks_av/0001-Fix-BT-in-call-on-CAF-devices.patch +++ b/patches/phh/platform_frameworks_av/0001-Fix-BT-in-call-on-CAF-devices.patch @@ -1,7 +1,7 @@ From 916800d4b0051a5782daf64bc346a4cceace0005 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 5 Aug 2019 18:09:50 +0200 -Subject: [PATCH 01/21] Fix BT in-call on CAF devices +Subject: [PATCH 01/23] Fix BT in-call on CAF devices See https://github.com/phhusson/treble_experimentations/issues/374 diff --git a/patches/phh/platform_frameworks_av/0002-Add-partial-cam-id-is-hardcoded-support-for-Asus-ZF6.patch b/patches/phh/platform_frameworks_av/0002-Add-partial-cam-id-is-hardcoded-support-for-Asus-ZF6.patch index 0f59005..9f2a8f8 100644 --- a/patches/phh/platform_frameworks_av/0002-Add-partial-cam-id-is-hardcoded-support-for-Asus-ZF6.patch +++ b/patches/phh/platform_frameworks_av/0002-Add-partial-cam-id-is-hardcoded-support-for-Asus-ZF6.patch @@ -1,7 +1,7 @@ From 0d24da4471c956c2914563145b36079fa3a60c43 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 1 Oct 2019 13:35:49 +0200 -Subject: [PATCH 02/21] Add (partial, cam id is hardcoded) support for Asus ZF6 +Subject: [PATCH 02/23] Add (partial, cam id is hardcoded) support for Asus ZF6 motor camera Change-Id: Iea6e1370780a1d16f728748d1d948d092532d8fe diff --git a/patches/phh/platform_frameworks_av/0003-audiopolicy-try-again-with-trimmed-audio-port-name-i.patch b/patches/phh/platform_frameworks_av/0003-audiopolicy-try-again-with-trimmed-audio-port-name-i.patch index 47f436b..c851eea 100644 --- a/patches/phh/platform_frameworks_av/0003-audiopolicy-try-again-with-trimmed-audio-port-name-i.patch +++ b/patches/phh/platform_frameworks_av/0003-audiopolicy-try-again-with-trimmed-audio-port-name-i.patch @@ -1,7 +1,7 @@ From c58a31446818ebb902773b2ab08df003d0e475d6 Mon Sep 17 00:00:00 2001 From: Peter Cai Date: Thu, 23 Jan 2020 11:13:43 +0800 -Subject: [PATCH 03/21] audiopolicy: try again with trimmed audio port name if +Subject: [PATCH 03/23] audiopolicy: try again with trimmed audio port name if not found * In Spreadtrum BSP, some audio routes may contain ports with extra diff --git a/patches/phh/platform_frameworks_av/0004-There-are-three-SCO-devices.-Fallback-from-one-to-th.patch b/patches/phh/platform_frameworks_av/0004-There-are-three-SCO-devices.-Fallback-from-one-to-th.patch index 04f770b..df8e021 100644 --- a/patches/phh/platform_frameworks_av/0004-There-are-three-SCO-devices.-Fallback-from-one-to-th.patch +++ b/patches/phh/platform_frameworks_av/0004-There-are-three-SCO-devices.-Fallback-from-one-to-th.patch @@ -1,7 +1,7 @@ From 824d82434aaecbc2715c972087f2069e6eebe87c Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 13 Apr 2020 21:01:16 +0200 -Subject: [PATCH 04/21] There are three SCO devices. Fallback from one to the +Subject: [PATCH 04/23] There are three SCO devices. Fallback from one to the others if needed Change-Id: I414dcb6b154855c00cb8520b23dc1069827864b2 diff --git a/patches/phh/platform_frameworks_av/0005-Add-persist.sys.phh.samsung.camera_ids-property-to-a.patch b/patches/phh/platform_frameworks_av/0005-Add-persist.sys.phh.samsung.camera_ids-property-to-a.patch index 8fe426e..b7a1cf4 100644 --- a/patches/phh/platform_frameworks_av/0005-Add-persist.sys.phh.samsung.camera_ids-property-to-a.patch +++ b/patches/phh/platform_frameworks_av/0005-Add-persist.sys.phh.samsung.camera_ids-property-to-a.patch @@ -1,7 +1,7 @@ From dc55498f4d76231da48425f8566ab7146f4c3b08 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 14 May 2020 19:54:55 +0200 -Subject: [PATCH 05/21] Add persist.sys.phh.samsung.camera_ids property to +Subject: [PATCH 05/23] Add persist.sys.phh.samsung.camera_ids property to access hidden Samsung cameras Change-Id: I2c7bf535272acc28ed2277e96c78ddd28a0b4593 diff --git a/patches/phh/platform_frameworks_av/0006-Add-a-property-to-force-camera-timestamp-source.patch b/patches/phh/platform_frameworks_av/0006-Add-a-property-to-force-camera-timestamp-source.patch index 0202933..6ee2c7d 100644 --- a/patches/phh/platform_frameworks_av/0006-Add-a-property-to-force-camera-timestamp-source.patch +++ b/patches/phh/platform_frameworks_av/0006-Add-a-property-to-force-camera-timestamp-source.patch @@ -1,7 +1,7 @@ From 32be1cfcf302656f199cae844b6f6319c2466d7e Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 19 May 2020 14:01:14 +0200 -Subject: [PATCH 06/21] Add a property to force camera timestamp source +Subject: [PATCH 06/23] Add a property to force camera timestamp source Some devices wrongly report their timesource Camera's timesource can either be CLOCK_MONOTONIC, or CLOCK_BOOTTIME diff --git a/patches/phh/platform_frameworks_av/0007-FIH-devices-Fix-Earpiece-audio-output.patch b/patches/phh/platform_frameworks_av/0007-FIH-devices-Fix-Earpiece-audio-output.patch index c362953..06bebb6 100644 --- a/patches/phh/platform_frameworks_av/0007-FIH-devices-Fix-Earpiece-audio-output.patch +++ b/patches/phh/platform_frameworks_av/0007-FIH-devices-Fix-Earpiece-audio-output.patch @@ -1,7 +1,7 @@ From 0892e7af02bdc826c2ce3d7deb86da9d2505bc6d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 24 Apr 2018 00:14:28 +0200 -Subject: [PATCH 07/21] FIH devices: Fix "Earpiece" audio output +Subject: [PATCH 07/23] FIH devices: Fix "Earpiece" audio output On some FIH devices (confirmed on Razer, and probably on Aquos SS2), Earpiece is not listed in attachedDevices, and devicePort's profile diff --git a/patches/phh/platform_frameworks_av/0008-audiopolicy-No-longer-make-re-assigning-legacy-audio.patch b/patches/phh/platform_frameworks_av/0008-audiopolicy-No-longer-make-re-assigning-legacy-audio.patch index 2ede005..e51555c 100644 --- a/patches/phh/platform_frameworks_av/0008-audiopolicy-No-longer-make-re-assigning-legacy-audio.patch +++ b/patches/phh/platform_frameworks_av/0008-audiopolicy-No-longer-make-re-assigning-legacy-audio.patch @@ -1,7 +1,7 @@ From 3b80a0a038a30e2ab40baa8c08524e3a2fd07cfa Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 12 Sep 2020 12:32:50 +0200 -Subject: [PATCH 08/21] [audiopolicy] No longer make re-assigning legacy audio +Subject: [PATCH 08/23] [audiopolicy] No longer make re-assigning legacy audio groups fatal. Mi9 declares AUDIO_STREAM_PATCH and AUDIO_STREAM_REROUTING which is defined by framework too diff --git a/patches/phh/platform_frameworks_av/0009-Add-persist.sys.phh.disable_a2dp_offload-property-to.patch b/patches/phh/platform_frameworks_av/0009-Add-persist.sys.phh.disable_a2dp_offload-property-to.patch index 82ee1c3..013a5d9 100644 --- a/patches/phh/platform_frameworks_av/0009-Add-persist.sys.phh.disable_a2dp_offload-property-to.patch +++ b/patches/phh/platform_frameworks_av/0009-Add-persist.sys.phh.disable_a2dp_offload-property-to.patch @@ -1,7 +1,7 @@ From 9c109da3fe56548fdbde82ea0dc835daae688936 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 25 May 2020 21:26:54 +0200 -Subject: [PATCH 09/21] Add persist.sys.phh.disable_a2dp_offload property to +Subject: [PATCH 09/23] Add persist.sys.phh.disable_a2dp_offload property to force a2dp offload Change-Id: Id474540c33c594cc4010a1a398d82bff8aadaeea diff --git a/patches/phh/platform_frameworks_av/0010-Make-camera-IDs-filter-out-optional.patch b/patches/phh/platform_frameworks_av/0010-Make-camera-IDs-filter-out-optional.patch index 3299a2b..fd55fcc 100644 --- a/patches/phh/platform_frameworks_av/0010-Make-camera-IDs-filter-out-optional.patch +++ b/patches/phh/platform_frameworks_av/0010-Make-camera-IDs-filter-out-optional.patch @@ -1,7 +1,7 @@ From c89845b906de7deb6d83537467738546c7180c68 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 21 Dec 2020 20:19:11 +0100 -Subject: [PATCH 10/21] Make camera IDs filter-out optional +Subject: [PATCH 10/23] Make camera IDs filter-out optional Nowadays most people have Camera 2 apps, and would like to have all cameras, rather than limit which cameras are available. diff --git a/patches/phh/platform_frameworks_av/0011-Support-Samsung-R-multi-cams.patch b/patches/phh/platform_frameworks_av/0011-Support-Samsung-R-multi-cams.patch index 5b0e0d7..bfec1d5 100644 --- a/patches/phh/platform_frameworks_av/0011-Support-Samsung-R-multi-cams.patch +++ b/patches/phh/platform_frameworks_av/0011-Support-Samsung-R-multi-cams.patch @@ -1,7 +1,7 @@ From 0f58fd9defa9741053b713c565d2a1daac5761da Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 13 Mar 2021 14:20:03 -0500 -Subject: [PATCH 11/21] Support Samsung R multi-cams +Subject: [PATCH 11/23] Support Samsung R multi-cams Change-Id: If46f385e8dd16185cbf37ab083e6a1242e1d1555 --- diff --git a/patches/phh/platform_frameworks_av/0012-audiopolicy-Don-t-crash-on-unknown-audio-devices.patch b/patches/phh/platform_frameworks_av/0012-audiopolicy-Don-t-crash-on-unknown-audio-devices.patch index a7874fa..ff853e7 100644 --- a/patches/phh/platform_frameworks_av/0012-audiopolicy-Don-t-crash-on-unknown-audio-devices.patch +++ b/patches/phh/platform_frameworks_av/0012-audiopolicy-Don-t-crash-on-unknown-audio-devices.patch @@ -1,7 +1,7 @@ From df8e477da0e65c955287d42922b8164b1280b5fa Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 23 Mar 2021 00:16:42 +0100 -Subject: [PATCH 12/21] [audiopolicy] Don't crash on unknown audio devices +Subject: [PATCH 12/23] [audiopolicy] Don't crash on unknown audio devices Change-Id: I2df8d88f742da6a84aa8888cdf19de25444de919 --- diff --git a/patches/phh/platform_frameworks_av/0013-Reenable-STRATEGY_ROUTING.-This-is-a-leftover-of-tri.patch b/patches/phh/platform_frameworks_av/0013-Reenable-STRATEGY_ROUTING.-This-is-a-leftover-of-tri.patch index ee70582..96b6387 100644 --- a/patches/phh/platform_frameworks_av/0013-Reenable-STRATEGY_ROUTING.-This-is-a-leftover-of-tri.patch +++ b/patches/phh/platform_frameworks_av/0013-Reenable-STRATEGY_ROUTING.-This-is-a-leftover-of-tri.patch @@ -1,7 +1,7 @@ From 5d57fe1f7b8674d218fa4da2ae26bafaf7a35997 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 28 Mar 2021 14:47:52 +0200 -Subject: [PATCH 13/21] Reenable STRATEGY_ROUTING. This is a leftover of tries +Subject: [PATCH 13/23] Reenable STRATEGY_ROUTING. This is a leftover of tries of 587b198, wrongly commited in 20f869 --- diff --git a/patches/phh/platform_frameworks_av/0014-Use-a-fake-volume-policy-when-none-has-been-found.patch b/patches/phh/platform_frameworks_av/0014-Use-a-fake-volume-policy-when-none-has-been-found.patch index 77e844c..dac7b46 100644 --- a/patches/phh/platform_frameworks_av/0014-Use-a-fake-volume-policy-when-none-has-been-found.patch +++ b/patches/phh/platform_frameworks_av/0014-Use-a-fake-volume-policy-when-none-has-been-found.patch @@ -1,7 +1,7 @@ From 27b4d05e1f48fc403cbe9fb836f12da6aab19a95 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 28 Mar 2021 14:48:49 +0200 -Subject: [PATCH 14/21] Use a fake volume policy when none has been found +Subject: [PATCH 14/23] Use a fake volume policy when none has been found This is useful, because on Samsung devices, the "real" (=non-gsi-cheating) audio policy doesn't have any volume policy. diff --git a/patches/phh/platform_frameworks_av/0015-Not-all-sources-in-a-route-are-valid.-Dont-ignore-th.patch b/patches/phh/platform_frameworks_av/0015-Not-all-sources-in-a-route-are-valid.-Dont-ignore-th.patch index f20d8c2..6c3890a 100644 --- a/patches/phh/platform_frameworks_av/0015-Not-all-sources-in-a-route-are-valid.-Dont-ignore-th.patch +++ b/patches/phh/platform_frameworks_av/0015-Not-all-sources-in-a-route-are-valid.-Dont-ignore-th.patch @@ -1,7 +1,7 @@ From b9ea32b141dae4c7f225737443a5cb41a6a9faaf Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 28 Mar 2021 18:54:47 +0200 -Subject: [PATCH 15/21] Not all sources in a route are valid. Dont ignore the +Subject: [PATCH 15/23] Not all sources in a route are valid. Dont ignore the whole route because of one broken source Change-Id: If8a51740e71bef3a4738262ad7b43a337b0ec36d diff --git a/patches/phh/platform_frameworks_av/0016-When-aux-cameras-are-enabled-ignore-system-only-came.patch b/patches/phh/platform_frameworks_av/0016-When-aux-cameras-are-enabled-ignore-system-only-came.patch index fe3bfde..7f04ad1 100644 --- a/patches/phh/platform_frameworks_av/0016-When-aux-cameras-are-enabled-ignore-system-only-came.patch +++ b/patches/phh/platform_frameworks_av/0016-When-aux-cameras-are-enabled-ignore-system-only-came.patch @@ -1,7 +1,7 @@ From 5a737734728a01ac529e944b9cf3468c2a705a51 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 7 Aug 2021 11:11:39 +0200 -Subject: [PATCH 16/21] When aux cameras are enabled, ignore "system only" +Subject: [PATCH 16/23] When aux cameras are enabled, ignore "system only" camera flag (it shouldnt be q security issue since secure cameras are listed otherwise) diff --git a/patches/phh/platform_frameworks_av/0017-APM-Restore-R-and-Q-behavior-respectively-for-teleph.patch b/patches/phh/platform_frameworks_av/0017-APM-Restore-R-and-Q-behavior-respectively-for-teleph.patch index 630ac81..066f0e1 100644 --- a/patches/phh/platform_frameworks_av/0017-APM-Restore-R-and-Q-behavior-respectively-for-teleph.patch +++ b/patches/phh/platform_frameworks_av/0017-APM-Restore-R-and-Q-behavior-respectively-for-teleph.patch @@ -1,7 +1,7 @@ From dfc16f14f7fbc0bcf939c8109575c7a490e21328 Mon Sep 17 00:00:00 2001 From: Peter Cai Date: Tue, 19 Oct 2021 21:16:55 -0400 -Subject: [PATCH 17/21] APM: Restore R and Q behavior respectively for +Subject: [PATCH 17/23] APM: Restore R and Q behavior respectively for telephony audio This conditionally reverts part of 51c9cc (S) and afd4ce (R) when the diff --git a/patches/phh/platform_frameworks_av/0018-Revert-Remove-support-for-audio-HAL-V2-from-the-fram.patch b/patches/phh/platform_frameworks_av/0018-Revert-Remove-support-for-audio-HAL-V2-from-the-fram.patch index 320a1ea..249f0b9 100644 --- a/patches/phh/platform_frameworks_av/0018-Revert-Remove-support-for-audio-HAL-V2-from-the-fram.patch +++ b/patches/phh/platform_frameworks_av/0018-Revert-Remove-support-for-audio-HAL-V2-from-the-fram.patch @@ -1,7 +1,7 @@ From 72af9dcd6308a431ca446b05c51f12aa5f3fe519 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 11 Oct 2021 16:10:42 -0400 -Subject: [PATCH 18/21] Revert "Remove support for audio HAL V2 from the +Subject: [PATCH 18/23] Revert "Remove support for audio HAL V2 from the framework" This reverts commit cbf517f837f7bf8a59f3ff8aa1e0e3e19612e251. diff --git a/patches/phh/platform_frameworks_av/0019-Fix-parsing-audio-hal-7.0-audio-policies.patch b/patches/phh/platform_frameworks_av/0019-Fix-parsing-audio-hal-7.0-audio-policies.patch index f8d18df..b7ecf31 100644 --- a/patches/phh/platform_frameworks_av/0019-Fix-parsing-audio-hal-7.0-audio-policies.patch +++ b/patches/phh/platform_frameworks_av/0019-Fix-parsing-audio-hal-7.0-audio-policies.patch @@ -1,7 +1,7 @@ From 82cda3c120bd077967a25ebfa763058b0a26e311 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 30 Jan 2022 07:40:19 -0500 -Subject: [PATCH 19/21] Fix parsing audio hal 7.0 audio policies +Subject: [PATCH 19/23] Fix parsing audio hal 7.0 audio policies Google changed separator from natural "," to weird " " We broke its support in "FIH devices: Fix "Earpiece" audio output" diff --git a/patches/phh/platform_frameworks_av/0020-fixup-Not-all-sources-in-a-route-are-valid.-Dont-ign.patch b/patches/phh/platform_frameworks_av/0020-fixup-Not-all-sources-in-a-route-are-valid.-Dont-ign.patch index 1649443..210bf03 100644 --- a/patches/phh/platform_frameworks_av/0020-fixup-Not-all-sources-in-a-route-are-valid.-Dont-ign.patch +++ b/patches/phh/platform_frameworks_av/0020-fixup-Not-all-sources-in-a-route-are-valid.-Dont-ign.patch @@ -1,7 +1,7 @@ From 800291258096c3c24bfdc305b78c7dcf4b2749f7 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 12 Mar 2022 18:07:43 -0500 -Subject: [PATCH 20/21] fixup! Not all sources in a route are valid. Dont +Subject: [PATCH 20/23] fixup! Not all sources in a route are valid. Dont ignore the whole route because of one broken source --- diff --git a/patches/phh/platform_frameworks_av/0021-Next-level-of-force-disable-a2dp-offload-erase-all-m.patch b/patches/phh/platform_frameworks_av/0021-Next-level-of-force-disable-a2dp-offload-erase-all-m.patch index 9b43bc4..ee5fe19 100644 --- a/patches/phh/platform_frameworks_av/0021-Next-level-of-force-disable-a2dp-offload-erase-all-m.patch +++ b/patches/phh/platform_frameworks_av/0021-Next-level-of-force-disable-a2dp-offload-erase-all-m.patch @@ -1,7 +1,7 @@ From 44d39de1cfc88d0d1340cb18a2892af5247f321d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 5 Apr 2022 15:07:37 -0400 -Subject: [PATCH 21/21] Next level of force disable a2dp offload: erase all +Subject: [PATCH 21/23] Next level of force disable a2dp offload: erase all modules related to a2dp, and include our own --- diff --git a/patches/phh/platform_frameworks_av/0022-Add-a-prop-to-change-Samsung-flash-strength.patch b/patches/phh/platform_frameworks_av/0022-Add-a-prop-to-change-Samsung-flash-strength.patch new file mode 100644 index 0000000..f9f9882 --- /dev/null +++ b/patches/phh/platform_frameworks_av/0022-Add-a-prop-to-change-Samsung-flash-strength.patch @@ -0,0 +1,57 @@ +From 1bdf994a30913b300dafc07050b9e3c89e14d7e6 Mon Sep 17 00:00:00 2001 +From: Pierre-Hugues Husson +Date: Sat, 16 Apr 2022 14:30:14 -0400 +Subject: [PATCH 22/23] Add a prop to change Samsung flash strength + +--- + services/camera/libcameraservice/Android.bp | 1 + + .../common/CameraProviderManager.cpp | 14 +++++++++++++- + 2 files changed, 14 insertions(+), 1 deletion(-) + +diff --git a/services/camera/libcameraservice/Android.bp b/services/camera/libcameraservice/Android.bp +index a2a2ad623e..b616f8207f 100644 +--- a/services/camera/libcameraservice/Android.bp ++++ b/services/camera/libcameraservice/Android.bp +@@ -156,6 +156,7 @@ cc_library_shared { + "android.hardware.camera.device@3.7", + "vendor.samsung.hardware.camera.provider@3.0", + "vendor.samsung.hardware.camera.provider@4.0", ++ "vendor.samsung.hardware.camera.device@5.0", + "media_permission-aidl-cpp", + ], + +diff --git a/services/camera/libcameraservice/common/CameraProviderManager.cpp b/services/camera/libcameraservice/common/CameraProviderManager.cpp +index 3d969845fd..19f217711c 100644 +--- a/services/camera/libcameraservice/common/CameraProviderManager.cpp ++++ b/services/camera/libcameraservice/common/CameraProviderManager.cpp +@@ -23,6 +23,7 @@ + #include + #include + #include ++#include + + #include + #include +@@ -2278,7 +2279,18 @@ sp CameraProviderManager::ProviderInfo::DeviceInfo::startDeviceInter + template + status_t CameraProviderManager::ProviderInfo::DeviceInfo::setTorchMode(InterfaceT& interface, + bool enabled) { +- Status s = interface->setTorchMode(enabled ? TorchMode::ON : TorchMode::OFF); ++ int32_t flashStrength = property_get_int32("persist.sys.phh.flash_strength", 1); ++ ++ auto sehCast = vendor::samsung::hardware::camera::device::V5_0::ISehCameraDevice::castFrom(interface); ++ android::sp seh = sehCast; ++ ++ Status s; ++ if(seh != nullptr) { ++ s = seh->sehSetTorchModeStrength(enabled ? TorchMode::ON : TorchMode::OFF, flashStrength); ++ } else { ++ s = interface->setTorchMode(enabled ? TorchMode::ON : TorchMode::OFF); ++ } ++ + return mapToStatusT(s); + } + +-- +2.25.1 + diff --git a/patches/phh/platform_frameworks_av/0023-Support-variable-flash-strength-on-samsung-hal-4.0.patch b/patches/phh/platform_frameworks_av/0023-Support-variable-flash-strength-on-samsung-hal-4.0.patch new file mode 100644 index 0000000..67edcc5 --- /dev/null +++ b/patches/phh/platform_frameworks_av/0023-Support-variable-flash-strength-on-samsung-hal-4.0.patch @@ -0,0 +1,52 @@ +From 1a91caed21cabac752cbf65f9b80ee04b5cb10cd Mon Sep 17 00:00:00 2001 +From: Pierre-Hugues Husson +Date: Mon, 2 May 2022 17:37:09 -0400 +Subject: [PATCH 23/23] Support variable flash strength on samsung hal 4.0 + +--- + services/camera/libcameraservice/Android.bp | 1 + + .../libcameraservice/common/CameraProviderManager.cpp | 6 ++++++ + 2 files changed, 7 insertions(+) + +diff --git a/services/camera/libcameraservice/Android.bp b/services/camera/libcameraservice/Android.bp +index b616f8207f..3b99e643e5 100644 +--- a/services/camera/libcameraservice/Android.bp ++++ b/services/camera/libcameraservice/Android.bp +@@ -157,6 +157,7 @@ cc_library_shared { + "vendor.samsung.hardware.camera.provider@3.0", + "vendor.samsung.hardware.camera.provider@4.0", + "vendor.samsung.hardware.camera.device@5.0", ++ "vendor.samsung.hardware.camera.device@4.0", + "media_permission-aidl-cpp", + ], + +diff --git a/services/camera/libcameraservice/common/CameraProviderManager.cpp b/services/camera/libcameraservice/common/CameraProviderManager.cpp +index 19f217711c..f6d8e276ee 100644 +--- a/services/camera/libcameraservice/common/CameraProviderManager.cpp ++++ b/services/camera/libcameraservice/common/CameraProviderManager.cpp +@@ -24,6 +24,7 @@ + #include + #include + #include ++#include + + #include + #include +@@ -2284,9 +2285,14 @@ status_t CameraProviderManager::ProviderInfo::DeviceInfo::setTorchMode(Interface + auto sehCast = vendor::samsung::hardware::camera::device::V5_0::ISehCameraDevice::castFrom(interface); + android::sp seh = sehCast; + ++ auto sehCast2 = vendor::samsung::hardware::camera::device::V4_0::ISehCameraDevice::castFrom(interface); ++ android::sp seh2 = sehCast2; ++ + Status s; + if(seh != nullptr) { + s = seh->sehSetTorchModeStrength(enabled ? TorchMode::ON : TorchMode::OFF, flashStrength); ++ } else if(seh2 != nullptr) { ++ s = seh2->sehSetTorchModeStrength(enabled ? TorchMode::ON : TorchMode::OFF, flashStrength); + } else { + s = interface->setTorchMode(enabled ? TorchMode::ON : TorchMode::OFF); + } +-- +2.25.1 + diff --git a/patches/phh/platform_frameworks_base/0001-Fallback-to-stupid-autobrightness-if-brightness-valu.patch b/patches/phh/platform_frameworks_base/0001-Fallback-to-stupid-autobrightness-if-brightness-valu.patch index b3a927b..897fca6 100644 --- a/patches/phh/platform_frameworks_base/0001-Fallback-to-stupid-autobrightness-if-brightness-valu.patch +++ b/patches/phh/platform_frameworks_base/0001-Fallback-to-stupid-autobrightness-if-brightness-valu.patch @@ -1,7 +1,7 @@ -From 355d858a0fd153174f7cb455e2b4d71cf281bdc2 Mon Sep 17 00:00:00 2001 +From 4bfb5a9f63233628d831922167a31863199e026f Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 5 Oct 2021 17:59:16 -0400 -Subject: [PATCH 01/31] Fallback to stupid autobrightness if brightness values +Subject: [PATCH 01/33] Fallback to stupid autobrightness if brightness values are broken This is needed because of: diff --git a/patches/phh/platform_frameworks_base/0002-Relax-requirement-for-visible-flag-to-sdcards.patch b/patches/phh/platform_frameworks_base/0002-Relax-requirement-for-visible-flag-to-sdcards.patch index d27e0aa..048ea94 100644 --- a/patches/phh/platform_frameworks_base/0002-Relax-requirement-for-visible-flag-to-sdcards.patch +++ b/patches/phh/platform_frameworks_base/0002-Relax-requirement-for-visible-flag-to-sdcards.patch @@ -1,7 +1,7 @@ -From 9bc107ee34c7c8344c7457745563bdc469577932 Mon Sep 17 00:00:00 2001 +From c1ae967a3f4dfa98d092b022f12019ccc0215e3f Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 28 Nov 2017 18:28:04 +0100 -Subject: [PATCH 02/31] Relax requirement for visible flag to sdcards +Subject: [PATCH 02/33] Relax requirement for visible flag to sdcards The vast majority of sdcard readers are stable enough to be declared by the API. (I see no counter-example) diff --git a/patches/phh/platform_frameworks_base/0003-Don-t-crash-if-there-is-IR-HAL-is-not-declared.patch b/patches/phh/platform_frameworks_base/0003-Don-t-crash-if-there-is-IR-HAL-is-not-declared.patch index 679ff83..3d33726 100644 --- a/patches/phh/platform_frameworks_base/0003-Don-t-crash-if-there-is-IR-HAL-is-not-declared.patch +++ b/patches/phh/platform_frameworks_base/0003-Don-t-crash-if-there-is-IR-HAL-is-not-declared.patch @@ -1,7 +1,7 @@ -From f4ba9da5d8cb0c539d4e8ef209de82a33fc658e8 Mon Sep 17 00:00:00 2001 +From 7f5ca15c709a3f65aa7570c250073f407d57822d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 17 May 2018 20:28:35 +0200 -Subject: [PATCH 03/31] Don't crash if there is IR HAL is not declared +Subject: [PATCH 03/33] Don't crash if there is IR HAL is not declared Change-Id: I3afded27441bbee8244d5fda544b3e6d1238dc1b --- diff --git a/patches/phh/platform_frameworks_base/0004-Show-APN-Settings-for-CDMA-carriers.patch b/patches/phh/platform_frameworks_base/0004-Show-APN-Settings-for-CDMA-carriers.patch index 6260d77..9706108 100644 --- a/patches/phh/platform_frameworks_base/0004-Show-APN-Settings-for-CDMA-carriers.patch +++ b/patches/phh/platform_frameworks_base/0004-Show-APN-Settings-for-CDMA-carriers.patch @@ -1,7 +1,7 @@ -From b5c3cf536b951182784a1a6b55d6e84ca2e8c057 Mon Sep 17 00:00:00 2001 +From 002c33f4df78ef7ce20c5a0db5623ad9a7506820 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 6 Aug 2018 12:49:00 +0200 -Subject: [PATCH 04/31] Show APN Settings for CDMA carriers +Subject: [PATCH 04/33] Show APN Settings for CDMA carriers --- telephony/java/android/telephony/CarrierConfigManager.java | 2 +- diff --git a/patches/phh/platform_frameworks_base/0005-Re-order-services-so-that-it-works-even-without-qtag.patch b/patches/phh/platform_frameworks_base/0005-Re-order-services-so-that-it-works-even-without-qtag.patch index c8853d9..6fc73b5 100644 --- a/patches/phh/platform_frameworks_base/0005-Re-order-services-so-that-it-works-even-without-qtag.patch +++ b/patches/phh/platform_frameworks_base/0005-Re-order-services-so-that-it-works-even-without-qtag.patch @@ -1,7 +1,7 @@ -From 78a35ef7f5faebe19e4032c20c0e473155070194 Mon Sep 17 00:00:00 2001 +From 75a4b7a4e2ee5cafaafec3ac196e44844371d8ba Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 8 Nov 2018 23:04:03 +0100 -Subject: [PATCH 05/31] Re-order services so that it works even without qtaguid +Subject: [PATCH 05/33] Re-order services so that it works even without qtaguid Change-Id: I0c0f527b3ae151d45c68f7ac6c205da3f34e74df --- diff --git a/patches/phh/platform_frameworks_base/0006-Support-samsung-Pie-and-Q-light-hal.patch b/patches/phh/platform_frameworks_base/0006-Support-samsung-Pie-and-Q-light-hal.patch index d4c541c..24466b2 100644 --- a/patches/phh/platform_frameworks_base/0006-Support-samsung-Pie-and-Q-light-hal.patch +++ b/patches/phh/platform_frameworks_base/0006-Support-samsung-Pie-and-Q-light-hal.patch @@ -1,7 +1,7 @@ -From 867f4bb8c91d70957b2c47fc670ca5f24bdcb58b Mon Sep 17 00:00:00 2001 +From 825a9326749a609860c2312dd9de6afa5dcc2da4 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 24 Mar 2019 23:05:14 +0100 -Subject: [PATCH 06/31] Support samsung Pie and Q light hal +Subject: [PATCH 06/33] Support samsung Pie and Q light hal Change-Id: I01f94acd7d0672733e48854d80368f9ac6f861c6 --- diff --git a/patches/phh/platform_frameworks_base/0007-Add-support-for-samsung-touch-physical-and-hover-pro.patch b/patches/phh/platform_frameworks_base/0007-Add-support-for-samsung-touch-physical-and-hover-pro.patch index 3cc822c..a5559af 100644 --- a/patches/phh/platform_frameworks_base/0007-Add-support-for-samsung-touch-physical-and-hover-pro.patch +++ b/patches/phh/platform_frameworks_base/0007-Add-support-for-samsung-touch-physical-and-hover-pro.patch @@ -1,7 +1,7 @@ -From 77b91a3653b5fd82d3cc892e440c73b0287bebee Mon Sep 17 00:00:00 2001 +From 23263ec24e6566c222ab75f31a51fac5805e11f5 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 12 Aug 2019 23:08:26 +0200 -Subject: [PATCH 07/31] Add support for samsung touch, physical and hover +Subject: [PATCH 07/33] Add support for samsung touch, physical and hover proximity sensor as fallback to real proximity sensor Change-Id: I7a0f8b4665c802140d19197d850b77b2a7ac1865 diff --git a/patches/phh/platform_frameworks_base/0008-Always-allow-overriding-the-number-of-work-profiles.patch b/patches/phh/platform_frameworks_base/0008-Always-allow-overriding-the-number-of-work-profiles.patch index d628efd..c4a5799 100644 --- a/patches/phh/platform_frameworks_base/0008-Always-allow-overriding-the-number-of-work-profiles.patch +++ b/patches/phh/platform_frameworks_base/0008-Always-allow-overriding-the-number-of-work-profiles.patch @@ -1,7 +1,7 @@ -From eeb5dbb4faddde5ae72e84192e967b5507ae85f0 Mon Sep 17 00:00:00 2001 +From 599c13a40b83eeed3ad13372ad22c0852811b6d8 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 5 Apr 2020 16:32:46 +0200 -Subject: [PATCH 08/31] Always allow overriding the number of work profiles +Subject: [PATCH 08/33] Always allow overriding the number of work profiles Change-Id: I6eb09aa71663c6fbe7563e3038bffcabdba0ff6a --- diff --git a/patches/phh/platform_frameworks_base/0009-HOME-deserves-to-wake-up-devices-just-as-well-as-bac.patch b/patches/phh/platform_frameworks_base/0009-HOME-deserves-to-wake-up-devices-just-as-well-as-bac.patch index d1336cb..722f821 100644 --- a/patches/phh/platform_frameworks_base/0009-HOME-deserves-to-wake-up-devices-just-as-well-as-bac.patch +++ b/patches/phh/platform_frameworks_base/0009-HOME-deserves-to-wake-up-devices-just-as-well-as-bac.patch @@ -1,7 +1,7 @@ -From b7e49f7494e477f013c49c84dee80debe63b9918 Mon Sep 17 00:00:00 2001 +From 2862e025e37ddede66a19585e312e6fb2f658ac5 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 6 Jun 2020 18:21:56 +0200 -Subject: [PATCH 09/31] HOME deserves to wake-up devices just as well as back +Subject: [PATCH 09/33] HOME deserves to wake-up devices just as well as back and menu Change-Id: Ia562bafd8c620d00c17e8eb338e4701c6c4a3c3a diff --git a/patches/phh/platform_frameworks_base/0010-Some-devices-have-proximity-sensor-reporting-NaN-as-.patch b/patches/phh/platform_frameworks_base/0010-Some-devices-have-proximity-sensor-reporting-NaN-as-.patch index 2aca809..1a72725 100644 --- a/patches/phh/platform_frameworks_base/0010-Some-devices-have-proximity-sensor-reporting-NaN-as-.patch +++ b/patches/phh/platform_frameworks_base/0010-Some-devices-have-proximity-sensor-reporting-NaN-as-.patch @@ -1,7 +1,7 @@ -From 33b35423d23bbdd9aea87f828d190470d59392c9 Mon Sep 17 00:00:00 2001 +From 72ab3cbd29d247362c852ab89a32367793d5b136 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 29 Sep 2020 22:39:47 +0200 -Subject: [PATCH 10/31] Some devices have proximity sensor reporting NaN as max +Subject: [PATCH 10/33] Some devices have proximity sensor reporting NaN as max range for some reason. Make them behave standard way by setting 5 cm Change-Id: I3c39e3e914a05903c140235702e0480d2d58a612 diff --git a/patches/phh/platform_frameworks_base/0011-Fix-brightness-range-not-being-complete-on-Samsung-d.patch b/patches/phh/platform_frameworks_base/0011-Fix-brightness-range-not-being-complete-on-Samsung-d.patch index 7482135..5b77cdf 100644 --- a/patches/phh/platform_frameworks_base/0011-Fix-brightness-range-not-being-complete-on-Samsung-d.patch +++ b/patches/phh/platform_frameworks_base/0011-Fix-brightness-range-not-being-complete-on-Samsung-d.patch @@ -1,7 +1,7 @@ -From 89faa2e1bd7d30d15a1ec3ff184e46d5bbbcb138 Mon Sep 17 00:00:00 2001 +From de1f7b8bfad7a7aeb0a219635f8fbf83ebae4f7d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 29 Sep 2020 22:40:10 +0200 -Subject: [PATCH 11/31] Fix brightness range not being complete on Samsung +Subject: [PATCH 11/33] Fix brightness range not being complete on Samsung devices On some devices, minimum brightness is 0, which totally messes with diff --git a/patches/phh/platform_frameworks_base/0012-Re-implement-fnmatch-like-behaviour-for-RRO-java-sid.patch b/patches/phh/platform_frameworks_base/0012-Re-implement-fnmatch-like-behaviour-for-RRO-java-sid.patch index 56a0dc7..51afbeb 100644 --- a/patches/phh/platform_frameworks_base/0012-Re-implement-fnmatch-like-behaviour-for-RRO-java-sid.patch +++ b/patches/phh/platform_frameworks_base/0012-Re-implement-fnmatch-like-behaviour-for-RRO-java-sid.patch @@ -1,7 +1,7 @@ -From 74c7167049901a49a6169a123d37bccab17df86b Mon Sep 17 00:00:00 2001 +From 06e604017f745f62caafe82cd2741418b920eee5 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 25 Oct 2020 23:57:26 +0100 -Subject: [PATCH 12/31] Re-implement fnmatch-like behaviour for RRO java-side +Subject: [PATCH 12/33] Re-implement fnmatch-like behaviour for RRO java-side Change-Id: Id38292a9a1453aa87b8401c1fdb390fa4e63c7d1 --- @@ -9,10 +9,10 @@ Change-Id: Id38292a9a1453aa87b8401c1fdb390fa4e63c7d1 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/core/java/android/content/pm/PackageParser.java b/core/java/android/content/pm/PackageParser.java -index 1861b7226a47..1bea1681bd33 100644 +index f480b5ef0a43..9eca92146123 100644 --- a/core/java/android/content/pm/PackageParser.java +++ b/core/java/android/content/pm/PackageParser.java -@@ -2489,8 +2489,17 @@ public class PackageParser { +@@ -2496,8 +2496,17 @@ public class PackageParser { for (int i = 0; i < propNames.length; i++) { // Check property value: make sure it is both set and equal to expected value final String currValue = SystemProperties.get(propNames[i]); diff --git a/patches/phh/platform_frameworks_base/0013-Make-rounded-corners-padding-overridable-with-persis.patch b/patches/phh/platform_frameworks_base/0013-Make-rounded-corners-padding-overridable-with-persis.patch index 1ce450c..5b09be5 100644 --- a/patches/phh/platform_frameworks_base/0013-Make-rounded-corners-padding-overridable-with-persis.patch +++ b/patches/phh/platform_frameworks_base/0013-Make-rounded-corners-padding-overridable-with-persis.patch @@ -1,7 +1,7 @@ -From aa21662ed85bd79710ea9a828333906c34ae4278 Mon Sep 17 00:00:00 2001 +From a45f4973b75f0a9ab73bcc6e9abac8503b77d03c Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 6 Dec 2020 12:20:08 +0100 -Subject: [PATCH 13/31] Make rounded corners padding overridable with +Subject: [PATCH 13/33] Make rounded corners padding overridable with persist.sys.phh.rounded_corners_padding Change-Id: I481c1c8849b2f22a7cdfb2896a6d3c2e7e3b44d9 diff --git a/patches/phh/platform_frameworks_base/0014-Remove-useless-notification-about-console-service-be.patch b/patches/phh/platform_frameworks_base/0014-Remove-useless-notification-about-console-service-be.patch index c63baa6..dda6af2 100644 --- a/patches/phh/platform_frameworks_base/0014-Remove-useless-notification-about-console-service-be.patch +++ b/patches/phh/platform_frameworks_base/0014-Remove-useless-notification-about-console-service-be.patch @@ -1,7 +1,7 @@ -From 6ccc5eb362d760825dc147b814fcde703b9e6f4e Mon Sep 17 00:00:00 2001 +From 5d2291bb1a97c89a5e5cdb9efbdd80a4f9f67a35 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Fri, 11 Dec 2020 14:41:09 +0100 -Subject: [PATCH 14/31] Remove useless notification about "console" service +Subject: [PATCH 14/33] Remove useless notification about "console" service being running --- diff --git a/patches/phh/platform_frameworks_base/0015-Revert-Remove-unused-SystemProperties.set.patch b/patches/phh/platform_frameworks_base/0015-Revert-Remove-unused-SystemProperties.set.patch index 2a42935..39535ec 100644 --- a/patches/phh/platform_frameworks_base/0015-Revert-Remove-unused-SystemProperties.set.patch +++ b/patches/phh/platform_frameworks_base/0015-Revert-Remove-unused-SystemProperties.set.patch @@ -1,7 +1,7 @@ -From b6415ecb4e2639450d9680735dd8c2ed7d4b8d93 Mon Sep 17 00:00:00 2001 +From b8a9c80480b4ce9fb90a353ede9416bfa2cadb6c Mon Sep 17 00:00:00 2001 From: Peter Cai Date: Wed, 16 Dec 2020 21:24:12 +0800 -Subject: [PATCH 15/31] Revert "Remove unused SystemProperties.set" +Subject: [PATCH 15/33] Revert "Remove unused SystemProperties.set" This reverts commit debb4616ef67f9ed5054eca51ec58592358ff55f. diff --git a/patches/phh/platform_frameworks_base/0016-TelephonyManager-bring-back-getNetworkClass.patch b/patches/phh/platform_frameworks_base/0016-TelephonyManager-bring-back-getNetworkClass.patch index 3e8382e..fe7a605 100644 --- a/patches/phh/platform_frameworks_base/0016-TelephonyManager-bring-back-getNetworkClass.patch +++ b/patches/phh/platform_frameworks_base/0016-TelephonyManager-bring-back-getNetworkClass.patch @@ -1,7 +1,7 @@ -From d0f01cb4d70daf01f21bac3c3fe98a5df9c634c2 Mon Sep 17 00:00:00 2001 +From afdef33c7b633f2182b8fda78253207912a1fc49 Mon Sep 17 00:00:00 2001 From: Peter Cai Date: Wed, 16 Dec 2020 13:46:15 +0800 -Subject: [PATCH 16/31] TelephonyManager: bring back getNetworkClass() +Subject: [PATCH 16/33] TelephonyManager: bring back getNetworkClass() This partially reverts commit c058cac051ab083dc7fb7ea6aa85699110b2e9bf. diff --git a/patches/phh/platform_frameworks_base/0017-TelephonyManager-add-API-annotations-for-setTelephon.patch b/patches/phh/platform_frameworks_base/0017-TelephonyManager-add-API-annotations-for-setTelephon.patch index 5117166..4d420b2 100644 --- a/patches/phh/platform_frameworks_base/0017-TelephonyManager-add-API-annotations-for-setTelephon.patch +++ b/patches/phh/platform_frameworks_base/0017-TelephonyManager-add-API-annotations-for-setTelephon.patch @@ -1,7 +1,7 @@ -From 5469fa9f6569a2dd84f6a4f2803dc43dc5e1de2d Mon Sep 17 00:00:00 2001 +From 22ed64fe2ea83de43250109a340d4928a7ee4397 Mon Sep 17 00:00:00 2001 From: Peter Cai Date: Wed, 16 Dec 2020 21:26:45 +0800 -Subject: [PATCH 17/31] TelephonyManager: add API annotations for +Subject: [PATCH 17/33] TelephonyManager: add API annotations for setTelephonyProperty * This method was added back by reverting commit diff --git a/patches/phh/platform_frameworks_base/0018-Fix-Wakelock-issue.patch b/patches/phh/platform_frameworks_base/0018-Fix-Wakelock-issue.patch index 32fbfeb..fe6d7df 100644 --- a/patches/phh/platform_frameworks_base/0018-Fix-Wakelock-issue.patch +++ b/patches/phh/platform_frameworks_base/0018-Fix-Wakelock-issue.patch @@ -1,7 +1,7 @@ -From 613082424c5fc3cdedd85f9508795841497e8d15 Mon Sep 17 00:00:00 2001 +From afecb007bf55d5f78f39a021564d346e17a41c50 Mon Sep 17 00:00:00 2001 From: Alberto Ponces Date: Tue, 2 Feb 2021 10:20:51 +0000 -Subject: [PATCH 18/31] Fix Wakelock issue +Subject: [PATCH 18/33] Fix Wakelock issue Prevent SystemUI crash due to "WakeLock under-locked Doze" (issue #12) by only releasing a wakelock that was not already released --- diff --git a/patches/phh/platform_frameworks_base/0019-Automatically-detect-pick-up-sensor-so-that-an-overl.patch b/patches/phh/platform_frameworks_base/0019-Automatically-detect-pick-up-sensor-so-that-an-overl.patch index ca598ab..ac9bb1d 100644 --- a/patches/phh/platform_frameworks_base/0019-Automatically-detect-pick-up-sensor-so-that-an-overl.patch +++ b/patches/phh/platform_frameworks_base/0019-Automatically-detect-pick-up-sensor-so-that-an-overl.patch @@ -1,7 +1,7 @@ -From ea4d95380054641c2a979082417391f81ad351be Mon Sep 17 00:00:00 2001 +From f168c7b694345e591d8a9f98c73b34babeb7283e Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 20 Mar 2021 14:31:01 +0100 -Subject: [PATCH 19/31] Automatically detect pick up sensor, so that an overlay +Subject: [PATCH 19/33] Automatically detect pick up sensor, so that an overlay is required for the sole purpose of enabling pulse doze on pick up sensor --- diff --git a/patches/phh/platform_frameworks_base/0020-Catch-broken-mainBuiltInDisplayCutoutRectApproximati.patch b/patches/phh/platform_frameworks_base/0020-Catch-broken-mainBuiltInDisplayCutoutRectApproximati.patch index 5cc2ebf..33dd804 100644 --- a/patches/phh/platform_frameworks_base/0020-Catch-broken-mainBuiltInDisplayCutoutRectApproximati.patch +++ b/patches/phh/platform_frameworks_base/0020-Catch-broken-mainBuiltInDisplayCutoutRectApproximati.patch @@ -1,7 +1,7 @@ -From 480c5fd6abea5870c871c91d96287e54afccf824 Mon Sep 17 00:00:00 2001 +From 4adc4acf4af9b5c2f7cc7eef787e0031d5d0565d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 23 Mar 2021 19:43:26 +0100 -Subject: [PATCH 20/31] Catch broken mainBuiltInDisplayCutoutRectApproximation +Subject: [PATCH 20/33] Catch broken mainBuiltInDisplayCutoutRectApproximation Some devices (Redmi Note 9T) have: mainBuiltInDisplayCutoutRectApproximation = @android:mainBuiltInDisplayCutout diff --git a/patches/phh/platform_frameworks_base/0021-backlight-Fix-backlight-control-on-Galaxy-S9.patch b/patches/phh/platform_frameworks_base/0021-backlight-Fix-backlight-control-on-Galaxy-S9.patch index 7e67a55..47d3990 100644 --- a/patches/phh/platform_frameworks_base/0021-backlight-Fix-backlight-control-on-Galaxy-S9.patch +++ b/patches/phh/platform_frameworks_base/0021-backlight-Fix-backlight-control-on-Galaxy-S9.patch @@ -1,7 +1,7 @@ -From 771f0408923f67c08bcc88f29f789ba059612ca4 Mon Sep 17 00:00:00 2001 +From 86652294b89fe3fa270d4fcdf824d1405ff6a569 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 24 Mar 2018 08:01:48 +0100 -Subject: [PATCH 21/31] :backlight: Fix backlight control on Galaxy S9(+) +Subject: [PATCH 21/33] :backlight: Fix backlight control on Galaxy S9(+) Change-Id: I1fbbb47939c377597ef8ad6b88b2acea5f4acaa6 diff --git a/patches/phh/platform_frameworks_base/0022-Add-support-for-app-signature-spoofing.patch b/patches/phh/platform_frameworks_base/0022-Add-support-for-app-signature-spoofing.patch index 0e2e22c..c2fba8a 100644 --- a/patches/phh/platform_frameworks_base/0022-Add-support-for-app-signature-spoofing.patch +++ b/patches/phh/platform_frameworks_base/0022-Add-support-for-app-signature-spoofing.patch @@ -1,7 +1,7 @@ -From a60642974537643ab7bbe4a486e9c6ffc31e68fb Mon Sep 17 00:00:00 2001 +From 398e104e8119cfa14cc43fd3628b005956b6e8e9 Mon Sep 17 00:00:00 2001 From: Danny Lin Date: Sat, 16 Oct 2021 05:27:57 -0700 -Subject: [PATCH 22/31] Add support for app signature spoofing +Subject: [PATCH 22/33] Add support for app signature spoofing This is needed by microG GmsCore to pretend to be the official Google Play Services package, because client apps check the package signature @@ -105,10 +105,10 @@ index 4a58a52388fb..19b38545bbbb 100644 disable or modify status bar diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java -index 327c590a0348..5806662ab6b6 100644 +index 8bc9cea63d81..00aa54b10181 100644 --- a/services/core/java/com/android/server/pm/PackageManagerService.java +++ b/services/core/java/com/android/server/pm/PackageManagerService.java -@@ -3322,6 +3322,29 @@ public class PackageManagerService extends IPackageManager.Stub +@@ -3326,6 +3326,29 @@ public class PackageManagerService extends IPackageManager.Stub return result; } @@ -138,7 +138,7 @@ index 327c590a0348..5806662ab6b6 100644 public final PackageInfo generatePackageInfo(PackageSetting ps, int flags, int userId) { if (!mUserManager.exists(userId)) return null; if (ps == null) { -@@ -3350,12 +3373,14 @@ public class PackageManagerService extends IPackageManager.Stub +@@ -3354,12 +3377,14 @@ public class PackageManagerService extends IPackageManager.Stub final int[] gids = (flags & PackageManager.GET_GIDS) == 0 ? EMPTY_INT_ARRAY : mPermissionManager.getGidsForUid(UserHandle.getUid(userId, ps.appId)); // Compute granted permissions only if package has requested permissions diff --git a/patches/phh/platform_frameworks_base/0023-Revert-Switch-long-press-power-behavior-in-AOSP.patch b/patches/phh/platform_frameworks_base/0023-Revert-Switch-long-press-power-behavior-in-AOSP.patch index 00e1e82..0238507 100644 --- a/patches/phh/platform_frameworks_base/0023-Revert-Switch-long-press-power-behavior-in-AOSP.patch +++ b/patches/phh/platform_frameworks_base/0023-Revert-Switch-long-press-power-behavior-in-AOSP.patch @@ -1,7 +1,7 @@ -From aae229dde6b00298aadb66eeb0e26b5dfb8bee90 Mon Sep 17 00:00:00 2001 +From 2f307a907cf992f5b0fa343f41619163cc323f4b Mon Sep 17 00:00:00 2001 From: Andy CrossGate Yan Date: Sat, 4 Sep 2021 08:26:30 +0000 -Subject: [PATCH 23/31] Revert "Switch long-press power behavior in AOSP." +Subject: [PATCH 23/33] Revert "Switch long-press power behavior in AOSP." This reverts commit 803c77a0a24624111944832098c6f65158051dc4. --- diff --git a/patches/phh/platform_frameworks_base/0024-Reduce-the-size-of-udfps-enroll-progress-bar.-Some-d.patch b/patches/phh/platform_frameworks_base/0024-Reduce-the-size-of-udfps-enroll-progress-bar.-Some-d.patch index 11ce5c7..96e985e 100644 --- a/patches/phh/platform_frameworks_base/0024-Reduce-the-size-of-udfps-enroll-progress-bar.-Some-d.patch +++ b/patches/phh/platform_frameworks_base/0024-Reduce-the-size-of-udfps-enroll-progress-bar.-Some-d.patch @@ -1,7 +1,7 @@ -From 4abeddbbe4094eeaa0309d0aa71ca8e1cf3a8d00 Mon Sep 17 00:00:00 2001 +From 67d6340250554d08f817299bd18cef9c0fcb48e3 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Fri, 17 Dec 2021 17:16:14 -0500 -Subject: [PATCH 24/31] Reduce the size of udfps enroll progress bar. Some +Subject: [PATCH 24/33] Reduce the size of udfps enroll progress bar. Some devices have their udfps pretty low, and the progress bar would make the icon at the wrong place diff --git a/patches/phh/platform_frameworks_base/0025-Add-UDFPS-support-for-various-devices.patch b/patches/phh/platform_frameworks_base/0025-Add-UDFPS-support-for-various-devices.patch index 3d8f684..dfe8cc3 100644 --- a/patches/phh/platform_frameworks_base/0025-Add-UDFPS-support-for-various-devices.patch +++ b/patches/phh/platform_frameworks_base/0025-Add-UDFPS-support-for-various-devices.patch @@ -1,7 +1,7 @@ -From a1202ed5896a82b3065ee4202e9267e3fce76448 Mon Sep 17 00:00:00 2001 +From 9435018a88eb29388ef47d7d7c60de0e231969eb Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sun, 19 Dec 2021 17:08:22 -0500 -Subject: [PATCH 25/31] Add UDFPS support for various devices +Subject: [PATCH 25/33] Add UDFPS support for various devices Successfully tested on Galaxy A51, Xiaomi Mi 9, and OnePlus Nord 2 diff --git a/patches/phh/platform_frameworks_base/0026-Dynamically-resize-boot-animation-to-match-screen-si.patch b/patches/phh/platform_frameworks_base/0026-Dynamically-resize-boot-animation-to-match-screen-si.patch index 65d93f2..b41c2df 100644 --- a/patches/phh/platform_frameworks_base/0026-Dynamically-resize-boot-animation-to-match-screen-si.patch +++ b/patches/phh/platform_frameworks_base/0026-Dynamically-resize-boot-animation-to-match-screen-si.patch @@ -1,7 +1,7 @@ -From 239dd51124b77aa849b327fe8a44a7c4ce506090 Mon Sep 17 00:00:00 2001 +From 8bafba118a2090ba39161135b5674c2a9d01d356 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 20 Dec 2021 15:01:41 -0500 -Subject: [PATCH 26/31] Dynamically resize boot animation to match screen size +Subject: [PATCH 26/33] Dynamically resize boot animation to match screen size Change-Id: I54e49fc6b8c670103852e212d1416e27ff976205 --- diff --git a/patches/phh/platform_frameworks_base/0027-Once-we-integrate-Samsung-Power-hal-in-libpowermanag.patch b/patches/phh/platform_frameworks_base/0027-Once-we-integrate-Samsung-Power-hal-in-libpowermanag.patch index 4dfcdb3..5c61324 100644 --- a/patches/phh/platform_frameworks_base/0027-Once-we-integrate-Samsung-Power-hal-in-libpowermanag.patch +++ b/patches/phh/platform_frameworks_base/0027-Once-we-integrate-Samsung-Power-hal-in-libpowermanag.patch @@ -1,7 +1,7 @@ -From 1e53161f3fb1a6d98b0d0d8999806e1c51497e16 Mon Sep 17 00:00:00 2001 +From 6a2a5877de73c7230fc113875b963002abd8bf5e Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Mon, 27 Dec 2021 17:57:11 -0500 -Subject: [PATCH 27/31] Once we integrate Samsung Power hal in libpowermanager, +Subject: [PATCH 27/33] Once we integrate Samsung Power hal in libpowermanager, libpowermanager and its deps require linking against vendor.samsung.hardware.miscpower@2.0 diff --git a/patches/phh/platform_frameworks_base/0028-Add-persist.sys.phh.ultrasonic_udfps-property-to-dis.patch b/patches/phh/platform_frameworks_base/0028-Add-persist.sys.phh.ultrasonic_udfps-property-to-dis.patch index 88915c9..d8e5300 100644 --- a/patches/phh/platform_frameworks_base/0028-Add-persist.sys.phh.ultrasonic_udfps-property-to-dis.patch +++ b/patches/phh/platform_frameworks_base/0028-Add-persist.sys.phh.ultrasonic_udfps-property-to-dis.patch @@ -1,7 +1,7 @@ -From cb545e45484f7f1835f59572c70ec7d042f4464e Mon Sep 17 00:00:00 2001 +From fe835d521af513c1610f3f8499d3e8f54aebd1aa Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 3 Mar 2022 09:15:32 -0500 -Subject: [PATCH 28/31] Add persist.sys.phh.ultrasonic_udfps property to +Subject: [PATCH 28/33] Add persist.sys.phh.ultrasonic_udfps property to disable green circle for udfps --- diff --git a/patches/phh/platform_frameworks_base/0029-Allow-128bits-SHA1-IPSec-keys.-This-is-required-to-i.patch b/patches/phh/platform_frameworks_base/0029-Allow-128bits-SHA1-IPSec-keys.-This-is-required-to-i.patch index d817f9e..d7193b4 100644 --- a/patches/phh/platform_frameworks_base/0029-Allow-128bits-SHA1-IPSec-keys.-This-is-required-to-i.patch +++ b/patches/phh/platform_frameworks_base/0029-Allow-128bits-SHA1-IPSec-keys.-This-is-required-to-i.patch @@ -1,7 +1,7 @@ -From 0182a7670eede77cb3af89a08b88daca3d3dde04 Mon Sep 17 00:00:00 2001 +From 3842e3d8e161df886c8293b1c73b4805c6e44a16 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 3 Mar 2022 09:17:17 -0500 -Subject: [PATCH 29/31] Allow 128bits SHA1 IPSec keys. This is required to +Subject: [PATCH 29/33] Allow 128bits SHA1 IPSec keys. This is required to implement VoLTE with this API --- diff --git a/patches/phh/platform_frameworks_base/0030-Fix-FOD-on-ZF8.patch b/patches/phh/platform_frameworks_base/0030-Fix-FOD-on-ZF8.patch index 730f5d8..9018ea2 100644 --- a/patches/phh/platform_frameworks_base/0030-Fix-FOD-on-ZF8.patch +++ b/patches/phh/platform_frameworks_base/0030-Fix-FOD-on-ZF8.patch @@ -1,7 +1,7 @@ -From 2a244f8dc55faa62c14fa97b805d1fed68109413 Mon Sep 17 00:00:00 2001 +From e9dd2f023a48656cd66ae122df082279aa23fd81 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Fri, 4 Mar 2022 19:26:53 -0500 -Subject: [PATCH 30/31] Fix FOD on ZF8 +Subject: [PATCH 30/33] Fix FOD on ZF8 Goodix HAL expects events in this order: - Fingerprint down when touchscreen says fp down diff --git a/patches/phh/platform_frameworks_base/0031-Allow-disabling-of-fingerprint-cleanups-needed-on-so.patch b/patches/phh/platform_frameworks_base/0031-Allow-disabling-of-fingerprint-cleanups-needed-on-so.patch index 15fdff3..ff62f6c 100644 --- a/patches/phh/platform_frameworks_base/0031-Allow-disabling-of-fingerprint-cleanups-needed-on-so.patch +++ b/patches/phh/platform_frameworks_base/0031-Allow-disabling-of-fingerprint-cleanups-needed-on-so.patch @@ -1,7 +1,7 @@ -From d7a50ef39c0b8025c9a23e715b46ae9c50d717fd Mon Sep 17 00:00:00 2001 +From ecd0a58ef016d20f1c3cbbf4fa4ea85042b6fb19 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 2 Apr 2022 18:04:01 -0400 -Subject: [PATCH 31/31] Allow disabling of fingerprint cleanups, needed on some +Subject: [PATCH 31/33] Allow disabling of fingerprint cleanups, needed on some Realme devices that cant enumerate --- diff --git a/patches/phh/platform_frameworks_base/0032-Switch-FOD-to-WHITE.patch b/patches/phh/platform_frameworks_base/0032-Switch-FOD-to-WHITE.patch new file mode 100644 index 0000000..bd41b45 --- /dev/null +++ b/patches/phh/platform_frameworks_base/0032-Switch-FOD-to-WHITE.patch @@ -0,0 +1,25 @@ +From 8bc9931d9e2f195cb7f1655e937a6687b58bee65 Mon Sep 17 00:00:00 2001 +From: Pierre-Hugues Husson +Date: Mon, 2 May 2022 18:02:25 -0400 +Subject: [PATCH 32/33] Switch FOD to WHITE + +--- + .../src/com/android/systemui/biometrics/UdfpsSurfaceView.java | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsSurfaceView.java b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsSurfaceView.java +index 51409b9c533a..77fad35d32d4 100644 +--- a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsSurfaceView.java ++++ b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsSurfaceView.java +@@ -69,7 +69,7 @@ public class UdfpsSurfaceView extends SurfaceView implements SurfaceHolder.Callb + + mSensorPaint = new Paint(0 /* flags */); + mSensorPaint.setAntiAlias(true); +- mSensorPaint.setARGB(255, 0, 255, 0); ++ mSensorPaint.setARGB(255, 255, 255, 255); + mSensorPaint.setStyle(Paint.Style.FILL); + } + +-- +2.32.0 (Apple Git-132) + diff --git a/patches/phh/platform_frameworks_base/0033-Support-samsung-ultrasonic-udfps.patch b/patches/phh/platform_frameworks_base/0033-Support-samsung-ultrasonic-udfps.patch new file mode 100644 index 0000000..0586f9d --- /dev/null +++ b/patches/phh/platform_frameworks_base/0033-Support-samsung-ultrasonic-udfps.patch @@ -0,0 +1,83 @@ +From 20dc89cf3209496bbe77ece0b8f35c53672b5ced Mon Sep 17 00:00:00 2001 +From: Pierre-Hugues Husson +Date: Mon, 2 May 2022 18:02:40 -0400 +Subject: [PATCH 33/33] Support samsung ultrasonic udfps + +--- + .../systemui/biometrics/UdfpsView.java | 4 +++- + .../sensors/fingerprint/UdfpsHelper.java | 23 +++++++++++++++++++ + 2 files changed, 26 insertions(+), 1 deletion(-) + +diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java +index c60318a9baf7..c16aa7e7419a 100644 +--- a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java ++++ b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsView.java +@@ -65,7 +65,7 @@ public class UdfpsView extends FrameLayout implements DozeReceiver, UdfpsIllumin + @NonNull private final Paint mDebugTextPaint; + private final float mSensorTouchAreaCoefficient; + private final int mOnIlluminatedDelayMs; +- private final @HbmType int mHbmType; ++ private @HbmType int mHbmType; + + // Only used for UdfpsHbmTypes.GLOBAL_HBM. + @Nullable private UdfpsSurfaceView mGhbmView; +@@ -151,6 +151,8 @@ public class UdfpsView extends FrameLayout implements DozeReceiver, UdfpsIllumin + SETTING_HBM_TYPE, DEFAULT_HBM_TYPE, UserHandle.USER_CURRENT); + } else { + mHbmType = DEFAULT_HBM_TYPE; ++ if(android.os.SystemProperties.getBoolean("persist.sys.phh.ultrasonic_udfps", false)) ++ mHbmType = UdfpsHbmTypes.LOCAL_HBM; + } + } + +diff --git a/services/core/java/com/android/server/biometrics/sensors/fingerprint/UdfpsHelper.java b/services/core/java/com/android/server/biometrics/sensors/fingerprint/UdfpsHelper.java +index e97f70d7bffd..8e99392cf545 100644 +--- a/services/core/java/com/android/server/biometrics/sensors/fingerprint/UdfpsHelper.java ++++ b/services/core/java/com/android/server/biometrics/sensors/fingerprint/UdfpsHelper.java +@@ -24,6 +24,7 @@ import android.os.RemoteException; + import android.util.Slog; + + import vendor.goodix.hardware.biometrics.fingerprint.V2_1.IGoodixFingerprintDaemon; ++import vendor.samsung.hardware.biometrics.fingerprint.V3_0.ISehBiometricsFingerprint; + + import java.io.PrintWriter; + +@@ -59,6 +60,17 @@ public class UdfpsHelper { + } + } + ++ try { ++ if("true".equals(android.os.SystemProperties.get("persist.sys.phh.ultrasonic_udfps"))) { ++ Slog.e(TAG, "trying ultrasonic samsung pressed"); ++ ISehBiometricsFingerprint fp = ISehBiometricsFingerprint.getService(); ++ fp.sehRequest(22 /* SEM_FINGER_STATE */, 2 /* finger pressed */, new java.util.ArrayList(), ++ (int retval, java.util.ArrayList out) -> {} ); ++ } ++ } catch(Throwable t) { ++ Slog.e(TAG, "Tried sending Samsung command failed"); ++ } ++ + try { + // Asus goodix commands + IGoodixFingerprintDaemon goodixDaemon = IGoodixFingerprintDaemon.getService(); +@@ -114,6 +126,17 @@ public class UdfpsHelper { + } + } + ++ try { ++ if("true".equals(android.os.SystemProperties.get("persist.sys.phh.ultrasonic_udfps"))) { ++ Slog.e(TAG, "trying ultrasonic samsung released"); ++ ISehBiometricsFingerprint fp = ISehBiometricsFingerprint.getService(); ++ fp.sehRequest(22 /* SEM_FINGER_STATE */, 1 /* finger pressed */, new java.util.ArrayList(), ++ (int retval, java.util.ArrayList out) -> {} ); ++ } ++ } catch(Throwable t) { ++ Slog.e(TAG, "Tried sending Samsung command failed"); ++ } ++ + try { + IGoodixFingerprintDaemon goodixDaemon = IGoodixFingerprintDaemon.getService(); + if(android.os.SystemProperties.get("ro.vendor.build.fingerprint").contains("ASUS")) { +-- +2.32.0 (Apple Git-132) + diff --git a/patches/phh/platform_packages_apps_Settings/0001-Act-as-usb-device-when-there-is-no-hal-but-we-believ.patch b/patches/phh/platform_packages_apps_Settings/0001-Act-as-usb-device-when-there-is-no-hal-but-we-believ.patch index 3cbb26b..952783c 100644 --- a/patches/phh/platform_packages_apps_Settings/0001-Act-as-usb-device-when-there-is-no-hal-but-we-believ.patch +++ b/patches/phh/platform_packages_apps_Settings/0001-Act-as-usb-device-when-there-is-no-hal-but-we-believ.patch @@ -1,8 +1,8 @@ -From f2bf18774000c5e058af0ddb3b88fb7a0255fc55 Mon Sep 17 00:00:00 2001 +From 5a8098378664681814c876222d326b2d2a215ccc Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Tue, 14 Aug 2018 21:48:19 +0200 -Subject: [PATCH] Act as usb device when there is no hal, but we believe we are - a device +Subject: [PATCH 1/2] Act as usb device when there is no hal, but we believe we + are a device Change-Id: I036090738525fd8cc63534d52d02ab1852950a7d --- diff --git a/patches/phh/platform_packages_apps_Settings/0002-Ignore-cancelled-fingerprint-events-they-are-expecte.patch b/patches/phh/platform_packages_apps_Settings/0002-Ignore-cancelled-fingerprint-events-they-are-expecte.patch new file mode 100644 index 0000000..c7c8935 --- /dev/null +++ b/patches/phh/platform_packages_apps_Settings/0002-Ignore-cancelled-fingerprint-events-they-are-expecte.patch @@ -0,0 +1,40 @@ +From 3d6e45a1418b25dd5e4f2ad65f92a5686e721e73 Mon Sep 17 00:00:00 2001 +From: Pierre-Hugues Husson +Date: Mon, 2 May 2022 17:44:28 -0400 +Subject: [PATCH 2/2] Ignore cancelled fingerprint events, they are expected, + plus add more fingerprint enroll logs + +--- + .../biometrics/fingerprint/FingerprintEnrollEnrolling.java | 3 +++ + .../biometrics/fingerprint/FingerprintEnrollFindSensor.java | 1 + + 2 files changed, 4 insertions(+) + +diff --git a/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollEnrolling.java b/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollEnrolling.java +index c2bcee3342..f3f7a9b689 100644 +--- a/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollEnrolling.java ++++ b/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollEnrolling.java +@@ -434,6 +434,9 @@ public class FingerprintEnrollEnrolling extends BiometricsEnrollEnrolling { + + @Override + public void onEnrollmentError(int errMsgId, CharSequence errString) { ++ android.util.Log.e("PHH-Enroll", "heyo " + errMsgId + ", " + errString , new Exception()); ++ if (errMsgId == 5) return; ++ + FingerprintErrorDialog.showErrorDialog(this, errMsgId); + stopIconAnimation(); + if (!mCanAssumeUdfps) { +diff --git a/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollFindSensor.java b/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollFindSensor.java +index 405c090552..f797257261 100644 +--- a/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollFindSensor.java ++++ b/src/com/android/settings/biometrics/fingerprint/FingerprintEnrollFindSensor.java +@@ -230,6 +230,7 @@ public class FingerprintEnrollFindSensor extends BiometricEnrollBase implements + + @Override + public void onEnrollmentError(int errMsgId, CharSequence errString) { ++ android.util.Log.e("PHH-Enroll", "heyo " + errMsgId + ", " + errString + ", " + mNextClicked, new Exception()); + if (mNextClicked && errMsgId == FingerprintManager.FINGERPRINT_ERROR_CANCELED) { + mNextClicked = false; + proceedToEnrolling(false /* cancelEnrollment */); +-- +2.25.1 +